MCPcopy Create free account
hub / github.com/axmolengine/axmol / updateCellAtIndex

Method updateCellAtIndex

extensions/GUI/src/GUI/ScrollView/TableView.cpp:163–183  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

161}
162
163void 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
185void TableView::insertCellAtIndex(ssize_t idx)
186{

Calls 6

cellAtIndexMethod · 0.95
_moveCellOutOfSightMethod · 0.95
_setIndexForCellMethod · 0.95
_addCellIfNecessaryMethod · 0.95
tableCellAtIndexMethod · 0.45

Tested by

no test coverage detected