|
|
@ -15,6 +15,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
// CHANGELOG
|
|
|
|
// CHANGELOG
|
|
|
|
// (minor and older changes stripped away, please see git history for details)
|
|
|
|
// (minor and older changes stripped away, please see git history for details)
|
|
|
|
|
|
|
|
// 2018-08-01: Inputs: Workaround for Emscripten which doesn't seem to handle focus related calls.
|
|
|
|
// 2018-06-29: Inputs: Added support for the ImGuiMouseCursor_Hand cursor.
|
|
|
|
// 2018-06-29: Inputs: Added support for the ImGuiMouseCursor_Hand cursor.
|
|
|
|
// 2018-06-08: Misc: Extracted imgui_impl_sdl.cpp/.h away from the old combined SDL2+OpenGL/Vulkan examples.
|
|
|
|
// 2018-06-08: Misc: Extracted imgui_impl_sdl.cpp/.h away from the old combined SDL2+OpenGL/Vulkan examples.
|
|
|
|
// 2018-06-08: Misc: ImGui_ImplSDL2_InitForOpenGL() now takes a SDL_GLContext parameter.
|
|
|
|
// 2018-06-08: Misc: ImGui_ImplSDL2_InitForOpenGL() now takes a SDL_GLContext parameter.
|
|
|
@ -214,7 +215,7 @@ static void ImGui_ImplSDL2_UpdateMousePosAndButtons()
|
|
|
|
io.MouseDown[2] = g_MousePressed[2] || (mouse_buttons & SDL_BUTTON(SDL_BUTTON_MIDDLE)) != 0;
|
|
|
|
io.MouseDown[2] = g_MousePressed[2] || (mouse_buttons & SDL_BUTTON(SDL_BUTTON_MIDDLE)) != 0;
|
|
|
|
g_MousePressed[0] = g_MousePressed[1] = g_MousePressed[2] = false;
|
|
|
|
g_MousePressed[0] = g_MousePressed[1] = g_MousePressed[2] = false;
|
|
|
|
|
|
|
|
|
|
|
|
#if SDL_HAS_CAPTURE_MOUSE
|
|
|
|
#if SDL_HAS_CAPTURE_MOUSE && !defined(__EMSCRIPTEN__)
|
|
|
|
SDL_Window* focused_window = SDL_GetKeyboardFocus();
|
|
|
|
SDL_Window* focused_window = SDL_GetKeyboardFocus();
|
|
|
|
if (g_Window == focused_window)
|
|
|
|
if (g_Window == focused_window)
|
|
|
|
{
|
|
|
|
{
|
|
|
|