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

Commit 2669e587 authored by Fabian Kozynski's avatar Fabian Kozynski
Browse files

Increase margin of Brightness dialog

The margins for the dialog where 8dp and were interfering with back
gesture. Instead, make it 16dp so it aligns with other elements and it's
clear of the edges.

Bug: 247049806
Test: manual
Change-Id: I4990da7e3eca469a9727efcfeb790608435ab9af
parent e0f07da1
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -25,6 +25,7 @@ import android.os.Handler;
import android.view.Gravity;
import android.view.KeyEvent;
import android.view.View;
import android.view.ViewGroup;
import android.view.Window;
import android.view.WindowManager;
import android.widget.FrameLayout;
@@ -76,6 +77,12 @@ public class BrightnessDialog extends Activity {
        FrameLayout frame = findViewById(R.id.brightness_mirror_container);
        // The brightness mirror container is INVISIBLE by default.
        frame.setVisibility(View.VISIBLE);
        ViewGroup.MarginLayoutParams lp = (ViewGroup.MarginLayoutParams) frame.getLayoutParams();
        int horizontalMargin =
                getResources().getDimensionPixelSize(R.dimen.notification_side_paddings);
        lp.leftMargin = horizontalMargin;
        lp.rightMargin = horizontalMargin;
        frame.setLayoutParams(lp);

        BrightnessSliderController controller = mToggleSliderFactory.create(this, frame);
        controller.init();