Menus: fixed top-level menu from not consistently using style.PopupRounding. (#4788)

+ Stack tool default size.
This commit is contained in:
ocornut
2021-12-21 15:05:10 +01:00
parent 4bad852a78
commit 612b787b0d
3 changed files with 6 additions and 1 deletions

View File

@ -12530,6 +12530,9 @@ void ImGui::DebugHookIdInfo(ImGuiID id, ImGuiDataType data_type, const void* dat
// Stack Tool: Display UI
void ImGui::ShowStackToolWindow(bool* p_open)
{
ImGuiContext& g = *GImGui;
if (!(g.NextWindowData.Flags & ImGuiNextWindowDataFlags_HasSize))
SetNextWindowSize(ImVec2(0.0f, GetFontSize() * 8.0f), ImGuiCond_FirstUseEver);
if (!Begin("Dear ImGui Stack Tool", p_open) || GetCurrentWindow()->BeginCount > 1)
{
End();
@ -12537,7 +12540,6 @@ void ImGui::ShowStackToolWindow(bool* p_open)
}
// Display hovered/active status
ImGuiContext& g = *GImGui;
const ImGuiID hovered_id = g.HoveredIdPreviousFrame;
const ImGuiID active_id = g.ActiveId;
#ifdef IMGUI_ENABLE_TEST_ENGINE