From ae708e3bcd761230016d3f5c8bedf396e04477d0 Mon Sep 17 00:00:00 2001 From: ocornut Date: Tue, 2 Jul 2024 12:12:25 +0200 Subject: [PATCH] Backends: SDL3: add default case to fix warnings. (#7763) --- backends/imgui_impl_sdl2.cpp | 1 + backends/imgui_impl_sdl3.cpp | 2 ++ 2 files changed, 3 insertions(+) diff --git a/backends/imgui_impl_sdl2.cpp b/backends/imgui_impl_sdl2.cpp index 5a319b930..6d2a868fa 100644 --- a/backends/imgui_impl_sdl2.cpp +++ b/backends/imgui_impl_sdl2.cpp @@ -287,6 +287,7 @@ static ImGuiKey ImGui_ImplSDL2_KeyEventToImGuiKey(SDL_Keycode keycode, SDL_Scanc case SDLK_F24: return ImGuiKey_F24; case SDLK_AC_BACK: return ImGuiKey_AppBack; case SDLK_AC_FORWARD: return ImGuiKey_AppForward; + default: break; } return ImGuiKey_None; } diff --git a/backends/imgui_impl_sdl3.cpp b/backends/imgui_impl_sdl3.cpp index bc56a51a9..c02345c8d 100644 --- a/backends/imgui_impl_sdl3.cpp +++ b/backends/imgui_impl_sdl3.cpp @@ -168,6 +168,7 @@ static ImGuiKey ImGui_ImplSDL3_KeyEventToImGuiKey(SDL_Keycode keycode, SDL_Scanc case SDL_SCANCODE_KP_PLUS: return ImGuiKey_KeypadAdd; case SDL_SCANCODE_KP_ENTER: return ImGuiKey_KeypadEnter; case SDL_SCANCODE_KP_EQUALS: return ImGuiKey_KeypadEqual; + default: break; } switch (keycode) { @@ -273,6 +274,7 @@ static ImGuiKey ImGui_ImplSDL3_KeyEventToImGuiKey(SDL_Keycode keycode, SDL_Scanc case SDLK_F24: return ImGuiKey_F24; case SDLK_AC_BACK: return ImGuiKey_AppBack; case SDLK_AC_FORWARD: return ImGuiKey_AppForward; + default: break; } return ImGuiKey_None; }