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:
authorJacques Lucke <mail@jlucke.com>2019-09-14 17:52:56 +0300
committerJacques Lucke <mail@jlucke.com>2019-09-14 17:52:56 +0300
commit7aeedf71b88b91d7bc857bdcc04a4845bb1bc794 (patch)
tree985bc7982f3d74df8fce593f0242d5532d2b7cb9 /source/blender/editors/animation/anim_markers.c
parent38cc53a168d27b19fb6033a38a043b5076c0aea6 (diff)
UI: quiet warning when drawing markers
The compiler was warning that it assumed that crfa - 4 < cfra is always true even though that might not be the case due to overflow. This patch just removes the condition that caused the assumption.
Diffstat (limited to 'source/blender/editors/animation/anim_markers.c')
-rw-r--r--source/blender/editors/animation/anim_markers.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c
index 8c873eb6b45..2a35acdefcb 100644
--- a/source/blender/editors/animation/anim_markers.c
+++ b/source/blender/editors/animation/anim_markers.c
@@ -486,7 +486,7 @@ static void draw_marker(
float name_y = UI_DPI_FAC * 18;
/* Give an offset to the marker name when selected,
* or when near the current frame (5 frames range, starting from the current one). */
- if ((marker->flag & SELECT) || (IN_RANGE_INCL(marker->frame, cfra - 4, cfra))) {
+ if ((marker->flag & SELECT) || (cfra - 4 <= marker->frame && marker->frame <= cfra)) {
name_y += UI_DPI_FAC * 10;
}
draw_marker_name(fstyle, marker, xpos, name_y);