diff --git a/.config/tmux/tmux.conf b/.config/tmux/tmux.conf index f80d123..05baed7 100644 --- a/.config/tmux/tmux.conf +++ b/.config/tmux/tmux.conf @@ -99,8 +99,13 @@ bind -n MouseDragEnd1Status { setenv -u tmux_move_direction } -# TODO: Move to beginning or end like in MouseDragEnd1Status -# bind -n MouseDragEnd1StatusDefault display-message "#{e|>|f|0:#{mouse_x},#{e|/|f:213,2}}" +# TODO: do nothing on drags that don't start on a window name +bind -n MouseDragEnd1StatusDefault \ + if -F "#{e|>|f|0:#{mouse_x},#{e|/|f:#{window_width},2}}" { + move-window -t #{last_window_index} -a + } { + move-window -t0 + } # Repeatable window-movement bindings bind -r \{ swap-pane -U