Add option to not minimize to tray
This commit is contained in:
parent
94b80ebe75
commit
c29dd6d2d7
3 changed files with 3 additions and 1 deletions
|
@ -222,7 +222,7 @@ export function createMainWindow() {
|
|||
});
|
||||
|
||||
win.on("close", e => {
|
||||
if (isQuitting) return;
|
||||
if (isQuitting || Settings.minimizeToTray === false) return;
|
||||
|
||||
e.preventDefault();
|
||||
win.hide();
|
||||
|
|
|
@ -10,6 +10,7 @@ export default function SettingsUi() {
|
|||
const { Forms: { FormSection, FormText, FormDivider, FormSwitch, FormTitle }, Text, Select, Button } = Common;
|
||||
|
||||
const switches: [keyof typeof Settings, string, string, boolean?][] = [
|
||||
["minimizeToTray", "Minimize to tray", "Hitting X will make Discord minimize to the tray instead of closing", true],
|
||||
["openLinksWithElectron", "Open Links in app", "Opens links in a new window instead of your WebBrowser"],
|
||||
["disableMinSize", "Disable minimum window size", "Allows you to resize the window smaller than the default size"],
|
||||
];
|
||||
|
|
1
src/shared/settings.d.ts
vendored
1
src/shared/settings.d.ts
vendored
|
@ -8,4 +8,5 @@ export interface Settings {
|
|||
openLinksWithElectron?: boolean;
|
||||
vencordDir?: string;
|
||||
disableMinSize?: boolean;
|
||||
minimizeToTray?: boolean;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue