fix warning/error for Graphics feature usage

This commit is contained in:
Zaltora
2018-01-16 11:54:35 +01:00
parent ee4a419019
commit 7d302574cc
6 changed files with 22 additions and 1 deletions

View File

@@ -44,7 +44,9 @@ static void refr_btn_width(lv_obj_t *list);
* STATIC VARIABLES
**********************/
static lv_signal_func_t btn_signal;
#if USE_LV_IMG
static lv_signal_func_t img_signal;
#endif
static lv_signal_func_t label_signal;
static lv_signal_func_t ancestor_signal;
@@ -110,8 +112,10 @@ lv_obj_t * lv_list_create(lv_obj_t * par, lv_obj_t * copy)
lv_obj_t *new_btn;
while(copy_btn) {
new_btn = lv_btn_create(new_list, copy_btn);
#if USE_LV_IMG
lv_obj_t *copy_img = lv_list_get_btn_img(copy_btn);
if(copy_img) lv_img_create(new_btn, copy_img);
#endif
lv_label_create(new_btn, lv_list_get_btn_label(copy_btn));
copy_btn = lv_obj_get_child_back(lv_page_get_scrl(copy), copy_btn);
}

View File

@@ -198,9 +198,9 @@ void lv_mbox_set_anim_time(lv_obj_t * mbox, uint16_t time)
*/
void lv_mbox_start_auto_close(lv_obj_t * mbox, uint16_t delay)
{
#if USE_LV_ANIMATION
lv_mbox_ext_t * ext = lv_obj_get_ext_attr(mbox);
#if USE_LV_ANIMATION
if(ext->anim_time != 0) {
/*Add shrinking animations*/
lv_obj_animate(mbox, LV_ANIM_GROW_H| LV_ANIM_OUT, ext->anim_time, delay, NULL);

View File

@@ -45,8 +45,10 @@ static bool lv_ta_design(lv_obj_t * ta, const lv_area_t * mask, lv_design_mode_t
static bool lv_ta_scrollable_design(lv_obj_t * scrl, const lv_area_t * mask, lv_design_mode_t mode);
static lv_res_t lv_ta_signal(lv_obj_t * ta, lv_signal_t sign, void * param);
static lv_res_t lv_ta_scrollable_signal(lv_obj_t * scrl, lv_signal_t sign, void * param);
#if USE_LV_ANIMATION
static void cursor_blink_anim(lv_obj_t * ta, uint8_t show);
static void pwd_char_hider_anim(lv_obj_t * ta, int32_t x);
#endif
static void pwd_char_hider(lv_obj_t * ta);
/**********************
@@ -987,6 +989,8 @@ static lv_res_t lv_ta_scrollable_signal(lv_obj_t * scrl, lv_signal_t sign, void
return res;
}
#if USE_LV_ANIMATION
/**
* Called to blink the cursor
* @param ta pointer to a text area
@@ -1018,6 +1022,8 @@ static void pwd_char_hider_anim(lv_obj_t * ta, int32_t x)
(void)x;
}
#endif
/**
* Hide all characters (convert them to '*')
* @param ta: pointer to text area object