Adding an ImGuiKey 'ImGuiKey_EnterSecondary' to support platforms that differentiate the enter (return key) and the numpad enter key.

This commit is contained in:
Aaron Cooper
2019-07-18 17:24:56 -07:00
committed by omar
parent 4b44f25c9a
commit 0f86116a69
8 changed files with 29 additions and 22 deletions

View File

@ -143,6 +143,7 @@ static bool ImGui_ImplSDL2_Init(SDL_Window* window)
io.KeyMap[ImGuiKey_Backspace] = SDL_SCANCODE_BACKSPACE;
io.KeyMap[ImGuiKey_Space] = SDL_SCANCODE_SPACE;
io.KeyMap[ImGuiKey_Enter] = SDL_SCANCODE_RETURN;
io.KeyMap[ImGuiKey_EnterSecondary] = SDL_SCANCODE_RETURN2;
io.KeyMap[ImGuiKey_Escape] = SDL_SCANCODE_ESCAPE;
io.KeyMap[ImGuiKey_A] = SDL_SCANCODE_A;
io.KeyMap[ImGuiKey_C] = SDL_SCANCODE_C;