aboutsummaryrefslogtreecommitdiffstats
path: root/ddms/app
diff options
context:
space:
mode:
authorRaphael Moll <ralf@android.com>2010-11-13 10:59:21 -0800
committerRaphael Moll <ralf@android.com>2010-11-15 10:30:53 -0800
commit710d2bb191d5a1cfe3e5d8ffef5566fd8193da11 (patch)
treebd9017911f322c402b89bd14ecfe4142f9263848 /ddms/app
parent6420b490b26047e05c890c4fb0db65f687142fce (diff)
downloadsdk-710d2bb191d5a1cfe3e5d8ffef5566fd8193da11.zip
sdk-710d2bb191d5a1cfe3e5d8ffef5566fd8193da11.tar.gz
sdk-710d2bb191d5a1cfe3e5d8ffef5566fd8193da11.tar.bz2
Use env var com.android.ddms.bindir for ddms.
The env var is used if the system property is not defined, which is convenient to start ddms in debug mode from Eclipse. Change-Id: I2a33c12399c703cf3194e2e67f39562ab0d59bd9
Diffstat (limited to 'ddms/app')
-rw-r--r--ddms/app/src/com/android/ddms/Main.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/ddms/app/src/com/android/ddms/Main.java b/ddms/app/src/com/android/ddms/Main.java
index 0c55078..c8bab66 100644
--- a/ddms/app/src/com/android/ddms/Main.java
+++ b/ddms/app/src/com/android/ddms/Main.java
@@ -84,6 +84,12 @@ public class Main {
// get the ddms parent folder location
String ddmsParentLocation = System.getProperty("com.android.ddms.bindir"); //$NON-NLS-1$
+ if (ddmsParentLocation == null) {
+ // Tip: for debugging DDMS in eclipse, set this env var to the SDK/tools
+ // directory path.
+ ddmsParentLocation = System.getenv("com.android.ddms.bindir"); //$NON-NLS-1$
+ }
+
// we're past the point where ddms can be called just to send a ping, so we can
// ping for ddms itself.
ping(ddmsParentLocation);