mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-22 01:54:21 +00:00
Misc comments + Demo: use IsItemVisible() when using direct ImDrawList calls.
This commit is contained in:
parent
65c4c0a490
commit
74f02703e6
3 changed files with 52 additions and 45 deletions
|
|
@ -6887,7 +6887,7 @@ bool ImGui::BeginMenuEx(const char* label, const char* icon, bool enabled)
|
|||
bool menu_is_open = IsPopupOpen(id, ImGuiPopupFlags_None);
|
||||
|
||||
// Sub-menus are ChildWindow so that mouse can be hovering across them (otherwise top-most popup menu would steal focus and not allow hovering on parent menu)
|
||||
// The first menu in a hierarchy isn't so hovering doesn't get accross (otherwise e.g. resizing borders with ImGuiButtonFlags_FlattenChildren would react), but top-most BeginMenu() will bypass that limitation.
|
||||
// The first menu in a hierarchy isn't so hovering doesn't get across (otherwise e.g. resizing borders with ImGuiButtonFlags_FlattenChildren would react), but top-most BeginMenu() will bypass that limitation.
|
||||
ImGuiWindowFlags flags = ImGuiWindowFlags_ChildMenu | ImGuiWindowFlags_AlwaysAutoResize | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoSavedSettings | ImGuiWindowFlags_NoNavFocus;
|
||||
if (window->Flags & ImGuiWindowFlags_ChildMenu)
|
||||
flags |= ImGuiWindowFlags_ChildWindow;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue