diff options
author | Michael Wright <michaelwr@google.com> | 2012-06-29 14:10:45 -0700 |
---|---|---|
committer | Michael Wright <michaelwr@google.com> | 2012-07-23 15:24:50 -0700 |
commit | 8f82fb0427e37162e0e2243785276a36946f3748 (patch) | |
tree | d4cf2565b72df7aaeec2652ba5e288b8691df9d6 /sdkmanager/app | |
parent | df97f7f5c9f5148d32dac2e2ed98bc6862fe5fc6 (diff) | |
download | sdk-8f82fb0427e37162e0e2243785276a36946f3748.zip sdk-8f82fb0427e37162e0e2243785276a36946f3748.tar.gz sdk-8f82fb0427e37162e0e2243785276a36946f3748.tar.bz2 |
Fixed AvdManager to only have one instance per SDK location
Change-Id: I59697ef605e33a9216ed318190060e71ce0df579
Diffstat (limited to 'sdkmanager/app')
-rw-r--r-- | sdkmanager/app/src/com/android/sdkmanager/Main.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sdkmanager/app/src/com/android/sdkmanager/Main.java b/sdkmanager/app/src/com/android/sdkmanager/Main.java index bbfbdcc..3d08574 100644 --- a/sdkmanager/app/src/com/android/sdkmanager/Main.java +++ b/sdkmanager/app/src/com/android/sdkmanager/Main.java @@ -1007,7 +1007,7 @@ public class Main { */ private void displayAvdList() { try { - AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog); + AvdManager avdManager = AvdManager.getInstance(mSdkManager, mSdkLog); displayAvdList(avdManager); } catch (AndroidLocationException e) { errorAndExit(e.getMessage()); @@ -1031,7 +1031,7 @@ public class Main { try { boolean removePrevious = mSdkCommandLine.getFlagForce(); - AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog); + AvdManager avdManager = AvdManager.getInstance(mSdkManager, mSdkLog); String avdName = mSdkCommandLine.getParamName(); @@ -1157,7 +1157,7 @@ public class Main { private void deleteAvd() { try { String avdName = mSdkCommandLine.getParamName(); - AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog); + AvdManager avdManager = AvdManager.getInstance(mSdkManager, mSdkLog); AvdInfo info = avdManager.getAvd(avdName, false /*validAvdOnly*/); if (info == null) { @@ -1177,7 +1177,7 @@ public class Main { private void moveAvd() { try { String avdName = mSdkCommandLine.getParamName(); - AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog); + AvdManager avdManager = AvdManager.getInstance(mSdkManager, mSdkLog); AvdInfo info = avdManager.getAvd(avdName, true /*validAvdOnly*/); if (info == null) { @@ -1273,7 +1273,7 @@ public class Main { private void updateAvd() { try { String avdName = mSdkCommandLine.getParamName(); - AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog); + AvdManager avdManager = AvdManager.getInstance(mSdkManager, mSdkLog); avdManager.updateAvd(avdName, mSdkLog); } catch (AndroidLocationException e) { errorAndExit(e.getMessage()); |