Deskop: Fix deprecation of getName() in Electron (#2367)

This change fixes the following deprecation:
(electron) 'getName function' is deprecated and will be removed. Please use 'name property' instead.
pull/2376/head
Helmut K. C. Tessarek 2020-01-26 12:32:00 -05:00 committed by Laurent Cozic
parent 5881cee167
commit 0bb1484b2d
2 changed files with 2 additions and 2 deletions

View File

@ -187,7 +187,7 @@ class ElectronAppWrapper {
createTray(contextMenu) {
try {
this.tray_ = new Tray(`${this.buildDir()}/icons/${this.trayIconFilename_()}`);
this.tray_.setToolTip(this.electronApp_.getName());
this.tray_.setToolTip(this.electronApp_.name);
this.tray_.setContextMenu(contextMenu);
this.tray_.on('click', () => {

View File

@ -1150,7 +1150,7 @@ class Application extends BaseApplication {
app.destroyTray();
} else {
const contextMenu = Menu.buildFromTemplate([
{ label: _('Open %s', app.electronApp().getName()), click: () => { app.window().show(); } },
{ label: _('Open %s', app.electronApp().name), click: () => { app.window().show(); } },
{ type: 'separator' },
{ label: _('Exit'), click: () => { app.quit(); } },
]);