From 42eb265624cb4a6461dc203a5ebfcb35ddd5d730 Mon Sep 17 00:00:00 2001 From: flow Date: Sun, 21 Aug 2022 10:50:10 -0300 Subject: refactor: create mod pages and filter widget by factory methods This takes most expensive operations out of the constructors. Signed-off-by: flow --- launcher/ui/pages/modplatform/flame/FlameModPage.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'launcher/ui/pages/modplatform/flame') diff --git a/launcher/ui/pages/modplatform/flame/FlameModPage.h b/launcher/ui/pages/modplatform/flame/FlameModPage.h index 445d0368..2cd484cb 100644 --- a/launcher/ui/pages/modplatform/flame/FlameModPage.h +++ b/launcher/ui/pages/modplatform/flame/FlameModPage.h @@ -44,7 +44,12 @@ class FlameModPage : public ModPage { Q_OBJECT public: - explicit FlameModPage(ModDownloadDialog* dialog, BaseInstance* instance); + static FlameModPage* create(ModDownloadDialog* dialog, BaseInstance* instance) + { + return ModPage::create(dialog, instance); + } + + FlameModPage(ModDownloadDialog* dialog, BaseInstance* instance); ~FlameModPage() override = default; inline auto displayName() const -> QString override { return "CurseForge"; } -- cgit