mirror of
https://github.com/lvgl/lvgl.git
synced 2026-05-23 07:46:36 +08:00
fix(scroll): fix infinite loop in scroll_end events (#6109)
This commit is contained in:
committed by
GitHub
parent
447f9b8f48
commit
92ea719669
@@ -677,7 +677,8 @@ static void scroll_y_anim(void * obj, int32_t v)
|
||||
|
||||
static void scroll_end_cb(lv_anim_t * a)
|
||||
{
|
||||
lv_obj_send_event(a->var, LV_EVENT_SCROLL_END, NULL);
|
||||
/*Do not sent END event if there wasn't a BEGIN*/
|
||||
if(a->start_cb_called) lv_obj_send_event(a->var, LV_EVENT_SCROLL_END, NULL);
|
||||
}
|
||||
|
||||
static void scroll_area_into_view(const lv_area_t * area, lv_obj_t * child, lv_point_t * scroll_value,
|
||||
|
||||
@@ -96,7 +96,6 @@ void lv_flex_init(void)
|
||||
{
|
||||
layout_list_def[LV_LAYOUT_FLEX].cb = flex_update;
|
||||
layout_list_def[LV_LAYOUT_FLEX].user_data = NULL;
|
||||
|
||||
}
|
||||
|
||||
void lv_obj_set_flex_flow(lv_obj_t * obj, lv_flex_flow_t flow)
|
||||
|
||||
@@ -353,9 +353,6 @@ static void anim_timer(lv_timer_t * param)
|
||||
lv_anim_t * a = _lv_ll_get_head(anim_ll_p);
|
||||
|
||||
while(a != NULL) {
|
||||
|
||||
// printf("%p, %d\n", a, a->start_value);
|
||||
|
||||
uint32_t elaps = lv_tick_elaps(a->last_timer_run);
|
||||
a->act_time += elaps;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user