mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-27 02:40:05 +00:00
parent
3b3af6b731
commit
615e9ae345
2 changed files with 14 additions and 4 deletions
|
|
@ -7289,6 +7289,11 @@ bool ImGui::TabItemEx(ImGuiTabBar* tab_bar, const char* label, bool* p_open,
|
|||
tab_bar->NextSelectedTabId = id;
|
||||
hovered |= (g.HoveredId == id);
|
||||
|
||||
// Transfer active id window so the active id is not owned by the dock host (as StartMouseMovingWindow()
|
||||
// will only do it on the drag). This allows FocusWindow() to be more conservative in how it clears active id.
|
||||
if (held && docked_window && g.ActiveId == id && g.ActiveIdIsJustActivated)
|
||||
g.ActiveIdWindow = docked_window;
|
||||
|
||||
// Allow the close button to overlap unless we are dragging (in which case we don't want any overlapping tabs to be hovered)
|
||||
if (!held)
|
||||
SetItemAllowOverlap();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue