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

Commit d859a67f authored by Phil Weaver's avatar Phil Weaver Committed by android-build-merger
Browse files

Merge "Move displaying mag bounds into surface transation" into oc-dev

am: 6f3bc058

Change-Id: I1240a4c21d712d1c04793897c5c50ef93edfc618
parents bfc81099 6f3bc058
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -222,11 +222,10 @@ final class AccessibilityController {
                || mWindowsForAccessibilityObserver != null);
    }

    /** NOTE: This has to be called within a surface transaction. */
    public void setForceShowMagnifiableBoundsLocked(boolean show) {
        if (mDisplayMagnifier != null) {
            mDisplayMagnifier.setForceShowMagnifiableBoundsLocked(show);
            mDisplayMagnifier.drawMagnifiedRegionBorderIfNeededLocked();
            mDisplayMagnifier.showMagnificationBoundsIfNeeded();
        }
    }

@@ -440,6 +439,12 @@ final class AccessibilityController {
            mMagnifedViewport.destroyWindow();
        }

        // Can be called outside of a surface transaction
        public void showMagnificationBoundsIfNeeded() {
            mHandler.obtainMessage(MyHandler.MESSAGE_SHOW_MAGNIFIED_REGION_BOUNDS_IF_NEEDED)
                    .sendToTarget();
        }

        /** NOTE: This has to be called within a surface transaction. */
        public void drawMagnifiedRegionBorderIfNeededLocked() {
            mMagnifedViewport.drawWindowIfNeededLocked();