Merge pull request #1333 from Ryex/fix/null_instance_edit_crash
This commit is contained in:
parent
6f86e8b66e
commit
a0ddd85b32
@ -1279,7 +1279,17 @@ void MainWindow::globalSettingsClosed()
|
|||||||
|
|
||||||
void MainWindow::on_actionEditInstance_triggered()
|
void MainWindow::on_actionEditInstance_triggered()
|
||||||
{
|
{
|
||||||
APPLICATION->showInstanceWindow(m_selectedInstance);
|
|
||||||
|
if (!m_selectedInstance)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (m_selectedInstance->canEdit()) {
|
||||||
|
APPLICATION->showInstanceWindow(m_selectedInstance);
|
||||||
|
} else {
|
||||||
|
CustomMessageBox::selectable(this, tr("Instance not editable"),
|
||||||
|
tr("This instance is not editable. It may be broken, invalid, or too old. Check logs for details."),
|
||||||
|
QMessageBox::Critical)->show();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::on_actionManageAccounts_triggered()
|
void MainWindow::on_actionManageAccounts_triggered()
|
||||||
|
Loading…
Reference in New Issue
Block a user