eo_do(sid->obj, elm_scrollable_interface_content_pos_get(&px, &py));
_elm_scroll_wanted_coordinates_update(sid, px, py);
- ELM_FREE_FUNC(sid->down.momentum_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.momentum_animator, ecore_animator_del);
sid->down.bounce_x_hold = EINA_FALSE;
sid->down.bounce_y_hold = EINA_FALSE;
sid->down.ax = 0;
if (sid->down.now) return; // down bounce while still held down
if (sid->down.onhold_animator)
{
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.onhold_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.hold_animator)
{
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.onhold_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
{
if (sid->bouncemex)
{
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
+ if (sid->scrollto.x.animator) ecore_animator_del(sid->scrollto.x.animator);
sid->down.bounce_x_animator =
ecore_animator_add(_elm_scroll_bounce_x_animator, sid->obj);
sid->down.anim_start2 = ecore_loop_time_get();
{
if (sid->bouncemey)
{
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ if (sid->scrollto.y.animator) ecore_animator_del(sid->scrollto.y.animator);
sid->down.bounce_y_animator =
ecore_animator_add(_elm_scroll_bounce_y_animator, sid->obj);
sid->down.anim_start3 = ecore_loop_time_get();
{
_elm_scroll_anim_stop(sid);
}
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.x.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.y.animator, ecore_animator_del);
if (sid->down.bounce_x_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_x_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_x_animator, ecore_animator_del);
sid->bouncemex = EINA_FALSE;
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.bounce_y_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_y_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_y_animator, ecore_animator_del);
sid->bouncemey = EINA_FALSE;
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.hold_animator)
{
- ELM_FREE_FUNC(sid->down.hold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.hold_animator, ecore_animator_del);
_elm_scroll_drag_stop(sid);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.momentum_animator)
{
- ELM_FREE_FUNC(sid->down.momentum_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.momentum_animator, ecore_animator_del);
sid->down.bounce_x_hold = EINA_FALSE;
sid->down.bounce_y_hold = EINA_FALSE;
sid->down.ax = 0;
{
_elm_scroll_anim_stop(sid);
}
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.x.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.y.animator, ecore_animator_del);
if (sid->down.bounce_x_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_x_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_x_animator, ecore_animator_del);
sid->bouncemex = EINA_FALSE;
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.bounce_y_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_y_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_y_animator, ecore_animator_del);
sid->bouncemey = EINA_FALSE;
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.bounce_y_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_y_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_y_animator, ecore_animator_del);
_elm_scroll_momentum_end(sid);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.bounce_x_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_x_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_x_animator, ecore_animator_del);
_elm_scroll_momentum_end(sid);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
{
if (sid->down.onhold_animator)
{
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.onhold_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
}
if (sid->down.hold_animator)
{
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.onhold_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
sid->down.hold = EINA_TRUE;
_elm_scroll_anim_stop(sid);
}
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.x.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.y.animator, ecore_animator_del);
if (sid->down.bounce_x_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_x_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_x_animator, ecore_animator_del);
sid->bouncemex = EINA_FALSE;
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.bounce_y_animator)
{
- ELM_FREE_FUNC(sid->down.bounce_y_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.bounce_y_animator, ecore_animator_del);
sid->bouncemey = EINA_FALSE;
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.hold_animator)
{
- ELM_FREE_FUNC(sid->down.hold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.hold_animator, ecore_animator_del);
_elm_scroll_drag_stop(sid);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
if (sid->down.momentum_animator)
{
- ELM_FREE_FUNC(sid->down.momentum_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.momentum_animator, ecore_animator_del);
sid->down.bounce_x_hold = EINA_FALSE;
sid->down.bounce_y_hold = EINA_FALSE;
sid->down.ax = 0;
!(sid->block & ELM_SCROLLER_MOVEMENT_BLOCK_HORIZONTAL))
{
Evas_Coord px;
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.x.animator, ecore_animator_del);
eo_do(sid->pan_obj, elm_obj_pan_pos_get(&px, NULL));
sid->down.sx = px;
sid->down.x = sid->down.history[0].x;
!(sid->block & ELM_SCROLLER_MOVEMENT_BLOCK_VERTICAL))
{
Evas_Coord py;
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.y.animator, ecore_animator_del);
eo_do(sid->pan_obj, elm_obj_pan_pos_get(NULL, &py));
sid->down.sy = py;
sid->down.y = sid->down.history[0].y;
{
if (sid->down.onhold_animator)
{
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.onhold_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
{
if (sid->down.momentum_animator)
{
- ELM_FREE_FUNC(sid->down.momentum_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.momentum_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
sid->bounce_animator_disabled = disabled;
if (sid->bounce_animator_disabled)
{
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.x.animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->scrollto.y.animator, ecore_animator_del);
}
}
{
if (sid->down.onhold_animator)
{
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
+ ELM_SAFE_FREE(sid->down.onhold_animator, ecore_animator_del);
if (sid->content_info.resized)
_elm_scroll_wanted_region_set(sid->obj);
}
eo_do(obj, elm_scrollable_interface_content_set(NULL));
if (!sid->extern_pan) evas_object_del(sid->pan_obj);
- ELM_FREE_FUNC(sid->down.hold_animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->down.onhold_animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->down.momentum_animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->down.bounce_x_animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->down.bounce_y_animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->scrollto.x.animator, ecore_animator_del);
- ELM_FREE_FUNC(sid->scrollto.y.animator, ecore_animator_del);
+ if (sid->down.hold_animator) ecore_animator_del(sid->down.hold_animator);
+ if (sid->down.onhold_animator) ecore_animator_del(sid->down.onhold_animator);
+ if (sid->down.momentum_animator) ecore_animator_del(sid->down.momentum_animator);
+ if (sid->down.bounce_x_animator) ecore_animator_del(sid->down.bounce_x_animator);
+ if (sid->down.bounce_y_animator) ecore_animator_del(sid->down.bounce_y_animator);
+ if (sid->scrollto.x.animator) ecore_animator_del(sid->scrollto.x.animator);
+ if (sid->scrollto.y.animator) ecore_animator_del(sid->scrollto.y.animator);
}
static void