[gnome-software] trivial: Correctly connect to the plugin loader signal from the update monitor



commit 1dacef3598daff2fc11cd569730b838f85264847
Author: Richard Hughes <richard hughsie com>
Date:   Wed Nov 2 10:39:47 2016 +0000

    trivial: Correctly connect to the plugin loader signal from the update monitor

 src/gs-update-monitor.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)
---
diff --git a/src/gs-update-monitor.c b/src/gs-update-monitor.c
index 5b433b9..99f5c7f 100644
--- a/src/gs-update-monitor.c
+++ b/src/gs-update-monitor.c
@@ -728,11 +728,6 @@ gs_update_monitor_init (GsUpdateMonitor *monitor)
        } else {
                g_warning ("failed to connect to upower: %s", error->message);
        }
-
-       g_signal_connect_object (monitor->plugin_loader,
-                                "notify::allow-updates",
-                                G_CALLBACK (allow_updates_notify_cb),
-                                monitor, 0);
 }
 
 static void
@@ -809,6 +804,8 @@ gs_update_monitor_new (GsApplication *application)
        monitor->plugin_loader = gs_application_get_plugin_loader (application);
        g_signal_connect (monitor->plugin_loader, "updates-changed",
                          G_CALLBACK (updates_changed_cb), monitor);
+       g_signal_connect (monitor->plugin_loader, "notify::allow-updates",
+                         G_CALLBACK (allow_updates_notify_cb), monitor);
 
        return monitor;
 }


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