mirror of
https://github.com/vcmi/vcmi.git
synced 2025-05-31 22:59:54 +02:00
Correctly block mod enable button for mods with missing dependencies
This commit is contained in:
parent
b0d8068493
commit
bcada0eeed
@ -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))
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user