提交 92514c46 编写于 作者: M Matt Bierner

Fix a few more issues related to #81574

上级 30120e4d
......@@ -102,7 +102,7 @@ export class EditorGroup extends Disposable {
private focusRecentEditorAfterClose: boolean | undefined;
constructor(
labelOrSerializedGroup: ISerializedEditorGroup,
labelOrSerializedGroup: ISerializedEditorGroup | undefined,
@IInstantiationService private readonly instantiationService: IInstantiationService,
@IConfigurationService private readonly configurationService: IConfigurationService
) {
......
......@@ -71,7 +71,11 @@ export class FeedbackStatusbarConribution extends Disposable implements IWorkben
if (!this.dropdown) {
const statusContainr = document.getElementById('status.feedback');
if (statusContainr) {
this.dropdown = this._register(this.instantiationService.createInstance(FeedbackDropdown, statusContainr.getElementsByClassName('octicon').item(0), {
const icon = statusContainr.getElementsByClassName('octicon').item(0) as HTMLElement | null;
if (!icon) {
throw new Error('Could not find icon');
}
this.dropdown = this._register(this.instantiationService.createInstance(FeedbackDropdown, icon, {
contextViewProvider: this.contextViewService,
feedbackService: this.instantiationService.createInstance(TwitterFeedbackService),
onFeedbackVisibilityChange: visible => this.entry!.update(this.getStatusEntry(visible))
......
......@@ -8,7 +8,7 @@ import { IDisposable, toDisposable, UnownedDisposable } from 'vs/base/common/lif
import { values } from 'vs/base/common/map';
import { URI } from 'vs/base/common/uri';
import { ExtensionIdentifier } from 'vs/platform/extensions/common/extensions';
import { createDecorator, IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
import { createDecorator } from 'vs/platform/instantiation/common/instantiation';
import { GroupIdentifier } from 'vs/workbench/common/editor';
import { IWebviewService, WebviewOptions, WebviewContentOptions } from 'vs/workbench/contrib/webview/browser/webview';
import { IEditorGroup, IEditorGroupsService } from 'vs/workbench/services/editor/common/editorGroupsService';
......@@ -131,7 +131,6 @@ export class WebviewEditorService implements IWebviewEditorService {
constructor(
@IEditorService private readonly _editorService: IEditorService,
@IInstantiationService private readonly _instantiationService: IInstantiationService,
@IEditorGroupsService private readonly _editorGroupService: IEditorGroupsService,
@IWebviewService private readonly _webviewService: IWebviewService,
@IWorkspaceContextService private readonly _contextService: IWorkspaceContextService,
......@@ -150,7 +149,7 @@ export class WebviewEditorService implements IWebviewEditorService {
): WebviewInput {
const webview = this.createWebiew(id, extension, options);
const webviewInput = this._instantiationService.createInstance(WebviewInput, id, viewType, title, new UnownedDisposable(webview), undefined);
const webviewInput = new WebviewInput(id, viewType, title, new UnownedDisposable(webview));
this._editorService.openEditor(webviewInput, {
pinned: true,
preserveFocus: showOptions.preserveFocus,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册