From 13033c28d83f5768b89a577e27f0fd1de054bbd8 Mon Sep 17 00:00:00 2001 From: Gabor Kiss-Vamosi Date: Sat, 23 Mar 2019 01:05:41 +0100 Subject: [PATCH] lv_page: fix scrl left padding --- src/lv_objx/lv_page.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lv_objx/lv_page.c b/src/lv_objx/lv_page.c index ecc2e7cab..4e7feaf80 100644 --- a/src/lv_objx/lv_page.c +++ b/src/lv_objx/lv_page.c @@ -944,7 +944,7 @@ static lv_res_t lv_page_scrollable_signal(lv_obj_t * scrl, lv_signal_t sign, voi } } else if(scrl_coords.x1 > page_coords.x1 + page_style->body.padding.left) { - new_x = hpad; /*Left align*/ + new_x = page_style->body.padding.left; /*Left align*/ refr_x = true; if(page_ext->edge_flash.enabled && page_ext->edge_flash.left_ip == 0 && page_ext->edge_flash.right_ip == 0 && @@ -955,7 +955,7 @@ static lv_res_t lv_page_scrollable_signal(lv_obj_t * scrl, lv_signal_t sign, voi } } - /*scrollable height smaller then page height? -> align to left*/ + /*scrollable height smaller then page height? -> align to top*/ if(lv_area_get_height(&scrl_coords) + vpad <= lv_area_get_height(&page_coords)) { if(scrl_coords.y1 != page_coords.y1 + page_style->body.padding.top) { new_y = page_style->body.padding.top;