[apps/calculation] Reset highlighted cells in additional results

Change-Id: I517e7d3dd025413f405fed605631dad830540e76
This commit is contained in:
Hugo Saint-Vignes
2020-07-22 10:52:22 +02:00
committed by Émilie Feral
parent 44da25dd64
commit d027d99597

View File

@@ -29,6 +29,9 @@ void ExpressionsListController::viewDidDisappear() {
// Reset layout and cell memoization to avoid taking extra space in the pool
for (int i = 0; i < k_maxNumberOfRows; i++) {
m_cells[i].setLayout(Layout());
/* By reseting m_layouts, numberOfRow will go down to 0, and the highlighted
* cells won't be unselected. Therefore we unselect them here. */
m_cells[i].setHighlighted(false);
m_layouts[i] = Layout();
}
m_expression = Expression();