[Xfce4-commits] <xfce4-power-manager:master> Better low power handling.

Ali Abdallah noreply at xfce.org
Wed Nov 11 10:16:04 CET 2009


Updating branch refs/heads/master
         to 7b2386df3ffd78935b83f5d776689e8aaf8aa4ec (commit)
       from 10b35c9d1f3c86ebd5179d6de90d4fdd690dc21c (commit)

commit 7b2386df3ffd78935b83f5d776689e8aaf8aa4ec
Author: Ali Abdallah <ali at ali-xfce.org>
Date:   Wed Nov 11 08:50:29 2009 +0100

    Better low power handling.

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

diff --git a/src/xfpm-supply.c b/src/xfpm-supply.c
index 5fbdc16..b71dc8d 100644
--- a/src/xfpm-supply.c
+++ b/src/xfpm-supply.c
@@ -303,14 +303,19 @@ xfpm_supply_on_low_power (XfpmSupply *supply)
 	    
 	device = xfpm_battery_get_device (battery);
 	g_object_get (G_OBJECT(device), "type", &type, "percentage", &percentage, NULL);
+	
 	if ( type != HAL_DEVICE_TYPE_PRIMARY )
 	    continue;
 	    
 	if ( percentage < low_power_level ) 
 	    low_power = TRUE;
 	else 
+	{
 	    low_power = FALSE;
+	    break;
+	}
     }
+    
     return low_power;
 }
 



More information about the Xfce4-commits mailing list