diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2016-02-19 13:28:03 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2016-02-19 13:28:03 +0000 |
commit | 95adc0e6bacb32108fd6557e2e5ddeaaaa4fd58e (patch) | |
tree | feaf5c9c936e2d83378087ca7325a13a85df0c29 /window-copy.c | |
parent | 02753ba9ea89bbeed1a5bba4d5b3a3c6a41e775e (diff) | |
download | rtmux-95adc0e6bacb32108fd6557e2e5ddeaaaa4fd58e.tar.gz rtmux-95adc0e6bacb32108fd6557e2e5ddeaaaa4fd58e.tar.bz2 rtmux-95adc0e6bacb32108fd6557e2e5ddeaaaa4fd58e.zip |
When a mouse drag is finished, fire a MouseUp key press, instead of doing the
drag end in code. From Stephen Coakley.
Diffstat (limited to 'window-copy.c')
-rw-r--r-- | window-copy.c | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/window-copy.c b/window-copy.c index 009ed246..d345f246 100644 --- a/window-copy.c +++ b/window-copy.c @@ -2248,7 +2248,7 @@ window_copy_start_drag(struct client *c, struct mouse_event *m) return; c->tty.mouse_drag_update = window_copy_drag_update; - c->tty.mouse_drag_release = window_copy_drag_release; + c->tty.mouse_drag_release = NULL; /* will fire MouseUp key */ window_copy_update_cursor(wp, x, y); window_copy_start_selection(wp); @@ -2275,16 +2275,3 @@ window_copy_drag_update(__unused struct client *c, struct mouse_event *m) if (window_copy_update_selection(wp, 1)) window_copy_redraw_selection(wp, old_cy); } - -void -window_copy_drag_release(__unused struct client *c, struct mouse_event *m) -{ - struct window_pane *wp; - - wp = cmd_mouse_pane(m, NULL, NULL); - if (wp == NULL || wp->mode != &window_copy_mode) - return; - - window_copy_copy_selection(wp, NULL); - window_pane_reset_mode(wp); -} |