aboutsummaryrefslogtreecommitdiffstats
path: root/packages/main/src/infrastructure/electron/impl/electronShell.ts
diff options
context:
space:
mode:
authorLibravatar Kristóf Marussy <kristof@marussy.com>2022-03-29 18:19:39 +0200
committerLibravatar Kristóf Marussy <kristof@marussy.com>2022-05-16 00:54:56 +0200
commita35d560f8d1ca414e3ba387b50731ca099e2da47 (patch)
tree5a8a90345c04eb0b69ea3fca8185641e26905b5d /packages/main/src/infrastructure/electron/impl/electronShell.ts
parentfeat: New window banner (diff)
downloadsophie-a35d560f8d1ca414e3ba387b50731ca099e2da47.tar.gz
sophie-a35d560f8d1ca414e3ba387b50731ca099e2da47.tar.zst
sophie-a35d560f8d1ca414e3ba387b50731ca099e2da47.zip
feat: Add custom menubar
The menu is populated reactive from the store with no caching. This doesn't seem to cause any performance problems so far. Currently the menu is electron-specific. In the future, we'll need a more runtime-independent way to build the menu. Signed-off-by: Kristóf Marussy <kristof@marussy.com>
Diffstat (limited to 'packages/main/src/infrastructure/electron/impl/electronShell.ts')
-rw-r--r--packages/main/src/infrastructure/electron/impl/electronShell.ts5
1 files changed, 4 insertions, 1 deletions
diff --git a/packages/main/src/infrastructure/electron/impl/electronShell.ts b/packages/main/src/infrastructure/electron/impl/electronShell.ts
index 0e8c0c1..be1cbe3 100644
--- a/packages/main/src/infrastructure/electron/impl/electronShell.ts
+++ b/packages/main/src/infrastructure/electron/impl/electronShell.ts
@@ -18,7 +18,7 @@
18 * SPDX-License-Identifier: AGPL-3.0-only 18 * SPDX-License-Identifier: AGPL-3.0-only
19 */ 19 */
20 20
21import { shell } from 'electron'; 21import { app, shell } from 'electron';
22import { getLogger } from 'loglevel'; 22import { getLogger } from 'loglevel';
23 23
24import type MainEnv from '../../../stores/MainEnv'; 24import type MainEnv from '../../../stores/MainEnv';
@@ -31,6 +31,9 @@ const electronShell: MainEnv = {
31 log.error('Failed to open', url, 'in external program', error); 31 log.error('Failed to open', url, 'in external program', error);
32 }); 32 });
33 }, 33 },
34 openAboutDialog(): void {
35 app.showAboutPanel();
36 },
34}; 37};
35 38
36export default electronShell; 39export default electronShell;