diff options
Diffstat (limited to 'services/java/com/android/server/InputMethodManagerService.java')
| -rw-r--r-- | services/java/com/android/server/InputMethodManagerService.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/services/java/com/android/server/InputMethodManagerService.java b/services/java/com/android/server/InputMethodManagerService.java index 8d6d3a1644b6..877f5598dbeb 100644 --- a/services/java/com/android/server/InputMethodManagerService.java +++ b/services/java/com/android/server/InputMethodManagerService.java @@ -1053,7 +1053,14 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } if (mCurMethod != null) { try { - mImeWindowVis = 0; + final Configuration conf = mRes.getConfiguration(); + final boolean haveHardKeyboard = conf.keyboard + != Configuration.KEYBOARD_NOKEYS; + final boolean hardKeyShown = haveHardKeyboard + && conf.hardKeyboardHidden != Configuration.KEYBOARDHIDDEN_YES; + mImeWindowVis = (mInputShown || hardKeyShown) ? ( + InputMethodService.IME_ACTIVE | InputMethodService.IME_VISIBLE) + : 0; mStatusBar.setImeWindowStatus(mCurToken, mImeWindowVis, mBackDisposition); // If subtype is null, try to find the most applicable one from |
