mirror of https://github.com/ppy/osu
Fix comment markdown image not showing tooltips
This commit is contained in:
parent
2b19cf6ce4
commit
dc2d574965
|
@ -64,7 +64,7 @@ public void TestComment(string description, string text)
|
||||||
new[] { "Plain", "This is plain comment" },
|
new[] { "Plain", "This is plain comment" },
|
||||||
new[] { "Pinned", "This is pinned comment" },
|
new[] { "Pinned", "This is pinned comment" },
|
||||||
new[] { "Link", "Please visit https://osu.ppy.sh" },
|
new[] { "Link", "Please visit https://osu.ppy.sh" },
|
||||||
new[] { "Big Image", "![](Backgrounds/bg1)" },
|
new[] { "Big Image", "![](Backgrounds/bg1 \"Big Image\")" },
|
||||||
new[] { "Small Image", "![](Cursor/cursortrail)" },
|
new[] { "Small Image", "![](Cursor/cursortrail)" },
|
||||||
new[]
|
new[]
|
||||||
{
|
{
|
||||||
|
|
|
@ -51,12 +51,12 @@ protected override float GetFontSizeByLevel(int level)
|
||||||
|
|
||||||
private partial class CommentMarkdownTextFlowContainer : OsuMarkdownTextFlowContainer
|
private partial class CommentMarkdownTextFlowContainer : OsuMarkdownTextFlowContainer
|
||||||
{
|
{
|
||||||
protected override void AddImage(LinkInline linkInline) => AddDrawable(new CommentMarkdownImage(linkInline.Url));
|
protected override void AddImage(LinkInline linkInline) => AddDrawable(new CommentMarkdownImage(linkInline));
|
||||||
|
|
||||||
private partial class CommentMarkdownImage : MarkdownImage
|
private partial class CommentMarkdownImage : OsuMarkdownImage
|
||||||
{
|
{
|
||||||
public CommentMarkdownImage(string url)
|
public CommentMarkdownImage(LinkInline linkInline)
|
||||||
: base(url)
|
: base(linkInline)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue