mirror of
https://github.com/fluxerapp/fluxer
synced 2026-10-17 13:05:32 +09:00
feat(desktop): add FLUXER_DISABLE_MODULE_UPDATES opt-out (#3466)
This commit is contained in:
1 parent
e8dff6a8a1
commit
e403fb6cce
11 files changed
+302
-77
No files matched your search
@@ -13,6 +13,7 @@ import type {
|
||||
} from '@electron/common/Types';
|
||||
import {getDesktopUpdateState, observeDesktopUpdateState} from '@electron/main/DesktopUpdateGate';
|
||||
import {checkForUpdatesFromShell, startDesktopUpdateFromShell} from '@electron/main/DesktopUpdatePrompt';
|
||||
import {areModuleUpdatesDisabled} from '@electron/main/LaunchOptions';
|
||||
import {relaunchStableLaunchPath} from '@electron/main/LinuxLaunchPath';
|
||||
import {onLocaleChange, t} from '@electron/main/MainI18n';
|
||||
import {app, type BrowserWindow, clipboard, Menu, nativeImage, Tray} from 'electron';
|
||||
@@ -399,13 +400,15 @@ function buildTrayMenu(): Menu {
|
||||
click: () => runTrayMenuAction(startDesktopUpdateFromShell),
|
||||
});
|
||||
}
|
||||
menuTemplate.push({
|
||||
label: t('desktop.tray.checkForUpdates'),
|
||||
click: () =>
|
||||
runTrayMenuAction(() => {
|
||||
void checkForUpdatesFromShell();
|
||||
}),
|
||||
});
|
||||
if (!areModuleUpdatesDisabled()) {
|
||||
menuTemplate.push({
|
||||
label: t('desktop.tray.checkForUpdates'),
|
||||
click: () =>
|
||||
runTrayMenuAction(() => {
|
||||
void checkForUpdatesFromShell();
|
||||
}),
|
||||
});
|
||||
}
|
||||
if (trayState.buildInfo) {
|
||||
menuTemplate.push({
|
||||
label: t('desktop.tray.copyBuildInfo'),
|
||||
|
||||
Reference in new issue
Block a user