summaryrefslogtreecommitdiff
path: root/src/profile.cpp
diff options
context:
space:
mode:
authorTannin <devnull@localhost>2014-06-25 23:51:29 +0200
committerTannin <devnull@localhost>2014-06-25 23:51:29 +0200
commit5e7c875b29b2dcff44201d2b6cd6815b20fb3945 (patch)
tree18b5212b480b060a633d93322fe93f3b6fb5bd0c /src/profile.cpp
parentb2a7c7c223a10db31f34e7d870d9969fcf158246 (diff)
- test-plugins accidentally distributed in the 1.2.5 release are now automatically deleted
- some fixes to the tutorial (mostly wording but also some actual problems) - bugfix: could disable mods that aren't supposed to be disable-able - bugfix: mod list wasn't saved on some changes - bugfix: when trying to start directly to application, MO didn't start up correctly - bugfix: hook.dll didn't load mod bsas into its directory structure and thus didn't allow bsas to overwrite loose files - bugfix: in some constellations the tutorial files couldn't be found despite being in the right location
Diffstat (limited to 'src/profile.cpp')
-rw-r--r--src/profile.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/profile.cpp b/src/profile.cpp
index 50e6c3b2..2bbdea66 100644
--- a/src/profile.cpp
+++ b/src/profile.cpp
@@ -415,10 +415,13 @@ void Profile::setModEnabled(unsigned int index, bool enabled)
throw MyException(tr("invalid index %1").arg(index));
}
- if (m_ModStatus[index].m_Overwrite) {
- // overwrite is always enabled
- return;
+ ModInfo::Ptr modInfo = ModInfo::getByIndex(index);
+ // we could quit in the following case, this shouldn't be a change anyway,
+ // but at least this allows the situation to be fixed in case of an error
+ if (modInfo->alwaysEnabled()) {
+ enabled = true;
}
+
if (enabled != m_ModStatus[index].m_Enabled) {
m_ModStatus[index].m_Enabled = enabled;
emit modStatusChanged(index);
@@ -740,13 +743,11 @@ QString Profile::getLoadOrderFileName() const
return QDir::cleanPath(m_Directory.absoluteFilePath("loadorder.txt"));
}
-
QString Profile::getLockedOrderFileName() const
{
return QDir::cleanPath(m_Directory.absoluteFilePath("lockedorder.txt"));
}
-
QString Profile::getArchivesFileName() const
{
return QDir::cleanPath(m_Directory.absoluteFilePath("archives.txt"));
@@ -757,7 +758,6 @@ QString Profile::getDeleterFileName() const
return QDir::cleanPath(m_Directory.absoluteFilePath("hide_plugins.txt"));
}
-
QString Profile::getIniFileName() const
{
std::wstring primaryIniFile = *(GameInfo::instance().getIniFileNames().begin());
@@ -769,7 +769,6 @@ QString Profile::getProfileTweaks() const
return QDir::cleanPath(m_Directory.absoluteFilePath(ToQString(AppConfig::profileTweakIni())));
}
-
QString Profile::getPath() const
{
return QDir::cleanPath(m_Directory.absolutePath());