summaryrefslogtreecommitdiff
path: root/battstat/battstat-upower.c
diff options
context:
space:
mode:
authorraveit65 <[email protected]>2013-11-10 03:03:38 +0100
committerraveit65 <[email protected]>2013-11-10 03:03:38 +0100
commit1e464e89fa0305266e72e3fce43f49e59b4a8ef8 (patch)
tree167b3844e907b818f5d0fc5c1b988ba4addcddb6 /battstat/battstat-upower.c
parentcabc210f238dfb89d535d4169bcff884c2616ea3 (diff)
downloadmate-applets-1e464e89fa0305266e72e3fce43f49e59b4a8ef8.tar.bz2
mate-applets-1e464e89fa0305266e72e3fce43f49e59b4a8ef8.tar.xz
battstat: use g_signal notify for upower-1.0
Diffstat (limited to 'battstat/battstat-upower.c')
-rw-r--r--battstat/battstat-upower.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/battstat/battstat-upower.c b/battstat/battstat-upower.c
index f10e6fc4..f42de3fd 100644
--- a/battstat/battstat-upower.c
+++ b/battstat/battstat-upower.c
@@ -92,8 +92,11 @@ battstat_upower_initialise (void (*callback) (void))
goto error_shutdownclient;
}
#endif
-
+#if UP_CHECK_VERSION(0, 99, 0)
+ g_signal_connect_after( upc, "notify", device_cb, NULL );
+#else
g_signal_connect_after( upc, "device-changed", device_cb, NULL );
+#endif
g_signal_connect_after( upc, "device-added", device_cb, NULL );
g_signal_connect_after( upc, "device-removed", device_cb, NULL );