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:
authorTon Roosendaal <ton@blender.org>2012-12-27 23:07:16 +0400
committerTon Roosendaal <ton@blender.org>2012-12-27 23:07:16 +0400
commit5a907210989c82f415ceeaeee2e71b0ed27725d0 (patch)
tree95b650febed63567cd5d867499f83c18a07d0b9c /source/blender/editors/space_outliner/outliner_tree.c
parentb931d2d0cdb3998e86d0dc828751cfd40be58110 (diff)
Outliner fix:
New "Blender file" viewer now shows names of libraries better.
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_tree.c')
-rw-r--r--source/blender/editors/space_outliner/outliner_tree.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/editors/space_outliner/outliner_tree.c b/source/blender/editors/space_outliner/outliner_tree.c
index d911818d0cb..f723fbedc7b 100644
--- a/source/blender/editors/space_outliner/outliner_tree.c
+++ b/source/blender/editors/space_outliner/outliner_tree.c
@@ -836,7 +836,11 @@ static TreeElement *outliner_add_element(SpaceOops *soops, ListBase *lb, void *i
/* pass */
}
else {
- te->name = id->name + 2; // default, can be overridden by Library or non-ID data
+ /* do here too, for blend file viewer, own ID_LI then shows file name */
+ if (GS(id->name) == ID_LI)
+ te->name = ((Library *)id)->name;
+ else
+ te->name = id->name + 2; // default, can be overridden by Library or non-ID data
te->idcode = GS(id->name);
}