Files
Upsilon/apps/graph/list/parameter_controller.h
Émilie Feral 56edcded0a [apps/graph/list] Add a switch to the parameter page in graph app
Change-Id: I51f432939157cbd772e7e868d3e0c8e54d279a6d
2016-09-21 11:55:18 +02:00

36 lines
972 B
C++

#ifndef GRAPH_LIST_PARAM_CONTROLLER_H
#define GRAPH_LIST_PARAM_CONTROLLER_H
#include <escher.h>
#include "../function.h"
#include "../function_store.h"
class ParameterController : public ViewController, public TableViewDataSource {
public:
ParameterController(Responder * parentResponder);
View * view() override;
const char * title() const override;
bool handleEvent(Ion::Events::Event event) override;
void setFunction(Graph::Function * function);
void didBecomeFirstResponder() override;
void setActiveCell(int index);
int numberOfCells() override;
KDCoordinate cellHeight() override;
View * reusableCell(int index) override;
int reusableCellCount() override;
private:
constexpr static int k_totalNumberOfCell = 3;
TableViewCell m_colorCell;
SwitchTableViewCell m_enableCell;
TableViewCell m_deleteCell;
TableView m_tableView;
int m_activeCell;
Graph::Function * m_function;
Graph::FunctionStore * m_functionStore;
};
#endif