From cf73b12996c64331aa449dfca41d2617e8d895b4 Mon Sep 17 00:00:00 2001 From: Uyanide Date: Fri, 3 Apr 2026 09:06:21 +0200 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat:=20quitOnSelected=20default=20?= =?UTF-8?q?to=20true?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- WallReel/Assets/man/man.5 | 2 +- WallReel/Core/Config/data.hpp | 4 ++-- config.schema.json | 2 +- docs/man/man.5.md | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 4067092..83d3a88 100644 --- a/README.md +++ b/README.md @@ -121,7 +121,7 @@ Configures system commands to execute on specific events mapping to your window | `onPreview` | String | `""` | Command to execute when a wallpaper is previewed. | | `saveState` | Array of Objects | `[]` | Commands to fetch system states before changing wallpapers. Each object defines: `key`, `fallback` (fallback value), `command` (stdout mapping), and `timeout` (ms). | | `onRestore` | String | `""` | Command to execute on restore. Extracted states from `saveState` can be injected using `{{ key }}`. | -| `quitOnSelected` | Boolean | `false` | Quit the application after a selection is made. | +| `quitOnSelected` | Boolean | `true` | Quit the application after a selection is made. | | `restoreOnClose` | Boolean | `true` | Run `onRestore` command if the application is closed without making a final selection. | Available placeholders for `onSelected`, `onPreview` commands: diff --git a/WallReel/Assets/man/man.5 b/WallReel/Assets/man/man.5 index f879d87..f5d007e 100644 --- a/WallReel/Assets/man/man.5 +++ b/WallReel/Assets/man/man.5 @@ -97,7 +97,7 @@ Each item has: executed on restore. Saved state keys are usable as placeholders. .PP -\f[CR]quitOnSelected\f[R] (boolean, default: \f[CR]false\f[R]) : Exit +\f[CR]quitOnSelected\f[R] (boolean, default: \f[CR]true\f[R]) : Exit application immediately after confirming a selection. .PP \f[CR]restoreOnClose\f[R] (boolean, default: \f[CR]true\f[R]) : Run diff --git a/WallReel/Core/Config/data.hpp b/WallReel/Core/Config/data.hpp index b5a6e28..5fd6382 100644 --- a/WallReel/Core/Config/data.hpp +++ b/WallReel/Core/Config/data.hpp @@ -35,7 +35,7 @@ // action.saveState[].command string "" Command that outputs(to stdout) the value to save when executed // action.saveState[].timeout number 3000 Timeout for executing "command" in milliseconds. 0 or negative means no timeout // action.onRestore string "" Command to execute on restore ({{ key }} -> value defined or obtained in saveState) -// action.quitOnSelected boolean false Whether to quit the application after confirming a wallpaper +// action.quitOnSelected boolean true Whether to quit the application after confirming a wallpaper // action.restoreOnClose boolean true Whether to run the restore command after closing the application without confirming a wallpaper // // style.image_width number 320 Width of each image @@ -125,7 +125,7 @@ struct ActionConfigItems { QString onRestore; int previewDebounceTime = 300; // milliseconds bool printSelected = true; - bool quitOnSelected = false; + bool quitOnSelected = true; bool restoreOnClose = true; }; diff --git a/config.schema.json b/config.schema.json index 75be019..984bd64 100644 --- a/config.schema.json +++ b/config.schema.json @@ -143,7 +143,7 @@ }, "quitOnSelected": { "type": "boolean", - "default": false, + "default": true, "description": "Whether to quit the application after confirming a wallpaper" }, "restoreOnClose": { diff --git a/docs/man/man.5.md b/docs/man/man.5.md index d0dc16d..c9f1b09 100644 --- a/docs/man/man.5.md +++ b/docs/man/man.5.md @@ -98,7 +98,7 @@ Each item has: `onRestore` (string, default: `""`) : Command executed on restore. Saved state keys are usable as placeholders. -`quitOnSelected` (boolean, default: `false`) +`quitOnSelected` (boolean, default: `true`) : Exit application immediately after confirming a selection. `restoreOnClose` (boolean, default: `true`)