Merge "Use HwLight.type as the key of mLightsByType" am: ee4446c09e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2198763 Change-Id: Id2ee0d209485830c792f8fbb6fc92c635dadde45 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -465,9 +465,10 @@ public class LightsService extends SystemService {
|
||||
}
|
||||
|
||||
for (int i = mLightsById.size() - 1; i >= 0; i--) {
|
||||
final int type = mLightsById.keyAt(i);
|
||||
LightImpl light = mLightsById.valueAt(i);
|
||||
final int type = light.mHwLight.type;
|
||||
if (0 <= type && type < mLightsByType.length) {
|
||||
mLightsByType[type] = mLightsById.valueAt(i);
|
||||
mLightsByType[type] = light;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user