fix progressbar.

This commit is contained in:
Christopher Jeffrey 2013-06-07 07:12:53 -05:00
parent 8cca60beac
commit 48658c4cf9

View File

@ -1244,7 +1244,11 @@ ProgressBar.prototype.render = function(stop) {
var xi = ret.xi
, xl = ret.xl
, yi = ret.yi
, yl = ret.yl;
, yl = ret.yl
, cell
, ch
, x
, y;
var lines = this.screen.lines;
@ -1257,12 +1261,11 @@ ProgressBar.prototype.render = function(stop) {
for (y = yi; y < yl; y++) {
if (!lines[y]) break;
for (x = xi; x < xl; x++) {
attr = dattr;
ch = this.ch;
cell = lines[y][x];
if (!cell) break;
if (attr !== cell[0] || ch !== cell[1]) {
lines[y][x][0] = attr;
if (dattr !== cell[0] || ch !== cell[1]) {
lines[y][x][0] = dattr;
lines[y][x][1] = ch;
lines[y].dirty = true;
}