Merge from vscode 8e0f348413f4f616c23a88ae30030efa85811973 (#6381)

* Merge from vscode 8e0f348413f4f616c23a88ae30030efa85811973

* disable strict null check
This commit is contained in:
Anthony Dresser
2019-07-15 22:35:46 -07:00
committed by GitHub
parent f720ec642f
commit 0b7e7ddbf9
2406 changed files with 59140 additions and 35464 deletions

View File

@@ -14,7 +14,7 @@ import { StartAction, ConfigureAction, SelectAndStartAction, FocusSessionAction
import { StartDebugActionViewItem, FocusSessionActionViewItem } from 'vs/workbench/contrib/debug/browser/debugActionViewItems';
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
import { IExtensionService } from 'vs/workbench/services/extensions/common/extensions';
import { IProgressService, IProgressRunner } from 'vs/platform/progress/common/progress';
import { IProgressService } from 'vs/platform/progress/common/progress';
import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace';
import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry';
import { IStorageService } from 'vs/platform/storage/common/storage';
@@ -37,10 +37,11 @@ import { IPanelService } from 'vs/workbench/services/panel/common/panelService';
export class DebugViewlet extends ViewContainerViewlet {
private startDebugActionViewItem: StartDebugActionViewItem;
private progressRunner: IProgressRunner;
private progressResolve: (() => void) | undefined;
private breakpointView: ViewletPanel;
private panelListeners = new Map<string, IDisposable>();
private debugToolBarMenu: IMenu;
private disposeOnTitleUpdate: IDisposable;
constructor(
@IWorkbenchLayoutService layoutService: IWorkbenchLayoutService,
@@ -112,9 +113,16 @@ export class DebugViewlet extends ViewContainerViewlet {
if (!this.debugToolBarMenu) {
this.debugToolBarMenu = this.menuService.createMenu(MenuId.DebugToolBar, this.contextKeyService);
this.toDispose.push(this.debugToolBarMenu);
this._register(this.debugToolBarMenu);
}
return DebugToolBar.getActions(this.debugToolBarMenu, this.debugService, this.instantiationService);
const { actions, disposable } = DebugToolBar.getActions(this.debugToolBarMenu, this.debugService, this.instantiationService);
if (this.disposeOnTitleUpdate) {
dispose(this.disposeOnTitleUpdate);
}
this.disposeOnTitleUpdate = disposable;
return actions;
}
get showInitialDebugActions(): boolean {
@@ -153,12 +161,15 @@ export class DebugViewlet extends ViewContainerViewlet {
}
private onDebugServiceStateChange(state: State): void {
if (this.progressRunner) {
this.progressRunner.done();
if (this.progressResolve) {
this.progressResolve();
this.progressResolve = undefined;
}
if (state === State.Initializing) {
this.progressRunner = this.progressService.show(true);
this.progressService.withProgress({ location: VIEWLET_ID }, _progress => {
return new Promise(resolve => this.progressResolve = resolve);
});
}
this.updateToolBar();