diff options
Diffstat (limited to 'meta/recipes-connectivity/connman/connman-gnome/0001-Monitor-the-Manager-s-State-property.patch')
-rw-r--r-- | meta/recipes-connectivity/connman/connman-gnome/0001-Monitor-the-Manager-s-State-property.patch | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/connman/connman-gnome/0001-Monitor-the-Manager-s-State-property.patch b/meta/recipes-connectivity/connman/connman-gnome/0001-Monitor-the-Manager-s-State-property.patch new file mode 100644 index 0000000000..20cbb30c1c --- /dev/null +++ b/meta/recipes-connectivity/connman/connman-gnome/0001-Monitor-the-Manager-s-State-property.patch | |||
@@ -0,0 +1,48 @@ | |||
1 | From 56d307993c0a661c73fcdd72b1392c3719a0c297 Mon Sep 17 00:00:00 2001 | ||
2 | Message-Id: <56d307993c0a661c73fcdd72b1392c3719a0c297.1334369310.git.paul.eggleton@linux.intel.com> | ||
3 | In-Reply-To: <cover.1334369310.git.paul.eggleton@linux.intel.com> | ||
4 | References: <cover.1334369310.git.paul.eggleton@linux.intel.com> | ||
5 | From: Joshua Lock <josh@linux.intel.com> | ||
6 | Date: Tue, 10 Apr 2012 17:54:56 -0700 | ||
7 | Subject: [PATCH 1/6] Monitor the Manager's State property | ||
8 | |||
9 | Monitor the Manager's State property and update global_ready | ||
10 | appropriately when it changes. | ||
11 | |||
12 | Without this change using the applet with connman 0.79 and | ||
13 | starting the applet after the daemon no status icon is shown. | ||
14 | |||
15 | With this change this icon displays an appropriate state when | ||
16 | the applet launches. | ||
17 | |||
18 | Upstream-Status: Submitted | ||
19 | |||
20 | Signed-off-by: Joshua Lock <josh@linux.intel.com> | ||
21 | --- | ||
22 | applet/main.c | 10 ++++++++++ | ||
23 | 1 files changed, 10 insertions(+), 0 deletions(-) | ||
24 | |||
25 | diff --git a/applet/main.c b/applet/main.c | ||
26 | index 224e2fd..68a77b1 100644 | ||
27 | --- a/applet/main.c | ||
28 | +++ b/applet/main.c | ||
29 | @@ -111,6 +111,16 @@ static void manager_property_changed(DBusGProxy *proxy, const char *property, | ||
30 | iterate_list, &path); | ||
31 | update_service(proxy, path); | ||
32 | g_free(path); | ||
33 | + } else if (g_str_equal(property, "State") == TRUE) { | ||
34 | + const gchar *state = g_value_get_string(value); | ||
35 | + | ||
36 | + if (g_strcmp0(state, "ready") == 0 || g_strcmp0(state, "online") == 0) { | ||
37 | + global_ready = TRUE; | ||
38 | + status_ready(global_strength); | ||
39 | + } else { | ||
40 | + global_ready = FALSE; | ||
41 | + status_offline(); | ||
42 | + } | ||
43 | } | ||
44 | } | ||
45 | |||
46 | -- | ||
47 | 1.7.5.4 | ||
48 | |||