[mutter] barrier: Make type derivable again



commit af65a01057b540cdaa88eb1744fe82c7a82698d8
Author: Jonas Ã…dahl <jadahl gmail com>
Date:   Thu Sep 15 10:13:57 2022 +0200

    barrier: Make type derivable again
    
    This was used gala to implement hot corners, and the way the barrier API
    works, there isn't really any practical reasons to not make it
    derivable, since the backend is a separate type and object.
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2626>

 src/backends/meta-barrier.c | 5 -----
 src/meta/barrier.h          | 9 +++++++--
 2 files changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/src/backends/meta-barrier.c b/src/backends/meta-barrier.c
index e227a83f15..dfcf5c41eb 100644
--- a/src/backends/meta-barrier.c
+++ b/src/backends/meta-barrier.c
@@ -23,11 +23,6 @@
 #include "backends/native/meta-barrier-native.h"
 #endif
 
-struct _MetaBarrier
-{
-  GObject parent;
-};
-
 typedef struct _MetaBarrierPrivate
 {
   MetaBackend *backend;
diff --git a/src/meta/barrier.h b/src/meta/barrier.h
index 374c42f0b7..ac090fb679 100644
--- a/src/meta/barrier.h
+++ b/src/meta/barrier.h
@@ -28,8 +28,13 @@ typedef enum
 
 #define META_TYPE_BARRIER (meta_barrier_get_type ())
 META_EXPORT
-G_DECLARE_FINAL_TYPE (MetaBarrier, meta_barrier,
-                      META, BARRIER, GObject)
+G_DECLARE_DERIVABLE_TYPE (MetaBarrier, meta_barrier,
+                          META, BARRIER, GObject)
+
+struct _MetaBarrierClass
+{
+  GObjectClass parent_class;
+};
 
 typedef struct _MetaBarrierEvent MetaBarrierEvent;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]