diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2019-06-08 00:41:37 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2019-06-08 00:45:41 +0300 |
commit | e70428c80e4a0b23db905dabb02dba6e75d32665 (patch) | |
tree | 6a15821e561ac8b734041cd120d12a760c4e762a /source/blender/editors/space_outliner | |
parent | b236c2a0ce1e73f1b82a88754e53fb049f6046ca (diff) |
Collections: Never change the collection views visibility when unhiding it
How to reproduce: use 1-10 to change the visible collection. If the
collection was globally invisible, it would be set to globally visible.
This was a left over from the previous collection visibility design.
Now that we have a more clear separation between temporary visibility
(i.e., layer collection visibiilty) and a global visibility setting
(i.e., collection visibility) we should keep them separated.
Diffstat (limited to 'source/blender/editors/space_outliner')
-rw-r--r-- | source/blender/editors/space_outliner/outliner_collections.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/source/blender/editors/space_outliner/outliner_collections.c b/source/blender/editors/space_outliner/outliner_collections.c index aca9e068dc4..459183ff226 100644 --- a/source/blender/editors/space_outliner/outliner_collections.c +++ b/source/blender/editors/space_outliner/outliner_collections.c @@ -1045,7 +1045,6 @@ static int collection_visibility_exec(bContext *C, wmOperator *op) SpaceOutliner *soops = CTX_wm_space_outliner(C); const bool is_inside = strstr(op->idname, "inside") != NULL; const bool show = strstr(op->idname, "show") != NULL; - bool depsgraph_changed = false; struct CollectionEditData data = { .scene = scene, .soops = soops, @@ -1058,18 +1057,13 @@ static int collection_visibility_exec(bContext *C, wmOperator *op) GSetIterator collections_to_edit_iter; GSET_ITER (collections_to_edit_iter, data.collections_to_edit) { LayerCollection *layer_collection = BLI_gsetIterator_getKey(&collections_to_edit_iter); - depsgraph_changed |= BKE_layer_collection_set_visible( - view_layer, layer_collection, show, is_inside); + BKE_layer_collection_set_visible(view_layer, layer_collection, show, is_inside); } BLI_gset_free(data.collections_to_edit, NULL); BKE_layer_collection_sync(scene, view_layer); DEG_id_tag_update(&scene->id, ID_RECALC_BASE_FLAGS); - if (depsgraph_changed) { - DEG_relations_tag_update(CTX_data_main(C)); - } - WM_main_add_notifier(NC_SCENE | ND_LAYER_CONTENT, NULL); return OPERATOR_FINISHED; } |