Utils: FilePathify RemoveFileDialog

Change-Id: I3402fb7b44ec556d7de79d42b3ddcb606048780d
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
hjk
2021-08-17 10:09:43 +02:00
parent 0416e15612
commit fd0f6fd5e6
5 changed files with 11 additions and 9 deletions

View File

@@ -541,8 +541,8 @@ void FolderNavigationWidget::removeCurrentItem()
const QModelIndex current = m_sortProxyModel->mapToSource(m_listView->currentIndex());
if (!current.isValid() || m_fileSystemModel->isDir(current))
return;
const Utils::FilePath filePath = Utils::FilePath::fromString(m_fileSystemModel->filePath(current));
Utils::RemoveFileDialog dialog(filePath.toString(), Core::ICore::dialogParent());
const FilePath filePath = FilePath::fromString(m_fileSystemModel->filePath(current));
RemoveFileDialog dialog(filePath, Core::ICore::dialogParent());
dialog.setDeleteFileVisible(false);
if (dialog.exec() == QDialog::Accepted) {
const QVector<FolderNode *> folderNodes = removableFolderNodes(filePath);