[Bf-blender-cvs] [97c7db168db] blender2.8: UI: auto open adjacent pulldown and popover buttons.
Brecht Van Lommel
noreply at git.blender.org
Sun Apr 29 09:24:31 CEST 2018
Commit: 97c7db168db2fdcf7049ca07d568f08bb52ed4de
Author: Brecht Van Lommel
Date: Sun Apr 29 09:06:17 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB97c7db168db2fdcf7049ca07d568f08bb52ed4de
UI: auto open adjacent pulldown and popover buttons.
===================================================================
M source/blender/editors/interface/interface_handlers.c
===================================================================
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c
index 3214bd8bb38..622c76079c0 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -7628,7 +7628,7 @@ static void button_activate_state(bContext *C, uiBut *but, uiHandleButtonState s
button_tooltip_timer_reset(C, but);
/* automatic open pulldown block timer */
- if (ELEM(but->type, UI_BTYPE_BLOCK, UI_BTYPE_PULLDOWN)) {
+ if (ELEM(but->type, UI_BTYPE_BLOCK, UI_BTYPE_PULLDOWN, UI_BTYPE_POPOVER)) {
if (data->used_mouse && !data->autoopentimer) {
int time;
@@ -10004,7 +10004,7 @@ static int ui_handler_region_menu(bContext *C, const wmEvent *event, void *UNUSE
(ELEM(but->type, UI_BTYPE_PULLDOWN, UI_BTYPE_POPOVER)) &&
(but_other = ui_but_find_mouse_over(ar, event)) &&
(but != but_other) &&
- (but->type == but_other->type))
+ (ELEM(but_other->type, UI_BTYPE_PULLDOWN, UI_BTYPE_POPOVER)))
{
/* if mouse moves to a different root-level menu button,
* open it to replace the current menu */
More information about the Bf-blender-cvs
mailing list