[Xfce4-commits] <xfce4-power-manager:master> Fix default spin down toogle value.

Ali Abdallah noreply at xfce.org
Thu May 5 12:18:01 CEST 2011


Updating branch refs/heads/master
         to f7a48533e198f3bb8d1ff5cffc1d2ec3bfdca6e6 (commit)
       from 8ef0d25692d1cc307a65634bc86458ac2a787fe5 (commit)

commit f7a48533e198f3bb8d1ff5cffc1d2ec3bfdca6e6
Author: Ali Abdallah <aliov at xfce.org>
Date:   Thu May 5 11:17:46 2011 +0200

    Fix default spin down toogle value.

 settings/xfpm-settings.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/settings/xfpm-settings.c b/settings/xfpm-settings.c
index 0d83734..67cc5a1 100644
--- a/settings/xfpm-settings.c
+++ b/settings/xfpm-settings.c
@@ -944,6 +944,8 @@ xfpm_settings_on_battery (XfconfChannel *channel, gboolean auth_hibernate,
 #endif
 
     spin_down = GTK_WIDGET (gtk_builder_get_object (xml, "spin-down-on-battery"));
+    gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (spin_down), 
+				  xfconf_channel_get_bool (channel, PROPERTIES_PREFIX SPIN_DOWN_ON_BATTERY, TRUE));
     gtk_widget_set_sensitive (spin_down, can_spin_down);
     
     if ( !devkit_disk )
@@ -1091,6 +1093,9 @@ xfpm_settings_on_ac (XfconfChannel *channel, gboolean auth_suspend,
 #endif
 
     spin_down = GTK_WIDGET (gtk_builder_get_object (xml, "spin-down-on-ac"));
+    gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (spin_down), 
+				  xfconf_channel_get_bool (channel, PROPERTIES_PREFIX SPIN_DOWN_ON_AC, FALSE));
+				  
     gtk_widget_set_sensitive (spin_down, can_spin_down);
     
     if ( !devkit_disk )



More information about the Xfce4-commits mailing list