Require proper permission for togglePanel()/handleSystemKey()
In S, we're preventing apps from closing notification shade unless they
fall into certain exemptions. The methods togglePanel() and
handleSystemKey() weren't properly protected, so fixing that.
These methods were @hide, only available in the AIDL and their only
usages were inside the system
Introducing @TestApis to be able to verify this in CTS.
Bug: 192946152
Test: atest -d CtsAppTestCases:android.app.cts.StatusBarManagerTest
Test: atest -d CtsLegacyNotification30TestCases:android.app.notification.legacy30.cts.StatusBarManagerApi30Test
Test: 1. adb shell input keyevent KEYCODE_SYSTEM_NAVIGATION_DOWN
2. Verify status bar expands
3. adb shell input keyevent KEYCODE_SYSTEM_NAVIGATION_UP
4. Verify status bar collapses
Change-Id: I925e3570c8d275a1159e4b6912e4628c9528cb61
3 files changed