aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/service.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/service.c b/src/service.c
index a1f6793..c86df15 100644
--- a/src/service.c
+++ b/src/service.c
@@ -805,14 +805,14 @@ on_statistics_activated (GSimpleAction * a G_GNUC_UNUSED,
GVariant * param,
gpointer gself G_GNUC_UNUSED)
{
- if (!g_strcmp0 (g_getenv ("DESKTOP_SESSION"), "mate"))
+ if (is_mate())
{
- char *cmd = g_strconcat ("gnome-power-statistics", " --device ",
+ char *cmd = g_strconcat ("mate-power-statistics", " --device ",
g_variant_get_string (param, NULL), NULL);
execute_command (cmd);
g_free (cmd);
}
- else
+ else if (is_gnome() || is_unity())
{
char *cmd = g_strconcat ("gnome-power-statistics", " --device ",
g_variant_get_string (param, NULL), NULL);