mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2026-06-17 14:11:33 +00:00
Limit the IME workaround to Windows only
This commit is contained in:
@@ -302,14 +302,20 @@ void SdlInputHandler::notifyFocusLost()
|
|||||||
// used in shortcuts that cause focus loss (such as Alt+Tab) may get stuck down.
|
// used in shortcuts that cause focus loss (such as Alt+Tab) may get stuck down.
|
||||||
raiseAllKeys();
|
raiseAllKeys();
|
||||||
|
|
||||||
// Re-enable text input when window loses focus
|
#ifdef Q_OS_WIN32
|
||||||
|
// Re-enable text input when window loses focus as a workaround for an SDL bug.
|
||||||
|
// See #1617 for details.
|
||||||
SDL_StartTextInput();
|
SDL_StartTextInput();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void SdlInputHandler::notifyFocusGained()
|
void SdlInputHandler::notifyFocusGained()
|
||||||
{
|
{
|
||||||
// Disable text input when window gains focus to prevent IME popup interference
|
#ifdef Q_OS_WIN32
|
||||||
|
// Disable text input when window gains focus to prevent IME popup interference.
|
||||||
|
// See #1617 for details.
|
||||||
SDL_StopTextInput();
|
SDL_StopTextInput();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
bool SdlInputHandler::isCaptureActive()
|
bool SdlInputHandler::isCaptureActive()
|
||||||
|
|||||||
Reference in New Issue
Block a user