Asset Browser: Don't expand top-level catalogs by default
The "All" item will be expanded of course, and the tree will also be expanded so that the active item is visible. But feedback was that in some setups, opening all the top-level catalogs is a bit too much. So collapse them for a more compact default layout. Part of T93582.
This commit is contained in:
@@ -201,11 +201,9 @@ void AssetCatalogTreeView::build_tree()
|
||||
all_item.set_collapsed(false);
|
||||
|
||||
if (catalog_tree_) {
|
||||
/* Pass the "All" item on as parent of the actual catalog items. */
|
||||
catalog_tree_->foreach_root_item([this, &all_item](AssetCatalogTreeItem &item) {
|
||||
ui::BasicTreeViewItem &child_view_item = build_catalog_items_recursive(all_item, item);
|
||||
|
||||
/* Open root-level items by default. */
|
||||
child_view_item.set_collapsed(false);
|
||||
build_catalog_items_recursive(all_item, item);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user