diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-11-09 23:20:40 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-11-11 01:06:54 +0300 |
commit | 5c6e3337801b493926210e96237be2b495fc5d1b (patch) | |
tree | 5ca4bd778c2d552a7eaf0645c3c1bc6be86d9e5d /source/blender/editors/space_buttons/buttons_texture.c | |
parent | 2b107beffd9b408ac1464288d07ee96214c09a30 (diff) |
UI Refactor T41640
Make the UI API more consistent and reduce confusion with some naming.
mainly:
- API function calls
- enum values
some internal static functions have been left for now
Diffstat (limited to 'source/blender/editors/space_buttons/buttons_texture.c')
-rw-r--r-- | source/blender/editors/space_buttons/buttons_texture.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/editors/space_buttons/buttons_texture.c b/source/blender/editors/space_buttons/buttons_texture.c index 020d477fc39..cfdb5b0f8ba 100644 --- a/source/blender/editors/space_buttons/buttons_texture.c +++ b/source/blender/editors/space_buttons/buttons_texture.c @@ -576,9 +576,9 @@ static void template_texture_user_menu(bContext *C, uiLayout *layout, void *UNUS else BLI_snprintf(name, UI_MAX_NAME_STR, " %s", user->name); - but = uiDefIconTextBut(block, BUT, 0, user->icon, name, 0, 0, UI_UNIT_X * 4, UI_UNIT_Y, + but = uiDefIconTextBut(block, UI_BTYPE_BUT, 0, user->icon, name, 0, 0, UI_UNIT_X * 4, UI_UNIT_Y, NULL, 0.0, 0.0, 0.0, 0.0, ""); - uiButSetNFunc(but, template_texture_select, MEM_dupallocN(user), NULL); + UI_but_funcN_set(but, template_texture_select, MEM_dupallocN(user), NULL); last_category = user->category; } @@ -620,9 +620,9 @@ void uiTemplateTextureUser(uiLayout *layout, bContext *C) } /* some cosmetic tweaks */ - uiButSetMenuFromPulldown(but); + UI_but_type_set_menu_from_pulldown(but); - but->flag &= ~UI_ICON_SUBMENU; + but->flag &= ~UI_BUT_ICON_SUBMENU; } /************************* Texture Show **************************/ @@ -675,9 +675,9 @@ void uiTemplateTextureShow(uiLayout *layout, bContext *C, PointerRNA *ptr, Prope uiBlock *block = uiLayoutGetBlock(layout); uiBut *but; - but = uiDefIconBut(block, BUT, 0, ICON_BUTS, 0, 0, UI_UNIT_X, UI_UNIT_Y, + but = uiDefIconBut(block, UI_BTYPE_BUT, 0, ICON_BUTS, 0, 0, UI_UNIT_X, UI_UNIT_Y, NULL, 0.0, 0.0, 0.0, 0.0, "Show texture in texture tab"); - uiButSetFunc(but, template_texture_show, user->ptr.data, user->prop); + UI_but_func_set(but, template_texture_show, user->ptr.data, user->prop); } } |