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

Commit 1b15f6c0 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Change condition for entering in touchMode"

parents 47ad1542 280630bf
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -5402,11 +5402,10 @@ public final class ViewRootImpl implements ViewParent,
                mTranslator.translateEventInScreenToAppWindow(event);
            }

            // Enter touch mode on down or scroll, if it is coming from a touch screen device,
            // exit otherwise.
            // Enter touch mode if event is coming from a touch screen device.
            final int action = event.getAction();
            if (action == MotionEvent.ACTION_DOWN || action == MotionEvent.ACTION_SCROLL) {
                ensureTouchMode(event.isFromSource(InputDevice.SOURCE_TOUCHSCREEN));
            if (event.isFromSource(InputDevice.SOURCE_TOUCHSCREEN)) {
                ensureTouchMode(true);
            }

            if (action == MotionEvent.ACTION_DOWN) {