mirror of
https://github.com/MultiMC/MultiMC5.git
synced 2025-01-13 00:45:54 +00:00
NOISSUE shortcut creation: fix version check
This commit is contained in:
parent
2dc44b3ff5
commit
363588789e
@ -44,7 +44,7 @@ CreateShortcutDialog::CreateShortcutDialog(QWidget *parent, InstancePtr instance
|
|||||||
{
|
{
|
||||||
MinecraftInstancePtr minecraftInstance = qobject_pointer_cast<MinecraftInstance>(m_instance);
|
MinecraftInstancePtr minecraftInstance = qobject_pointer_cast<MinecraftInstance>(m_instance);
|
||||||
QString version = minecraftInstance->getPackProfile()->getComponentVersion("net.minecraft");
|
QString version = minecraftInstance->getPackProfile()->getComponentVersion("net.minecraft");
|
||||||
bool enableJoinServer = QRegExp(JOIN_SERVER_DISALLOWED_VERSIONS).exactMatch(version);
|
bool enableJoinServer = !QRegExp(JOIN_SERVER_DISALLOWED_VERSIONS).exactMatch(version);
|
||||||
ui->joinServerCheckBox->setEnabled(enableJoinServer);
|
ui->joinServerCheckBox->setEnabled(enableJoinServer);
|
||||||
ui->joinServer->setEnabled(enableJoinServer);
|
ui->joinServer->setEnabled(enableJoinServer);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user