Add option to have button without border. (#101)

This commit is contained in:
Arthur Sonzogni
2021-05-18 17:49:53 +02:00
committed by GitHub
parent ab9d6feaa5
commit 7b88656e25
4 changed files with 17 additions and 9 deletions

View File

@@ -21,7 +21,7 @@ class ButtonBase : public ComponentBase {
static ButtonBase* From(Component);
// Constructor.
ButtonBase(ConstStringRef label, std::function<void()> on_click);
ButtonBase(ConstStringRef label, std::function<void()> on_click, bool border);
~ButtonBase() override = default;
// Component implementation.
@@ -31,6 +31,7 @@ class ButtonBase : public ComponentBase {
private:
ConstStringRef label_;
std::function<void()> on_click_;
bool border_;
Box box_;
};