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

Commit 868e770b authored by Jamie Garside's avatar Jamie Garside
Browse files

Update the bouncer to be able to move to either side of a wide screen.

I'd like to test other things (like tap makes the IME move), but to do
that means replacing the mock with a proper fake. That can come later,
but this at least tests that the flagging works correctly.

The changes between this and
commit cae34b8e is the bouncer height is
now measured using wrap_content, so the placement can be controlled
properly by the outer View (as the position of the bouncer changes
depending on the size of the screen).

This reverts commit cae34b8e.

Test: Included
Bug: 170858298
Change-Id: I18428a6df9abf0e8e37c1c179be6843e4eee793c
parent 0622a76d
Loading
Loading
Loading
Loading
+23 −0
Original line number Diff line number Diff line
@@ -14614,6 +14614,29 @@ public final class Settings {
        public static final String POWER_BUTTON_VERY_LONG_PRESS =
                "power_button_very_long_press";
        /**
         * Keyguard should be on the left hand side of the screen, for wide screen layouts.
         *
         * @hide
         */
        public static final int ONE_HANDED_KEYGUARD_SIDE_LEFT = 0;
        /**
         * Keyguard should be on the right hand side of the screen, for wide screen layouts.
         *
         * @hide
         */
        public static final int ONE_HANDED_KEYGUARD_SIDE_RIGHT = 1;
        /**
         * In one handed mode, which side the keyguard should be on. Allowable values are one of
         * the ONE_HANDED_KEYGUARD_SIDE_* constants.
         *
         * @hide
         */
        @Readable
        public static final String ONE_HANDED_KEYGUARD_SIDE = "one_handed_keyguard_side";
        /**
         * Keys we no longer back up under the current schema, but want to continue to
         * process when restoring historical backup datasets.
+2 −0
Original line number Diff line number Diff line
@@ -4203,4 +4203,6 @@
  <java-symbol type="bool" name="config_telephony5gNonStandalone" />

  <java-symbol type="bool" name="config_voice_data_sms_auto_fallback" />

  <java-symbol type="bool" name="config_enableOneHandedKeyguard" />
</resources>
+5 −0
Original line number Diff line number Diff line
@@ -147,5 +147,10 @@ public class GlobalSettingsValidators {
        VALIDATORS.put(Global.DEVELOPMENT_SETTINGS_ENABLED, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Global.NOTIFICATION_FEEDBACK_ENABLED, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Global.RESTRICTED_NETWORKING_MODE, BOOLEAN_VALIDATOR);
        VALIDATORS.put(
                Global.ONE_HANDED_KEYGUARD_SIDE,
                new InclusiveIntegerRangeValidator(
                        /* first= */Global.ONE_HANDED_KEYGUARD_SIDE_LEFT,
                        /* last= */Global.ONE_HANDED_KEYGUARD_SIDE_RIGHT));
    }
}
+1 −0
Original line number Diff line number Diff line
@@ -283,6 +283,7 @@ public class SettingsBackupTest {
                    Settings.Global.EUICC_REMOVING_INVISIBLE_PROFILES_TIMEOUT_MILLIS,
                    Settings.Global.EUICC_SWITCH_SLOT_TIMEOUT_MILLIS,
                    Settings.Global.FANCY_IME_ANIMATIONS,
                    Settings.Global.ONE_HANDED_KEYGUARD_SIDE,
                    Settings.Global.FORCE_ALLOW_ON_EXTERNAL,
                    Settings.Global.FORCED_APP_STANDBY_ENABLED,
                    Settings.Global.FORCED_APP_STANDBY_FOR_SMALL_BATTERY_ENABLED,
+1 −1
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@
    <include
        style="@style/BouncerSecurityContainer"
        layout="@layout/keyguard_host_view"
        android:layout_width="wrap_content"
        android:layout_width="match_parent"
        android:layout_height="wrap_content" />
</FrameLayout>
Loading