Skip to content
Commit 95d05138 authored by Robin Lee's avatar Robin Lee
Browse files

Make LogicalLight @Nullable: part two (internal)

Primarily refactors populateAvailableLights()

* breaks AIDL and HIDL logic into two small helpers
* stops going and inventing fake lights if we have the AIDL HAL.

Also reworks some LightsService internals

* move "system light" definition into the light class
* rename mLights -> mLightsByType (matching mLightsById)
* put the traceEnd() for "setLightState" in one final block

The way the HIDL HAL goes and invents fake lights hasn't been changed,
to avoid breaking HALs that didn't implement getLights() before.

Bug: 151113302
Test: atest LightsManagerTest
Test: atest LightsServiceTest
Test: atest google/perf/boottime/boottime-test
Change-Id: I23545586a2fa44ec656cd4c58df61970ce6db979
parent b9e44e50
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment