Center video on current screen (#427)

Fixes #404
This commit is contained in:
DC
2016-04-22 19:59:17 -07:00
committed by Feross Aboukhadijeh
parent 9a1c329434
commit 6b70554e63
2 changed files with 9 additions and 5 deletions

View File

@@ -1054,12 +1054,8 @@ function setDimensions (dimensions) {
config.WINDOW_MIN_HEIGHT
)
// Center window on screen
var x = Math.floor((screenWidth - width) / 2)
var y = Math.floor((screenHeight - height) / 2)
ipcRenderer.send('setAspectRatio', aspectRatio)
ipcRenderer.send('setBounds', {x, y, width, height})
ipcRenderer.send('setBounds', {x: null, y: null, width, height})
}
function restoreBounds () {