You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-31 18:41:20 +00:00
Merge pull request #113822 from kitbdev/fix-editor-distraction-free-sc-size
Fix distraction-free mode changing split offsets
This commit is contained in:
@@ -932,7 +932,9 @@ void EditorDockManager::set_docks_visible(bool p_show) {
|
||||
}
|
||||
docks_visible = p_show;
|
||||
for (int i = 0; i < DockConstants::DOCK_SLOT_BOTTOM; i++) {
|
||||
dock_slots[i].container->set_visible(docks_visible && dock_slots[i].container->get_tab_count() > 0);
|
||||
// Show and hide in reverse order due to the SplitContainer prioritizing the last split offset.
|
||||
TabContainer *container = dock_slots[docks_visible ? i : DockConstants::DOCK_SLOT_BOTTOM - i - 1].container;
|
||||
container->set_visible(docks_visible && container->get_tab_count() > 0);
|
||||
}
|
||||
_update_layout();
|
||||
}
|
||||
|
||||
@@ -993,7 +993,7 @@ void SplitContainer::_remove_valid_child(Control *p_control) {
|
||||
}
|
||||
// Only use desired sizes to change the split offset after the first time a child is removed.
|
||||
// This allows adding children to not affect the split offsets when creating.
|
||||
can_use_desired_sizes = valid_children.size() > 1u;
|
||||
can_use_desired_sizes = true;
|
||||
|
||||
_update_default_dragger_positions();
|
||||
queue_sort();
|
||||
|
||||
Reference in New Issue
Block a user