0
필자는 창을 만들 때 창 너비와 높이를 설정했지만 이제는 ipc를 호출 할 때 동일한 창 너비와 높이를 변경하려고합니다. 주요 프로세스. 는 여기가 IPC 방법전자의 현재 창 너비와 높이를 설정하는 방법
ipcMain.on('userRegLinkClicked', (event, data) => {
win.setSize({
width: 448,
height: 850
})
}
를 호출하고 지금 내 코드
function createWindow() {
win = new BrowserWindow({
width: 448, // here I have set the width and height
height: 650,
frame: false,
transparent: true,
minimizable: true,
maximizable: true,
closable: true,
})
win.loadURL(url.format({
pathname: path.join(__dirname, './view/loginWindow.html'),
protocol: 'file:',
slashes: true
}))
.....
....
입니다 그러나 아무것도 대신 작동하지 않습니다 내가 옵션을 고려하지 않습니다 TypeError: Error processing argument at index 0, conversion failure from #<Object>