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

Commit 45023727 authored by Fabian Kozynski's avatar Fabian Kozynski Committed by Automerger Merge Worker
Browse files

Merge "Reduce the size of buttons in Global Actions Lite" into udc-dev am: 629884d3

parents 5212496f 629884d3
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -76,4 +76,10 @@
    <!-- Bouncer user switcher margins -->
    <dimen name="bouncer_user_switcher_view_mode_user_switcher_bottom_margin">0dp</dimen>
    <dimen name="bouncer_user_switcher_view_mode_view_flipper_bottom_margin">0dp</dimen>

    <!-- Power Menu Lite -->
    <!-- These values are for small screen landscape. For larger landscape screens, they are
         overlaid -->
    <dimen name="global_actions_button_size">72dp</dimen>
    <dimen name="global_actions_button_padding">26dp</dimen>
</resources>
+4 −0
Original line number Diff line number Diff line
@@ -18,4 +18,8 @@
    <!-- Lock pattern view size, align sysui biometric_auth_pattern_view_size -->
    <dimen name="biometric_auth_pattern_view_size">248dp</dimen>
    <dimen name="biometric_auth_pattern_view_max_size">348dp</dimen>

    <!-- Power Menu Lite -->
    <dimen name="global_actions_button_size">96dp</dimen>
    <dimen name="global_actions_button_padding">38dp</dimen>
</resources>
 No newline at end of file
+5 −1
Original line number Diff line number Diff line
@@ -249,6 +249,7 @@ public class GlobalActionsDialogLite implements DialogInterface.OnDismissListene
    private int mDialogPressDelay = DIALOG_PRESS_DELAY; // ms
    protected Handler mMainHandler;
    private int mSmallestScreenWidthDp;
    private int mOrientation;
    private final Optional<CentralSurfaces> mCentralSurfacesOptional;
    private final KeyguardUpdateMonitor mKeyguardUpdateMonitor;
    private final DialogLaunchAnimator mDialogLaunchAnimator;
@@ -391,6 +392,7 @@ public class GlobalActionsDialogLite implements DialogInterface.OnDismissListene
        mRingerModeTracker = ringerModeTracker;
        mMainHandler = handler;
        mSmallestScreenWidthDp = resources.getConfiguration().smallestScreenWidthDp;
        mOrientation = resources.getConfiguration().orientation;
        mCentralSurfacesOptional = centralSurfacesOptional;
        mKeyguardUpdateMonitor = keyguardUpdateMonitor;
        mDialogLaunchAnimator = dialogLaunchAnimator;
@@ -744,8 +746,10 @@ public class GlobalActionsDialogLite implements DialogInterface.OnDismissListene
    @Override
    public void onConfigChanged(Configuration newConfig) {
        if (mDialog != null && mDialog.isShowing()
                && (newConfig.smallestScreenWidthDp != mSmallestScreenWidthDp)) {
                && (newConfig.smallestScreenWidthDp != mSmallestScreenWidthDp
                || newConfig.orientation != mOrientation)) {
            mSmallestScreenWidthDp = newConfig.smallestScreenWidthDp;
            mOrientation = newConfig.orientation;
            mDialog.refreshDialog();
        }
    }