Merge "Change dream IN animation duration to 250ms." into tm-qpr-dev am: d5b85d4ef2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20246465 Change-Id: Id0210c82ea39a4feff23695d3b5357a0c7520c36 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -19,5 +19,5 @@
|
|||||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:fromAlpha="1.0"
|
android:fromAlpha="1.0"
|
||||||
android:toAlpha="0.0"
|
android:toAlpha="0.0"
|
||||||
android:duration="100" />
|
android:duration="@integer/config_dreamCloseAnimationDuration" />
|
||||||
|
|
||||||
|
|||||||
@@ -22,5 +22,5 @@ those two has to be the same. -->
|
|||||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:fromAlpha="0.0"
|
android:fromAlpha="0.0"
|
||||||
android:toAlpha="1.0"
|
android:toAlpha="1.0"
|
||||||
android:duration="1000" />
|
android:duration="@integer/config_dreamOpenAnimationDuration" />
|
||||||
|
|
||||||
|
|||||||
@@ -22,4 +22,4 @@ dream_activity_open_enter animation. -->
|
|||||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:fromAlpha="1.0"
|
android:fromAlpha="1.0"
|
||||||
android:toAlpha="1.0"
|
android:toAlpha="1.0"
|
||||||
android:duration="1000" />
|
android:duration="@integer/config_dreamOpenAnimationDuration" />
|
||||||
|
|||||||
@@ -2439,6 +2439,11 @@
|
|||||||
<!-- Whether dreams are disabled when ambient mode is suppressed. -->
|
<!-- Whether dreams are disabled when ambient mode is suppressed. -->
|
||||||
<bool name="config_dreamsDisabledByAmbientModeSuppressionConfig">false</bool>
|
<bool name="config_dreamsDisabledByAmbientModeSuppressionConfig">false</bool>
|
||||||
|
|
||||||
|
<!-- The duration in milliseconds of the dream opening animation. -->
|
||||||
|
<integer name="config_dreamOpenAnimationDuration">250</integer>
|
||||||
|
<!-- The duration in milliseconds of the dream closing animation. -->
|
||||||
|
<integer name="config_dreamCloseAnimationDuration">100</integer>
|
||||||
|
|
||||||
<!-- Whether to dismiss the active dream when an activity is started. Doesn't apply to
|
<!-- Whether to dismiss the active dream when an activity is started. Doesn't apply to
|
||||||
assistant activities (ACTIVITY_TYPE_ASSISTANT) -->
|
assistant activities (ACTIVITY_TYPE_ASSISTANT) -->
|
||||||
<bool name="config_dismissDreamOnActivityStart">false</bool>
|
<bool name="config_dismissDreamOnActivityStart">false</bool>
|
||||||
|
|||||||
@@ -2226,6 +2226,8 @@
|
|||||||
<java-symbol type="string" name="config_dreamsDefaultComponent" />
|
<java-symbol type="string" name="config_dreamsDefaultComponent" />
|
||||||
<java-symbol type="bool" name="config_dreamsDisabledByAmbientModeSuppressionConfig" />
|
<java-symbol type="bool" name="config_dreamsDisabledByAmbientModeSuppressionConfig" />
|
||||||
<java-symbol type="bool" name="config_dreamsOnlyEnabledForSystemUser" />
|
<java-symbol type="bool" name="config_dreamsOnlyEnabledForSystemUser" />
|
||||||
|
<java-symbol type="integer" name="config_dreamOpenAnimationDuration" />
|
||||||
|
<java-symbol type="integer" name="config_dreamCloseAnimationDuration" />
|
||||||
<java-symbol type="array" name="config_supportedDreamComplications" />
|
<java-symbol type="array" name="config_supportedDreamComplications" />
|
||||||
<java-symbol type="array" name="config_disabledDreamComponents" />
|
<java-symbol type="array" name="config_disabledDreamComponents" />
|
||||||
<java-symbol type="bool" name="config_dismissDreamOnActivityStart" />
|
<java-symbol type="bool" name="config_dismissDreamOnActivityStart" />
|
||||||
|
|||||||
@@ -400,6 +400,11 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
|||||||
private final float mPowerButtonY;
|
private final float mPowerButtonY;
|
||||||
private final float mWindowCornerRadius;
|
private final float mWindowCornerRadius;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The duration in milliseconds of the dream open animation.
|
||||||
|
*/
|
||||||
|
private final int mDreamOpenAnimationDuration;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The animation used for hiding keyguard. This is used to fetch the animation timings if
|
* The animation used for hiding keyguard. This is used to fetch the animation timings if
|
||||||
* WindowManager is not providing us with them.
|
* WindowManager is not providing us with them.
|
||||||
@@ -946,8 +951,7 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
|||||||
}
|
}
|
||||||
|
|
||||||
mOccludeByDreamAnimator = ValueAnimator.ofFloat(0f, 1f);
|
mOccludeByDreamAnimator = ValueAnimator.ofFloat(0f, 1f);
|
||||||
// Use the same duration as for the UNOCCLUDE.
|
mOccludeByDreamAnimator.setDuration(mDreamOpenAnimationDuration);
|
||||||
mOccludeByDreamAnimator.setDuration(UNOCCLUDE_ANIMATION_DURATION);
|
|
||||||
mOccludeByDreamAnimator.setInterpolator(Interpolators.LINEAR);
|
mOccludeByDreamAnimator.setInterpolator(Interpolators.LINEAR);
|
||||||
mOccludeByDreamAnimator.addUpdateListener(
|
mOccludeByDreamAnimator.addUpdateListener(
|
||||||
animation -> {
|
animation -> {
|
||||||
@@ -1179,6 +1183,9 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
|||||||
mPowerButtonY = context.getResources().getDimensionPixelSize(
|
mPowerButtonY = context.getResources().getDimensionPixelSize(
|
||||||
R.dimen.physical_power_button_center_screen_location_y);
|
R.dimen.physical_power_button_center_screen_location_y);
|
||||||
mWindowCornerRadius = ScreenDecorationsUtils.getWindowCornerRadius(context);
|
mWindowCornerRadius = ScreenDecorationsUtils.getWindowCornerRadius(context);
|
||||||
|
|
||||||
|
mDreamOpenAnimationDuration = context.getResources().getInteger(
|
||||||
|
com.android.internal.R.integer.config_dreamOpenAnimationDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void userActivity() {
|
public void userActivity() {
|
||||||
|
|||||||
Reference in New Issue
Block a user