Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Eisel <julian@blender.org>2022-03-25 21:00:04 +0300
committerFabian Schempp <fabianschempp@googlemail.com>2022-04-11 01:31:46 +0300
commitc7004ff99c31ea382b530dfe06636ba8094cd6bf (patch)
treef22ecf91c39ebb25a295f85d9f6a4c492d5e2e40 /source/blender/editors/space_outliner
parent1712d8b8d912b65e2e6485f7ca5385fa08b98536 (diff)
Fix Outliner highlighting multiple base elements in different libraries
In the Blender File display mode of the Outliner, mouse hovering a "base" element (e.g. "Objects", "Materials", ...) would also highlight that same base element in other libraries linked into the scene. In fact operations like (un)collapsing would be applied to both too. Issue was that we'd always use the listbase containing the data-blocks from the current main as a way to identify the tree element. So for the same data-block types we'd use the same listbase pointers. Instead use the the library pointer + a per library index.
Diffstat (limited to 'source/blender/editors/space_outliner')
-rw-r--r--source/blender/editors/space_outliner/tree/tree_display_libraries.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/space_outliner/tree/tree_display_libraries.cc b/source/blender/editors/space_outliner/tree/tree_display_libraries.cc
index 0023b7c7b62..476bbdb63ae 100644
--- a/source/blender/editors/space_outliner/tree/tree_display_libraries.cc
+++ b/source/blender/editors/space_outliner/tree/tree_display_libraries.cc
@@ -150,7 +150,7 @@ TreeElement *TreeDisplayLibraries::add_library_contents(Main &mainvar, ListBase
}
else {
ten = outliner_add_element(
- &space_outliner_, &tenlib->subtree, lbarray[a], nullptr, TSE_ID_BASE, 0);
+ &space_outliner_, &tenlib->subtree, lib, nullptr, TSE_ID_BASE, a);
ten->directdata = lbarray[a];
ten->name = outliner_idcode_to_plural(GS(id->name));
}