diff options
author | Elia Sarti <vekoon@gmail.com> | 2009-11-26 02:13:47 +0300 |
---|---|---|
committer | Elia Sarti <vekoon@gmail.com> | 2009-11-26 02:13:47 +0300 |
commit | aa5227664ab419d5446466fe0b3a368b05281fbe (patch) | |
tree | f1cbbcc27978d7948fd622fefc0b56f026bd676f /source/blender/makesrna/intern/rna_ID.c | |
parent | f6b03893945cac9bd79ed5bfe7eed12b3805c97d (diff) |
After talking with Matt about this, added notifier NC_ID to handle ID changes, specifically ND_ID_RENAME for ID renaming. Done for outliner, 3d view and properties editor.
Diffstat (limited to 'source/blender/makesrna/intern/rna_ID.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_ID.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_ID.c b/source/blender/makesrna/intern/rna_ID.c index cb1a1211d24..3bcdf373c43 100644 --- a/source/blender/makesrna/intern/rna_ID.c +++ b/source/blender/makesrna/intern/rna_ID.c @@ -31,6 +31,8 @@ #include "DNA_ID.h" +#include "WM_types.h" + #include "rna_internal.h" /* enum of ID-block types @@ -301,6 +303,7 @@ static void rna_def_ID(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Name", "Unique datablock ID name."); RNA_def_property_string_funcs(prop, "rna_ID_name_get", "rna_ID_name_length", "rna_ID_name_set"); RNA_def_property_string_maxlength(prop, sizeof(((ID*)NULL)->name)-2); + RNA_def_property_update(prop, NC_ID|ND_ID_RENAME, NULL); RNA_def_struct_name_property(srna, prop); prop= RNA_def_property(srna, "users", PROP_INT, PROP_UNSIGNED); |