From 76bb89940a3818456f535b7d4a8ba6ab9f382631 Mon Sep 17 00:00:00 2001 From: Arno Date: Sat, 6 Nov 2010 14:12:12 +0100 Subject: Bugfix in moveToBurn() Using the filename from the QModelIndex isn't enough to determine wether the file is a cover or not. A series can have more than one part. So check the real file type and only copy if it's not of type Movie. This fix should obsolete the new ConsistencyChecker :) --- filestreemodel.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'filestreemodel.h') diff --git a/filestreemodel.h b/filestreemodel.h index a620312..5140478 100644 --- a/filestreemodel.h +++ b/filestreemodel.h @@ -44,6 +44,7 @@ class FilesTreeModel : public SmTreeModel { QMap pictureInfo(const QString &path) const; QMap pictureInfo(const QModelIndex &idx) const; QMap pictureMetaInfo(const QModelIndex &idx); + int fileType(const QString &md5sum) const; //file manipulation bool addFile(const QString &fullPath, int type, int quality, int filePart, int seriesPartId, int dvd = -1); @@ -66,6 +67,7 @@ class FilesTreeModel : public SmTreeModel { QSqlQuery *mInsertFileQuery; QSqlQuery *mFilesQuery; QSqlQuery *mDeleteFileQuery; + QSqlQuery *mFileTypeQuery; //misc QHash mFileTypes; -- cgit v1.2.3-70-g09d2