Fix unintentional copies of asset catalog tree items in asset shelf

The asset catalog selector tree-view would store a copy of each of the
items in the catalog tree, including all of its sub-hierarchy. This can
be avoided, it can just use a reference.
This commit is contained in:
Julian Eisel
2024-02-23 17:58:19 +01:00
parent 53273e4460
commit b07506c87b
@@ -85,7 +85,7 @@ class AssetCatalogSelectorTree : public ui::AbstractTreeView {
void update_shelf_settings_from_enabled_catalogs();
class Item : public ui::BasicTreeViewItem {
asset_system::AssetCatalogTreeItem catalog_item_;
asset_system::AssetCatalogTreeItem &catalog_item_;
/* Is the catalog path enabled in this redraw? Set on construction, updated by the UI (which
* gets a pointer to it). The UI needs it as char. */
char catalog_path_enabled_ = false;