From 4f21e6fc4fb450a0ba819522111e878be173ed55 Mon Sep 17 00:00:00 2001 From: JunsuChoi Date: Fri, 3 May 2019 15:40:40 +0900 Subject: [PATCH] elementary animation_view: correct max frame number. Change-Id: Iee8ed41f8d1e0c17bfff97765a5cdc2d7ca3a8e1 Signed-off-by: JunsuChoi --- src/lib/elm_animation_view.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/elm_animation_view.c b/src/lib/elm_animation_view.c index 4a317b871..a439c28f0 100644 --- a/src/lib/elm_animation_view.c +++ b/src/lib/elm_animation_view.c @@ -169,7 +169,7 @@ _transit_cb(Elm_Transit_Effect *effect, Elm_Transit *transit, double progress) else pd->state = ELM_ANIMATION_VIEW_STATE_PLAY; pd->keyframe = progress; - evas_object_vg_animated_frame_set(pd->vg, (int) (pd->frame_cnt * progress)); + evas_object_vg_animated_frame_set(pd->vg, (int) ((pd->frame_cnt - 1) * progress)); if (pd->auto_repeat) { @@ -493,7 +493,7 @@ _elm_animation_view_keyframe_set(Eo *obj EINA_UNUSED, Elm_Animation_View_Data *p pd->keyframe = keyframe; if (pd->frame_cnt > 0) - evas_object_vg_animated_frame_set(pd->vg, (int) (pd->frame_cnt * keyframe)); + evas_object_vg_animated_frame_set(pd->vg, (int) ((pd->frame_cnt - 1) * keyframe)); if (pd->transit) { -- 2.34.1