aboutsummaryrefslogtreecommitdiffstats
path: root/src/stores
diff options
context:
space:
mode:
authorLibravatar Stefan Malzner <stefan@adlk.io>2018-02-19 10:50:44 +0100
committerLibravatar GitHub <noreply@github.com>2018-02-19 10:50:44 +0100
commit3426e5d43fcb5f6272670563a9d9aebee8fbbd9c (patch)
tree12b7457f39d7fdb88a46d5e93502f34f74b9b42e /src/stores
parentreadd @2x icons (diff)
parentRestore windows behavior for notifications and add linux support (diff)
downloadferdium-app-3426e5d43fcb5f6272670563a9d9aebee8fbbd9c.tar.gz
ferdium-app-3426e5d43fcb5f6272670563a9d9aebee8fbbd9c.tar.zst
ferdium-app-3426e5d43fcb5f6272670563a9d9aebee8fbbd9c.zip
fix(Linux): Fix window restore on notification click (@closingin)
Correctly restore window when clicking on a notification
Diffstat (limited to 'src/stores')
-rw-r--r--src/stores/AppStore.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js
index 9b59f01d2..162422017 100644
--- a/src/stores/AppStore.js
+++ b/src/stores/AppStore.js
@@ -9,7 +9,7 @@ import prettyBytes from 'pretty-bytes';
9import Store from './lib/Store'; 9import Store from './lib/Store';
10import Request from './lib/Request'; 10import Request from './lib/Request';
11import { CHECK_INTERVAL, DEFAULT_APP_SETTINGS } from '../config'; 11import { CHECK_INTERVAL, DEFAULT_APP_SETTINGS } from '../config';
12import { isMac } from '../environment'; 12import { isMac, isLinux, isWindows } from '../environment';
13import locales from '../i18n/translations'; 13import locales from '../i18n/translations';
14import { gaEvent } from '../lib/analytics'; 14import { gaEvent } from '../lib/analytics';
15 15
@@ -179,9 +179,12 @@ export default class AppStore extends Store {
179 179
180 this.actions.service.setActive({ serviceId }); 180 this.actions.service.setActive({ serviceId });
181 181
182 if (!isMac) { 182 const mainWindow = remote.getCurrentWindow();
183 const mainWindow = remote.getCurrentWindow(); 183
184 if (isWindows) {
184 mainWindow.restore(); 185 mainWindow.restore();
186 } else if (isLinux) {
187 mainWindow.show();
185 } 188 }
186 } 189 }
187 }; 190 };