Added configuration helper types.
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
|
||||
#include <array>
|
||||
#include "raid/raid.hpp"
|
||||
#include "./frames/config.hpp"
|
||||
#include "./frames/data_table.hpp"
|
||||
|
||||
namespace raid_test
|
||||
@@ -20,12 +21,17 @@ private:
|
||||
render_fn_t render;
|
||||
};
|
||||
static constexpr Frame FRAMES[] = {
|
||||
{.title = CONFIG_TITLE, .render = &renderConfig},
|
||||
{.title = DATA_TABLE_TITLE, .render = &renderDataTable}
|
||||
};
|
||||
static constexpr std::size_t NUM_FRAMES = sizeof(FRAMES) / sizeof(FRAMES[0]);
|
||||
|
||||
raid::FileConfig mConfig;
|
||||
bool mShowMetrics = false;
|
||||
std::array<bool, NUM_FRAMES> mFrameOpen{};
|
||||
public:
|
||||
[[nodiscard]]
|
||||
raid::FileConfig& getConfig() noexcept { return mConfig; }
|
||||
protected:
|
||||
bool init() override;
|
||||
void configureImgui() override;
|
||||
|
||||
Reference in New Issue
Block a user