diff --git a/lib/utils/tab-helpers.cpp b/lib/utils/tab-helpers.cpp index e0971e56..32db2120 100644 --- a/lib/utils/tab-helpers.cpp +++ b/lib/utils/tab-helpers.cpp @@ -161,7 +161,7 @@ void SetTabOrder(QTabWidget *tabWidget) void SetCurrentTab(QTabWidget *tabWidget) { - if (lastOpenedTab >= 0) { + if (lastOpenedTab >= 0 && tabWidget->isTabVisible(lastOpenedTab)) { tabWidget->setCurrentIndex(lastOpenedTab); } }