MCPcopy Create free account
hub / github.com/Aegel5/SimpleSwitcher / DockContextEndFrame

Method DockContextEndFrame

imgui_tiny_app/imgui/imgui.cpp:17995–18009  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17993}
17994
17995void ImGui::DockContextEndFrame(ImGuiContext* ctx)
17996{
17997 // Draw backgrounds of node missing their window
17998 ImGuiContext& g = *ctx;
17999 ImGuiDockContext* dc = &g.DockContext;
18000 for (int n = 0; n < dc->Nodes.Data.Size; n++)
18001 if (ImGuiDockNode* node = (ImGuiDockNode*)dc->Nodes.Data[n].val_p)
18002 if (node->LastFrameActive == g.FrameCount && node->IsVisible && node->HostWindow && node->IsLeafNode() && !node->IsBgDrawnThisFrame)
18003 {
18004 ImRect bg_rect(node->Pos + ImVec2(0.0f, GetFrameHeight()), node->Pos + node->Size);
18005 ImDrawFlags bg_rounding_flags = CalcRoundingFlagsForRectInRect(bg_rect, node->HostWindow->Rect(), g.Style.DockingSeparatorSize);
18006 node->HostWindow->DrawList->ChannelsSetCurrent(DOCKING_HOST_DRAW_CHANNEL_BG);
18007 node->HostWindow->DrawList->AddRectFilled(bg_rect.Min, bg_rect.Max, node->LastBgColor, node->HostWindow->WindowRounding, bg_rounding_flags);
18008 }
18009}
18010
18011ImGuiDockNode* ImGui::DockContextFindNodeByID(ImGuiContext* ctx, ImGuiID id)
18012{

Callers

nothing calls this directly

Calls 3

ImVec2Function · 0.85
ChannelsSetCurrentMethod · 0.80
AddRectFilledMethod · 0.80

Tested by

no test coverage detected