diff options
author | Adrian Roos <roosa@google.com> | 2014-05-14 20:01:43 +0200 |
---|---|---|
committer | Adrian Roos <roosa@google.com> | 2014-05-14 18:05:54 +0000 |
commit | 6e2d465b9c8fdf66957264a07c16729ff22fda22 (patch) | |
tree | be5d15eb9ea5c9ae41fd6ef44a2d4753a3c13136 /packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java | |
parent | 8ac546eaa36e6f7c6a89bdbb38f3886bdf5b4fb7 (diff) | |
download | frameworks_base-6e2d465b9c8fdf66957264a07c16729ff22fda22.zip frameworks_base-6e2d465b9c8fdf66957264a07c16729ff22fda22.tar.gz frameworks_base-6e2d465b9c8fdf66957264a07c16729ff22fda22.tar.bz2 |
Follow up for "A better auto brightness"
Original CL: I62d0695b7da16ffa7a27c465c3b6bc4b1515f9c0
Change-Id: I79c307586c0ba9be275d3920a3805f45b6006ce8
Diffstat (limited to 'packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java')
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java b/packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java index c0a07e9..a770f58 100644 --- a/packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java +++ b/packages/SystemUI/src/com/android/systemui/settings/BrightnessController.java @@ -193,7 +193,7 @@ public class BrightnessController implements ToggleSlider.Listener { } } else { final float adj = value / (BRIGHTNESS_ADJ_RESOLUTION / 2f) - 1; - setBrignessAdj(adj); + setBrightnessAdj(adj); if (!tracking) { AsyncTask.execute(new Runnable() { public void run() { @@ -223,7 +223,7 @@ public class BrightnessController implements ToggleSlider.Listener { } } - private void setBrignessAdj(float adj) { + private void setBrightnessAdj(float adj) { try { mPower.setTemporaryScreenAutoBrightnessAdjustmentSettingOverride(adj); } catch (RemoteException ex) { @@ -246,7 +246,7 @@ public class BrightnessController implements ToggleSlider.Listener { Settings.System.SCREEN_BRIGHTNESS_MODE, Settings.System.SCREEN_BRIGHTNESS_MODE_MANUAL, UserHandle.USER_CURRENT); - mAutomatic = automatic != 0; + mAutomatic = automatic != Settings.System.SCREEN_BRIGHTNESS_MODE_MANUAL; updateIcon(mAutomatic); } else { mControl.setChecked(false); |