Skip to content

bugfix: Singular right-click logic now always executes after a double right-click #1454

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Stubbjax
Copy link

This change fixes single right-click behaviour not being performed on a double right-click.

When a double right-click is performed, the singular right-click logic is potentially not executed as the isClick condition may return false. This is due to the double-click logic not updating the mouse down and mouse up timestamps that determine whether the user is holding down the mouse button (for camera dragging purposes). This means that there is a brief window after cancelling a context command (unit abilities, Beacon placement, General's Powers, etc.) that a unit will not perform the respective right-click action on the second right-click.

Note: Double-clicking very fast will cause the double-click to be within the first click's timestamp window and isClick will thus succeed. The issue is most noticeable when exiting context modes via a 'slower' double right-click.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant