Code compilation fix

This commit is contained in:
Bruno Herbelin
2023-03-07 23:38:13 +01:00
parent 4c3c3de065
commit b8e0a9c1dd
11 changed files with 16 additions and 11 deletions

View File

@@ -1253,6 +1253,7 @@ std::string Control::inputLabel(uint id)
//
int Control::layoutKey(int key)
{
#if (GLFW_VERSION_MAJOR * 1000 + GLFW_VERSION_MINOR * 100 >= 3300) // 3.3+
static int _keyMap[GLFW_KEY_LAST];
static bool _initialized = false;
if (!_initialized) {
@@ -1283,4 +1284,7 @@ int Control::layoutKey(int key)
// fprintf(stderr, "%d pressed; converted to %d\n", key, _keyMap[key]);
return _keyMap[key];
#else
return key;
#endif
}