| 161 | } |
| 162 | |
| 163 | void TableView::updateCellAtIndex(ssize_t idx) |
| 164 | { |
| 165 | if (idx == AX_INVALID_INDEX) |
| 166 | { |
| 167 | return; |
| 168 | } |
| 169 | auto countOfItems = _dataSource->numberOfCellsInTableView(this); |
| 170 | if (0 == countOfItems || idx > countOfItems - 1) |
| 171 | { |
| 172 | return; |
| 173 | } |
| 174 | |
| 175 | TableViewCell* cell = this->cellAtIndex(idx); |
| 176 | if (cell) |
| 177 | { |
| 178 | this->_moveCellOutOfSight(cell); |
| 179 | } |
| 180 | cell = _dataSource->tableCellAtIndex(this, (ssize_t)idx); |
| 181 | this->_setIndexForCell(idx, cell); |
| 182 | this->_addCellIfNecessary(cell); |
| 183 | } |
| 184 | |
| 185 | void TableView::insertCellAtIndex(ssize_t idx) |
| 186 | { |
no test coverage detected