[gnome-control-center] Adapt to changes in hdy_init()



commit 726684e9e0c73c56a18c65a50af05b94ff77e2de
Author: Adrien Plazas <kekun plazas laposte net>
Date:   Fri Mar 6 09:20:53 2020 +0100

    Adapt to changes in hdy_init()
    
    It must now be called after initializing GTK, and doesn't take
    parameters.

 shell/cc-application.c             | 4 ++++
 shell/main.c                       | 5 -----
 tests/network/test-network-panel.c | 2 +-
 3 files changed, 5 insertions(+), 6 deletions(-)
---
diff --git a/shell/cc-application.c b/shell/cc-application.c
index 8de3c6fb4f..3f066f6ad5 100644
--- a/shell/cc-application.c
+++ b/shell/cc-application.c
@@ -24,6 +24,8 @@
 #include <glib.h>
 #include <glib/gi18n.h>
 #include <gio/gio.h>
+#define HANDY_USE_UNSTABLE_API
+#include <handy.h>
 
 #include "cc-application.h"
 #include "cc-log.h"
@@ -224,6 +226,8 @@ cc_application_startup (GApplication *application)
 
   G_APPLICATION_CLASS (cc_application_parent_class)->startup (application);
 
+  hdy_init ();
+
   gtk_application_set_accels_for_action (GTK_APPLICATION (application),
                                          "app.help", help_accels);
 
diff --git a/shell/main.c b/shell/main.c
index 425306bc25..14c81c5f77 100644
--- a/shell/main.c
+++ b/shell/main.c
@@ -33,9 +33,6 @@
 #include <cheese-gtk.h>
 #endif /* HAVE_CHEESE */
 
-#define HANDY_USE_UNSTABLE_API
-#include <handy.h>
-
 #include "cc-application.h"
 
 static void
@@ -49,8 +46,6 @@ initialize_dependencies (gint    *argc,
   #ifdef HAVE_CHEESE
     cheese_gtk_init (argc, argv);
   #endif /* HAVE_CHEESE */
-
-    hdy_init (argc, argv);
 }
 
 int
diff --git a/tests/network/test-network-panel.c b/tests/network/test-network-panel.c
index 1f89e21874..1032f43c49 100644
--- a/tests/network/test-network-panel.c
+++ b/tests/network/test-network-panel.c
@@ -651,7 +651,7 @@ main (int argc, char **argv)
   g_setenv ("LC_ALL", "C", TRUE);
 
   gtk_test_init (&argc, &argv, NULL);
-  hdy_init (&argc, &argv);
+  hdy_init ();
 
   g_test_add ("/network-panel-wired/empty-ui",
               NetworkPanelFixture,


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