diff options
author | Dan Williams <dcbw@redhat.com> | 2014-09-11 14:34:09 -0500 |
---|---|---|
committer | Dan Williams <dcbw@redhat.com> | 2014-09-11 15:02:55 -0500 |
commit | 63cd19e2b56272ea4f51553330ff2d8dcd6dccce (patch) | |
tree | 894e92cce151b0624f0abb2a93c366443f271cf1 | |
parent | a8a9dfed425ce5f0010ad6d99d0eb09098b9a565 (diff) | |
download | network-manager-applet-63cd19e2b56272ea4f51553330ff2d8dcd6dccce.tar.gz |
applet: remove useless "loop" property
It's not used anywhere in NMApplet.
-rw-r--r-- | src/applet.c | 34 | ||||
-rw-r--r-- | src/applet.h | 2 | ||||
-rw-r--r-- | src/main.c | 2 |
3 files changed, 4 insertions, 34 deletions
diff --git a/src/applet.c b/src/applet.c index 48b5f663..81e2ac52 100644 --- a/src/applet.c +++ b/src/applet.c @@ -3821,39 +3821,12 @@ static void nma_init (NMApplet *applet) applet->icon_size = 16; } -enum { - PROP_0, - PROP_LOOP, - LAST_PROP -}; - -static void -set_property (GObject *object, guint prop_id, - const GValue *value, GParamSpec *pspec) -{ - NMApplet *applet = NM_APPLET (object); - - switch (prop_id) { - case PROP_LOOP: - applet->loop = g_value_get_pointer (value); - break; - default: - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); - break; - } -} - static void nma_class_init (NMAppletClass *klass) { GObjectClass *oclass = G_OBJECT_CLASS (klass); - GParamSpec *pspec; - oclass->set_property = set_property; oclass->finalize = finalize; - pspec = g_param_spec_pointer ("loop", "Loop", "Applet mainloop", G_PARAM_CONSTRUCT | G_PARAM_WRITABLE); - g_object_class_install_property (oclass, PROP_LOOP, pspec); - dbus_g_object_type_install_info (NM_TYPE_APPLET, &dbus_glib_nma_object_info); } @@ -3864,19 +3837,16 @@ nma_initable_interface_init (GInitableIface *iface, gpointer iface_data) } NMApplet * -nm_applet_new (GMainLoop *loop) +nm_applet_new (void) { NMApplet *applet; GError *error = NULL; - applet = g_initable_new (NM_TYPE_APPLET, NULL, &error, - "loop", loop, - NULL); + applet = g_initable_new (NM_TYPE_APPLET, NULL, &error, NULL); if (!applet) { g_warning ("%s", error->message); g_error_free (error); } - return applet; } diff --git a/src/applet.h b/src/applet.h index 174e42a1..cd5ac97c 100644 --- a/src/applet.h +++ b/src/applet.h @@ -268,7 +268,7 @@ struct NMADeviceClass { GType nma_get_type (void); -NMApplet *nm_applet_new (GMainLoop *loop); +NMApplet *nm_applet_new (void); void applet_schedule_update_icon (NMApplet *applet); @@ -98,7 +98,7 @@ int main (int argc, char *argv[]) loop = g_main_loop_new (NULL, FALSE); - applet = nm_applet_new (loop); + applet = nm_applet_new (); if (applet == NULL) exit (1); |