Fix Windows 10 Full-screen Start Menu search Z-Order bug on Windows 11 - #5179
Open
envergokmenn wants to merge 1 commit into
Open
Fix Windows 10 Full-screen Start Menu search Z-Order bug on Windows 11#5179envergokmenn wants to merge 1 commit into
envergokmenn wants to merge 1 commit into
Conversation
envergokmenn
marked this pull request as ready for review
September 9, 2026 17:22
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.
PR Description
Problem
When using ExplorerPatcher on Windows 11 with the Windows 10 Start menu style and "Full screen Start" enabled (
ForceStartSize = 2):Winkey properly opens the full-screen Windows 10 tile Start Menu.SearchHost.exe) to get stuck behindStartMenuExperienceHost.exedue to Windows 11 DWM / CoreWindow Z-Order isolation.Root Cause
SearchHost.exeis a separate XAML host fromStartMenuExperienceHost.exe.StartMenuExperienceHostclaims exclusive foreground Z-order and does not yield when SearchHost activates.SetForegroundWindow,BringWindowToTop) are blocked by modern CoreWindow isolation.Solution
This PR adds a dedicated, lightweight native C module (
StartSearchFix.h/StartSearchFix.c) that hooks the keyboard (WH_KEYBOARD_LL) to orchestrate a seamless, flicker-free transition:StartMenuExperienceHostorSearchHost.ESC+ 180ms):ESCkeydown and keyup.StartMenuExperienceHostdismissal animation to complete cleanly without killing the subsequent Search window.Win + S):Win + Swith hardware scan codes (VK_LWIN0x5B scan 0x5B,VK_S0x53 scan 0x1F).Alt+Tab).|to take focus.keybd_eventwith both Virtual Key and hardware scan codes (MapVirtualKeyW).Changes
ExplorerPatcher/StartSearchFix.h&ExplorerPatcher/StartSearchFix.c.StartSearchFix.cinExplorerPatcher.vcxprojandExplorerPatcher.vcxproj.filters.StartSearchFix_Init()indllmain.c(Inject) and cleaned up inDLL_PROCESS_DETACH.