mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 04:49:35 +00:00
macOS: Process explorer not put to front if minimized (fix #137598)
This commit is contained in:
parent
23d5cb019d
commit
2c6630a5ce
|
@ -250,7 +250,9 @@ export class IssueMainService implements ICommonIssueService {
|
|||
}
|
||||
}
|
||||
|
||||
this.issueReporterWindow?.focus();
|
||||
if (this.issueReporterWindow) {
|
||||
this.focusWindow(this.issueReporterWindow);
|
||||
}
|
||||
}
|
||||
|
||||
async openProcessExplorer(data: ProcessExplorerData): Promise<void> {
|
||||
|
@ -298,7 +300,17 @@ export class IssueMainService implements ICommonIssueService {
|
|||
}
|
||||
}
|
||||
|
||||
this.processExplorerWindow?.focus();
|
||||
if (this.processExplorerWindow) {
|
||||
this.focusWindow(this.processExplorerWindow);
|
||||
}
|
||||
}
|
||||
|
||||
private focusWindow(window: BrowserWindow): void {
|
||||
if (window.isMinimized()) {
|
||||
window.restore();
|
||||
}
|
||||
|
||||
window.focus();
|
||||
}
|
||||
|
||||
private createBrowserWindow<T>(position: IWindowState, ipcObjectUrl: IIPCObjectUrl<T>, options: IBrowserWindowOptions, windowKind: string): BrowserWindow {
|
||||
|
|
Loading…
Reference in a new issue