MCPcopy Create free account
hub / github.com/Raais/ImStudio / BringWindowToDisplayFront

Method BringWindowToDisplayFront

src/third-party/imgui/imgui.cpp:6669–6682  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6667}
6668
6669void ImGui::BringWindowToDisplayFront(ImGuiWindow* window)
6670{
6671 ImGuiContext& g = *GImGui;
6672 ImGuiWindow* current_front_window = g.Windows.back();
6673 if (current_front_window == window || current_front_window->RootWindow == window) // Cheap early out (could be better)
6674 return;
6675 for (int i = g.Windows.Size - 2; i >= 0; i--) // We can ignore the top-most window
6676 if (g.Windows[i] == window)
6677 {
6678 memmove(&g.Windows[i], &g.Windows[i + 1], (size_t)(g.Windows.Size - i - 1) * sizeof(ImGuiWindow*));
6679 g.Windows[g.Windows.Size - 1] = window;
6680 break;
6681 }
6682}
6683
6684void ImGui::BringWindowToDisplayBack(ImGuiWindow* window)
6685{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected