TextProxy: key-code fallback waits a few frames for the TextBox (fixes doubled typing)
Build & Release / build (push) Canceled after 0s
Build & Release / build (push) Canceled after 0s
This commit is contained in:
1 parent
4bee0e493a
commit
e1c4ea96d7
4 files changed
+24
-8
No files matched your search
@@ -64,7 +64,7 @@ game:GetService("RunService").Stepped:Connect(function()
|
||||
assert(st.TextLen == 0, "backspace should delete imgui's whole selection, len " .. st.TextLen)
|
||||
print("BACKSPACE OK")
|
||||
end
|
||||
if f == 27 then
|
||||
if f == 30 then -- (key-code fallback waits a few frames for the TextBox first)
|
||||
local st = ImGui.GetCurrentContext().InputTextState
|
||||
local got = G.ImGui._ByteArrayToString(st.TextA.Data, 1, st.TextLen + 1)
|
||||
assert(got:find("z"), "key fallback while proxy focused: " .. got)
|
||||
|
||||
Reference in new issue
Block a user