remove static DefaultCell
This commit is contained in:
+2
-3
@@ -5,13 +5,12 @@
|
||||
import { CharData, IBufferLine } from './Types';
|
||||
import { NULL_CELL_CODE, NULL_CELL_WIDTH, NULL_CELL_CHAR } from './Buffer';
|
||||
|
||||
export const defaultCell: CharData = [0, NULL_CELL_CHAR, NULL_CELL_WIDTH, NULL_CELL_CODE];
|
||||
export const DEFAULT_CELL: CharData = [0, NULL_CELL_CHAR, NULL_CELL_WIDTH, NULL_CELL_CODE];
|
||||
|
||||
/**
|
||||
* Class representing a terminal line.
|
||||
*/
|
||||
export class BufferLine implements IBufferLine {
|
||||
static defaultCell: CharData = [0, NULL_CELL_CHAR, NULL_CELL_WIDTH, NULL_CELL_CODE];
|
||||
static blankLine(cols: number, attr: number, isWrapped?: boolean): IBufferLine {
|
||||
const ch: CharData = [attr, NULL_CELL_CHAR, NULL_CELL_WIDTH, NULL_CELL_CODE];
|
||||
return new BufferLine(cols, ch, isWrapped);
|
||||
@@ -25,7 +24,7 @@ export class BufferLine implements IBufferLine {
|
||||
this.length = this._data.length;
|
||||
if (cols) {
|
||||
if (!ch) {
|
||||
ch = BufferLine.defaultCell;
|
||||
ch = DEFAULT_CELL;
|
||||
}
|
||||
for (let i = 0; i < cols; i++) {
|
||||
this.push(ch); // Note: the ctor ch is not cloned
|
||||
|
||||
Reference in New Issue
Block a user