diff --git a/main/ipc.js b/main/ipc.js
index a61da263..7c03cad2 100644
--- a/main/ipc.js
+++ b/main/ipc.js
@@ -45,7 +45,7 @@ function addTorrentFromPaste () {
function setBounds (bounds) {
debug('setBounds %o', bounds)
- if (windows.main) {
+ if (windows.main && !windows.main.isFullScreen()) {
windows.main.setBounds(bounds, true)
}
}
diff --git a/renderer/views/app.js b/renderer/views/app.js
index 56c93bb3..ae9aa38f 100644
--- a/renderer/views/app.js
+++ b/renderer/views/app.js
@@ -8,7 +8,23 @@ var Header = require('./header')
var Player = require('./player')
var TorrentList = require('./torrent-list')
+var isOSX = process.platform === 'darwin'
+
function App (state, dispatch) {
+ return hx`
+
+ ${getHeader()}
+
${getView()}
+
+ `
+
+ function getHeader () {
+ // Hide the header on Windows/Linux when in the player
+ if (isOSX || state.url !== '/player') {
+ return Header(state, dispatch)
+ }
+ }
+
function getView () {
if (state.url === '/') {
return TorrentList(state, dispatch)
@@ -16,18 +32,4 @@ function App (state, dispatch) {
return Player(state, dispatch)
}
}
-
- // Show the header only when we're outside of fullscreen
- // Also don't show it in the video player except in OSX
- var isOSX = process.platform === 'darwin'
- var isVideo = state.url === '/player'
- var isFullScreen = state.isFullScreen
- var header = !isFullScreen && (!isVideo || isOSX) ? Header(state, dispatch) : null
-
- return hx`
-
- ${header}
-
${getView()}
-
- `
}