ENABLE_TOUCH_OPAQUE_ACTIVITIES to default enabled
Use mActivityRecord.getSurfaceControl() to set the correct bounds when activity is moved between tasks Test: atest CtsWindowManagerDeviceTestCases:WindowUntrustedTouchTest Test: atest CtsInputTestCases:android.input.cts.InputShellCommandTest Test: Manually verifed with sample app that touches are blocked from passing through activities by default Bug: 194480991 Change-Id: I7b709ebfd3e854a4e814f534b605a4c0c6466d2b
This commit is contained in:
@@ -22,7 +22,7 @@ import static com.android.server.wm.WindowContainer.AnimationFlags.TRANSITION;
|
||||
|
||||
import android.app.compat.CompatChanges;
|
||||
import android.compat.annotation.ChangeId;
|
||||
import android.compat.annotation.Disabled;
|
||||
import android.compat.annotation.Overridable;
|
||||
import android.os.IBinder;
|
||||
import android.os.InputConstants;
|
||||
import android.os.Looper;
|
||||
@@ -47,7 +47,7 @@ class ActivityRecordInputSink {
|
||||
* Feature flag for making Activities consume all touches within their task bounds.
|
||||
*/
|
||||
@ChangeId
|
||||
@Disabled
|
||||
@Overridable
|
||||
static final long ENABLE_TOUCH_OPAQUE_ACTIVITIES = 194480991L;
|
||||
|
||||
private static final String TAG = "ActivityRecordInputSink";
|
||||
@@ -116,8 +116,7 @@ class ActivityRecordInputSink {
|
||||
private InputWindowHandle createInputWindowHandle() {
|
||||
InputWindowHandle inputWindowHandle = new InputWindowHandle(null,
|
||||
mActivityRecord.getDisplayId());
|
||||
inputWindowHandle.replaceTouchableRegionWithCrop(
|
||||
mActivityRecord.getParentSurfaceControl());
|
||||
inputWindowHandle.replaceTouchableRegionWithCrop(mActivityRecord.getSurfaceControl());
|
||||
inputWindowHandle.name = mName;
|
||||
inputWindowHandle.ownerUid = Process.myUid();
|
||||
inputWindowHandle.ownerPid = Process.myPid();
|
||||
|
||||
Reference in New Issue
Block a user