Merge lp:~larsu/indicator-power/xfce-control-center into lp:indicator-power/14.04

Proposed by Lars Karlitski
Status: Merged
Approved by: Sebastien Bacher
Approved revision: 225
Merged at revision: 222
Proposed branch: lp:~larsu/indicator-power/xfce-control-center
Merge into: lp:indicator-power/14.04
Diff against target: 41 lines (+23/-8)
1 file modified
src/service.c (+23/-8)
To merge this branch: bzr merge lp:~larsu/indicator-power/xfce-control-center
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Sebastien Bacher Approve
Review via email: mp+202641@code.launchpad.net

Description of the change

Run xfce-powermanager-settings when in an Xubuntu session

To post a comment you must log in.
Revision history for this message
Sebastien Bacher (seb128) wrote :

Looks good to me!

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'src/service.c'
--- src/service.c 2014-01-10 02:02:31 +0000
+++ src/service.c 2014-01-22 10:56:02 +0000
@@ -692,14 +692,29 @@
692 GVariant * param G_GNUC_UNUSED,692 GVariant * param G_GNUC_UNUSED,
693 gpointer gself G_GNUC_UNUSED)693 gpointer gself G_GNUC_UNUSED)
694{694{
695 gchar *path;695 static const gchar *control_center_cmd = NULL;
696696
697 path = g_find_program_in_path ("unity-control-center");697 if (control_center_cmd == NULL)
698 if (path != NULL)698 {
699 execute_command ("unity-control-center power");699 if (!g_strcmp0 (g_getenv ("DESKTOP_SESSION"), "xubuntu"))
700 else700 {
701 execute_command ("gnome-control-center power");701 control_center_cmd = "xfce4-power-manager-settings";
702 g_free (path);702 }
703 else
704 {
705 gchar *path;
706
707 path = g_find_program_in_path ("unity-control-center");
708 if (path != NULL)
709 control_center_cmd = "unity-control-center power";
710 else
711 control_center_cmd = "gnome-control-center power";
712
713 g_free (path);
714 }
715 }
716
717 execute_command (control_center_cmd);
703}718}
704719
705static void720static void

Subscribers

People subscribed via source and target branches