aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaphael Moll <ralf@android.com>2010-06-29 15:06:39 -0700
committerAndroid Code Review <code-review@android.com>2010-06-29 15:06:39 -0700
commit1d21469ba4c7a69dc96f264d979c03b8a189a9cf (patch)
tree5561c46ee45f8fe29252f9029819810f64f9a173
parent816ed429281b40ec2b8545409bef6f833ef3c5ff (diff)
parentb6fd70d47d0d9ac4080ffb3d58bcf55375453561 (diff)
downloadsdk-1d21469ba4c7a69dc96f264d979c03b8a189a9cf.zip
sdk-1d21469ba4c7a69dc96f264d979c03b8a189a9cf.tar.gz
sdk-1d21469ba4c7a69dc96f264d979c03b8a189a9cf.tar.bz2
Merge "ADT: Fix NPE in ConfigComposite"
-rw-r--r--eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/configuration/ConfigurationComposite.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/configuration/ConfigurationComposite.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/configuration/ConfigurationComposite.java
index 89285bf..4b1d5f6 100644
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/configuration/ConfigurationComposite.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/configuration/ConfigurationComposite.java
@@ -189,9 +189,12 @@ public class ConfigurationComposite extends Composite {
sb.append(configName);
sb.append(SEP);
if (locale != null) {
- sb.append(((LanguageQualifier) locale[0]).getValue());
- sb.append(SEP_LOCALE);
- sb.append(((RegionQualifier) locale[1]).getValue());
+ if (locale[0] != null && locale[1] != null) {
+ // locale[0]/[1] can be null sometimes when starting Eclipse
+ sb.append(((LanguageQualifier) locale[0]).getValue());
+ sb.append(SEP_LOCALE);
+ sb.append(((RegionQualifier) locale[1]).getValue());
+ }
}
sb.append(SEP);
sb.append(theme);