From f081f06a4808291b72cb31f641ea4deed0b61e18 Mon Sep 17 00:00:00 2001
From: Jorim Jaggi
Date: Thu, 24 Oct 2019 16:24:54 +0200
Subject: [PATCH] Kill overscan insets and outsets
Also remove WindowManagerStressTest because that has been replaced
with proper perf test.
Test: Boots
Bug: 143255833
Change-Id: I1d293cda7c82d0aa1c3a6cc694c74bf7d10cc974
---
.../core/src/android/wm/RelayoutPerfTest.java | 6 +-
.../android/wm/WindowAddRemovePerfTest.java | 3 +-
api/current.txt | 8 +-
.../service/wallpaper/WallpaperService.java | 40 +---
core/java/android/view/Display.java | 14 --
core/java/android/view/DisplayInfo.java | 51 -----
core/java/android/view/IWindow.aidl | 4 +-
core/java/android/view/IWindowManager.aidl | 2 -
core/java/android/view/IWindowSession.aidl | 9 +-
core/java/android/view/View.java | 42 +---
core/java/android/view/ViewRootImpl.java | 71 +-----
core/java/android/view/WindowManager.java | 3 +
.../android/view/WindowlessWindowManager.java | 6 +-
.../android/internal/policy/DecorView.java | 26 ---
.../android/internal/policy/PhoneWindow.java | 4 -
.../internal/util/ScreenShapeHelper.java | 23 --
.../android/internal/view/BaseIWindow.java | 4 +-
.../android/server/windowmanagerservice.proto | 4 +-
core/res/res/values/attrs.xml | 4 +-
core/res/res/values/config_material.xml | 3 -
core/res/res/values/themes_material.xml | 12 +-
.../server/display/LogicalDisplay.java | 4 -
.../server/policy/WindowManagerPolicy.java | 9 -
.../server/wm/CircularDisplayMask.java | 161 --------------
.../com/android/server/wm/DisplayFrames.java | 57 +----
.../com/android/server/wm/DisplayPolicy.java | 204 ++++--------------
.../server/wm/DisplayWindowSettings.java | 42 +---
.../server/wm/RootWindowContainer.java | 4 -
.../java/com/android/server/wm/Session.java | 14 +-
.../server/wm/TaskSnapshotSurface.java | 8 +-
.../com/android/server/wm/WindowFrames.java | 112 ++--------
.../server/wm/WindowManagerService.java | 107 +--------
.../server/wm/WindowManagerShellCommand.java | 28 ---
.../com/android/server/wm/WindowState.java | 37 +---
.../server/wm/DisplayPolicyLayoutTests.java | 12 +-
.../server/wm/DisplayWindowSettingsTests.java | 51 -----
.../com/android/server/wm/TestIWindow.java | 4 +-
.../android/server/wm/WindowFrameTests.java | 29 ++-
tests/WindowManagerStressTest/Android.bp | 21 --
.../AndroidManifest.xml | 34 ---
.../res/layout/activity_main.xml | 38 ----
.../res/mipmap-hdpi/ic_launcher.png | Bin 3418 -> 0 bytes
.../res/mipmap-mdpi/ic_launcher.png | Bin 2206 -> 0 bytes
.../res/mipmap-xhdpi/ic_launcher.png | Bin 4842 -> 0 bytes
.../res/mipmap-xxhdpi/ic_launcher.png | Bin 7718 -> 0 bytes
.../res/mipmap-xxxhdpi/ic_launcher.png | Bin 10486 -> 0 bytes
.../res/values/colors.xml | 20 --
.../res/values/dimens.xml | 19 --
.../res/values/strings.xml | 19 --
.../res/values/styles.xml | 23 --
.../windowmanagerstresstest/MainActivity.java | 155 -------------
51 files changed, 168 insertions(+), 1383 deletions(-)
delete mode 100644 core/java/com/android/internal/util/ScreenShapeHelper.java
delete mode 100644 services/core/java/com/android/server/wm/CircularDisplayMask.java
delete mode 100644 tests/WindowManagerStressTest/Android.bp
delete mode 100644 tests/WindowManagerStressTest/AndroidManifest.xml
delete mode 100644 tests/WindowManagerStressTest/res/layout/activity_main.xml
delete mode 100644 tests/WindowManagerStressTest/res/mipmap-hdpi/ic_launcher.png
delete mode 100644 tests/WindowManagerStressTest/res/mipmap-mdpi/ic_launcher.png
delete mode 100644 tests/WindowManagerStressTest/res/mipmap-xhdpi/ic_launcher.png
delete mode 100644 tests/WindowManagerStressTest/res/mipmap-xxhdpi/ic_launcher.png
delete mode 100644 tests/WindowManagerStressTest/res/mipmap-xxxhdpi/ic_launcher.png
delete mode 100644 tests/WindowManagerStressTest/res/values/colors.xml
delete mode 100644 tests/WindowManagerStressTest/res/values/dimens.xml
delete mode 100644 tests/WindowManagerStressTest/res/values/strings.xml
delete mode 100644 tests/WindowManagerStressTest/res/values/styles.xml
delete mode 100644 tests/WindowManagerStressTest/src/test/windowmanagerstresstest/MainActivity.java
diff --git a/apct-tests/perftests/core/src/android/wm/RelayoutPerfTest.java b/apct-tests/perftests/core/src/android/wm/RelayoutPerfTest.java
index f43bdf8348ead..f32bf9a4b9e61 100644
--- a/apct-tests/perftests/core/src/android/wm/RelayoutPerfTest.java
+++ b/apct-tests/perftests/core/src/android/wm/RelayoutPerfTest.java
@@ -111,11 +111,9 @@ public class RelayoutPerfTest extends WindowManagerPerfTestBase {
private static class RelayoutRunner {
final Rect mOutFrame = new Rect();
- final Rect mOutOverscanInsets = new Rect();
final Rect mOutContentInsets = new Rect();
final Rect mOutVisibleInsets = new Rect();
final Rect mOutStableInsets = new Rect();
- final Rect mOutOutsets = new Rect();
final Rect mOutBackDropFrame = new Rect();
final DisplayCutout.ParcelableWrapper mOutDisplayCutout =
new DisplayCutout.ParcelableWrapper(DisplayCutout.NO_CUTOUT);
@@ -149,8 +147,8 @@ public class RelayoutPerfTest extends WindowManagerPerfTestBase {
while (state.keepRunning()) {
session.relayout(mWindow, mSeq, mParams, mWidth, mHeight,
mViewVisibility.getAsInt(), mFlags, mFrameNumber, mOutFrame,
- mOutOverscanInsets, mOutContentInsets, mOutVisibleInsets, mOutStableInsets,
- mOutOutsets, mOutBackDropFrame, mOutDisplayCutout, mOutMergedConfiguration,
+ mOutContentInsets, mOutVisibleInsets, mOutStableInsets,
+ mOutBackDropFrame, mOutDisplayCutout, mOutMergedConfiguration,
mOutSurfaceControl, mOutInsetsState);
}
}
diff --git a/apct-tests/perftests/core/src/android/wm/WindowAddRemovePerfTest.java b/apct-tests/perftests/core/src/android/wm/WindowAddRemovePerfTest.java
index 27790e649a263..82eb97be54bd7 100644
--- a/apct-tests/perftests/core/src/android/wm/WindowAddRemovePerfTest.java
+++ b/apct-tests/perftests/core/src/android/wm/WindowAddRemovePerfTest.java
@@ -70,7 +70,6 @@ public class WindowAddRemovePerfTest extends WindowManagerPerfTestBase {
final Rect mOutFrame = new Rect();
final Rect mOutContentInsets = new Rect();
final Rect mOutStableInsets = new Rect();
- final Rect mOutOutsets = new Rect();
final DisplayCutout.ParcelableWrapper mOutDisplayCutout =
new DisplayCutout.ParcelableWrapper();
final InsetsState mOutInsetsState = new InsetsState();
@@ -92,7 +91,7 @@ public class WindowAddRemovePerfTest extends WindowManagerPerfTestBase {
long startTime = SystemClock.elapsedRealtimeNanos();
session.addToDisplay(this, mSeq, mLayoutParams, View.VISIBLE,
Display.DEFAULT_DISPLAY, mOutFrame, mOutContentInsets, mOutStableInsets,
- mOutOutsets, mOutDisplayCutout, inputChannel, mOutInsetsState);
+ mOutDisplayCutout, inputChannel, mOutInsetsState);
final long elapsedTimeNsOfAdd = SystemClock.elapsedRealtimeNanos() - startTime;
state.addExtraResult("add", elapsedTimeNsOfAdd);
diff --git a/api/current.txt b/api/current.txt
index d6f785f0cb534..be7688fd21bf1 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -1597,7 +1597,7 @@ package android {
field public static final int windowMinWidthMinor = 16843607; // 0x1010357
field public static final int windowNoDisplay = 16843294; // 0x101021e
field public static final int windowNoTitle = 16842838; // 0x1010056
- field public static final int windowOverscan = 16843727; // 0x10103cf
+ field @Deprecated public static final int windowOverscan = 16843727; // 0x10103cf
field public static final int windowReenterTransition = 16843951; // 0x10104af
field public static final int windowReturnTransition = 16843950; // 0x10104ae
field public static final int windowSharedElementEnterTransition = 16843833; // 0x1010439
@@ -2324,13 +2324,13 @@ package android {
field public static final int Theme_Material_Light_LightStatusBar = 16974549; // 0x10302d5
field public static final int Theme_Material_Light_NoActionBar = 16974401; // 0x1030241
field public static final int Theme_Material_Light_NoActionBar_Fullscreen = 16974402; // 0x1030242
- field public static final int Theme_Material_Light_NoActionBar_Overscan = 16974403; // 0x1030243
+ field @Deprecated public static final int Theme_Material_Light_NoActionBar_Overscan = 16974403; // 0x1030243
field public static final int Theme_Material_Light_NoActionBar_TranslucentDecor = 16974404; // 0x1030244
field public static final int Theme_Material_Light_Panel = 16974405; // 0x1030245
field public static final int Theme_Material_Light_Voice = 16974406; // 0x1030246
field public static final int Theme_Material_NoActionBar = 16974382; // 0x103022e
field public static final int Theme_Material_NoActionBar_Fullscreen = 16974383; // 0x103022f
- field public static final int Theme_Material_NoActionBar_Overscan = 16974384; // 0x1030230
+ field @Deprecated public static final int Theme_Material_NoActionBar_Overscan = 16974384; // 0x1030230
field public static final int Theme_Material_NoActionBar_TranslucentDecor = 16974385; // 0x1030231
field public static final int Theme_Material_Panel = 16974386; // 0x1030232
field public static final int Theme_Material_Settings = 16974387; // 0x1030233
@@ -52255,7 +52255,7 @@ package android.view {
field public static final int FLAG_KEEP_SCREEN_ON = 128; // 0x80
field public static final int FLAG_LAYOUT_ATTACHED_IN_DECOR = 1073741824; // 0x40000000
field public static final int FLAG_LAYOUT_INSET_DECOR = 65536; // 0x10000
- field public static final int FLAG_LAYOUT_IN_OVERSCAN = 33554432; // 0x2000000
+ field @Deprecated public static final int FLAG_LAYOUT_IN_OVERSCAN = 33554432; // 0x2000000
field public static final int FLAG_LAYOUT_IN_SCREEN = 256; // 0x100
field public static final int FLAG_LAYOUT_NO_LIMITS = 512; // 0x200
field public static final int FLAG_LOCAL_FOCUS_MODE = 268435456; // 0x10000000
diff --git a/core/java/android/service/wallpaper/WallpaperService.java b/core/java/android/service/wallpaper/WallpaperService.java
index e784ad3e31880..d5c67668b88ea 100644
--- a/core/java/android/service/wallpaper/WallpaperService.java
+++ b/core/java/android/service/wallpaper/WallpaperService.java
@@ -176,14 +176,10 @@ public abstract class WallpaperService extends Service {
int mCurWindowPrivateFlags = mWindowPrivateFlags;
final Rect mVisibleInsets = new Rect();
final Rect mWinFrame = new Rect();
- final Rect mOverscanInsets = new Rect();
final Rect mContentInsets = new Rect();
final Rect mStableInsets = new Rect();
- final Rect mOutsets = new Rect();
- final Rect mDispatchedOverscanInsets = new Rect();
final Rect mDispatchedContentInsets = new Rect();
final Rect mDispatchedStableInsets = new Rect();
- final Rect mDispatchedOutsets = new Rect();
final Rect mFinalSystemInsets = new Rect();
final Rect mFinalStableInsets = new Rect();
final Rect mBackdropFrame = new Rect();
@@ -317,13 +313,13 @@ public abstract class WallpaperService extends Service {
final BaseIWindow mWindow = new BaseIWindow() {
@Override
- public void resized(Rect frame, Rect overscanInsets, Rect contentInsets,
- Rect visibleInsets, Rect stableInsets, Rect outsets, boolean reportDraw,
+ public void resized(Rect frame, Rect contentInsets,
+ Rect visibleInsets, Rect stableInsets, boolean reportDraw,
MergedConfiguration mergedConfiguration, Rect backDropRect, boolean forceLayout,
boolean alwaysConsumeSystemBars, int displayId,
DisplayCutout.ParcelableWrapper displayCutout) {
- Message msg = mCaller.obtainMessageIO(MSG_WINDOW_RESIZED,
- reportDraw ? 1 : 0, outsets);
+ Message msg = mCaller.obtainMessageI(MSG_WINDOW_RESIZED,
+ reportDraw ? 1 : 0);
mCaller.sendMessage(msg);
}
@@ -822,7 +818,7 @@ public abstract class WallpaperService extends Service {
if (mSession.addToDisplay(mWindow, mWindow.mSeq, mLayout, View.VISIBLE,
mDisplay.getDisplayId(), mWinFrame, mContentInsets, mStableInsets,
- mOutsets, mDisplayCutout, inputChannel,
+ mDisplayCutout, inputChannel,
mInsetsState) < 0) {
Log.w(TAG, "Failed to add window while updating wallpaper surface.");
return;
@@ -838,17 +834,13 @@ public abstract class WallpaperService extends Service {
if (!fixedSize) {
mLayout.surfaceInsets.set(mIWallpaperEngine.mDisplayPadding);
- mLayout.surfaceInsets.left += mOutsets.left;
- mLayout.surfaceInsets.top += mOutsets.top;
- mLayout.surfaceInsets.right += mOutsets.right;
- mLayout.surfaceInsets.bottom += mOutsets.bottom;
} else {
mLayout.surfaceInsets.set(0, 0, 0, 0);
}
final int relayoutResult = mSession.relayout(
mWindow, mWindow.mSeq, mLayout, mWidth, mHeight,
- View.VISIBLE, 0, -1, mWinFrame, mOverscanInsets, mContentInsets,
- mVisibleInsets, mStableInsets, mOutsets, mBackdropFrame,
+ View.VISIBLE, 0, -1, mWinFrame, mContentInsets,
+ mVisibleInsets, mStableInsets, mBackdropFrame,
mDisplayCutout, mMergedConfiguration, mSurfaceControl,
mInsetsState);
if (mSurfaceControl.isValid()) {
@@ -864,12 +856,8 @@ public abstract class WallpaperService extends Service {
if (!fixedSize) {
final Rect padding = mIWallpaperEngine.mDisplayPadding;
- w += padding.left + padding.right + mOutsets.left + mOutsets.right;
- h += padding.top + padding.bottom + mOutsets.top + mOutsets.bottom;
- mOverscanInsets.left += padding.left;
- mOverscanInsets.top += padding.top;
- mOverscanInsets.right += padding.right;
- mOverscanInsets.bottom += padding.bottom;
+ w += padding.left + padding.right;
+ h += padding.top + padding.bottom;
mContentInsets.left += padding.left;
mContentInsets.top += padding.top;
mContentInsets.right += padding.right;
@@ -898,10 +886,8 @@ public abstract class WallpaperService extends Service {
Log.v(TAG, "Wallpaper size has changed: (" + mCurWidth + ", " + mCurHeight);
}
- insetsChanged |= !mDispatchedOverscanInsets.equals(mOverscanInsets);
insetsChanged |= !mDispatchedContentInsets.equals(mContentInsets);
insetsChanged |= !mDispatchedStableInsets.equals(mStableInsets);
- insetsChanged |= !mDispatchedOutsets.equals(mOutsets);
insetsChanged |= !mDispatchedDisplayCutout.equals(mDisplayCutout.get());
mSurfaceHolder.setSurfaceFrameSize(w, h);
@@ -961,16 +947,9 @@ public abstract class WallpaperService extends Service {
}
if (insetsChanged) {
- mDispatchedOverscanInsets.set(mOverscanInsets);
- mDispatchedOverscanInsets.left += mOutsets.left;
- mDispatchedOverscanInsets.top += mOutsets.top;
- mDispatchedOverscanInsets.right += mOutsets.right;
- mDispatchedOverscanInsets.bottom += mOutsets.bottom;
mDispatchedContentInsets.set(mContentInsets);
mDispatchedStableInsets.set(mStableInsets);
- mDispatchedOutsets.set(mOutsets);
mDispatchedDisplayCutout = mDisplayCutout.get();
- mFinalSystemInsets.set(mDispatchedOverscanInsets);
mFinalStableInsets.set(mDispatchedStableInsets);
WindowInsets insets = new WindowInsets(mFinalSystemInsets,
mFinalStableInsets,
@@ -1457,7 +1436,6 @@ public abstract class WallpaperService extends Service {
} break;
case MSG_WINDOW_RESIZED: {
final boolean reportDraw = message.arg1 != 0;
- mEngine.mOutsets.set((Rect) message.obj);
mEngine.updateSurface(true, false, reportDraw);
mEngine.doOffsetsChanged(true);
} break;
diff --git a/core/java/android/view/Display.java b/core/java/android/view/Display.java
index b3d98b8de0a37..03e68b0058b2c 100644
--- a/core/java/android/view/Display.java
+++ b/core/java/android/view/Display.java
@@ -748,20 +748,6 @@ public final class Display {
}
}
- /**
- * @hide
- * Return a rectangle defining the insets of the overscan region of the display.
- * Each field of the rectangle is the number of pixels the overscan area extends
- * into the display on that side.
- */
- public void getOverscanInsets(Rect outRect) {
- synchronized (this) {
- updateDisplayInfoLocked();
- outRect.set(mDisplayInfo.overscanLeft, mDisplayInfo.overscanTop,
- mDisplayInfo.overscanRight, mDisplayInfo.overscanBottom);
- }
- }
-
/**
* Returns the rotation of the screen from its "natural" orientation.
* The returned value may be {@link Surface#ROTATION_0 Surface.ROTATION_0}
diff --git a/core/java/android/view/DisplayInfo.java b/core/java/android/view/DisplayInfo.java
index 7e22dd9f0ac84..38baccbc009fc 100644
--- a/core/java/android/view/DisplayInfo.java
+++ b/core/java/android/view/DisplayInfo.java
@@ -135,30 +135,6 @@ public final class DisplayInfo implements Parcelable {
@UnsupportedAppUsage
public int logicalHeight;
- /**
- * @hide
- * Number of overscan pixels on the left side of the display.
- */
- public int overscanLeft;
-
- /**
- * @hide
- * Number of overscan pixels on the top side of the display.
- */
- public int overscanTop;
-
- /**
- * @hide
- * Number of overscan pixels on the right side of the display.
- */
- public int overscanRight;
-
- /**
- * @hide
- * Number of overscan pixels on the bottom side of the display.
- */
- public int overscanBottom;
-
/**
* The {@link DisplayCutout} if present, otherwise {@code null}.
*
@@ -322,10 +298,6 @@ public final class DisplayInfo implements Parcelable {
&& largestNominalAppHeight == other.largestNominalAppHeight
&& logicalWidth == other.logicalWidth
&& logicalHeight == other.logicalHeight
- && overscanLeft == other.overscanLeft
- && overscanTop == other.overscanTop
- && overscanRight == other.overscanRight
- && overscanBottom == other.overscanBottom
&& Objects.equals(displayCutout, other.displayCutout)
&& rotation == other.rotation
&& modeId == other.modeId
@@ -365,10 +337,6 @@ public final class DisplayInfo implements Parcelable {
largestNominalAppHeight = other.largestNominalAppHeight;
logicalWidth = other.logicalWidth;
logicalHeight = other.logicalHeight;
- overscanLeft = other.overscanLeft;
- overscanTop = other.overscanTop;
- overscanRight = other.overscanRight;
- overscanBottom = other.overscanBottom;
displayCutout = other.displayCutout;
rotation = other.rotation;
modeId = other.modeId;
@@ -404,10 +372,6 @@ public final class DisplayInfo implements Parcelable {
largestNominalAppHeight = source.readInt();
logicalWidth = source.readInt();
logicalHeight = source.readInt();
- overscanLeft = source.readInt();
- overscanTop = source.readInt();
- overscanRight = source.readInt();
- overscanBottom = source.readInt();
displayCutout = DisplayCutout.ParcelableWrapper.readCutoutFromParcel(source);
rotation = source.readInt();
modeId = source.readInt();
@@ -452,10 +416,6 @@ public final class DisplayInfo implements Parcelable {
dest.writeInt(largestNominalAppHeight);
dest.writeInt(logicalWidth);
dest.writeInt(logicalHeight);
- dest.writeInt(overscanLeft);
- dest.writeInt(overscanTop);
- dest.writeInt(overscanRight);
- dest.writeInt(overscanBottom);
DisplayCutout.ParcelableWrapper.writeCutoutToParcel(displayCutout, dest, flags);
dest.writeInt(rotation);
dest.writeInt(modeId);
@@ -632,17 +592,6 @@ public final class DisplayInfo implements Parcelable {
sb.append(logicalWidth);
sb.append(" x ");
sb.append(logicalHeight);
- if (overscanLeft != 0 || overscanTop != 0 || overscanRight != 0 || overscanBottom != 0) {
- sb.append(", overscan (");
- sb.append(overscanLeft);
- sb.append(",");
- sb.append(overscanTop);
- sb.append(",");
- sb.append(overscanRight);
- sb.append(",");
- sb.append(overscanBottom);
- sb.append(")");
- }
sb.append(", largest app ");
sb.append(largestNominalAppWidth);
sb.append(" x ");
diff --git a/core/java/android/view/IWindow.aidl b/core/java/android/view/IWindow.aidl
index 8bf99ec4f2513..37b685a230668 100644
--- a/core/java/android/view/IWindow.aidl
+++ b/core/java/android/view/IWindow.aidl
@@ -51,8 +51,8 @@ oneway interface IWindow {
*/
void executeCommand(String command, String parameters, in ParcelFileDescriptor descriptor);
- void resized(in Rect frame, in Rect overscanInsets, in Rect contentInsets,
- in Rect visibleInsets, in Rect stableInsets, in Rect outsets, boolean reportDraw,
+ void resized(in Rect frame, in Rect contentInsets,
+ in Rect visibleInsets, in Rect stableInsets, boolean reportDraw,
in MergedConfiguration newMergedConfiguration, in Rect backDropFrame,
boolean forceLayout, boolean alwaysConsumeSystemBars, int displayId,
in DisplayCutout.ParcelableWrapper displayCutout);
diff --git a/core/java/android/view/IWindowManager.aidl b/core/java/android/view/IWindowManager.aidl
index 7f717a72b0f9e..870732b2aac8d 100644
--- a/core/java/android/view/IWindowManager.aidl
+++ b/core/java/android/view/IWindowManager.aidl
@@ -88,8 +88,6 @@ interface IWindowManager
void clearForcedDisplayDensityForUser(int displayId, int userId);
void setForcedDisplayScalingMode(int displayId, int mode); // 0 = auto, 1 = disable
- void setOverscan(int displayId, int left, int top, int right, int bottom);
-
// These can only be called when holding the MANAGE_APP_TOKENS permission.
void setEventDispatching(boolean enabled);
void addWindowToken(IBinder token, int type, int displayId);
diff --git a/core/java/android/view/IWindowSession.aidl b/core/java/android/view/IWindowSession.aidl
index eaf6fca1b91fe..0489e14993e32 100644
--- a/core/java/android/view/IWindowSession.aidl
+++ b/core/java/android/view/IWindowSession.aidl
@@ -43,7 +43,7 @@ import java.util.List;
interface IWindowSession {
int addToDisplay(IWindow window, int seq, in WindowManager.LayoutParams attrs,
in int viewVisibility, in int layerStackId, out Rect outFrame,
- out Rect outContentInsets, out Rect outStableInsets, out Rect outOutsets,
+ out Rect outContentInsets, out Rect outStableInsets,
out DisplayCutout.ParcelableWrapper displayCutout, out InputChannel outInputChannel,
out InsetsState insetsState);
int addToDisplayWithoutInputChannel(IWindow window, int seq, in WindowManager.LayoutParams attrs,
@@ -70,9 +70,6 @@ interface IWindowSession {
* @param frameNumber A frame number in which changes requested in this layout will be rendered.
* @param outFrame Rect in which is placed the new position/size on
* screen.
- * @param outOverscanInsets Rect in which is placed the offsets from
- * outFrame in which the content of the window are inside
- * of the display's overlay region.
* @param outContentInsets Rect in which is placed the offsets from
* outFrame in which the content of the window should be
* placed. This can be used to modify the window layout to ensure its
@@ -99,9 +96,9 @@ interface IWindowSession {
*/
int relayout(IWindow window, int seq, in WindowManager.LayoutParams attrs,
int requestedWidth, int requestedHeight, int viewVisibility,
- int flags, long frameNumber, out Rect outFrame, out Rect outOverscanInsets,
+ int flags, long frameNumber, out Rect outFrame,
out Rect outContentInsets, out Rect outVisibleInsets, out Rect outStableInsets,
- out Rect outOutsets, out Rect outBackdropFrame,
+ out Rect outBackdropFrame,
out DisplayCutout.ParcelableWrapper displayCutout,
out MergedConfiguration outMergedConfiguration, out SurfaceControl outSurfaceControl,
out InsetsState insetsState);
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index 8d08004607758..e8e5d6ff22b30 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -11287,16 +11287,14 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
public WindowInsets computeSystemWindowInsets(WindowInsets in, Rect outLocalInsets) {
if ((mViewFlags & OPTIONAL_FITS_SYSTEM_WINDOWS) == 0
|| mAttachInfo == null
- || ((mAttachInfo.mSystemUiVisibility & SYSTEM_UI_LAYOUT_FLAGS) == 0
- && !mAttachInfo.mOverscanRequested)) {
+ || ((mAttachInfo.mSystemUiVisibility & SYSTEM_UI_LAYOUT_FLAGS) == 0)) {
outLocalInsets.set(in.getSystemWindowInsetsAsRect());
return in.consumeSystemWindowInsets().inset(outLocalInsets);
} else {
// The application wants to take care of fitting system window for
- // the content... however we still need to take care of any overscan here.
- final Rect overscan = mAttachInfo.mOverscanInsets;
- outLocalInsets.set(overscan);
- return in.inset(outLocalInsets);
+ // the content.
+ outLocalInsets.setEmpty();
+ return in;
}
}
@@ -11375,19 +11373,6 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
setFlags(OPTIONAL_FITS_SYSTEM_WINDOWS, OPTIONAL_FITS_SYSTEM_WINDOWS);
}
- /**
- * Returns the outsets, which areas of the device that aren't a surface, but we would like to
- * treat them as such.
- * @hide
- */
- public void getOutsets(Rect outOutsetRect) {
- if (mAttachInfo != null) {
- outOutsetRect.set(mAttachInfo.mOutsets);
- } else {
- outOutsetRect.setEmpty();
- }
- }
-
/**
* Returns the visibility status for this view.
*
@@ -28442,13 +28427,6 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
*/
boolean mUse32BitDrawingCache;
- /**
- * For windows that are full-screen but using insets to layout inside
- * of the screen areas, these are the current insets to appear inside
- * the overscan area of the display.
- */
- final Rect mOverscanInsets = new Rect();
-
/**
* For windows that are full-screen but using insets to layout inside
* of the screen decorations, these are the current insets for the
@@ -28476,12 +28454,6 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
final DisplayCutout.ParcelableWrapper mDisplayCutout =
new DisplayCutout.ParcelableWrapper(DisplayCutout.NO_CUTOUT);
- /**
- * For windows that include areas that are not covered by real surface these are the outsets
- * for real surface.
- */
- final Rect mOutsets = new Rect();
-
/**
* In multi-window we force show the system bars. Because we don't want that the surface
* size changes in this mode, we instead have a flag whether the system bars sizes should
@@ -28590,12 +28562,6 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
*/
boolean mHasSystemUiListeners;
- /**
- * Set if the window has requested to extend into the overscan region
- * via WindowManager.LayoutParams.FLAG_LAYOUT_IN_OVERSCAN.
- */
- boolean mOverscanRequested;
-
/**
* Set if the visibility of any views has changed.
*/
diff --git a/core/java/android/view/ViewRootImpl.java b/core/java/android/view/ViewRootImpl.java
index 97adaf57f9b48..8ee7a0ef5a66e 100644
--- a/core/java/android/view/ViewRootImpl.java
+++ b/core/java/android/view/ViewRootImpl.java
@@ -219,10 +219,6 @@ public final class ViewRootImpl implements ViewParent,
*/
private static final String PROPERTY_PROFILE_RENDERING = "viewroot.profile_rendering";
- // properties used by emulator to determine display shape
- public static final String PROPERTY_EMULATOR_WIN_OUTSET_BOTTOM_PX =
- "ro.emu.win_outset_bottom_px";
-
/**
* Maximum time we allow the user to roll the trackball enough to generate
* a key event, before resetting the counters.
@@ -447,7 +443,6 @@ public final class ViewRootImpl implements ViewParent,
boolean mIsDrawing;
int mLastSystemUiVisibility;
int mClientWindowLayoutFlags;
- boolean mLastOverscanRequested;
// Pool of queued input events.
private static final int MAX_QUEUED_INPUT_EVENT_POOL_SIZE = 10;
@@ -507,11 +502,9 @@ public final class ViewRootImpl implements ViewParent,
// These are accessed by multiple threads.
final Rect mWinFrame; // frame given by window manager.
- final Rect mPendingOverscanInsets = new Rect();
final Rect mPendingVisibleInsets = new Rect();
final Rect mPendingStableInsets = new Rect();
final Rect mPendingContentInsets = new Rect();
- final Rect mPendingOutsets = new Rect();
final Rect mPendingBackDropFrame = new Rect();
final DisplayCutout.ParcelableWrapper mPendingDisplayCutout =
new DisplayCutout.ParcelableWrapper(DisplayCutout.NO_CUTOUT);
@@ -900,7 +893,7 @@ public final class ViewRootImpl implements ViewParent,
res = mWindowSession.addToDisplay(mWindow, mSeq, mWindowAttributes,
getHostVisibility(), mDisplay.getDisplayId(), mTmpFrame,
mAttachInfo.mContentInsets, mAttachInfo.mStableInsets,
- mAttachInfo.mOutsets, mAttachInfo.mDisplayCutout, inputChannel,
+ mAttachInfo.mDisplayCutout, inputChannel,
mTempInsets);
setFrame(mTmpFrame);
} catch (RemoteException e) {
@@ -921,7 +914,6 @@ public final class ViewRootImpl implements ViewParent,
if (mTranslator != null) {
mTranslator.translateRectInScreenToAppWindow(mAttachInfo.mContentInsets);
}
- mPendingOverscanInsets.set(0, 0, 0, 0);
mPendingContentInsets.set(mAttachInfo.mContentInsets);
mPendingStableInsets.set(mAttachInfo.mStableInsets);
mPendingDisplayCutout.set(mAttachInfo.mDisplayCutout);
@@ -1967,12 +1959,6 @@ public final class ViewRootImpl implements ViewParent,
stableInsets = mPendingStableInsets;
displayCutout = mPendingDisplayCutout.get();
}
- Rect outsets = mAttachInfo.mOutsets;
- if (outsets.left > 0 || outsets.top > 0 || outsets.right > 0 || outsets.bottom > 0) {
- contentInsets = new Rect(contentInsets.left + outsets.left,
- contentInsets.top + outsets.top, contentInsets.right + outsets.right,
- contentInsets.bottom + outsets.bottom);
- }
contentInsets = ensureInsetsNonNegative(contentInsets, "content");
stableInsets = ensureInsetsNonNegative(stableInsets, "stable");
mLastWindowInsets = mInsetsController.calculateInsets(
@@ -2146,9 +2132,6 @@ public final class ViewRootImpl implements ViewParent,
mAttachInfo.mInTouchMode = !mAddedTouchMode;
ensureTouchModeLocally(mAddedTouchMode);
} else {
- if (!mPendingOverscanInsets.equals(mAttachInfo.mOverscanInsets)) {
- insetsChanged = true;
- }
if (!mPendingContentInsets.equals(mAttachInfo.mContentInsets)) {
insetsChanged = true;
}
@@ -2163,9 +2146,6 @@ public final class ViewRootImpl implements ViewParent,
if (DEBUG_LAYOUT) Log.v(mTag, "Visible insets changing to: "
+ mAttachInfo.mVisibleInsets);
}
- if (!mPendingOutsets.equals(mAttachInfo.mOutsets)) {
- insetsChanged = true;
- }
if (mPendingAlwaysConsumeSystemBars != mAttachInfo.mAlwaysConsumeSystemBars) {
insetsChanged = true;
}
@@ -2228,7 +2208,6 @@ public final class ViewRootImpl implements ViewParent,
if (mApplyInsetsRequested) {
mApplyInsetsRequested = false;
- mLastOverscanRequested = mAttachInfo.mOverscanRequested;
dispatchApplyInsets(host);
if (mLayoutRequested) {
// Short-circuit catching a new layout request here, so
@@ -2292,8 +2271,6 @@ public final class ViewRootImpl implements ViewParent,
&& !PixelFormat.formatHasAlpha(params.format)) {
params.format = PixelFormat.TRANSLUCENT;
}
- mAttachInfo.mOverscanRequested =
- (params.flags & WindowManager.LayoutParams.FLAG_LAYOUT_IN_OVERSCAN) != 0;
}
if (mFirst || windowShouldResize || insetsChanged ||
@@ -2342,12 +2319,10 @@ public final class ViewRootImpl implements ViewParent,
relayoutResult = relayoutWindow(params, viewVisibility, insetsPending);
if (DEBUG_LAYOUT) Log.v(mTag, "relayout: frame=" + frame.toShortString()
- + " overscan=" + mPendingOverscanInsets.toShortString()
+ " content=" + mPendingContentInsets.toShortString()
+ " visible=" + mPendingVisibleInsets.toShortString()
+ " stable=" + mPendingStableInsets.toShortString()
+ " cutout=" + mPendingDisplayCutout.get().toString()
- + " outsets=" + mPendingOutsets.toShortString()
+ " surface=" + mSurface);
// If the pending {@link MergedConfiguration} handed back from
@@ -2363,8 +2338,6 @@ public final class ViewRootImpl implements ViewParent,
updatedConfiguration = true;
}
- final boolean overscanInsetsChanged = !mPendingOverscanInsets.equals(
- mAttachInfo.mOverscanInsets);
contentInsetsChanged = !mPendingContentInsets.equals(
mAttachInfo.mContentInsets);
final boolean visibleInsetsChanged = !mPendingVisibleInsets.equals(
@@ -2373,7 +2346,6 @@ public final class ViewRootImpl implements ViewParent,
mAttachInfo.mStableInsets);
final boolean cutoutChanged = !mPendingDisplayCutout.equals(
mAttachInfo.mDisplayCutout);
- final boolean outsetsChanged = !mPendingOutsets.equals(mAttachInfo.mOutsets);
surfaceSizeChanged = (relayoutResult
& WindowManagerGlobal.RELAYOUT_RES_SURFACE_RESIZED) != 0;
final boolean alwaysConsumeSystemBarsChanged =
@@ -2389,13 +2361,6 @@ public final class ViewRootImpl implements ViewParent,
if (DEBUG_LAYOUT) Log.v(mTag, "Content insets changing to: "
+ mAttachInfo.mContentInsets);
}
- if (overscanInsetsChanged) {
- mAttachInfo.mOverscanInsets.set(mPendingOverscanInsets);
- if (DEBUG_LAYOUT) Log.v(mTag, "Overscan insets changing to: "
- + mAttachInfo.mOverscanInsets);
- // Need to relayout with content insets.
- contentInsetsChanged = true;
- }
if (stableInsetsChanged) {
mAttachInfo.mStableInsets.set(mPendingStableInsets);
if (DEBUG_LAYOUT) Log.v(mTag, "Decor insets changing to: "
@@ -2416,12 +2381,8 @@ public final class ViewRootImpl implements ViewParent,
contentInsetsChanged = true;
}
if (contentInsetsChanged || mLastSystemUiVisibility !=
- mAttachInfo.mSystemUiVisibility || mApplyInsetsRequested
- || mLastOverscanRequested != mAttachInfo.mOverscanRequested
- || outsetsChanged) {
+ mAttachInfo.mSystemUiVisibility || mApplyInsetsRequested) {
mLastSystemUiVisibility = mAttachInfo.mSystemUiVisibility;
- mLastOverscanRequested = mAttachInfo.mOverscanRequested;
- mAttachInfo.mOutsets.set(mPendingOutsets);
mApplyInsetsRequested = false;
dispatchApplyInsets(host);
// We applied insets so force contentInsetsChanged to ensure the
@@ -4671,12 +4632,10 @@ public final class ViewRootImpl implements ViewParent,
// Recycled in the fall through...
SomeArgs args = (SomeArgs) msg.obj;
if (mWinFrame.equals(args.arg1)
- && mPendingOverscanInsets.equals(args.arg5)
&& mPendingContentInsets.equals(args.arg2)
&& mPendingStableInsets.equals(args.arg6)
&& mPendingDisplayCutout.get().equals(args.arg9)
&& mPendingVisibleInsets.equals(args.arg3)
- && mPendingOutsets.equals(args.arg7)
&& mPendingBackDropFrame.equals(args.arg8)
&& args.arg4 == null
&& args.argi1 == 0
@@ -4706,20 +4665,16 @@ public final class ViewRootImpl implements ViewParent,
}
final boolean framesChanged = !mWinFrame.equals(args.arg1)
- || !mPendingOverscanInsets.equals(args.arg5)
|| !mPendingContentInsets.equals(args.arg2)
|| !mPendingStableInsets.equals(args.arg6)
|| !mPendingDisplayCutout.get().equals(args.arg9)
- || !mPendingVisibleInsets.equals(args.arg3)
- || !mPendingOutsets.equals(args.arg7);
+ || !mPendingVisibleInsets.equals(args.arg3);
setFrame((Rect) args.arg1);
- mPendingOverscanInsets.set((Rect) args.arg5);
mPendingContentInsets.set((Rect) args.arg2);
mPendingStableInsets.set((Rect) args.arg6);
mPendingDisplayCutout.set((DisplayCutout) args.arg9);
mPendingVisibleInsets.set((Rect) args.arg3);
- mPendingOutsets.set((Rect) args.arg7);
mPendingBackDropFrame.set((Rect) args.arg8);
mForceNextWindowRelayout = args.argi1 != 0;
mPendingAlwaysConsumeSystemBars = args.argi2 != 0;
@@ -7174,8 +7129,8 @@ public final class ViewRootImpl implements ViewParent,
(int) (mView.getMeasuredWidth() * appScale + 0.5f),
(int) (mView.getMeasuredHeight() * appScale + 0.5f), viewVisibility,
insetsPending ? WindowManagerGlobal.RELAYOUT_INSETS_PENDING : 0, frameNumber,
- mTmpFrame, mPendingOverscanInsets, mPendingContentInsets, mPendingVisibleInsets,
- mPendingStableInsets, mPendingOutsets, mPendingBackDropFrame, mPendingDisplayCutout,
+ mTmpFrame, mPendingContentInsets, mPendingVisibleInsets,
+ mPendingStableInsets, mPendingBackDropFrame, mPendingDisplayCutout,
mPendingMergedConfiguration, mSurfaceControl, mTempInsets);
if (mSurfaceControl.isValid()) {
if (USE_BLAST_BUFFERQUEUE == false) {
@@ -7198,7 +7153,6 @@ public final class ViewRootImpl implements ViewParent,
if (mTranslator != null) {
mTranslator.translateRectInScreenToAppWinFrame(mTmpFrame);
- mTranslator.translateRectInScreenToAppWindow(mPendingOverscanInsets);
mTranslator.translateRectInScreenToAppWindow(mPendingContentInsets);
mTranslator.translateRectInScreenToAppWindow(mPendingVisibleInsets);
mTranslator.translateRectInScreenToAppWindow(mPendingStableInsets);
@@ -7493,8 +7447,8 @@ public final class ViewRootImpl implements ViewParent,
}
@UnsupportedAppUsage
- private void dispatchResized(Rect frame, Rect overscanInsets, Rect contentInsets,
- Rect visibleInsets, Rect stableInsets, Rect outsets, boolean reportDraw,
+ private void dispatchResized(Rect frame, Rect contentInsets,
+ Rect visibleInsets, Rect stableInsets, boolean reportDraw,
MergedConfiguration mergedConfiguration, Rect backDropFrame, boolean forceLayout,
boolean alwaysConsumeSystemBars, int displayId,
DisplayCutout.ParcelableWrapper displayCutout) {
@@ -7519,7 +7473,6 @@ public final class ViewRootImpl implements ViewParent,
Message msg = mHandler.obtainMessage(reportDraw ? MSG_RESIZED_REPORT : MSG_RESIZED);
if (mTranslator != null) {
mTranslator.translateRectInScreenToAppWindow(frame);
- mTranslator.translateRectInScreenToAppWindow(overscanInsets);
mTranslator.translateRectInScreenToAppWindow(contentInsets);
mTranslator.translateRectInScreenToAppWindow(visibleInsets);
}
@@ -7530,9 +7483,7 @@ public final class ViewRootImpl implements ViewParent,
args.arg3 = sameProcessCall ? new Rect(visibleInsets) : visibleInsets;
args.arg4 = sameProcessCall && mergedConfiguration != null
? new MergedConfiguration(mergedConfiguration) : mergedConfiguration;
- args.arg5 = sameProcessCall ? new Rect(overscanInsets) : overscanInsets;
args.arg6 = sameProcessCall ? new Rect(stableInsets) : stableInsets;
- args.arg7 = sameProcessCall ? new Rect(outsets) : outsets;
args.arg8 = sameProcessCall ? new Rect(backDropFrame) : backDropFrame;
args.arg9 = displayCutout.get(); // DisplayCutout is immutable.
args.argi1 = forceLayout ? 1 : 0;
@@ -8637,15 +8588,15 @@ public final class ViewRootImpl implements ViewParent,
}
@Override
- public void resized(Rect frame, Rect overscanInsets, Rect contentInsets,
- Rect visibleInsets, Rect stableInsets, Rect outsets, boolean reportDraw,
+ public void resized(Rect frame, Rect contentInsets,
+ Rect visibleInsets, Rect stableInsets, boolean reportDraw,
MergedConfiguration mergedConfiguration, Rect backDropFrame, boolean forceLayout,
boolean alwaysConsumeSystemBars, int displayId,
DisplayCutout.ParcelableWrapper displayCutout) {
final ViewRootImpl viewAncestor = mViewAncestor.get();
if (viewAncestor != null) {
- viewAncestor.dispatchResized(frame, overscanInsets, contentInsets,
- visibleInsets, stableInsets, outsets, reportDraw, mergedConfiguration,
+ viewAncestor.dispatchResized(frame, contentInsets,
+ visibleInsets, stableInsets, reportDraw, mergedConfiguration,
backDropFrame, forceLayout, alwaysConsumeSystemBars, displayId,
displayCutout);
}
diff --git a/core/java/android/view/WindowManager.java b/core/java/android/view/WindowManager.java
index 742ab77b50684..39088112397ce 100644
--- a/core/java/android/view/WindowManager.java
+++ b/core/java/android/view/WindowManager.java
@@ -1445,7 +1445,10 @@ public interface WindowManager extends ViewManager {
* position its UI elements with this overscan flag is set:
*
* {@sample development/samples/ApiDemos/res/layout/overscan_activity.xml complete}
+ *
+ * @deprecated Overscan areas aren't set by any Android product anymore.
*/
+ @Deprecated
public static final int FLAG_LAYOUT_IN_OVERSCAN = 0x02000000;
/**
diff --git a/core/java/android/view/WindowlessWindowManager.java b/core/java/android/view/WindowlessWindowManager.java
index 403bfda782925..0ff6063d4ae2f 100644
--- a/core/java/android/view/WindowlessWindowManager.java
+++ b/core/java/android/view/WindowlessWindowManager.java
@@ -90,7 +90,7 @@ class WindowlessWindowManager implements IWindowSession {
@Override
public int addToDisplay(IWindow window, int seq, WindowManager.LayoutParams attrs,
int viewVisibility, int displayId, Rect outFrame, Rect outContentInsets,
- Rect outStableInsets, Rect outOutsets,
+ Rect outStableInsets,
DisplayCutout.ParcelableWrapper outDisplayCutout, InputChannel outInputChannel,
InsetsState outInsetsState) {
final SurfaceControl.Builder b = new SurfaceControl.Builder(mSurfaceSession)
@@ -140,8 +140,8 @@ class WindowlessWindowManager implements IWindowSession {
@Override
public int relayout(IWindow window, int seq, WindowManager.LayoutParams inAttrs,
int requestedWidth, int requestedHeight, int viewFlags, int flags, long frameNumber,
- Rect outFrame, Rect outOverscanInsets, Rect outContentInsets, Rect outVisibleInsets,
- Rect outStableInsets, Rect outsets, Rect outBackdropFrame,
+ Rect outFrame, Rect outContentInsets, Rect outVisibleInsets,
+ Rect outStableInsets, Rect outBackdropFrame,
DisplayCutout.ParcelableWrapper cutout, MergedConfiguration mergedConfiguration,
SurfaceControl outSurfaceControl, InsetsState outInsetsState) {
State state = null;
diff --git a/core/java/com/android/internal/policy/DecorView.java b/core/java/com/android/internal/policy/DecorView.java
index b02563a675038..c33b6dc0bba23 100644
--- a/core/java/com/android/internal/policy/DecorView.java
+++ b/core/java/com/android/internal/policy/DecorView.java
@@ -236,7 +236,6 @@ public class DecorView extends FrameLayout implements RootViewSurfaceTaker, Wind
ViewGroup mContentRoot;
private Rect mTempRect;
- private Rect mOutsets = new Rect();
// This is the caption view for the window, containing the caption and window control
// buttons. The visibility of this decor depends on the workspace and the window type.
@@ -729,24 +728,6 @@ public class DecorView extends FrameLayout implements RootViewSurfaceTaker, Wind
}
}
- getOutsets(mOutsets);
- if (mOutsets.top > 0 || mOutsets.bottom > 0) {
- int mode = MeasureSpec.getMode(heightMeasureSpec);
- if (mode != MeasureSpec.UNSPECIFIED) {
- int height = MeasureSpec.getSize(heightMeasureSpec);
- heightMeasureSpec = MeasureSpec.makeMeasureSpec(
- height + mOutsets.top + mOutsets.bottom, mode);
- }
- }
- if (mOutsets.left > 0 || mOutsets.right > 0) {
- int mode = MeasureSpec.getMode(widthMeasureSpec);
- if (mode != MeasureSpec.UNSPECIFIED) {
- int width = MeasureSpec.getSize(widthMeasureSpec);
- widthMeasureSpec = MeasureSpec.makeMeasureSpec(
- width + mOutsets.left + mOutsets.right, mode);
- }
- }
-
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
int width = getMeasuredWidth();
@@ -785,13 +766,6 @@ public class DecorView extends FrameLayout implements RootViewSurfaceTaker, Wind
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
super.onLayout(changed, left, top, right, bottom);
- getOutsets(mOutsets);
- if (mOutsets.left > 0) {
- offsetLeftAndRight(-mOutsets.left);
- }
- if (mOutsets.top > 0) {
- offsetTopAndBottom(-mOutsets.top);
- }
if (mApplyFloatingVerticalInsets) {
offsetTopAndBottom(mFloatingInsets.top);
}
diff --git a/core/java/com/android/internal/policy/PhoneWindow.java b/core/java/com/android/internal/policy/PhoneWindow.java
index c8ba0a0e25a22..227ef28cd1299 100644
--- a/core/java/com/android/internal/policy/PhoneWindow.java
+++ b/core/java/com/android/internal/policy/PhoneWindow.java
@@ -2378,10 +2378,6 @@ public class PhoneWindow extends Window implements MenuBuilder.Callback {
& (~getForcedWindowFlags()));
}
- if (a.getBoolean(R.styleable.Window_windowOverscan, false)) {
- setFlags(FLAG_LAYOUT_IN_OVERSCAN, FLAG_LAYOUT_IN_OVERSCAN&(~getForcedWindowFlags()));
- }
-
if (a.getBoolean(R.styleable.Window_windowShowWallpaper, false)) {
setFlags(FLAG_SHOW_WALLPAPER, FLAG_SHOW_WALLPAPER&(~getForcedWindowFlags()));
}
diff --git a/core/java/com/android/internal/util/ScreenShapeHelper.java b/core/java/com/android/internal/util/ScreenShapeHelper.java
deleted file mode 100644
index 5f390be05da5e..0000000000000
--- a/core/java/com/android/internal/util/ScreenShapeHelper.java
+++ /dev/null
@@ -1,23 +0,0 @@
-package com.android.internal.util;
-
-import android.content.res.Resources;
-import android.os.Build;
-import android.os.SystemProperties;
-import android.view.ViewRootImpl;
-
-/**
- * @hide
- */
-public class ScreenShapeHelper {
- /**
- * Return the bottom pixel window outset of a window given its style attributes.
- * @return An outset dimension in pixels or 0 if no outset should be applied.
- */
- public static int getWindowOutsetBottomPx(Resources resources) {
- if (Build.IS_EMULATOR) {
- return SystemProperties.getInt(ViewRootImpl.PROPERTY_EMULATOR_WIN_OUTSET_BOTTOM_PX, 0);
- } else {
- return resources.getInteger(com.android.internal.R.integer.config_windowOutsetBottom);
- }
- }
-}
diff --git a/core/java/com/android/internal/view/BaseIWindow.java b/core/java/com/android/internal/view/BaseIWindow.java
index 7e1f13afc2cb7..c7cdc3b51bcae 100644
--- a/core/java/com/android/internal/view/BaseIWindow.java
+++ b/core/java/com/android/internal/view/BaseIWindow.java
@@ -49,8 +49,8 @@ public class BaseIWindow extends IWindow.Stub {
}
@Override
- public void resized(Rect frame, Rect overscanInsets, Rect contentInsets, Rect visibleInsets,
- Rect stableInsets, Rect outsets, boolean reportDraw,
+ public void resized(Rect frame, Rect contentInsets, Rect visibleInsets,
+ Rect stableInsets, boolean reportDraw,
MergedConfiguration mergedConfiguration, Rect backDropFrame, boolean forceLayout,
boolean alwaysConsumeSystemBars, int displayId,
DisplayCutout.ParcelableWrapper displayCutout) {
diff --git a/core/proto/android/server/windowmanagerservice.proto b/core/proto/android/server/windowmanagerservice.proto
index c9a18296a292a..653d381e2960d 100644
--- a/core/proto/android/server/windowmanagerservice.proto
+++ b/core/proto/android/server/windowmanagerservice.proto
@@ -385,12 +385,12 @@ message WindowFramesProto {
optional .android.graphics.RectProto display_frame = 4;
optional .android.graphics.RectProto frame = 5;
optional .android.graphics.RectProto outset_frame = 6;
- optional .android.graphics.RectProto overscan_frame = 7;
+ optional .android.graphics.RectProto overscan_frame = 7 [deprecated=true];
optional .android.graphics.RectProto parent_frame = 8;
optional .android.graphics.RectProto visible_frame = 9;
optional .android.view.DisplayCutoutProto cutout = 10;
optional .android.graphics.RectProto content_insets = 11;
- optional .android.graphics.RectProto overscan_insets = 12;
+ optional .android.graphics.RectProto overscan_insets = 12 [deprecated=true];
optional .android.graphics.RectProto visible_insets = 13;
optional .android.graphics.RectProto stable_insets = 14;
optional .android.graphics.RectProto outsets = 15;
diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml
index bad5d6453bda7..642dc929e88a5 100644
--- a/core/res/res/values/attrs.xml
+++ b/core/res/res/values/attrs.xml
@@ -359,7 +359,9 @@
to {@link android.view.WindowManager.LayoutParams#FLAG_FULLSCREEN}. -->
+ to {@link android.view.WindowManager.LayoutParams#FLAG_LAYOUT_IN_OVERSCAN}.
+ @deprecated Overscan areas aren't set by any Android product anymore.
+ -->
diff --git a/core/res/res/values/config_material.xml b/core/res/res/values/config_material.xml
index 840a551f914ff..64483f1f32dba 100644
--- a/core/res/res/values/config_material.xml
+++ b/core/res/res/values/config_material.xml
@@ -29,9 +29,6 @@
0
-
- false
-
true
diff --git a/core/res/res/values/themes_material.xml b/core/res/res/values/themes_material.xml
index 78d218f9a4381..f3905e93a525a 100644
--- a/core/res/res/values/themes_material.xml
+++ b/core/res/res/values/themes_material.xml
@@ -162,7 +162,6 @@ please see themes_device_defaults.xml.
@null@bool/config_windowNoTitleDefaultfalse
- @bool/config_windowOverscanByDefaultfalse@nullfalse
@@ -536,7 +535,6 @@ please see themes_device_defaults.xml.
@null@bool/config_windowNoTitleDefaultfalse
- @bool/config_windowOverscanByDefaultfalse@nullfalse
@@ -963,10 +961,11 @@ please see themes_device_defaults.xml.
+ to true.
+ @deprecated Overscan areas aren't set by any Android product anymore.
+ -->
@@ -996,10 +995,11 @@ please see themes_device_defaults.xml.
+ to true.
+ @deprecated Overscan areas aren't set by any Android product anymore.
+ -->
diff --git a/services/core/java/com/android/server/display/LogicalDisplay.java b/services/core/java/com/android/server/display/LogicalDisplay.java
index a7b90510e6c82..dcef99817fac5 100644
--- a/services/core/java/com/android/server/display/LogicalDisplay.java
+++ b/services/core/java/com/android/server/display/LogicalDisplay.java
@@ -150,10 +150,6 @@ final class LogicalDisplay {
mInfo.largestNominalAppHeight = mOverrideDisplayInfo.largestNominalAppHeight;
mInfo.logicalWidth = mOverrideDisplayInfo.logicalWidth;
mInfo.logicalHeight = mOverrideDisplayInfo.logicalHeight;
- mInfo.overscanLeft = mOverrideDisplayInfo.overscanLeft;
- mInfo.overscanTop = mOverrideDisplayInfo.overscanTop;
- mInfo.overscanRight = mOverrideDisplayInfo.overscanRight;
- mInfo.overscanBottom = mOverrideDisplayInfo.overscanBottom;
mInfo.rotation = mOverrideDisplayInfo.rotation;
mInfo.displayCutout = mOverrideDisplayInfo.displayCutout;
mInfo.logicalDensityDpi = mOverrideDisplayInfo.logicalDensityDpi;
diff --git a/services/core/java/com/android/server/policy/WindowManagerPolicy.java b/services/core/java/com/android/server/policy/WindowManagerPolicy.java
index 01250db9c5c60..1f37fafc34426 100644
--- a/services/core/java/com/android/server/policy/WindowManagerPolicy.java
+++ b/services/core/java/com/android/server/policy/WindowManagerPolicy.java
@@ -212,15 +212,6 @@ public interface WindowManagerPolicy extends WindowManagerPolicyConstants {
*/
public Rect getDisplayFrameLw();
- /**
- * Retrieve the frame of the area inside the overscan region of the
- * display that this window was last laid out in. Must be called with the
- * window manager lock held.
- *
- * @return Rect The rectangle holding the display overscan frame.
- */
- public Rect getOverscanFrameLw();
-
/**
* Retrieve the frame of the content area that this window was last
* laid out in. This is the area in which the content of the window
diff --git a/services/core/java/com/android/server/wm/CircularDisplayMask.java b/services/core/java/com/android/server/wm/CircularDisplayMask.java
deleted file mode 100644
index b73b481075aef..0000000000000
--- a/services/core/java/com/android/server/wm/CircularDisplayMask.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Copyright (C) 2014 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.server.wm;
-
-
-import static com.android.server.wm.WindowManagerDebugConfig.TAG_WITH_CLASS_NAME;
-import static com.android.server.wm.WindowManagerDebugConfig.TAG_WM;
-
-import android.graphics.Canvas;
-import android.graphics.Color;
-import android.graphics.Paint;
-import android.graphics.PixelFormat;
-import android.graphics.Point;
-import android.graphics.PorterDuff;
-import android.graphics.PorterDuffXfermode;
-import android.graphics.Rect;
-import android.util.Slog;
-import android.view.Display;
-import android.view.Surface;
-import android.view.Surface.OutOfResourcesException;
-import android.view.SurfaceControl;
-
-import java.util.function.Supplier;
-
-class CircularDisplayMask {
- private static final String TAG = TAG_WITH_CLASS_NAME ? "CircularDisplayMask" : TAG_WM;
-
- // size of the chin
- private int mScreenOffset = 0;
- // Display dimensions
- private Point mScreenSize;
-
- private final SurfaceControl mSurfaceControl;
- private final Surface mSurface;
- private int mLastDW;
- private int mLastDH;
- private boolean mDrawNeeded;
- private Paint mPaint;
- private int mRotation;
- private boolean mVisible;
- private boolean mDimensionsUnequal = false;
- private int mMaskThickness;
-
- CircularDisplayMask(Supplier surfaceFactory, DisplayContent dc, int zOrder,
- int screenOffset, int maskThickness, SurfaceControl.Transaction t) {
- final Display display = dc.getDisplay();
- mSurface = surfaceFactory.get();
- mScreenSize = new Point();
- display.getSize(mScreenSize);
- if (mScreenSize.x != mScreenSize.y + screenOffset) {
- Slog.w(TAG, "Screen dimensions of displayId = " + display.getDisplayId() +
- "are not equal, circularMask will not be drawn.");
- mDimensionsUnequal = true;
- }
-
- SurfaceControl ctrl = null;
- try {
- ctrl = dc.makeOverlay()
- .setName("CircularDisplayMask")
- .setBufferSize(mScreenSize.x, mScreenSize.y) // not a typo
- .setFormat(PixelFormat.TRANSLUCENT)
- .build();
-
- t.setLayerStack(ctrl, display.getLayerStack());
- t.setLayer(ctrl, zOrder);
- t.setPosition(ctrl, 0, 0);
- t.show(ctrl);
- mSurface.copyFrom(ctrl);
- } catch (OutOfResourcesException e) {
- }
- mSurfaceControl = ctrl;
- mDrawNeeded = true;
- mPaint = new Paint();
- mPaint.setAntiAlias(true);
- mPaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.CLEAR));
- mScreenOffset = screenOffset;
- mMaskThickness = maskThickness;
- }
-
- private void drawIfNeeded(SurfaceControl.Transaction t) {
- if (!mDrawNeeded || !mVisible || mDimensionsUnequal) {
- return;
- }
- mDrawNeeded = false;
-
- Rect dirty = new Rect(0, 0, mScreenSize.x, mScreenSize.y);
- Canvas c = null;
- try {
- c = mSurface.lockCanvas(dirty);
- } catch (IllegalArgumentException e) {
- } catch (Surface.OutOfResourcesException e) {
- }
- if (c == null) {
- return;
- }
- switch (mRotation) {
- case Surface.ROTATION_0:
- case Surface.ROTATION_90:
- // chin bottom or right
- t.setPosition(mSurfaceControl, 0, 0);
- break;
- case Surface.ROTATION_180:
- // chin top
- t.setPosition(mSurfaceControl, 0, -mScreenOffset);
- break;
- case Surface.ROTATION_270:
- // chin left
- t.setPosition(mSurfaceControl, -mScreenOffset, 0);
- break;
- }
-
- int circleRadius = mScreenSize.x / 2;
- c.drawColor(Color.BLACK);
-
- // The radius is reduced by mMaskThickness to provide an anti aliasing effect on the
- // display edges.
- c.drawCircle(circleRadius, circleRadius, circleRadius - mMaskThickness, mPaint);
- mSurface.unlockCanvasAndPost(c);
- }
-
- // Note: caller responsible for being inside
- // Surface.openTransaction() / closeTransaction()
- public void setVisibility(boolean on, SurfaceControl.Transaction t) {
- if (mSurfaceControl == null) {
- return;
- }
- mVisible = on;
- drawIfNeeded(t);
- if (on) {
- t.show(mSurfaceControl);
- } else {
- t.hide(mSurfaceControl);
- }
- }
-
- void positionSurface(int dw, int dh, int rotation, SurfaceControl.Transaction t) {
- if (mLastDW == dw && mLastDH == dh && mRotation == rotation) {
- return;
- }
- mLastDW = dw;
- mLastDH = dh;
- mDrawNeeded = true;
- mRotation = rotation;
- drawIfNeeded(t);
- }
-
-}
diff --git a/services/core/java/com/android/server/wm/DisplayFrames.java b/services/core/java/com/android/server/wm/DisplayFrames.java
index dc6b49127f7b4..6b47c8a820d0f 100644
--- a/services/core/java/com/android/server/wm/DisplayFrames.java
+++ b/services/core/java/com/android/server/wm/DisplayFrames.java
@@ -38,21 +38,12 @@ import java.io.PrintWriter;
public class DisplayFrames {
public final int mDisplayId;
- /**
- * The current size of the screen; really; extends into the overscan area of the screen and
- * doesn't account for any system elements like the status bar.
- */
- public final Rect mOverscan = new Rect();
-
/**
* The current visible size of the screen; really; (ir)regardless of whether the status bar can
* be hidden but not extending into the overscan area.
*/
public final Rect mUnrestricted = new Rect();
- /** Like mOverscan*, but allowed to move into the overscan region where appropriate. */
- public final Rect mRestrictedOverscan = new Rect();
-
/**
* The current size of the screen; these may be different than (0,0)-(dw,dh) if the status bar
* can't be hidden; in that case it effectively carves out that area of the display from all
@@ -109,8 +100,6 @@ public class DisplayFrames {
*/
public final Rect mDisplayCutoutSafe = new Rect();
- private final Rect mDisplayInfoOverscan = new Rect();
- private final Rect mRotatedDisplayInfoOverscan = new Rect();
public int mDisplayWidth;
public int mDisplayHeight;
@@ -125,43 +114,13 @@ public class DisplayFrames {
mDisplayWidth = info.logicalWidth;
mDisplayHeight = info.logicalHeight;
mRotation = info.rotation;
- mDisplayInfoOverscan.set(
- info.overscanLeft, info.overscanTop, info.overscanRight, info.overscanBottom);
mDisplayInfoCutout = displayCutout != null ? displayCutout : WmDisplayCutout.NO_CUTOUT;
}
public void onBeginLayout() {
- switch (mRotation) {
- case ROTATION_90:
- mRotatedDisplayInfoOverscan.left = mDisplayInfoOverscan.top;
- mRotatedDisplayInfoOverscan.top = mDisplayInfoOverscan.right;
- mRotatedDisplayInfoOverscan.right = mDisplayInfoOverscan.bottom;
- mRotatedDisplayInfoOverscan.bottom = mDisplayInfoOverscan.left;
- break;
- case ROTATION_180:
- mRotatedDisplayInfoOverscan.left = mDisplayInfoOverscan.right;
- mRotatedDisplayInfoOverscan.top = mDisplayInfoOverscan.bottom;
- mRotatedDisplayInfoOverscan.right = mDisplayInfoOverscan.left;
- mRotatedDisplayInfoOverscan.bottom = mDisplayInfoOverscan.top;
- break;
- case ROTATION_270:
- mRotatedDisplayInfoOverscan.left = mDisplayInfoOverscan.bottom;
- mRotatedDisplayInfoOverscan.top = mDisplayInfoOverscan.left;
- mRotatedDisplayInfoOverscan.right = mDisplayInfoOverscan.top;
- mRotatedDisplayInfoOverscan.bottom = mDisplayInfoOverscan.right;
- break;
- default:
- mRotatedDisplayInfoOverscan.set(mDisplayInfoOverscan);
- break;
- }
-
- mRestrictedOverscan.set(0, 0, mDisplayWidth, mDisplayHeight);
- mOverscan.set(mRestrictedOverscan);
- mSystem.set(mRestrictedOverscan);
- mUnrestricted.set(mRotatedDisplayInfoOverscan);
- mUnrestricted.right = mDisplayWidth - mUnrestricted.right;
- mUnrestricted.bottom = mDisplayHeight - mUnrestricted.bottom;
+ mUnrestricted.set(0, 0, mDisplayWidth, mDisplayHeight);
mRestricted.set(mUnrestricted);
+ mSystem.set(mUnrestricted);
mDock.set(mUnrestricted);
mContent.set(mUnrestricted);
mVoiceContent.set(mUnrestricted);
@@ -175,16 +134,16 @@ public class DisplayFrames {
if (!mDisplayCutout.getDisplayCutout().isEmpty()) {
final DisplayCutout c = mDisplayCutout.getDisplayCutout();
if (c.getSafeInsetLeft() > 0) {
- mDisplayCutoutSafe.left = mRestrictedOverscan.left + c.getSafeInsetLeft();
+ mDisplayCutoutSafe.left = mUnrestricted.left + c.getSafeInsetLeft();
}
if (c.getSafeInsetTop() > 0) {
- mDisplayCutoutSafe.top = mRestrictedOverscan.top + c.getSafeInsetTop();
+ mDisplayCutoutSafe.top = mUnrestricted.top + c.getSafeInsetTop();
}
if (c.getSafeInsetRight() > 0) {
- mDisplayCutoutSafe.right = mRestrictedOverscan.right - c.getSafeInsetRight();
+ mDisplayCutoutSafe.right = mUnrestricted.right - c.getSafeInsetRight();
}
if (c.getSafeInsetBottom() > 0) {
- mDisplayCutoutSafe.bottom = mRestrictedOverscan.bottom - c.getSafeInsetBottom();
+ mDisplayCutoutSafe.bottom = mUnrestricted.bottom - c.getSafeInsetBottom();
}
}
}
@@ -210,12 +169,8 @@ public class DisplayFrames {
dumpFrame(mSystem, "mSystem", myPrefix, pw);
dumpFrame(mContent, "mContent", myPrefix, pw);
dumpFrame(mVoiceContent, "mVoiceContent", myPrefix, pw);
- dumpFrame(mOverscan, "mOverscan", myPrefix, pw);
- dumpFrame(mRestrictedOverscan, "mRestrictedOverscan", myPrefix, pw);
dumpFrame(mRestricted, "mRestricted", myPrefix, pw);
dumpFrame(mUnrestricted, "mUnrestricted", myPrefix, pw);
- dumpFrame(mDisplayInfoOverscan, "mDisplayInfoOverscan", myPrefix, pw);
- dumpFrame(mRotatedDisplayInfoOverscan, "mRotatedDisplayInfoOverscan", myPrefix, pw);
pw.println(myPrefix + "mDisplayCutout=" + mDisplayCutout);
}
diff --git a/services/core/java/com/android/server/wm/DisplayPolicy.java b/services/core/java/com/android/server/wm/DisplayPolicy.java
index 6a6b2517e1a58..f8c1ad951fc3a 100644
--- a/services/core/java/com/android/server/wm/DisplayPolicy.java
+++ b/services/core/java/com/android/server/wm/DisplayPolicy.java
@@ -163,7 +163,6 @@ import com.android.internal.R;
import com.android.internal.annotations.GuardedBy;
import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.policy.ScreenDecorationsUtils;
-import com.android.internal.util.ScreenShapeHelper;
import com.android.internal.util.ScreenshotHelper;
import com.android.internal.util.function.TriConsumer;
import com.android.internal.view.AppearanceRegion;
@@ -294,9 +293,6 @@ public class DisplayPolicy {
private boolean mIsFreeformWindowOverlappingWithNavBar;
- /** Cached value of {@link ScreenShapeHelper#getWindowOutsetBottomPx} */
- @Px private int mWindowOutsetBottom;
-
private final StatusBarController mStatusBarController;
private final BarController mNavigationBarController;
@@ -1209,7 +1205,6 @@ public class DisplayPolicy {
* @param outContentInsets The areas covered by system windows, expressed as positive insets.
* @param outStableInsets The areas covered by stable system windows irrespective of their
* current visibility. Expressed as positive insets.
- * @param outOutsets The areas that are not real display, but we would like to treat as such.
* @param outDisplayCutout The area that has been cut away from the display.
* @return Whether to always consume the system bars.
* See {@link #areSystemBarsForcedShownLw(WindowState)}.
@@ -1217,28 +1212,11 @@ public class DisplayPolicy {
public boolean getLayoutHintLw(LayoutParams attrs, Rect taskBounds,
DisplayFrames displayFrames, boolean floatingStack, Rect outFrame,
Rect outContentInsets, Rect outStableInsets,
- Rect outOutsets, DisplayCutout.ParcelableWrapper outDisplayCutout) {
+ DisplayCutout.ParcelableWrapper outDisplayCutout) {
final int fl = PolicyControl.getWindowFlags(null, attrs);
final int pfl = attrs.privateFlags;
final int requestedSysUiVis = PolicyControl.getSystemUiVisibility(null, attrs);
final int sysUiVis = requestedSysUiVis | getImpliedSysUiFlagsForLayout(attrs);
- final int displayRotation = displayFrames.mRotation;
-
- final boolean useOutsets = outOutsets != null && shouldUseOutsets(attrs, fl);
- if (useOutsets) {
- int outset = mWindowOutsetBottom;
- if (outset > 0) {
- if (displayRotation == Surface.ROTATION_0) {
- outOutsets.bottom += outset;
- } else if (displayRotation == Surface.ROTATION_90) {
- outOutsets.right += outset;
- } else if (displayRotation == Surface.ROTATION_180) {
- outOutsets.top += outset;
- } else if (displayRotation == Surface.ROTATION_270) {
- outOutsets.left += outset;
- }
- }
- }
final boolean layoutInScreen = (fl & FLAG_LAYOUT_IN_SCREEN) != 0;
final boolean layoutInScreenAndInsetDecor = layoutInScreen
@@ -1268,8 +1246,8 @@ public class DisplayPolicy {
} else {
cf = displayFrames.mStable;
}
- } else if ((fl & FLAG_FULLSCREEN) != 0 || (fl & FLAG_LAYOUT_IN_OVERSCAN) != 0) {
- cf = displayFrames.mOverscan;
+ } else if ((fl & FLAG_FULLSCREEN) != 0) {
+ cf = displayFrames.mUnrestricted;
} else {
cf = displayFrames.mCurrent;
}
@@ -1312,11 +1290,6 @@ public class DisplayPolicy {
return impliedFlags;
}
- private static boolean shouldUseOutsets(WindowManager.LayoutParams attrs, int fl) {
- return attrs.type == TYPE_WALLPAPER || (fl & (WindowManager.LayoutParams.FLAG_FULLSCREEN
- | WindowManager.LayoutParams.FLAG_LAYOUT_IN_OVERSCAN)) != 0;
- }
-
private final Runnable mClearHideNavigationFlag = new Runnable() {
@Override
public void run() {
@@ -1482,11 +1455,9 @@ public class DisplayPolicy {
w.getWindowFrames().setFrames(displayFrames.mUnrestricted /* parentFrame */,
displayFrames.mUnrestricted /* displayFrame */,
- displayFrames.mUnrestricted /* overscanFrame */,
displayFrames.mUnrestricted /* contentFrame */,
displayFrames.mUnrestricted /* visibleFrame */, sTmpRect /* decorFrame */,
- displayFrames.mUnrestricted /* stableFrame */,
- displayFrames.mUnrestricted /* outsetFrame */);
+ displayFrames.mUnrestricted /* stableFrame */);
w.getWindowFrames().setDisplayCutout(displayFrames.mDisplayCutout);
w.computeFrameLw();
final Rect frame = w.getFrameLw();
@@ -1530,7 +1501,6 @@ public class DisplayPolicy {
displayFrames.mVoiceContent.set(dockFrame);
displayFrames.mSystem.set(dockFrame);
displayFrames.mContent.set(dockFrame);
- displayFrames.mRestrictedOverscan.set(dockFrame);
}
private boolean layoutStatusBar(DisplayFrames displayFrames, int sysui,
@@ -1544,9 +1514,9 @@ public class DisplayPolicy {
final WindowFrames windowFrames = mStatusBar.getWindowFrames();
windowFrames.setFrames(displayFrames.mUnrestricted /* parentFrame */,
displayFrames.mUnrestricted /* displayFrame */,
- displayFrames.mStable /* overscanFrame */, displayFrames.mStable /* contentFrame */,
+ displayFrames.mStable /* contentFrame */,
displayFrames.mStable /* visibleFrame */, sTmpRect /* decorFrame */,
- displayFrames.mStable /* stableFrame */, displayFrames.mStable /* outsetFrame */);
+ displayFrames.mStable /* stableFrame */);
windowFrames.setDisplayCutout(displayFrames.mDisplayCutout);
// Let the status bar determine its size.
@@ -1630,8 +1600,7 @@ public class DisplayPolicy {
mNavigationBarController.setBarShowingLw(true);
} else if (navVisible) {
mNavigationBarController.setBarShowingLw(true);
- dockFrame.bottom = displayFrames.mRestricted.bottom =
- displayFrames.mRestrictedOverscan.bottom = top;
+ dockFrame.bottom = displayFrames.mRestricted.bottom = top;
} else {
// We currently want to hide the navigation UI - unless we expanded the status bar.
mNavigationBarController.setBarShowingLw(statusBarForcesShowingNavigation);
@@ -1653,8 +1622,7 @@ public class DisplayPolicy {
mNavigationBarController.setBarShowingLw(true);
} else if (navVisible) {
mNavigationBarController.setBarShowingLw(true);
- dockFrame.right = displayFrames.mRestricted.right =
- displayFrames.mRestrictedOverscan.right = left;
+ dockFrame.right = displayFrames.mRestricted.right = left;
} else {
// We currently want to hide the navigation UI - unless we expanded the status bar.
mNavigationBarController.setBarShowingLw(statusBarForcesShowingNavigation);
@@ -1676,8 +1644,7 @@ public class DisplayPolicy {
mNavigationBarController.setBarShowingLw(true);
} else if (navVisible) {
mNavigationBarController.setBarShowingLw(true);
- dockFrame.left = displayFrames.mRestricted.left =
- displayFrames.mRestrictedOverscan.left = right;
+ dockFrame.left = displayFrames.mRestricted.left = right;
} else {
// We currently want to hide the navigation UI - unless we expanded the status bar.
mNavigationBarController.setBarShowingLw(statusBarForcesShowingNavigation);
@@ -1699,11 +1666,10 @@ public class DisplayPolicy {
// And compute the final frame.
sTmpRect.setEmpty();
mNavigationBar.getWindowFrames().setFrames(navigationFrame /* parentFrame */,
- navigationFrame /* displayFrame */, navigationFrame /* overscanFrame */,
+ navigationFrame /* displayFrame */,
displayFrames.mDisplayCutoutSafe /* contentFrame */,
navigationFrame /* visibleFrame */, sTmpRect /* decorFrame */,
- navigationFrame /* stableFrame */,
- displayFrames.mDisplayCutoutSafe /* outsetFrame */);
+ navigationFrame /* stableFrame */);
mNavigationBar.getWindowFrames().setDisplayCutout(displayFrames.mDisplayCutout);
mNavigationBar.computeFrameLw();
mNavigationBarController.setContentFrame(mNavigationBar.getContentFrameLw());
@@ -1713,7 +1679,7 @@ public class DisplayPolicy {
}
private void setAttachedWindowFrames(WindowState win, int fl, int adjust, WindowState attached,
- boolean insetDecors, Rect pf, Rect df, Rect of, Rect cf, Rect vf,
+ boolean insetDecors, Rect pf, Rect df, Rect cf, Rect vf,
DisplayFrames displayFrames) {
if (!win.isInputMethodTarget() && attached.isInputMethodTarget()) {
// Here's a special case: if the child window is not the 'dock window'
@@ -1725,29 +1691,25 @@ public class DisplayPolicy {
// compute the frames that would be appropriate without the dock.
vf.set(displayFrames.mDock);
cf.set(displayFrames.mDock);
- of.set(displayFrames.mDock);
df.set(displayFrames.mDock);
} else {
- // In case we forced the window to draw behind the navigation bar, restrict df/of to
- // DF.RestrictedOverscan to simulate old compat behavior.
+ // In case we forced the window to draw behind the navigation bar, restrict df to
+ // DF.Restricted to simulate old compat behavior.
Rect parentDisplayFrame = attached.getDisplayFrameLw();
- Rect parentOverscan = attached.getOverscanFrameLw();
final WindowManager.LayoutParams attachedAttrs = attached.mAttrs;
if ((attachedAttrs.privateFlags & PRIVATE_FLAG_FORCE_DRAW_BAR_BACKGROUNDS) != 0
&& (attachedAttrs.flags & FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS) == 0
&& (attachedAttrs.systemUiVisibility
& SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION) == 0) {
- parentOverscan = new Rect(parentOverscan);
- parentOverscan.intersect(displayFrames.mRestrictedOverscan);
parentDisplayFrame = new Rect(parentDisplayFrame);
- parentDisplayFrame.intersect(displayFrames.mRestrictedOverscan);
+ parentDisplayFrame.intersect(displayFrames.mRestricted);
}
// The effective display frame of the attached window depends on whether it is taking
// care of insetting its content. If not, we need to use the parent's content frame so
// that the entire window is positioned within that content. Otherwise we can use the
- // overscan frame and let the attached window take care of positioning its content
+ // parent display frame and let the attached window take care of positioning its content
// appropriately.
if (adjust != SOFT_INPUT_ADJUST_RESIZE) {
// Set the content frame of the attached window to the parent's decor frame
@@ -1755,7 +1717,7 @@ public class DisplayPolicy {
// setting {@link WindowManager.LayoutParams#FLAG_LAYOUT_ATTACHED_IN_DECOR} flag.
// Otherwise, use the overscan frame.
cf.set((fl & FLAG_LAYOUT_ATTACHED_IN_DECOR) != 0
- ? attached.getContentFrameLw() : parentOverscan);
+ ? attached.getContentFrameLw() : parentDisplayFrame);
} else {
// If the window is resizing, then we want to base the content frame on our attached
// content frame to resize...however, things can be tricky if the attached window is
@@ -1770,7 +1732,6 @@ public class DisplayPolicy {
}
}
df.set(insetDecors ? parentDisplayFrame : cf);
- of.set(insetDecors ? parentOverscan : cf);
vf.set(attached.getVisibleFrameLw());
}
// The LAYOUT_IN_SCREEN flag is used to determine whether the attached window should be
@@ -1820,7 +1781,6 @@ public class DisplayPolicy {
return;
}
final WindowManager.LayoutParams attrs = win.getAttrs();
- final boolean isDefaultDisplay = win.isDefaultDisplay();
final int type = attrs.type;
final int fl = PolicyControl.getWindowFlags(win, attrs);
@@ -1831,11 +1791,9 @@ public class DisplayPolicy {
final WindowFrames windowFrames = win.getWindowFrames();
- windowFrames.setHasOutsets(false);
sTmpLastParentFrame.set(windowFrames.mParentFrame);
final Rect pf = windowFrames.mParentFrame;
final Rect df = windowFrames.mDisplayFrame;
- final Rect of = windowFrames.mOverscanFrame;
final Rect cf = windowFrames.mContentFrame;
final Rect vf = windowFrames.mVisibleFrame;
final Rect dcf = windowFrames.mDecorFrame;
@@ -1860,21 +1818,20 @@ public class DisplayPolicy {
if (type == TYPE_INPUT_METHOD) {
vf.set(displayFrames.mDock);
cf.set(displayFrames.mDock);
- of.set(displayFrames.mDock);
df.set(displayFrames.mDock);
windowFrames.mParentFrame.set(displayFrames.mDock);
// IM dock windows layout below the nav bar...
- pf.bottom = df.bottom = of.bottom = displayFrames.mUnrestricted.bottom;
+ pf.bottom = df.bottom = displayFrames.mUnrestricted.bottom;
// ...with content insets above the nav bar
cf.bottom = vf.bottom = displayFrames.mStable.bottom;
if (mStatusBar != null && mFocusedWindow == mStatusBar && canReceiveInput(mStatusBar)) {
// The status bar forces the navigation bar while it's visible. Make sure the IME
// avoids the navigation bar in that case.
if (mNavigationBarPosition == NAV_BAR_RIGHT) {
- pf.right = df.right = of.right = cf.right = vf.right =
+ pf.right = df.right = cf.right = vf.right =
displayFrames.mStable.right;
} else if (mNavigationBarPosition == NAV_BAR_LEFT) {
- pf.left = df.left = of.left = cf.left = vf.left = displayFrames.mStable.left;
+ pf.left = df.left = cf.left = vf.left = displayFrames.mStable.left;
}
}
@@ -1897,7 +1854,6 @@ public class DisplayPolicy {
// IM dock windows always go to the bottom of the screen.
attrs.gravity = Gravity.BOTTOM;
} else if (type == TYPE_VOICE_INTERACTION) {
- of.set(displayFrames.mUnrestricted);
df.set(displayFrames.mUnrestricted);
pf.set(displayFrames.mUnrestricted);
if (adjust != SOFT_INPUT_ADJUST_RESIZE) {
@@ -1911,9 +1867,8 @@ public class DisplayPolicy {
vf.set(cf);
}
} else if (type == TYPE_WALLPAPER) {
- layoutWallpaper(displayFrames, pf, df, of, cf);
+ layoutWallpaper(displayFrames, pf, df, cf);
} else if (win == mStatusBar) {
- of.set(displayFrames.mUnrestricted);
df.set(displayFrames.mUnrestricted);
pf.set(displayFrames.mUnrestricted);
cf.set(displayFrames.mStable);
@@ -1967,7 +1922,7 @@ public class DisplayPolicy {
if (attached != null) {
// If this window is attached to another, our display
// frame is the same as the one we are attached to.
- setAttachedWindowFrames(win, fl, adjust, attached, true, pf, df, of, cf, vf,
+ setAttachedWindowFrames(win, fl, adjust, attached, true, pf, df, cf, vf,
displayFrames);
} else {
if (type == TYPE_STATUS_BAR_PANEL || type == TYPE_STATUS_BAR_SUB_PANEL) {
@@ -1977,24 +1932,17 @@ public class DisplayPolicy {
//
// However, they should still dodge the navigation bar if it exists.
- pf.left = df.left = of.left = hasNavBar
+ pf.left = df.left = hasNavBar
? displayFrames.mDock.left : displayFrames.mUnrestricted.left;
- pf.top = df.top = of.top = displayFrames.mUnrestricted.top;
- pf.right = df.right = of.right = hasNavBar
+ pf.top = df.top = displayFrames.mUnrestricted.top;
+ pf.right = df.right = hasNavBar
? displayFrames.mRestricted.right
: displayFrames.mUnrestricted.right;
- pf.bottom = df.bottom = of.bottom = hasNavBar
+ pf.bottom = df.bottom = hasNavBar
? displayFrames.mRestricted.bottom
: displayFrames.mUnrestricted.bottom;
if (DEBUG_LAYOUT) Slog.v(TAG, "Laying out status bar window: " + pf);
- } else if ((fl & FLAG_LAYOUT_IN_OVERSCAN) != 0
- && type >= FIRST_APPLICATION_WINDOW && type <= LAST_SUB_WINDOW) {
- // Asking to layout into the overscan region, so give it that pure
- // unrestricted area.
- of.set(displayFrames.mOverscan);
- df.set(displayFrames.mOverscan);
- pf.set(displayFrames.mOverscan);
} else if ((sysUiFl & SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION) != 0
&& (type >= FIRST_APPLICATION_WINDOW && type <= LAST_SUB_WINDOW
|| type == TYPE_VOLUME_OVERLAY
@@ -2003,19 +1951,11 @@ public class DisplayPolicy {
// extend into the unrestricted overscan screen area. We only do this for
// application windows and certain system windows to ensure no window that
// can be above the nav bar can do this.
- df.set(displayFrames.mOverscan);
- pf.set(displayFrames.mOverscan);
- // We need to tell the app about where the frame inside the overscan is, so
- // it can inset its content by that amount -- it didn't ask to actually
- // extend itself into the overscan region.
- of.set(displayFrames.mUnrestricted);
+ df.set(displayFrames.mUnrestricted);
+ pf.set(displayFrames.mUnrestricted);
} else {
- df.set(displayFrames.mRestrictedOverscan);
- pf.set(displayFrames.mRestrictedOverscan);
- // We need to tell the app about where the frame inside the overscan
- // is, so it can inset its content by that amount -- it didn't ask
- // to actually extend itself into the overscan region.
- of.set(displayFrames.mUnrestricted);
+ df.set(displayFrames.mRestricted);
+ pf.set(displayFrames.mRestricted);
}
if ((fl & FLAG_FULLSCREEN) == 0) {
@@ -2053,19 +1993,17 @@ public class DisplayPolicy {
// gets everything, period.
if (type == TYPE_STATUS_BAR_PANEL || type == TYPE_STATUS_BAR_SUB_PANEL) {
cf.set(displayFrames.mUnrestricted);
- of.set(displayFrames.mUnrestricted);
df.set(displayFrames.mUnrestricted);
pf.set(displayFrames.mUnrestricted);
if (hasNavBar) {
- pf.left = df.left = of.left = cf.left = displayFrames.mDock.left;
- pf.right = df.right = of.right = cf.right = displayFrames.mRestricted.right;
- pf.bottom = df.bottom = of.bottom = cf.bottom =
+ pf.left = df.left = cf.left = displayFrames.mDock.left;
+ pf.right = df.right = cf.right = displayFrames.mRestricted.right;
+ pf.bottom = df.bottom = cf.bottom =
displayFrames.mRestricted.bottom;
}
if (DEBUG_LAYOUT) Slog.v(TAG, "Laying out IN_SCREEN status bar window: " + pf);
} else if (type == TYPE_NAVIGATION_BAR || type == TYPE_NAVIGATION_BAR_PANEL) {
// The navigation bar has Real Ultimate Power.
- of.set(displayFrames.mUnrestricted);
df.set(displayFrames.mUnrestricted);
pf.set(displayFrames.mUnrestricted);
if (DEBUG_LAYOUT) Slog.v(TAG, "Laying out navigation bar window: " + pf);
@@ -2073,24 +2011,14 @@ public class DisplayPolicy {
&& ((fl & FLAG_FULLSCREEN) != 0)) {
// Fullscreen secure system overlays get what they ask for. Screenshot region
// selection overlay should also expand to full screen.
- cf.set(displayFrames.mOverscan);
- of.set(displayFrames.mOverscan);
- df.set(displayFrames.mOverscan);
- pf.set(displayFrames.mOverscan);
+ cf.set(displayFrames.mUnrestricted);
+ df.set(displayFrames.mUnrestricted);
+ pf.set(displayFrames.mUnrestricted);
} else if (type == TYPE_BOOT_PROGRESS) {
// Boot progress screen always covers entire display.
- cf.set(displayFrames.mOverscan);
- of.set(displayFrames.mOverscan);
- df.set(displayFrames.mOverscan);
- pf.set(displayFrames.mOverscan);
- } else if ((fl & FLAG_LAYOUT_IN_OVERSCAN) != 0
- && type >= FIRST_APPLICATION_WINDOW && type <= LAST_SUB_WINDOW) {
- // Asking to layout into the overscan region, so give it that pure unrestricted
- // area.
- cf.set(displayFrames.mOverscan);
- of.set(displayFrames.mOverscan);
- df.set(displayFrames.mOverscan);
- pf.set(displayFrames.mOverscan);
+ cf.set(displayFrames.mUnrestricted);
+ df.set(displayFrames.mUnrestricted);
+ pf.set(displayFrames.mUnrestricted);
} else if ((sysUiFl & SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION) != 0
&& (type == TYPE_STATUS_BAR
|| type == TYPE_TOAST
@@ -2105,11 +2033,9 @@ public class DisplayPolicy {
// ask for layout in only content. We can't currently figure out
// what the screen would be if only laying out to hide the nav bar.
cf.set(displayFrames.mUnrestricted);
- of.set(displayFrames.mUnrestricted);
df.set(displayFrames.mUnrestricted);
pf.set(displayFrames.mUnrestricted);
} else if ((sysUiFl & View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN) != 0) {
- of.set(displayFrames.mRestricted);
df.set(displayFrames.mRestricted);
pf.set(displayFrames.mRestricted);
@@ -2123,7 +2049,6 @@ public class DisplayPolicy {
}
} else {
cf.set(displayFrames.mRestricted);
- of.set(displayFrames.mRestricted);
df.set(displayFrames.mRestricted);
pf.set(displayFrames.mRestricted);
}
@@ -2140,7 +2065,7 @@ public class DisplayPolicy {
+ "): attached to " + attached);
// A child window should be placed inside of the same visible
// frame that its parent had.
- setAttachedWindowFrames(win, fl, adjust, attached, false, pf, df, of, cf, vf,
+ setAttachedWindowFrames(win, fl, adjust, attached, false, pf, df, cf, vf,
displayFrames);
} else {
if (DEBUG_LAYOUT) Slog.v(TAG, "layoutWindowLw(" + attrs.getTitle()
@@ -2152,28 +2077,23 @@ public class DisplayPolicy {
// top of the status bar. They are protected by the STATUS_BAR_SERVICE
// permission, so they have the same privileges as the status bar itself.
cf.set(displayFrames.mRestricted);
- of.set(displayFrames.mRestricted);
df.set(displayFrames.mRestricted);
pf.set(displayFrames.mRestricted);
} else if (type == TYPE_TOAST || type == TYPE_SYSTEM_ALERT) {
// These dialogs are stable to interim decor changes.
cf.set(displayFrames.mStable);
- of.set(displayFrames.mStable);
df.set(displayFrames.mStable);
pf.set(displayFrames.mStable);
} else {
pf.set(displayFrames.mContent);
if (win.isVoiceInteraction()) {
cf.set(displayFrames.mVoiceContent);
- of.set(displayFrames.mVoiceContent);
df.set(displayFrames.mVoiceContent);
} else if (adjust != SOFT_INPUT_ADJUST_RESIZE) {
cf.set(displayFrames.mDock);
- of.set(displayFrames.mDock);
df.set(displayFrames.mDock);
} else {
cf.set(displayFrames.mContent);
- of.set(displayFrames.mContent);
df.set(displayFrames.mContent);
}
if (adjust != SOFT_INPUT_ADJUST_NOTHING) {
@@ -2252,34 +2172,8 @@ public class DisplayPolicy {
df.left = df.top = -10000;
df.right = df.bottom = 10000;
if (type != TYPE_WALLPAPER) {
- of.left = of.top = cf.left = cf.top = vf.left = vf.top = -10000;
- of.right = of.bottom = cf.right = cf.bottom = vf.right = vf.bottom = 10000;
- }
- }
-
- // If the device has a chin (e.g. some watches), a dead area at the bottom of the screen we
- // need to provide information to the clients that want to pretend that you can draw there.
- // We only want to apply outsets to certain types of windows. For example, we never want to
- // apply the outsets to floating dialogs, because they wouldn't make sense there.
- final boolean useOutsets = shouldUseOutsets(attrs, fl);
- if (isDefaultDisplay && useOutsets) {
- final Rect osf = windowFrames.mOutsetFrame;
- osf.set(cf.left, cf.top, cf.right, cf.bottom);
- windowFrames.setHasOutsets(true);
- int outset = mWindowOutsetBottom;
- if (outset > 0) {
- int rotation = displayFrames.mRotation;
- if (rotation == Surface.ROTATION_0) {
- osf.bottom += outset;
- } else if (rotation == Surface.ROTATION_90) {
- osf.right += outset;
- } else if (rotation == Surface.ROTATION_180) {
- osf.top -= outset;
- } else if (rotation == Surface.ROTATION_270) {
- osf.left -= outset;
- }
- if (DEBUG_LAYOUT) Slog.v(TAG, "applying bottom outset of " + outset
- + " with rotation " + rotation + ", result: " + osf);
+ cf.left = cf.top = vf.left = vf.top = -10000;
+ cf.right = cf.bottom = vf.right = vf.bottom = 10000;
}
}
@@ -2288,11 +2182,9 @@ public class DisplayPolicy {
+ " attach=" + attached + " type=" + type
+ String.format(" flags=0x%08x", fl)
+ " pf=" + pf.toShortString() + " df=" + df.toShortString()
- + " of=" + of.toShortString()
+ " cf=" + cf.toShortString() + " vf=" + vf.toShortString()
+ " dcf=" + dcf.toShortString()
- + " sf=" + sf.toShortString()
- + " osf=" + windowFrames.mOutsetFrame.toShortString() + " " + win);
+ + " sf=" + sf.toShortString());
if (!sTmpLastParentFrame.equals(pf)) {
windowFrames.setContentChanged(true);
@@ -2311,12 +2203,11 @@ public class DisplayPolicy {
}
}
- private void layoutWallpaper(DisplayFrames displayFrames, Rect pf, Rect df, Rect of, Rect cf) {
- // The wallpaper has Real Ultimate Power, but we want to tell it about the overscan area.
- df.set(displayFrames.mOverscan);
- pf.set(displayFrames.mOverscan);
+ private void layoutWallpaper(DisplayFrames displayFrames, Rect pf, Rect df, Rect cf) {
+ // The wallpaper has Real Ultimate Power
+ df.set(displayFrames.mUnrestricted);
+ pf.set(displayFrames.mUnrestricted);
cf.set(displayFrames.mUnrestricted);
- of.set(displayFrames.mUnrestricted);
}
private void offsetInputMethodWindowLw(WindowState win, DisplayFrames displayFrames) {
@@ -2722,7 +2613,6 @@ public class DisplayPolicy {
- getNavigationBarFrameHeight(portraitRotation, uiMode);
updateConfigurationAndScreenSizeDependentBehaviors();
- mWindowOutsetBottom = ScreenShapeHelper.getWindowOutsetBottomPx(mContext.getResources());
}
void updateConfigurationAndScreenSizeDependentBehaviors() {
diff --git a/services/core/java/com/android/server/wm/DisplayWindowSettings.java b/services/core/java/com/android/server/wm/DisplayWindowSettings.java
index 8507918df480b..dac8b14c8ff14 100644
--- a/services/core/java/com/android/server/wm/DisplayWindowSettings.java
+++ b/services/core/java/com/android/server/wm/DisplayWindowSettings.java
@@ -100,10 +100,6 @@ class DisplayWindowSettings {
private static class Entry {
private final String mName;
- private int mOverscanLeft;
- private int mOverscanTop;
- private int mOverscanRight;
- private int mOverscanBottom;
private int mWindowingMode = WindowConfiguration.WINDOWING_MODE_UNDEFINED;
private int mUserRotationMode = WindowManagerPolicy.USER_ROTATION_FREE;
private int mUserRotation = Surface.ROTATION_0;
@@ -124,10 +120,6 @@ class DisplayWindowSettings {
private Entry(String name, Entry copyFrom) {
this(name);
- mOverscanLeft = copyFrom.mOverscanLeft;
- mOverscanTop = copyFrom.mOverscanTop;
- mOverscanRight = copyFrom.mOverscanRight;
- mOverscanBottom = copyFrom.mOverscanBottom;
mWindowingMode = copyFrom.mWindowingMode;
mUserRotationMode = copyFrom.mUserRotationMode;
mUserRotation = copyFrom.mUserRotation;
@@ -144,9 +136,7 @@ class DisplayWindowSettings {
/** @return {@code true} if all values are default. */
private boolean isEmpty() {
- return mOverscanLeft == 0 && mOverscanTop == 0 && mOverscanRight == 0
- && mOverscanBottom == 0
- && mWindowingMode == WindowConfiguration.WINDOWING_MODE_UNDEFINED
+ return mWindowingMode == WindowConfiguration.WINDOWING_MODE_UNDEFINED
&& mUserRotationMode == WindowManagerPolicy.USER_ROTATION_FREE
&& mUserRotation == Surface.ROTATION_0
&& mForcedWidth == 0 && mForcedHeight == 0 && mForcedDensity == 0
@@ -202,15 +192,6 @@ class DisplayWindowSettings {
return newEntry;
}
- void setOverscanLocked(DisplayInfo displayInfo, int left, int top, int right, int bottom) {
- final Entry entry = getOrCreateEntry(displayInfo);
- entry.mOverscanLeft = left;
- entry.mOverscanTop = top;
- entry.mOverscanRight = right;
- entry.mOverscanBottom = bottom;
- writeSettingsIfNeeded(entry, displayInfo);
- }
-
void setUserRotation(DisplayContent displayContent, int rotationMode, int rotation) {
final DisplayInfo displayInfo = displayContent.getDisplayInfo();
final Entry entry = getOrCreateEntry(displayInfo);
@@ -405,11 +386,6 @@ class DisplayWindowSettings {
// Setting windowing mode first, because it may override overscan values later.
dc.setWindowingMode(getWindowingModeLocked(entry, dc.getDisplayId()));
- displayInfo.overscanLeft = entry.mOverscanLeft;
- displayInfo.overscanTop = entry.mOverscanTop;
- displayInfo.overscanRight = entry.mOverscanRight;
- displayInfo.overscanBottom = entry.mOverscanBottom;
-
dc.getDisplayRotation().restoreSettings(entry.mUserRotationMode,
entry.mUserRotation, entry.mFixedToUserRotation);
@@ -536,10 +512,6 @@ class DisplayWindowSettings {
String name = parser.getAttributeValue(null, "name");
if (name != null) {
Entry entry = new Entry(name);
- entry.mOverscanLeft = getIntAttribute(parser, "overscanLeft");
- entry.mOverscanTop = getIntAttribute(parser, "overscanTop");
- entry.mOverscanRight = getIntAttribute(parser, "overscanRight");
- entry.mOverscanBottom = getIntAttribute(parser, "overscanBottom");
entry.mWindowingMode = getIntAttribute(parser, "windowingMode",
WindowConfiguration.WINDOWING_MODE_UNDEFINED);
entry.mUserRotationMode = getIntAttribute(parser, "userRotationMode",
@@ -602,18 +574,6 @@ class DisplayWindowSettings {
for (Entry entry : mEntries.values()) {
out.startTag(null, "display");
out.attribute(null, "name", entry.mName);
- if (entry.mOverscanLeft != 0) {
- out.attribute(null, "overscanLeft", Integer.toString(entry.mOverscanLeft));
- }
- if (entry.mOverscanTop != 0) {
- out.attribute(null, "overscanTop", Integer.toString(entry.mOverscanTop));
- }
- if (entry.mOverscanRight != 0) {
- out.attribute(null, "overscanRight", Integer.toString(entry.mOverscanRight));
- }
- if (entry.mOverscanBottom != 0) {
- out.attribute(null, "overscanBottom", Integer.toString(entry.mOverscanBottom));
- }
if (entry.mWindowingMode != WindowConfiguration.WINDOWING_MODE_UNDEFINED) {
out.attribute(null, "windowingMode", Integer.toString(entry.mWindowingMode));
}
diff --git a/services/core/java/com/android/server/wm/RootWindowContainer.java b/services/core/java/com/android/server/wm/RootWindowContainer.java
index 149bcfb991eab..63b11ffe158d7 100644
--- a/services/core/java/com/android/server/wm/RootWindowContainer.java
+++ b/services/core/java/com/android/server/wm/RootWindowContainer.java
@@ -818,10 +818,6 @@ class RootWindowContainer extends WindowContainer
if (mWmService.mStrictModeFlash != null) {
mWmService.mStrictModeFlash.positionSurface(defaultDw, defaultDh, mDisplayTransaction);
}
- if (mWmService.mCircularDisplayMask != null) {
- mWmService.mCircularDisplayMask.positionSurface(defaultDw, defaultDh,
- mWmService.getDefaultDisplayRotation(), mDisplayTransaction);
- }
if (mWmService.mEmulatorDisplayOverlay != null) {
mWmService.mEmulatorDisplayOverlay.positionSurface(defaultDw, defaultDh,
mWmService.getDefaultDisplayRotation(), mDisplayTransaction);
diff --git a/services/core/java/com/android/server/wm/Session.java b/services/core/java/com/android/server/wm/Session.java
index 96be7cc416bd0..265ca91e1d211 100644
--- a/services/core/java/com/android/server/wm/Session.java
+++ b/services/core/java/com/android/server/wm/Session.java
@@ -155,11 +155,11 @@ class Session extends IWindowSession.Stub implements IBinder.DeathRecipient {
@Override
public int addToDisplay(IWindow window, int seq, WindowManager.LayoutParams attrs,
int viewVisibility, int displayId, Rect outFrame, Rect outContentInsets,
- Rect outStableInsets, Rect outOutsets,
+ Rect outStableInsets,
DisplayCutout.ParcelableWrapper outDisplayCutout, InputChannel outInputChannel,
InsetsState outInsetsState) {
return mService.addWindow(this, window, seq, attrs, viewVisibility, displayId, outFrame,
- outContentInsets, outStableInsets, outOutsets, outDisplayCutout, outInputChannel,
+ outContentInsets, outStableInsets, outDisplayCutout, outInputChannel,
outInsetsState);
}
@@ -168,7 +168,7 @@ class Session extends IWindowSession.Stub implements IBinder.DeathRecipient {
int viewVisibility, int displayId, Rect outContentInsets, Rect outStableInsets,
InsetsState outInsetsState) {
return mService.addWindow(this, window, seq, attrs, viewVisibility, displayId,
- new Rect() /* outFrame */, outContentInsets, outStableInsets, null /* outOutsets */,
+ new Rect() /* outFrame */, outContentInsets, outStableInsets,
new DisplayCutout.ParcelableWrapper() /* cutout */, null /* outInputChannel */,
outInsetsState);
}
@@ -186,8 +186,8 @@ class Session extends IWindowSession.Stub implements IBinder.DeathRecipient {
@Override
public int relayout(IWindow window, int seq, WindowManager.LayoutParams attrs,
int requestedWidth, int requestedHeight, int viewFlags, int flags, long frameNumber,
- Rect outFrame, Rect outOverscanInsets, Rect outContentInsets, Rect outVisibleInsets,
- Rect outStableInsets, Rect outsets, Rect outBackdropFrame,
+ Rect outFrame, Rect outContentInsets, Rect outVisibleInsets,
+ Rect outStableInsets, Rect outBackdropFrame,
DisplayCutout.ParcelableWrapper cutout, MergedConfiguration mergedConfiguration,
SurfaceControl outSurfaceControl, InsetsState outInsetsState) {
if (false) Slog.d(TAG_WM, ">>>>>> ENTERED relayout from "
@@ -195,8 +195,8 @@ class Session extends IWindowSession.Stub implements IBinder.DeathRecipient {
Trace.traceBegin(TRACE_TAG_WINDOW_MANAGER, mRelayoutTag);
int res = mService.relayoutWindow(this, window, seq, attrs,
requestedWidth, requestedHeight, viewFlags, flags, frameNumber,
- outFrame, outOverscanInsets, outContentInsets, outVisibleInsets,
- outStableInsets, outsets, outBackdropFrame, cutout,
+ outFrame, outContentInsets, outVisibleInsets,
+ outStableInsets, outBackdropFrame, cutout,
mergedConfiguration, outSurfaceControl, outInsetsState);
Trace.traceEnd(TRACE_TAG_WINDOW_MANAGER);
if (false) Slog.d(TAG_WM, "<<<<<< EXITING relayout to "
diff --git a/services/core/java/com/android/server/wm/TaskSnapshotSurface.java b/services/core/java/com/android/server/wm/TaskSnapshotSurface.java
index b1e5c8f7f5ee1..b3750e95fb36b 100644
--- a/services/core/java/com/android/server/wm/TaskSnapshotSurface.java
+++ b/services/core/java/com/android/server/wm/TaskSnapshotSurface.java
@@ -209,7 +209,7 @@ class TaskSnapshotSurface implements StartingSurface {
try {
final int res = session.addToDisplay(window, window.mSeq, layoutParams,
View.GONE, activity.getDisplayContent().getDisplayId(), tmpFrame, tmpRect, tmpRect,
- tmpRect, tmpCutout, null, mTmpInsetsState);
+ tmpCutout, null, mTmpInsetsState);
if (res < 0) {
Slog.w(TAG, "Failed to add snapshot starting window res=" + res);
return null;
@@ -224,7 +224,7 @@ class TaskSnapshotSurface implements StartingSurface {
window.setOuter(snapshotSurface);
try {
session.relayout(window, window.mSeq, layoutParams, -1, -1, View.VISIBLE, 0, -1,
- tmpFrame, tmpRect, tmpContentInsets, tmpRect, tmpStableInsets, tmpRect, tmpRect,
+ tmpFrame, tmpContentInsets, tmpRect, tmpStableInsets, tmpRect,
tmpCutout, tmpMergedConfiguration, surfaceControl, mTmpInsetsState);
} catch (RemoteException e) {
// Local call.
@@ -466,8 +466,8 @@ class TaskSnapshotSurface implements StartingSurface {
}
@Override
- public void resized(Rect frame, Rect overscanInsets, Rect contentInsets, Rect visibleInsets,
- Rect stableInsets, Rect outsets, boolean reportDraw,
+ public void resized(Rect frame, Rect contentInsets, Rect visibleInsets,
+ Rect stableInsets, boolean reportDraw,
MergedConfiguration mergedConfiguration, Rect backDropFrame, boolean forceLayout,
boolean alwaysConsumeSystemBars, int displayId,
DisplayCutout.ParcelableWrapper displayCutout) {
diff --git a/services/core/java/com/android/server/wm/WindowFrames.java b/services/core/java/com/android/server/wm/WindowFrames.java
index 9fe47604d7041..70fc19470f831 100644
--- a/services/core/java/com/android/server/wm/WindowFrames.java
+++ b/services/core/java/com/android/server/wm/WindowFrames.java
@@ -23,10 +23,6 @@ import static com.android.server.wm.WindowFramesProto.CUTOUT;
import static com.android.server.wm.WindowFramesProto.DECOR_FRAME;
import static com.android.server.wm.WindowFramesProto.DISPLAY_FRAME;
import static com.android.server.wm.WindowFramesProto.FRAME;
-import static com.android.server.wm.WindowFramesProto.OUTSETS;
-import static com.android.server.wm.WindowFramesProto.OUTSET_FRAME;
-import static com.android.server.wm.WindowFramesProto.OVERSCAN_FRAME;
-import static com.android.server.wm.WindowFramesProto.OVERSCAN_INSETS;
import static com.android.server.wm.WindowFramesProto.PARENT_FRAME;
import static com.android.server.wm.WindowFramesProto.STABLE_INSETS;
import static com.android.server.wm.WindowFramesProto.VISIBLE_FRAME;
@@ -69,14 +65,6 @@ public class WindowFrames {
*/
public final Rect mDisplayFrame = new Rect();
- /**
- * The region of the display frame that the display type supports displaying content on. This
- * is mostly a special case for TV where some displays don’t have the entire display usable.
- * {@link android.view.WindowManager.LayoutParams#FLAG_LAYOUT_IN_OVERSCAN} flag can be used to
- * allow window display contents to extend into the overscan region.
- */
- public final Rect mOverscanFrame = new Rect();
-
/**
* Legacy stuff. Generally equal to the content frame expect when the IME for older apps
* displays hint text.
@@ -101,12 +89,6 @@ public class WindowFrames {
*/
public final Rect mStableFrame = new Rect();
- /**
- * Frame that includes dead area outside of the surface but where we want to pretend that it's
- * possible to draw.
- */
- final public Rect mOutsetFrame = new Rect();
-
/**
* Similar to {@link #mDisplayFrame}
*
@@ -147,14 +129,6 @@ public class WindowFrames {
private boolean mDisplayCutoutChanged;
- /**
- * Insets that determine the area covered by the display overscan region. These are in the
- * application's coordinate space (without compatibility scale applied).
- */
- final Rect mOverscanInsets = new Rect();
- final Rect mLastOverscanInsets = new Rect();
- private boolean mOverscanInsetsChanged;
-
/**
* Insets that determine the area covered by the stable system windows. These are in the
* application's coordinate space (without compatibility scale applied).
@@ -163,14 +137,6 @@ public class WindowFrames {
final Rect mLastStableInsets = new Rect();
private boolean mStableInsetsChanged;
- /**
- * Outsets determine the area outside of the surface where we want to pretend that it's possible
- * to draw anyway.
- */
- final Rect mOutsets = new Rect();
- final Rect mLastOutsets = new Rect();
- private boolean mOutsetsChanged = false;
-
/**
* Insets that determine the actually visible area. These are in the application's
* coordinate space (without compatibility scale applied).
@@ -190,30 +156,25 @@ public class WindowFrames {
private final Rect mTmpRect = new Rect();
- private boolean mHasOutsets;
-
private boolean mContentChanged;
public WindowFrames() {
}
- public WindowFrames(Rect parentFrame, Rect displayFrame, Rect overscanFrame, Rect contentFrame,
- Rect visibleFrame, Rect decorFrame, Rect stableFrame, Rect outsetFrame) {
- setFrames(parentFrame, displayFrame, overscanFrame, contentFrame, visibleFrame, decorFrame,
- stableFrame, outsetFrame);
+ public WindowFrames(Rect parentFrame, Rect displayFrame, Rect contentFrame,
+ Rect visibleFrame, Rect decorFrame, Rect stableFrame) {
+ setFrames(parentFrame, displayFrame, contentFrame, visibleFrame, decorFrame,
+ stableFrame);
}
- public void setFrames(Rect parentFrame, Rect displayFrame, Rect overscanFrame,
- Rect contentFrame, Rect visibleFrame, Rect decorFrame, Rect stableFrame,
- Rect outsetFrame) {
+ public void setFrames(Rect parentFrame, Rect displayFrame,
+ Rect contentFrame, Rect visibleFrame, Rect decorFrame, Rect stableFrame) {
mParentFrame.set(parentFrame);
mDisplayFrame.set(displayFrame);
- mOverscanFrame.set(overscanFrame);
mContentFrame.set(contentFrame);
mVisibleFrame.set(visibleFrame);
mDecorFrame.set(decorFrame);
mStableFrame.set(stableFrame);
- mOutsetFrame.set(outsetFrame);
}
public void setParentFrameWasClippedByDisplayCutout(
@@ -236,17 +197,6 @@ public class WindowFrames {
return (mLastFrame.width() != mFrame.width()) || (mLastFrame.height() != mFrame.height());
}
- /**
- * Calculates the outsets for this windowFrame. The outsets are calculated by the area between
- * the {@link #mOutsetFrame} and the {@link #mContentFrame}. If there are no outsets, then
- * {@link #mOutsets} is set to empty.
- */
- void calculateOutsets() {
- if (mHasOutsets) {
- InsetUtils.insetsBetweenFrames(mOutsetFrame, mContentFrame, mOutsets);
- }
- }
-
/**
* Calculate the insets for the type
* {@link android.view.WindowManager.LayoutParams#TYPE_DOCK_DIVIDER}
@@ -301,11 +251,9 @@ public class WindowFrames {
* @param scale The amount to scale the insets by.
*/
void scaleInsets(float scale) {
- mOverscanInsets.scale(scale);
mContentInsets.scale(scale);
mVisibleInsets.scale(scale);
mStableInsets.scale(scale);
- mOutsets.scale(scale);
}
void offsetFrames(int layoutXDiff, int layoutYDiff) {
@@ -321,15 +269,13 @@ public class WindowFrames {
* @return true if info about size has changed since last reported.
*/
boolean setReportResizeHints() {
- mOverscanInsetsChanged |= !mLastOverscanInsets.equals(mOverscanInsets);
mContentInsetsChanged |= !mLastContentInsets.equals(mContentInsets);
mVisibleInsetsChanged |= !mLastVisibleInsets.equals(mVisibleInsets);
mStableInsetsChanged |= !mLastStableInsets.equals(mStableInsets);
- mOutsetsChanged |= !mLastOutsets.equals(mOutsets);
mFrameSizeChanged |= didFrameSizeChange();
mDisplayCutoutChanged |= !mLastDisplayCutout.equals(mDisplayCutout);
- return mOverscanInsetsChanged || mContentInsetsChanged || mVisibleInsetsChanged
- || mStableInsetsChanged || mOutsetsChanged || mFrameSizeChanged
+ return mContentInsetsChanged || mVisibleInsetsChanged
+ || mStableInsetsChanged || mFrameSizeChanged
|| mDisplayCutoutChanged;
}
@@ -338,11 +284,9 @@ public class WindowFrames {
* after the insets are reported to client.
*/
void resetInsetsChanged() {
- mOverscanInsetsChanged = false;
mContentInsetsChanged = false;
mVisibleInsetsChanged = false;
mStableInsetsChanged = false;
- mOutsetsChanged = false;
mFrameSizeChanged = false;
mDisplayCutoutChanged = false;
}
@@ -351,11 +295,9 @@ public class WindowFrames {
* Copy over inset values as the last insets that were sent to the client.
*/
void updateLastInsetValues() {
- mLastOverscanInsets.set(mOverscanInsets);
mLastContentInsets.set(mContentInsets);
mLastVisibleInsets.set(mVisibleInsets);
mLastStableInsets.set(mStableInsets);
- mLastOutsets.set(mOutsets);
mLastDisplayCutout = mDisplayCutout;
}
@@ -367,19 +309,6 @@ public class WindowFrames {
mLastContentInsets.set(-1, -1, -1, -1);
}
- /**
- * Sets whether the frame has outsets.
- */
- public void setHasOutsets(boolean hasOutsets) {
- if (mHasOutsets == hasOutsets) {
- return;
- }
- mHasOutsets = hasOutsets;
- if (!hasOutsets) {
- mOutsets.setEmpty();
- }
- }
-
/**
* Sets whether the content has changed. This means that either the size or parent frame has
* changed.
@@ -400,18 +329,14 @@ public class WindowFrames {
mParentFrame.writeToProto(proto, PARENT_FRAME);
mContentFrame.writeToProto(proto, CONTENT_FRAME);
mDisplayFrame.writeToProto(proto, DISPLAY_FRAME);
- mOverscanFrame.writeToProto(proto, OVERSCAN_FRAME);
mVisibleFrame.writeToProto(proto, VISIBLE_FRAME);
mDecorFrame.writeToProto(proto, DECOR_FRAME);
- mOutsetFrame.writeToProto(proto, OUTSET_FRAME);
mContainingFrame.writeToProto(proto, CONTAINING_FRAME);
mFrame.writeToProto(proto, FRAME);
mDisplayCutout.getDisplayCutout().writeToProto(proto, CUTOUT);
mContentInsets.writeToProto(proto, CONTENT_INSETS);
- mOverscanInsets.writeToProto(proto, OVERSCAN_INSETS);
mVisibleInsets.writeToProto(proto, VISIBLE_INSETS);
mStableInsets.writeToProto(proto, STABLE_INSETS);
- mOutsets.writeToProto(proto, OUTSETS);
proto.end(token);
}
@@ -420,33 +345,26 @@ public class WindowFrames {
pw.println(prefix + "Frames: containing="
+ mContainingFrame.toShortString(sTmpSB)
+ " parent=" + mParentFrame.toShortString(sTmpSB));
- pw.println(prefix + " display=" + mDisplayFrame.toShortString(sTmpSB)
- + " overscan=" + mOverscanFrame.toShortString(sTmpSB));
+ pw.println(prefix + " display=" + mDisplayFrame.toShortString(sTmpSB));
pw.println(prefix + " content=" + mContentFrame.toShortString(sTmpSB)
+ " visible=" + mVisibleFrame.toShortString(sTmpSB));
pw.println(prefix + " decor=" + mDecorFrame.toShortString(sTmpSB));
- pw.println(prefix + " outset=" + mOutsetFrame.toShortString(sTmpSB));
pw.println(prefix + "mFrame=" + mFrame.toShortString(sTmpSB)
+ " last=" + mLastFrame.toShortString(sTmpSB));
pw.println(prefix + " cutout=" + mDisplayCutout.getDisplayCutout()
+ " last=" + mLastDisplayCutout.getDisplayCutout());
- pw.print(prefix + "Cur insets: overscan=" + mOverscanInsets.toShortString(sTmpSB)
- + " content=" + mContentInsets.toShortString(sTmpSB)
+ pw.print(prefix + "Cur insets: content=" + mContentInsets.toShortString(sTmpSB)
+ " visible=" + mVisibleInsets.toShortString(sTmpSB)
- + " stable=" + mStableInsets.toShortString(sTmpSB)
- + " outsets=" + mOutsets.toShortString(sTmpSB));
- pw.println(prefix + "Lst insets: overscan=" + mLastOverscanInsets.toShortString(sTmpSB)
- + " content=" + mLastContentInsets.toShortString(sTmpSB)
+ + " stable=" + mStableInsets.toShortString(sTmpSB));
+ pw.println(prefix + "Lst insets: content=" + mLastContentInsets.toShortString(sTmpSB)
+ " visible=" + mLastVisibleInsets.toShortString(sTmpSB)
- + " stable=" + mLastStableInsets.toShortString(sTmpSB)
- + " outset=" + mLastOutsets.toShortString(sTmpSB));
+ + " stable=" + mLastStableInsets.toShortString(sTmpSB));
}
String getInsetsInfo() {
return "ci=" + mContentInsets.toShortString()
+ " vi=" + mVisibleInsets.toShortString()
- + " si=" + mStableInsets.toShortString()
- + " of=" + mOutsets.toShortString();
+ + " si=" + mStableInsets.toShortString();
}
String getInsetsChangedInfo() {
@@ -456,8 +374,6 @@ public class WindowFrames {
+ " " + mVisibleInsets.toShortString()
+ " stableInsetsChanged=" + mStableInsetsChanged
+ " " + mStableInsets.toShortString()
- + " outsetsChanged=" + mOutsetsChanged
- + " " + mOutsets.toShortString()
+ " displayCutoutChanged=" + mDisplayCutoutChanged;
}
}
diff --git a/services/core/java/com/android/server/wm/WindowManagerService.java b/services/core/java/com/android/server/wm/WindowManagerService.java
index fc8705bbaae63..649f347f50042 100644
--- a/services/core/java/com/android/server/wm/WindowManagerService.java
+++ b/services/core/java/com/android/server/wm/WindowManagerService.java
@@ -591,7 +591,6 @@ public class WindowManagerService extends IWindowManager.Stub
Watermark mWatermark;
StrictModeFlash mStrictModeFlash;
- CircularDisplayMask mCircularDisplayMask;
EmulatorDisplayOverlay mEmulatorDisplayOverlay;
final float[] mTmpFloats = new float[9];
@@ -760,11 +759,6 @@ public class WindowManagerService extends IWindowManager.Stub
return;
}
- if (mDisplayInversionEnabledUri.equals(uri)) {
- updateCircularDisplayMaskIfNeeded();
- return;
- }
-
if (mPointerLocationUri.equals(uri)) {
updatePointerLocation();
return;
@@ -1332,7 +1326,7 @@ public class WindowManagerService extends IWindowManager.Stub
public int addWindow(Session session, IWindow client, int seq,
LayoutParams attrs, int viewVisibility, int displayId, Rect outFrame,
- Rect outContentInsets, Rect outStableInsets, Rect outOutsets,
+ Rect outContentInsets, Rect outStableInsets,
DisplayCutout.ParcelableWrapper outDisplayCutout, InputChannel outInputChannel,
InsetsState outInsetsState) {
int[] appOp = new int[1];
@@ -1684,7 +1678,7 @@ public class WindowManagerService extends IWindowManager.Stub
floatingStack = false;
}
if (displayPolicy.getLayoutHintLw(win.mAttrs, taskBounds, displayFrames, floatingStack,
- outFrame, outContentInsets, outStableInsets, outOutsets, outDisplayCutout)) {
+ outFrame, outContentInsets, outStableInsets, outDisplayCutout)) {
res |= WindowManagerGlobal.ADD_FLAG_ALWAYS_CONSUME_SYSTEM_BARS;
}
outInsetsState.set(displayContent.getInsetsPolicy().getInsetsForDispatch(win));
@@ -2087,8 +2081,8 @@ public class WindowManagerService extends IWindowManager.Stub
public int relayoutWindow(Session session, IWindow client, int seq, LayoutParams attrs,
int requestedWidth, int requestedHeight, int viewVisibility, int flags,
- long frameNumber, Rect outFrame, Rect outOverscanInsets, Rect outContentInsets,
- Rect outVisibleInsets, Rect outStableInsets, Rect outOutsets, Rect outBackdropFrame,
+ long frameNumber, Rect outFrame, Rect outContentInsets,
+ Rect outVisibleInsets, Rect outStableInsets, Rect outBackdropFrame,
DisplayCutout.ParcelableWrapper outCutout, MergedConfiguration mergedConfiguration,
SurfaceControl outSurfaceControl, InsetsState outInsetsState) {
int result = 0;
@@ -2380,8 +2374,8 @@ public class WindowManagerService extends IWindowManager.Stub
win.updateLastInsetValues();
win.getCompatFrame(outFrame);
- win.getInsetsForRelayout(outOverscanInsets, outContentInsets, outVisibleInsets,
- outStableInsets, outOutsets);
+ win.getInsetsForRelayout(outContentInsets, outVisibleInsets,
+ outStableInsets);
outCutout.set(win.getWmDisplayCutout().getDisplayCutout());
outBackdropFrame.set(win.getBackdropFrame(win.getFrameLw()));
outInsetsState.set(displayContent.getInsetsPolicy().getInsetsForDispatch(win));
@@ -3428,26 +3422,6 @@ public class WindowManagerService extends IWindowManager.Stub
}
}
- private void updateCircularDisplayMaskIfNeeded() {
- if (mContext.getResources().getConfiguration().isScreenRound()
- && mContext.getResources().getBoolean(
- com.android.internal.R.bool.config_windowShowCircularMask)) {
- final int currentUserId;
- synchronized (mGlobalLock) {
- currentUserId = mCurrentUserId;
- }
- // Device configuration calls for a circular display mask, but we only enable the mask
- // if the accessibility color inversion feature is disabled, as the inverted mask
- // causes artifacts.
- int inversionState = Settings.Secure.getIntForUser(mContext.getContentResolver(),
- Settings.Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED, 0, currentUserId);
- int showMask = (inversionState == 1) ? 0 : 1;
- Message m = mH.obtainMessage(H.SHOW_CIRCULAR_DISPLAY_MASK);
- m.arg1 = showMask;
- mH.sendMessage(m);
- }
- }
-
public void showEmulatorDisplayOverlayIfNeeded() {
if (mContext.getResources().getBoolean(
com.android.internal.R.bool.config_windowEnableCircularEmulatorDisplayOverlay)
@@ -3457,35 +3431,6 @@ public class WindowManagerService extends IWindowManager.Stub
}
}
- public void showCircularMask(boolean visible) {
- synchronized (mGlobalLock) {
- if (visible) {
- // TODO(multi-display): support multiple displays
- if (mCircularDisplayMask == null) {
- int screenOffset = mContext.getResources().getInteger(
- com.android.internal.R.integer.config_windowOutsetBottom);
- int maskThickness = mContext.getResources().getDimensionPixelSize(
- com.android.internal.R.dimen.circular_display_mask_thickness);
-
-
- if (SHOW_LIGHT_TRANSACTIONS) {
- Slog.i(TAG_WM,
- ">>> showCircularMask(visible=" + visible + ")");
- }
- mCircularDisplayMask = new CircularDisplayMask(mSurfaceFactory,
- getDefaultDisplayContentLocked(), mPolicy.getWindowLayerFromTypeLw(
- WindowManager.LayoutParams.TYPE_POINTER) * TYPE_LAYER_MULTIPLIER
- + 10, screenOffset, maskThickness, mTransaction);
- }
- mCircularDisplayMask.setVisibility(true, mTransaction);
- } else if (mCircularDisplayMask != null) {
- mCircularDisplayMask.setVisibility(false, mTransaction);
- mCircularDisplayMask = null;
- }
- mTransaction.apply();
- }
- }
-
public void showEmulatorDisplayOverlay() {
synchronized (mGlobalLock) {
@@ -4436,8 +4381,6 @@ public class WindowManagerService extends IWindowManager.Stub
mActivityTaskManager.updateConfiguration(null);
} catch (RemoteException e) {
}
-
- updateCircularDisplayMaskIfNeeded();
}
public void systemReady() {
@@ -4520,7 +4463,6 @@ public class WindowManagerService extends IWindowManager.Stub
public static final int NEW_ANIMATOR_SCALE = 34;
- public static final int SHOW_CIRCULAR_DISPLAY_MASK = 35;
public static final int SHOW_EMULATOR_DISPLAY_OVERLAY = 36;
public static final int CHECK_IF_BOOT_ANIMATION_FINISHED = 37;
@@ -4754,11 +4696,6 @@ public class WindowManagerService extends IWindowManager.Stub
break;
}
- case SHOW_CIRCULAR_DISPLAY_MASK: {
- showCircularMask(msg.arg1 == 1);
- break;
- }
-
case SHOW_EMULATOR_DISPLAY_OVERLAY: {
showEmulatorDisplayOverlay();
break;
@@ -5167,38 +5104,6 @@ public class WindowManagerService extends IWindowManager.Stub
return 0;
}
- @Override
- public void setOverscan(int displayId, int left, int top, int right, int bottom) {
- if (mContext.checkCallingOrSelfPermission(WRITE_SECURE_SETTINGS)
- != PackageManager.PERMISSION_GRANTED) {
- throw new SecurityException("Must hold permission " + WRITE_SECURE_SETTINGS);
- }
- final long ident = Binder.clearCallingIdentity();
- try {
- synchronized (mGlobalLock) {
- DisplayContent displayContent = mRoot.getDisplayContent(displayId);
- if (displayContent != null) {
- setOverscanLocked(displayContent, left, top, right, bottom);
- }
- }
- } finally {
- Binder.restoreCallingIdentity(ident);
- }
- }
-
- private void setOverscanLocked(DisplayContent displayContent,
- int left, int top, int right, int bottom) {
- final DisplayInfo displayInfo = displayContent.getDisplayInfo();
- displayInfo.overscanLeft = left;
- displayInfo.overscanTop = top;
- displayInfo.overscanRight = right;
- displayInfo.overscanBottom = bottom;
-
- mDisplayWindowSettings.setOverscanLocked(displayInfo, left, top, right, bottom);
-
- displayContent.reconfigureDisplayLocked();
- }
-
@Override
public void startWindowTrace(){
mWindowTracing.startTrace(null /* printwriter */);
diff --git a/services/core/java/com/android/server/wm/WindowManagerShellCommand.java b/services/core/java/com/android/server/wm/WindowManagerShellCommand.java
index e01cbf26dadc0..8e955cf3a8bbf 100644
--- a/services/core/java/com/android/server/wm/WindowManagerShellCommand.java
+++ b/services/core/java/com/android/server/wm/WindowManagerShellCommand.java
@@ -66,8 +66,6 @@ public class WindowManagerShellCommand extends ShellCommand {
return runDisplayDensity(pw);
case "folded-area":
return runDisplayFoldedArea(pw);
- case "overscan":
- return runDisplayOverscan(pw);
case "scaling":
return runDisplayScaling(pw);
case "dismiss-keyguard":
@@ -247,30 +245,6 @@ public class WindowManagerShellCommand extends ShellCommand {
return 0;
}
- private int runDisplayOverscan(PrintWriter pw) throws RemoteException {
- String overscanStr = getNextArgRequired();
- Rect rect = new Rect();
- final int displayId = getDisplayId(overscanStr);
- if ("reset".equals(overscanStr)) {
- rect.set(0, 0, 0, 0);
- } else {
- final Pattern FLATTENED_PATTERN = Pattern.compile(
- "(-?\\d+),(-?\\d+),(-?\\d+),(-?\\d+)");
- Matcher matcher = FLATTENED_PATTERN.matcher(overscanStr);
- if (!matcher.matches()) {
- getErrPrintWriter().println("Error: bad rectangle arg: " + overscanStr);
- return -1;
- }
- rect.left = Integer.parseInt(matcher.group(1));
- rect.top = Integer.parseInt(matcher.group(2));
- rect.right = Integer.parseInt(matcher.group(3));
- rect.bottom = Integer.parseInt(matcher.group(4));
- }
-
- mInterface.setOverscan(displayId, rect.left, rect.top, rect.right, rect.bottom);
- return 0;
- }
-
private int runDisplayScaling(PrintWriter pw) throws RemoteException {
String scalingStr = getNextArgRequired();
if ("auto".equals(scalingStr)) {
@@ -380,8 +354,6 @@ public class WindowManagerShellCommand extends ShellCommand {
pw.println(" Return or override display density.");
pw.println(" folded-area [reset|LEFT,TOP,RIGHT,BOTTOM]");
pw.println(" Return or override folded area.");
- pw.println(" overscan [reset|LEFT,TOP,RIGHT,BOTTOM] [-d DISPLAY ID]");
- pw.println(" Set overscan area for display.");
pw.println(" scaling [off|auto] [-d DISPLAY_ID]");
pw.println(" Set display scaling mode.");
pw.println(" dismiss-keyguard");
diff --git a/services/core/java/com/android/server/wm/WindowState.java b/services/core/java/com/android/server/wm/WindowState.java
index d5905720a6117..62a3512c3cae0 100644
--- a/services/core/java/com/android/server/wm/WindowState.java
+++ b/services/core/java/com/android/server/wm/WindowState.java
@@ -1047,9 +1047,6 @@ class WindowState extends WindowContainer implements WindowManagerP
applyGravityAndUpdateFrame(layoutContainingFrame, layoutDisplayFrame);
- // Calculate the outsets before the content frame gets shrinked to the window frame.
- mWindowFrames.calculateOutsets();
-
// Make sure the content and visible frames are inside of the
// final window frame.
if (windowsAreFloating && !mWindowFrames.mFrame.isEmpty()) {
@@ -1094,13 +1091,6 @@ class WindowState extends WindowContainer implements WindowManagerP
Math.min(mWindowFrames.mStableFrame.bottom, mWindowFrames.mFrame.bottom));
}
- if (isFullscreenAndFillsDisplay && !windowsAreFloating) {
- // Windows that are not fullscreen can be positioned outside of the display frame,
- // but that is not a reason to provide them with overscan insets.
- InsetUtils.insetsBetweenFrames(layoutContainingFrame, mWindowFrames.mOverscanFrame,
- mWindowFrames.mOverscanInsets);
- }
-
if (mAttrs.type == TYPE_DOCK_DIVIDER) {
final WmDisplayCutout c = mWindowFrames.mDisplayCutout.calculateRelativeTo(
mWindowFrames.mDisplayFrame);
@@ -1169,11 +1159,6 @@ class WindowState extends WindowContainer implements WindowManagerP
return mWindowFrames.mDisplayFrame;
}
- @Override
- public Rect getOverscanFrameLw() {
- return mWindowFrames.mOverscanFrame;
- }
-
@Override
public Rect getContentFrameLw() {
return mWindowFrames.mContentFrame;
@@ -3265,11 +3250,9 @@ class WindowState extends WindowContainer implements WindowManagerP
}
final Rect frame = mWindowFrames.mCompatFrame;
- final Rect overscanInsets = mWindowFrames.mLastOverscanInsets;
final Rect contentInsets = mWindowFrames.mLastContentInsets;
final Rect visibleInsets = mWindowFrames.mLastVisibleInsets;
final Rect stableInsets = mWindowFrames.mLastStableInsets;
- final Rect outsets = mWindowFrames.mLastOutsets;
final boolean reportDraw = mWinAnimator.mDrawState == DRAW_PENDING;
final boolean reportOrientation = mReportOrientationChanged;
final int displayId = getDisplayId();
@@ -3281,8 +3264,8 @@ class WindowState extends WindowContainer implements WindowManagerP
@Override
public void run() {
try {
- dispatchResized(frame, overscanInsets, contentInsets, visibleInsets,
- stableInsets, outsets, reportDraw, mergedConfiguration,
+ dispatchResized(frame, contentInsets, visibleInsets,
+ stableInsets, reportDraw, mergedConfiguration,
reportOrientation, displayId, displayCutout);
} catch (RemoteException e) {
// Not a remote call, RemoteException won't be raised.
@@ -3290,8 +3273,8 @@ class WindowState extends WindowContainer implements WindowManagerP
}
});
} else {
- dispatchResized(frame, overscanInsets, contentInsets, visibleInsets, stableInsets,
- outsets, reportDraw, mergedConfiguration, reportOrientation, displayId,
+ dispatchResized(frame, contentInsets, visibleInsets, stableInsets,
+ reportDraw, mergedConfiguration, reportOrientation, displayId,
displayCutout);
}
if (mWmService.mAccessibilityController != null) {
@@ -3423,14 +3406,14 @@ class WindowState extends WindowContainer implements WindowManagerP
return stack.mStackId;
}
- private void dispatchResized(Rect frame, Rect overscanInsets, Rect contentInsets,
- Rect visibleInsets, Rect stableInsets, Rect outsets, boolean reportDraw,
+ private void dispatchResized(Rect frame, Rect contentInsets,
+ Rect visibleInsets, Rect stableInsets, boolean reportDraw,
MergedConfiguration mergedConfiguration, boolean reportOrientation, int displayId,
DisplayCutout displayCutout)
throws RemoteException {
final boolean forceRelayout = isDragResizeChanged() || reportOrientation;
- mClient.resized(frame, overscanInsets, contentInsets, visibleInsets, stableInsets, outsets,
+ mClient.resized(frame, contentInsets, visibleInsets, stableInsets,
reportDraw, mergedConfiguration, getBackdropFrame(frame), forceRelayout,
getDisplayContent().getDisplayPolicy().areSystemBarsForcedShownLw(this), displayId,
new DisplayCutout.ParcelableWrapper(displayCutout));
@@ -5282,13 +5265,11 @@ class WindowState extends WindowContainer implements WindowManagerP
/**
* Copy the inset values over so they can be sent back to the client when a relayout occurs.
*/
- void getInsetsForRelayout(Rect outOverscanInsets, Rect outContentInsets, Rect outVisibleInsets,
- Rect outStableInsets, Rect outOutsets) {
- outOverscanInsets.set(mWindowFrames.mOverscanInsets);
+ void getInsetsForRelayout(Rect outContentInsets, Rect outVisibleInsets,
+ Rect outStableInsets) {
outContentInsets.set(mWindowFrames.mContentInsets);
outVisibleInsets.set(mWindowFrames.mVisibleInsets);
outStableInsets.set(mWindowFrames.mStableInsets);
- outOutsets.set(mWindowFrames.mOutsets);
mLastRelayoutContentInsets.set(mWindowFrames.mContentInsets);
}
diff --git a/services/tests/wmtests/src/com/android/server/wm/DisplayPolicyLayoutTests.java b/services/tests/wmtests/src/com/android/server/wm/DisplayPolicyLayoutTests.java
index 67b7a66b4794e..62ab11c5a18f3 100644
--- a/services/tests/wmtests/src/com/android/server/wm/DisplayPolicyLayoutTests.java
+++ b/services/tests/wmtests/src/com/android/server/wm/DisplayPolicyLayoutTests.java
@@ -515,18 +515,16 @@ public class DisplayPolicyLayoutTests extends DisplayPolicyTestsBase {
final Rect outFrame = new Rect();
final Rect outContentInsets = new Rect();
final Rect outStableInsets = new Rect();
- final Rect outOutsets = new Rect();
final DisplayCutout.ParcelableWrapper outDisplayCutout =
new DisplayCutout.ParcelableWrapper();
mDisplayPolicy.getLayoutHintLw(mWindow.mAttrs, null, mFrames,
false /* floatingStack */, outFrame, outContentInsets, outStableInsets,
- outOutsets, outDisplayCutout);
+ outDisplayCutout);
assertThat(outFrame, is(mFrames.mUnrestricted));
assertThat(outContentInsets, is(new Rect(0, STATUS_BAR_HEIGHT, 0, NAV_BAR_HEIGHT)));
assertThat(outStableInsets, is(new Rect(0, STATUS_BAR_HEIGHT, 0, NAV_BAR_HEIGHT)));
- assertThat(outOutsets, is(new Rect()));
assertThat(outDisplayCutout, is(new DisplayCutout.ParcelableWrapper()));
}
@@ -540,18 +538,16 @@ public class DisplayPolicyLayoutTests extends DisplayPolicyTestsBase {
final Rect outFrame = new Rect();
final Rect outContentInsets = new Rect();
final Rect outStableInsets = new Rect();
- final Rect outOutsets = new Rect();
final DisplayCutout.ParcelableWrapper outDisplayCutout =
new DisplayCutout.ParcelableWrapper();
mDisplayPolicy.getLayoutHintLw(mWindow.mAttrs, taskBounds, mFrames,
false /* floatingStack */, outFrame, outContentInsets, outStableInsets,
- outOutsets, outDisplayCutout);
+ outDisplayCutout);
assertThat(outFrame, is(taskBounds));
assertThat(outContentInsets, is(new Rect()));
assertThat(outStableInsets, is(new Rect()));
- assertThat(outOutsets, is(new Rect()));
assertThat(outDisplayCutout, is(new DisplayCutout.ParcelableWrapper()));
}
@@ -568,18 +564,16 @@ public class DisplayPolicyLayoutTests extends DisplayPolicyTestsBase {
final Rect outFrame = new Rect();
final Rect outContentInsets = new Rect();
final Rect outStableInsets = new Rect();
- final Rect outOutsets = new Rect();
final DisplayCutout.ParcelableWrapper outDisplayCutout =
new DisplayCutout.ParcelableWrapper();
mDisplayPolicy.getLayoutHintLw(mWindow.mAttrs, taskBounds, mFrames,
true /* floatingStack */, outFrame, outContentInsets, outStableInsets,
- outOutsets, outDisplayCutout);
+ outDisplayCutout);
assertThat(outFrame, is(taskBounds));
assertThat(outContentInsets, is(new Rect()));
assertThat(outStableInsets, is(new Rect()));
- assertThat(outOutsets, is(new Rect()));
assertThat(outDisplayCutout, is(new DisplayCutout.ParcelableWrapper()));
}
diff --git a/services/tests/wmtests/src/com/android/server/wm/DisplayWindowSettingsTests.java b/services/tests/wmtests/src/com/android/server/wm/DisplayWindowSettingsTests.java
index 703ebc9370820..e375f8344cb4d 100644
--- a/services/tests/wmtests/src/com/android/server/wm/DisplayWindowSettingsTests.java
+++ b/services/tests/wmtests/src/com/android/server/wm/DisplayWindowSettingsTests.java
@@ -276,47 +276,6 @@ public class DisplayWindowSettingsTests extends WindowTestsBase {
assertFalse(mSecondaryDisplay.mDisplayScalingDisabled);
}
- @Test
- public void testDefaultToZeroOverscan() {
- mTarget.applySettingsToDisplayLocked(mPrimaryDisplay);
-
- assertOverscan(mPrimaryDisplay, 0 /* left */, 0 /* top */, 0 /* right */, 0 /* bottom */);
- }
-
- @Test
- public void testPersistOverscanInSameInstance() {
- final DisplayInfo info = mPrimaryDisplay.getDisplayInfo();
- try {
- mTarget.setOverscanLocked(info, 1 /* left */, 2 /* top */, 3 /* right */,
- 4 /* bottom */);
-
- mTarget.applySettingsToDisplayLocked(mPrimaryDisplay);
-
- assertOverscan(mPrimaryDisplay, 1 /* left */, 2 /* top */, 3 /* right */,
- 4 /* bottom */);
- } finally {
- mTarget.setOverscanLocked(info, 0, 0, 0, 0);
- mTarget.applySettingsToDisplayLocked(mPrimaryDisplay);
- }
- }
-
- @Test
- public void testPersistOverscanAcrossInstances() {
- final DisplayInfo info = mPrimaryDisplay.getDisplayInfo();
- try {
- mTarget.setOverscanLocked(info, 10 /* left */, 20 /* top */, 30 /* right */,
- 40 /* bottom */);
-
- applySettingsToDisplayByNewInstance(mPrimaryDisplay);
-
- assertOverscan(mPrimaryDisplay, 10 /* left */, 20 /* top */, 30 /* right */,
- 40 /* bottom */);
- } finally {
- mTarget.setOverscanLocked(info, 0, 0, 0, 0);
- mTarget.applySettingsToDisplayLocked(mPrimaryDisplay);
- }
- }
-
@Test
public void testDefaultToFreeUserRotation() {
mTarget.applySettingsToDisplayLocked(mSecondaryDisplay);
@@ -690,16 +649,6 @@ public class DisplayWindowSettingsTests extends WindowTestsBase {
return null;
}
- private static void assertOverscan(DisplayContent display, int left, int top, int right,
- int bottom) {
- final DisplayInfo info = display.getDisplayInfo();
-
- assertEquals(left, info.overscanLeft);
- assertEquals(top, info.overscanTop);
- assertEquals(right, info.overscanRight);
- assertEquals(bottom, info.overscanBottom);
- }
-
/**
* This method helps to ensure read and write persistent settings successfully because the
* constructor of {@link DisplayWindowSettings} should read the persistent file from the given
diff --git a/services/tests/wmtests/src/com/android/server/wm/TestIWindow.java b/services/tests/wmtests/src/com/android/server/wm/TestIWindow.java
index 6a9413716a89c..e1475a4533303 100644
--- a/services/tests/wmtests/src/com/android/server/wm/TestIWindow.java
+++ b/services/tests/wmtests/src/com/android/server/wm/TestIWindow.java
@@ -37,8 +37,8 @@ public class TestIWindow extends IWindow.Stub {
}
@Override
- public void resized(Rect frame, Rect overscanInsets, Rect contentInsets, Rect visibleInsets,
- Rect stableInsets, Rect outsets, boolean reportDraw, MergedConfiguration mergedConfig,
+ public void resized(Rect frame, Rect contentInsets, Rect visibleInsets,
+ Rect stableInsets, boolean reportDraw, MergedConfiguration mergedConfig,
Rect backDropFrame, boolean forceLayout, boolean alwaysConsumeSystemBars, int displayId,
DisplayCutout.ParcelableWrapper displayCutout) throws RemoteException {
}
diff --git a/services/tests/wmtests/src/com/android/server/wm/WindowFrameTests.java b/services/tests/wmtests/src/com/android/server/wm/WindowFrameTests.java
index 428d869fe3cd1..0b8b6a1f23ecf 100644
--- a/services/tests/wmtests/src/com/android/server/wm/WindowFrameTests.java
+++ b/services/tests/wmtests/src/com/android/server/wm/WindowFrameTests.java
@@ -150,7 +150,7 @@ public class WindowFrameTests extends WindowTestsBase {
// When mFrame extends past cf, the content insets are
// the difference between mFrame and ContentFrame. Visible
// and stable frames work the same way.
- w.getWindowFrames().setFrames(pf, df, of, cf, vf, dcf, sf, mEmptyRect);
+ w.getWindowFrames().setFrames(pf, df, cf, vf, dcf, sf);
w.computeFrameLw();
assertFrame(w, 0, 0, 1000, 1000);
assertContentInset(w, 0, topContentInset, 0, bottomContentInset);
@@ -186,7 +186,7 @@ public class WindowFrameTests extends WindowTestsBase {
// Here the window has FILL_PARENT, FILL_PARENT
// so we expect it to fill the entire available frame.
- w.getWindowFrames().setFrames(pf, pf, pf, pf, pf, pf, pf, pf);
+ w.getWindowFrames().setFrames(pf, pf, pf, pf, pf, pf);
w.computeFrameLw();
assertFrame(w, 0, 0, 1000, 1000);
@@ -274,7 +274,7 @@ public class WindowFrameTests extends WindowTestsBase {
final Rect pf = new Rect(0, 0, logicalWidth, logicalHeight);
final WindowFrames windowFrames = w.getWindowFrames();
- windowFrames.setFrames(pf, pf, pf, pf, pf, pf, pf, mEmptyRect);
+ windowFrames.setFrames(pf, pf, pf, pf, pf, pf);
w.computeFrameLw();
// For non fullscreen tasks the containing frame is based off the
// task bounds not the parent frame.
@@ -287,7 +287,7 @@ public class WindowFrameTests extends WindowTestsBase {
final int cfRight = logicalWidth / 2;
final int cfBottom = logicalHeight / 2;
final Rect cf = new Rect(0, 0, cfRight, cfBottom);
- windowFrames.setFrames(pf, pf, pf, cf, cf, pf, cf, mEmptyRect);
+ windowFrames.setFrames(pf, pf, cf, cf, pf, cf);
w.computeFrameLw();
assertEquals(resolvedTaskBounds, w.getFrameLw());
int contentInsetRight = resolvedTaskBounds.right - cfRight;
@@ -306,7 +306,7 @@ public class WindowFrameTests extends WindowTestsBase {
final int insetBottom = insetTop + (resolvedTaskBounds.bottom - resolvedTaskBounds.top);
task.setOverrideDisplayedBounds(resolvedTaskBounds);
task.setBounds(insetLeft, insetTop, insetRight, insetBottom);
- windowFrames.setFrames(pf, pf, pf, cf, cf, pf, cf, mEmptyRect);
+ windowFrames.setFrames(pf, pf, cf, cf, pf, cf);
w.computeFrameLw();
assertEquals(resolvedTaskBounds, w.getFrameLw());
contentInsetRight = insetRight - cfRight;
@@ -328,7 +328,6 @@ public class WindowFrameTests extends WindowTestsBase {
final int logicalHeight = displayInfo.logicalHeight;
final Rect pf = new Rect(0, 0, logicalWidth, logicalHeight);
final Rect df = pf;
- final Rect of = df;
final Rect cf = new Rect(pf);
// Produce some insets
cf.top += displayInfo.logicalWidth / 10;
@@ -339,7 +338,7 @@ public class WindowFrameTests extends WindowTestsBase {
Rect dcf = new Rect(cf);
final WindowFrames windowFrames = w.getWindowFrames();
- windowFrames.setFrames(pf, df, of, cf, vf, dcf, sf, mEmptyRect);
+ windowFrames.setFrames(pf, df, cf, vf, dcf, sf);
w.computeFrameLw();
assertPolicyCrop(w, 0, cf.top, logicalWidth, cf.bottom);
@@ -353,7 +352,7 @@ public class WindowFrameTests extends WindowTestsBase {
// we need to account for the fact the windows surface will be made
// fullscreen and thus also make the crop fullscreen.
- windowFrames.setFrames(pf, pf, pf, pf, pf, pf, pf, pf);
+ windowFrames.setFrames(pf, pf, pf, pf, pf, pf);
w.mAttrs.gravity = Gravity.LEFT | Gravity.TOP;
w.mAttrs.width = logicalWidth / 2;
w.mAttrs.height = logicalHeight / 2;
@@ -395,7 +394,7 @@ public class WindowFrameTests extends WindowTestsBase {
final Rect pf = new Rect(0, 0, logicalWidth, logicalHeight);
final WindowFrames windowFrames = w.getWindowFrames();
- windowFrames.setFrames(pf, pf, pf, pf, pf, pf, pf, mEmptyRect);
+ windowFrames.setFrames(pf, pf, pf, pf, pf, pf);
w.computeFrameLw();
// For non fullscreen tasks the containing frame is based off the
// task bounds not the parent frame.
@@ -413,7 +412,7 @@ public class WindowFrameTests extends WindowTestsBase {
pf.set(0, 0, logicalWidth, logicalHeight);
task.setWindowingMode(WINDOWING_MODE_FULLSCREEN);
task.setBounds(null);
- windowFrames.setFrames(pf, pf, pf, cf, cf, pf, cf, mEmptyRect);
+ windowFrames.setFrames(pf, pf, cf, cf, pf, cf);
w.computeFrameLw();
assertFrame(w, cf);
assertContentFrame(w, cf);
@@ -434,7 +433,7 @@ public class WindowFrameTests extends WindowTestsBase {
pf.width(), pf.height());
final WindowFrames windowFrames = w.getWindowFrames();
- windowFrames.setFrames(pf, pf, pf, pf, pf, pf, pf, pf);
+ windowFrames.setFrames(pf, pf, pf, pf, pf, pf);
windowFrames.setDisplayCutout(cutout);
w.computeFrameLw();
@@ -461,7 +460,7 @@ public class WindowFrameTests extends WindowTestsBase {
pf.width(), pf.height());
final WindowFrames windowFrames = w.getWindowFrames();
- windowFrames.setFrames(pf, pf, pf, pf, pf, pf, pf, pf);
+ windowFrames.setFrames(pf, pf, pf, pf, pf, pf);
windowFrames.setDisplayCutout(cutout);
w.computeFrameLw();
@@ -501,7 +500,7 @@ public class WindowFrameTests extends WindowTestsBase {
final Rect winRect = new Rect(200, 200, 300, 500);
task.setBounds(winRect);
- w.getWindowFrames().setFrames(pf, df, of, cf, vf, dcf, sf, mEmptyRect);
+ w.getWindowFrames().setFrames(pf, df, cf, vf, dcf, sf);
w.computeFrameLw();
final Rect expected = new Rect(winRect.left, cf.bottom - winRect.height(),
@@ -514,7 +513,7 @@ public class WindowFrameTests extends WindowTestsBase {
winRect.bottom = 600;
task.setBounds(winRect);
w.setBounds(winRect);
- w.getWindowFrames().setFrames(pf, df, of, cf, vf, dcf, sf, mEmptyRect);
+ w.getWindowFrames().setFrames(pf, df, cf, vf, dcf, sf);
w.computeFrameLw();
assertFrame(w, winRect.left, 0, winRect.right, winRect.height());
@@ -524,7 +523,7 @@ public class WindowFrameTests extends WindowTestsBase {
assertVisibleFrame(w, expected);
// Check that it's moved back without ime insets
- w.getWindowFrames().setFrames(pf, df, of, pf, pf, dcf, sf, mEmptyRect);
+ w.getWindowFrames().setFrames(pf, df, pf, pf, dcf, sf);
w.computeFrameLw();
assertEquals(winRect, w.getFrameLw());
}
diff --git a/tests/WindowManagerStressTest/Android.bp b/tests/WindowManagerStressTest/Android.bp
deleted file mode 100644
index 98749a7e45126..0000000000000
--- a/tests/WindowManagerStressTest/Android.bp
+++ /dev/null
@@ -1,21 +0,0 @@
-//
-// Copyright (C) 2016 The Android Open Source Project
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-android_test {
- name: "WindowManagerStressTest",
- srcs: ["**/*.java"],
- platform_apis: true,
-}
diff --git a/tests/WindowManagerStressTest/AndroidManifest.xml b/tests/WindowManagerStressTest/AndroidManifest.xml
deleted file mode 100644
index 17e0f15c29a9b..0000000000000
--- a/tests/WindowManagerStressTest/AndroidManifest.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/tests/WindowManagerStressTest/res/layout/activity_main.xml b/tests/WindowManagerStressTest/res/layout/activity_main.xml
deleted file mode 100644
index 6cf82691155c2..0000000000000
--- a/tests/WindowManagerStressTest/res/layout/activity_main.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/tests/WindowManagerStressTest/res/mipmap-hdpi/ic_launcher.png b/tests/WindowManagerStressTest/res/mipmap-hdpi/ic_launcher.png
deleted file mode 100644
index cde69bcccec65160d92116f20ffce4fce0b5245c..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 3418
zcmZ{nX*|@A^T0p5j$I+^%FVhdvMbgt%d+mG98ubwNv_tpITppba^GiieBBZGI>I89
zGgm8TA>_)DlEu&W;s3#ZUNiH4&CF{a%siTjzG;eOzQB6{003qKeT?}z_5U*{{kgZ;
zdV@U&tqa-&4FGisjMN8o=P}$t-`oTM2oeB5d9mHPgTYJx4jup)+5a;Tke$m708DocFzDL>U$$}s6FGiy_I1?O
zHXq`q884|^O4Q*%V#vwxqCz-#8i`Gu)2LeB0{%%VKunOF%9~JcFB9MM>N00M`E~;o
zBU%)O5u-D6NF~OQV7TV#JAN;=Lylgxy0kncoQpGq<<_gxw`FC=C-cV#$L|(47Hatl
ztq3Jngq00x#}HGW@_tj{&A?lwOwrVX4@d66vLVyj1H@i}VD2YXd)n03?U5?cKtFz4
zW#@+MLeDVP>fY0F2IzT;r5*MAJ2}P8Z{g3utX0<+ZdAC)Tvm-4uN!I7|BTw&G%RQn
zR+A5VFx(}r<1q9^N40XzP=Jp?i=jlS7}T~tB4CsWx!XbiHSm
zLu}yar%t>-3jlutK=wdZhES->*1X({YI;DN?6R=C*{1U6%wG`0>^?u}h0hhqns|SeTmV=s;Gxx5F9DtK>{>{f-`SpJ`dO26Ujk?^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#1B2}Jai^DOjM2<90tpql|M5tmheg){2NyZR}x3w
zL6u}F+C-PIzZ56q0x$;mVJXM1V0;F}y9F29ob51f;;+)t&7l30gloMMHPTuod530FC}j^4#qOJV%5!&e!H9#!N&XQvs5{R
zD_FOomd-uk@?_JiWP%&nQ_myBlM6so1Ffa1aaL7B`!ZTXPg_S%TUS*>M^8iJRj1*~
e{{%>Z1YfTk|3C04d;8A^0$7;Zm{b|L#{L(;l>}-4
diff --git a/tests/WindowManagerStressTest/res/mipmap-xhdpi/ic_launcher.png b/tests/WindowManagerStressTest/res/mipmap-xhdpi/ic_launcher.png
deleted file mode 100644
index bfa42f0e7b91d006d22352c9ff2f134e504e3c1d..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 4842
zcmZ{oXE5C1x5t0WvTCfdv7&7fy$d2l*k#q|U5FAbL??P!61}%ovaIM)mL!5G(V|6J
zAtDH(OY|Du^}l!K&fFLG%sJ2JIp@rG=9y>Ci)Wq~U2RobsvA@Q0MM$dq4lq5{hy#9
zzgp+B{O(-=?1<7r0l>Q?>N6X%s~lmgrmqD6fjj_!c?AF`S0&6U06Z51fWOuNAe#jM
z%pSN#J-Mp}`ICpL=qp~?u~Jj$6(~K_%)9}Bn(;pY0&;M00H9x2N23h=CpR7kr8A9X
zU%oh4-E@i!Ac}P+&%vOPQ3warO9l!SCN)ixGW54Jsh!`>*aU)#&Mg7;#O_6xd5%I6
zneGSZL3Kn-4B^>#T7pVaIHs3^PY-N^v1!W=%gzfioIWosZ!BN?_M)OOux&6HCyyMf
z3ToZ@_h75A33KyC!T)-zYC-bp`@^1n;w3~N+vQ0#4V7!f|JPMlWWJ@+Tg~8>1$GzLlHGuxS)w&NAF*&Y;ef`T^w4HP7GK%6UA8(
z{&ALM(%!w2U7WFWwq8v4H3|0cOjdt7$JLh(;U8VcTG;R-vmR7?21nA?@@b+XPgJbD
z*Y@v&dTqo5Bcp-dIQQ4@?-m{=7>`LZ{g4jvo$CE&(+7(rp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JdgiL{1=w0!qS9$A`w9Qm7>N0Y*Ma%P_
zr@fR4>5u{mKwgZ33Xs$RD6(tcVH~Mas-87Fd^6M6iuV^_o$~ql+!eBIw$U)lzl`q9
z=L6zVsZzi0IIW=DT&ES9HajKhb5lz4yQxT-NRBLv_=2sn7WFX&Wp6Y!&}P+%`!A;s
zrCwXO3}jrdA7mB`h~N~HT64TM{R$lNj*~ekqSP^n9P~z;P
zWPlRPz0h6za8-P>!ARb+A1-r>8VF*xhrGa8W6J$p*wy`ULrD$CmYV7Gt^scLydQWbo7XN-o9X1i7;l+J_8Ncu
zc=EX&dg`GRo4==cz2d_Rz28oLS`Suf6OCp~f{0-aQ`t5YZ=!CAMc6-RZw#}A%;s44
znf2`6gcgm=0SezTH9h+JzeR3Lcm;8?*@+?FDfguK^9)z(Z`I!RKrSAI?H~4et6GTkz07Qgq4B6%Q*8Y0yPc4x
z8(^YwtZjYIeOvVLey#>@$UzIciJ#x0pJLFg=8UaZv%-&?Yzp7gWNIo_x^(d75=x2c
zv|LQ`HrKP(8TqFxTiP5gdT2>aTN0S7XW*pilASS$UkJ2*n+==D)0mgTGxv43t61fr
z47GkfMnD-zSH@|mZ26r*d3WEtr+l-xH@L}BM)~ThoMvKqGw=Ifc}BdkL$^wC}=(XSf4YpG;sA9#OSJf)V=rs#Wq$?Wj+nTlu$YXn
yn3SQon5>kvtkl(BT2@T#Mvca!|08g9w{vm``2PjZHg=b<1c17-HkzPl9sXa)&-Ts$
diff --git a/tests/WindowManagerStressTest/res/mipmap-xxhdpi/ic_launcher.png b/tests/WindowManagerStressTest/res/mipmap-xxhdpi/ic_launcher.png
deleted file mode 100644
index 324e72cdd7480cb983fa1bcc7ce686e51ef87fe7..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 7718
zcmZ{JWl)?=u?hpbj?h-6mfK3P*Eck~k0Tzeg5-hkABxtZea0_k$f-mlF
z0S@Qqtva`>x}TYzc}9LrO?P#qj+P1@HZ?W?0C;Muih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z5|%qOa!WTBed-8`#AQ~wb9TrUZKU)H*O7!LtNnEd!r8!Oda)u!Gb5P`9(`b
z`lMP6CLh4OzvXC#CR|@uo$EcHAyGr=)LB7)>=s3
zvU;aR#cN3<5&CLMFU@keW^R-Tqyf4fdkOnwI(H$x#@I1D6#dkUo@YW#7MU0@=NV-4
zEh2K?O@+2e{qW^7r?B~QTO)j}>hR$q9*n$8M(4+DOZ00WXFonLlk^;os8*zI>YG#?
z9oq$CD~byz>;`--_NMy|iJRALZ#+qV8OXn=AmL^GL&|q1Qw-^*#~;WNNNbk(96Tnw
zGjjscNyIyM2CYwiJ2l-}u_7mUGcvM+puPF^F89eIBx27&$|p_NG)fOaafGv|_b9G$;1LzZ-1aIE?*R6kHg}dy%~K(Q5S2O6086
z{lN&8;0>!pq^f*Jlh=J%Rmaoed<=uf@$iKl+bieC83IT!09J&IF)9H)C?d!eW1UQ}BQwxaqQY47DpOk@`zZ
zo>#SM@oI^|nrWm~Ol7=r`!Bp9lQNbBCeHcfN&X$kjj0R(@?f$OHHt|fWe6jDrYg3(mdEd$8P2Yzjt9*EM
zLE|cp-Tzsdyt(dvLhU8}_IX&I?B=|yoZ!&<`9&H5PtApt=VUIB4l0a1NH
v0SQqt3DM`an1p};^>=lX|A*k@Y-MNT^ZzF}9G-1G696?OEyXH%^Pv9$0dR%J
diff --git a/tests/WindowManagerStressTest/res/mipmap-xxxhdpi/ic_launcher.png b/tests/WindowManagerStressTest/res/mipmap-xxxhdpi/ic_launcher.png
deleted file mode 100644
index aee44e138434630332d88b1680f33c4b24c70ab3..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 10486
zcmai4byOU|lb&5k+^GN3bv-?^>(QkVinb
zlU9`mfQEQnq$S4VGrg6fmMQ=QFarQQ0ss(?uiys&;LQU7M-~7engIZmZaH5x#UC3m
z-zvYBd&I}<`b3rPHj1tDgVv1x|
zQss$ELI?W?E(!7PKk$lm@;7PwPX3o43{Ccd9@_BUsL4kQzSMa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Sjei*$%Ai4A}4W1S3}-mXNa1B^jTL+Biw<*SD;pmpz7SdmFu%Z231W
zkED`=rBr|FkuV%mCW~b>XQTCw%K0Clxj&QGIm4o%6lpuc4OgwWW^N>I
z$CiUaixkCEQf)R*DBF6P&%z|)%AGchvGhBH3v_5YPKL6o6gDG~@`ZoTScT$`HQPz7
zQiqtq$|yTKXN%7
zSaCG2Ucn>50Z`>XxJnz6%(tPlqY9dGm@zHtV2!nWMmS!~Ac!e66nI-(6fh>Qh>8n)+v%wQv>T#tc54h
zB%~5--xs;qRhX+bIms&XJP;?K$K2_5H1EpFn-*GyZaD5sGDZ&n5P~FndmWj1xxfxb
zSocm{R9OVmD?CfFE;Oebf@%V^7{ZETZUhZ?GM(@uT|gImuIH#AeMtxlE^*teXWH`b
z$LnM8?Q_|vjv^u(kO-Y$cB1?ICmH@j5PY(q
zaPxf3LgA{hO>D7{M2?XnUpAsX?0!P#eL3cHStcyY4^PB2N&Y`}U05UvjiREStj@u{
z|B)ET
-
-
- #3F51B5
- #303F9F
- #FF4081
-
diff --git a/tests/WindowManagerStressTest/res/values/dimens.xml b/tests/WindowManagerStressTest/res/values/dimens.xml
deleted file mode 100644
index ed4ccbcc700f3..0000000000000
--- a/tests/WindowManagerStressTest/res/values/dimens.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
- 16dp
- 16dp
-
diff --git a/tests/WindowManagerStressTest/res/values/strings.xml b/tests/WindowManagerStressTest/res/values/strings.xml
deleted file mode 100644
index cef05dcb65848..0000000000000
--- a/tests/WindowManagerStressTest/res/values/strings.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
- WmSlam
- Run
-
diff --git a/tests/WindowManagerStressTest/res/values/styles.xml b/tests/WindowManagerStressTest/res/values/styles.xml
deleted file mode 100644
index 0983b2535878e..0000000000000
--- a/tests/WindowManagerStressTest/res/values/styles.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
-
-
diff --git a/tests/WindowManagerStressTest/src/test/windowmanagerstresstest/MainActivity.java b/tests/WindowManagerStressTest/src/test/windowmanagerstresstest/MainActivity.java
deleted file mode 100644
index 85646987940f1..0000000000000
--- a/tests/WindowManagerStressTest/src/test/windowmanagerstresstest/MainActivity.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License
- */
-
-package test.windowmanagerstresstest;
-
-import android.app.Activity;
-import android.graphics.Rect;
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.os.SystemClock;
-import android.util.Log;
-import android.util.MergedConfiguration;
-import android.view.Display;
-import android.view.DisplayCutout;
-import android.view.IWindowSession;
-import android.view.InsetsState;
-import android.view.Surface;
-import android.view.SurfaceControl;
-import android.view.View;
-import android.view.WindowManager;
-import android.view.WindowManager.LayoutParams;
-import android.view.WindowManagerGlobal;
-import android.widget.TextView;
-
-import com.android.internal.view.BaseIWindow;
-
-import java.util.ArrayList;
-
-public class MainActivity extends Activity {
-
- private static final String TAG = "WmSlam";
-
- private TextView mOutput;
- private volatile boolean finished;
- private final ArrayList mWindows = new ArrayList<>();
- private final LayoutParams mLayoutParams = new LayoutParams();
- private final Rect mTmpRect = new Rect();
-
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_main);
- mOutput = (TextView) findViewById(R.id.output);
-
- findViewById(R.id.run).setOnClickListener(view -> {
- view.setEnabled(false);
- mOutput.setText("");
- startBatch();
- });
- mLayoutParams.token = getActivityToken();
- }
-
- void startBatch() {
- new Thread(() -> {
- finished = false;
- addWindows();
- startCpuRunnables();
- for (int i = 0; i < 5; i++) {
- final long time = SystemClock.uptimeMillis();
- slamWm();
- log("Total: " + (SystemClock.uptimeMillis() - time) + " ms");
- }
- removeWindows();
- finished = true;
- }).start();
- }
-
- void startCpuRunnables() {
- for (int i = 0; i < 10; i++) {
- new Thread(mUseCpuRunnable).start();
- }
- }
-
- private final Runnable mUseCpuRunnable = new Runnable() {
- @Override
- public void run() {
- while (!finished) {
- }
- }
- };
-
- private void log(String text) {
- mOutput.post(() -> mOutput.append(text + "\n"));
- Log.d(TAG, text);
- }
-
- private void slamWm() {
- ArrayList threads = new ArrayList<>();
- for (int i = 0; i < 20; i++) {
- for (BaseIWindow window : mWindows) {
- Thread t = new Thread(() -> {
- try {
- WindowManagerGlobal.getWindowSession().relayout(window,
- window.mSeq, mLayoutParams, -1, -1, View.VISIBLE, 0, -1, mTmpRect,
- mTmpRect, mTmpRect, mTmpRect, mTmpRect, mTmpRect, mTmpRect,
- new DisplayCutout.ParcelableWrapper(), new MergedConfiguration(),
- new SurfaceControl(), new InsetsState());
- } catch (RemoteException e) {
- e.printStackTrace();
- }
- });
- threads.add(t);
- t.start();
- }
- }
- for (Thread t : threads) {
- try {
- t.join();
- } catch (InterruptedException e) {
- e.printStackTrace();
- }
- }
- }
-
- void addWindows() {
- for (int i = 0; i < 50; i++) {
- final WindowManager.LayoutParams layoutParams = new WindowManager.LayoutParams();
- layoutParams.token = getActivityToken();
- final BaseIWindow window = new BaseIWindow();
- final IWindowSession session = WindowManagerGlobal.getWindowSession();
- final Rect tmpRect = new Rect();
- try {
- final int res = session.addToDisplayWithoutInputChannel(window, window.mSeq,
- layoutParams, View.VISIBLE, Display.DEFAULT_DISPLAY, tmpRect, tmpRect,
- new InsetsState());
- } catch (RemoteException e) {
- e.printStackTrace();
- }
- mWindows.add(window);
- }
- }
-
- void removeWindows() {
- for (BaseIWindow window : mWindows) {
- try {
- WindowManagerGlobal.getWindowSession().remove(window);
- } catch (RemoteException e) {
- e.printStackTrace();
- }
- }
- }
-}