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

Commit a525b079 authored by Adrian Roos's avatar Adrian Roos Committed by android-build-merger
Browse files

Merge "ScreenDecorations: Only draw cutout if requested" into pi-dev

am: 819fffaf

Change-Id: I83f228f42789b40816c39b517c53e35ae74f2554
parents e7e1f443 819fffaf
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -214,7 +214,11 @@ public class ScreenDecorations extends SystemUI implements Tunable {
    }

    private boolean shouldDrawCutout() {
        return mContext.getResources().getBoolean(
        return shouldDrawCutout(mContext);
    }

    static boolean shouldDrawCutout(Context context) {
        return context.getResources().getBoolean(
                com.android.internal.R.bool.config_fillMainBuiltInDisplayCutout);
    }

@@ -393,7 +397,7 @@ public class ScreenDecorations extends SystemUI implements Tunable {
            mBoundingRect.setEmpty();
            mBoundingPath.reset();
            int newVisible;
            if (hasCutout()) {
            if (shouldDrawCutout(getContext()) && hasCutout()) {
                mBounds.set(mInfo.displayCutout.getBounds());
                localBounds(mBoundingRect);
                updateBoundingPath();