We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ae61c96 commit 2da301eCopy full SHA for 2da301e
src/main/labview/labview.ts
@@ -6,7 +6,8 @@ import {
6
clipboard,
7
dialog,
8
Menu,
9
- MenuItemConstructorOptions
+ MenuItemConstructorOptions,
10
+ shell
11
} from 'electron';
12
import log from 'electron-log';
13
import * as path from 'path';
@@ -63,6 +64,12 @@ export class LabView implements IDisposable {
63
64
}
65
});
66
67
+ // Open external links in system browser
68
+ this._view.webContents.setWindowOpenHandler(({ url }) => {
69
+ shell.openExternal(url);
70
+ return { action: 'deny' };
71
+ });
72
+
73
this._view.setBackgroundColor(
74
options.isDarkTheme ? DarkThemeBGColor : LightThemeBGColor
75
);
0 commit comments