OSDN Git Service

AI 146508: am: CL 146035 am: CL 146034 ADT #1786173: NPW should not overwritte user...
authorRaphael Moll <>
Thu, 16 Apr 2009 18:44:28 +0000 (11:44 -0700)
committerThe Android Open Source Project <initial-contribution@android.com>
Thu, 16 Apr 2009 18:44:28 +0000 (11:44 -0700)
  Original author: raphael
  Merged from: //branches/cupcake/...
  Original author: android-build

Automated import of CL 146508

eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectCreationPage.java

index 6e8ff47..61b1534 100644 (file)
@@ -661,7 +661,7 @@ public class NewProjectCreationPage extends WizardPage {
                                                  abs_dir.equals(sCustomLocationOsPath);
                     sCustomLocationOsPath = TextProcessor.process(abs_dir);
                 } else  if (sAutoComputeCustomLocation ||
-                            !new File(sCustomLocationOsPath).isDirectory()) {
+                            (!is_new_project && !new File(sCustomLocationOsPath).isDirectory())) {
                     // By default select the samples directory of the current target
                     IAndroidTarget target = getSdkTarget();
                     if (target != null) {