Update src/common/InputHandler.ts
Co-authored-by: jerch <jerch@rockborn.de>
This commit is contained in:
@@ -1221,15 +1221,12 @@ export class InputHandler extends Disposable implements IInputHandler {
|
|||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
if (this._optionsService.rawOptions.scrollOnDisplayErase) {
|
if (this._optionsService.rawOptions.scrollOnDisplayErase) {
|
||||||
let fouldLastLineToKeep = false;
|
|
||||||
j = this._bufferService.rows;
|
j = this._bufferService.rows;
|
||||||
const x = this._activeBuffer.getBlankLine(this._eraseAttrData());
|
this._dirtyRowTracker.markRangeDirty(0, j - 1);
|
||||||
while (j > 0 && !fouldLastLineToKeep) {
|
while (j--) {
|
||||||
j--;
|
|
||||||
const currentLine = this._activeBuffer.lines.get(this._activeBuffer.ybase + j);
|
const currentLine = this._activeBuffer.lines.get(this._activeBuffer.ybase + j);
|
||||||
if (currentLine?.translateToString() !== x.translateToString()) {
|
if (currentLine?.getTrimmedLength()) {
|
||||||
fouldLastLineToKeep = true;
|
break;
|
||||||
this._dirtyRowTracker.markRangeDirty(0, j);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (; j >= 0; j--) {
|
for (; j >= 0; j--) {
|
||||||
|
|||||||
Reference in New Issue
Block a user