From e301cf3ec2cb8caa544032238cf7a1e7bb5e2523 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 25 Jul 2015 13:26:20 +1000 Subject: Cleanup: double-promotion warnings --- source/blender/editors/animation/anim_draw.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'source/blender/editors/animation/anim_draw.c') diff --git a/source/blender/editors/animation/anim_draw.c b/source/blender/editors/animation/anim_draw.c index 498086047ad..33a5447698a 100644 --- a/source/blender/editors/animation/anim_draw.c +++ b/source/blender/editors/animation/anim_draw.c @@ -494,11 +494,14 @@ void ANIM_center_frame(struct bContext *C, int smooth_viewtx) switch (U.view_frame_type) { case ZOOM_FRAME_MODE_SECONDS: - newrct.xmax = scene->r.cfra + U.view_frame_seconds * FPS + 1; - newrct.xmin = scene->r.cfra - U.view_frame_seconds * FPS - 1; + { + const float fps = FPS; + newrct.xmax = scene->r.cfra + U.view_frame_seconds * fps + 1; + newrct.xmin = scene->r.cfra - U.view_frame_seconds * fps - 1; newrct.ymax = ar->v2d.cur.ymax; newrct.ymin = ar->v2d.cur.ymin; break; + } /* hardest case of all, look for all keyframes around frame and display those */ case ZOOM_FRAME_MODE_KEYFRAMES: -- cgit v1.2.3