diff options
author | Jan Dalheimer <jan@dalheimer.de> | 2013-12-28 23:34:18 +0100 |
---|---|---|
committer | Jan Dalheimer <jan@dalheimer.de> | 2013-12-28 23:34:18 +0100 |
commit | 5b54a4ca8c4849a4476bb9a5e1c2414463949621 (patch) | |
tree | 80705f47867cad113f0b3d83442ab1434b6ea091 /gui/dialogs | |
parent | 55e62a81b69663041cb2402f779d0d957c499cb1 (diff) | |
download | MultiMC-5b54a4ca8c4849a4476bb9a5e1c2414463949621.tar MultiMC-5b54a4ca8c4849a4476bb9a5e1c2414463949621.tar.gz MultiMC-5b54a4ca8c4849a4476bb9a5e1c2414463949621.tar.lz MultiMC-5b54a4ca8c4849a4476bb9a5e1c2414463949621.tar.xz MultiMC-5b54a4ca8c4849a4476bb9a5e1c2414463949621.zip |
Don't hardcode stuff!!!
Diffstat (limited to 'gui/dialogs')
-rw-r--r-- | gui/dialogs/OneSixModEditDialog.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/gui/dialogs/OneSixModEditDialog.cpp b/gui/dialogs/OneSixModEditDialog.cpp index 0d54328a..fb422941 100644 --- a/gui/dialogs/OneSixModEditDialog.cpp +++ b/gui/dialogs/OneSixModEditDialog.cpp @@ -72,6 +72,8 @@ OneSixModEditDialog::OneSixModEditDialog(OneSixInstance *inst, QWidget *parent) auto smodel = ui->loaderModTreeView->selectionModel(); connect(smodel, SIGNAL(currentChanged(QModelIndex, QModelIndex)), SLOT(loaderCurrent(QModelIndex, QModelIndex))); + + ui->liteloaderBtn->setEnabled(LiteLoaderInstaller(m_inst->intendedVersionId()).canApply()); } // resource packs { @@ -207,7 +209,15 @@ void OneSixModEditDialog::on_forgeBtn_clicked() void OneSixModEditDialog::on_liteloaderBtn_clicked() { - LiteLoaderInstaller liteloader; + LiteLoaderInstaller liteloader(m_inst->intendedVersionId()); + if (!liteloader.canApply()) + { + QMessageBox::critical( + this, tr("LiteLoader"), + tr("There is no information available on how to install LiteLoader " + "into this version of Minecraft")); + return; + } if (!liteloader.apply(m_version)) { // failure notice |