Remove mouseEvents from Terminal
Depend on CoreMouseService directly
This commit is contained in:
@@ -31,6 +31,7 @@ export class MockBufferService implements IBufferService {
|
||||
}
|
||||
|
||||
export class MockCoreMouseService implements ICoreMouseService {
|
||||
public areMouseEventsActive: boolean = false;
|
||||
public activeEncoding: string = '';
|
||||
public activeProtocol: string = '';
|
||||
public addEncoding(name: string): void {}
|
||||
|
||||
@@ -192,6 +192,10 @@ export class CoreMouseService implements ICoreMouseService {
|
||||
return this._activeProtocol;
|
||||
}
|
||||
|
||||
public get areMouseEventsActive(): boolean {
|
||||
return this._protocols[this._activeProtocol].events !== 0;
|
||||
}
|
||||
|
||||
public set activeProtocol(name: string) {
|
||||
if (!this._protocols[name]) {
|
||||
throw new Error(`unknown protocol "${name}"`);
|
||||
|
||||
@@ -27,6 +27,7 @@ export const ICoreMouseService = createDecorator<ICoreMouseService>('CoreMouseSe
|
||||
export interface ICoreMouseService {
|
||||
activeProtocol: string;
|
||||
activeEncoding: string;
|
||||
areMouseEventsActive: boolean;
|
||||
addProtocol(name: string, protocol: ICoreMouseProtocol): void;
|
||||
addEncoding(name: string, encoding: CoreMouseEncoding): void;
|
||||
reset(): void;
|
||||
|
||||
Reference in New Issue
Block a user