minor change to alloc.

This commit is contained in:
Christopher Jeffrey 2013-07-14 12:21:14 -05:00
parent caa21ee356
commit 4541fc5c50
1 changed files with 5 additions and 2 deletions

View File

@ -534,16 +534,17 @@ Screen.prototype.__defineGetter__('height', function() {
});
Screen.prototype.alloc = function() {
this.program.clear();
var x, y;
this.lines = [];
for (y = 0; y < this.rows; y++) {
this.lines[y] = [];
for (x = 0; x < this.cols; x++) {
this.lines[y][x] = [this.dattr, ' '];
}
this.lines[y].dirty = true;
this.lines[y].dirty = false;
}
this.olines = [];
for (y = 0; y < this.rows; y++) {
this.olines[y] = [];
@ -551,6 +552,8 @@ Screen.prototype.alloc = function() {
this.olines[y][x] = [this.dattr, ' '];
}
}
this.program.clear();
};
Screen.prototype.render = function() {