alols / xcape

Linux utility to configure modifier keys to act as other keys when pressed and released on their own.
GNU General Public License v3.0
2.1k stars 115 forks source link

Feature request: Option to listen to mouse click events #51

Closed gandalf3 closed 9 years ago

gandalf3 commented 9 years ago

In my use case I'm using Super on it's own to start dmenu, and Super in combination with mouse 1 and mouse 3 (left and right click) for window moving/resizing.

The problem occurs when I move windows around fast enough that I release Super before the timeout is up (quite reasonable when doing small tweaks to window size etc.). When this happens, xcape ends up calling the openbox shortcut and running dmenu even though I pressed some mouse buttons while Super was held.

I tried fiddling with the timeout a bit, and it kind of works, but either it still occasionally starts dmenu at undesired times, or I have to stab Super in a really staccato fashion when I actually want dmenu.

Would it be possible to have xcape listen for mouse button press events in addition to the way it currently listens for keypress events?

TL;DR: Would it be possible to make it so that when Super+Left Mouse is pressed within the timeout, the alternate keypresses are not generated?

alols commented 9 years ago

This was a bug, not a missing feature :) thanks for pointing it out. Please reopen if the new version doesn’t work for you.

gandalf3 commented 9 years ago

Wow, that was fast! Works perfectly, thanks :)