summaryrefslogtreecommitdiffstats
path: root/include/batteryservice
diff options
context:
space:
mode:
authorTodd Poynor <toddpoynor@google.com>2014-05-08 16:04:22 -0700
committerTodd Poynor <toddpoynor@google.com>2014-05-16 03:05:11 +0000
commita186e65368719a2f47b357be50d4ccf61501fe9b (patch)
tree61a99e0690fc09d0b457721553d3bfb487f18b8e /include/batteryservice
parent37a5e7a21a018211b4502f80187a1dd23d71fd9f (diff)
downloadframeworks_native-a186e65368719a2f47b357be50d4ccf61501fe9b.zip
frameworks_native-a186e65368719a2f47b357be50d4ccf61501fe9b.tar.gz
frameworks_native-a186e65368719a2f47b357be50d4ccf61501fe9b.tar.bz2
BatteryProperty: Add property ENERGY_COUNTER and 64-bit integer properties
Also fixup comments to match recent changes in BatteryManager. Change-Id: I6f40924f9e66d564ad1175f9650e2bfd2ad39a3a
Diffstat (limited to 'include/batteryservice')
-rw-r--r--include/batteryservice/BatteryService.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/include/batteryservice/BatteryService.h b/include/batteryservice/BatteryService.h
index 2902d17..6211cf4 100644
--- a/include/batteryservice/BatteryService.h
+++ b/include/batteryservice/BatteryService.h
@@ -18,6 +18,7 @@
#define ANDROID_BATTERYSERVICE_H
#include <binder/Parcel.h>
+#include <sys/types.h>
#include <utils/Errors.h>
#include <utils/String8.h>
@@ -45,10 +46,11 @@ enum {
// must be kept in sync with definitions in BatteryProperty.java
enum {
- BATTERY_PROP_CHARGE_COUNTER = 1, // equals BatteryProperty.BATTERY_PROP_CHARGE_COUNTER constant
- BATTERY_PROP_CURRENT_NOW = 2, // equals BatteryProperty.BATTERY_PROP_CURRENT_NOW constant
- BATTERY_PROP_CURRENT_AVG = 3, // equals BatteryProperty.BATTERY_PROP_CURRENT_AVG constant
- BATTERY_PROP_CAPACITY = 4, // equals BatteryProperty.BATTERY_PROP_CAPACITY constant
+ BATTERY_PROP_CHARGE_COUNTER = 1, // equals BatteryProperty.CHARGE_COUNTER constant
+ BATTERY_PROP_CURRENT_NOW = 2, // equals BatteryProperty.CURRENT_NOW constant
+ BATTERY_PROP_CURRENT_AVG = 3, // equals BatteryProperty.CURRENT_AVG constant
+ BATTERY_PROP_CAPACITY = 4, // equals BatteryProperty.CAPACITY constant
+ BATTERY_PROP_ENERGY_COUNTER = 5, // equals BatteryProperty.ENERGY_COUNTER constant
};
struct BatteryProperties {
@@ -68,7 +70,7 @@ struct BatteryProperties {
};
struct BatteryProperty {
- int valueInt;
+ int64_t valueInt64;
status_t writeToParcel(Parcel* parcel) const;
status_t readFromParcel(Parcel* parcel);