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

Commit 11893118 authored by LuK1337's avatar LuK1337 Committed by Łukasz Patron
Browse files

LockPatternView: Fix a11y+BiometricPrompt related OOB exception

Fixes: https://gitlab.com/LineageOS/issues/android/-/issues/4007
Change-Id: Ifcae0a46430915c93b9e65ad968ca7e90504a9fb
parent 3b46ef12
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -1587,8 +1587,10 @@ public class LockPatternView extends View {
            if (virtualViewId != ExploreByTouchHelper.INVALID_ID) {
                int row = (virtualViewId - VIRTUAL_BASE_VIEW_ID) / 3;
                int col = (virtualViewId - VIRTUAL_BASE_VIEW_ID) % 3;
                if (row < 3) {
                    return !mPatternDrawLookup[row][col];
                }
            }
            return false;
        }

@@ -1633,7 +1635,6 @@ public class LockPatternView extends View {
            final Rect bounds = mTempRect;
            final int row = ordinal / 3;
            final int col = ordinal % 3;
            final CellState cell = mCellStates[row][col];
            float centerX = getCenterXForColumn(col);
            float centerY = getCenterYForRow(row);
            float cellheight = mSquareHeight * mHitFactor * 0.5f;