make IWindowIndicator.onDidChange optional. FIxes #128109

This commit is contained in:
Martin Aeschlimann 2021-07-09 09:09:48 +02:00
parent ede06d01ec
commit b5a3dddea0
No known key found for this signature in database
GPG key ID: 2609A01E695523E3
2 changed files with 4 additions and 4 deletions

View file

@ -180,7 +180,7 @@ export class RemoteStatusIndicator extends Disposable implements IWorkbenchContr
// Update based on remote indicator changes if any // Update based on remote indicator changes if any
const remoteIndicator = this.environmentService.options?.windowIndicator; const remoteIndicator = this.environmentService.options?.windowIndicator;
if (remoteIndicator) { if (remoteIndicator && remoteIndicator.onDidChange) {
this._register(remoteIndicator.onDidChange(() => this.updateRemoteStatusIndicator())); this._register(remoteIndicator.onDidChange(() => this.updateRemoteStatusIndicator()));
} }

View file

@ -160,7 +160,7 @@ interface IWindowIndicator {
/** /**
* Triggering this event will cause the window indicator to update. * Triggering this event will cause the window indicator to update.
*/ */
onDidChange: Event<void>; readonly onDidChange?: Event<void>;
/** /**
* Label of the window indicator may include octicons * Label of the window indicator may include octicons
@ -192,12 +192,12 @@ interface IInitialColorTheme {
/** /**
* Initial color theme type. * Initial color theme type.
*/ */
themeType: ColorScheme; readonly themeType: ColorScheme;
/** /**
* A list of workbench colors to apply initially. * A list of workbench colors to apply initially.
*/ */
colors?: { [colorId: string]: string }; readonly colors?: { [colorId: string]: string };
} }
interface IDefaultView { interface IDefaultView {