Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSean Evoy2004-08-05 14:30:42 +0000
committerSean Evoy2004-08-05 14:30:42 +0000
commit39dd636454e8559471c4a86f4a4c0a85b507436b (patch)
tree83646004a057f3effd07c474980bd533bc037157 /build/org.eclipse.cdt.managedbuilder.ui/src
parent172c988cf8d3eba6f968194ea89b55c0dd2b6f5a (diff)
downloadorg.eclipse.cdt-39dd636454e8559471c4a86f4a4c0a85b507436b.tar.gz
org.eclipse.cdt-39dd636454e8559471c4a86f4a4c0a85b507436b.tar.xz
org.eclipse.cdt-39dd636454e8559471c4a86f4a4c0a85b507436b.zip
Commit for Leo Treggiari: bugzilla 70577 and 71254.
Diffstat (limited to 'build/org.eclipse.cdt.managedbuilder.ui/src')
-rw-r--r--build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildOptionSettingsPage.java4
-rw-r--r--build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolSettingsPage.java11
-rw-r--r--build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolsSettingsStore.java4
3 files changed, 16 insertions, 3 deletions
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildOptionSettingsPage.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildOptionSettingsPage.java
index 2236eb2265..2603c2abb0 100644
--- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildOptionSettingsPage.java
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildOptionSettingsPage.java
@@ -68,9 +68,11 @@ public class BuildOptionSettingsPage extends BuildSettingsPage {
fieldsList.add(booleanField);
break;
case IOption.ENUMERATED :
+ String selId;
String sel;
try {
- sel = opt.getSelectedEnum();
+ selId = opt.getSelectedEnum();
+ sel = opt.getEnumName(selId);
} catch (BuildException e) {
// If we get this exception, then the option type is
// wrong
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolSettingsPage.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolSettingsPage.java
index 8c36b835fc..02833e1088 100644
--- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolSettingsPage.java
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolSettingsPage.java
@@ -184,8 +184,15 @@ public class BuildToolSettingsPage extends BuildSettingsPage {
IOption option = options[k];
switch (option.getValueType()) {
case IOption.BOOLEAN :
+ String boolCmd;
if (getPreferenceStore().getBoolean(option.getId())) {
- buf.append(option.getCommand() + ITool.WHITE_SPACE);
+ boolCmd = option.getCommand();
+ } else {
+ // Note: getCommandFalse is new with CDT 2.0
+ boolCmd = option.getCommandFalse();
+ }
+ if (boolCmd != null && boolCmd.length() > 0) {
+ buf.append(boolCmd + ITool.WHITE_SPACE);
}
break;
case IOption.ENUMERATED :
@@ -199,10 +206,12 @@ public class BuildToolSettingsPage extends BuildSettingsPage {
}
break;
case IOption.STRING :
+ String strCmd = option.getCommand();
String val = getPreferenceStore().getString(option.getId());
// add this string option value to the list
stringOptionsMap.put(option, val);
if (val.length() > 0) {
+ if (strCmd != null) buf.append(strCmd);
buf.append(val + ITool.WHITE_SPACE);
}
break;
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolsSettingsStore.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolsSettingsStore.java
index f164cab091..9507da90b5 100644
--- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolsSettingsStore.java
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildToolsSettingsStore.java
@@ -232,7 +232,9 @@ public class BuildToolsSettingsStore implements IPreferenceStore {
case IOption.ENUMERATED :
try{
- value = opt.getSelectedEnum();
+ String selId;
+ selId = opt.getSelectedEnum();
+ value = opt.getEnumName(selId);
} catch (BuildException e) {
break;
}

Back to the top