浏览代码

Fixed calling SetNextTreeNodeOpen() on a collapsed window leaking to next frame.

omar 7 年之前
父节点
当前提交
97bf2131e2
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      imgui.cpp

+ 2 - 0
imgui.cpp

@@ -6472,6 +6472,8 @@ float ImGui::GetTreeNodeToLabelSpacing()
 void ImGui::SetNextTreeNodeOpen(bool is_open, ImGuiCond cond)
 {
     ImGuiContext& g = *GImGui;
+    if (g.CurrentWindow->SkipItems)
+        return;
     g.SetNextTreeNodeOpenVal = is_open;
     g.SetNextTreeNodeOpenCond = cond ? cond : ImGuiCond_Always;
 }