Bug 15877 Jar export wizard (driver 020502)
Hi, I really don't know if this is the correct category for this bug. Sorry if I am at the wrong place. The option of saving the "export to jar" wizard settings on a file is really good. The only problem is that if I activate the Jar wizard again (not using the jardesc file) to do an export that I don't to create a jardesc for, all the previous settings are loaded again, including the jardesc file name. Since this information is on the 2nd or 3rd page, I got it rewrite without knowing it. Maybe the export wizard should keep the previous settings only if a jardesc is NOT created (afterall why do I need then persisted between wizard activations if I saved the information?).
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/jarpackager/JarFileExportOperation.java
* @param	jarPackages		an array with JAR package data objects
	 * @param	parent			the parent for the dialog,
	 * 			or <code>null</code> if no dialog should be presented
	 */
	public JarFileExportOperation(JarPackageData[] jarPackages, Shell parent) {
		this(parent);
		fJarPackages= jarPackages;
	}
	private JarFileExportOperation(Shell parent) {
		fParentShell= parent;
		fStatus= new MessageMultiStatus(JavaPlugin.getPluginId(), IStatus.OK, "", null); 
	}
	protected void addToStatus(CoreException ex) {
		IStatus status= ex.getStatus();
		String message= ex.getLocalizedMessage();
		if (message == null || message.length() < 1) {
			message= JarPackagerMessages.getString("JarFileExportOperation.coreErrorDuringExport"); 
			status= new Status(status.getSeverity(), status.getPlugin(), status.getCode(), message, ex);
		}		
		fStatus.add(status);
	}
	/**
	 * Adds a new info to the list with the passed information.
	 * Normally the export operation continues after a warning.
	 * @param	message		the message
	 * @param	exception	the throwable that caused the warning, or <code>null</code>
	 */
	protected void addInfo(String message, Throwable error) {
		fStatus.add(new Status(IStatus.INFO, JavaPlugin.getPluginId(), JavaStatusConstants.INTERNAL_ERROR, message, error));
	}