Skip to content

Commit 5f62290

Browse files
committed
Merge pull request godotengine#109525 from bruvzg/res_link_target
Show symlink target in the resource tooltip.
2 parents 9023f65 + 90da041 commit 5f62290

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

editor/inspector/editor_resource_tooltip_plugins.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,12 @@ VBoxContainer *EditorResourceTooltipPlugin::make_default_tooltip(const String &p
8585
Label *label = memnew(Label(vformat(TTR("Type: %s"), type)));
8686
vb->add_child(label);
8787
}
88+
89+
Ref<DirAccess> da = DirAccess::create(DirAccess::ACCESS_RESOURCES);
90+
if (da->is_link(p_resource_path)) {
91+
Label *link = memnew(Label(vformat(TTR("Link to: %s"), da->read_link(p_resource_path))));
92+
vb->add_child(link);
93+
}
8894
return vb;
8995
}
9096

0 commit comments

Comments
 (0)