31 lines
845 B
C++
31 lines
845 B
C++
#pragma once
|
|
|
|
#include "RoomCardWidgetBase.hpp"
|
|
|
|
class RoomCardTileWidget : public RoomCardWidgetBase {
|
|
public:
|
|
explicit RoomCardTileWidget(const WidgetConfig& config);
|
|
~RoomCardTileWidget() override = default;
|
|
|
|
lv_obj_t* create(lv_obj_t* parent) override;
|
|
void applyStyle() override;
|
|
void clearLvglObject() override;
|
|
|
|
// Text line KNX updates
|
|
void onTextLineValue(uint8_t index, float value);
|
|
|
|
protected:
|
|
void calculateSubButtonPosition(uint8_t index, const SubButtonConfig& cfg, int16_t& x, int16_t& y) override;
|
|
|
|
private:
|
|
// Tile-specific elements
|
|
lv_obj_t* decorIcon_ = nullptr;
|
|
|
|
// Text line elements (rows with icon + label)
|
|
lv_obj_t* textLineLabels_[MAX_TEXTLINES] = {};
|
|
|
|
void createTileLayout();
|
|
void createTextLines();
|
|
void updateTextLineValue(uint8_t index, float value);
|
|
};
|