mirror of
https://github.com/mudita/MuditaOS.git
synced 2026-10-25 07:58:29 -04:00
* tryAddWidget was redundant to addWidget, with Rect fixes and log it's not needed * With changes in BoundingBox simplified axis use in BoxLayout * Add widget moves elements to it's place, resize is not thought through and for now is removed
25 lines
682 B
C++
25 lines
682 B
C++
#pragma once
|
|
|
|
#include <BoxLayout.hpp>
|
|
|
|
namespace gui
|
|
{
|
|
|
|
class PageLayout : public BoxLayout
|
|
{
|
|
public:
|
|
PageLayout() = default;
|
|
virtual ~PageLayout() = default;
|
|
PageLayout(Item *parent, const uint32_t &x, const uint32_t &y, const uint32_t &w, const uint32_t &h);
|
|
PageLayout(Item *parent, const BoundingBox &box);
|
|
|
|
VBox *addPage();
|
|
virtual bool addWidget(Item *item) override;
|
|
/// switch page to page ∈ [0 ... (num of pages -1) )
|
|
/// set it's navigation and select first element as selected (in setVisible)
|
|
bool switchPage(unsigned int n, bool previous = false);
|
|
};
|
|
|
|
;
|
|
} // namespace gui
|