* Emit additions for a row that only exists in next (height grew). * Skips empty/unwritten cells.
( nextCells: Int32Array, next: Screen, ci: number, y: number, startX: number, endX: number, nextCell: Cell, cb: DiffCallback, )
| 1649 | * Skips empty/unwritten cells. |
| 1650 | */ |
| 1651 | function diffRowAdded( |
| 1652 | nextCells: Int32Array, |
| 1653 | next: Screen, |
| 1654 | ci: number, |
| 1655 | y: number, |
| 1656 | startX: number, |
| 1657 | endX: number, |
| 1658 | nextCell: Cell, |
| 1659 | cb: DiffCallback, |
| 1660 | ): boolean { |
| 1661 | for (let x = startX; x < endX; x++, ci += 2) { |
| 1662 | if (nextCells[ci] === 0 && nextCells[ci | 1] === 0) continue |
| 1663 | cellAtCI(next, ci, nextCell) |
| 1664 | if (cb(x, y, undefined, nextCell)) return true |
| 1665 | } |
| 1666 | return false |
| 1667 | } |
| 1668 | |
| 1669 | /** |
| 1670 | * Diff two screens with identical width. |
no test coverage detected