public LoadDialog(StainedSockClient controller, MainFrame mainframe) {
		File loadFile = null;
		do {
			JFileChooser chooser = new JFileChooser();
			chooser.setMultiSelectionEnabled(false);
			FileFilter sspff = new sspLoadFilter();
			chooser.addChoosableFileFilter(sspff);
			chooser.setFileFilter(sspff);
			chooser.setSelectedFile(loadFile);
			chooser.setAcceptAllFileFilterUsed(false);
			switch (chooser.showOpenDialog(mainframe)) {
			case JFileChooser.APPROVE_OPTION:
				loadFile = chooser.getSelectedFile();
				if (!loadFile.exists()) {
					String ext = "";
					FileFilter selectedFilter = chooser.getFileFilter();
					if (selectedFilter instanceof sspLoadFilter) {
						ext = ".ssproj";
					}
					String path = loadFile.getPath();
					if (!path.toLowerCase().endsWith(ext)) {
						path += ext;
					}
					if (!new File(path).exists()) {
						continue;
					}
					loadFile = new File(path);
				}
				mainframe.getWorkspace().deserialize(loadFile);
				break;
			case JFileChooser.ERROR_OPTION:
				controller.setStatus("view.dialog.loaddialog.erroroption", true);
				controller.getLog().severe("The attempt to load a project file failed");
				break;
			case JFileChooser.CANCEL_OPTION:
			default:
				return;
			}
			return;
		} while (true);
	}