Remove portalToDisplayId from InputWindowHandle

All of the existing users have already moved off of virtual displays.
There are no more users of this functionality.

Bug: 167946720
Test: compile only
Change-Id: I8e602b781227c9ad18c933f4ed77cdc2f21efbb0
This commit is contained in:
Siarhei Vishniakou
2020-12-03 14:50:50 -10:00
parent b9c36da7d6
commit 37fba99340
5 changed files with 0 additions and 23 deletions

View File

@@ -16,8 +16,6 @@
package android.view;
import static android.view.Display.INVALID_DISPLAY;
import android.annotation.Nullable;
import android.graphics.Region;
import android.os.IBinder;
@@ -101,10 +99,6 @@ public final class InputWindowHandle {
// Display this input is on.
public int displayId;
// If this value is set to a valid display ID, it indicates this window is a portal which
// transports the touch of this window to the display indicated by portalToDisplayId.
public int portalToDisplayId = INVALID_DISPLAY;
/**
* Crops the touchable region to the bounds of the surface provided.
*

View File

@@ -66,7 +66,6 @@ static struct {
jfieldID packageName;
jfieldID inputFeatures;
jfieldID displayId;
jfieldID portalToDisplayId;
jfieldID replaceTouchableRegionWithCrop;
WeakRefHandleField touchableRegionSurfaceControl;
} gInputWindowHandleClassInfo;
@@ -163,8 +162,6 @@ bool NativeInputWindowHandle::updateInfo() {
env->GetIntField(obj, gInputWindowHandleClassInfo.inputFeatures));
mInfo.displayId = env->GetIntField(obj,
gInputWindowHandleClassInfo.displayId);
mInfo.portalToDisplayId = env->GetIntField(obj,
gInputWindowHandleClassInfo.portalToDisplayId);
jobject inputApplicationHandleObj = env->GetObjectField(obj,
gInputWindowHandleClassInfo.inputApplicationHandle);
@@ -348,9 +345,6 @@ int register_android_view_InputWindowHandle(JNIEnv* env) {
GET_FIELD_ID(gInputWindowHandleClassInfo.displayId, clazz,
"displayId", "I");
GET_FIELD_ID(gInputWindowHandleClassInfo.portalToDisplayId, clazz,
"portalToDisplayId", "I");
GET_FIELD_ID(gInputWindowHandleClassInfo.replaceTouchableRegionWithCrop, clazz,
"replaceTouchableRegionWithCrop", "Z");

View File

@@ -5364,7 +5364,6 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
portalWindowHandle.scaleFactor = 1f;
portalWindowHandle.ownerPid = Process.myPid();
portalWindowHandle.ownerUid = Process.myUid();
portalWindowHandle.portalToDisplayId = mDisplayId;
return portalWindowHandle;
}

View File

@@ -18,7 +18,6 @@ package com.android.server.wm;
import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN;
import static android.os.Trace.TRACE_TAG_WINDOW_MANAGER;
import static android.view.Display.INVALID_DISPLAY;
import static android.view.WindowManager.INPUT_CONSUMER_PIP;
import static android.view.WindowManager.INPUT_CONSUMER_RECENTS_ANIMATION;
import static android.view.WindowManager.INPUT_CONSUMER_WALLPAPER;
@@ -617,7 +616,6 @@ final class InputMonitor {
inputWindowHandle.setScaleFactor(1f);
inputWindowHandle.setLayoutParamsFlags(
FLAG_NOT_TOUCH_MODAL | FLAG_NOT_TOUCHABLE | FLAG_NOT_FOCUSABLE);
inputWindowHandle.setPortalToDisplayId(INVALID_DISPLAY);
inputWindowHandle.clearTouchableRegion();
inputWindowHandle.setTouchableRegionCrop(null);
}

View File

@@ -223,14 +223,6 @@ class InputWindowHandleWrapper {
mChanged = true;
}
void setPortalToDisplayId(int displayId) {
if (mHandle.portalToDisplayId == displayId) {
return;
}
mHandle.portalToDisplayId = displayId;
mChanged = true;
}
void setFrame(int left, int top, int right, int bottom) {
if (mHandle.frameLeft == left && mHandle.frameTop == top && mHandle.frameRight == right
&& mHandle.frameBottom == bottom) {