- Remove the dark variant of button icons, since it is now tinted to the desired color - Use DrawableCompat.setTintList to tint the drawables to the same color used as text - Use textColorPrimary as the navigation text color, since the spec now matches the default textColorPrimary implementation of material theme (This changes the disabled color from 20% alpha to 26% alpha) - Configured the build to take two different implementations of NavigationBarButton. The platform build is the same as Button, since drawable tinting is natively supported. The comapt build uses DrawableCompat in the support library to tint any compound drawables - Removed all xxxhdpi assets since that was introduced in L, but vector assets are used in L instead. - For the vector drawables, use tint instead of fillColor so that the state in the ColorStateList will be taken into account. Bug: 22129308 Change-Id: Id0c7b40ad3e71c2c66a0e89df4522865a61e923e
85 lines
2.9 KiB
Groovy
85 lines
2.9 KiB
Groovy
/**
|
|
* Base rules for building setup wizard library. This build file is not used directly but rather
|
|
* included in scripts like build.gradle or standalone.gradle using 'apply from'.
|
|
*
|
|
* This allows the dependencies to be configured so that for builds in the Android tree, the
|
|
* dependencies like support library is built directly from source, while for standalone builds they
|
|
* will be fetched from maven central.
|
|
*/
|
|
|
|
apply plugin: 'com.android.library'
|
|
|
|
android {
|
|
|
|
publishNonDefault true
|
|
|
|
sourceSets {
|
|
main {
|
|
manifest.srcFile 'main/AndroidManifest.xml'
|
|
java.srcDirs = ['main/src']
|
|
resources.srcDirs = ['main/src']
|
|
res.srcDirs = ['main/res']
|
|
}
|
|
|
|
productFlavors {
|
|
// Platform version that will not include the compatibility libraries
|
|
platform {
|
|
minSdkVersion 21
|
|
}
|
|
|
|
// Compatibility build that provides the L layout for SDK versions ICS+
|
|
icsCompat {
|
|
minSdkVersion 14
|
|
dependencies {
|
|
// Read the dependencies from the "deps" map in the extra properties.
|
|
//
|
|
// For builds in the Android tree we want to build the dependencies from source
|
|
// for reproducible builds, for example in build.gradle define something like
|
|
// this:
|
|
// ext {
|
|
// deps = ['project-name': project(':project-path')]
|
|
// }
|
|
//
|
|
// For standalone project clients, since the source may not be available, we
|
|
// fetch the dependencies from maven. For example in standalone.gradle define
|
|
// something like this:
|
|
// ext {
|
|
// deps = ['project-name': 'com.example.group:project-name:1.0.0']
|
|
// }
|
|
//
|
|
icsCompatCompile deps['support-appcompat-v7']
|
|
}
|
|
}
|
|
|
|
// Compatibility build that provides the L layout for SDK versions Eclair MR1+
|
|
eclairMr1Compat {
|
|
minSdkVersion 7
|
|
dependencies {
|
|
eclairMr1CompatCompile deps['support-appcompat-v7']
|
|
}
|
|
}
|
|
}
|
|
|
|
platform {
|
|
java.srcDirs = ['platform/src']
|
|
res.srcDirs = ['platform/res']
|
|
}
|
|
|
|
icsCompat {
|
|
java.srcDirs = ['eclair-mr1/src']
|
|
res.srcDirs = ['eclair-mr1/res']
|
|
}
|
|
|
|
eclairMr1Compat {
|
|
java.srcDirs = ['eclair-mr1/src']
|
|
res.srcDirs = ['eclair-mr1/res']
|
|
}
|
|
|
|
androidTest {
|
|
manifest.srcFile 'test/AndroidManifest.xml'
|
|
java.srcDirs = ['test/src']
|
|
res.srcDirs = ['test/res']
|
|
}
|
|
}
|
|
}
|