UI: fix incorrect collapse menu button alignment.
authorHarley Acheson <harley>
Fri, 4 Jan 2019 14:12:12 +0000 (15:12 +0100)
committerBrecht Van Lommel <brechtvanlommel@gmail.com>
Fri, 4 Jan 2019 14:27:51 +0000 (15:27 +0100)
Differential Revision: https://developer.blender.org/D4151

source/blender/editors/interface/interface_layout.c

index e6c3d968a2709decd14ad2c60ea34308e01d4d0e..45c0498cda6ece09412390f7f1dc679e51136acc 100644 (file)
@@ -2247,7 +2247,9 @@ static uiBut *ui_item_menu(
        }
        else if (icon) {
                but = uiDefIconMenuBut(block, func, arg, icon, 0, 0, w, h, tip);
-               UI_but_drawflag_enable(but, UI_BUT_ICON_LEFT);
+               if (force_menu) {
+                       UI_but_drawflag_enable(but, UI_BUT_ICON_LEFT);
+               }
        }
        else {
                but = uiDefMenuBut(block, func, arg, name, 0, 0, w, h, tip);