Opened 6 years ago

Closed 6 years ago

#2680 closed defect (fixed)

Pressing two mouse buttons while dragging does not call mouse_up on first button mode

Reported by: Tristan Croll Owned by: Tom Goddard
Priority: moderate Milestone:
Component: UI Version:
Keywords: Cc:
Blocked By: Blocking:
Notify when closed: Platform: all
Project: ChimeraX

Description

Related to this comment regarding VR tugging from Josef Lewandowski:

Just to let you know, also sometimes while tugging ISOLDE freaks out and the tug becomes rather large and not necessarily direction where the controlled is moved (it is almost as tugging was locked in and not released when the button is released). Though this could be something related to tracking rather than ISOLDE itself.

This looks like something I've noticed when tugging with the mouse in ISOLDE (to the point where I've gotten into the habit of using it as a "feature"). If I'm dragging an atom with the right mouse button then click with the left button while the right is still down, ChimeraX switches to the RotateMouseMode and the tugging mode never receives its mouse_up event - so the last tugging target remains applied until I right-click on the atom again. Can also cause similarly strange behaviour in other modes.

One possible solution: have each MouseMode fire a trigger in session.ui.mouse_modes on its mouse_down event, which would allow other MouseModes to know when they've been gazumped and back out gracefully.

Change History (1)

comment:1 by Tom Goddard, 6 years ago

Resolution: fixed
Status: assignedclosed
Summary: Swapping mouse modes while dragging causes unexpected resultsPressing two mouse buttons while dragging does not call mouse_up on first button mode

I fixed the problem where clicking two mouse buttons causes the mode assigned to the first button to not get the mouse_up() callback. Every mode that gets a mouse_down() is guaranteed to later get a mouse_up() call.

I think it is a bad idea to have two mouse modes getting drag callbacks at the same time, doing two actions at once. So the second button press terminates the drag on the first button mouse mode and the first button mode gets the mouse_up() call when the second button is pressed (even though the first button was not released -- the mouse_up() callback strictly means the drag is ended).

The other bug that ISOLDE freaks out in VR is not specific enough to pursue. Please state clearly if the tug mode remained engaged as if the VR button was still down when in fact it had been released. Perhaps only Jozef knows those details -- they will be needed to get anywhere. The VR button handling is entirely separate from mouse button handling.

Please put distinct bugs in separate tickets so they can be closed independently.

Please report ISOLDE VR bug as another ticket if some detail of the problem can be provided.

Note: See TracTickets for help on using tickets.