mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-23 04:17:00 +00:00
Begin: Tidying up code to make it more readable.
This commit is contained in:
parent
28bbf1ade6
commit
02e0a078f4
@ -4409,8 +4409,11 @@ bool ImGui::Begin(const char* name, bool* p_open, ImGuiWindowFlags flags)
|
|||||||
{
|
{
|
||||||
// Initialize
|
// Initialize
|
||||||
window->ParentWindow = parent_window;
|
window->ParentWindow = parent_window;
|
||||||
window->RootWindow = ((flags & ImGuiWindowFlags_ChildWindow) && parent_window) ? parent_window->RootWindow : window;
|
window->RootWindow = window->RootNonPopupWindow = window;
|
||||||
window->RootNonPopupWindow = !(flags & (ImGuiWindowFlags_ChildWindow | ImGuiWindowFlags_Popup)) || (flags & ImGuiWindowFlags_Modal) || (parent_window == NULL) ? window : parent_window->RootNonPopupWindow; // Used to display TitleBgActive color and for selecting which window to use for NavWindowing
|
if (parent_window && (flags & ImGuiWindowFlags_ChildWindow))
|
||||||
|
window->RootWindow = parent_window->RootWindow;
|
||||||
|
if (parent_window && !(flags & ImGuiWindowFlags_Modal) && (flags & (ImGuiWindowFlags_ChildWindow | ImGuiWindowFlags_Popup)))
|
||||||
|
window->RootNonPopupWindow = parent_window->RootNonPopupWindow;
|
||||||
//window->RootNavWindow = window;
|
//window->RootNavWindow = window;
|
||||||
//while (window->RootNavWindow->Flags & ImGuiWindowFlags_NavFlattened)
|
//while (window->RootNavWindow->Flags & ImGuiWindowFlags_NavFlattened)
|
||||||
// window->RootNavWindow = window->RootNavWindow->ParentWindow;
|
// window->RootNavWindow = window->RootNavWindow->ParentWindow;
|
||||||
|
Loading…
Reference in New Issue
Block a user