summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorisanae <14251494+isanae@users.noreply.github.com>2019-12-14 13:49:26 -0500
committerisanae <14251494+isanae@users.noreply.github.com>2019-12-14 13:49:26 -0500
commit7af0e164f778ee8b2135e097856a597f5d68b873 (patch)
treecd507d7d2abd67f775fefa33394fdd14a8eac52e /src/mainwindow.cpp
parent4c7b626e7748cae0f7c1933989bc1bcb755664f7 (diff)
don't activate the root data item
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index ea202064..a29ea8ab 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -5305,6 +5305,10 @@ void MainWindow::activateDataTreeItem(QTreeWidgetItem *item, int column)
}
const QString path = item->data(0, Qt::UserRole).toString();
+ if (path.isEmpty()) {
+ return;
+ }
+
const QFileInfo targetInfo(path);
const auto tryPreview = m_OrganizerCore.settings().interface().doubleClicksOpenPreviews();