[apps/*/editable_cell_table_view_controller] Use typeAtLocation

This commit is contained in:
Ruben Dashyan
2019-08-01 10:21:08 +02:00
parent dbb7d3d01c
commit 04fcc0eac4
7 changed files with 17 additions and 24 deletions

View File

@@ -23,13 +23,13 @@ ValuesController::ValuesController(Responder * parentResponder,InputEventHandler
void ValuesController::willDisplayCellAtLocation(HighlightCell * cell, int i, int j) {
Shared::ValuesController::willDisplayCellAtLocation(cell, i, j);
// The cell is the abscissa title cell:
if (j == 0 && i == 0) {
if (typeAtLocation(i,j) == 0) {
EvenOddMessageTextCell * mytitleCell = (EvenOddMessageTextCell *)cell;
mytitleCell->setMessage(I18n::Message::N);
return;
}
// The cell is a function title cell:
if (j == 0 && i > 0) {
if (typeAtLocation(i,j) == 1) {
SequenceTitleCell * myCell = (SequenceTitleCell *)cell;
Sequence * sequence = functionStore()->modelForRecord(recordAtColumn(i));
myCell->setLayout(sequence->nameLayout());