Skip to content

Commit

Permalink
itemimage: Use smooth thumbnails
Browse files Browse the repository at this point in the history
  • Loading branch information
hluk committed Jun 17, 2017
1 parent 5b7cdea commit 9d239ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/itemimage/itemimage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,9 @@ ItemWidget *ItemImageLoader::create(const QModelIndex &index, QWidget *parent, b
const int w = preview ? 0 : m_settings.value("max_image_width", 320).toInt();
const int h = preview ? 0 : m_settings.value("max_image_height", 240).toInt();
if ( w > 0 && pix.width() > w && (h <= 0 || pix.width()/w > pix.height()/h) ) {
pix = pix.scaledToWidth(w);
pix = pix.scaledToWidth(w, Qt::SmoothTransformation);
} else if (h > 0 && pix.height() > h) {
pix = pix.scaledToHeight(h);
pix = pix.scaledToHeight(h, Qt::SmoothTransformation);
}

QByteArray animationData;
Expand Down

0 comments on commit 9d239ee

Please sign in to comment.