Remove ScrollSource

This isn't used anymore, it was used earlier to workaround recursion between
the viewport and the terminal objects
This commit is contained in:
Daniel Imms
2024-07-10 07:01:44 -07:00
parent c2b90c6dae
commit 416f12fcc3
7 changed files with 23 additions and 31 deletions
+2 -2
View File
@@ -5,7 +5,7 @@
import { EventEmitter } from 'common/EventEmitter';
import { Disposable } from 'common/Lifecycle';
import { IAttributeData, IBufferLine, ScrollSource } from 'common/Types';
import { IAttributeData, IBufferLine } from 'common/Types';
import { BufferSet } from 'common/buffer/BufferSet';
import { IBuffer, IBufferSet } from 'common/buffer/Types';
import { IBufferService, IOptionsService } from 'common/services/Services';
@@ -125,7 +125,7 @@ export class BufferService extends Disposable implements IBufferService {
* to avoid unwanted events being handled by the viewport when the event was triggered from the
* viewport originally.
*/
public scrollLines(disp: number, suppressScrollEvent?: boolean, source?: ScrollSource): void {
public scrollLines(disp: number, suppressScrollEvent?: boolean): void {
const buffer = this.buffer;
if (disp < 0) {
if (buffer.ydisp === 0) {
+3 -3
View File
@@ -3,11 +3,11 @@
* @license MIT
*/
import { IDecoration, IDecorationOptions, ILinkHandler, ILogger, IWindowsPty } from '@xterm/xterm';
import { IEvent, IEventEmitter } from 'common/EventEmitter';
import { CoreMouseEncoding, CoreMouseEventType, CursorInactiveStyle, CursorStyle, IAttributeData, ICharset, IColor, ICoreMouseEvent, ICoreMouseProtocol, IDecPrivateModes, IDisposable, IModes, IOscLinkData, IWindowOptions } from 'common/Types';
import { IBuffer, IBufferSet } from 'common/buffer/Types';
import { IDecPrivateModes, ICoreMouseEvent, CoreMouseEncoding, ICoreMouseProtocol, CoreMouseEventType, ICharset, IWindowOptions, IModes, IAttributeData, ScrollSource, IDisposable, IColor, CursorStyle, CursorInactiveStyle, IOscLinkData } from 'common/Types';
import { createDecorator } from 'common/services/ServiceRegistry';
import { IDecorationOptions, IDecoration, ILinkHandler, IWindowsPty, ILogger } from '@xterm/xterm';
export const IBufferService = createDecorator<IBufferService>('BufferService');
export interface IBufferService {
@@ -21,7 +21,7 @@ export interface IBufferService {
onResize: IEvent<{ cols: number, rows: number }>;
onScroll: IEvent<number>;
scroll(eraseAttr: IAttributeData, isWrapped?: boolean): void;
scrollLines(disp: number, suppressScrollEvent?: boolean, source?: ScrollSource): void;
scrollLines(disp: number, suppressScrollEvent?: boolean): void;
resize(cols: number, rows: number): void;
reset(): void;
}