How can I detect right click event on a lemur Button?


#1

1-how can I detect right click event on a lemur Button?

2-and is it possible to combine and use the Ctrl key and Left mouse button on a lemur button?


#2

Add a mouse or cursor listener to the button that reacts to the right button.

For this you have two options… have a key listener for control that keeps a boolean that you can check in your other listeners.

Or setup a Ctrl + left mouse mapping in InputMapper and listen to that. Combine that with a ButtonAction.Hover listener on the button to only engage the ctrl + left when you are over the button. Coordinating this second approach can get kind of tricky if you use it in a lot of places.