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>2010-02-08 13:47:34 +0300
committerJoshua Leung <aligorith@gmail.com>2010-02-08 13:47:34 +0300
commit5e9b5ddfc10c3ced34f09a0b066c1d6493e976a3 (patch)
treec13d15bcf9b8e35b6be85166aee32d16fe6a9725 /source/blender/editors/animation
parent23c070dd41138cc973e8e64f87dfa3c9eb629939 (diff)
Durian Bugreport - Animation channel visiblity (upwards) flushing
When the visiblity of a F-Curve in an expanded group was enabled using VKEY, the visibility of all groups above the expanded groups were also turned on.
Diffstat (limited to 'source/blender/editors/animation')
-rw-r--r--source/blender/editors/animation/anim_channels_edit.c31
1 files changed, 21 insertions, 10 deletions
diff --git a/source/blender/editors/animation/anim_channels_edit.c b/source/blender/editors/animation/anim_channels_edit.c
index 9448db3ebe3..fba6d56fcc6 100644
--- a/source/blender/editors/animation/anim_channels_edit.c
+++ b/source/blender/editors/animation/anim_channels_edit.c
@@ -437,18 +437,29 @@ void ANIM_flush_setting_anim_channels (bAnimContext *ac, ListBase *anim_data, bA
/* if the level is 'less than' (i.e. more important) the level we're matching
* but also 'less than' the level just tried (i.e. only the 1st group above grouped F-Curves,
- * when toggling visibility of F-Curves, gets flushed), flush the new status...
+ * when toggling visibility of F-Curves, gets flushed, which should happen if we don't let prevLevel
+ * get updated below once the first 1st group is found)...
*/
- if (level < prevLevel)
+ if (level < prevLevel) {
+ /* flush the new status... */
ANIM_channel_setting_set(ac, ale, setting, on);
- /* however, if the level is 'greater than' (i.e. less important than the previous channel,
- * stop searching, since we've already reached the bottom of another hierarchy
- */
- else if (level > matchLevel)
- break;
-
- /* store this level as the 'old' level now */
- prevLevel= level;
+
+ /* store this level as the 'old' level now */
+ prevLevel= level;
+ }
+ /* if the level is 'greater than' (i.e. less important) than the previous level... */
+ else if (level > prevLevel) {
+ /* if previous level was a base-level (i.e. 0 offset / root of one hierarchy),
+ * stop here
+ */
+ if (prevLevel == 0)
+ break;
+ /* otherwise, this level weaves into another sibling hierarchy to the previous one just
+ * finished, so skip until we get to the parent of this level
+ */
+ else
+ continue;
+ }
}
}