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
fExportedClassContainers= new HashSet(10);
		int n= fJarPackage.getElements().length;
		for (int i= 0; i < n; i++)
			exportElement(fJarPackage.getElements()[i], progressMonitor);
	}
	/**
	 * Returns an iterator on a list with files that correspond to the
	 * passed file and that are on the classpath of its project.
	 *
	 * @param	file			the file for which to find the corresponding classpath resources
	 * @param	pathInJar		the path that the file has in the JAR (i.e. project and source folder segments removed)
	 * @param	javaProject		the javaProject that contains the file
	 * @return	the iterator over the corresponding classpath files for the given file
	 */
	protected Iterator filesOnClasspath(IFile file, IPath pathInJar, IJavaProject javaProject, IProgressMonitor progressMonitor) throws CoreException {
		
		IFile[] classFiles= fJarPackage.findClassfilesFor(file);
		if (classFiles != null)
			return Arrays.asList(classFiles).iterator();
		if (!isJavaFile(file))
			return Collections.EMPTY_LIST.iterator();
		
		IPath outputPath= javaProject.getOutputLocation();
		IContainer outputContainer;		
		if (javaProject.getProject().getFullPath().equals(outputPath))
			outputContainer= javaProject.getProject();
		else {
			outputContainer= createFolderHandle(outputPath);
			if (outputContainer == null || !outputContainer.isAccessible()) {
				String msg= JarPackagerMessages.getString("JarFileExportOperation.outputContainerNotAccessible");