GalleryRemote._().properties.getThumbnailSize());
GalleryRemote._().properties.getThumbnailSize(), true);
	public void run() {		Thread.yield();		int loaded = 0;		GalleryRemote._().getCore().getMainStatusUpdate().startProgress(StatusUpdate.LEVEL_CACHE, 0, toLoad.size(), GRI18n.getString(MODULE, "loadThmb"), false);		//Log.log(Log.TRACE, MODULE, "Starting " + iFilename);		while (!toLoad.isEmpty()) {			Picture p = (Picture) toLoad.pop();			ImageIcon i = null;			if (!thumbnails.containsKey(p)) {				if (p.isOnline()) {					i = new ImageIcon(p.getUrlThumbnail());					Image scaled = null;					Dimension newD = ImageUtils.getSizeKeepRatio(							new Dimension(i.getIconWidth(), i.getIconHeight()),							GalleryRemote._().properties.getThumbnailSize());					scaled = i.getImage().getScaledInstance(newD.width, newD.height, Image.SCALE_FAST);					i.getImage().flush();					i.setImage(scaled);				} else {					i = ImageUtils.load(							p.getSource().getPath(),							GalleryRemote._().properties.getThumbnailSize(),							ImageUtils.THUMB);				}				thumbnails.put(p, i);				loaded++;				Log.log(Log.LEVEL_TRACE, MODULE, "update progress " + loaded + "/" + (loaded + toLoad.size()));				GalleryRemote._().getCore().getMainStatusUpdate().updateProgressValue(StatusUpdate.LEVEL_CACHE, loaded, loaded + toLoad.size());				GalleryRemote._().getCore().thumbnailLoadedNotify();			}		}		stillRunning = false;		GalleryRemote._().getCore().getMainStatusUpdate().stopProgress(StatusUpdate.LEVEL_CACHE, GRI18n.getString(MODULE, "thmbLoaded"));		//Log.log(Log.TRACE, MODULE, "Ending");	}