1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-28 07:03:00 +08:00

anim built names are updated (LV_ prefix added)

This commit is contained in:
Gabor 2016-07-12 15:07:57 +02:00
parent 50634f2053
commit 9274c1705e
2 changed files with 16 additions and 16 deletions

View File

@ -979,7 +979,7 @@ void lv_obj_anim(lv_obj_t * obj_dp, lv_anim_builtin_t type, uint16_t time, uint1
bool out = (type & ANIM_DIR_MASK) == ANIM_IN ? false : true;
type = type & (~ANIM_DIR_MASK);
if(type == ANIM_NONE) return;
if(type == LV_ANIM_NONE) return;
anim_t a;
a.p = obj_dp;
@ -989,43 +989,43 @@ void lv_obj_anim(lv_obj_t * obj_dp, lv_anim_builtin_t type, uint16_t time, uint1
/*Init to ANIM_IN*/
switch(type) {
case ANIM_FLOAT_LEFT:
case LV_ANIM_FLOAT_LEFT:
a.fp = (void(*)(void *, int32_t))lv_obj_set_x;
a.start = -lv_obj_get_width(obj_dp);
a.end = lv_obj_get_x(obj_dp);
a.path_p = anim_path_lin;
break;
case ANIM_FLOAT_RIGHT:
case LV_ANIM_FLOAT_RIGHT:
a.fp = (void(*)(void *, int32_t))lv_obj_set_x;
a.start = lv_obj_get_width(par_dp);
a.end = lv_obj_get_x(obj_dp);
a.path_p = anim_path_lin;
break;
case ANIM_FLOAT_TOP:
case LV_ANIM_FLOAT_TOP:
a.fp = (void(*)(void * , int32_t))lv_obj_set_y;
a.start = -lv_obj_get_height(obj_dp);
a.end = lv_obj_get_y(obj_dp);
a.path_p = anim_path_lin;
break;
case ANIM_FLOAT_BOTTOM:
case LV_ANIM_FLOAT_BOTTOM:
a.fp = (void(*)(void * , int32_t))lv_obj_set_y;
a.start = lv_obj_get_height(par_dp);
a.end = lv_obj_get_y(obj_dp);
a.path_p = anim_path_lin;
break;
case ANIM_FADE:
case LV_ANIM_FADE:
a.fp = (void(*)(void * , int32_t))lv_obj_set_opar;
a.start = OPA_TRANSP;
a.end = OPA_COVER;
a.path_p = anim_path_lin;
break;
case ANIM_GROW_H:
case LV_ANIM_GROW_H:
a.fp = (void(*)(void * , int32_t))lv_obj_set_width;
a.start = 0;
a.end = lv_obj_get_width(obj_dp);
a.path_p = anim_path_lin;
break;
case ANIM_GROW_V:
case LV_ANIM_GROW_V:
a.fp = (void(*)(void * , int32_t))lv_obj_set_height;
a.start = 0;
a.end = lv_obj_get_height(obj_dp);

View File

@ -150,14 +150,14 @@ typedef enum
typedef enum
{
ANIM_NONE = 0,
ANIM_FADE,
ANIM_FLOAT_TOP,
ANIM_FLOAT_LEFT,
ANIM_FLOAT_BOTTOM,
ANIM_FLOAT_RIGHT,
ANIM_GROW_H,
ANIM_GROW_V,
LV_ANIM_NONE = 0,
LV_ANIM_FADE,
LV_ANIM_FLOAT_TOP,
LV_ANIM_FLOAT_LEFT,
LV_ANIM_FLOAT_BOTTOM,
LV_ANIM_FLOAT_RIGHT,
LV_ANIM_GROW_H,
LV_ANIM_GROW_V,
}lv_anim_builtin_t;
/**********************