fix(refr): fix lv_refr_get_top_obj

related to https://forum.lvgl.io/t/how-to-speed-up-the-v8-version/9091/21
This commit is contained in:
Gabor Kiss-Vamosi
2022-07-09 14:37:14 +02:00
parent 0eab027a33
commit 56a5742c77
+3 -3
View File
@@ -738,9 +738,9 @@ static lv_obj_t * lv_refr_get_top_obj(const lv_area_t * area_p, lv_obj_t * obj)
lv_event_send(obj, LV_EVENT_COVER_CHECK, &info);
if(info.res == LV_COVER_RES_MASKED) return NULL;
uint32_t i;
uint32_t child_cnt = lv_obj_get_child_cnt(obj);
for(i = 0; i < child_cnt; i++) {
int32_t i;
int32_t child_cnt = lv_obj_get_child_cnt(obj);
for(i = child_cnt - 1; i >= 0; i--) {
lv_obj_t * child = obj->spec_attr->children[i];
found_p = lv_refr_get_top_obj(area_p, child);