@ -17218,11 +17218,12 @@ void ImGui::SetWindowDock(ImGuiWindow* window, ImGuiID dock_id, ImGuiCond cond)
// Create an explicit dockspace node within an existing window. Also expose dock node flags and creates a CentralNode by default.
// The Central Node is always displayed even when empty and shrink/extend according to the requested size of its neighbors.
// DockSpace() needs to be submitted _before_ any window they can host. If you use a dockspace, submit it early in your app.
// When ImGuiDockNodeFlags_KeepAliveOnly is set, nothing is submitted in the current window (function may be called from any location).
ImGuiID ImGui : : DockSpace ( ImGuiID id , const ImVec2 & size_arg , ImGuiDockNodeFlags flags , const ImGuiWindowClass * window_class )
{
ImGuiContext * ctx = GImGui ;
ImGuiContext & g = * ctx ;
ImGuiWindow * window = GetCurrentWindow ( ) ;
ImGuiWindow * window = GetCurrentWindowRead ( ) ;
if ( ! ( g . IO . ConfigFlags & ImGuiConfigFlags_DockingEnable ) )
return 0 ;
@ -17231,6 +17232,8 @@ ImGuiID ImGui::DockSpace(ImGuiID id, const ImVec2& size_arg, ImGuiDockNodeFlags
// If for whichever reason this is causing problem we would need to ensure that DockNodeUpdateTabBar() ends up clearing NextSelectedTabId even if SkipItems=true.
if ( window - > SkipItems )
flags | = ImGuiDockNodeFlags_KeepAliveOnly ;
if ( ( flags & ImGuiDockNodeFlags_KeepAliveOnly ) = = 0 )
window = GetCurrentWindow ( ) ; // call to set window->WriteAccessed = true;
IM_ASSERT ( ( flags & ImGuiDockNodeFlags_DockSpace ) = = 0 ) ;
IM_ASSERT ( id ! = 0 ) ;