Skip to content

Commit d5c5c02

Browse files
author
Benjamin Pasero
committed
Reloading/restoring workbench with open webview throws exception (fix microsoft#100783)
1 parent 60d8579 commit d5c5c02

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

src/vs/workbench/browser/parts/editor/editorPart.ts

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ class GridWidgetView<T extends IView> implements IView {
8181
}
8282
}
8383

84-
export class EditorPart extends Part implements IEditorGroupsService, IEditorGroupsAccessor {
84+
export class EditorPart extends Part implements IEditorGroupsService, IEditorGroupsAccessor, IEditorDropService {
8585

8686
declare readonly _serviceBrand: undefined;
8787

@@ -1141,5 +1141,16 @@ export class EditorPart extends Part implements IEditorGroupsService, IEditorGro
11411141
//#endregion
11421142
}
11431143

1144+
class EditorDropService implements IEditorDropService {
1145+
1146+
declare readonly _serviceBrand: undefined;
1147+
1148+
constructor(@IEditorGroupsService private readonly editorPart: EditorPart) { }
1149+
1150+
createEditorDropTarget(container: HTMLElement, delegate: IEditorDropTargetDelegate): IDisposable {
1151+
return this.editorPart.createEditorDropTarget(container, delegate);
1152+
}
1153+
}
1154+
11441155
registerSingleton(IEditorGroupsService, EditorPart);
1145-
registerSingleton(IEditorDropService, EditorPart);
1156+
registerSingleton(IEditorDropService, EditorDropService);

0 commit comments

Comments
 (0)