From 97638bf97745353fe79b638763bdaa84f7fe46c4 Mon Sep 17 00:00:00 2001 From: ocornut Date: Fri, 9 Jul 2021 17:18:23 +0200 Subject: [PATCH] BeginMenu: remove unnecessary call to ItemHoverable() which is already done by the Selectable() call. Amend 88d7b3de --- imgui_widgets.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/imgui_widgets.cpp b/imgui_widgets.cpp index 8692575a9..204817610 100644 --- a/imgui_widgets.cpp +++ b/imgui_widgets.cpp @@ -6858,7 +6858,7 @@ bool ImGui::BeginMenu(const char* label, bool enabled) PopStyleColor(); PopID(); - const bool hovered = enabled && ItemHoverable(window->DC.LastItemRect, id); + const bool hovered = (g.HoveredId == id) && enabled; if (menuset_is_open) g.NavWindow = backed_nav_window;