Fixed always loading 1x, 2x and 3x images

This commit is contained in:
fourtf
2019-08-13 13:42:38 +02:00
parent 294c2aecdc
commit 6274c05520
5 changed files with 19 additions and 10 deletions
+5 -5
View File
@@ -84,16 +84,16 @@ const ImagePtr &ImageSet::getImage(float scale) const
return this->imageX1_;
}();
// prefere other image if selected image is not loaded yet
if (result->pixmap())
// prefer other image if selected image is not loaded yet
if (result->loaded())
return result;
else if (this->imageX1_->pixmap())
else if (this->imageX1_->loaded())
return this->imageX1_;
else if (this->imageX2_ && !this->imageX2_->isEmpty() &&
this->imageX2_->pixmap())
this->imageX2_->loaded())
return this->imageX2_;
else if (this->imageX3_ && !this->imageX3_->isEmpty() &&
this->imageX3_->pixmap())
this->imageX3_->loaded())
return this->imageX3_;
else
return result;