summaryrefslogtreecommitdiffstats
path: root/archiveviewwidget.cpp
diff options
context:
space:
mode:
authoram <am@f440f766-f032-0410-8965-dc7d17de2ca0>2009-08-01 13:23:42 +0000
committeram <am@f440f766-f032-0410-8965-dc7d17de2ca0>2009-08-01 13:23:42 +0000
commit286d54a4705e56567a68cf6dabfa3ce64ac162d6 (patch)
tree021bff63e2e4f77383a6c95dc5b0dc54ea45e90e /archiveviewwidget.cpp
parent68ee8c0796a663ec87b913da33d48cf5481ddb35 (diff)
downloadSheMov-286d54a4705e56567a68cf6dabfa3ce64ac162d6.tar.gz
SheMov-286d54a4705e56567a68cf6dabfa3ce64ac162d6.tar.bz2
SheMov-286d54a4705e56567a68cf6dabfa3ce64ac162d6.zip
-finished properties dialog
-start mplayer detached from FileSystemWidget git-svn-id: file:///var/svn/repos2/shemov/trunk@397 f440f766-f032-0410-8965-dc7d17de2ca0
Diffstat (limited to 'archiveviewwidget.cpp')
-rw-r--r--archiveviewwidget.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/archiveviewwidget.cpp b/archiveviewwidget.cpp
index 1bc7902..9be3a10 100644
--- a/archiveviewwidget.cpp
+++ b/archiveviewwidget.cpp
@@ -28,6 +28,7 @@
#include "coverarchiveeditor.h"
#include "textenterdialog.h"
#include "helper.h"
+#include "moviepropertiesdialog.h"
ArchiveViewWidget::ArchiveViewWidget(MovieModel *model, ListModel *genre, ListModel *actors, QWidget *parent) : QWidget(parent), mMovieModel(model), mGenreModel(genre), mActorsModel(actors){
//filter bar
@@ -151,6 +152,18 @@ void ArchiveViewWidget::showMovie(const QModelIndex &movie){
QProcess::startDetached(playerPath, args);
}
+void ArchiveViewWidget::properties(){
+ QModelIndexList selected = fileView()->selectionModel()->selectedRows();
+ if(selected.isEmpty()){
+ return;
+ }
+ QModelIndex idx = selected.at(0);
+ QModelIndex real = mProxy->mapToSource(idx);
+ int movid = real.data(MovieModel::IdRole).toInt();
+ MoviePropertiesDialog dlg(movid, this);
+ dlg.exec();
+}
+
void ArchiveViewWidget::setFilter(){
QString filter = mName->text().toLower();
if(filter.isEmpty()){