[PATCH] iPaq with kernel 2.6 × battery applet

Slavek Banko <[email protected]>
Newsgroups gmane.comp.handhelds.opie.devel
Organization axis, spol. s r. o.
Message-ID <[email protected]>
Hi.

Problem with displaying battery status is not specific for model H19xx, 
but for all models with kernel 2.6 (H22xx, H4700,...).

Attached patch removes error message after unsuccessfull attempt to 
open /proc/hal/battery. If error message is not displayed, battery status 
is properly openned.

Slavek

_______________________________________________

http://opie.handhelds.org/cgi-bin/moin.cgi/DeveloperWikiIndex

Opie-devel mailing list
[email protected]
https://handhelds.org/mailman/listinfo/opie-devel
iPaq-2.6-batteryapplet.patch (text/x-diff, 513 B)
diff -aruN batteryapplet.orig/batterystatus.cpp batteryapplet/batterystatus.cpp
--- batteryapplet.orig/batterystatus.cpp	2005-06-14 20:14:38.000000000 +0200
+++ batteryapplet/batterystatus.cpp	2006-05-28 23:56:44.000000000 +0200
@@ -81,11 +81,9 @@
                 }
             }
         }
-    } else {
-        QMessageBox::warning(this, tr("Failure"),tr("could not open file"));
+	procApmIpaq.close();
     }
 
-    procApmIpaq.close();
     jackPercent = perc2.toInt();
     ipaqPercent = perc1.toInt();
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.