Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 93e5ab46 authored by Yohei Yukawa's avatar Yohei Yukawa Committed by android-build-merger
Browse files

Merge "Fix a regression in SHOW_IME_WITH_HARD_KEYBOARD handling." into nyc-dev am: 12a52bc3

am: f650e10a

* commit 'f650e10a':
  Fix a regression in SHOW_IME_WITH_HARD_KEYBOARD handling.

Change-Id: I6c282a716a0177759a8ef016adaaabc8c24dfa22
parents 64f225c3 f650e10a
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -717,7 +717,11 @@ public class InputMethodService extends AbstractInputMethodService {
                mShowImeWithHardKeyboard = Settings.Secure.getInt(mService.getContentResolver(),
                        Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD, 0) != 0 ?
                        ShowImeWithHardKeyboardType.TRUE : ShowImeWithHardKeyboardType.FALSE;
                mService.updateInputViewShown();
                // In Android M and prior, state change of
                // Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD has triggered
                // #onConfigurationChanged().  For compatibility reasons, we reset the internal
                // state as if configuration was changed.
                mService.resetStateForNewConfiguration();
            }
        }

@@ -884,7 +888,10 @@ public class InputMethodService extends AbstractInputMethodService {
     */
    @Override public void onConfigurationChanged(Configuration newConfig) {
        super.onConfigurationChanged(newConfig);
        resetStateForNewConfiguration();
    }

    private void resetStateForNewConfiguration() {
        boolean visible = mWindowVisible;
        int showFlags = mShowInputFlags;
        boolean showingInput = mShowInputRequested;