Author: jerome
Date: 2009-03-14 18:47:59 +0100 (Sat, 14 Mar 2009)
New Revision: 4081

Modified:
   
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/executables/tuxdroid-gadget-system.py
   
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/resources/gadget.pot
Log:
* Updated tts messages.
* Removed memory floating point in windblows.

Modified: 
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/executables/tuxdroid-gadget-system.py
===================================================================
--- 
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/executables/tuxdroid-gadget-system.py
        2009-03-14 17:35:54 UTC (rev 4080)
+++ 
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/executables/tuxdroid-gadget-system.py
        2009-03-14 17:47:59 UTC (rev 4081)
@@ -91,8 +91,7 @@
                     if (float(cpu) > float(self.tgp_cpuThreshold)):
                         print("message \"c p u meltdown\"")
                 else:   
-                    print("message \"Your c p u load is\"")
-                    print("message \"" + str(cpu) + "%\"")
+                    print("message \"Your c p u load is " + str(cpu) + " 
percent\"")
                  
         
         if self.tgp_giveMem:
@@ -107,8 +106,7 @@
                     if (float(memory) > float(self.tgp_memThreshold)):
                         print("message \"memory is up\"")
                 else:    
-                    print("message \"Your used memory is\"")
-                    print("message \"" + str(memory) + "%\"")
+                    print("message \"Your used memory is " + str(memory) + " 
percent\"")
             
             
 
@@ -213,7 +211,10 @@
         freeMem = result[ totalAvailable + len("Available Physical Memory:") : 
freeMem ]
         totalMem = string.replace(totalMem.strip(), ".", "")
         freeMem = string.replace(freeMem.strip(), ".", "")
-        return str(float( float(int(totalMem) - int(freeMem)) / 
float(totalMem) ) * 100)
+        value = str(float( float(int(totalMem) - int(freeMem)) / 
float(totalMem) ) * 100)
+        if value.find("."):
+            value = value[ : value.find(".")]
+        return value 
         
 
 tuxdroid_gadget_pcMonitor = pcMonitor()

Modified: 
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/resources/gadget.pot
===================================================================
--- 
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/resources/gadget.pot
 2009-03-14 17:35:54 UTC (rev 4080)
+++ 
software_suite_v2/software/gadgets/tuxdroid-gadget-system/trunk/tuxdroid-gadget-system/resources/gadget.pot
 2009-03-14 17:47:59 UTC (rev 4081)
@@ -13,10 +13,10 @@
 msgid "Give system informations."
 msgstr ""
 
-msgid "Your c p u load is"
+msgid "Your c p u load is {0} percent"
 msgstr ""
 
-msgid "Your used memory is"
+msgid "Your used memory is {0] percent"
 msgstr ""
 
 msgid "Make use of cpu threshold"


------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn

Reply via email to