Compare commits

...

2 Commits

Author SHA1 Message Date
blankie 283b5e9f4d
Make sure that disabled buttons cannot be activated 2023-03-08 08:40:18 +07:00
blankie 451c57f198
Update imgui 2023-03-08 08:38:28 +07:00
2 changed files with 3 additions and 3 deletions

View File

@ -54,7 +54,7 @@ bool ImGui::Button(const char* label, bool enabled) {
ImGui::BeginDisabled();
}
bool res = ImGui::Button(label);
bool res = ImGui::Button(label) && enabled;
if (!enabled) {
ImGui::EndDisabled();
@ -67,7 +67,7 @@ bool ImGui::ArrowButton(const char* label, ImGuiDir dir, bool enabled) {
ImGui::BeginDisabled();
}
bool res = ImGui::ArrowButton(label, dir);
bool res = ImGui::ArrowButton(label, dir) && enabled;
if (!enabled) {
ImGui::EndDisabled();

2
thirdparty/imgui vendored

@ -1 +1 @@
Subproject commit bfce7750b168b5a857b4379596236dda7b58bd39
Subproject commit c9a53aa74d84cdb6471651f7b3da14d7248d58c7