[apps/calc] Do not forget to call parent method

Scenario: Open several times the additional outputs menu, there are
drawing problems (multiple stack headers)
This commit is contained in:
Léa Saviot
2020-02-21 16:36:22 +01:00
committed by EmilieNumworks
parent 686e25ec43
commit c8537df3b4
2 changed files with 4 additions and 3 deletions

View File

@@ -25,10 +25,11 @@ int ExpressionsListController::reusableCellCount(int type) {
}
void ExpressionsListController::viewDidDisappear() {
ListController::viewDidDisappear();
// Reset cell memoization to avoid taking extra space in the pool
for (int i = 0; i < k_maxNumberOfCells; i++) {
m_cells[i].setLayout(Layout());
}
m_cells[i].setLayout(Layout());
}
}
HighlightCell * ExpressionsListController::reusableCell(int index, int type) {

View File

@@ -26,7 +26,7 @@ void IllustratedListController::didEnterResponderChain(Responder * previousFirst
}
void IllustratedListController::viewDidDisappear() {
StackViewController::viewDidDisappear();
ListController::viewDidDisappear();
// Reset the context as it was before displaying the IllustratedListController
Poincare::Context * context = App::app()->localContext();
if (m_savedExpression.isUninitialized()) {