feat: add 'Close launcher on game start' option and improve app termination behavior (#93)

* update main branch to release/v2.0.2b (#86)

* add more linux pkgs, create auto-release and pre-release feature for Github Actions

* removed package-lock from gitignore

* update .gitignore for local build

* add package-lock.json to maintain stability development

* update version to 2.0.2b also add deps for rpm and arch

* update 2.0.2b: add arm64 support, product and executable name, maintainers; remove snap;

* update 2.0.2b: add latest.yml for win & linux, arm64 support; remove snap

* fix release build naming

* Prepare release v2.0.2b

* feat: add 'Close launcher on game start' option and improve app termination behavior

- Added 'Close launcher on game start' setting in GUI and backend.
- Implemented automatic app quit after game launch if setting is enabled.
- Added Cmd+Q (Mac) and Ctrl+Q/Alt+F4 (Win/Linux) shortcuts to quit the app.
- Updated 'window-close' handler to fully quit the app instead of just closing the window.
- Added i18n support for the new setting in English, Spanish, and Portuguese.

---------

Co-authored-by: Fazri Gading <fazrigading@gmail.com>
Co-authored-by: Arnav Singh <hi.arnavsingh3@gmail.com>
This commit is contained in:
Arnav Singh
2026-01-22 15:41:16 +05:30
committed by GitHub
parent a8da559e93
commit 68d697576a
11 changed files with 184 additions and 67 deletions

View File

@@ -156,6 +156,15 @@ function loadLanguage() {
return config.language || 'en';
}
function saveCloseLauncherOnStart(enabled) {
saveConfig({ closeLauncherOnStart: !!enabled });
}
function loadCloseLauncherOnStart() {
const config = loadConfig();
return config.closeLauncherOnStart !== undefined ? config.closeLauncherOnStart : false;
}
function saveModsToConfig(mods) {
try {
const config = loadConfig();
@@ -331,5 +340,8 @@ module.exports = {
resetCurrentUserUuid,
// GPU Preference exports
saveGpuPreference,
loadGpuPreference
loadGpuPreference,
// Close Launcher export
saveCloseLauncherOnStart,
loadCloseLauncherOnStart
};

View File

@@ -17,6 +17,8 @@ const {
loadDiscordRPC,
saveLanguage,
loadLanguage,
saveCloseLauncherOnStart,
loadCloseLauncherOnStart,
saveModsToConfig,
loadModsFromConfig,
getUuidForUser,
@@ -124,6 +126,10 @@ module.exports = {
saveLanguage,
loadLanguage,
// Close Launcher functions
saveCloseLauncherOnStart,
loadCloseLauncherOnStart,
// GPU Preference functions
saveGpuPreference,
loadGpuPreference,