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:
authorJoshua Leung <aligorith@gmail.com>2009-10-15 14:13:59 +0400
committerJoshua Leung <aligorith@gmail.com>2009-10-15 14:13:59 +0400
commit384a1b5a5c15cfc5311f3865bde095d89130cfa5 (patch)
tree2f6ac27c59188efb2db84f9539111971ceab9c57 /source/blender/makesrna/intern/rna_ui_api.c
parent29e738f60c1cafc33b8006425f1fad4c1721d971 (diff)
UI Templates: RNA-Path Builder (Skeleton Code)
Added a base-template for editing/creating RNA-Paths. This is now used for KeyingSets and Driver UI's, so that when the actual magic gets put in, it will work.
Diffstat (limited to 'source/blender/makesrna/intern/rna_ui_api.c')
-rw-r--r--source/blender/makesrna/intern/rna_ui_api.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_ui_api.c b/source/blender/makesrna/intern/rna_ui_api.c
index 79465f64daf..cce8fb0fef7 100644
--- a/source/blender/makesrna/intern/rna_ui_api.c
+++ b/source/blender/makesrna/intern/rna_ui_api.c
@@ -266,6 +266,16 @@ void RNA_api_ui_layout(StructRNA *srna)
RNA_def_property_flag(parm, PROP_REQUIRED);
parm= RNA_def_string(func, "text", "", 0, "", "Custom label to display in UI.");
+ func= RNA_def_function(srna, "template_path_builder", "uiTemplatePathBuilder");
+ RNA_def_function_flag(func, FUNC_USE_CONTEXT);
+ parm= RNA_def_pointer(func, "data", "AnyType", "", "Data from which to take property.");
+ RNA_def_property_flag(parm, PROP_REQUIRED|PROP_RNAPTR|PROP_NEVER_NULL);
+ parm= RNA_def_string(func, "property", "", 0, "", "Identifier of property in data.");
+ RNA_def_property_flag(parm, PROP_REQUIRED);
+ parm= RNA_def_pointer(func, "root", "ID", "", "ID-block from which path is evaluated from.");
+ RNA_def_property_flag(parm, PROP_REQUIRED|PROP_RNAPTR);
+ parm= RNA_def_string(func, "text", "", 0, "", "Custom label to display in UI.");
+
func= RNA_def_function(srna, "template_modifier", "uiTemplateModifier");
parm= RNA_def_pointer(func, "data", "Modifier", "", "Modifier data.");
RNA_def_property_flag(parm, PROP_REQUIRED|PROP_RNAPTR|PROP_NEVER_NULL);