diff --git a/app/build.gradle b/app/build.gradle index 847036f..4649532 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -56,11 +56,11 @@ repositories { dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) - implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlinVersion" + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion" implementation "com.android.support:design:$supportVersion" testImplementation 'junit:junit:4.12' - androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1' + androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' implementation 'com.github.naz013:ColorSlider:1.0.3' diff --git a/app/src/main/res/layout/fragment_viewgroup.xml b/app/src/main/res/layout/fragment_viewgroup.xml index 5dbd607..518c600 100644 --- a/app/src/main/res/layout/fragment_viewgroup.xml +++ b/app/src/main/res/layout/fragment_viewgroup.xml @@ -2,10 +2,16 @@ + android:padding="@dimen/margin" + app:maskColor="@color/colorPrimary" + app:maskCornerRadius="10dp" + app:showShimmer="true" + app:shimmerColor="@color/colorPrimaryDark" + app:shimmerDurationInMillis="2000"> diff --git a/build.gradle b/build.gradle index f6dc8ce..7b35ff0 100644 --- a/build.gradle +++ b/build.gradle @@ -5,8 +5,8 @@ buildscript { targetSdk = 27 kotlinVersion = '1.2.41' supportVersion = '27.1.1' - projectVersion = '1.0.0' - projectVersionCode = 1 + projectVersion = '1.0.1' + projectVersionCode = 2 } repositories { @@ -15,7 +15,7 @@ buildscript { } dependencies { - classpath 'com.android.tools.build:gradle:3.1.2' + classpath 'com.android.tools.build:gradle:3.1.3' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion" classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.0' classpath 'com.github.dcendents:android-maven-gradle-plugin:2.0' diff --git a/skeletonlayout/build.gradle b/skeletonlayout/build.gradle index cd7e488..06410b1 100644 --- a/skeletonlayout/build.gradle +++ b/skeletonlayout/build.gradle @@ -41,7 +41,7 @@ dependencies { api "com.android.support:recyclerview-v7:$supportVersion" testImplementation 'junit:junit:4.12' - androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1' + androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' } apply from: 'deploy.gradle' \ No newline at end of file diff --git a/skeletonlayout/src/main/kotlin/com/faltenreich/skeletonlayout/SkeletonLayout.kt b/skeletonlayout/src/main/kotlin/com/faltenreich/skeletonlayout/SkeletonLayout.kt index c4a1d16..4582711 100644 --- a/skeletonlayout/src/main/kotlin/com/faltenreich/skeletonlayout/SkeletonLayout.kt +++ b/skeletonlayout/src/main/kotlin/com/faltenreich/skeletonlayout/SkeletonLayout.kt @@ -70,7 +70,7 @@ class SkeletonLayout @JvmOverloads constructor( attrs?.let { val typedArray = context.obtainStyledAttributes(it, R.styleable.SkeletonLayout, 0, 0) this.maskColor = typedArray.getColor(R.styleable.SkeletonLayout_maskColor, maskColor) - this.maskCornerRadius = typedArray.getFloat(R.styleable.SkeletonLayout_cornerRadius, cornerRadius) + this.maskCornerRadius = typedArray.getDimensionPixelSize(R.styleable.SkeletonLayout_maskCornerRadius, cornerRadius.toInt()).toFloat() this.showShimmer = typedArray.getBoolean(R.styleable.SkeletonLayout_showShimmer, showShimmer) this.shimmerColor = typedArray.getColor(R.styleable.SkeletonLayout_shimmerColor, shimmerColor) this.shimmerDurationInMillis = typedArray.getInt(R.styleable.SkeletonLayout_shimmerDurationInMillis, shimmerDurationInMillis.toInt()).toLong() diff --git a/skeletonlayout/src/main/res/values/attrs.xml b/skeletonlayout/src/main/res/values/attrs.xml index da5bc14..a47c017 100644 --- a/skeletonlayout/src/main/res/values/attrs.xml +++ b/skeletonlayout/src/main/res/values/attrs.xml @@ -4,7 +4,7 @@ - +