Fix egregious state check for window focusability.

am: 3d0a74a9e4

Change-Id: I68aac94729227b30e2ba05bf2e89afae5a9debbf
This commit is contained in:
Winson Chung
2017-07-12 19:58:56 +00:00
committed by android-build-merger

View File

@@ -1970,7 +1970,7 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
return false;
}
final boolean windowsAreFocusable = mAppToken != null && mAppToken.windowsAreFocusable();
final boolean windowsAreFocusable = mAppToken == null || mAppToken.windowsAreFocusable();
if (!windowsAreFocusable) {
// This window can't be an IME target if the app's windows should not be focusable.
return false;