Icons are resized depending on the current scale/resolution

See issue #3547 and #4803
This commit is contained in:
Hombre
2018-12-08 22:48:15 +01:00
parent 434e121f99
commit 5ea0bacddd
23 changed files with 259 additions and 192 deletions

View File

@@ -27,7 +27,7 @@
#include "thumbbrowserbase.h"
bool BatchQueueEntry::iconsLoaded(false);
Cairo::RefPtr<Cairo::ImageSurface> BatchQueueEntry::savedAsIcon;
Glib::RefPtr<Gdk::Pixbuf> BatchQueueEntry::savedAsIcon;
BatchQueueEntry::BatchQueueEntry (rtengine::ProcessingJob* pjob, const rtengine::procparams::ProcParams& pparams, Glib::ustring fname, int prevw, int prevh, Thumbnail* thm) :
ThumbBrowserEntryBase(fname),
@@ -55,7 +55,7 @@ BatchQueueEntry::BatchQueueEntry (rtengine::ProcessingJob* pjob, const rtengine:
#endif
if (!iconsLoaded) {
savedAsIcon = RTImage::createFromFile ("save-small.png");
savedAsIcon = RTImage::createPixbufFromFile ("save-small.png");
iconsLoaded = true;
}
@@ -145,10 +145,10 @@ void BatchQueueEntry::removeButtonSet ()
buttonSet = nullptr;
}
std::vector<Cairo::RefPtr<Cairo::ImageSurface> > BatchQueueEntry::getIconsOnImageArea ()
std::vector<Glib::RefPtr<Gdk::Pixbuf> > BatchQueueEntry::getIconsOnImageArea ()
{
std::vector<Cairo::RefPtr<Cairo::ImageSurface> > ret;
std::vector<Glib::RefPtr<Gdk::Pixbuf> > ret;
if (!outFileName.empty()) {
ret.push_back (savedAsIcon);