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

fix(obj_pos) save x,y even if the object is on a layout

The set values will be ignored later, but they needs to be saved
in case the layout is removed from the parent
This commit is contained in:
Gabor Kiss-Vamosi 2021-10-20 11:55:26 +02:00
parent 91a0d3b5e4
commit a9b660c278

View File

@ -51,9 +51,6 @@ void lv_obj_set_pos(lv_obj_t * obj, lv_coord_t x, lv_coord_t y)
void lv_obj_set_x(lv_obj_t * obj, lv_coord_t x)
{
LV_ASSERT_OBJ(obj, MY_CLASS);
if(lv_obj_is_layout_positioned(obj)) {
return;
}
lv_res_t res_x;
lv_style_value_t v_x;
@ -67,9 +64,6 @@ void lv_obj_set_x(lv_obj_t * obj, lv_coord_t x)
void lv_obj_set_y(lv_obj_t * obj, lv_coord_t y)
{
if(lv_obj_is_layout_positioned(obj)) {
return;
}
LV_ASSERT_OBJ(obj, MY_CLASS);
lv_res_t res_y;