diff options
author | crupest <crupest@outlook.com> | 2022-03-29 22:55:29 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2022-03-29 22:55:29 +0800 |
commit | 77e217af8bdbfb20b9147f6159d5bdfda439ea95 (patch) | |
tree | 46873c9dc28ad7d0f900a8f7610a1ea4b881f75e /src/theme_builder/components/stylers/StylerEditor.h | |
parent | 6c09f49d51a564ff4dd0a6d3fa9804dffc2b236c (diff) | |
download | cru-77e217af8bdbfb20b9147f6159d5bdfda439ea95.tar.gz cru-77e217af8bdbfb20b9147f6159d5bdfda439ea95.tar.bz2 cru-77e217af8bdbfb20b9147f6159d5bdfda439ea95.zip |
...
Diffstat (limited to 'src/theme_builder/components/stylers/StylerEditor.h')
-rw-r--r-- | src/theme_builder/components/stylers/StylerEditor.h | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/src/theme_builder/components/stylers/StylerEditor.h b/src/theme_builder/components/stylers/StylerEditor.h index 3cbcb5a5..8aa52bda 100644 --- a/src/theme_builder/components/stylers/StylerEditor.h +++ b/src/theme_builder/components/stylers/StylerEditor.h @@ -1,33 +1,15 @@ #pragma once -#include "../Editor.h" -#include "cru/ui/controls/Container.h" -#include "cru/ui/controls/FlexLayout.h" -#include "cru/ui/controls/TextBlock.h" +#include "../HeadBodyEditor.h" #include "cru/ui/style/Styler.h" namespace cru::theme_builder::components::stylers { -class StylerEditor : public Editor { +class StylerEditor : public HeadBodyEditor { public: StylerEditor(); ~StylerEditor() override; public: - ui::controls::Control* GetRootControl() override { return &border_; } - - ui::controls::FlexLayout* GetContainer() { return &container_; } - - ui::controls::FlexLayout* GetHeadContainer() { return &head_container_; } - - String GetLabel() const { return label_.GetText(); } - void SetLabel(String label) { label_.SetText(std::move(label)); } - virtual ClonablePtr<ui::style::Styler> GetStyler() = 0; - - private: - ui::controls::Container border_; - ui::controls::FlexLayout container_; - ui::controls::FlexLayout head_container_; - ui::controls::TextBlock label_; }; std::unique_ptr<StylerEditor> CreateStylerEditor(ui::style::Styler* styler); |