am a13b4da6: Merge "Fix initial brightness state after startup." into jb-dev
* commit 'a13b4da68d8df0977c8dec5001de7c9ecea71d9e': Fix initial brightness state after startup.
This commit is contained in:
@@ -2242,7 +2242,9 @@ public class PowerManagerService extends IPowerManager.Stub
|
|||||||
} else {
|
} else {
|
||||||
newValue = endValue;
|
newValue = endValue;
|
||||||
mHighestLightSensorValue = endSensorValue;
|
mHighestLightSensorValue = endSensorValue;
|
||||||
mInitialAnimation = false;
|
if (endValue > 0) {
|
||||||
|
mInitialAnimation = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mDebugLightAnimation) {
|
if (mDebugLightAnimation) {
|
||||||
@@ -2290,7 +2292,7 @@ public class PowerManagerService extends IPowerManager.Stub
|
|||||||
currentMask = mask;
|
currentMask = mask;
|
||||||
duration = (int) (mWindowScaleAnimation * animationDuration);
|
duration = (int) (mWindowScaleAnimation * animationDuration);
|
||||||
startTimeMillis = SystemClock.elapsedRealtime();
|
startTimeMillis = SystemClock.elapsedRealtime();
|
||||||
mInitialAnimation = currentValue == 0 && target > 0;
|
mInitialAnimation = mInitialAnimation && target > 0;
|
||||||
|
|
||||||
if (mDebugLightAnimation) {
|
if (mDebugLightAnimation) {
|
||||||
Slog.v(TAG, "animateTo(target=" + target
|
Slog.v(TAG, "animateTo(target=" + target
|
||||||
@@ -2608,7 +2610,8 @@ public class PowerManagerService extends IPowerManager.Stub
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
private boolean mInitialAnimation; // used to prevent lightsensor changes while turning on
|
/** used to prevent lightsensor changes while turning on. */
|
||||||
|
private boolean mInitialAnimation = true;
|
||||||
|
|
||||||
private void dockStateChanged(int state) {
|
private void dockStateChanged(int state) {
|
||||||
synchronized (mLocks) {
|
synchronized (mLocks) {
|
||||||
|
|||||||
Reference in New Issue
Block a user