summaryrefslogtreecommitdiffstats
path: root/helper.cpp
diff options
context:
space:
mode:
authorArno <am@disconnect.de>2013-08-22 07:43:20 +0200
committerArno <am@disconnect.de>2013-08-22 07:43:20 +0200
commit369c14264c664b38049ac081cf60b8485a4042cb (patch)
tree5e77075e82d5d0caf7f0a7743a9a69f42ac9df9e /helper.cpp
parentcd2d39368e2319eb7c949439e9688bf8319ec0a3 (diff)
downloadSheMov-369c14264c664b38049ac081cf60b8485a4042cb.tar.gz
SheMov-369c14264c664b38049ac081cf60b8485a4042cb.tar.bz2
SheMov-369c14264c664b38049ac081cf60b8485a4042cb.zip
Give Pictures some love!
* Show and archive size of pictures * Fix SqlQueries in PicFilesModel: removeFiles and changeMappings * use delegate in PictureView
Diffstat (limited to 'helper.cpp')
-rw-r--r--helper.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/helper.cpp b/helper.cpp
index 348c066..7349b09 100644
--- a/helper.cpp
+++ b/helper.cpp
@@ -290,6 +290,15 @@ namespace Helper {
return retval.scaledToWidth(640);
}
+ QVariant picSize(const QString &path){
+ QPixmap pm(path);
+ if(!pm.isNull()){
+ QString retval = QString("%1x%2").arg(QString::number(pm.width())).arg(QString::number(pm.height()));
+ return retval;
+ }
+ return QVariant();
+ }
+
Duration::Duration() : mHours(0), mMinutes(0), mSeconds(0) {}
Duration::Duration(qint64 seconds){