Compare commits

..
Author SHA1 Message Date
Tannin 89e0c258e3 - added an option to show meta info on downloads instead of filenames
- MO will now cancel if user tries to run MO vfs-injected
- when saving the MO ini file it is now written to a tmp file first and then overwritten
- updated to link against boost python 1.55
2014-04-23 23:59:30 +02:00
Tannin dbbed655a1 - improved NCC compatibility
- crude support for multi-volume archives
- updated imageformats plugins
- nxmhandler now puts the exe to the top of the list when registering an MO instance, even if it is already in the list
- bugfix: WritePrivateProfileString hook attempted to access lpKeyName even when it is null
2014-03-26 15:35:59 +01:00
+16 -2
View File
@@ -84,6 +84,13 @@ bool InstallerBundle::isArchiveSupported(const DirectoryTree &tree) const
return true;
}
}
if ((tree.numNodes() == 0)
&& (tree.numLeafs() == 1)
&& (tree.leafsBegin()->getName().endsWith(".7z", Qt::CaseInsensitive)
|| tree.leafsBegin()->getName().endsWith(".rar", Qt::CaseInsensitive))) {
// nested archive
return true;
}
return false;
}
@@ -92,9 +99,16 @@ IPluginInstaller::EInstallResult InstallerBundle::install(GuessedValue<QString>
{
for (DirectoryTree::const_leaf_iterator fileIter = tree.leafsBegin();
fileIter != tree.leafsEnd(); ++fileIter) {
if (fileIter->getName().endsWith(".fomod", Qt::CaseInsensitive)) {
QString name = fileIter->getName();
if (name.endsWith(".fomod", Qt::CaseInsensitive)
|| name.endsWith(".7z", Qt::CaseInsensitive)
|| name.endsWith(".rar", Qt::CaseInsensitive)) {
QString tempFile = manager()->extractFile(fileIter->getName());
return manager()->installArchive(modName, tempFile);
IPluginInstaller::EInstallResult res = manager()->installArchive(modName, tempFile);
if (res == IPluginInstaller::RESULT_SUCCESS) {
res = IPluginInstaller::RESULT_SUCCESSCANCEL;
}
return res;
}
}
return IPluginInstaller::RESULT_NOTATTEMPTED;