[Bf-blender-cvs] [570e37261da] blender2.8: Hide collections menu: ignore excluded collections

Dalai Felinto noreply at git.blender.org
Thu Nov 15 14:52:46 CET 2018


Commit: 570e37261da2be1ab75c8cce3f2386704aadef32
Author: Dalai Felinto
Date:   Thu Nov 15 10:00:21 2018 -0200
Branches: blender2.8
https://developer.blender.org/rB570e37261da2be1ab75c8cce3f2386704aadef32

Hide collections menu: ignore excluded collections

Note: I didn't change the shortcuts, I think this is a separate decision
to be made. I just want at the moment to have the H operator to mimic
the upcoming popover.

Personally if we are to keep the 1-10 shortcuts (and they do work) I
think we should skip the excluded collections altogether.

In fact we could have an option to hide them from the outliner too.

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

M	source/blender/editors/object/object_edit.c

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

diff --git a/source/blender/editors/object/object_edit.c b/source/blender/editors/object/object_edit.c
index 18f5f7f0207..2e8ae8f2cc2 100644
--- a/source/blender/editors/object/object_edit.c
+++ b/source/blender/editors/object/object_edit.c
@@ -311,6 +311,10 @@ void ED_hide_collections_menu_draw(const bContext *C, uiLayout *layout)
 		int index = BKE_layer_collection_findindex(view_layer, lc);
 		uiLayout *row = uiLayoutRow(layout, false);
 
+		if (lc->flag & LAYER_COLLECTION_EXCLUDE) {
+			continue;
+		}
+
 		if (lc->collection->flag & COLLECTION_RESTRICT_VIEW) {
 			continue;
 		}



More information about the Bf-blender-cvs mailing list