Skip to content

Commit

Permalink
feat: Add OK button to update message box
Browse files Browse the repository at this point in the history
  • Loading branch information
ashchan committed Aug 1, 2019
1 parent 73bd7af commit 9cba232
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/neuron-wallet/src/controllers/update.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,19 @@ autoUpdater.on('update-available', () => {

autoUpdater.on('update-not-available', () => {
dialog.showMessageBox({
type: 'info',
message: i18n.t('updater.update-not-available'),
buttons: [i18n.t('common.ok')],
})
enableUpdaterMenuItem()
})

autoUpdater.on('update-downloaded', () => {
dialog.showMessageBox(
{
type: 'info',
message: i18n.t('updater.updates-downloaded-about-to-quit-and-install'),
buttons: [i18n.t('common.ok')],
},
() => {
setImmediate(() => autoUpdater.quitAndInstall())
Expand Down
1 change: 1 addition & 0 deletions packages/neuron-wallet/src/locales/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ export default {
common: {
yes: 'Yes',
no: 'No',
ok: 'OK',
},
},
}
1 change: 1 addition & 0 deletions packages/neuron-wallet/src/locales/zh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ export default {
common: {
yes: '是',
no: '否',
ok: '确定',
},
},
}

0 comments on commit 9cba232

Please sign in to comment.