summaryrefslogtreecommitdiff
path: root/src/gpm-control.c
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2014-04-22 18:00:55 +0200
committerStefano Karapetsas <[email protected]>2014-04-22 18:00:55 +0200
commitd96bb779e9d88d83ba2bf54e8610bf966dcdf1c9 (patch)
treebb895796d71a346eff190714b865928d82980422 /src/gpm-control.c
parent8cb168b752f4130e88daefa400bb9bf07cf18227 (diff)
parentd59f4b8bd38e1628af3a992ae8e96b8e069ab738 (diff)
downloadmate-power-manager-d96bb779e9d88d83ba2bf54e8610bf966dcdf1c9.tar.bz2
mate-power-manager-d96bb779e9d88d83ba2bf54e8610bf966dcdf1c9.tar.xz
Merge pull request #98 from seife/master
make m-p-m work with current upower-0.99
Diffstat (limited to 'src/gpm-control.c')
-rw-r--r--src/gpm-control.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gpm-control.c b/src/gpm-control.c
index ec50136..0562d38 100644
--- a/src/gpm-control.c
+++ b/src/gpm-control.c
@@ -289,10 +289,11 @@ gpm_control_suspend (GpmControl *control, GError **error)
}
g_object_unref(proxy);
}
+#if !UP_CHECK_VERSION(0, 99, 0)
else {
ret = up_client_suspend_sync (control->priv->client, NULL, error);
}
-
+#endif
egg_debug ("emitting resume");
g_signal_emit (control, signals [RESUME], 0, GPM_CONTROL_ACTION_SUSPEND);
@@ -399,10 +400,11 @@ gpm_control_hibernate (GpmControl *control, GError **error)
ret = TRUE;
}
}
+#if !UP_CHECK_VERSION(0, 99, 0)
else {
ret = up_client_hibernate_sync (control->priv->client, NULL, error);
}
-
+#endif
egg_debug ("emitting resume");
g_signal_emit (control, signals [RESUME], 0, GPM_CONTROL_ACTION_HIBERNATE);