diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2022-11-24 13:24:14 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2022-11-24 13:24:14 +0100 |
commit | 53a8903f793489fa0adf0b5e3976f79703407592 (patch) | |
tree | 3ad2f33359ce279c97f4520fdeef77ad0ad68c19 | |
parent | f16c5b564b569497d04deb965a4fd63b3ea2ab2f (diff) | |
parent | 4fdfc5176c0ee0c55b7ed88aaaeda143efe4a3cb (diff) |
Merge pull request #68283 from zaevi/fix_float_dock_title
[Editor] Fix float dock shows incorrect title.
-rw-r--r-- | editor/editor_node.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index f277bf6467..995cfb138c 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -4437,6 +4437,7 @@ void EditorNode::_dock_floating_close_request(Control *p_control) { dock_slot[window_slot]->add_child(p_control); dock_slot[window_slot]->move_child(p_control, MIN((int)window->get_meta("dock_index"), dock_slot[window_slot]->get_tab_count())); dock_slot[window_slot]->set_current_tab(window->get_meta("dock_index")); + dock_slot[window_slot]->set_tab_title(dock_slot[window_slot]->get_tab_idx_from_control(p_control), TTRGET(p_control->get_name())); window->queue_free(); @@ -4460,7 +4461,7 @@ void EditorNode::_dock_make_float() { dock_slot[dock_popup_selected_idx]->remove_child(dock); Window *window = memnew(Window); - window->set_title(dock->get_name()); + window->set_title(TTRGET(dock->get_name())); Panel *p = memnew(Panel); p->add_theme_style_override("panel", gui_base->get_theme_stylebox(SNAME("PanelForeground"), SNAME("EditorStyles"))); p->set_anchors_and_offsets_preset(Control::PRESET_FULL_RECT); |