[apps/sequence] Do no add a new function as long as the user did not

choose a type

Change-Id: I67c3172b416d7d80a3bd9a4eb18091ab72626e4b
This commit is contained in:
Émilie Feral
2017-02-08 13:57:05 +01:00
parent 0f4d7f0914
commit 08a663a64f
7 changed files with 36 additions and 42 deletions

View File

@@ -148,17 +148,6 @@ void ListController::didBecomeFirstResponder() {
app()->setFirstResponder(&m_selectableTableView);
}
bool ListController::addFunction() {
if (m_functionStore->numberOfFunctions() < m_functionStore->maxNumberOfFunctions()) {
m_functionStore->addEmptyFunction();
m_selectableTableView.reloadData();
return true;
}
// Add a warning to tell the user there is no more space for new functions
app()->displayWarning("Nombre maximal d'éléments atteint");
return false;
}
void ListController::configureFunction(Function * function) {
StackViewController * stack = stackController();
parameterController()->setFunction(function);