Unify key name string handling

This makes key names per-key static strings for all supported platforms.

Fixes #1200.

(cherry picked from commit 56ca0cb3b3)
This commit is contained in:
Camilla Löwy
2019-08-22 21:31:46 +02:00
parent 2032a8f0dc
commit 79f4ec6822
5 changed files with 16 additions and 11 deletions

View File

@@ -4193,9 +4193,11 @@ GLFWAPI int glfwRawMouseMotionSupported(void);
* @errors Possible errors include @ref GLFW_NOT_INITIALIZED and @ref
* GLFW_PLATFORM_ERROR.
*
* @remark The contents of the returned string may change when a keyboard
* layout change event is received.
*
* @pointer_lifetime The returned string is allocated and freed by GLFW. You
* should not free it yourself. It is valid until the next call to @ref
* glfwGetKeyName, or until the library is terminated.
* should not free it yourself. It is valid until the library is terminated.
*
* @thread_safety This function must only be called from the main thread.
*