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:
Diffstat (limited to 'source/blender/makesrna/intern/rna_space.c')
-rw-r--r--source/blender/makesrna/intern/rna_space.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c
index 7b0f3bf708c..c26ba5b022d 100644
--- a/source/blender/makesrna/intern/rna_space.c
+++ b/source/blender/makesrna/intern/rna_space.c
@@ -2312,6 +2312,18 @@ static int rna_FileBrowser_FSMenuEntry_name_get_editable(PointerRNA *ptr,
return fsm->save ? PROP_EDITABLE : 0;
}
+static int rna_FileBrowser_FSMenuEntry_icon_get(PointerRNA *ptr)
+{
+ FSMenuEntry *fsm = ptr->data;
+ return ED_fsmenu_entry_get_icon(fsm);
+}
+
+static void rna_FileBrowser_FSMenuEntry_icon_set(PointerRNA *ptr, int value)
+{
+ FSMenuEntry *fsm = ptr->data;
+ ED_fsmenu_entry_set_icon(fsm, value);
+}
+
static bool rna_FileBrowser_FSMenuEntry_use_save_get(PointerRNA *ptr)
{
FSMenuEntry *fsm = ptr->data;
@@ -5573,6 +5585,11 @@ static void rna_def_filemenu_entry(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Name", "");
RNA_def_struct_name_property(srna, prop);
+ prop = RNA_def_property(srna, "icon", PROP_INT, PROP_NONE);
+ RNA_def_property_int_funcs(
+ prop, "rna_FileBrowser_FSMenuEntry_icon_get", "rna_FileBrowser_FSMenuEntry_icon_set", NULL);
+ RNA_def_property_ui_text(prop, "Icon", "");
+
prop = RNA_def_property(srna, "use_save", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_funcs(prop, "rna_FileBrowser_FSMenuEntry_use_save_get", NULL);
RNA_def_property_ui_text(