mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-16 11:02:11 +08:00
github-electron: Add addWorkSpace() and removeWorkSpace to WebContents
This commit is contained in:
@@ -65,6 +65,8 @@ app.on('ready', () => {
|
||||
mainWindow.webContents.toggleDevTools();
|
||||
mainWindow.webContents.openDevTools({detach: true});
|
||||
mainWindow.webContents.closeDevTools();
|
||||
mainWindow.webContents.addWorkSpace('/path/to/workspace');
|
||||
mainWindow.webContents.removeWorkSpace('/path/to/workspace');
|
||||
var opened: boolean = mainWindow.webContents.isDevToolsOpened()
|
||||
// Emitted when the window is closed.
|
||||
mainWindow.on('closed', () => {
|
||||
|
||||
8
github-electron/github-electron.d.ts
vendored
8
github-electron/github-electron.d.ts
vendored
@@ -710,6 +710,14 @@ declare module GitHubElectron {
|
||||
* data Buffer - PDF file content
|
||||
*/
|
||||
callback: (error: Error, data: Buffer) => void): void;
|
||||
/**
|
||||
* Adds the specified path to DevTools workspace.
|
||||
*/
|
||||
addWorkSpace(path: string): void;
|
||||
/**
|
||||
* Removes the specified path from DevTools workspace.
|
||||
*/
|
||||
removeWorkSpace(path: string): void;
|
||||
/**
|
||||
* Opens the developer tools.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user