summaryrefslogtreecommitdiffstats
path: root/ajde/src
diff options
context:
space:
mode:
authoracolyer <acolyer>2003-05-09 09:21:08 +0000
committeracolyer <acolyer>2003-05-09 09:21:08 +0000
commitd74d7bfa222e384f4fad1f01d5ea27f209677fea (patch)
treeb8317e4979417cbd487268fdc5698f8463689922 /ajde/src
parentf51347e6c045584422b3adf0fc37645576c7b2c5 (diff)
downloadaspectj-d74d7bfa222e384f4fad1f01d5ea27f209677fea.tar.gz
aspectj-d74d7bfa222e384f4fad1f01d5ea27f209677fea.zip
Added persist member.
Diffstat (limited to 'ajde/src')
-rw-r--r--ajde/src/org/aspectj/ajde/ui/internal/UserPreferencesStore.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/ajde/src/org/aspectj/ajde/ui/internal/UserPreferencesStore.java b/ajde/src/org/aspectj/ajde/ui/internal/UserPreferencesStore.java
index 722e18577..f6ca2d439 100644
--- a/ajde/src/org/aspectj/ajde/ui/internal/UserPreferencesStore.java
+++ b/ajde/src/org/aspectj/ajde/ui/internal/UserPreferencesStore.java
@@ -33,13 +33,15 @@ public class UserPreferencesStore implements UserPreferencesAdapter {
public static final String FILE_NAME = "/.ajbrowser";
private final String VALUE_SEP = ";";
private Properties properties = new Properties();
+ private boolean persist = true;
public UserPreferencesStore() {
this(true);
}
public UserPreferencesStore(boolean loadDefault) {
- if (loadDefault) {
+ persist = loadDefault;
+ if (persist) {
loadProperties(getPropertiesFilePath());
}
}
@@ -123,6 +125,8 @@ public class UserPreferencesStore implements UserPreferencesAdapter {
}
}
public void saveProperties() {
+ if (!persist) return;
+
FileOutputStream out = null;
String path = null;
try {