Merge branch 'master' into bg_decorations

This commit is contained in:
Daniel Imms
2022-05-10 11:50:01 -07:00
committed by GitHub
3 changed files with 20 additions and 17 deletions
+2
View File
@@ -32,6 +32,7 @@ export class DecorationService extends Disposable implements IDecorationService
}
const decoration = new Decoration(options);
if (decoration) {
const markerDispose = decoration.marker.onDispose(() => decoration.dispose());
decoration.onDispose(() => {
if (decoration) {
const index = this._decorations.indexOf(decoration);
@@ -39,6 +40,7 @@ export class DecorationService extends Disposable implements IDecorationService
this._decorations.splice(this._decorations.indexOf(decoration), 1);
this._onDecorationRemoved.fire(decoration);
}
markerDispose.dispose();
}
});
this._decorations.push(decoration);