TextProxy: don't re-press Ctrl after a paste if it was released meanwhile (stuck Ctrl)
Build & Release / build (push) Canceled after 0s
Build & Release / build (push) Canceled after 0s
This commit is contained in:
1 parent
e1c4ea96d7
commit
fdbf6d5583
3 files changed
+11
-3
No files matched your search
@@ -360,7 +360,11 @@ function ImGui_ImplRoblox_NewFrame()
|
||||
for _, cp in utf8.codes(text:sub(#prev + 1)) do io:AddInputCharacter(cp) end
|
||||
end
|
||||
end
|
||||
if ctrl then io:AddKeyEvent(ImGuiMod_Ctrl, true) end
|
||||
-- re-press only if still physically held: the text can arrive after Ctrl's InputEnded, and re-pressing
|
||||
-- then left Ctrl stuck down in imgui (typing ignored, shortcuts broken until Ctrl was pressed again)
|
||||
if ctrl and (UserInputService:IsKeyDown(Enum.KeyCode.LeftControl) or UserInputService:IsKeyDown(Enum.KeyCode.RightControl)) then
|
||||
io:AddKeyEvent(ImGuiMod_Ctrl, true)
|
||||
end
|
||||
used_proxy_text = true
|
||||
BackendData.ProxyText = nil
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user