# Pass escape immediately to vim
set -sg escape-time 0
+# Default word-separators are: "!\"#$%&'()*+,-./:;<=>?@[\\]^`{|}~"
+# Remove some characters to have sane {mouse_word} on filenames
+set-window-option -g word-separators "!\"#$%&'()*+,:;<=>?@[\\]^`{|}~"
+
# Copy to X11 clipboard
-bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -in -selection clipboard'
+bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -in -selection clipboard'
+
+# Fire drag&drop for files
+bind-key -n DoubleClick1Pane run-shell -c '#{pane_current_path}' "dragon -x '#{mouse_word}'"
-bind-key m set-option -g mouse on \; display 'Mouse: ON'
-bind-key M set-option -g mouse off \; display 'Mouse: OFF'
+bind-key m "set-option -g mouse on \; display 'Mouse: ON'"
+bind-key M "set-option -g mouse off \; display 'Mouse: OFF'"
# Let split et alii use the pane's current path as current path of the new pane
-bind '"' split-window -c "#{pane_current_path}"
-bind % split-window -h -c "#{pane_current_path}"
-bind c new-window -c "#{pane_current_path}"
+bind-key '"' split-window -c "#{pane_current_path}"
+bind-key % split-window -h -c "#{pane_current_path}"
+bind-key c new-window -c "#{pane_current_path}"
# Pass home and end keys
bind-key -n Home send Escape "OH"