Code development platform for open source projects from the European Union institutions :large_blue_circle: EU Login authentication by SMS has been phased out. To see alternatives please check here

Skip to content
Snippets Groups Projects
Commit e66fb7f5 authored by Jérôme Gorin's avatar Jérôme Gorin
Browse files

Fix debug browser button

parent 1c3f36be
Branches
Tags
No related merge requests found
......@@ -13,6 +13,7 @@ export class BrowserSession {
_collector: BrowserCollector;
_session_name: string;
_mainWindow: BrowserWindow;
_devtools: BrowserWindow | null;
constructor(mainWindow: BrowserWindow, session_name: string, settings) {
this._collector = new BrowserCollector(session_name, settings);
......@@ -248,7 +249,16 @@ export class BrowserSession {
}
toogleDevTool() {
this.contents.toggleDevTools();
if (this._devtools == null) {
this._devtools = new BrowserWindow();
this.contents.setDevToolsWebContents(this._devtools.webContents);
this.contents.openDevTools({ mode: 'detach' })
} else {
this._devtools.close();
this._devtools = null;
this.contents.closeDevTools();
}
}
async collect(kinds) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment