if (! (gallery.getComm(null) instanceof GalleryComm2_5) && gallery.getType() == Gallery.TYPE_APPLET) {
if (! (gallery.getComm(null) instanceof GalleryComm2_5) && gallery.getType() != Gallery.TYPE_APPLET) {
	public void setInProgress(boolean inProgress) {		jUpload.setEnabled(!inProgress);		jAdd.setEnabled(!inProgress);		jPicturesList.setEnabled(!inProgress);		jCaption.setEnabled(!inProgress);		jResize.setEnabled(!inProgress);		this.inProgress = inProgress;		if (! inProgress && hasHadPictures) {			// probably finished uploading...			try {				// no update for G2 and for embedded applets (non-embedded applets are TYPE_STANDALONE)				if (! (gallery.getComm(null) instanceof GalleryComm2_5) && gallery.getType() == Gallery.TYPE_APPLET) {					getAppletContext().showDocument(new URL(getCodeBase().toString() + "add_photos_refresh.php"), "hack");				}			} catch (MalformedURLException e1) {				Log.logException(Log.LEVEL_ERROR, MODULE, e1);			}			hasHadPictures = false;		}	}