Skip to content

Commit

Permalink
Up was misleading
Browse files Browse the repository at this point in the history
  • Loading branch information
jory committed Mar 3, 2015
1 parent ec15ea1 commit cc2a64f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ttyrec-decoder.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ TTYDecoder.prototype.eraseData = function (n) {
}
this.dirtyLines(1, this.y - 1);

this.clearUpToCursor();
this.clearLineToCursor();

} else if (n == 2) {
this.buffer = [[]];
Expand All @@ -192,7 +192,7 @@ TTYDecoder.prototype.eraseInLine = function (n) {
if (n == 0) {
this.clearToEndOfLine();
} else if (n == 1) {
this.clearUpToCursor();
this.clearLineToCursor();
} else if (n == 2) {
this.buffer[this.y - 1] = [];
this.dirtyLines(this.y);
Expand Down Expand Up @@ -604,7 +604,7 @@ TTYDecoder.prototype.clearToEndOfLine = function () {
this.dirtyInLine(this.x, WIDTH);
};

TTYDecoder.prototype.clearUpToCursor = function () {
TTYDecoder.prototype.clearLineToCursor = function () {
for (var i = 0, il = this.x; i < il; i++) {
this.buffer[this.y - 1][i] = undefined;
}
Expand Down

0 comments on commit cc2a64f

Please sign in to comment.