From d6b178b1fdcdac519ded25e3f253d9eeffa84053 Mon Sep 17 00:00:00 2001 From: Arno Date: Sun, 28 Jul 2013 07:46:16 +0200 Subject: Implement file properties dialog Show file properties in Filemanager and Archive, if the file is available. Also get rid of the palette stuff in SmGlobals. Just call setPalette() early enough and set it in SmTreeView. --- fileview.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'fileview.cpp') diff --git a/fileview.cpp b/fileview.cpp index 336d179..80a81bd 100644 --- a/fileview.cpp +++ b/fileview.cpp @@ -32,6 +32,7 @@ #include "hoverwindow.h" #include "smglobals.h" #include "filesystemfileproxy.h" +#include "filepropertiesdialog.h" #include "smdirmodel.h" #include "framecache.h" @@ -231,6 +232,16 @@ void FileView::selectedFilesChanged(){ emit selectedDuration(dur, false); } +void FileView::properties(){ + QModelIndexList selected = selectionModel()->selectedRows(); + if(selected.isEmpty()){ + return; + } + QString fp = selected.at(0).data(SmDirModel::FullPathRole).toString(); + FilePropertiesDialog fpd(fp, this); + fpd.exec(); +} + void FileView::saveSelection(){ mMd5Sums.clear(); QModelIndexList selected = selectionModel()->selectedRows(SmDirModel::Md5sum); -- cgit v1.2.3-70-g09d2