diff options
author | Julian Eisel <eiseljulian@gmail.com> | 2017-03-01 18:32:13 +0300 |
---|---|---|
committer | Julian Eisel <eiseljulian@gmail.com> | 2017-03-01 18:34:16 +0300 |
commit | 18684e546f25feefa5a696b786e74fd63b590d10 (patch) | |
tree | 26ca4b6896783bfe2b822f2e4b2a3009df824f45 /source/blender/editors | |
parent | b00b9dadd819d3b94405f755131e609afa827438 (diff) |
Outliner: Make sure collection name is unique after renaming
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/space_outliner/outliner_draw.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c index cc5afd51493..990ad296bb9 100644 --- a/source/blender/editors/space_outliner/outliner_draw.c +++ b/source/blender/editors/space_outliner/outliner_draw.c @@ -421,6 +421,13 @@ static void namebutton_cb(bContext *C, void *tsep, char *oldname) } case TSE_R_LAYER: break; + case TSE_SCENE_COLLECTION: + case TSE_LAYER_COLLECTION: + { + SceneCollection *sc = outliner_scene_collection_from_tree_element(te); + BKE_collection_rename(scene, sc, te->name); + break; + } } } tselem->flag &= ~TSE_TEXTBUT; |