[Win32] Add PrtScr hotkey check for KeyEvent tests #2516 #2595
+5
−3
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.
The Win32 KeyEvent tests started to fail on GitHub Actions when the environment was updated to Windows Server 2025. Using the print screen button opens the Windows snipping tools which, for yet unknown reason, now receives the focus and does not close automatically when processing further key events, like it did before and does on Windows 11 systems.
To keep the tests working properly, this change excludes the PtrScr key as a system hotkey when not combined with any modifier key. It reverts the complete disablement of the tests performed in #2559.
Fixes #2516
@jonahgraham this is an extended version of your experiment jonahgraham#2
It limits the exclusion of the PtrScr key to the case where no state modifier is used, as this seems to be sufficient and ensures that we preserve testing of the other key combinations. I've successfully run this configuration three time in HeikoKlare#2.