BufferService listen to onBufferActivate, remove tests

This commit is contained in:
Anthony Kim
2025-08-28 08:46:27 -07:00
parent 675b2c3a70
commit 753ea81fc0
5 changed files with 7 additions and 77 deletions
+4 -4
View File
@@ -29,6 +29,10 @@ export class MockBufferService implements IBufferService {
optionsService: IOptionsService = new MockOptionsService()
) {
this.buffers = new BufferSet(optionsService, this);
// Listen to buffer activation events and automatically fire scroll events
this.buffers.onBufferActivate(e => {
this._onScroll.fire(e.activeBuffer.ydisp);
});
}
public scrollPages(pageCount: number): void {
throw new Error('Method not implemented.');
@@ -48,10 +52,6 @@ export class MockBufferService implements IBufferService {
public scrollLines(disp: number, suppressScrollEvent?: boolean): void {
throw new Error('Method not implemented.');
}
public syncScrollPosition(): void {
// Fire scroll event with current buffer position
this._onScroll.fire(this.buffer.ydisp);
}
public resize(cols: number, rows: number): void {
this.cols = cols;
this.rows = rows;