Fix readSelectionFromPasteboard not actually inserting the text

This commit is contained in:
Kovid Goyal 2023-02-02 06:14:34 +05:30
parent 01720a8d4f
commit 78d0cc40a3
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -1632,7 +1632,7 @@ void _glfwPlatformUpdateIMEState(_GLFWwindow *w, const GLFWIMEUpdateEvent *ev) {
_glfwInputKeyboard(window, &glfw_keyevent);
}
debug_key("Sending text received in readSelectionFromPasteboard as key event\n");
GLFWkeyevent glfw_keyevent = {.text=utf8};
GLFWkeyevent glfw_keyevent = {.text=utf8, .ime_state=GLFW_IME_COMMIT_TEXT};
_glfwInputKeyboard(window, &glfw_keyevent);
return YES;
}