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

Fixing ImGUi keybindings screen processing keys pressed before it was shown #72800

Merged

Conversation

katemonster33
Copy link
Contributor

@katemonster33 katemonster33 commented Apr 2, 2024

Summary

Bugfixes "fixed issue where ImGui processes input that happens with no ImGui screens visible"

Purpose of change

Fixes: #72447

Describe the solution

When no ImGui screens are visible, do not process any input into ImGui.

Describe alternatives you've considered

We could have some sort of boolean that is updated whenever a ui_adaptor is created or destroyed that determines if any ImGui screen is in the ui_adaptor list. That's more complex and has more moving parts than this.

Testing

Perform the sequence of inputs mentioned in the linked issue and verify the extra inputs are not sent to the keybindings screen

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) json-styled JSON lint passed, label assigned by github actions astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Apr 2, 2024
@katemonster33 katemonster33 force-pushed the imgui_input_when_no_window_shown branch from 097d099 to 4340210 Compare April 3, 2024 15:11
@katemonster33 katemonster33 force-pushed the imgui_input_when_no_window_shown branch from 4340210 to 0e01e26 Compare April 4, 2024 17:51
@I-am-Erk
Copy link
Member

I-am-Erk commented Apr 4, 2024

This one definitely adds a back door for you to steal credit card information but I'll allow it this once, just use it wisely.

@I-am-Erk I-am-Erk merged commit 373238f into CleverRaven:master Apr 4, 2024
24 of 28 checks passed
SurFlurer added a commit to SurFlurer/Cataclysm-DDA that referenced this pull request Aug 26, 2024
…_input_when_no_window_shown"

This reverts commit 373238f, reversing
changes made to 210e5b1.
this
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.

ImGui: sometimes stores keys and presses them in the wrong order
2 participants