Merge branch 'master' into blender2.8
authorCampbell Barton <ideasman42@gmail.com>
Fri, 25 May 2018 08:52:53 +0000 (10:52 +0200)
committerCampbell Barton <ideasman42@gmail.com>
Fri, 25 May 2018 08:52:53 +0000 (10:52 +0200)
source/blender/editors/interface/interface.c
source/blender/windowmanager/intern/wm_keymap.c

index e4b298fecf0c8e3a43707714646b61725a72be97..683db8985c96b5a4603ae48849aa1bb4faa724e8 100644 (file)
@@ -2887,7 +2887,7 @@ void ui_but_update_ex(uiBut *but, const bool validate)
        switch (but->type) {
 
                case UI_BTYPE_MENU:
-                       if (BLI_rctf_size_x(&but->rect) > 24.0f) {
+                       if (BLI_rctf_size_x(&but->rect) >= (UI_UNIT_X * 2)) {
                                /* only needed for menus in popup blocks that don't recreate buttons on redraw */
                                if (but->block->flag & UI_BLOCK_LOOP) {
                                        if (but->rnaprop && (RNA_property_type(but->rnaprop) == PROP_ENUM)) {
index 9d26c7e92d536aaec163ef958660bf86819cf300..f2387846fd22e19d4b181ea3f1b7bf1c23c7e948 100644 (file)
@@ -1215,9 +1215,11 @@ static wmKeyMapItem *wm_keymap_item_find_props(
 
        /* look into multiple handler lists to find the item */
        if (win) {
-               found = wm_keymap_item_find_handlers(C, &win->modalhandlers, opname, opcontext, properties, is_strict, is_hotkey, r_keymap);
+               found = wm_keymap_item_find_handlers(
+                       C, &win->modalhandlers, opname, opcontext, properties, is_strict, is_hotkey, r_keymap);
                if (found == NULL) {
-                       found = wm_keymap_item_find_handlers(C, &win->handlers, opname, opcontext, properties, is_strict, is_hotkey, r_keymap);
+                       found = wm_keymap_item_find_handlers(
+                               C, &win->handlers, opname, opcontext, properties, is_strict, is_hotkey, r_keymap);
                }
        }