Fixed keyboard shortcuts on linux.
This commit is contained in:
parent
78f44600fc
commit
e65907488c
@ -220,15 +220,10 @@ static void key_callback(GLFWwindow *window, int key, int scancode, int action,
|
||||
key_super = down;
|
||||
break;
|
||||
default:
|
||||
// GLFW has some platform issues with keyboard handling that needs workaround until
|
||||
// it's fixed properly in glfw. This code must not run on linux with glfw 3.0.4 (it
|
||||
// has changed several times in the past). issue #10.
|
||||
#ifndef TB_TARGET_LINUX
|
||||
// glfw calls key_callback instead of char_callback
|
||||
// when pressing a character while ctrl is also pressed.
|
||||
if ((key_ctrl || key_super) && !key_alt && key >= 32 && key <= 255)
|
||||
InvokeKey(window, key, TB_KEY_UNDEFINED, modifier, down);
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user