You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-02 16:48:55 +00:00
Show symlink target in the resource tooltip.
This commit is contained in:
@@ -81,6 +81,12 @@ VBoxContainer *EditorResourceTooltipPlugin::make_default_tooltip(const String &p
|
|||||||
Label *label = memnew(Label(vformat(TTR("Type: %s"), type)));
|
Label *label = memnew(Label(vformat(TTR("Type: %s"), type)));
|
||||||
vb->add_child(label);
|
vb->add_child(label);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Ref<DirAccess> da = DirAccess::create(DirAccess::ACCESS_RESOURCES);
|
||||||
|
if (da->is_link(p_resource_path)) {
|
||||||
|
Label *link = memnew(Label(vformat(TTR("Link to: %s"), da->read_link(p_resource_path))));
|
||||||
|
vb->add_child(link);
|
||||||
|
}
|
||||||
return vb;
|
return vb;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user