Start new model when closing the last tab. Fixes #422.

This commit is contained in:
Leonardo Zide 2020-01-26 11:31:21 -08:00
parent 59098436b7
commit bbc40d5a22

View file

@ -933,6 +933,8 @@ void lcMainWindow::ModelTabClosed(int Index)
{
if (mModelTabWidget->count() != 1)
delete mModelTabWidget->widget(Index);
else
NewProject();
}
void lcMainWindow::ModelTabChanged(int Index)
@ -1449,6 +1451,8 @@ void lcMainWindow::CloseCurrentModelTab()
{
if (mModelTabWidget->count() > 1)
delete mModelTabWidget->currentWidget();
else
NewProject();
}
void lcMainWindow::SetCurrentModelTab(lcModel* Model)