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

Commit 0b831ba2 authored by Tadashi G. Takaoka's avatar Tadashi G. Takaoka
Browse files

Tab key preforms next action when EditorInfo.IME_ACTION_NEXT is specified

Bug: 6435484
Change-Id: Iccca7d1b770c547efae0b5e5931cebd910083d40
parent 22d196cb
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -29,6 +29,7 @@ public class InputAttributes {
    final public boolean mInputTypeNoAutoCorrect;
    final public boolean mIsSettingsSuggestionStripOn;
    final public boolean mApplicationSpecifiedCompletionOn;
    final public int mEditorAction;

    public InputAttributes(final EditorInfo editorInfo, final boolean isFullscreenMode) {
        final int inputType = null != editorInfo ? editorInfo.inputType : 0;
@@ -91,6 +92,8 @@ public class InputAttributes {

            mApplicationSpecifiedCompletionOn = flagAutoComplete && isFullscreenMode;
        }
        mEditorAction = (editorInfo == null) ? EditorInfo.IME_ACTION_UNSPECIFIED
                : editorInfo.imeOptions & EditorInfo.IME_MASK_ACTION;
    }

    @SuppressWarnings("unused")
+5 −0
Original line number Diff line number Diff line
@@ -1257,6 +1257,11 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
            handleLanguageSwitchKey();
            break;
        default:
            if (primaryCode == Keyboard.CODE_TAB
                    && mInputAttributes.mEditorAction == EditorInfo.IME_ACTION_NEXT) {
                performEditorAction(EditorInfo.IME_ACTION_NEXT);
                break;
            }
            mSpaceState = SPACE_STATE_NONE;
            if (mSettingsValues.isWordSeparator(primaryCode)) {
                didAutoCorrect = handleSeparator(primaryCode, x, y, spaceState);