[Suggestion] Left/right click detection in UI

Editor Discussion
Patch 2.0.4 added a way for buttons to filter mouse clicks.

This allows us to create buttons that only start events with left/right clicks.

BUT, we still can't differ between left/right clicks on the same spot in the UI.

The problem is that the dialog item button that only accepts left clicks eats up a right click.
If the right click would fall through that dialog item button, it could be caught by another dialog.
Then we could stack 2 buttons: left & right click detection and improve our own UIs with that.

I don't know how the click registering works inside an engine, but maybe that would be possible.
As JademusSreg informed me, we can find out the used mouse button.

(Dialog item mouse button) == Right

There has been a function added that returns the mouse button that was used to click on a button.

I'm going to improve my UIs with this and I hope a few other modders see this and make use of this. :)

Join the Conversation

Return to Forum