move saving play queue to window close intercept instead of app exit in case we crash during exit tasks
This commit is contained in:
@@ -140,6 +140,7 @@ func NewMainWindow(fyneApp fyne.App, appName, displayAppName, appVersion string,
|
||||
m.Window.SetContent(fynetooltip.AddWindowToolTipLayer(m.container, m.Window.Canvas()))
|
||||
m.setInitialSize()
|
||||
m.Window.SetCloseIntercept(func() {
|
||||
app.SavePlayQueueIfEnabled()
|
||||
m.SaveWindowSize()
|
||||
if app.Config.Application.CloseToSystemTray && m.HaveSystemTray() {
|
||||
m.Window.Hide()
|
||||
|
||||
Reference in New Issue
Block a user