* src/xterm.c (handle_one_event): Don't select xwidget window
on button event if the button pressed actually represents the
scroll wheel.
event->xbutton.button, event->xbutton.state,
event->xbutton.time);
- if (!EQ (selected_window, xvw->w))
+ if (!EQ (selected_window, xvw->w)
+ && ((event->xbutton.button < 3)
+ || (event->xbutton.button > 7)))
{
inev.ie.kind = SELECT_WINDOW_EVENT;
inev.ie.frame_or_window = xvw->w;