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

Commit 86bf6ae9 authored by Artsiom Mitrokhin's avatar Artsiom Mitrokhin
Browse files

Prevent spawning multiple pinning popups on right click

The dismiss logic only checks for `ACTION_DOWN` events, but when the
user frequently right-clicks OR right-press-move-release, we get
multiple `ACTION_MOVE` events instead, which are ignored by the dismiss
logic of the previous popup instance.

Attached screen recordings to the bug.

Bug: 362475367
Flag: EXEMPT bugfix
Test: manual
Change-Id: I665c3127e4b449a8f4c71e443cc6ae07c1bf2794
parent 8ed2ef90
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -91,6 +91,7 @@ public class TaskbarViewCallbacks {
    public View.OnTouchListener getTaskbarDividerRightClickListener() {
        return (v, event) -> {
            if (event.isFromSource(InputDevice.SOURCE_MOUSE)
                    && event.getAction() == MotionEvent.ACTION_DOWN
                    && event.getButtonState() == MotionEvent.BUTTON_SECONDARY) {
                mControllers.taskbarPinningController.showPinningView(v, getDividerCenterX());
                return true;