mirror of
https://github.com/MultiMC/MultiMC5.git
synced 2024-11-20 08:10:11 +00:00
GH-866 load instance profile on launch and from version page
This commit is contained in:
parent
28aa8f342e
commit
3507ccaf50
@ -1736,6 +1736,12 @@ void MainWindow::launchInstance(InstancePtr instance, AuthSessionPtr session,
|
||||
|
||||
QString launchScript;
|
||||
|
||||
if(!instance->reload())
|
||||
{
|
||||
QMessageBox::critical(this, tr("Error"), tr("Couldn't load the instance profile."));
|
||||
return;
|
||||
}
|
||||
|
||||
BaseProcess *proc = instance->prepareForLaunch(session);
|
||||
if (!proc)
|
||||
return;
|
||||
|
@ -62,6 +62,8 @@ VersionPage::VersionPage(OneSixInstance *inst, QWidget *parent)
|
||||
ui->setupUi(this);
|
||||
ui->tabWidget->tabBar()->hide();
|
||||
|
||||
reloadMinecraftProfile();
|
||||
|
||||
m_version = m_inst->getMinecraftProfile();
|
||||
if (m_version)
|
||||
{
|
||||
@ -119,7 +121,7 @@ bool VersionPage::reloadMinecraftProfile()
|
||||
{
|
||||
QMessageBox::critical(
|
||||
this, tr("Error"),
|
||||
tr("Failed to load the version description file for reasons unknown."));
|
||||
tr("Couldn't load the instance profile."));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user