[pkg-fso-commits] [SCM] Various useful tools for an FSO installation branch, master, updated. debian/0.git20080812.2-32-gb5a13bb

Michael 'Mickey' Lauer mickey at vanille-media.de
Sun Sep 27 16:11:40 UTC 2009


The following commit has been merged in the master branch:
commit eb39ce7fb81bfa64e1a9eb5f142ca3d1065be3fa
Author: Michael 'Mickey' Lauer <mickey at vanille-media.de>
Date:   Wed Dec 3 23:32:42 2008 +0100

    fso-apm: show battery status together with capacity

diff --git a/fso-apm/apm b/fso-apm/apm
index c39c344..36cbbeb 100755
--- a/fso-apm/apm
+++ b/fso-apm/apm
@@ -7,6 +7,8 @@ apm compatibility command
 GPLv2 or later
 """
 
+__version__ = "1.0.0"
+
 import sys, dbus
 
 #=========================================================================#
@@ -21,7 +23,8 @@ def showCapacity():
         obj = bus.get_object( "org.freesmartphone.odeviced", batteries[0] )
         battery = dbus.Interface( obj, "org.freesmartphone.Device.PowerSupply" )
         capacity = battery.GetCapacity()
-        print "%d%%" % capacity
+        status = battery.GetPowerStatus()
+        print "%d%% - %s" % ( capacity, status )
 
 #=========================================================================#
 def callSuspend():

-- 
Various useful tools for an FSO installation



More information about the pkg-fso-commits mailing list