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/makesrna.c')
-rw-r--r--source/blender/makesrna/intern/makesrna.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/makesrna.c b/source/blender/makesrna/intern/makesrna.c
index ae414489f52..0f69adf6298 100644
--- a/source/blender/makesrna/intern/makesrna.c
+++ b/source/blender/makesrna/intern/makesrna.c
@@ -482,8 +482,14 @@ static const char *rna_type_type_name(PropertyRNA *prop)
case PROP_BOOLEAN:
return "bool";
case PROP_INT:
- case PROP_ENUM:
return "int";
+ case PROP_ENUM: {
+ EnumPropertyRNA *eprop = (EnumPropertyRNA *)prop;
+ if (eprop->native_enum_type) {
+ return eprop->native_enum_type;
+ }
+ return "int";
+ }
case PROP_FLOAT:
return "float";
case PROP_STRING:
@@ -4331,6 +4337,7 @@ static void rna_generate(BlenderRNA *brna, FILE *f, const char *filename, const
fprintf(f, "#include \"DNA_ID.h\"\n");
fprintf(f, "#include \"DNA_scene_types.h\"\n");
+ fprintf(f, "#include \"DNA_node_types.h\"\n");
fprintf(f, "#include \"BLI_blenlib.h\"\n\n");
fprintf(f, "#include \"BLI_utildefines.h\"\n\n");
@@ -4423,6 +4430,7 @@ static void rna_generate_header(BlenderRNA *UNUSED(brna), FILE *f)
" * Do not edit manually, changes will be overwritten. */\n\n");
fprintf(f, "#include \"RNA_types.h\"\n\n");
+ fprintf(f, "#include \"DNA_node_types.h\"\n\n");
fprintf(f, "#ifdef __cplusplus\nextern \"C\" {\n#endif\n\n");
@@ -4857,6 +4865,7 @@ static void rna_generate_header_cpp(BlenderRNA *UNUSED(brna), FILE *f)
fprintf(f, "#include \"RNA_blender.h\"\n");
fprintf(f, "#include \"RNA_types.h\"\n");
fprintf(f, "#include \"RNA_access.h\"\n");
+ fprintf(f, "#include \"DNA_node_types.h\"\n");
fprintf(f, "%s", cpp_classes);