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

Commit 0ba72ad4 authored by John Reck's avatar John Reck
Browse files

Tap highlight fix + small perf increase

 Bug: 5229717

Change-Id: I9ebc92dc96d77ff9051517b717d203686b574f7a
parent 05ef0439
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
@@ -4004,9 +4004,12 @@ public class WebView extends AbsoluteLayout
        // state.
        // If mNativeClass is 0, we should not reach here, so we do not
        // need to check it again.
        if (mDrawCursorRing && drawRings) {
            // Only update if we are actually going to use the result
            nativeRecordButtons(hasFocus() && hasWindowFocus(),
                    mTouchMode == TOUCH_SHORTPRESS_START_MODE
                    || mTrackballDown || mGotCenterDown, false);
        }
        drawCoreAndCursorRing(canvas, mBackgroundColor,
                mDrawCursorRing && drawRings);
    }
@@ -4075,7 +4078,8 @@ public class WebView extends AbsoluteLayout
        boolean drawJavaRings = !mTouchHighlightRegion.isEmpty()
                && (mTouchMode == TOUCH_INIT_MODE
                || mTouchMode == TOUCH_SHORTPRESS_START_MODE
                || mTouchMode == TOUCH_SHORTPRESS_MODE);
                || mTouchMode == TOUCH_SHORTPRESS_MODE
                || mTouchMode == TOUCH_DONE_MODE);
        boolean drawNativeRings = !drawJavaRings;
        if (USE_WEBKIT_RINGS) {
            drawNativeRings = !drawJavaRings && !isInTouchMode();