Commit: 6e4cc26265ef260a8c6891a8f6b13eacaaf6e91e
Author: Dalai Felinto
Date:   Wed Apr 12 16:55:04 2017 +0200
Branches: blender2.8
https://developer.blender.org/rB6e4cc26265ef260a8c6891a8f6b13eacaaf6e91e

Layer / Outliner / Depsgraph: update depsgraph when running outliner operators

===================================================================

M       source/blender/editors/space_outliner/outliner_collections.c

===================================================================

diff --git a/source/blender/editors/space_outliner/outliner_collections.c 
b/source/blender/editors/space_outliner/outliner_collections.c
index e9c49ffdb14..b3d52da26d5 100644
--- a/source/blender/editors/space_outliner/outliner_collections.c
+++ b/source/blender/editors/space_outliner/outliner_collections.c
@@ -122,6 +122,10 @@ static int collection_link_exec(bContext *C, wmOperator 
*op)
        BKE_collection_link(sl, sc);
 
        DAG_relations_tag_update(CTX_data_main(C));
+
+       /* TODO(sergey): Use proper flag for tagging here. */
+       DAG_id_tag_update(&scene->id, 0);
+
        WM_main_add_notifier(NC_SCENE | ND_LAYER, NULL);
        return OPERATOR_FINISHED;
 }
@@ -220,6 +224,10 @@ static int collection_unlink_exec(bContext *C, wmOperator 
*op)
        BKE_collection_unlink(sl, lc);
 
        DAG_relations_tag_update(CTX_data_main(C));
+
+       /* TODO(sergey): Use proper flag for tagging here. */
+       DAG_id_tag_update(&CTX_data_scene(C)->id, 0);
+
        WM_main_add_notifier(NC_SCENE | ND_LAYER, NULL);
        return OPERATOR_FINISHED;
 }
@@ -347,6 +355,10 @@ static int collection_delete_exec(bContext *C, wmOperator 
*UNUSED(op))
        outliner_tree_traverse(soops, &soops->tree, 0, TSE_SELECTED, 
collection_delete_cb, &data);
 
        DAG_relations_tag_update(CTX_data_main(C));
+
+       /* TODO(sergey): Use proper flag for tagging here. */
+       DAG_id_tag_update(&scene->id, 0);
+
        WM_main_add_notifier(NC_SCENE | ND_LAYER, NULL);
 
        return OPERATOR_FINISHED;

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to