Don't broadcast language change

This commit is contained in:
Yusyuriv 2025-03-23 18:26:11 +06:00
parent bf011f11db
commit 382d0c2bfe
No known key found for this signature in database
GPG key ID: A91C52E6F73148E0
2 changed files with 3 additions and 2 deletions

View file

@ -54,6 +54,5 @@ ActivateKeyboardLayout
GetKeyboardLayoutList
PostMessage
HWND_BROADCAST
WM_INPUTLANGCHANGEREQUEST
INPUTLANGCHANGE_FORWARD

View file

@ -403,7 +403,9 @@ namespace Flow.Launcher.Infrastructure
{
if (_previousLayout == HKL.Null) return;
PInvoke.PostMessage(HWND.HWND_BROADCAST,
var hwnd = PInvoke.GetForegroundWindow();
PInvoke.PostMessage(
hwnd,
PInvoke.WM_INPUTLANGCHANGEREQUEST,
PInvoke.INPUTLANGCHANGE_FORWARD,
_previousLayout.Value