1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Checked in the patch from Bob Monteleone that fixes the problem with updating a CDT 1.2 project to CDT 3.0 where a property of type enumeration has changed

This commit is contained in:
Mikhail Sennikovsky 2005-07-29 13:28:03 +00:00
parent b2aff9b7c5
commit 09ed69dcb6

View file

@ -385,6 +385,12 @@ class UpdateManagedProject12 {
String name = optRef.getAttribute(IOption.DEFAULT_VALUE);
// Convert it to the ID
String idValue = newOpt.getEnumeratedId(name);
if (idValue == null) {
// If the name does not match one of the enumerations values, probably because
// the list of enumerands has changed, set the name to be the name used for the
// enumeration's default value
name = (String)newOpt.getDefaultValue();
}
configuration.setOption(tool, newOpt, idValue != null ? idValue : name);
break;
case IOption.STRING_LIST: