Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2017-11-02 10:25:47 +0300
committerCampbell Barton <ideasman42@gmail.com>2017-11-02 10:25:47 +0300
commit08141260ffa619fef1871ccd446b8a59a7b111ca (patch)
tree7b226f6bf1fc81cc50339278d390b9539efc4495 /source/blender/editors/interface/interface_regions.c
parentd2e39edae8d5c6c2062b0a03f63b33e007c4d5b2 (diff)
parente32c1bd5d03148b123c8d2664b6164fe5cbd5c12 (diff)
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/editors/interface/interface_regions.c')
-rw-r--r--source/blender/editors/interface/interface_regions.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/source/blender/editors/interface/interface_regions.c b/source/blender/editors/interface/interface_regions.c
index cd3aa2095b0..81a7640610d 100644
--- a/source/blender/editors/interface/interface_regions.c
+++ b/source/blender/editors/interface/interface_regions.c
@@ -3058,7 +3058,6 @@ int UI_pie_menu_invoke(struct bContext *C, const char *idname, const wmEvent *ev
{
uiPieMenu *pie;
uiLayout *layout;
- Menu menu;
MenuType *mt = WM_menutype_find(idname, true);
if (mt == NULL) {
@@ -3073,14 +3072,7 @@ int UI_pie_menu_invoke(struct bContext *C, const char *idname, const wmEvent *ev
pie = UI_pie_menu_begin(C, IFACE_(mt->label), ICON_NONE, event);
layout = UI_pie_menu_layout(pie);
- menu.layout = layout;
- menu.type = mt;
-
- if (G.debug & G_DEBUG_WM) {
- printf("%s: opening menu \"%s\"\n", __func__, idname);
- }
-
- mt->draw(C, &menu);
+ UI_menutype_draw(C, mt, layout);
UI_pie_menu_end(C, pie);
@@ -3291,7 +3283,6 @@ int UI_popup_menu_invoke(bContext *C, const char *idname, ReportList *reports)
{
uiPopupMenu *pup;
uiLayout *layout;
- Menu menu;
MenuType *mt = WM_menutype_find(idname, true);
if (mt == NULL) {
@@ -3306,14 +3297,7 @@ int UI_popup_menu_invoke(bContext *C, const char *idname, ReportList *reports)
pup = UI_popup_menu_begin(C, IFACE_(mt->label), ICON_NONE);
layout = UI_popup_menu_layout(pup);
- menu.layout = layout;
- menu.type = mt;
-
- if (G.debug & G_DEBUG_WM) {
- printf("%s: opening menu \"%s\"\n", __func__, idname);
- }
-
- mt->draw(C, &menu);
+ UI_menutype_draw(C, mt, layout);
UI_popup_menu_end(C, pup);