We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 364eefa commit a35f19aCopy full SHA for a35f19a
1 file changed
src/ui/MainWindow.cpp
@@ -1274,11 +1274,14 @@ bool MainWindow::on_actionCloseProject_triggered()
1274
if (auto editor = getEditorForTab(i))
1275
{
1276
const auto filePath = currProject->getRelativePathOf(QDir::fromNativeSeparators(QDir::cleanPath(editor->getFilePath())));
1277
- openedTabs.append(filePath);
1278
- if (editor == currentEditor)
+ if (!filePath.isEmpty())
1279
1280
- settings->setValue(key + "/currentTab", filePath);
1281
- currentEditor->saveState(*settings, key);
+ openedTabs.append(filePath);
+ if (editor == currentEditor)
+ {
1282
+ settings->setValue(key + "/currentTab", filePath);
1283
+ currentEditor->saveState(*settings, key);
1284
+ }
1285
}
1286
1287
0 commit comments