summaryrefslogtreecommitdiffstats
path: root/src/hardware_batteryCollection.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/hardware_batteryCollection.cpp')
-rw-r--r--src/hardware_batteryCollection.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/hardware_batteryCollection.cpp b/src/hardware_batteryCollection.cpp
index 523ca6f..0d4f4dd 100644
--- a/src/hardware_batteryCollection.cpp
+++ b/src/hardware_batteryCollection.cpp
@@ -24,6 +24,10 @@
* \date 2006-2007
*/
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
// own headers
#include "hardware_batteryCollection.h"
@@ -50,7 +54,7 @@ void BatteryCollection::initDefault() {
udis.clear();
- present_rate_unit = "mWh";
+ present_rate_unit = "W";
charging_state = UNKNOWN_STATE;
state = BAT_NORM;
@@ -79,7 +83,7 @@ bool BatteryCollection::refreshInfo(TQPtrList<Battery> BatteryList, bool force_l
int _percent = 0;
int _minutes = 0;
int _present_batteries = 0;
- int _present_rate = 0;
+ double _present_rate = 0;
// for now: clean list before run update process!
udis.clear();
@@ -214,7 +218,7 @@ TQString BatteryCollection::getChargeLevelUnit() const {
}
//! get the current reported battery rate
-int BatteryCollection::getCurrentRate() const {
+double BatteryCollection::getCurrentRate() const {
return present_rate;
}