Implement requestKeyboardShortcuts for PopupDecorView
A call to requestKeyboardShortcuts from popup menu might be dispatched
to PopupDecorView or DecorView depending on WindowManagerService's
focusedWindow at that moment.
In case it gets dispatched to PopupDecorView, we would like to resend it
to parent activity's decor view (which can then handle it
appropriately). The change adds a notion of mParentRootView which keeps
track of popup's parent's decor view. The request is then routed
appropriately so as to display the corresponding shortcuts. mAnchor
cannot be used as it gets nulled (by dismiss) by the time
requestKeyboardShortcuts gets called.
Bug: 31850671
Change-Id: I0ee3a1c7801c6d3fce8748bc7513382f250c5c63
Fixes: 31850671
Test: cts-tradefed run cts-dev -m CtsAppTestCases -t
android.app.cts.ActivityKeyboardShortcutsTest#testRequestShowKeyboardShortcuts
1 file changed