aboutsummaryrefslogtreecommitdiffstats
path: root/src/stores
diff options
context:
space:
mode:
authorLibravatar vantezzen <properly@protonmail.com>2019-09-14 13:47:49 +0200
committerLibravatar vantezzen <properly@protonmail.com>2019-09-14 13:47:49 +0200
commite9746cbfe618193ab580836643812e601ac4295a (patch)
treec0bbf8d14c7ffc86c71405129e0819f9f65dcdeb /src/stores
parentdocs: add dayzlun as a contributor (#34) (diff)
downloadferdium-app-e9746cbfe618193ab580836643812e601ac4295a.tar.gz
ferdium-app-e9746cbfe618193ab580836643812e601ac4295a.tar.zst
ferdium-app-e9746cbfe618193ab580836643812e601ac4295a.zip
Implement #7
Diffstat (limited to 'src/stores')
-rw-r--r--src/stores/SettingsStore.js11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/stores/SettingsStore.js b/src/stores/SettingsStore.js
index 6c7b586a5..2975499b3 100644
--- a/src/stores/SettingsStore.js
+++ b/src/stores/SettingsStore.js
@@ -1,6 +1,6 @@
1import { ipcRenderer } from 'electron'; 1import { ipcRenderer, remote } from 'electron';
2import { 2import {
3 action, computed, observable, set, 3 action, computed, observable, set, reaction,
4} from 'mobx'; 4} from 'mobx';
5import localStorage from 'mobx-localstorage'; 5import localStorage from 'mobx-localstorage';
6 6
@@ -55,6 +55,13 @@ export default class SettingsStore extends Store {
55 // We need to wait until `appSettingsRequest` has been executed once, otherwise we can't patch the result. If we don't wait we'd run into an issue with mobx not reacting to changes of previously not existing keys 55 // We need to wait until `appSettingsRequest` has been executed once, otherwise we can't patch the result. If we don't wait we'd run into an issue with mobx not reacting to changes of previously not existing keys
56 await this.appSettingsRequest._promise; 56 await this.appSettingsRequest._promise;
57 await this._migrate(); 57 await this._migrate();
58
59 reaction(
60 () => this.all.app.autohideMenuBar,
61 () => remote.getCurrentWindow().setAutoHideMenuBar(
62 this.all.app.autohideMenuBar,
63 ),
64 );
58 } 65 }
59 66
60 @computed get app() { 67 @computed get app() {