16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-17 23:39:18 +02:00

fix linux crash (maybe not correct, but does not crash)

This commit is contained in:
milek7
2017-08-18 15:58:08 +02:00
parent 6b5084e855
commit 9aace0d85f

View File

@@ -53,6 +53,9 @@ int vk_to_glfw_key( int const Keycode ) {
#ifdef _WINDOWS
auto const code = VkKeyScan( Keycode );
#else
auto const code = (short int)Keycode;
#endif
char key = code & 0xff;
char shiftstate = ( code & 0xff00 ) >> 8;
@@ -63,7 +66,6 @@ int vk_to_glfw_key( int const Keycode ) {
key = GLFW_KEY_0 + key - '0';
}
return key + ( shiftstate << 8 );
#endif
}
bool TEventLauncher::Load(cParser *parser)