void runTask() {
			ArrayList<Picture> pictures = g.getAllUploadablePictures();

			// get total file size
			long totalSize = 0;
			Iterator<Picture> iter = pictures.iterator();
			while (iter.hasNext()) {
				Picture p = iter.next();
				totalSize += p.getFileSize();
			}

//			transferListener = new MyTransferListener(su);
//			transferListener.sizeAllFiles = totalSize;
//			transferListener.numberAllFiles = pictures.size();

			su.startProgress(StatusUpdate.LEVEL_UPLOAD_ALL, 0, 100, GRI18n.getString(MODULE, "upPic"), false);

			if (su instanceof UploadProgress) {
				((UploadProgress) su).setCancelListener(new ActionListener() {
					public void actionPerformed(ActionEvent e) {
						su.updateProgressStatus(StatusUpdate.LEVEL_UPLOAD_ALL, GRI18n.getString(MODULE, "upStop"));
						su.setUndetermined(StatusUpdate.LEVEL_UPLOAD_ALL, true);
						interrupt();
						long startTime = System.currentTimeMillis();

						while (!terminated && System.currentTimeMillis() < startTime + 10000) {
							try {
								Thread.sleep(1000);
							} catch (InterruptedException e1) {
							}
						}

						if (!terminated) {
							Log.log(Log.LEVEL_ERROR, "Thread would not terminate properly: killing it");
							thread.stop();

							// since we killed the thread, it's not going to clean up after itself
							cleanUp();
						}

						((UploadProgress) su).done();
					}
				});
			}

			// upload each file, one at a time
			boolean allGood = true;
			//int uploadedCount = 0;
			iter = pictures.iterator();
			while (iter.hasNext() /*&& allGood*/ && !interrupt) {
				Picture p = iter.next();

				/*Object[] params = {
						p.toString(),
						new Integer((uploadedCount + 1)),
						new Integer(pictures.size()),
						new Integer((int) ((transferListener.sizeFilesDone + transferListener.sizeThisFile) / 1024 / 1024)),
						new Integer((int) (transferListener.sizeAllFiles / 1024 / 1024)),
						transferListener.getProjectedTimeLeft()
				};
				su.updateProgressStatus(StatusUpdate.LEVEL_UPLOAD_ALL, GRI18n.getString(MODULE, "upStatus", params));*/

				allGood = uploadPicture(p);

				//su.updateProgressValue(StatusUpdate.LEVEL_UPLOAD_ALL, ++uploadedCount);

				if (allGood) {
					p.getParentAlbum().removePicture(p);
				}
			}

			if (allGood) {
				su.stopProgress(StatusUpdate.LEVEL_UPLOAD_ALL, GRI18n.getString(MODULE, "upComplete"));

				if (su instanceof UploadProgress) {
					if (((UploadProgress) su).isShutdown()) {
						GalleryRemote._().getCore().shutdown(true);
					}
				}

				g.setDirty(false);

				GalleryRemote._().getCore().flushMemory();
			} else {
				su.stopProgress(StatusUpdate.LEVEL_UPLOAD_ALL, GRI18n.getString(MODULE, "upFailed"));
			}
		}