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:
authorJoshua Leung <aligorith@gmail.com>2015-04-14 07:48:34 +0300
committerJoshua Leung <aligorith@gmail.com>2015-04-14 09:39:03 +0300
commit5361339ba0590abe2220a65efa53ca48b2813974 (patch)
tree27ffb4807fc3b243f8f65c3ae0675bf8dfbc2144 /source/blender/editors/animation/anim_filter.c
parent097801e701cec7ae1e388d201ca3426153616097 (diff)
Temporary fix for NLA strips not getting drawn in tweakmode with multiple strips selected
When entering tweakmode on multiple strips (from different AnimData blocks) simultaneously, only the track containing the last selected strip would be shown. All the other tracks with strips being tweaked would not appear at all.
Diffstat (limited to 'source/blender/editors/animation/anim_filter.c')
-rw-r--r--source/blender/editors/animation/anim_filter.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c
index ee662c46fd0..25f2b0b43af 100644
--- a/source/blender/editors/animation/anim_filter.c
+++ b/source/blender/editors/animation/anim_filter.c
@@ -1301,8 +1301,22 @@ static size_t animfilter_nla(bAnimContext *UNUSED(ac), ListBase *anim_data, bDop
* - active track should still get shown though (even though it has disabled flag set)
*/
// FIXME: the channels after should still get drawn, just 'differently', and after an active-action channel
- if ((adt->flag & ADT_NLA_EDIT_ON) && (nlt->flag & NLATRACK_DISABLED) && !(nlt->flag & NLATRACK_ACTIVE))
- continue;
+ if ((adt->flag & ADT_NLA_EDIT_ON) && (nlt->flag & NLATRACK_DISABLED)) {
+ /* NOTE: The tweaking track may not be active, if strips from different AnimData blocks
+ * entered tweakmode at the same time. Since this loop works both ways, we can't
+ * just stop on the first disabled track we encounter...
+ */
+ if (nlt->flag & NLATRACK_ACTIVE) {
+ /* OK = "the" active track */
+ }
+ else if (BLI_findindex(&nlt->strips, adt->actstrip) != -1) {
+ /* OK = this is the one containing the active strip */
+ }
+ else {
+ /* Not OK - neither of the previous two were met, so it must be one of the "later" ones */
+ continue;
+ }
+ }
/* only work with this channel and its subchannels if it is editable */
if (!(filter_mode & ANIMFILTER_FOREDIT) || EDITABLE_NLT(nlt)) {