acme: Don't move the mouse if button depressed

Fixes #19
This commit is contained in:
Ben Huntsman 2022-05-12 16:52:00 -07:00 committed by Dan Cross
parent 964ac74cdc
commit 686f5d035c

View file

@ -149,7 +149,10 @@ coladd(Column *c, Window *w, Window *clone, int y)
savemouse(w); savemouse(w);
/* near the button, but in the body */ /* near the button, but in the body */
moveto(mousectl, addpt(w->tag.scrollr.max, Pt(3, 3))); /* don't move the mouse to the new window if a mouse button is depressed */
if(!mousectl->m.buttons)
moveto(mousectl, addpt(w->tag.scrollr.max, Pt(3, 3)));
barttext = &w->body; barttext = &w->body;
return w; return w;
} }