Move some IWindowManager methods to internal interface

The methods are only used in system server. It is unnecessary to
declare in aidl.

This also eliminates the confusion of missing permission check
for updateRotation().

Bug: 230863943
Test: atest WindowManagerPermissionTests
Change-Id: I703830650bab3a792982cada99aa1512430658a4
This commit is contained in:
Riddle Hsu
2022-05-04 18:36:26 +08:00
parent 923e43dc70
commit 4bf606c578
6 changed files with 22 additions and 49 deletions

View File

@@ -123,16 +123,6 @@ public class WindowManagerPermissionTests extends TestCase {
@SmallTest
public void testSET_ORIENTATION() {
try {
mWm.updateRotation(true, false);
fail("IWindowManager.updateRotation did not throw SecurityException as"
+ " expected");
} catch (SecurityException e) {
// expected
} catch (RemoteException e) {
fail("Unexpected remote exception");
}
try {
mWm.freezeRotation(-1);
fail("IWindowManager.freezeRotation did not throw SecurityException as"