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/modlistsortproxy.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/modlistsortproxy.cpp')
| -rw-r--r-- | src/modlistsortproxy.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/modlistsortproxy.cpp b/src/modlistsortproxy.cpp index e61f9494..704ec10b 100644 --- a/src/modlistsortproxy.cpp +++ b/src/modlistsortproxy.cpp @@ -171,11 +171,11 @@ bool ModListSortProxy::lessThan(const QModelIndex& left, const QModelIndex& righ lt = true; else { try { - CategoryFactory* categories = CategoryFactory::instance(); - QString leftCatName = categories->getCategoryName( - categories->getCategoryIndex(leftMod->primaryCategory())); - QString rightCatName = categories->getCategoryName( - categories->getCategoryIndex(rightMod->primaryCategory())); + CategoryFactory& categories = CategoryFactory::instance(); + QString leftCatName = categories.getCategoryName( + categories.getCategoryIndex(leftMod->primaryCategory())); + QString rightCatName = categories.getCategoryName( + categories.getCategoryIndex(rightMod->primaryCategory())); lt = leftCatName < rightCatName; } catch (const std::exception& e) { log::error("failed to compare categories: {}", e.what()); |
