diff options
author | Julian Eisel <julian@blender.org> | 2020-04-03 14:25:03 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2020-04-03 14:34:50 +0300 |
commit | 905c0269f302e8e0e7a27dda8d5256fdcd06ce60 (patch) | |
tree | 1c720d4f0069879d5b4c0c9ea8db867106920d4f /source/blender/editors/animation/anim_markers.c | |
parent | 1a69384e76e2b1ab11c87a582eb2cdf26386ac59 (diff) |
Cleanup: Rename ScrArea variables from sa to area
Follow up of b2ee1770d4c3 and 10c2254d412d, part of T74432.
Now the area and region naming conventions should be less confusing.
Mostly a careful batch rename but had to do few smaller fixes.
Also ran clang-format on affected files.
Diffstat (limited to 'source/blender/editors/animation/anim_markers.c')
-rw-r--r-- | source/blender/editors/animation/anim_markers.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c index 27d38cf625a..93d2d99effb 100644 --- a/source/blender/editors/animation/anim_markers.c +++ b/source/blender/editors/animation/anim_markers.c @@ -74,12 +74,12 @@ /* ************* Marker API **************** */ /* helper function for getting the list of markers to work on */ -static ListBase *context_get_markers(Scene *scene, ScrArea *sa) +static ListBase *context_get_markers(Scene *scene, ScrArea *area) { /* local marker sets... */ - if (sa) { - if (sa->spacetype == SPACE_ACTION) { - SpaceAction *saction = (SpaceAction *)sa->spacedata.first; + if (area) { + if (area->spacetype == SPACE_ACTION) { + SpaceAction *saction = (SpaceAction *)area->spacedata.first; /* local markers can only be shown when there's only a single active action to grab them from * - flag only takes effect when there's an action, otherwise it can get too confusing? @@ -108,7 +108,7 @@ ListBase *ED_context_get_markers(const bContext *C) ListBase *ED_animcontext_get_markers(const bAnimContext *ac) { if (ac) { - return context_get_markers(ac->scene, ac->sa); + return context_get_markers(ac->scene, ac->area); } else { return NULL; @@ -234,35 +234,35 @@ void ED_markers_get_minmax(ListBase *markers, short sel, float *r_first, float * */ static bool ED_operator_markers_region_active(bContext *C) { - ScrArea *sa = CTX_wm_area(C); - if (sa == NULL) { + ScrArea *area = CTX_wm_area(C); + if (area == NULL) { return false; } - switch (sa->spacetype) { + switch (area->spacetype) { case SPACE_ACTION: { - SpaceAction *saction = sa->spacedata.first; + SpaceAction *saction = area->spacedata.first; if (saction->flag & SACTION_SHOW_MARKERS) { return true; } break; } case SPACE_GRAPH: { - SpaceGraph *sipo = sa->spacedata.first; + SpaceGraph *sipo = area->spacedata.first; if (sipo->mode != SIPO_MODE_DRIVERS && sipo->flag & SIPO_SHOW_MARKERS) { return true; } break; } case SPACE_NLA: { - SpaceNla *snla = sa->spacedata.first; + SpaceNla *snla = area->spacedata.first; if (snla->flag & SNLA_SHOW_MARKERS) { return true; } break; } case SPACE_SEQ: { - SpaceSeq *seq = sa->spacedata.first; + SpaceSeq *seq = area->spacedata.first; if (seq->flag & SEQ_SHOW_MARKERS) { return true; } |