mirror of https://github.com/godotengine/godot
Merge pull request #100745 from mdelorme/mdelorme/issue_100727
Assign the project manager title to the node instead of DisplayServer
This commit is contained in:
commit
01c6e18963
|
|
@ -1139,7 +1139,7 @@ ProjectManager::ProjectManager() {
|
||||||
}
|
}
|
||||||
|
|
||||||
// TRANSLATORS: This refers to the application where users manage their Godot projects.
|
// TRANSLATORS: This refers to the application where users manage their Godot projects.
|
||||||
DisplayServer::get_singleton()->window_set_title(VERSION_NAME + String(" - ") + TTR("Project Manager", "Application"));
|
SceneTree::get_singleton()->get_root()->set_title(VERSION_NAME + String(" - ") + TTR("Project Manager", "Application"));
|
||||||
|
|
||||||
SceneTree::get_singleton()->get_root()->connect("files_dropped", callable_mp(this, &ProjectManager::_files_dropped));
|
SceneTree::get_singleton()->get_root()->connect("files_dropped", callable_mp(this, &ProjectManager::_files_dropped));
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -282,11 +282,13 @@ void Window::set_title(const String &p_title) {
|
||||||
|
|
||||||
title = p_title;
|
title = p_title;
|
||||||
tr_title = atr(p_title);
|
tr_title = atr(p_title);
|
||||||
|
|
||||||
#ifdef DEBUG_ENABLED
|
#ifdef DEBUG_ENABLED
|
||||||
if (window_id == DisplayServer::MAIN_WINDOW_ID) {
|
if (window_id == DisplayServer::MAIN_WINDOW_ID && !Engine::get_singleton()->is_project_manager_hint()) {
|
||||||
// Append a suffix to the window title to denote that the project is running
|
// Append a suffix to the window title to denote that the project is running
|
||||||
// from a debug build (including the editor). Since this results in lower performance,
|
// from a debug build (including the editor, excluding the project manager).
|
||||||
// this should be clearly presented to the user.
|
// Since this results in lower performance, this should be clearly presented
|
||||||
|
// to the user.
|
||||||
tr_title = vformat("%s (DEBUG)", tr_title);
|
tr_title = vformat("%s (DEBUG)", tr_title);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -1435,10 +1437,11 @@ void Window::_notification(int p_what) {
|
||||||
|
|
||||||
tr_title = atr(title);
|
tr_title = atr(title);
|
||||||
#ifdef DEBUG_ENABLED
|
#ifdef DEBUG_ENABLED
|
||||||
if (window_id == DisplayServer::MAIN_WINDOW_ID) {
|
if (window_id == DisplayServer::MAIN_WINDOW_ID && !Engine::get_singleton()->is_project_manager_hint()) {
|
||||||
// Append a suffix to the window title to denote that the project is running
|
// Append a suffix to the window title to denote that the project is running
|
||||||
// from a debug build (including the editor). Since this results in lower performance,
|
// from a debug build (including the editor, excluding the project manager).
|
||||||
// this should be clearly presented to the user.
|
// Since this results in lower performance, this should be clearly presented
|
||||||
|
// to the user.
|
||||||
tr_title = vformat("%s (DEBUG)", tr_title);
|
tr_title = vformat("%s (DEBUG)", tr_title);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue