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

Commit 35e68fb8 authored by Holly Jiuyu Sun's avatar Holly Jiuyu Sun Committed by Android (Google) Code Review
Browse files

Merge "[a11y] Fix Switch Access keyboard input issue in AA+." into main

parents 7a3c354c 38c0102a
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -28,6 +28,9 @@ public class KeyboardStateManager {
    // Height of the keyboard when it's shown.
    // mImeShownHeightPx>=mImeHeightPx always.
    private int mImeShownHeightPx;
    // Indicate if the latest All Apps session was started from a11y action (rather than a direct
    // user interaction).
    private boolean mLaunchedFromA11y;

    public enum KeyboardState {
        NO_IME_ACTION,
@@ -89,4 +92,14 @@ public class KeyboardStateManager {
            mImeShownHeightPx = mImeHeightPx;
        }
    }

    /** Getter for {@code mLaunchedFromA11y} */
    public boolean getLaunchedFromA11y() {
        return mLaunchedFromA11y;
    }

    /** Setter for {@code mLaunchedFromA11y} */
    public void setLaunchedFromA11y(boolean fromA11y) {
        mLaunchedFromA11y = fromA11y;
    }
}
+1 −0
Original line number Diff line number Diff line
@@ -79,6 +79,7 @@ public class AccessibilityActionsView extends View implements StateListener<Laun
        }
        Launcher l = Launcher.getLauncher(getContext());
        if (action == R.string.all_apps_button_label) {
            l.getStatsLogManager().keyboardStateManager().setLaunchedFromA11y(true);
            l.getStateManager().goToState(ALL_APPS);
            return true;
        }