mirror of
https://github.com/embarklabs/neo-blessed.git
synced 2025-01-11 11:34:20 +00:00
minor change to alloc.
This commit is contained in:
parent
caa21ee356
commit
4541fc5c50
@ -534,16 +534,17 @@ Screen.prototype.__defineGetter__('height', function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
Screen.prototype.alloc = function() {
|
Screen.prototype.alloc = function() {
|
||||||
this.program.clear();
|
|
||||||
var x, y;
|
var x, y;
|
||||||
|
|
||||||
this.lines = [];
|
this.lines = [];
|
||||||
for (y = 0; y < this.rows; y++) {
|
for (y = 0; y < this.rows; y++) {
|
||||||
this.lines[y] = [];
|
this.lines[y] = [];
|
||||||
for (x = 0; x < this.cols; x++) {
|
for (x = 0; x < this.cols; x++) {
|
||||||
this.lines[y][x] = [this.dattr, ' '];
|
this.lines[y][x] = [this.dattr, ' '];
|
||||||
}
|
}
|
||||||
this.lines[y].dirty = true;
|
this.lines[y].dirty = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.olines = [];
|
this.olines = [];
|
||||||
for (y = 0; y < this.rows; y++) {
|
for (y = 0; y < this.rows; y++) {
|
||||||
this.olines[y] = [];
|
this.olines[y] = [];
|
||||||
@ -551,6 +552,8 @@ Screen.prototype.alloc = function() {
|
|||||||
this.olines[y][x] = [this.dattr, ' '];
|
this.olines[y][x] = [this.dattr, ' '];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.program.clear();
|
||||||
};
|
};
|
||||||
|
|
||||||
Screen.prototype.render = function() {
|
Screen.prototype.render = function() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user