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

Commit c1ac2a11 authored by Ben Murdoch's avatar Ben Murdoch Committed by Android (Google) Code Review
Browse files

Merge "Align one handed bouncer to the right edge of the screen." into sc-v2-dev

parents 9bd2221e b5b1e54f
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -317,7 +317,8 @@ public class KeyguardSecurityContainer extends FrameLayout {
            mRunningOneHandedAnimator = null;
        }

        int targetTranslation = mIsSecurityViewLeftAligned ? 0 : (int) (getMeasuredWidth() / 2f);
        int targetTranslation = mIsSecurityViewLeftAligned
                ? 0 : (int) (getMeasuredWidth() - mSecurityViewFlipper.getWidth());

        if (animate) {
            mRunningOneHandedAnimator =
+2 −1
Original line number Diff line number Diff line
@@ -165,7 +165,8 @@ public class KeyguardSecurityContainerTest extends SysuiTestCase {

        mKeyguardSecurityContainer.setOneHandedModeLeftAligned(
                /* leftAligned= */false, /* animate= */false);
        verify(mSecurityViewFlipper).setTranslationX(SCREEN_WIDTH / 2.0f);
        verify(mSecurityViewFlipper).setTranslationX(
                mKeyguardSecurityContainer.getWidth() - mSecurityViewFlipper.getWidth());

        mKeyguardSecurityContainer.setOneHandedModeLeftAligned(
                /* leftAligned= */true, /* animate= */false);