diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-02-24 21:42:04 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-02-24 21:42:04 +0000 |
| commit | 551170d94067614ce42d853f09bee908ed8ff9c2 (patch) | |
| tree | 5c3021f70b3e2ecc737efa6b60992d99866bbc37 | |
| parent | input: pointer-leave: reset 'active-surface' in terminal (diff) | |
input: pointer-motion/button: ignore actions in non-main surfaces
| -rw-r--r-- | input.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -716,6 +716,9 @@ wl_pointer_motion(void *data, struct wl_pointer *wl_pointer, assert(term != NULL); + if (term->active_surface != TERM_SURF_GRID) + return; + int x = wl_fixed_to_int(surface_x) * term->scale; int y = wl_fixed_to_int(surface_y) * term->scale; @@ -771,6 +774,10 @@ wl_pointer_button(void *data, struct wl_pointer *wl_pointer, } assert(term != NULL); + + if (term->active_surface != TERM_SURF_GRID) + return; + search_cancel(term); switch (state) { |
