aboutsummaryrefslogtreecommitdiffstats
path: root/sdkmanager/libs
diff options
context:
space:
mode:
authorRaphael Moll <ralf@android.com>2012-11-26 15:06:11 -0800
committerGerrit Code Review <noreply-gerritcodereview@google.com>2012-11-26 15:06:12 -0800
commit66ea266d64c6710a03a4531ebdf486037844bfcc (patch)
treef9f1b34971fe879e4e820e0175b1cfbe5a0a46b0 /sdkmanager/libs
parente34bfe70f739bc0640c0bd955527007b8be9ce92 (diff)
parent15832585a03db4e9ccb0b9732c7c9fd2677f8529 (diff)
downloadsdk-66ea266d64c6710a03a4531ebdf486037844bfcc.zip
sdk-66ea266d64c6710a03a4531ebdf486037844bfcc.tar.gz
sdk-66ea266d64c6710a03a4531ebdf486037844bfcc.tar.bz2
Merge "SDK Manager: auto-select Support Library at startup."
Diffstat (limited to 'sdkmanager/libs')
-rwxr-xr-xsdkmanager/libs/sdkuilib/src/com/android/sdkuilib/internal/repository/core/PackagesDiffLogic.java20
1 files changed, 16 insertions, 4 deletions
diff --git a/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/internal/repository/core/PackagesDiffLogic.java b/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/internal/repository/core/PackagesDiffLogic.java
index f5a2ed3..a95c8ac 100755
--- a/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/internal/repository/core/PackagesDiffLogic.java
+++ b/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/internal/repository/core/PackagesDiffLogic.java
@@ -252,18 +252,30 @@ public class PackagesDiffLogic {
}
}
- if (selectTop && currentPlatform == SdkConstants.PLATFORM_WINDOWS) {
- // On Windows, we'll also auto-select the USB driver
+ if (selectTop) {
for (PkgItem item : getAllPkgItems(true /*byApi*/, true /*bySource*/)) {
Package p = item.getMainPackage();
if (p instanceof ExtraPackage &&
item.getState() == PkgState.NEW &&
!item.getRevision().isPreview()) {
ExtraPackage ep = (ExtraPackage) p;
- if (ep.getVendorId().equals("google") && //$NON-NLS-1$
- ep.getPath().equals("usb_driver")) { //$NON-NLS-1$
+
+ // On Windows, we'll also auto-select the USB driver
+ if (currentPlatform == SdkConstants.PLATFORM_WINDOWS) {
+ if (ep.getVendorId().equals("google") && //$NON-NLS-1$
+ ep.getPath().equals("usb_driver")) { //$NON-NLS-1$
+ item.setChecked(true);
+ continue;
+ }
+ }
+
+ // On all platforms, we'll auto-select the support library.
+ if (ep.getVendorId().equals("android") && //$NON-NLS-1$
+ ep.getPath().equals("support")) { //$NON-NLS-1$
item.setChecked(true);
+ continue;
}
+
}
}
}