* Load data at `index` into `cell`. This is used to access cells in a way that's more friendly * to GC as it significantly reduced the amount of new objects/references needed.
(index: number, cell: ICellData)
| 179 | * to GC as it significantly reduced the amount of new objects/references needed. |
| 180 | */ |
| 181 | public loadCell(index: number, cell: ICellData): ICellData { |
| 182 | $startIndex = index * CELL_SIZE; |
| 183 | cell.content = this._data[$startIndex + Cell.CONTENT]; |
| 184 | cell.fg = this._data[$startIndex + Cell.FG]; |
| 185 | cell.bg = this._data[$startIndex + Cell.BG]; |
| 186 | if (cell.content & Content.IS_COMBINED_MASK) { |
| 187 | cell.combinedData = this._combined[index]; |
| 188 | } |
| 189 | if (cell.bg & BgFlags.HAS_EXTENDED) { |
| 190 | cell.extended = this._extendedAttrs[index]!; |
| 191 | } |
| 192 | return cell; |
| 193 | } |
| 194 | |
| 195 | /** |
| 196 | * Set data at `index` to `cell`. |
no outgoing calls
no test coverage detected