mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-09 23:54:20 +00:00
Backends: SDL2: Fixed build for Emscripten and SDL_HAS_CAPTURE_AND_GLOBAL_MOUSE=0 platforms.
Amend e06b5df.
This commit is contained in:
parent
719ea9c228
commit
940627d008
1 changed files with 1 additions and 0 deletions
|
|
@ -667,6 +667,7 @@ static void ImGui_ImplSDL2_UpdateMouseData()
|
|||
SDL_Window* focused_window = SDL_GetKeyboardFocus();
|
||||
const bool is_app_focused = (bd->Window == focused_window);
|
||||
#else
|
||||
SDL_Window* focused_window = bd->Window;
|
||||
const bool is_app_focused = (SDL_GetWindowFlags(bd->Window) & SDL_WINDOW_INPUT_FOCUS) != 0; // SDL 2.0.3 and non-windowed systems: single-viewport only
|
||||
#endif
|
||||
if (is_app_focused)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue