From 31bc791cb48e110db8f7b994931c1879974168a1 Mon Sep 17 00:00:00 2001 From: Arno Date: Sun, 31 Oct 2010 08:26:07 +0100 Subject: Added ".." entry to FileView Show ".." entry in FileView and make it go to the parent directory. Had to work around QT Bug 14760: NoDot doesn't work so the "." entry has to be filtered in filterAcceptsRow() --- fileview.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'fileview.cpp') diff --git a/fileview.cpp b/fileview.cpp index f4f5294..03fc76f 100644 --- a/fileview.cpp +++ b/fileview.cpp @@ -163,6 +163,9 @@ bool FileView::event(QEvent *e){ if(!curIdx.isValid() || (curIdx.column() != 0)){ return exitHover(); } + if(curIdx.data().toString() == ".."){ + return exitHover(); + } QFileInfo fi(curIdx.data(QFileSystemModel::FilePathRole).toString()); if(!fi.exists()){ return true; -- cgit v1.2.3-70-g09d2