mirror of
https://github.com/Foundry376/Mailspring.git
synced 2024-09-22 00:06:06 +08:00
fix(fullscreen): Restore fullscreen if app was closed in fullscreen
Fixes #671
This commit is contained in:
parent
a03e8f704b
commit
48ea9e6198
|
@ -575,7 +575,8 @@ class NylasEnvConstructor extends Model
|
|||
browserWindow = @getCurrentWindow()
|
||||
{x, y, width, height} = browserWindow.getBounds()
|
||||
maximized = browserWindow.isMaximized()
|
||||
{x, y, width, height, maximized}
|
||||
fullScreen = browserWindow.isFullScreen()
|
||||
{x, y, width, height, maximized, fullScreen}
|
||||
|
||||
# Set the dimensions of the window.
|
||||
#
|
||||
|
@ -627,6 +628,7 @@ class NylasEnvConstructor extends Model
|
|||
dimensions = @getDefaultWindowDimensions()
|
||||
@setWindowDimensions(dimensions)
|
||||
@maximize() if dimensions.maximized and process.platform isnt 'darwin'
|
||||
@setFullScreen(true) if dimensions.fullScreen
|
||||
|
||||
storeWindowDimensions: ->
|
||||
dimensions = @getWindowDimensions()
|
||||
|
|
Loading…
Reference in a new issue