diff options
Diffstat (limited to 'src/ui/helpers.cpp')
| -rw-r--r-- | src/ui/helpers.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ui/helpers.cpp b/src/ui/helpers.cpp index 7bde384..6ca1bd2 100644 --- a/src/ui/helpers.cpp +++ b/src/ui/helpers.cpp @@ -59,6 +59,7 @@ int TextInputWithAutocomplete(const char* label, const char* hint, char* buffer, for (int i = 0; i < suggestion_count; ++i) { + ImGui::PushID(i); if (ImGui::Selectable(suggestions[i])) { // Copy selected suggestion to buffer @@ -67,6 +68,7 @@ int TextInputWithAutocomplete(const char* label, const char* hint, char* buffer, result = i; is_open = false; } + ImGui::PopID(); } ImGui::EndChild(); |
