From f96c7fac91cf93ce7221f1aab43ba005ae469c6d Mon Sep 17 00:00:00 2001 From: omar Date: Mon, 11 Jun 2018 20:03:35 +0200 Subject: [PATCH] Examples: FreeGLUT: Fixed mapping of Space key. (#801) --- examples/imgui_impl_freeglut.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/imgui_impl_freeglut.cpp b/examples/imgui_impl_freeglut.cpp index 57fc9da2..3c099eca 100644 --- a/examples/imgui_impl_freeglut.cpp +++ b/examples/imgui_impl_freeglut.cpp @@ -38,11 +38,12 @@ bool ImGui_ImplFreeGLUT_Init() io.KeyMap[ImGuiKey_PageDown] = 256 + GLUT_KEY_PAGE_DOWN; io.KeyMap[ImGuiKey_Home] = 256 + GLUT_KEY_HOME; io.KeyMap[ImGuiKey_End] = 256 + GLUT_KEY_END; + io.KeyMap[ImGuiKey_Insert] = 256 + GLUT_KEY_INSERT; io.KeyMap[ImGuiKey_Delete] = 127; io.KeyMap[ImGuiKey_Backspace] = 8; // == CTRL+H + io.KeyMap[ImGuiKey_Space] = ' '; io.KeyMap[ImGuiKey_Enter] = 13; // == CTRL+M io.KeyMap[ImGuiKey_Escape] = 27; - io.KeyMap[ImGuiKey_Insert] = 256 + GLUT_KEY_INSERT; io.KeyMap[ImGuiKey_A] = 'A'; io.KeyMap[ImGuiKey_C] = 'C'; io.KeyMap[ImGuiKey_V] = 'V';