diff options
author | Stefan Malzner <stefan@adlk.io> | 2019-03-12 14:04:13 +0100 |
---|---|---|
committer | Stefan Malzner <stefan@adlk.io> | 2019-03-12 14:04:13 +0100 |
commit | 9af01849f895230ae60a635c9756a5e206aa0fa1 (patch) | |
tree | b0b99f324c1a2e8c52e1fadf1152efac6d1028d2 /src/lib/Tray.js | |
parent | Bump version to 5.0.1-beta.1 (diff) | |
parent | Merge branch 'sergiughf-hotfix/update-electron' into develop (diff) | |
download | ferdium-app-9af01849f895230ae60a635c9756a5e206aa0fa1.tar.gz ferdium-app-9af01849f895230ae60a635c9756a5e206aa0fa1.tar.zst ferdium-app-9af01849f895230ae60a635c9756a5e206aa0fa1.zip |
Merge branch 'develop' into release/5.0.1-beta.1
Diffstat (limited to 'src/lib/Tray.js')
-rw-r--r-- | src/lib/Tray.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/Tray.js b/src/lib/Tray.js index 669b02709..192e24796 100644 --- a/src/lib/Tray.js +++ b/src/lib/Tray.js | |||
@@ -22,7 +22,11 @@ export default class TrayIcon { | |||
22 | { | 22 | { |
23 | label: 'Show Franz', | 23 | label: 'Show Franz', |
24 | click() { | 24 | click() { |
25 | if (app.mainWindow.isMinimized()) { | ||
26 | app.mainWindow.restore(); | ||
27 | } | ||
25 | app.mainWindow.show(); | 28 | app.mainWindow.show(); |
29 | app.mainWindow.focus(); | ||
26 | }, | 30 | }, |
27 | }, { | 31 | }, { |
28 | label: 'Quit Franz', | 32 | label: 'Quit Franz', |
@@ -36,7 +40,11 @@ export default class TrayIcon { | |||
36 | this.trayIcon.setContextMenu(trayMenu); | 40 | this.trayIcon.setContextMenu(trayMenu); |
37 | 41 | ||
38 | this.trayIcon.on('click', () => { | 42 | this.trayIcon.on('click', () => { |
43 | if (app.mainWindow.isMinimized()) { | ||
44 | app.mainWindow.restore(); | ||
45 | } | ||
39 | app.mainWindow.show(); | 46 | app.mainWindow.show(); |
47 | app.mainWindow.focus(); | ||
40 | }); | 48 | }); |
41 | 49 | ||
42 | if (process.platform === 'darwin') { | 50 | if (process.platform === 'darwin') { |