diff options
author | Francois Andriot <francois.andriot@free.fr> | 2013-08-01 18:06:52 +0200 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2013-08-01 18:07:34 +0200 |
commit | fb86c5c8459927513b39b622e323c15abbd551ae (patch) | |
tree | 8600c6f2ded48d818fde3c750b264f6b09074d9b | |
parent | 12b5e141be261b5ff652e8ec5153d50888859d1a (diff) | |
download | tdelibs-fb86c5c8459927513b39b622e323c15abbd551ae.tar.gz tdelibs-fb86c5c8459927513b39b622e323c15abbd551ae.zip |
Fix battery charge detection
This resolves Bug 1514
-rw-r--r-- | tdecore/tdehardwaredevices.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tdecore/tdehardwaredevices.cpp b/tdecore/tdehardwaredevices.cpp index f66d7f678..f75df6e87 100644 --- a/tdecore/tdehardwaredevices.cpp +++ b/tdecore/tdehardwaredevices.cpp @@ -4716,6 +4716,15 @@ void TDEHardwareDevices::updateExistingDeviceInformation(TDEGenericDevice* exist if (nodename == "alarm") { bdevice->internalSetAlarmEnergy(line.toDouble()/1000000.0); } + if (nodename == "charge_full") { + bdevice->internalSetMaximumEnergy(line.toDouble()/1000000.0); + } + if (nodename == "charge_full_design") { + bdevice->internalSetMaximumDesignEnergy(line.toDouble()/1000000.0); + } + if (nodename == "charge_now") { + bdevice->internalSetEnergy(line.toDouble()/1000000.0); + } if (nodename == "energy_full") { bdevice->internalSetMaximumEnergy(line.toDouble()/1000000.0); } |