[apps] enable node navigation controller to use different cell types

(implemented by its subclasses)

Change-Id: I44ef187c0142f049c710a4515c3dc0edf5573927
This commit is contained in:
Émilie Feral
2016-11-14 10:48:56 +01:00
parent 9e9302b602
commit 41f8d0c75c
8 changed files with 53 additions and 10 deletions

View File

@@ -19,6 +19,19 @@ const char * VariableBoxController::title() const {
return "VariableBoxController";
}
TableViewCell * VariableBoxController::leafCellAtIndex(int index) {
return &m_leafCells[index];
}
TableViewCell * VariableBoxController::nodeCellAtIndex(int index) {
return &m_nodeCells[index];
}
void VariableBoxController::willDisplayCellForIndex(TableViewCell * cell, int index) {
MenuListCell * myCell = (MenuListCell *)cell;
myCell->setText(m_listViewController.nodeModel()->children(index)->label());
}
Node * VariableBoxController::nodeModel() {
return (Node *)&variableBoxModel;
}