launcher: configure and preview controller lightbar color
Add an optional lightbar color to launcher settings and pass it to the emulator with --controller-color. Preview changes on RGB gamepads, handle controller hotplug events, and restore the saved color when settings dialogs close. Release launcher preview handles when starting a game.
Co-authored-by: m66401970-eng <m66401970@gmail.com>
* launcher: keep primary update feed answer when the fallback request fails
When the primary feed is reachable but its tag differs from the build tag,
the result was discarded and the GitHub API fallback was consulted. If the
fallback request failed (api.github.com rate-limits unauthenticated
requests), the launcher reported an error even though the primary feed had
already returned a usable update answer with a working release URL. Keep
the primary feed answer and show it if the fallback fails.
* emulator: validate numeric CLI arguments
--screen-width, --screen-height, --gpu, and --vblank-frequency were parsed
with Common::ToInt32/ToInt64, which ignores std::from_chars errors and
returns 0, so values like "--screen-width abc" or "--gpu xyz" were
silently accepted: zero screen size, or GPU 0 selected instead of auto
(-1). Reject invalid values with an error message like the other options,
using from_chars-based helpers (ParseUint32/ParseInt32); reject zero
screen dimensions.
* tests: add LeastRecentlyUsedCache regression tests
Cover the LRU cache walk order, tick filtering in ForEachItemBelow,
early-exit boolean callbacks, Touch reordering and same-tick skips,
Free, and freed-id reuse by later inserts. Modeled on BitArrayTests.
* tests: use a tick cutoff that detects a stale newest-item tick
Collect(cache, 35) also visits c when Touch(c, 35) failed to update
its tick (30 <= 35). Use a cutoff of 30 and expect only b.
* Run LRU cache tests in CI
---------
Co-authored-by: nmzik <Nmzik@mail.ru>
* cli: add --gpu <index> to select a Vulkan physical device
Select the Vulkan physical device by enumeration index, defaulting to
automatic selection (-1). Invalid or out-of-range indices fall back to
automatic selection with a clear message, and the selected device is
logged.
Co-Authored-By: Claude <noreply@anthropic.com>
* cli: reject invalid --gpu index, translate comments, apply clang-format
An invalid --gpu index now prints an error and exits with code 1 (usage),
matching --user-id / --present-mode / --console-language. The automatic
fallback is kept only for out-of-range indices detected at runtime.
Comments translated to English and the touched files brought in line
with clang-format (pre-commit v22.1.3).
Co-Authored-By: Claude <noreply@anthropic.com>
* cli: simplify Vulkan device selection
---------
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: nmzik <Nmzik@mail.ru>
* graphics: report the VkResult when a submit or fence wait fails
* graphics: add a --gpu-assisted-validation flag
* graphics: imply Vulkan validation for GPU-assisted validation
---------
Co-authored-by: nmzik <Nmzik@mail.ru>
Add compact keyboard and mouse mapping with analog-stick defaults and integrate a global remapping editor into the Qt launcher.
Based on the host input remapping work from PR #109.
Co-authored-by: DistantMyth <thetarun3@gmail.com>