aboutsummaryrefslogtreecommitdiffstats
path: root/sway/input/cursor.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/input/cursor.c')
-rw-r--r--sway/input/cursor.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sway/input/cursor.c b/sway/input/cursor.c
index 3b70b471..6208ce32 100644
--- a/sway/input/cursor.c
+++ b/sway/input/cursor.c
@@ -726,13 +726,13 @@ void dispatch_cursor_button(struct sway_cursor *cursor,
726 } 726 }
727 727
728 // Via mod+click 728 // Via mod+click
729 struct sway_container *floater = cont;
730 while (floater->parent->layout != L_FLOATING) {
731 floater = floater->parent;
732 }
733 uint32_t btn_resize = config->floating_mod_inverse ? 729 uint32_t btn_resize = config->floating_mod_inverse ?
734 BTN_LEFT : BTN_RIGHT; 730 BTN_LEFT : BTN_RIGHT;
735 if (button == btn_resize) { 731 if (mod_pressed && button == btn_resize) {
732 struct sway_container *floater = cont;
733 while (floater->parent->layout != L_FLOATING) {
734 floater = floater->parent;
735 }
736 edge = 0; 736 edge = 0;
737 edge |= cursor->cursor->x > floater->x + floater->width / 2 ? 737 edge |= cursor->cursor->x > floater->x + floater->width / 2 ?
738 WLR_EDGE_RIGHT : WLR_EDGE_LEFT; 738 WLR_EDGE_RIGHT : WLR_EDGE_LEFT;