Loading quickstep/src/com/android/quickstep/TouchInteractionService.java +10 −3 Original line number Diff line number Diff line Loading @@ -86,7 +86,6 @@ import androidx.annotation.UiThread; import com.android.launcher3.BaseDraggingActivity; import com.android.launcher3.ConstantItem; import com.android.launcher3.DeviceProfile; import com.android.launcher3.EncryptionType; import com.android.launcher3.LauncherPrefs; import com.android.launcher3.R; Loading Loading @@ -725,8 +724,7 @@ public class TouchInteractionService extends Service { final int action = event.getActionMasked(); // Note this will create a new consumer every mouse click, as after ACTION_UP from the click // an ACTION_HOVER_ENTER will fire as well. boolean isHoverActionWithoutConsumer = event.isHoverEvent() && (mUncheckedConsumer.getType() & TYPE_CURSOR_HOVER) == 0; boolean isHoverActionWithoutConsumer = isHoverActionWithoutConsumer(event); CompoundString reasonString = action == ACTION_DOWN ? new CompoundString("onMotionEvent: ") : CompoundString.NO_OP; if (action == ACTION_DOWN || isHoverActionWithoutConsumer) { Loading Loading @@ -846,6 +844,15 @@ public class TouchInteractionService extends Service { traceToken.close(); } private boolean isHoverActionWithoutConsumer(MotionEvent event) { // Only process these events when taskbar is present. TaskbarActivityContext tac = mTaskbarManager.getCurrentActivityContext(); boolean isTaskbarPresent = tac != null && tac.getDeviceProfile().isTaskbarPresent && !tac.isPhoneMode(); return event.isHoverEvent() && (mUncheckedConsumer.getType() & TYPE_CURSOR_HOVER) == 0 && isTaskbarPresent; } // Talkback generates hover events on touch, which we do not want to consume. private boolean isCursorHoverEvent(MotionEvent event) { return event.isHoverEvent() && event.getSource() == InputDevice.SOURCE_MOUSE; Loading Loading
quickstep/src/com/android/quickstep/TouchInteractionService.java +10 −3 Original line number Diff line number Diff line Loading @@ -86,7 +86,6 @@ import androidx.annotation.UiThread; import com.android.launcher3.BaseDraggingActivity; import com.android.launcher3.ConstantItem; import com.android.launcher3.DeviceProfile; import com.android.launcher3.EncryptionType; import com.android.launcher3.LauncherPrefs; import com.android.launcher3.R; Loading Loading @@ -725,8 +724,7 @@ public class TouchInteractionService extends Service { final int action = event.getActionMasked(); // Note this will create a new consumer every mouse click, as after ACTION_UP from the click // an ACTION_HOVER_ENTER will fire as well. boolean isHoverActionWithoutConsumer = event.isHoverEvent() && (mUncheckedConsumer.getType() & TYPE_CURSOR_HOVER) == 0; boolean isHoverActionWithoutConsumer = isHoverActionWithoutConsumer(event); CompoundString reasonString = action == ACTION_DOWN ? new CompoundString("onMotionEvent: ") : CompoundString.NO_OP; if (action == ACTION_DOWN || isHoverActionWithoutConsumer) { Loading Loading @@ -846,6 +844,15 @@ public class TouchInteractionService extends Service { traceToken.close(); } private boolean isHoverActionWithoutConsumer(MotionEvent event) { // Only process these events when taskbar is present. TaskbarActivityContext tac = mTaskbarManager.getCurrentActivityContext(); boolean isTaskbarPresent = tac != null && tac.getDeviceProfile().isTaskbarPresent && !tac.isPhoneMode(); return event.isHoverEvent() && (mUncheckedConsumer.getType() & TYPE_CURSOR_HOVER) == 0 && isTaskbarPresent; } // Talkback generates hover events on touch, which we do not want to consume. private boolean isCursorHoverEvent(MotionEvent event) { return event.isHoverEvent() && event.getSource() == InputDevice.SOURCE_MOUSE; Loading