mirror of
https://github.com/AltarikMC/Launcher
synced 2024-11-25 06:49:51 +01:00
Removed dialog when update downloaded
This commit is contained in:
parent
0001b54e15
commit
03a4e345d1
@ -31,20 +31,9 @@ class Updater {
|
|||||||
|
|
||||||
// TODO : replace dialog by automatic restart
|
// TODO : replace dialog by automatic restart
|
||||||
this.autoUpdater.on('update-downloaded', (_event, releaseNotes, releaseName) => {
|
this.autoUpdater.on('update-downloaded', (_event, releaseNotes, releaseName) => {
|
||||||
const dialogOpts = {
|
this.logger.info(`update downloaded ${releaseName}`)
|
||||||
type: 'info',
|
this.logger.info("Leaving application to install update...")
|
||||||
buttons: ['Rédémarrer', 'Plus tard'],
|
this.autoUpdater.quitAndInstall()
|
||||||
title: 'Une mise à jour du launcher est disponible',
|
|
||||||
message: process.platform === 'win32' ? releaseNotes : releaseName,
|
|
||||||
detail: 'Une nouvelle version du launcher a été téléchargé. Redémarrez l\'application pour appliquer les mises à jour.'
|
|
||||||
}
|
|
||||||
|
|
||||||
this.dialog.showMessageBox(dialogOpts).then((returnValue) => {
|
|
||||||
if (returnValue.response === 0) {
|
|
||||||
this.logger.info("Leaving application to install update...")
|
|
||||||
this.autoUpdater.quitAndInstall()
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user