From 3448fe6c710e0d502193b3b26e22ad0d1a86ddc9 Mon Sep 17 00:00:00 2001 From: kobewi Date: Tue, 11 Feb 2025 14:51:09 +0100 Subject: [PATCH] Split repeated translation for floating windows --- editor/plugins/script_editor_plugin.cpp | 2 +- editor/plugins/shader_editor_plugin.cpp | 2 +- editor/window_wrapper.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp index 8461d837e6..afad65787b 100644 --- a/editor/plugins/script_editor_plugin.cpp +++ b/editor/plugins/script_editor_plugin.cpp @@ -4398,7 +4398,7 @@ ScriptEditor::ScriptEditor(WindowWrapper *p_wrapper) { make_floating->connect("request_open_in_screen", callable_mp(window_wrapper, &WindowWrapper::enable_window_on_screen).bind(true)); if (!make_floating->is_disabled()) { // Override default ScreenSelect tooltip if multi-window support is available. - make_floating->set_tooltip_text(TTR("Make the script editor floating.\nRight-click to open the screen selector.")); + make_floating->set_tooltip_text(TTR("Make the script editor floating.") + "\n" + TTR("Right-click to open the screen selector.")); } menu_hb->add_child(make_floating); diff --git a/editor/plugins/shader_editor_plugin.cpp b/editor/plugins/shader_editor_plugin.cpp index 766bbac86b..6e7f984f43 100644 --- a/editor/plugins/shader_editor_plugin.cpp +++ b/editor/plugins/shader_editor_plugin.cpp @@ -813,7 +813,7 @@ ShaderEditorPlugin::ShaderEditorPlugin() { make_floating->connect("request_open_in_screen", callable_mp(window_wrapper, &WindowWrapper::enable_window_on_screen).bind(true)); if (!make_floating->is_disabled()) { // Override default ScreenSelect tooltip if multi-window support is available. - make_floating->set_tooltip_text(TTR("Make the shader editor floating.\nRight-click to open the screen selector.")); + make_floating->set_tooltip_text(TTR("Make the shader editor floating.") + "\n" + TTR("Right-click to open the screen selector.")); } menu_hb->add_child(make_floating); diff --git a/editor/window_wrapper.cpp b/editor/window_wrapper.cpp index 4d82df70db..89ada709ea 100644 --- a/editor/window_wrapper.cpp +++ b/editor/window_wrapper.cpp @@ -489,7 +489,7 @@ ScreenSelect::ScreenSelect() { set_disabled(true); set_tooltip_text(EditorNode::get_singleton()->get_multiwindow_support_tooltip_text()); } else { - set_tooltip_text(TTR("Make this panel floating.\nRight-click to open the screen selector.")); + set_tooltip_text(TTR("Make this panel floating.") + "\n" + TTR("Right-click to open the screen selector.")); } // Create the popup.