mirror of
https://github.com/vcmi/vcmi.git
synced 2025-08-10 22:31:40 +02:00
Correctly block mod enable button for mods with missing dependencies
This commit is contained in:
@@ -546,9 +546,6 @@ QStringList CModListView::getModsToInstall(QString mod)
|
||||
candidates.pop_back();
|
||||
processed.push_back(potentialToInstall);
|
||||
|
||||
if (modStateModel->isModExists(potentialToInstall) && modStateModel->isModInstalled(potentialToInstall))
|
||||
continue;
|
||||
|
||||
if (modStateModel->isSubmod(potentialToInstall))
|
||||
{
|
||||
QString topParent = modStateModel->getTopParent(potentialToInstall);
|
||||
@@ -562,7 +559,8 @@ QStringList CModListView::getModsToInstall(QString mod)
|
||||
potentialToInstall = modStateModel->getTopParent(potentialToInstall);
|
||||
}
|
||||
|
||||
result.push_back(potentialToInstall);
|
||||
if (modStateModel->isModExists(potentialToInstall) && !modStateModel->isModInstalled(potentialToInstall))
|
||||
result.push_back(potentialToInstall);
|
||||
|
||||
if (modStateModel->isModExists(potentialToInstall))
|
||||
{
|
||||
|
Reference in New Issue
Block a user