1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-12 13:20:55 +00:00

Hide non-functional "Show in File Manager" buttons in Android/web editor

The editor filesystem isn't readily accessible by OS applications
on those platforms.
This commit is contained in:
Hugo Locurcio
2023-01-15 22:50:40 +01:00
parent 1033dfcb3d
commit 1108594e66
3 changed files with 28 additions and 3 deletions

View File

@@ -1503,8 +1503,13 @@ void ProjectList::create_project_item_control(int p_index) {
path_hb->add_child(show);
if (!item.missing) {
#if !defined(ANDROID_ENABLED) && !defined(WEB_ENABLED)
show->connect("pressed", callable_mp(this, &ProjectList::_show_project).bind(item.path));
show->set_tooltip_text(TTR("Show in File Manager"));
#else
// Opening the system file manager is not supported on the Android and web editors.
show->hide();
#endif
} else {
show->set_tooltip_text(TTR("Error: Project is missing on the filesystem."));
}