Add option to restrict cycle hotkeys to focused EVE windows - #136
Open
mr-moon wants to merge 1 commit into
Open
Conversation
mr-moon
force-pushed
the
feature/conditional-cycle-hotkeys
branch
3 times, most recently
from
June 23, 2026 18:22
8de3c7a to
cb492b7
Compare
…VE clients Cycle-group and Minimize-All hotkeys were registered as global hotkeys (RegisterHotKey), so they fired everywhere and swallowed the key even when no EVE window was focused. This adds an opt-in option to only act on those hotkeys while an EVE client or an EVE-O-Preview window is focused, passing the key through to its native action otherwise. - Keep activating clients through RegisterHotKey (HotkeyHandler): its WM_HOTKEY message implicitly grants this process the right to change the foreground window, so a plain SetForegroundWindow stays fast and reliable. (A low-level keyboard hook does not get this grant, which caused windows to fail to focus, intermittent lag, stuck highlight borders, and broken cycling after Alt-Tab.) - Achieve conditional pass-through by registering / unregistering the cycle / minimize hotkeys as the foreground window changes, via a SetWinEventHook watcher (ForegroundWindowWatcher). Unregistered hotkeys pass through to their native action; gating is instant on focus change with a refresh-timer backstop so a runtime toggle takes effect without a restart. - Add RestrictCycleHotkeysToActiveClients config + General-tab checkbox. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
mr-moon
force-pushed
the
feature/conditional-cycle-hotkeys
branch
from
June 24, 2026 10:51
cb492b7 to
0277fc6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Cycle-group and "Minimize All Clients" hotkeys were registered as system-wide global hotkeys (RegisterHotKey). They fired in
every application and swallowed the key combo even when no EVE window was focused, so the key's native action could never run.
This PR adds an opt-in option so those hotkeys only act while an EVE client window or an EVE-O-Preview window is focused;
otherwise the key passes through to its native action. Default is off, preserving current behavior.
Changes
each press can be suppressed (handled) or passed through (CallNextHookEx). Exact modifier matching; cycling work dispatched
async so the callback never trips the OS hook timeout.
EVE-O-Preview window, reusing IsClientWindowActive / IsMainWindowActive. Flag is read live, so toggling applies without
restart.
SetForegroundWindow. RegisterHotKey granted this implicitly; a low-level hook does not, so without it the next client would
highlight then immediately revert.
focused" checkbox on the General tab, following the existing HideThumbnailsOnLostFocus pattern.
Scope
Only cycle-group and Minimize-All hotkeys are affected. Per-character jump hotkeys are unchanged.