This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { remote, screen, ipcRenderer } from 'electron'; | |
// … | |
customMaximize() | |
{ | |
// windows dimension and positon {width, height, x, y} | |
let resDetails = remote.getCurrentWindow().getBounds(); | |
// use ipcRender to send custom-resize event to main thread to invoke the custom resize event handler to resize the window…. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const {ipcMain} = require('electron'); | |
// to store the restore window screen width and height and position… | |
let restoreWindowSave; | |
//... | |
function createWindow () { | |
// Create the browser window logics. | |
let win = new BrowserWindow({ width: 800, height: 600 }); |
NewerOlder