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:
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/animation/anim_channels.c14
-rw-r--r--source/blender/editors/animation/anim_filter.c39
-rw-r--r--source/blender/editors/space_action/action_draw.c5
-rw-r--r--source/blender/editors/space_graph/graph_draw.c11
4 files changed, 52 insertions, 17 deletions
diff --git a/source/blender/editors/animation/anim_channels.c b/source/blender/editors/animation/anim_channels.c
index 4ac1648361e..5e9abd42aeb 100644
--- a/source/blender/editors/animation/anim_channels.c
+++ b/source/blender/editors/animation/anim_channels.c
@@ -928,6 +928,12 @@ static void setflag_anim_channels (bAnimContext *ac, short setting, short mode,
case ACHANNEL_SETTING_EXPAND:
ACHANNEL_SET_FLAG(agrp, mode, AGRP_EXPANDED);
break;
+ case ACHANNEL_SETTING_MUTE:
+ ACHANNEL_SET_FLAG(agrp, mode, AGRP_MUTED);
+ break;
+ case ACHANNEL_SETTING_VISIBLE:
+ ACHANNEL_SET_FLAG_NEG(agrp, mode, AGRP_NOTVISIBLE);
+ break;
}
}
break;
@@ -1491,10 +1497,18 @@ static void mouse_anim_channels (bAnimContext *ac, float x, int channel_index, s
/* toggle expand */
agrp->flag ^= AGRP_EXPANDED;
}
+ else if ((x < (offset+32)) && (ac->spacetype==SPACE_IPO)) {
+ /* toggle visibility (of grouped F-Curves in Graph editor) */
+ agrp->flag ^= AGRP_NOTVISIBLE;
+ }
else if (x >= (ACHANNEL_NAMEWIDTH-ACHANNEL_BUTTON_WIDTH)) {
/* toggle protection/locking */
agrp->flag ^= AGRP_PROTECTED;
}
+ else if (x >= (ACHANNEL_NAMEWIDTH-2*ACHANNEL_BUTTON_WIDTH)) {
+ /* toggle mute */
+ agrp->flag ^= AGRP_MUTED;
+ }
else {
/* select/deselect group */
if (selectmode == SELECT_INVERT) {
diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c
index f9c1b1bb42f..42943475a57 100644
--- a/source/blender/editors/animation/anim_filter.c
+++ b/source/blender/editors/animation/anim_filter.c
@@ -682,25 +682,30 @@ static int animdata_filter_action (ListBase *anim_data, bAction *act, int filter
* cases when we should include F-Curves inside group:
* - we don't care about visibility
* - group is expanded
- * - we're interested in keyframes, but not if they appear in selected channels
+ * - we just need the F-Curves present
*/
- // XXX what was the selection check here for again?
- if ( (!(filter_mode & ANIMFILTER_VISIBLE) || EXPANDED_AGRP(agrp)) ||
- ( /*ANIMCHANNEL_SELOK(SEL_AGRP(agrp)) &&*/ (filter_mode & ANIMFILTER_CURVESONLY) ) )
+ if ( (!(filter_mode & ANIMFILTER_VISIBLE) || EXPANDED_AGRP(agrp)) || (filter_mode & ANIMFILTER_CURVESONLY) )
{
- if (!(filter_mode & ANIMFILTER_FOREDIT) || EDITABLE_AGRP(agrp)) {
- // XXX the 'owner' info here needs review...
- items += animdata_filter_fcurves(anim_data, agrp->channels.first, agrp, owner, ownertype, filter_mode, owner_id);
-
- /* remove group from filtered list if last element is group
- * (i.e. only if group had channels, which were all hidden)
- */
- // XXX this is really hacky... it should be fixed in a much more elegant way!
- if ( (ale) && (anim_data->last == ale) &&
- (ale->data == agrp) && (agrp->channels.first) )
- {
- BLI_freelinkN(anim_data, ale);
- items--;
+ /* for the Graph Editor, curves may be set to not be visible in the view to lessen clutter,
+ * but to do this, we need to check that the group doesn't have it's not-visible flag set preventing
+ * all its sub-curves to be shown
+ */
+ if ( !(filter_mode & ANIMFILTER_CURVEVISIBLE) || !(agrp->flag & AGRP_NOTVISIBLE) )
+ {
+ if (!(filter_mode & ANIMFILTER_FOREDIT) || EDITABLE_AGRP(agrp)) {
+ // XXX the 'owner' info here needs review...
+ items += animdata_filter_fcurves(anim_data, agrp->channels.first, agrp, owner, ownertype, filter_mode, owner_id);
+
+ /* remove group from filtered list if last element is group
+ * (i.e. only if group had channels, which were all hidden)
+ */
+ // XXX this is really hacky... it should be fixed in a much more elegant way!
+ if ( (ale) && (anim_data->last == ale) &&
+ (ale->data == agrp) && (agrp->channels.first) )
+ {
+ BLI_freelinkN(anim_data, ale);
+ items--;
+ }
}
}
}
diff --git a/source/blender/editors/space_action/action_draw.c b/source/blender/editors/space_action/action_draw.c
index f3a0dda4ce7..910b9733bc8 100644
--- a/source/blender/editors/space_action/action_draw.c
+++ b/source/blender/editors/space_action/action_draw.c
@@ -645,6 +645,11 @@ void draw_channel_names(bAnimContext *ac, SpaceAction *saction, ARegion *ar)
expand = ICON_TRIA_RIGHT;
}
+ if (agrp->flag & AGRP_MUTED)
+ mute = ICON_MUTE_IPO_ON;
+ else
+ mute = ICON_MUTE_IPO_OFF;
+
if (EDITABLE_AGRP(agrp))
protect = ICON_UNLOCKED;
else
diff --git a/source/blender/editors/space_graph/graph_draw.c b/source/blender/editors/space_graph/graph_draw.c
index 0d7dafe2938..f8f613223db 100644
--- a/source/blender/editors/space_graph/graph_draw.c
+++ b/source/blender/editors/space_graph/graph_draw.c
@@ -1166,6 +1166,17 @@ void graph_draw_channel_names(bAnimContext *ac, SpaceIpo *sipo, ARegion *ar)
expand = ICON_TRIA_RIGHT;
}
+ /* for now, 'special' (i.e. in front of name) is used to show visibility status */
+ if (agrp->flag & AGRP_NOTVISIBLE)
+ special= ICON_CHECKBOX_DEHLT;
+ else
+ special= ICON_CHECKBOX_HLT;
+
+ if (agrp->flag & AGRP_MUTED)
+ mute = ICON_MUTE_IPO_ON;
+ else
+ mute = ICON_MUTE_IPO_OFF;
+
if (EDITABLE_AGRP(agrp))
protect = ICON_UNLOCKED;
else