Show charging speed on Keyguard
Bug: 8099739 Change-Id: I2e5c21dd7ec028ce47fb03ab71e74f7fccaa9e36
This commit is contained in:
parent
3f8fbfdb9b
commit
687aa22c92
@ -57,6 +57,7 @@ struct BatteryProperties {
|
|||||||
bool chargerAcOnline;
|
bool chargerAcOnline;
|
||||||
bool chargerUsbOnline;
|
bool chargerUsbOnline;
|
||||||
bool chargerWirelessOnline;
|
bool chargerWirelessOnline;
|
||||||
|
int maxChargingCurrent;
|
||||||
int batteryStatus;
|
int batteryStatus;
|
||||||
int batteryHealth;
|
int batteryHealth;
|
||||||
bool batteryPresent;
|
bool batteryPresent;
|
||||||
|
@ -33,6 +33,7 @@ status_t BatteryProperties::readFromParcel(Parcel* p) {
|
|||||||
chargerAcOnline = p->readInt32() == 1 ? true : false;
|
chargerAcOnline = p->readInt32() == 1 ? true : false;
|
||||||
chargerUsbOnline = p->readInt32() == 1 ? true : false;
|
chargerUsbOnline = p->readInt32() == 1 ? true : false;
|
||||||
chargerWirelessOnline = p->readInt32() == 1 ? true : false;
|
chargerWirelessOnline = p->readInt32() == 1 ? true : false;
|
||||||
|
maxChargingCurrent = p->readInt32();
|
||||||
batteryStatus = p->readInt32();
|
batteryStatus = p->readInt32();
|
||||||
batteryHealth = p->readInt32();
|
batteryHealth = p->readInt32();
|
||||||
batteryPresent = p->readInt32() == 1 ? true : false;
|
batteryPresent = p->readInt32() == 1 ? true : false;
|
||||||
@ -47,6 +48,7 @@ status_t BatteryProperties::writeToParcel(Parcel* p) const {
|
|||||||
p->writeInt32(chargerAcOnline ? 1 : 0);
|
p->writeInt32(chargerAcOnline ? 1 : 0);
|
||||||
p->writeInt32(chargerUsbOnline ? 1 : 0);
|
p->writeInt32(chargerUsbOnline ? 1 : 0);
|
||||||
p->writeInt32(chargerWirelessOnline ? 1 : 0);
|
p->writeInt32(chargerWirelessOnline ? 1 : 0);
|
||||||
|
p->writeInt32(maxChargingCurrent);
|
||||||
p->writeInt32(batteryStatus);
|
p->writeInt32(batteryStatus);
|
||||||
p->writeInt32(batteryHealth);
|
p->writeInt32(batteryHealth);
|
||||||
p->writeInt32(batteryPresent ? 1 : 0);
|
p->writeInt32(batteryPresent ? 1 : 0);
|
||||||
|
Loading…
Reference in New Issue
Block a user