From 217fd2903d09d40cabcdade9f2a162dc6513f800 Mon Sep 17 00:00:00 2001 From: "jungheang.lee" Date: Tue, 26 Feb 2013 16:53:22 +0900 Subject: [PATCH] Fixed the problem ime invisible status despite being the icon that appears in the statusbar. [Reproduce the Path] Precondition : Set "Auto-rotate screen" option to ENABLE Calendar App lunch -> Rotate device to "Landscape" -> Touch "+" button(Add new Schedule) -> Check the ime icons of the Status bar Ime invisible status despite being the icon that appears in the statusbar. Displays an icon in the status bar when the ime was actually visible state is modified to check. Change-Id: If103ab909c5bfa6391eb51a696fb8b8f0b18808c --- core/java/android/inputmethodservice/InputMethodService.java | 2 +- .../java/com/android/server/InputMethodManagerService.java | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/core/java/android/inputmethodservice/InputMethodService.java b/core/java/android/inputmethodservice/InputMethodService.java index 6f1cc942c965e..d6b90c3f331e0 100644 --- a/core/java/android/inputmethodservice/InputMethodService.java +++ b/core/java/android/inputmethodservice/InputMethodService.java @@ -424,7 +424,7 @@ public class InputMethodService extends AbstractInputMethodService { showWindow(true); } // If user uses hard keyboard, IME button should always be shown. - boolean showing = onEvaluateInputViewShown(); + boolean showing = isInputViewShown(); mImm.setImeWindowStatus(mToken, IME_ACTIVE | (showing ? IME_VISIBLE : 0), mBackDisposition); if (resultReceiver != null) { diff --git a/services/java/com/android/server/InputMethodManagerService.java b/services/java/com/android/server/InputMethodManagerService.java index a296d34498dcc..72aa2031e7354 100644 --- a/services/java/com/android/server/InputMethodManagerService.java +++ b/services/java/com/android/server/InputMethodManagerService.java @@ -1493,7 +1493,9 @@ public class InputMethodManagerService extends IInputMethodManager.Stub if (mStatusBar != null) { mStatusBar.setImeWindowStatus(token, vis, backDisposition); } - final boolean iconVisibility = (vis & InputMethodService.IME_ACTIVE) != 0; + final boolean iconVisibility = ((vis & (InputMethodService.IME_ACTIVE)) != 0) + && (mWindowManagerService.isHardKeyboardAvailable() + || (vis & (InputMethodService.IME_VISIBLE)) != 0); final InputMethodInfo imi = mMethodMap.get(mCurMethodId); if (imi != null && iconVisibility && needsToShowImeSwitchOngoingNotification()) { // Used to load label