diff options
author | S. Christoffer Eliesen <christoffer@eliesen.no> | 2015-10-23 14:12:53 +0200 |
---|---|---|
committer | S. Christoffer Eliesen <christoffer@eliesen.no> | 2015-10-23 16:35:48 +0200 |
commit | 1f08106b0a006d00e7d74701e4196c1f99e4ac36 (patch) | |
tree | 8f80c3a480ba05e891b2c6096988942ecf596e13 | |
parent | Merge pull request #201 from sce/cmd_results (diff) | |
download | sway-1f08106b0a006d00e7d74701e4196c1f99e4ac36.tar.gz sway-1f08106b0a006d00e7d74701e4196c1f99e4ac36.tar.zst sway-1f08106b0a006d00e7d74701e4196c1f99e4ac36.zip |
handlers: Don't switch output when mouse button is pressed.
(E.g. if the user is using a scrollbar at the edge of the screen then
switching workspace would cancel the scroll.)
-rw-r--r-- | sway/handlers.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sway/handlers.c b/sway/handlers.c index 24105130..5acdd096 100644 --- a/sway/handlers.c +++ b/sway/handlers.c | |||
@@ -362,7 +362,8 @@ static bool handle_pointer_motion(wlc_handle handle, uint32_t time, const struct | |||
362 | // | 362 | // |
363 | // Since this doesn't currently support moving windows between outputs we | 363 | // Since this doesn't currently support moving windows between outputs we |
364 | // don't do the switch if the pointer is in a mode. | 364 | // don't do the switch if the pointer is in a mode. |
365 | if (config->seamless_mouse && !pointer_state.mode) { | 365 | if (config->seamless_mouse && !pointer_state.mode && |
366 | !pointer_state.left.held && !pointer_state.right.held && !pointer_state.scroll.held) { | ||
366 | swayc_t *output = swayc_active_output(); | 367 | swayc_t *output = swayc_active_output(); |
367 | 368 | ||
368 | // TODO: This implementation is naïve: We assume all outputs are | 369 | // TODO: This implementation is naïve: We assume all outputs are |