[gnome-builder] libide-plugins: port to GTK 4 and remove libdazzle usage



commit c0714f7edf21199f0c17c8c875ee02b09b7a9b22
Author: Christian Hergert <chergert redhat com>
Date:   Mon Jul 11 17:56:11 2022 -0700

    libide-plugins: port to GTK 4 and remove libdazzle usage

 src/libide/plugins/ide-extension-adapter.c     | 17 +++++------------
 src/libide/plugins/ide-extension-adapter.h     | 19 ++++++++++---------
 src/libide/plugins/ide-extension-set-adapter.c |  9 ---------
 src/libide/plugins/ide-extension-set-adapter.h | 25 +++++++++++++------------
 src/libide/plugins/ide-extension-util.c        |  2 --
 src/libide/plugins/libide-plugins.h            |  6 ++----
 src/libide/plugins/meson.build                 |  2 --
 7 files changed, 30 insertions(+), 50 deletions(-)
---
diff --git a/src/libide/plugins/ide-extension-adapter.c b/src/libide/plugins/ide-extension-adapter.c
index ea912bd59..5bb59ce13 100644
--- a/src/libide/plugins/ide-extension-adapter.c
+++ b/src/libide/plugins/ide-extension-adapter.c
@@ -22,7 +22,6 @@
 
 #include "config.h"
 
-#include <dazzle.h>
 #include <glib/gi18n.h>
 
 #include "ide-extension-adapter.h"
@@ -36,7 +35,7 @@ struct _IdeExtensionAdapter
   gchar          *key;
   gchar          *value;
   GObject        *extension;
-  DzlSignalGroup *settings_signals;
+  IdeSignalGroup *settings_signals;
   GSettings      *settings;
 
   PeasPluginInfo *plugin_info;
@@ -96,13 +95,13 @@ ide_extension_adapter_monitor (IdeExtensionAdapter *self,
   g_assert (IDE_IS_MAIN_THREAD ());
   g_assert (IDE_IS_EXTENSION_ADAPTER (self));
 
-  dzl_signal_group_set_target (self->settings_signals, NULL);
+  ide_signal_group_set_target (self->settings_signals, NULL);
   g_clear_object (&self->settings);
 
   if (plugin_info != NULL)
     {
       self->settings = ide_extension_adapter_get_settings (self, plugin_info);
-      dzl_signal_group_set_target (self->settings_signals, self->settings);
+      ide_signal_group_set_target (self->settings_signals, self->settings);
     }
 }
 
@@ -470,8 +469,8 @@ ide_extension_adapter_init (IdeExtensionAdapter *self)
 {
   self->interface_type = G_TYPE_INVALID;
 
-  self->settings_signals = dzl_signal_group_new (G_TYPE_SETTINGS);
-  dzl_signal_group_connect_object (self->settings_signals,
+  self->settings_signals = ide_signal_group_new (G_TYPE_SETTINGS);
+  ide_signal_group_connect_object (self->settings_signals,
                                    "changed::disabled",
                                    G_CALLBACK (ide_extension_adapter__changed_disabled),
                                    self,
@@ -544,8 +543,6 @@ ide_extension_adapter_get_interface_type (IdeExtensionAdapter *self)
  * Gets the #IdeExtensionAdapter:engine property.
  *
  * Returns: (transfer none): a #PeasEngine.
- *
- * Since: 3.32
  */
 PeasEngine *
 ide_extension_adapter_get_engine (IdeExtensionAdapter *self)
@@ -562,8 +559,6 @@ ide_extension_adapter_get_engine (IdeExtensionAdapter *self)
  * Gets the extension object managed by the adapter.
  *
  * Returns: (transfer none) (type GObject.Object): a #GObject or %NULL.
- *
- * Since: 3.32
  */
 gpointer
 ide_extension_adapter_get_extension (IdeExtensionAdapter *self)
@@ -598,8 +593,6 @@ ide_extension_adapter_get_extension (IdeExtensionAdapter *self)
  * be used.
  *
  * Returns: (transfer full): A newly created #IdeExtensionAdapter.
- *
- * Since: 3.32
  */
 IdeExtensionAdapter *
 ide_extension_adapter_new (IdeObject   *parent,
diff --git a/src/libide/plugins/ide-extension-adapter.h b/src/libide/plugins/ide-extension-adapter.h
index e8499ec69..34fc098c7 100644
--- a/src/libide/plugins/ide-extension-adapter.h
+++ b/src/libide/plugins/ide-extension-adapter.h
@@ -25,35 +25,36 @@
 #endif
 
 #include <libpeas/peas.h>
+
 #include <libide-core.h>
 
 G_BEGIN_DECLS
 
 #define IDE_TYPE_EXTENSION_ADAPTER (ide_extension_adapter_get_type())
 
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 G_DECLARE_FINAL_TYPE (IdeExtensionAdapter, ide_extension_adapter, IDE, EXTENSION_ADAPTER, IdeObject)
 
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 IdeExtensionAdapter *ide_extension_adapter_new                (IdeObject           *parent,
                                                                PeasEngine          *engine,
                                                                GType                interface_type,
                                                                const gchar         *key,
                                                                const gchar         *value);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 PeasEngine          *ide_extension_adapter_get_engine         (IdeExtensionAdapter *self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 gpointer             ide_extension_adapter_get_extension      (IdeExtensionAdapter *self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 GType                ide_extension_adapter_get_interface_type (IdeExtensionAdapter *self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 const gchar         *ide_extension_adapter_get_key            (IdeExtensionAdapter *self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 void                 ide_extension_adapter_set_key            (IdeExtensionAdapter *self,
                                                                const gchar         *key);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 const gchar         *ide_extension_adapter_get_value          (IdeExtensionAdapter *self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 void                 ide_extension_adapter_set_value          (IdeExtensionAdapter *self,
                                                                const gchar         *value);
 
diff --git a/src/libide/plugins/ide-extension-set-adapter.c b/src/libide/plugins/ide-extension-set-adapter.c
index 9b9a62ac8..ad9fe72be 100644
--- a/src/libide/plugins/ide-extension-set-adapter.c
+++ b/src/libide/plugins/ide-extension-set-adapter.c
@@ -22,7 +22,6 @@
 
 #include "config.h"
 
-#include <dazzle.h>
 #include <glib/gi18n.h>
 #include <stdlib.h>
 
@@ -553,8 +552,6 @@ ide_extension_set_adapter_init (IdeExtensionSetAdapter *self)
  * Gets the #IdeExtensionSetAdapter:engine property.
  *
  * Returns: (transfer none): a #PeasEngine.
- *
- * Since: 3.32
  */
 PeasEngine *
 ide_extension_set_adapter_get_engine (IdeExtensionSetAdapter *self)
@@ -632,8 +629,6 @@ ide_extension_set_adapter_set_value (IdeExtensionSetAdapter *self,
  * @user_data: user data for @foreach_func
  *
  * Calls @foreach_func for every extension loaded by the extension set.
- *
- * Since: 3.32
  */
 void
 ide_extension_set_adapter_foreach (IdeExtensionSetAdapter            *self,
@@ -693,8 +688,6 @@ sort_by_priority (gconstpointer a,
  * @user_data: user data for @foreach_func
  *
  * Calls @foreach_func for every extension loaded by the extension set.
- *
- * Since: 3.32
  */
 void
 ide_extension_set_adapter_foreach_by_priority (IdeExtensionSetAdapter            *self,
@@ -799,8 +792,6 @@ ide_extension_set_adapter_new (IdeObject   *parent,
  * Locates the extension owned by @plugin_info if such extension exists.
  *
  * Returns: (transfer none) (nullable): a #PeasExtension or %NULL
- *
- * Since: 3.32
  */
 PeasExtension *
 ide_extension_set_adapter_get_extension (IdeExtensionSetAdapter *self,
diff --git a/src/libide/plugins/ide-extension-set-adapter.h b/src/libide/plugins/ide-extension-set-adapter.h
index 16b213e82..46e0820ca 100644
--- a/src/libide/plugins/ide-extension-set-adapter.h
+++ b/src/libide/plugins/ide-extension-set-adapter.h
@@ -25,13 +25,14 @@
 #endif
 
 #include <libpeas/peas.h>
+
 #include <libide-core.h>
 
 G_BEGIN_DECLS
 
 #define IDE_TYPE_EXTENSION_SET_ADAPTER (ide_extension_set_adapter_get_type())
 
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 G_DECLARE_FINAL_TYPE (IdeExtensionSetAdapter, ide_extension_set_adapter, IDE, EXTENSION_SET_ADAPTER, 
IdeObject)
 
 typedef void (*IdeExtensionSetAdapterForeachFunc) (IdeExtensionSetAdapter *set,
@@ -39,37 +40,37 @@ typedef void (*IdeExtensionSetAdapterForeachFunc) (IdeExtensionSetAdapter *set,
                                                    PeasExtension          *extension,
                                                    gpointer                user_data);
 
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 IdeExtensionSetAdapter *ide_extension_set_adapter_new                 (IdeObject                         
*parent,
                                                                        PeasEngine                        
*engine,
                                                                        GType                              
interface_type,
                                                                        const gchar                       
*key,
                                                                        const gchar                       
*value);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 PeasEngine             *ide_extension_set_adapter_get_engine          (IdeExtensionSetAdapter            
*self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 GType                   ide_extension_set_adapter_get_interface_type  (IdeExtensionSetAdapter            
*self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 const gchar            *ide_extension_set_adapter_get_key             (IdeExtensionSetAdapter            
*self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 void                    ide_extension_set_adapter_set_key             (IdeExtensionSetAdapter            
*self,
                                                                        const gchar                       
*key);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 const gchar            *ide_extension_set_adapter_get_value           (IdeExtensionSetAdapter            
*self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 void                    ide_extension_set_adapter_set_value           (IdeExtensionSetAdapter            
*self,
                                                                        const gchar                       
*value);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 guint                   ide_extension_set_adapter_get_n_extensions    (IdeExtensionSetAdapter            
*self);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 void                    ide_extension_set_adapter_foreach             (IdeExtensionSetAdapter            
*self,
                                                                        IdeExtensionSetAdapterForeachFunc  
foreach_func,
                                                                        gpointer                           
user_data);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 void                    ide_extension_set_adapter_foreach_by_priority (IdeExtensionSetAdapter            
*self,
                                                                        IdeExtensionSetAdapterForeachFunc  
foreach_func,
                                                                        gpointer                           
user_data);
-IDE_AVAILABLE_IN_3_32
+IDE_AVAILABLE_IN_ALL
 PeasExtension          *ide_extension_set_adapter_get_extension       (IdeExtensionSetAdapter            
*self,
                                                                        PeasPluginInfo                    
*plugin_info);
 
diff --git a/src/libide/plugins/ide-extension-util.c b/src/libide/plugins/ide-extension-util.c
index d198f7e70..19680a74f 100644
--- a/src/libide/plugins/ide-extension-util.c
+++ b/src/libide/plugins/ide-extension-util.c
@@ -249,8 +249,6 @@ G_GNUC_END_IGNORE_DEPRECATIONS
  * but looking at base-classes in addition to interface properties.
  *
  * Returns: (transfer full): a #PeasExtensionSet.
- *
- * Since: 3.32
  */
 PeasExtensionSet *
 ide_extension_set_new (PeasEngine     *engine,
diff --git a/src/libide/plugins/libide-plugins.h b/src/libide/plugins/libide-plugins.h
index 1260890cd..91065a612 100644
--- a/src/libide/plugins/libide-plugins.h
+++ b/src/libide/plugins/libide-plugins.h
@@ -25,10 +25,8 @@
 G_BEGIN_DECLS
 
 #define IDE_PLUGINS_INSIDE
-
-#include "ide-extension-adapter.h"
-#include "ide-extension-set-adapter.h"
-
+# include "ide-extension-adapter.h"
+# include "ide-extension-set-adapter.h"
 #undef IDE_PLUGINS_INSIDE
 
 G_END_DECLS
diff --git a/src/libide/plugins/meson.build b/src/libide/plugins/meson.build
index fff599db3..c3337a283 100644
--- a/src/libide/plugins/meson.build
+++ b/src/libide/plugins/meson.build
@@ -37,8 +37,6 @@ libide_plugins_private_sources = [
 libide_plugins_deps = [
   libgio_dep,
   libpeas_dep,
-  libdazzle_dep,
-
   libide_core_dep,
 ]
 


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