Core: Use FilePaths for recent documents

Change-Id: I453e7dd2c5d8d357b651392fa7d7f0baf07173f7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
David Schulz
2021-06-08 14:34:05 +02:00
parent b29ee5493b
commit 95a7dc4857
4 changed files with 17 additions and 20 deletions

View File

@@ -1200,8 +1200,7 @@ void MainWindow::aboutToShowRecentFiles()
for (int i = 0; i < recentFiles.count(); ++i) {
const DocumentManager::RecentFile file = recentFiles[i];
const QString filePath
= Utils::quoteAmpersands(QDir::toNativeSeparators(withTildeHomePath(file.first)));
const QString filePath = Utils::quoteAmpersands(file.first.shortNativePath());
const QString actionText = ActionManager::withNumberAccelerator(filePath, i + 1);
QAction *action = menu->addAction(actionText);
connect(action, &QAction::triggered, this, [file] {