diff options
| author | Jeremy Rimpo <jeremy.rimpo@servermonkey.com> | 2023-09-23 19:00:41 -0500 |
|---|---|---|
| committer | Jeremy Rimpo <jeremy.rimpo@servermonkey.com> | 2023-09-23 19:00:41 -0500 |
| commit | e22331fa0305d8a0a2b8b6d37203dac1ed3524e9 (patch) | |
| tree | 3231affb718494c342fc6197bae2b784fde9fd21 /src/modinforegular.cpp | |
| parent | 31a85a3db5fcb34b36dc6ed6f56a351a5dcb319a (diff) | |
Restructure category refresh action
- Remove plugins class
- Route signals to run Nexus API call from MainWindow
- Pass Dialog instance to route response data
- Revert CategoryFactory::instance to return reference
Diffstat (limited to 'src/modinforegular.cpp')
| -rw-r--r-- | src/modinforegular.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/modinforegular.cpp b/src/modinforegular.cpp index 58590477..c79fc574 100644 --- a/src/modinforegular.cpp +++ b/src/modinforegular.cpp @@ -213,7 +213,7 @@ void ModInfoRegular::readMeta() continue; } if (ok && (categoryID != 0) && - (CategoryFactory::instance()->categoryExists(categoryID))) { + (CategoryFactory::instance().categoryExists(categoryID))) { m_Categories.insert(categoryID); if (iter == categories.begin()) { m_PrimaryCategory = categoryID; @@ -578,7 +578,7 @@ void ModInfoRegular::setInstallationFile(const QString& fileName) void ModInfoRegular::addNexusCategory(int categoryID) { - m_Categories.insert(CategoryFactory::instance()->resolveNexusID(categoryID)); + m_Categories.insert(CategoryFactory::instance().resolveNexusID(categoryID)); } void ModInfoRegular::setIsEndorsed(bool endorsed) @@ -734,15 +734,15 @@ QString ModInfoRegular::getDescription() const const std::set<int>& categories = getCategories(); std::wostringstream categoryString; categoryString << ToWString(tr("Categories: <br>")); - CategoryFactory* categoryFactory = CategoryFactory::instance(); + CategoryFactory& categoryFactory = CategoryFactory::instance(); for (std::set<int>::const_iterator catIter = categories.begin(); catIter != categories.end(); ++catIter) { if (catIter != categories.begin()) { categoryString << " , "; } categoryString << "<span style=\"white-space: nowrap;\"><i>" - << ToWString(categoryFactory->getCategoryName( - categoryFactory->getCategoryIndex(*catIter))) + << ToWString(categoryFactory.getCategoryName( + categoryFactory.getCategoryIndex(*catIter))) << "</font></span>"; } |
