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

Skip to content
Commit 51534594 authored by Pawit Pornkitprasan's avatar Pawit Pornkitprasan Committed by Gerrit Code Review
Browse files

Fix automatic brightness

Broken in Iddcbee98f6588bba428c4059e786d946d7ce2298

- Brightness is now handled in handleLightSensorValue instead of
  onSensorChanged, but the previous patch copied the old handling
  code into onSensorChanged in addition to calling handleLightSensorValue.
  This patch integrates the brightness filter change from
  onSensorChanged into handleLightSensorValue.
- onSensorChanged called mHandler.removeCallbacks(mAutoBrightnessTask)
  every time a value is received from the sensor ensuring that the
  task never get ran! (We schedule it 2 seconds into the future
  but receives a value from the sensor every second.)
  This patch removes the call.

(Note: similar to http://review.cyanogenmod.com/11341)

Change-Id: Id3e4f0f02f91f27c7c12cb2e274e0c13213d4774
parent 9a8117c4
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