aidl: light: Lower battery light priority

Prioritize notification and attention lights over battery.

Change-Id: I88fe39a90ea8fb12a48a1a2d2d36e5bf4dca5b94
This commit is contained in:
LuK1337 2024-06-22 13:04:13 +02:00 committed by Sebastiano Barezzi
parent 435cd2659d
commit 842e692081
No known key found for this signature in database
GPG key ID: 763BD3AE91A7A13F

View file

@ -96,10 +96,12 @@ void Lights::updateNotificationColor() {
bool isBatteryLit = rgb(mLastBatteryState.color).isLit();
bool isAttentionLit = rgb(mLastAttentionState.color).isLit();
bool isNotificationsLit = rgb(mLastNotificationsState.color).isLit();
const HwLightState state = isBatteryLit ? mLastBatteryState
: isAttentionLit ? mLastAttentionState
: mLastNotificationsState;
const HwLightState state = isNotificationsLit ? mLastNotificationsState
: isAttentionLit ? mLastAttentionState
: isBatteryLit ? mLastBatteryState
: HwLightState();
rgb color(state.color);