Loading core/java/android/inputmethodservice/InputMethodService.java +10 −1 Original line number Diff line number Diff line Loading @@ -395,7 +395,7 @@ public class InputMethodService extends AbstractInputMethodService { /** * @hide * The IME is visible. * The IME is perceptibly visible to the user. */ public static final int IME_VISIBLE = 0x2; Loading @@ -406,6 +406,15 @@ public class InputMethodService extends AbstractInputMethodService { */ public static final int IME_INVISIBLE = 0x4; /** * @hide * The IME is visible, but not yet perceptible to the user (e.g. fading in) * by {@link android.view.WindowInsetsController}. * * @see InputMethodManager#reportPerceptible */ public static final int IME_VISIBLE_IMPERCEPTIBLE = 0x8; // Min and max values for back disposition. private static final int BACK_DISPOSITION_MIN = BACK_DISPOSITION_DEFAULT; private static final int BACK_DISPOSITION_MAX = BACK_DISPOSITION_ADJUST_NOTHING; Loading packages/SystemUI/src/com/android/systemui/navigationbar/TaskbarDelegate.java +5 −0 Original line number Diff line number Diff line Loading @@ -41,6 +41,7 @@ import android.content.ComponentCallbacks; import android.content.Context; import android.content.res.Configuration; import android.hardware.display.DisplayManager; import android.inputmethodservice.InputMethodService; import android.os.IBinder; import android.os.RemoteException; import android.util.Log; Loading Loading @@ -279,6 +280,10 @@ public class TaskbarDelegate implements CommandQueue.Callbacks, public void setImeWindowStatus(int displayId, IBinder token, int vis, int backDisposition, boolean showImeSwitcher) { boolean imeShown = mNavBarHelper.isImeShown(vis); if (!imeShown) { // Count imperceptible changes as visible so we transition taskbar out quickly. imeShown = (vis & InputMethodService.IME_VISIBLE_IMPERCEPTIBLE) != 0; } showImeSwitcher = imeShown && showImeSwitcher; int hints = Utilities.calculateBackDispositionHints(mNavigationIconHints, backDisposition, imeShown, showImeSwitcher); Loading services/core/java/com/android/server/inputmethod/InputMethodManagerService.java +6 −1 Original line number Diff line number Diff line Loading @@ -2868,7 +2868,12 @@ public class InputMethodManagerService extends IInputMethodManager.Stub final long ident = Binder.clearCallingIdentity(); try { if (!mCurPerceptible) { if ((vis & InputMethodService.IME_VISIBLE) != 0) { vis &= ~InputMethodService.IME_VISIBLE; vis |= InputMethodService.IME_VISIBLE_IMPERCEPTIBLE; } } else { vis &= ~InputMethodService.IME_VISIBLE_IMPERCEPTIBLE; } // mImeWindowVis should be updated before calling shouldShowImeSwitcherLocked(). final boolean needsToShowImeSwitcher = shouldShowImeSwitcherLocked(vis); Loading Loading
core/java/android/inputmethodservice/InputMethodService.java +10 −1 Original line number Diff line number Diff line Loading @@ -395,7 +395,7 @@ public class InputMethodService extends AbstractInputMethodService { /** * @hide * The IME is visible. * The IME is perceptibly visible to the user. */ public static final int IME_VISIBLE = 0x2; Loading @@ -406,6 +406,15 @@ public class InputMethodService extends AbstractInputMethodService { */ public static final int IME_INVISIBLE = 0x4; /** * @hide * The IME is visible, but not yet perceptible to the user (e.g. fading in) * by {@link android.view.WindowInsetsController}. * * @see InputMethodManager#reportPerceptible */ public static final int IME_VISIBLE_IMPERCEPTIBLE = 0x8; // Min and max values for back disposition. private static final int BACK_DISPOSITION_MIN = BACK_DISPOSITION_DEFAULT; private static final int BACK_DISPOSITION_MAX = BACK_DISPOSITION_ADJUST_NOTHING; Loading
packages/SystemUI/src/com/android/systemui/navigationbar/TaskbarDelegate.java +5 −0 Original line number Diff line number Diff line Loading @@ -41,6 +41,7 @@ import android.content.ComponentCallbacks; import android.content.Context; import android.content.res.Configuration; import android.hardware.display.DisplayManager; import android.inputmethodservice.InputMethodService; import android.os.IBinder; import android.os.RemoteException; import android.util.Log; Loading Loading @@ -279,6 +280,10 @@ public class TaskbarDelegate implements CommandQueue.Callbacks, public void setImeWindowStatus(int displayId, IBinder token, int vis, int backDisposition, boolean showImeSwitcher) { boolean imeShown = mNavBarHelper.isImeShown(vis); if (!imeShown) { // Count imperceptible changes as visible so we transition taskbar out quickly. imeShown = (vis & InputMethodService.IME_VISIBLE_IMPERCEPTIBLE) != 0; } showImeSwitcher = imeShown && showImeSwitcher; int hints = Utilities.calculateBackDispositionHints(mNavigationIconHints, backDisposition, imeShown, showImeSwitcher); Loading
services/core/java/com/android/server/inputmethod/InputMethodManagerService.java +6 −1 Original line number Diff line number Diff line Loading @@ -2868,7 +2868,12 @@ public class InputMethodManagerService extends IInputMethodManager.Stub final long ident = Binder.clearCallingIdentity(); try { if (!mCurPerceptible) { if ((vis & InputMethodService.IME_VISIBLE) != 0) { vis &= ~InputMethodService.IME_VISIBLE; vis |= InputMethodService.IME_VISIBLE_IMPERCEPTIBLE; } } else { vis &= ~InputMethodService.IME_VISIBLE_IMPERCEPTIBLE; } // mImeWindowVis should be updated before calling shouldShowImeSwitcherLocked(). final boolean needsToShowImeSwitcher = shouldShowImeSwitcherLocked(vis); Loading