From 9de07de46784c479fd32f6867eee3692f911693d Mon Sep 17 00:00:00 2001 From: Gagah Pangeran Rosfatiputra Date: Tue, 25 May 2021 12:14:07 +0700 Subject: [PATCH] move text flow container inside markdown container --- .../Overlays/Wiki/Markdown/WikiMarkdownContainer.cs | 6 ++++++ .../Wiki/Markdown/WikiMarkdownTextFlowContainer.cs | 13 ------------- 2 files changed, 6 insertions(+), 13 deletions(-) delete mode 100644 osu.Game/Overlays/Wiki/Markdown/WikiMarkdownTextFlowContainer.cs diff --git a/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownContainer.cs b/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownContainer.cs index 81115293d4..d4ad0bee4d 100644 --- a/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownContainer.cs +++ b/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownContainer.cs @@ -3,6 +3,7 @@ using Markdig.Extensions.Yaml; using Markdig.Syntax; +using Markdig.Syntax.Inlines; using osu.Framework.Graphics.Containers; using osu.Framework.Graphics.Containers.Markdown; using osu.Game.Graphics.Containers.Markdown; @@ -35,5 +36,10 @@ namespace osu.Game.Overlays.Wiki.Markdown protected override MarkdownParagraph CreateParagraph(ParagraphBlock paragraphBlock, int level) => new WikiMarkdownParagraph(paragraphBlock); protected virtual FillFlowContainer CreateNotice(YamlFrontMatterBlock yamlFrontMatterBlock) => new WikiNoticeContainer(yamlFrontMatterBlock); + + private class WikiMarkdownTextFlowContainer : OsuMarkdownTextFlowContainer + { + protected override void AddImage(LinkInline linkInline) => AddDrawable(new WikiMarkdownImage(linkInline)); + } } } diff --git a/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownTextFlowContainer.cs b/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownTextFlowContainer.cs deleted file mode 100644 index 1c2b37a219..0000000000 --- a/osu.Game/Overlays/Wiki/Markdown/WikiMarkdownTextFlowContainer.cs +++ /dev/null @@ -1,13 +0,0 @@ -// Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. -// See the LICENCE file in the repository root for full licence text. - -using Markdig.Syntax.Inlines; -using osu.Game.Graphics.Containers.Markdown; - -namespace osu.Game.Overlays.Wiki.Markdown -{ - public class WikiMarkdownTextFlowContainer : OsuMarkdownTextFlowContainer - { - protected override void AddImage(LinkInline linkInline) => AddDrawable(new WikiMarkdownImage(linkInline)); - } -}