summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorWale Ogunwale <ogunwale@google.com>2016-11-01 15:43:46 -0700
committerWale Ogunwale <ogunwale@google.com>2016-11-02 10:28:45 -0700
commitac2561e8206ac42921bb6ddbb0a5972fb360e394 (patch)
tree15f2bef8479d20bfda1927a2d55e7634e3c47b42 /tests
parent87045377c464ed6ec97dc7d4f5c6d8b473cd4ed9 (diff)
Make window token add/remove APIs require displayId
Window tokens can now only be on one display, so we now require clients that want to add/remove window tokens to specify the display they would like the token to be created on. This simplifies the token handling code in WM and will be useful moving forward for clients that want to add windows to external displays. Test: Existing tests pass Change-Id: I6b2d8d58a913b3624f1a9a7bebbb99315613f103
Diffstat (limited to 'tests')
-rw-r--r--tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java b/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java
index f737b247a7f5..7d6f32bd8f88 100644
--- a/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java
+++ b/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java
@@ -73,7 +73,7 @@ public class WindowManagerPermissionTests extends TestCase {
}
try {
- mWm.addWindowToken(null, 0);
+ mWm.addWindowToken(null, 0, DEFAULT_DISPLAY);
fail("IWindowManager.addWindowToken did not throw SecurityException as"
+ " expected");
} catch (SecurityException e) {
@@ -83,7 +83,7 @@ public class WindowManagerPermissionTests extends TestCase {
}
try {
- mWm.removeWindowToken(null);
+ mWm.removeWindowToken(null, DEFAULT_DISPLAY);
fail("IWindowManager.removeWindowToken did not throw SecurityException as"
+ " expected");
} catch (SecurityException e) {
@@ -126,7 +126,7 @@ public class WindowManagerPermissionTests extends TestCase {
try {
mWm.setAppOrientation(null, 0);
- mWm.addWindowToken(null, 0);
+ mWm.addWindowToken(null, 0, DEFAULT_DISPLAY);
fail("IWindowManager.setAppOrientation did not throw SecurityException as"
+ " expected");
} catch (SecurityException e) {
@@ -206,7 +206,7 @@ public class WindowManagerPermissionTests extends TestCase {
}
try {
- mWm.removeAppToken(null);
+ mWm.removeAppToken(null, DEFAULT_DISPLAY);
fail("IWindowManager.removeAppToken did not throw SecurityException as"
+ " expected");
} catch (SecurityException e) {