Why not just let them both through always?
Index: server-client.c =================================================================== RCS file: /cvs/src/usr.bin/tmux/server-client.c,v retrieving revision 1.115 diff -u -p -r1.115 server-client.c --- server-client.c 31 Jan 2014 14:19:24 -0000 1.115 +++ server-client.c 14 Feb 2014 13:22:03 -0000 @@ -324,9 +324,9 @@ server_client_check_mouse(struct client else if (statusat > 0 && m->y >= (u_int)statusat) m->y = statusat - 1; - /* Is this a pane selection? Allow down only in copy mode. */ + /* Is this a pane selection? */ if (options_get_number(oo, "mouse-select-pane") && - (m->event == MOUSE_EVENT_DOWN || wp->mode != &window_copy_mode)) { + (m->event == MOUSE_EVENT_DOWN || m->event == MOUSE_EVENT_WHEEL)) { window_set_active_at(wp->window, m->x, m->y); server_redraw_window_borders(wp->window); wp = wp->window->active; /* may have changed */ On Sat, Feb 08, 2014 at 10:16:51PM +0000, Balazs Kezes wrote: > If you have mouse-select-pane enabled you can switch panes via the mouse > wheel. But if the current pane is in copy mode this doesn't work. The > attached patch fixes this. > > -- > Balazs > diff --git a/server-client.c b/server-client.c > index 77e6de7..6001d64 100644 > --- a/server-client.c > +++ b/server-client.c > @@ -318,9 +318,12 @@ server_client_check_mouse(struct client *c, struct > window_pane *wp) > else if (statusat > 0 && m->y >= (u_int)statusat) > m->y = statusat - 1; > > - /* Is this a pane selection? Allow down only in copy mode. */ > + /* Is this a pane selection? Allow only down and wheel in copy mode. */ > + int event_ok_in_copy_mode = 0; > + if (m->event == MOUSE_EVENT_DOWN || m->event == MOUSE_EVENT_WHEEL) > + event_ok_in_copy_mode = 1; > if (options_get_number(oo, "mouse-select-pane") && > - (m->event == MOUSE_EVENT_DOWN || wp->mode != &window_copy_mode)) { > + (event_ok_in_copy_mode || wp->mode != &window_copy_mode)) { > window_set_active_at(wp->window, m->x, m->y); > server_redraw_window_borders(wp->window); > wp = wp->window->active; /* may have changed */ > ------------------------------------------------------------------------------ > Managing the Performance of Cloud-Based Applications > Take advantage of what the Cloud has to offer - Avoid Common Pitfalls. > Read the Whitepaper. > http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk > _______________________________________________ > tmux-users mailing list > tmux-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/tmux-users ------------------------------------------------------------------------------ Android apps run on BlackBerry 10 Introducing the new BlackBerry 10.2.1 Runtime for Android apps. Now with support for Jelly Bean, Bluetooth, Mapview and more. Get your Android app in front of a whole new audience. Start now. http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk _______________________________________________ tmux-users mailing list tmux-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/tmux-users