Resize app when second projector connected
This commit is contained in:
parent
c964410f7b
commit
6622a72241
14
app/main.js
14
app/main.js
|
@ -346,16 +346,24 @@ dev.remember = function (which, device, type) {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
dev.ready = function (projector, camera, light) {
|
dev.ready = function (projector, camera, light, projector_second) {
|
||||||
mainWindow.webContents.send('ready', {
|
let args = {
|
||||||
camera,
|
camera,
|
||||||
projector,
|
projector,
|
||||||
light,
|
light,
|
||||||
profile: mcopy.settings.profile
|
profile: mcopy.settings.profile
|
||||||
})
|
}
|
||||||
|
if (projector_second && projector_second.arduino) {
|
||||||
|
args.projector_second = projector_second
|
||||||
|
}
|
||||||
|
mainWindow.webContents.send('ready', args)
|
||||||
settings.update('camera', camera)
|
settings.update('camera', camera)
|
||||||
settings.update('projector', projector)
|
settings.update('projector', projector)
|
||||||
settings.update('light', light)
|
settings.update('light', light)
|
||||||
|
if (projector_second && projector_second.arduino) {
|
||||||
|
settings.update('projector_second', projector_second)
|
||||||
|
mainWindow.setSize(800, 800)
|
||||||
|
}
|
||||||
settings.save()
|
settings.save()
|
||||||
return true
|
return true
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue