1 #ifndef ESCHER_STACK_VIEW_CONTROLLER_H 2 #define ESCHER_STACK_VIEW_CONTROLLER_H 21 const char *
title()
override;
30 m_viewController(viewController),
31 m_textColor(textColor),
32 m_backgroundColor(backgroundColor),
33 m_separatorColor(separatorColor) {}
35 KDColor textColor() {
return m_textColor; }
36 KDColor backgroundColor() {
return m_backgroundColor; }
37 KDColor separatorColor() {
return m_separatorColor; }
44 class ControllerView :
public View {
47 void shouldDisplayStackHearders(
bool shouldDisplay);
48 int8_t numberOfStacks()
const {
return m_numberOfStacks; }
50 void pushStack(Frame frame);
53 #if ESCHER_VIEW_LOGGING 54 const char * className()
const override;
57 int numberOfSubviews()
const override;
58 View * subviewAtIndex(
int index)
override;
59 void layoutSubviews()
override;
64 bool m_displayStackHeaders;
66 ControllerView m_view;
67 void pushModel(Frame frame);
68 void setupActiveViewController();
69 static constexpr
uint8_t k_maxNumberOfChildren = 4;
70 Frame m_childrenFrame[k_maxNumberOfChildren];
StackViewController(Responder *parentResponder, ViewController *rootViewController, KDColor textColor=Palette::SubTab, KDColor backgroundColor=KDColorWhite, KDColor separatorColor=Palette::GreyBright)
void push(ViewController *vc, KDColor textColor=Palette::SubTab, KDColor backgroundColor=KDColorWhite, KDColor separatorColor=Palette::GreyBright)
Responder * parentResponder() const
const char * title() override
void viewDidDisappear() override
constexpr KDColor KDColorWhite
static constexpr KDColor SubTab
bool handleEvent(Ion::Events::Event event) override
constexpr uint8_t kMaxNumberOfStacks
void viewWillAppear() override
void didBecomeFirstResponder() override
static constexpr KDColor GreyBright