summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHermet Park <hermetpark@gmail.com>2019-11-18 12:57:18 +0900
committerHermet Park <hermetpark@gmail.com>2019-11-18 12:57:21 +0900
commit98a3dcd94e43e7d172d1609523467edcaed02c1c (patch)
tree06949f5c96a4350143ce88b28c3a0e9aa06f32f3
parenta1f1cd6dd67de8eac0e302d47ce2aebf44aead16 (diff)
Revert "evas: migrate the vg json example"
This reverts commit a1f1cd6dd67de8eac0e302d47ce2aebf44aead16. Eeek, this shouldn't be pushed yet.
-rw-r--r--src/examples/evas/evas-vg-json.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/examples/evas/evas-vg-json.c b/src/examples/evas/evas-vg-json.c
index cf0519f..248dcb1 100644
--- a/src/examples/evas/evas-vg-json.c
+++ b/src/examples/evas/evas-vg-json.c
@@ -35,9 +35,10 @@
35static Eo *gvg[5]; 35static Eo *gvg[5];
36 36
37static void 37static void
38_running_cb(void *data EINA_UNUSED, const Efl_Event *event) 38running_cb(void *data EINA_UNUSED, const Efl_Event *event)
39{ 39{
40 double progress = *((double*)event->info); 40 Efl_Canvas_Animation_Player_Event_Running *event_running = event->info;
41 double progress = event_running->progress;
41 42
42 int i; 43 int i;
43 for (i = 0; i < 5; i++) 44 for (i = 0; i < 5; i++)
@@ -119,8 +120,11 @@ main(void)
119 //Play custom animation 120 //Play custom animation
120 Eo *anim = efl_add(EFL_CANVAS_ANIMATION_CLASS, evas); 121 Eo *anim = efl_add(EFL_CANVAS_ANIMATION_CLASS, evas);
121 efl_animation_duration_set(anim, efl_gfx_frame_controller_frame_duration_get(vg, 0, 0)); 122 efl_animation_duration_set(anim, efl_gfx_frame_controller_frame_duration_get(vg, 0, 0));
122 efl_event_callback_add(vg, EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, _running_cb, NULL); 123
123 efl_canvas_object_animation_start(vg, anim, 1.0, 0.0); 124 Eo *player = efl_add(EFL_CANVAS_ANIMATION_PLAYER_CLASS, evas);
125 efl_animation_player_animation_set(player, anim);
126 efl_event_callback_add(player, EFL_ANIMATION_PLAYER_EVENT_RUNNING, running_cb, NULL);
127 efl_player_playing_set(player, EINA_TRUE);
124 128
125 ecore_main_loop_begin(); 129 ecore_main_loop_begin();
126 ecore_evas_shutdown(); 130 ecore_evas_shutdown();