Numworks Epsilon  1.4.1
Graphing Calculator Operating System
warning_controller.h
Go to the documentation of this file.
1 #ifndef ESCHER_WARNING_CONTROLLER_H
2 #define ESCHER_WARNING_CONTROLLER_H
3 
7 #include <escher/i18n.h>
8 
10 public:
11  WarningController(Responder * parentResponder, I18n::Message warningMessage);
12  void setLabel(I18n::Message message);
13  const char * title() override;
14  View * view() override;
15  bool handleEvent(Ion::Events::Event event) override;
16 private:
17  class ContentView : public SolidColorView {
18  public:
19  ContentView();
20  void setLabel(I18n::Message message);
21  int numberOfSubviews() const override;
22  View * subviewAtIndex(int index) override;
23  void layoutSubviews() override;
24  KDSize minimalSizeForOptimalDisplay() const override;
25  private:
26  constexpr static KDCoordinate k_verticalMargin = 40;
27  constexpr static KDCoordinate k_horizontalMargin = 20;
28  MessageTextView m_textView;
29  };
30 
31  ContentView m_contentView;
32  I18n::Message m_warningMessage;
33 };
34 
35 #endif
bool handleEvent(Ion::Events::Event event) override
const char * title() override
int16_t KDCoordinate
Definition: coordinate.h:6
Responder * parentResponder() const
Definition: responder.cpp:12
void setLabel(I18n::Message message)
Definition: size.h:6
View * view() override
WarningController(Responder *parentResponder, I18n::Message warningMessage)
Definition: view.h:23