Small tweak for using transparent+overlapping regions:

On mouse-over these regions now become active always (as if they were opaque).
This active state is used by many tools, or for drawing cursors.

Currently, all events (if not handled by button region) are passed on anyway to
the underlying region.

Visible errors were for example drawing the paint brush circle.
This commit is contained in:
Ton Roosendaal 2012-12-17 09:02:43 +00:00
parent 8a4ba61786
commit 359b683e1e

@ -1291,9 +1291,12 @@ void ED_screen_set_subwinactive(bContext *C, wmEvent *event)
break;
}
if (sa) {
/* make overlap active when mouse over */
for (ar = sa->regionbase.first; ar; ar = ar->next) {
if (BLI_rcti_isect_pt_v(&ar->winrct, &event->x))
if (BLI_rcti_isect_pt_v(&ar->winrct, &event->x)) {
scr->subwinactive = ar->swinid;
break;
}
}
}
else