From ab7ebf2b10f67b002447fb0e2cb352c2c178e128 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 18 Oct 2017 15:07:26 +1100 Subject: Cleanup: Use const for RNA EnumPropertyItem args Practically all access to enum data is read-only. --- source/blender/makesrna/intern/rna_main_api.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/blender/makesrna/intern/rna_main_api.c') diff --git a/source/blender/makesrna/intern/rna_main_api.c b/source/blender/makesrna/intern/rna_main_api.c index 871f50e992e..dc3bbf6ca45 100644 --- a/source/blender/makesrna/intern/rna_main_api.c +++ b/source/blender/makesrna/intern/rna_main_api.c @@ -259,7 +259,7 @@ static Material *rna_Main_materials_new(Main *bmain, const char *name) return (Material *)id; } -static EnumPropertyItem *rna_Main_nodetree_type_itemf(bContext *UNUSED(C), PointerRNA *UNUSED(ptr), PropertyRNA *UNUSED(prop), bool *r_free) +static const EnumPropertyItem *rna_Main_nodetree_type_itemf(bContext *UNUSED(C), PointerRNA *UNUSED(ptr), PropertyRNA *UNUSED(prop), bool *r_free) { return rna_node_tree_type_itemf(NULL, NULL, r_free); } @@ -805,7 +805,7 @@ void RNA_def_main_node_groups(BlenderRNA *brna, PropertyRNA *cprop) PropertyRNA *parm; PropertyRNA *prop; - static EnumPropertyItem dummy_items[] = { + static const EnumPropertyItem dummy_items[] = { {0, "DUMMY", 0, "", ""}, {0, NULL, 0, NULL, NULL} }; @@ -853,7 +853,7 @@ void RNA_def_main_meshes(BlenderRNA *brna, PropertyRNA *cprop) PropertyRNA *parm; PropertyRNA *prop; - static EnumPropertyItem mesh_type_items[] = { + static const EnumPropertyItem mesh_type_items[] = { {eModifierMode_Realtime, "PREVIEW", 0, "Preview", "Apply modifier preview settings"}, {eModifierMode_Render, "RENDER", 0, "Render", "Apply modifier render settings"}, {0, NULL, 0, NULL, NULL} -- cgit v1.2.3