From: Sung-Jin Park Date: Tue, 3 Sep 2019 02:34:36 +0000 (+0900) Subject: pui_sample : modify to resume the paused animation X-Git-Tag: accepted/tizen/5.5/unified/20200102.014046~22 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Flibpui.git;a=commitdiff_plain;h=20fc0f69e1c140098cfafe5f5f6ee3fee1588141 pui_sample : modify to resume the paused animation Change-Id: Id8e859037ed38a19330ec402550a8038b59adb4b Signed-off-by: Sung-Jin Park --- diff --git a/samples/PUI_sample.c b/samples/PUI_sample.c index a6b04d5..c8b16e0 100644 --- a/samples/PUI_sample.c +++ b/samples/PUI_sample.c @@ -212,7 +212,7 @@ _cb_ani_stopped(void *data, int type EINA_UNUSED, void *event) } static Eina_Bool -_cb_ani_ready_to_start(void *data, int type EINA_UNUSED, void *event) +_cb_ani_ready_to_resume(void *data, int type EINA_UNUSED, void *event) { app_data_t *app = (app_data_t *)data; PUI_Event_Animation_Status *ev; @@ -221,7 +221,8 @@ _cb_ani_ready_to_start(void *data, int type EINA_UNUSED, void *event) ev = event; debug_info("[%s] ani id=%s, status=%d, window=0x%x\n", __FUNCTION__, pui_ani_get_id(ev->ani_h), ev->status, ev->win); - /* start animation */ + /* resume animation */ + app->ani_idx--; ani_collection_play(app); return ECORE_CALLBACK_PASS_ON; @@ -251,7 +252,7 @@ event_handlers_init(app_data_t *app) h = ecore_event_handler_add(PUI_EVENT_ANI_STOPPED, _cb_ani_stopped, app); eina_array_push(_ecore_event_hdls, h); - h = ecore_event_handler_add(PUI_EVENT_ANI_READY_TO_START, _cb_ani_ready_to_start, app); + h = ecore_event_handler_add(PUI_EVENT_ANI_READY_TO_RESUME, _cb_ani_ready_to_resume, app); eina_array_push(_ecore_event_hdls, h); }