mirror of
https://github.com/vcmi/vcmi.git
synced 2025-06-02 23:07:36 +02:00
Fix visibility of translation mods, fix heading for mod version field
This commit is contained in:
parent
1f8dc49669
commit
5ca65f14bd
@ -327,7 +327,12 @@ QString CModListView::genModInfoText(const ModState & mod)
|
||||
result += replaceIfNotEmpty(mod.getRepositoryVersion(), lineTemplate.arg(tr("Latest version")));
|
||||
}
|
||||
else
|
||||
result += replaceIfNotEmpty(mod.getVersion(), lineTemplate.arg(tr("Installed version")));
|
||||
{
|
||||
if (mod.isInstalled())
|
||||
result += replaceIfNotEmpty(mod.getInstalledVersion(), lineTemplate.arg(tr("Installed version")));
|
||||
else
|
||||
result += replaceIfNotEmpty(mod.getRepositoryVersion(), lineTemplate.arg(tr("Latest version")));
|
||||
}
|
||||
|
||||
if (mod.isInstalled())
|
||||
result += replaceIfNotEmpty(modStateModel->getInstalledModSizeFormatted(mod.getID()), lineTemplate.arg(tr("Size")));
|
||||
|
@ -200,7 +200,7 @@ bool ModState::isVisible() const
|
||||
bool ModState::isHidden() const
|
||||
{
|
||||
if (isTranslation() && !isInstalled())
|
||||
return impl.getBaseLanguage() == CGeneralTextHandler::getPreferredLanguage();
|
||||
return impl.getBaseLanguage() != CGeneralTextHandler::getPreferredLanguage();
|
||||
|
||||
return isCompatibility() || getID() == "vcmi" || getID() == "core";
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user