[gnome-control-center] network: Sync airplane mode status on startup
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] network: Sync airplane mode status on startup
- Date: Fri, 16 Aug 2013 17:37:33 +0000 (UTC)
commit 6d353f296eb36ef149d2134d51db449cbaf4a9ac
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Aug 14 21:01:58 2013 -0400
network: Sync airplane mode status on startup
https://bugzilla.gnome.org/show_bug.cgi?id=706042
panels/network/cc-network-panel.c | 15 ++++++++++-----
1 files changed, 10 insertions(+), 5 deletions(-)
---
diff --git a/panels/network/cc-network-panel.c b/panels/network/cc-network-panel.c
index 1af45e7..8a469bb 100644
--- a/panels/network/cc-network-panel.c
+++ b/panels/network/cc-network-panel.c
@@ -289,12 +289,8 @@ cc_network_panel_notify_enable_active_cb (GtkSwitch *sw,
}
static void
-on_property_change (GDBusProxy *proxy,
- GVariant *changed_properties,
- GVariant *invalidated_properties,
- gpointer user_data)
+sync_airplane_mode_switch (CcNetworkPanel *panel)
{
- CcNetworkPanel *panel = CC_NETWORK_PANEL (user_data);
GVariant *result;
gboolean enabled;
@@ -310,7 +306,15 @@ on_property_change (GDBusProxy *proxy,
cc_network_panel_notify_enable_active_cb,
panel);
}
+}
+static void
+on_property_change (GDBusProxy *proxy,
+ GVariant *changed_properties,
+ GVariant *invalidated_properties,
+ gpointer user_data)
+{
+ sync_airplane_mode_switch (CC_NETWORK_PANEL (user_data));
}
static void
@@ -328,6 +332,7 @@ got_rfkill_proxy_cb (GObject *source_object, GAsyncResult *res, gpointer user_da
g_signal_connect (panel->priv->rfkill_proxy, "g-properties-changed",
G_CALLBACK (on_property_change), panel);
+ sync_airplane_mode_switch (panel);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]