summaryrefslogtreecommitdiffstats
path: root/sway/input
diff options
context:
space:
mode:
authorLibravatar Drew DeVault <sir@cmpwn.com>2018-07-06 06:28:01 -0700
committerLibravatar GitHub <noreply@github.com>2018-07-06 06:28:01 -0700
commit3d2595b1028ce1f7cf0ceff673e7180c6c991afb (patch)
treea645930a9b105185a5f2dbddbe8ca8acf50a4559 /sway/input
parentAttach destroy handler earlier (diff)
parentMerge pull request #2217 from RedSoxFan/fix-663 (diff)
downloadsway-3d2595b1028ce1f7cf0ceff673e7180c6c991afb.tar.gz
sway-3d2595b1028ce1f7cf0ceff673e7180c6c991afb.tar.zst
sway-3d2595b1028ce1f7cf0ceff673e7180c6c991afb.zip
Merge branch 'master' into remove-input-fix
Diffstat (limited to 'sway/input')
-rw-r--r--sway/input/cursor.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/sway/input/cursor.c b/sway/input/cursor.c
index 944e35aa..a2f11557 100644
--- a/sway/input/cursor.c
+++ b/sway/input/cursor.c
@@ -255,14 +255,12 @@ void dispatch_cursor_button(struct sway_cursor *cursor,
255 wlr_layer_surface_from_wlr_surface(surface); 255 wlr_layer_surface_from_wlr_surface(surface);
256 if (layer->current.keyboard_interactive) { 256 if (layer->current.keyboard_interactive) {
257 seat_set_focus_layer(cursor->seat, layer); 257 seat_set_focus_layer(cursor->seat, layer);
258 return;
259 } 258 }
260 } 259 } else if (surface && cont && cont->type != C_VIEW) {
261 // Avoid moving keyboard focus from a surface that accepts it to one 260 // Avoid moving keyboard focus from a surface that accepts it to one
262 // that does not unless the change would move us to a new workspace. 261 // that does not unless the change would move us to a new workspace.
263 // 262 //
264 // This prevents, for example, losing focus when clicking on swaybar. 263 // This prevents, for example, losing focus when clicking on swaybar.
265 if (surface && cont && cont->type != C_VIEW) {
266 struct sway_container *new_ws = cont; 264 struct sway_container *new_ws = cont;
267 if (new_ws && new_ws->type != C_WORKSPACE) { 265 if (new_ws && new_ws->type != C_WORKSPACE) {
268 new_ws = container_parent(new_ws, C_WORKSPACE); 266 new_ws = container_parent(new_ws, C_WORKSPACE);