Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e952e58a authored by Pierre-Hugues Husson's avatar Pierre-Hugues Husson Committed by Łukasz Patron
Browse files

Fix other lights when backlight uses SurfaceController API

Only backlight should go to SurfaceControler, other lights are still using good old Lights API.

Change-Id: I0c55bae02ec3a9d762b90b4ecf31dc63d29530b5
parent 5ceea4f3
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -76,6 +76,7 @@ public class LightsService extends SystemService {
                // right now we just fall back to the old path through Lights brightessMode is
                // anything but USER or the device shouldBeInLowPersistenceMode().
                if (brightnessMode == BRIGHTNESS_MODE_USER && !shouldBeInLowPersistenceMode()
                        && mId == LightsManager.LIGHT_ID_BACKLIGHT
                        && mSurfaceControlMaximumBrightness == 255) {
                    // TODO: the last check should be mSurfaceControlMaximumBrightness != 0; the
                    // reason we enforce 255 right now is to stay consistent with the old path. In