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>2018-06-26 12:35:31 +0300
committerJoshua Leung <aligorith@gmail.com>2018-06-26 12:44:14 +0300
commitc0a8a29ae68f95bc0e0843774700868c19af1407 (patch)
tree1bc07abaa4909d579451b9a832400836573a2e60 /source/blender/editors/animation/anim_filter.c
parent5f545dbde81352fd2e98fdb77e8a2d15434d2648 (diff)
AnimEditors: Remove the toggles to enable name/collection-based filtering
Now the name/collection filters run when there's some text, and don't run when the box is empty, thus reducing an extra step that was needed before these options could be used.
Diffstat (limited to 'source/blender/editors/animation/anim_filter.c')
-rw-r--r--source/blender/editors/animation/anim_filter.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c
index 25704bc7348..c59d24bbdf8 100644
--- a/source/blender/editors/animation/anim_filter.c
+++ b/source/blender/editors/animation/anim_filter.c
@@ -1221,7 +1221,7 @@ static FCurve *animfilter_fcurve_next(bDopeSheet *ads, FCurve *first, eAnim_Chan
/* only include if this curve is active */
if (!(filter_mode & ANIMFILTER_ACTIVE) || (fcu->flag & FCURVE_ACTIVE)) {
/* name based filtering... */
- if ( ((ads) && (ads->filterflag & ADS_FILTER_BY_FCU_NAME)) && (owner_id) ) {
+ if ( ((ads) && (ads->searchstr[0] != '\0')) && (owner_id) ) {
if (skip_fcurve_with_name(ads, fcu, channel_type, owner, owner_id))
continue;
}
@@ -1453,7 +1453,7 @@ static size_t animfilter_nla(bAnimContext *UNUSED(ac), ListBase *anim_data, bDop
/* only include if this track is active */
if (!(filter_mode & ANIMFILTER_ACTIVE) || (nlt->flag & NLATRACK_ACTIVE)) {
/* name based filtering... */
- if (((ads) && (ads->filterflag & ADS_FILTER_BY_FCU_NAME)) && (owner_id)) {
+ if (((ads) && (ads->searchstr[0] != '\0')) && (owner_id)) {
bool track_ok = false, strip_ok = false;
/* check if the name of the track, or the strips it has are ok... */
@@ -1633,7 +1633,7 @@ static size_t animdata_filter_gpencil_layers_data(ListBase *anim_data, bDopeShee
/* active... */
if (!(filter_mode & ANIMFILTER_ACTIVE) || (gpl->flag & GP_LAYER_ACTIVE)) {
/* skip layer if the name doesn't match the filter string */
- if ((ads) && (ads->filterflag & ADS_FILTER_BY_FCU_NAME)) {
+ if ((ads) && (ads->searchstr[0] != '\0')) {
if (name_matches_dopesheet_filter(ads, gpl->info) == false)
continue;
}
@@ -1741,7 +1741,7 @@ static size_t animdata_filter_gpencil(bAnimContext *ac, ListBase *anim_data, voi
* objects by the grouped status is on
* - used to ease the process of doing multiple-character choreographies
*/
- if (ads->filterflag & ADS_FILTER_ONLYOBGROUP) {
+ if (ads->filter_grp != NULL) {
if (BKE_collection_has_object_recursive(ads->filter_grp, ob) == 0)
continue;
}
@@ -2908,7 +2908,7 @@ static bool animdata_filter_base_is_ok(bDopeSheet *ads, Base *base, int filter_m
* objects by the grouped status is on
* - used to ease the process of doing multiple-character choreographies
*/
- if (ads->filterflag & ADS_FILTER_ONLYOBGROUP) {
+ if (ads->filter_grp != NULL) {
if (BKE_collection_has_object_recursive(ads->filter_grp, ob) == 0)
return false;
}