1
0
mirror of https://github.com/ocornut/imgui.git synced 2024-11-27 17:10:57 +01:00

Backends: GLFW: revert flipping mouse-wheel axis for Emscripten. (#4019)

Latest version seems ok.
This commit is contained in:
ocornut 2023-02-02 18:09:20 +01:00
parent ce6e6da510
commit 624c057ae1
2 changed files with 0 additions and 10 deletions

View File

@ -16,7 +16,6 @@
// CHANGELOG
// (minor and older changes stripped away, please see git history for details)
// 2023-02-01: Inputs: flipping both wheel axises when running on Emscripten's GLFW emulation. (#6096)
// 2023-01-04: Inputs: Fixed mods state on Linux when using Alt-GR text input (e.g. German keyboard layout), could lead to broken text input. Revert a 2022/01/17 change were we resumed using mods provided by GLFW, turns out they were faulty.
// 2022-11-22: Perform a dummy glfwGetError() read to cancel missing names with glfwGetKeyName(). (#5908)
// 2022-10-18: Perform a dummy glfwGetError() read to cancel missing mouse cursors errors. Using GLFW_VERSION_COMBINED directly. (#5785)
@ -284,13 +283,6 @@ void ImGui_ImplGlfw_ScrollCallback(GLFWwindow* window, double xoffset, double yo
if (bd->PrevUserCallbackScroll != nullptr && window == bd->Window)
bd->PrevUserCallbackScroll(window, xoffset, yoffset);
#if defined(__EMSCRIPTEN__)
// Emscripten's GLFW emulation reports grossly mis-scaled and flipped scroll events.
// The scale is still currently incorrect, see #4019 #6096 for details.
xoffset = -xoffset;
yoffset = -yoffset;
#endif
ImGuiIO& io = ImGui::GetIO();
io.AddMouseWheelEvent((float)xoffset, (float)yoffset);
}

View File

@ -45,8 +45,6 @@ Breaking changes:
offer consistent horizontal scrolling direction. (#4019)
- Backends: SDL: flipping SDL_MOUSEWHEEL 'wheel.x' value to match other backends and
offer consistent horizontal scrolling direction. (#4019)
- Backends: GLFW+Emscripten: flipping both wheels axises when running on Emscripten's
GLFW emulation. (#6096) [@topolarity]
- Shift+WheelY support on non-OSX machines was already correct. (#2424, #1463)
(whereaas on OSX machines Shift+WheelY turns into WheelX at the OS level).
- If you use a custom-backend, you should verify that: