[apps/graph/values] Implement the action linked to the button "Regler l'intervallle"

Change-Id: I60a8c11b518f6f5c6e68908f0f99341e0c350af9
This commit is contained in:
Émilie Feral
2016-10-12 11:40:40 +02:00
parent 8fd83716e3
commit 5b1078175a

View File

@@ -11,6 +11,11 @@ ValuesController::ValuesController(Responder * parentResponder, Graph::FunctionS
m_parameterController(ValuesParameterController(this))
{
setButtonTitles("Regler l'intervalle", nullptr, nullptr);
setButtonActions(Invocation([](void * context, void * sender) {
ValuesController * valuesController = (ValuesController *) context;
StackViewController * stack = ((StackViewController *)valuesController->parentResponder());
stack->push(valuesController->parameterController());
}, this), Invocation(nullptr, nullptr), Invocation(nullptr, nullptr));
}
const char * ValuesController::title() const {
@@ -101,6 +106,7 @@ void ValuesController::setActiveCell(int i, int j) {
}
void ValuesController::didBecomeFirstResponder() {
setSelectedButton(-1);
if (m_activeCellY == -1) {
setActiveCell(0,0);
} else {