Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWalter Harley2006-01-20 01:04:48 +0000
committerWalter Harley2006-01-20 01:04:48 +0000
commit6fea7eafdd413dccff31028f8da1f1ac6859e6fe (patch)
treed21f8a6a1a96c18c4c4706c412bbf5f2a589b773 /org.eclipse.jdt.apt.ui
parentc4c0df5e4aeb7d3e8571312c597020a7d0812327 (diff)
downloadeclipse.jdt.core-6fea7eafdd413dccff31028f8da1f1ac6859e6fe.tar.gz
eclipse.jdt.core-6fea7eafdd413dccff31028f8da1f1ac6859e6fe.tar.xz
eclipse.jdt.core-6fea7eafdd413dccff31028f8da1f1ac6859e6fe.zip
wharley - merge from 3.1.1 to 3.2. Base of merge is v20060120-0034.
Diffstat (limited to 'org.eclipse.jdt.apt.ui')
-rw-r--r--org.eclipse.jdt.apt.ui/scripts/exportplugin.xml2
-rw-r--r--org.eclipse.jdt.apt.ui/src/org/eclipse/jdt/apt/ui/internal/preferences/AptConfigurationBlock.java23
2 files changed, 6 insertions, 19 deletions
diff --git a/org.eclipse.jdt.apt.ui/scripts/exportplugin.xml b/org.eclipse.jdt.apt.ui/scripts/exportplugin.xml
index 4313f06548..7ed0bfe024 100644
--- a/org.eclipse.jdt.apt.ui/scripts/exportplugin.xml
+++ b/org.eclipse.jdt.apt.ui/scripts/exportplugin.xml
@@ -22,7 +22,7 @@
<target name="export plug-in [_1.0.0]">
<antcall target="zz_internal_export">
- <param name="plugin_version" value="3.1.1.apt02"/>
+ <param name="plugin_version" value="3.1.1.apt03"/>
</antcall>
</target>
diff --git a/org.eclipse.jdt.apt.ui/src/org/eclipse/jdt/apt/ui/internal/preferences/AptConfigurationBlock.java b/org.eclipse.jdt.apt.ui/src/org/eclipse/jdt/apt/ui/internal/preferences/AptConfigurationBlock.java
index 3e0206c0c5..1a52069517 100644
--- a/org.eclipse.jdt.apt.ui/src/org/eclipse/jdt/apt/ui/internal/preferences/AptConfigurationBlock.java
+++ b/org.eclipse.jdt.apt.ui/src/org/eclipse/jdt/apt/ui/internal/preferences/AptConfigurationBlock.java
@@ -20,7 +20,6 @@ import java.util.Map;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.preferences.IScopeContext;
import org.eclipse.jdt.apt.core.AptPlugin;
import org.eclipse.jdt.apt.core.util.AptConfig;
@@ -326,13 +325,11 @@ public class AptConfigurationBlock extends BaseConfigurationBlock {
elements = getListElements();
}
saveProcessorOptions(elements);
- fAptProject.handlePreferenceChange(
- AptPreferenceConstants.APT_GENSRCDIR, fOriginalGenSrcDir, fGenSrcDirField.getText());
- fAptProject.handlePreferenceChange(
- AptPreferenceConstants.APT_ENABLED,
- Boolean.toString(fOriginalAptEnabled),
- Boolean.toString(fAptEnabledField.isSelected()));
super.saveSettings();
+ if (!fOriginalGenSrcDir.equals(fGenSrcDirField.getText()))
+ fAptProject.preferenceChanged(AptPreferenceConstants.APT_GENSRCDIR);
+ if (fOriginalAptEnabled != fAptEnabledField.isSelected())
+ fAptProject.preferenceChanged(AptPreferenceConstants.APT_ENABLED);
}
/**
@@ -383,20 +380,10 @@ public class AptConfigurationBlock extends BaseConfigurationBlock {
* @return
*/
private IStatus validateGenSrcDir() {
- // TODO: this check should be delegated to a validation routine in apt.core.
String dirName = fGenSrcDirField.getText();
- Path path = null;
- if (dirName != null) {
- path= new Path(dirName);
- }
- if (path == null ||
- path.isAbsolute() ||
- path.isEmpty() ||
- !path.isValidPath(dirName) ||
- !dirName.trim().equals(dirName)) {
+ if (!AptConfig.validateGenSrcDir(fJProj, dirName)) {
return new StatusInfo(IStatus.ERROR, Messages.AptConfigurationBlock_genSrcDirMustBeValidRelativePath);
}
- // TODO: how can we tell whether dirName points to a "normal" src directory?
return new StatusInfo();
}

Back to the top