merged upstream/master

This commit is contained in:
csoler 2020-09-11 21:36:45 +02:00
commit 2e6a87a2ea
84 changed files with 2515 additions and 968 deletions

View file

@ -308,8 +308,10 @@ QPixmap misc::getOpenThumbnailedPicture(QWidget *parent, const QString &caption,
if (!getOpenFileName(parent, RshareSettings::LASTDIR_IMAGES, caption, tr("Pictures (*.png *.jpeg *.xpm *.jpg *.tiff *.gif)"), fileName))
return QPixmap();
return FilesDefs::getPixmapFromQtResourcePath(fileName).scaledToHeight(height, Qt::SmoothTransformation).copy( 0, 0, width, height);
//return FilesDefs::getPixmapFromQtResourcePath(fileName).scaledToHeight(width, height, Qt::KeepAspectRatioByExpanding, Qt::SmoothTransformation);
if(width > 0 && height > 0)
return FilesDefs::getPixmapFromQtResourcePath(fileName).scaledToHeight(height, Qt::SmoothTransformation).copy( 0, 0, width, height);
else
return FilesDefs::getPixmapFromQtResourcePath(fileName);
}
bool misc::getOpenFileName(QWidget *parent, RshareSettings::enumLastDir type