diff options
Diffstat (limited to 'plugingui/frame.h')
-rw-r--r-- | plugingui/frame.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/plugingui/frame.h b/plugingui/frame.h index 1a07db0..04cfeb2 100644 --- a/plugingui/frame.h +++ b/plugingui/frame.h @@ -26,6 +26,8 @@ */ #pragma once +#include <notifier.h> + #include "font.h" #include "powerbutton.h" #include "widget.h" @@ -33,7 +35,8 @@ namespace GUI { -class FrameWidget : public Widget +class FrameWidget + : public Widget { public: FrameWidget(Widget* parent, bool has_switch = false); @@ -48,6 +51,10 @@ public: void setTitle(std::string const& title); void setContent(Widget* content); + void setOnSwitch(bool on); + + Notifier<bool> onSwitchChangeNotifier; // (bool on) + protected: // From Widget: virtual void repaintEvent(RepaintEvent* repaintEvent) override; |