diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-07-13 20:13:44 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-07-13 20:16:35 +0300 |
commit | cca87ccc753a85b447872a259c9d3e3f07ec1c13 (patch) | |
tree | 9b2e9d8aa5d45153affaef7ad648a811156fbd8c /source/blender/makesrna/intern/rna_ui_api.c | |
parent | af0fc660499a63b367dcc63222d0baee93aa665c (diff) |
UI: remove space/region from popover args
Instead use global panel-type list.
Diffstat (limited to 'source/blender/makesrna/intern/rna_ui_api.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_ui_api.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/source/blender/makesrna/intern/rna_ui_api.c b/source/blender/makesrna/intern/rna_ui_api.c index 74117b43d91..c9ce9ae7961 100644 --- a/source/blender/makesrna/intern/rna_ui_api.c +++ b/source/blender/makesrna/intern/rna_ui_api.c @@ -277,8 +277,7 @@ static void rna_uiItemM( static void rna_uiItemPopoverPanel( uiLayout *layout, bContext *C, - int space_type, int region_type, const char *panel_type, - const char *name, const char *text_ctxt, + const char *panel_type, const char *name, const char *text_ctxt, bool translate, int icon, int icon_value) { /* Get translated name (label). */ @@ -288,7 +287,7 @@ static void rna_uiItemPopoverPanel( icon = icon_value; } - uiItemPopoverPanel(layout, C, space_type, region_type, panel_type, name, icon); + uiItemPopoverPanel(layout, C, panel_type, name, icon); } static void rna_uiItemPopoverPanelFromGroup( @@ -717,11 +716,7 @@ void RNA_api_ui_layout(StructRNA *srna) func = RNA_def_function(srna, "popover", "rna_uiItemPopoverPanel"); RNA_def_function_flag(func, FUNC_USE_CONTEXT); - parm = RNA_def_enum(func, "space_type", rna_enum_space_type_items, 0, "Space Type", ""); - RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); - parm = RNA_def_enum(func, "region_type", rna_enum_region_type_items, RGN_TYPE_WINDOW, "Region Type", ""); - RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); - parm = RNA_def_string(func, "panel_type", NULL, 0, "", "Identifier of the panel"); + parm = RNA_def_string(func, "panel", NULL, 0, "", "Identifier of the panel"); api_ui_item_common(func); RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); parm = RNA_def_property(func, "icon_value", PROP_INT, PROP_UNSIGNED); |