Clean up code and documentation for glfwGetKeyScancode and add
implementation for Wayland and Mir.

Related to #830.
This commit is contained in:
Camilla Berglund
2016-09-06 15:40:31 +02:00
parent e745b0dd47
commit bb3cb8f233
11 changed files with 28 additions and 41 deletions
+4 -7
View File
@@ -225,16 +225,13 @@ arguments can always be passed unmodified to this function.
@subsection input_key_scancode Key scancodes
If you need the platform dependent scancode for any given key, you can query
it with @ref glfwGetKeyScancode.
If you need the platform dependent scancode for a [named key](@ref keys), you
can query it with @ref glfwGetKeyScancode.
@code
const short int scancode = glfwGetKeyScancode(GLFW_KEY_X);
const int scancode = glfwGetKeyScancode(GLFW_KEY_X);
set_key_mapping(scancode, swap_weapons);
@encode
If the key is `GLFW_KEY_UNKNOWN` or does not exist on the keyboard this
method will return `-1`.
@endcode
@section input_mouse Mouse input