From 2dd9ca06d347c5b81ab05f94f40a3e59000cbe19 Mon Sep 17 00:00:00 2001 From: Gabor Kiss-Vamosi Date: Fri, 26 Mar 2021 20:27:11 +0100 Subject: [PATCH] minor fixes --- src/extra/themes/default/lv_theme_default.c | 3 +-- src/extra/widgets/msgbox/lv_msgbox.c | 2 +- src/extra/widgets/win/lv_win.c | 1 + 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/extra/themes/default/lv_theme_default.c b/src/extra/themes/default/lv_theme_default.c index 7743d739f..6a35a4273 100644 --- a/src/extra/themes/default/lv_theme_default.c +++ b/src/extra/themes/default/lv_theme_default.c @@ -600,8 +600,7 @@ static void theme_apply(lv_theme_t * th, lv_obj_t * obj) /*Header*/ if(lv_obj_get_child_id(obj) == 0 && lv_obj_check_type(lv_obj_get_parent(obj), &lv_win_class)) { lv_obj_add_style(obj, LV_PART_MAIN, LV_STATE_DEFAULT, &styles->bg_color_grey); - lv_obj_add_style(obj, LV_PART_MAIN, LV_STATE_DEFAULT, &styles->pad_small); - lv_obj_add_style(obj, LV_PART_MAIN, LV_STATE_DEFAULT, &styles->text_align_center); + lv_obj_add_style(obj, LV_PART_MAIN, LV_STATE_DEFAULT, &styles->pad_tiny); return; } /*Content*/ diff --git a/src/extra/widgets/msgbox/lv_msgbox.c b/src/extra/widgets/msgbox/lv_msgbox.c index 007a13b03..5064fd707 100644 --- a/src/extra/widgets/msgbox/lv_msgbox.c +++ b/src/extra/widgets/msgbox/lv_msgbox.c @@ -58,7 +58,7 @@ lv_obj_t * lv_msgbox_create(const char * title, const char * txt, const char * b if(w > 2 * LV_DPI_DEF) w = 2 * LV_DPI_DEF; lv_obj_set_size(mbox, w, LV_SIZE_CONTENT); - lv_obj_set_flex_flow(mbox, LV_FLEX_FLOW_ROW); + lv_obj_set_flex_flow(mbox, LV_FLEX_FLOW_ROW_WRAP); lv_obj_t * label; label = lv_label_create(mbox); diff --git a/src/extra/widgets/win/lv_win.c b/src/extra/widgets/win/lv_win.c index bd2c5a867..59fc9687b 100644 --- a/src/extra/widgets/win/lv_win.c +++ b/src/extra/widgets/win/lv_win.c @@ -89,6 +89,7 @@ static void lv_win_constructor(lv_obj_t * obj) lv_obj_t * header = lv_obj_create(obj); lv_obj_set_size(header, LV_SIZE_PCT(100), create_header_height); lv_obj_set_flex_flow(header, LV_FLEX_FLOW_ROW); + lv_obj_set_flex_place(header, LV_FLEX_PLACE_START, LV_FLEX_PLACE_CENTER, LV_FLEX_PLACE_CENTER); lv_obj_t * cont = lv_obj_create(obj); lv_obj_set_flex_grow(cont, 1);