mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-01 02:46:59 +03:00
Instance flags. Currently used for marking instances as broken. Can later be used for badges.
This commit is contained in:
parent
4e8be668cb
commit
0b56b5efaf
10 changed files with 83 additions and 10 deletions
|
|
@ -325,11 +325,12 @@ bool OneSixInstance::reloadVersion(QWidget *widgetParent)
|
|||
}
|
||||
if (ret)
|
||||
{
|
||||
setFlags(flags() & ~VersionBrokenFlag);
|
||||
emit versionReloaded();
|
||||
}
|
||||
else
|
||||
{
|
||||
nuke();
|
||||
setFlags(flags() | VersionBrokenFlag);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
|
@ -366,8 +367,14 @@ QString OneSixInstance::defaultCustomBaseJar() const
|
|||
|
||||
bool OneSixInstance::menuActionEnabled(QString action_name) const
|
||||
{
|
||||
if (action_name == "actionChangeInstLWJGLVersion")
|
||||
if (flags() & VersionBrokenFlag)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (action_name == "actionChangeInstLWJGLVersion")
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -376,7 +383,11 @@ QString OneSixInstance::getStatusbarDescription()
|
|||
QString descr = "OneSix : " + intendedVersionId();
|
||||
if (versionIsCustom())
|
||||
{
|
||||
descr + " (custom)";
|
||||
descr += " (custom)";
|
||||
}
|
||||
if (flags() & VersionBrokenFlag)
|
||||
{
|
||||
descr += " (broken)";
|
||||
}
|
||||
return descr;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue