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>2004-10-17 02:30:54 +0400
committerTon Roosendaal <ton@blender.org>2004-10-17 02:30:54 +0400
commit0be2d97e2e2052f4a123492bb2afe9c4db9b99e7 (patch)
treef8fe53f3b61b98fef260d873bd222720af52711f /source/blender/src/outliner.c
parent121f842fb41dd339e26fae1407149bdbbd6f4291 (diff)
Hah! found the trick to recover hierarchy in edit bones, so the display
of Outliner of it is nice hierarchical too. Please note that storage in outliner for editbones and pose-bones are separate, so you have to uncollapse the views independently
Diffstat (limited to 'source/blender/src/outliner.c')
-rw-r--r--source/blender/src/outliner.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/source/blender/src/outliner.c b/source/blender/src/outliner.c
index 4a3b92da782..d0c7ce35025 100644
--- a/source/blender/src/outliner.c
+++ b/source/blender/src/outliner.c
@@ -585,7 +585,21 @@ static TreeElement *outliner_add_element(SpaceOops *soops, ListBase *lb, void *i
ten= outliner_add_element(soops, &te->subtree, id, te, TSE_EBONE, a);
ten->directdata= ebone;
ten->name= ebone->name;
+ ebone->temp= ten;
}
+ /* make hierarchy */
+ ten= te->subtree.first;
+ while(ten) {
+ TreeElement *nten= ten->next, *par;
+ ebone= (EditBone *)ten->directdata;
+ if(ebone->parent) {
+ BLI_remlink(&te->subtree, ten);
+ par= ebone->parent->temp;
+ BLI_addtail(&par->subtree, ten);
+ }
+ ten= nten;
+ }
+
}
else {
Bone *curBone;