Fix space key being ignored
This commit is contained in:
parent
397ca366c3
commit
3b314c119b
2 changed files with 3 additions and 3 deletions
|
|
@ -215,7 +215,7 @@ void ImGuiWidget::onButton(const ButtonEvent& e)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
io.KeyCtrl = e.mods & GLFW_MOD_CTRL;
|
io.KeyCtrl = e.mods & GLFW_MOD_CONTROL;
|
||||||
io.KeyShift = e.mods & GLFW_MOD_SHIFT;
|
io.KeyShift = e.mods & GLFW_MOD_SHIFT;
|
||||||
io.KeyAlt = e.mods & GLFW_MOD_ALT;
|
io.KeyAlt = e.mods & GLFW_MOD_ALT;
|
||||||
io.KeySuper = e.mods & GLFW_MOD_SUPER;
|
io.KeySuper = e.mods & GLFW_MOD_SUPER;
|
||||||
|
|
@ -245,7 +245,7 @@ void ImGuiWidget::onSelectKey(const SelectKeyEvent& e)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
io.KeyCtrl = e.mods & GLFW_MOD_CTRL;
|
io.KeyCtrl = e.mods & GLFW_MOD_CONTROL;
|
||||||
io.KeyShift = e.mods & GLFW_MOD_SHIFT;
|
io.KeyShift = e.mods & GLFW_MOD_SHIFT;
|
||||||
io.KeyAlt = e.mods & GLFW_MOD_ALT;
|
io.KeyAlt = e.mods & GLFW_MOD_ALT;
|
||||||
io.KeySuper = e.mods & GLFW_MOD_SUPER;
|
io.KeySuper = e.mods & GLFW_MOD_SUPER;
|
||||||
|
|
|
||||||
|
|
@ -514,7 +514,7 @@ protected:
|
||||||
|
|
||||||
bool onCharacterInput(const CharacterInputEvent& ev) override
|
bool onCharacterInput(const CharacterInputEvent& ev) override
|
||||||
{
|
{
|
||||||
if (ev.character <= ' ' || ev.character >= kKeyDelete)
|
if (ev.character < ' ' || ev.character >= kKeyDelete)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
const int mods = glfwMods(ev.mod);
|
const int mods = glfwMods(ev.mod);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue