summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 92127e0a..4294904e 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -2868,13 +2868,18 @@ void MainWindow::createSeparator_clicked()
{
return;
}
- int newPriority;
- if (m_ContextRow >= 0) {
+
+ int newPriority = -1;
+ if (m_ContextRow >= 0 && m_ModListSortProxy->sortColumn() == ModList::COL_PRIORITY)
+ {
newPriority = m_OrganizerCore.currentProfile()->getModPriority(m_ContextRow);
}
+
if (m_OrganizerCore.createMod(name) == nullptr) { return; }
m_OrganizerCore.refreshModList();
- if (m_ContextRow >= 0 && newPriority >= 0) {
+
+ if (newPriority >= 0)
+ {
m_OrganizerCore.modList()->changeModPriority(ModInfo::getIndex(name), newPriority);
}
}