From db158a5735e18442f76118f1f6a060e6c3680e33 Mon Sep 17 00:00:00 2001 From: flow Date: Sat, 10 Sep 2022 18:49:00 -0300 Subject: [PATCH] feat: add image support for mod pages Signed-off-by: flow --- launcher/ui/pages/modplatform/ModPage.ui | 9 ++++++++- launcher/ui/pages/modplatform/flame/FlameModPage.cpp | 2 ++ .../ui/pages/modplatform/modrinth/ModrinthModPage.cpp | 2 ++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/launcher/ui/pages/modplatform/ModPage.ui b/launcher/ui/pages/modplatform/ModPage.ui index afcd9bb7f..943f02aa2 100644 --- a/launcher/ui/pages/modplatform/ModPage.ui +++ b/launcher/ui/pages/modplatform/ModPage.ui @@ -14,7 +14,7 @@ - + true @@ -98,6 +98,13 @@ + + + ProjectDescriptionPage + QTextBrowser +
ui/widgets/ProjectDescriptionPage.h
+
+
searchEdit searchButton diff --git a/launcher/ui/pages/modplatform/flame/FlameModPage.cpp b/launcher/ui/pages/modplatform/flame/FlameModPage.cpp index 772fd2e07..b497d1fee 100644 --- a/launcher/ui/pages/modplatform/flame/FlameModPage.cpp +++ b/launcher/ui/pages/modplatform/flame/FlameModPage.cpp @@ -59,6 +59,8 @@ FlameModPage::FlameModPage(ModDownloadDialog* dialog, BaseInstance* instance) connect(ui->packView->selectionModel(), &QItemSelectionModel::currentChanged, this, &FlameModPage::onSelectionChanged); connect(ui->versionSelectionBox, &QComboBox::currentTextChanged, this, &FlameModPage::onVersionSelectionChanged); connect(ui->modSelectionButton, &QPushButton::clicked, this, &FlameModPage::onModSelected); + + ui->packDescription->setMetaEntry(metaEntryBase()); } auto FlameModPage::validateVersion(ModPlatform::IndexedVersion& ver, QString mineVer, ModAPI::ModLoaderTypes loaders) const -> bool diff --git a/launcher/ui/pages/modplatform/modrinth/ModrinthModPage.cpp b/launcher/ui/pages/modplatform/modrinth/ModrinthModPage.cpp index 5fa00b9b4..62e417c8a 100644 --- a/launcher/ui/pages/modplatform/modrinth/ModrinthModPage.cpp +++ b/launcher/ui/pages/modplatform/modrinth/ModrinthModPage.cpp @@ -59,6 +59,8 @@ ModrinthModPage::ModrinthModPage(ModDownloadDialog* dialog, BaseInstance* instan connect(ui->packView->selectionModel(), &QItemSelectionModel::currentChanged, this, &ModrinthModPage::onSelectionChanged); connect(ui->versionSelectionBox, &QComboBox::currentTextChanged, this, &ModrinthModPage::onVersionSelectionChanged); connect(ui->modSelectionButton, &QPushButton::clicked, this, &ModrinthModPage::onModSelected); + + ui->packDescription->setMetaEntry(metaEntryBase()); } auto ModrinthModPage::validateVersion(ModPlatform::IndexedVersion& ver, QString mineVer, ModAPI::ModLoaderTypes loaders) const -> bool