aboutsummaryrefslogtreecommitdiffstats
path: root/src/stores
diff options
context:
space:
mode:
authorLibravatar Amine Mouafik <amine@mouafik.fr>2020-03-11 04:36:02 +0100
committerLibravatar Amine Mouafik <amine@mouafik.fr>2020-03-11 04:36:02 +0100
commit063875d7395438ba6566327e0f26c7cda5fe5ba8 (patch)
tree7fff0347843a0376f7aee07eb34260c28c40808f /src/stores
parentMerge branch 'develop' (diff)
parent5.4.4-beta.3 (diff)
downloadferdium-app-063875d7395438ba6566327e0f26c7cda5fe5ba8.tar.gz
ferdium-app-063875d7395438ba6566327e0f26c7cda5fe5ba8.tar.zst
ferdium-app-063875d7395438ba6566327e0f26c7cda5fe5ba8.zip
Merge branch 'develop'
Diffstat (limited to 'src/stores')
-rw-r--r--src/stores/AppStore.js2
-rw-r--r--src/stores/ServicesStore.js2
-rw-r--r--src/stores/SettingsStore.js7
3 files changed, 7 insertions, 4 deletions
diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js
index 36e6efd4f..593bf341e 100644
--- a/src/stores/AppStore.js
+++ b/src/stores/AppStore.js
@@ -202,7 +202,7 @@ export default class AppStore extends Store {
202 powerMonitor.on('resume', () => { 202 powerMonitor.on('resume', () => {
203 debug('System resumed, last suspended on', this.timeSuspensionStart.toString()); 203 debug('System resumed, last suspended on', this.timeSuspensionStart.toString());
204 204
205 if (this.timeSuspensionStart.add(10, 'm').isBefore(moment())) { 205 if (this.timeSuspensionStart.add(10, 'm').isBefore(moment()) && this.stores.settings.app.get('reloadAfterResume')) {
206 debug('Reloading services, user info and features'); 206 debug('Reloading services, user info and features');
207 207
208 setTimeout(() => { 208 setTimeout(() => {
diff --git a/src/stores/ServicesStore.js b/src/stores/ServicesStore.js
index ae6ba11c5..985887d2d 100644
--- a/src/stores/ServicesStore.js
+++ b/src/stores/ServicesStore.js
@@ -766,7 +766,7 @@ export default class ServicesStore extends Store {
766 const isMuted = isAppMuted || service.isMuted; 766 const isMuted = isAppMuted || service.isMuted;
767 767
768 if (isAttached) { 768 if (isAttached) {
769 service.webview.audioMuted = isMuted; 769 service.webview.setAudioMuted(isMuted);
770 } 770 }
771 }); 771 });
772 } 772 }
diff --git a/src/stores/SettingsStore.js b/src/stores/SettingsStore.js
index 26e83b725..71d4e1702 100644
--- a/src/stores/SettingsStore.js
+++ b/src/stores/SettingsStore.js
@@ -1,5 +1,7 @@
1import { ipcRenderer, remote } from 'electron'; 1import { ipcRenderer, remote } from 'electron';
2import { action, computed, observable, reaction } from 'mobx'; 2import {
3 action, computed, observable, reaction,
4} from 'mobx';
3import localStorage from 'mobx-localstorage'; 5import localStorage from 'mobx-localstorage';
4import { DEFAULT_APP_SETTINGS, FILE_SYSTEM_SETTINGS_TYPES, LOCAL_SERVER } from '../config'; 6import { DEFAULT_APP_SETTINGS, FILE_SYSTEM_SETTINGS_TYPES, LOCAL_SERVER } from '../config';
5import { API } from '../environment'; 7import { API } from '../environment';
@@ -12,6 +14,7 @@ const debug = require('debug')('Ferdi:SettingsStore');
12 14
13export default class SettingsStore extends Store { 15export default class SettingsStore extends Store {
14 @observable updateAppSettingsRequest = new Request(this.api.local, 'updateAppSettings'); 16 @observable updateAppSettingsRequest = new Request(this.api.local, 'updateAppSettings');
17
15 startup = true; 18 startup = true;
16 19
17 fileSystemSettingsTypes = FILE_SYSTEM_SETTINGS_TYPES; 20 fileSystemSettingsTypes = FILE_SYSTEM_SETTINGS_TYPES;
@@ -103,7 +106,7 @@ export default class SettingsStore extends Store {
103 // So we lock manually 106 // So we lock manually
104 window.ferdi.stores.router.push('/auth/locked'); 107 window.ferdi.stores.router.push('/auth/locked');
105 } 108 }
106 }) 109 });
107 } 110 }
108 debug('Get appSettings resolves', resp.type, resp.data); 111 debug('Get appSettings resolves', resp.type, resp.data);
109 Object.assign(this._fileSystemSettingsCache[resp.type], resp.data); 112 Object.assign(this._fileSystemSettingsCache[resp.type], resp.data);