Officially support the system tray on Windows
This commit is contained in:
parent
23acbf284e
commit
af1f2ea449
24 changed files with 968 additions and 194 deletions
|
@ -55,6 +55,10 @@ import { ReadReceipts } from './messageModifiers/ReadReceipts';
|
|||
import { ReadSyncs } from './messageModifiers/ReadSyncs';
|
||||
import { ViewSyncs } from './messageModifiers/ViewSyncs';
|
||||
import * as AttachmentDownloads from './messageModifiers/AttachmentDownloads';
|
||||
import {
|
||||
SystemTraySetting,
|
||||
parseSystemTraySetting,
|
||||
} from './types/SystemTraySetting';
|
||||
|
||||
const MAX_ATTACHMENT_DOWNLOAD_AGE = 3600 * 72 * 1000;
|
||||
|
||||
|
@ -464,6 +468,12 @@ export async function startApp(): Promise<void> {
|
|||
window.setAutoHideMenuBar(value);
|
||||
window.setMenuBarVisibility(!value);
|
||||
},
|
||||
getSystemTraySetting: (): SystemTraySetting =>
|
||||
parseSystemTraySetting(window.storage.get('system-tray-setting')),
|
||||
setSystemTraySetting: (value: Readonly<SystemTraySetting>) => {
|
||||
window.storage.put('system-tray-setting', value);
|
||||
window.updateSystemTraySetting(value);
|
||||
},
|
||||
|
||||
getNotificationSetting: () =>
|
||||
window.storage.get('notification-setting', 'message'),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue