Navigation: Can nav-out but not nav-in a window with ImGuiWindowFlags_NoNav flag (#323)

This commit is contained in:
ocornut
2016-07-24 14:41:27 +02:00
parent 67feb5ac6c
commit 175f42420c
2 changed files with 5 additions and 6 deletions

View File

@ -735,6 +735,7 @@ public:
ImRect TitleBarRect() const { return ImRect(Pos, ImVec2(Pos.x + SizeFull.x, Pos.y + TitleBarHeight())); }
float MenuBarHeight() const { return (Flags & ImGuiWindowFlags_MenuBar) ? CalcFontSize() + GImGui->Style.FramePadding.y * 2.0f : 0.0f; }
ImRect MenuBarRect() const { float y1 = Pos.y + TitleBarHeight(); return ImRect(Pos.x, y1, Pos.x + SizeFull.x, y1 + MenuBarHeight()); }
bool IsNavigableTo() const { return Active && this == this->RootNonPopupWindow && (!(Flags & ImGuiWindowFlags_NoNav) || this == GImGui->FocusedWindow); }
};
//-----------------------------------------------------------------------------