IME: make WindowInsetsController.show(ime()) more robust
We need to make sure the served view is up-to-date, otherwise we might
erroneously reject or allow a request to show the IME via WindowInsetsController.
Fixes: 190217891
Bug: 200051968
Test: atest WindowInsetsControllerTests#\
testShowIme_immediatelyAfterDetachAndReattach
Merged-In: Ib41412d5d5636bdc236aa94c4ee4702686b6d10f
Change-Id: Ib41412d5d5636bdc236aa94c4ee4702686b6d10f
(cherry picked from commit e6b4e24b30)
This commit is contained in:
committed by
Ming-Shin Lu
parent
a7efb5e025
commit
e4e7d6fda6
@@ -2154,6 +2154,7 @@ public final class InputMethodManager {
|
||||
* @hide
|
||||
*/
|
||||
public boolean requestImeShow(IBinder windowToken) {
|
||||
checkFocus();
|
||||
synchronized (mH) {
|
||||
final View servedView = getServedViewLocked();
|
||||
if (servedView == null || servedView.getWindowToken() != windowToken) {
|
||||
|
||||
Reference in New Issue
Block a user