diff --git a/scripts/vscode.patch b/scripts/vscode.patch index 967c3d14..8e89e69e 100644 --- a/scripts/vscode.patch +++ b/scripts/vscode.patch @@ -827,7 +827,7 @@ index 780147c..2e8c9af 100644 - if (platform.isMacintosh) { + if (browser.isMacintosh) { diff --git a/src/vs/workbench/contrib/webview/electron-browser/webview-pre.js b/src/vs/workbench/contrib/webview/electron-browser/webview-pre.js -index 74fc798..03728d0 100644 +index 74fc798..0b6b5eb 100644 --- a/src/vs/workbench/contrib/webview/electron-browser/webview-pre.js +++ b/src/vs/workbench/contrib/webview/electron-browser/webview-pre.js @@ -10 +10,19 @@ @@ -866,6 +866,11 @@ index 74fc798..03728d0 100644 + // supportFetchAPI: true, + // corsEnabled: true + // }); +@@ -328 +346,3 @@ +- newFrame.contentWindow.focus(); ++ if (document.hasFocus()) { ++ newFrame.contentWindow.focus(); ++ } diff --git a/src/vs/workbench/contrib/webview/electron-browser/webview.contribution.ts b/src/vs/workbench/contrib/webview/electron-browser/webview.contribution.ts index 484ff86..f3f57cb 100644 --- a/src/vs/workbench/contrib/webview/electron-browser/webview.contribution.ts