ask for confirmation before updating (fixes #1386)

This commit is contained in:
Eugene Pankov 2019-08-29 14:11:30 +02:00
parent bcaa638ef0
commit 6968dcdd13

View File

@ -217,9 +217,19 @@ export class AppRootComponent {
return false return false
} }
updateApp () { async updateApp () {
if ((await this.electron.showMessageBox(
this.hostApp.getWindow(),
{
type: 'warning',
message: 'Installing the update will close all tabs and restart Terminus.',
buttons: ['Cancel', 'Update'],
defaultId: 1,
}
)).response === 1) {
this.updater.update() this.updater.update()
} }
}
onTabDragStart () { onTabDragStart () {
this.tabsDragging = true this.tabsDragging = true