Compatibility
Minecraft: Java Edition
26.1.x
1.21.11
Platforms
Supported environments
Client-side
Links
Tags
Creators
Details
Licensed LGPL-3.0-or-later
Published 2 weeks ago
MC-122477 Fix
This mod fixes MC-122477 Linux/GNU: Opening chat sometimes writes 't'.
Bug
The bug is caused by an upstream bug in GLFW tracked at GLFW#1794. When the "Open Chat" keybind is pressed the next glfwPollEvents() call should fire a KeyCallback and a CharCallback for the key. Due to the bug the CharCallback isnt fired immediately and instead fires at the next but one glfwPollEvents() call. At this time the ChatScreen might already be open and the character associated with the "Open Chat" keybind (often a "t" is typed into the chat).
Fix
This mod simply cancels the next CharCallback that appears one to three glfwPollEvents() calls after the "Open Chat" or "Open Command" keybind is pressed (only if the chat is actually opened).


