mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-24 00:14:06 +00:00
Fix crash when closing last opened tab
This commit is contained in:
parent
753b0185df
commit
9404c4dd70
|
@ -1009,7 +1009,9 @@ void MainWindow::tabCloseRequested( int x )
|
|||
delete w;
|
||||
|
||||
//activate a tab in accordance with MRU
|
||||
ui.tabWidget->setCurrentWidget(mruList.at(0));
|
||||
if ( mruList.size() > 0 ) {
|
||||
ui.tabWidget->setCurrentWidget(mruList.at(0));
|
||||
}
|
||||
|
||||
// if everything is closed, add new tab
|
||||
if ( ui.tabWidget->count() == 0 )
|
||||
|
|
Loading…
Reference in a new issue