Skip to content
Snippets Groups Projects
Commit bfa80c41 authored by dt's avatar dt
Browse files

Fixes file system view to be unable to cdUp to the root

Reviewed-By: Robert Loehning
parent d3ba80bf
No related branches found
No related tags found
No related merge requests found
...@@ -253,8 +253,7 @@ void FolderNavigationWidget::openItem(const QModelIndex &srcIndex) ...@@ -253,8 +253,7 @@ void FolderNavigationWidget::openItem(const QModelIndex &srcIndex)
if (fileName == QLatin1String("..")) { if (fileName == QLatin1String("..")) {
// cd up: Special behaviour: The fileInfo of ".." is that of the parent directory. // cd up: Special behaviour: The fileInfo of ".." is that of the parent directory.
const QString parentPath = m_fileSystemModel->fileInfo(srcIndex).absoluteFilePath(); const QString parentPath = m_fileSystemModel->fileInfo(srcIndex).absoluteFilePath();
if (parentPath != QDir::rootPath()) setCurrentDirectory(parentPath);
setCurrentDirectory(parentPath);
return; return;
} }
if (m_fileSystemModel->isDir(srcIndex)) { // Change to directory if (m_fileSystemModel->isDir(srcIndex)) { // Change to directory
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment