flex grid: add shortcut for Window

This commit is contained in:
Raphael Coeffic
2022-06-11 15:13:11 +02:00
committed by Raphael Coeffic
parent e47b1ca245
commit 14fea89118
+4
View File
@@ -41,6 +41,8 @@ class FlexGridLayout
{
}
void apply(Window* w) { apply(w->getLvObj()); }
void apply(lv_obj_t* obj) {
// padding
@@ -56,6 +58,8 @@ class FlexGridLayout
}
}
void add(Window* w) { add(w->getLvObj()); }
void add(lv_obj_t* obj) {
if (col_dsc && row_dsc) {
lv_obj_set_grid_cell(obj, LV_GRID_ALIGN_START, col_pos, col_span,