resetUIState();
setGalleries( newGalleries );
	private void openState() {		try {			JFileChooser fc = new JFileChooser();			fc.setAcceptAllFileFilterUsed(false);		    fc.setFileFilter(galleryFileFilter);			int returnVal = fc.showOpenDialog(this);			if(returnVal == JFileChooser.APPROVE_OPTION) {				Log.log(Log.INFO, MODULE, "Opening state from file " + fc.getSelectedFile().getPath());				ObjIn in = new ObjIn(new BufferedReader(new FileReader(fc.getSelectedFile())));				Gallery[] galleryArray = (Gallery[]) in.readObject();				galleries = new DefaultComboBoxModel();				for (int i = 0; i < galleryArray.length; i++) {					galleries.addElement(galleryArray[i]);					thumbnailCache.preloadThumbnailPictures(Collections.enumeration(galleryArray[i].getAllPictures()));				}				gallery.setModel( galleries );				updateGalleryParams();				resetUIState();			}		} catch (IOException e) {			Log.log(Log.ERROR, MODULE, "Exception while trying to read state");			Log.logException(Log.ERROR, MODULE, e);		} catch (ClassNotFoundException e) {			Log.log(Log.ERROR, MODULE, "Exception while trying to read state (probably a version mismatch)");			Log.logException(Log.ERROR, MODULE, e);		} catch (NoClassDefFoundError e) {			Log.log(Log.ERROR, MODULE, "JSX not installed, can't read state...");		}	}