summaryrefslogtreecommitdiff
path: root/src/modlist.cpp
diff options
context:
space:
mode:
authorMikaƫl Capelle <capelle.mikael@gmail.com>2021-01-14 09:11:52 +0100
committerGitHub <noreply@github.com>2021-01-14 09:11:52 +0100
commit899308b31d541e78a3e4395bf33cd66c5ec4f769 (patch)
treee360f819bbe96e7cc30626a53395c466967e8e0f /src/modlist.cpp
parent34f7ae24501f75d5a74a09b6af939db6edaf6f1c (diff)
parent853db4a60a0a701b92d3eb7be7c3a0d8d8f6f2b1 (diff)
Merge pull request #1360 from Holt59/organizercore-cleaning
OrganizerCore cleaning.
Diffstat (limited to 'src/modlist.cpp')
-rw-r--r--src/modlist.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/modlist.cpp b/src/modlist.cpp
index f820e4d1..1c097db4 100644
--- a/src/modlist.cpp
+++ b/src/modlist.cpp
@@ -900,7 +900,18 @@ QStringList ModList::allModsByProfilePriority(MOBase::IProfile* profile) const
{
Profile* mo2Profile = profile == nullptr ?
m_Organizer->currentProfile() : static_cast<Profile*>(profile);
- return m_Organizer->modsSortedByProfilePriority(mo2Profile);
+
+ QStringList res;
+ for (int i = mo2Profile->getPriorityMinimum();
+ i < mo2Profile->getPriorityMinimum() + (int)mo2Profile->numRegularMods();
+ ++i) {
+ int modIndex = mo2Profile->modIndexByPriority(i);
+ auto modInfo = ModInfo::getByIndex(modIndex);
+ if (!modInfo->isBackup() && !modInfo->isOverwrite()) {
+ res.push_back(modInfo->internalName());
+ }
+ }
+ return res;
}
MOBase::IModInterface* ModList::getMod(const QString& name) const