mirror of
https://github.com/glfw/glfw.git
synced 2026-01-11 15:23:17 +01:00
Wayland: Replace _glfwKeySym2Unicode with xkbcommon
libxkbcommon already provides functions to convert keysyms to codepoints and UTF-8. The library has offered these functions since 0.5.0[1], so using them won't cause any compatibility problems. [1] https://xkbcommon.org/doc/0.5.0/group__keysyms.html Closes #2444
This commit is contained in:
@@ -711,6 +711,10 @@ int _glfwInitWayland(void)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.xkb.handle, "xkb_compose_state_get_status");
|
||||
_glfw.wl.xkb.compose_state_get_one_sym = (PFN_xkb_compose_state_get_one_sym)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.xkb.handle, "xkb_compose_state_get_one_sym");
|
||||
_glfw.wl.xkb.keysym_to_utf32 = (PFN_xkb_keysym_to_utf32)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.xkb.handle, "xkb_keysym_to_utf32");
|
||||
_glfw.wl.xkb.keysym_to_utf8 = (PFN_xkb_keysym_to_utf8)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.xkb.handle, "xkb_keysym_to_utf8");
|
||||
|
||||
if (!_glfw.wl.xkb.context_new ||
|
||||
!_glfw.wl.xkb.context_unref ||
|
||||
|
||||
Reference in New Issue
Block a user