Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

don't trickle fast imgui inputs #73180

Merged
merged 1 commit into from
Apr 22, 2024

Conversation

nornagon
Copy link
Contributor

Summary

Bugfixes "Fixed frame lag in imgui text inputs"

Purpose of change

Fixed laggy text input in imgui windows.

See #73052. This fixes the issue on macOS. The issue might be the same on
Android (and thus also fixed by this change), but I haven't verified.

Describe the solution

There's an imgui feature that's supposed to prevent "skipping" inputs that
happen quickly by trickling them out one per frame if they happen on the same
key. However, this seems to also be applying to the "keydown" event and then
the "text" event, which both "involve" the same key, even though they're just
two different views of the same event.

This could plausibly be described as an ImGui bug—the trickling behavior could
be useful for repeated down/up/down sequences on a key, perhaps, but it
shouldn't apply to text events—but I'm not sure we really want the trickling
behavior at all, so this patch just disables it.

Describe alternatives you've considered

Testing

Additional context

@github-actions github-actions bot added Info / User Interface Game - player communication, menus, etc. [C++] Changes (can be) made in C++. Previously named `Code` <Bugfix> This is a fix for a bug (or closes open issue) astyled astyled PR, label is assigned by github actions json-styled JSON lint passed, label assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Apr 21, 2024
@katemonster33
Copy link
Contributor

katemonster33 commented Apr 22, 2024

I can't verify whether the Android issue is fixed by this branch as my phone appears unaffected - I have pulled the commit to my master branch and created an experimental Android build, it can be found here https://github.com/katemonster33/Cataclysm-DDA/releases/tag/cdda-experimental-2024-04-22-0254 anyone with an Android device affected by #73052 should give this a try

Anyway, I tested this on Windows, did not notice any regressions on the keybindings UI.

@Maleclypse Maleclypse merged commit a60d305 into CleverRaven:master Apr 22, 2024
24 of 28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Info / User Interface Game - player communication, menus, etc. json-styled JSON lint passed, label assigned by github actions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants