Bugfix #25840
UI bug: when a button has an open menu, the menu closed on any mouse-over of other buttons in this panel. That's not too bad, but it didn't check for whether the mouse was already inside the menu itself (respecting safety region). The bug showed error on zoomed in UI, using FPS presets, in case the menu-button was drawing aligned with other buttons. A real boundary case... :)
This commit is contained in:
@@ -5238,8 +5238,15 @@ static int ui_handle_button_event(bContext *C, wmEvent *event, uiBut *but)
|
||||
retval= WM_UI_HANDLER_CONTINUE;
|
||||
}
|
||||
else if(data->state == BUTTON_STATE_MENU_OPEN) {
|
||||
/* check for exit because of mouse-over another button */
|
||||
switch(event->type) {
|
||||
case MOUSEMOVE: {
|
||||
case MOUSEMOVE:
|
||||
|
||||
if(data->menu && data->menu->region)
|
||||
if(ui_mouse_inside_region(data->menu->region, event->x, event->y))
|
||||
break;
|
||||
|
||||
{
|
||||
uiBut *bt= ui_but_find_mouse_over(ar, event->x, event->y);
|
||||
|
||||
if(bt && bt->active != data) {
|
||||
|
||||
Reference in New Issue
Block a user