aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--about/build.gradle11
-rw-r--r--about/progress-proguard.txt4
-rw-r--r--about/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java26
-rw-r--r--about/src/main/kotlin/ca/allanwang/kau/about/CutoutIItem.kt1
-rw-r--r--about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt1
-rw-r--r--about/src/main/res/values/strings_about.xml27
-rw-r--r--about/src/test/java/ca/allanwang/kau/ExampleUnitTest.java17
-rw-r--r--adapter/build.gradle10
-rw-r--r--adapter/src/androidTest/java/ca/allanwang/kau/adapter/ExampleInstrumentedTest.java26
-rw-r--r--adapter/src/test/java/ca/allanwang/kau/adapter/ExampleUnitTest.java17
-rw-r--r--android-lib.gradle (renamed from android.gradle)4
-rw-r--r--build.gradle67
-rw-r--r--colorpicker/build.gradle10
-rw-r--r--colorpicker/src/androidTest/java/ca/allanwang/kau/colorpicker/ExampleInstrumentedTest.java26
-rw-r--r--colorpicker/src/test/java/ca/allanwang/kau/colorpicker/ExampleUnitTest.java17
-rw-r--r--core-ui/build.gradle11
-rw-r--r--core-ui/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java26
-rw-r--r--core-ui/src/test/java/ca/allanwang/kau/ExampleUnitTest.java17
-rw-r--r--core/build.gradle2
-rw-r--r--core/src/androidTest/java/ca/allanwang/kprefs/library/ExampleInstrumentedTest.java2
-rw-r--r--core/src/main/res/values/strings_about.xml27
-rw-r--r--imagepicker/build.gradle4
-rw-r--r--imagepicker/src/main/kotlin/ca/allanwang/kau/imagepicker/ImagePickerActivityBase.kt1
-rw-r--r--kpref-activity/build.gradle10
-rw-r--r--kpref-activity/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java26
-rw-r--r--kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemBase.kt2
-rw-r--r--kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemCore.kt2
-rw-r--r--kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefPlainText.kt2
-rw-r--r--kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSeekbar.kt2
-rw-r--r--kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSubItems.kt2
-rw-r--r--kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefText.kt2
-rw-r--r--kpref-activity/src/main/res/values/strings.xml3
-rw-r--r--kpref-activity/src/test/java/ca/allanwang/kau/ExampleUnitTest.java17
-rw-r--r--sample/build.gradle2
-rw-r--r--sample/proguard-rules.pro33
-rw-r--r--searchbar/build.gradle10
-rw-r--r--searchbar/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java26
-rw-r--r--searchbar/src/test/java/ca/allanwang/kau/ExampleUnitTest.java17
38 files changed, 55 insertions, 455 deletions
diff --git a/about/build.gradle b/about/build.gradle
index 6718145..bb51f9f 100644
--- a/about/build.gradle
+++ b/about/build.gradle
@@ -1,22 +1,13 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
}
dependencies {
- compile fileTree(dir: 'libs', include: ['*.jar'])
- androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
- exclude group: 'com.android.support', module: 'support-annotations'
- })
- testCompile 'junit:junit:4.12'
-
compile project(':core-ui')
compile project(':adapter')
- compile "org.jetbrains.kotlin:kotlin-stdlib:${KOTLIN}"
- testCompile "org.jetbrains.kotlin:kotlin-test-junit:${KOTLIN}"
-
compile("com.mikepenz:aboutlibraries:${ABOUT_LIBRARIES}@aar") {
transitive = true
}
diff --git a/about/progress-proguard.txt b/about/progress-proguard.txt
index 8b13789..cfa4747 100644
--- a/about/progress-proguard.txt
+++ b/about/progress-proguard.txt
@@ -1 +1,3 @@
-
+-keepclasseswithmembers class **.R$* {
+ public static final int define_*;
+}
diff --git a/about/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java b/about/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
deleted file mode 100644
index 7b079b2..0000000
--- a/about/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ca.allanwang.kau;
-
-import android.content.Context;
-import android.support.test.InstrumentationRegistry;
-import android.support.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.*;
-
-/**
- * Instrumentation test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ca.allanwang.kau.test", appContext.getPackageName());
- }
-}
diff --git a/about/src/main/kotlin/ca/allanwang/kau/about/CutoutIItem.kt b/about/src/main/kotlin/ca/allanwang/kau/about/CutoutIItem.kt
index 9a4f6bf..1ba5815 100644
--- a/about/src/main/kotlin/ca/allanwang/kau/about/CutoutIItem.kt
+++ b/about/src/main/kotlin/ca/allanwang/kau/about/CutoutIItem.kt
@@ -2,7 +2,6 @@ package ca.allanwang.kau.about
import android.support.v7.widget.RecyclerView
import android.view.View
-import ca.allanwang.kau.about.R
import ca.allanwang.kau.adapters.ThemableIItem
import ca.allanwang.kau.adapters.ThemableIItemDelegate
import ca.allanwang.kau.ui.views.CutoutView
diff --git a/about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt b/about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt
index 82d71dc..b5e2c28 100644
--- a/about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt
+++ b/about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt
@@ -6,7 +6,6 @@ import android.support.v7.widget.RecyclerView
import android.text.Html
import android.view.View
import android.widget.TextView
-import ca.allanwang.kau.about.R
import ca.allanwang.kau.adapters.ThemableIItem
import ca.allanwang.kau.adapters.ThemableIItemDelegate
import ca.allanwang.kau.utils.bindView
diff --git a/about/src/main/res/values/strings_about.xml b/about/src/main/res/values/strings_about.xml
new file mode 100644
index 0000000..35ffeb2
--- /dev/null
+++ b/about/src/main/res/values/strings_about.xml
@@ -0,0 +1,27 @@
+<resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="ResourceName">
+ <string name="library_kau_libraryVersion">1.5</string>
+
+ <string name="define_kau"/>
+ <!-- Author section -->
+ <string name="library_kau_author">Allan Wang</string>
+ <string name="library_kau_authorWebsite">https://www.allanwang.ca/dev/</string>
+ <!-- Library section -->
+ <string name="library_kau_libraryName">KAU</string>
+ <string name="library_kau_libraryDescription">
+ <![CDATA[
+ An extensive collection of Kotlin Android Utilities.
+ <br/><br/>
+ KAU aims to make many common functions executable in one line. It adds numerous extensions to match Kotlin\'s DSL,
+ and supports completely customizable view groups that are used in almost any app project.
+ ]]>
+ </string>
+ <string name="library_kau_libraryWebsite">https://allanwang.github.io/KAU/</string>
+ <!-- OpenSource section -->
+ <string name="library_kau_isOpenSource">true</string>
+ <string name="library_kau_repositoryLink">https://github.com/AllanWang/KAU</string>
+ <!-- ClassPath for autoDetect section -->
+ <string name="library_kau_classPath">ca.allanwang.kau</string>
+ <!-- License section -->
+ <string name="library_kau_licenseId">apache_2_0</string>
+ <!-- Custom variables section -->
+</resources> \ No newline at end of file
diff --git a/about/src/test/java/ca/allanwang/kau/ExampleUnitTest.java b/about/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
deleted file mode 100644
index a29b447..0000000
--- a/about/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ca.allanwang.kau;
-
-import org.junit.Test;
-
-import static org.junit.Assert.*;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file
diff --git a/adapter/build.gradle b/adapter/build.gradle
index 7894627..bdeee97 100644
--- a/adapter/build.gradle
+++ b/adapter/build.gradle
@@ -1,21 +1,13 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
}
dependencies {
- compile fileTree(dir: 'libs', include: ['*.jar'])
- androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
- exclude group: 'com.android.support', module: 'support-annotations'
- })
- testCompile 'junit:junit:4.12'
compile project(':core')
- compile "org.jetbrains.kotlin:kotlin-stdlib:${KOTLIN}"
- testCompile "org.jetbrains.kotlin:kotlin-test-junit:${KOTLIN}"
-
compile "com.mikepenz:fastadapter:${FAST_ADAPTER}@aar"
compile "com.mikepenz:fastadapter-commons:${FAST_ADAPTER_COMMONS}@aar"
}
diff --git a/adapter/src/androidTest/java/ca/allanwang/kau/adapter/ExampleInstrumentedTest.java b/adapter/src/androidTest/java/ca/allanwang/kau/adapter/ExampleInstrumentedTest.java
deleted file mode 100644
index 3e64d38..0000000
--- a/adapter/src/androidTest/java/ca/allanwang/kau/adapter/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ca.allanwang.kau.adapter;
-
-import android.content.Context;
-import android.support.test.InstrumentationRegistry;
-import android.support.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.*;
-
-/**
- * Instrumentation test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ca.allanwang.kau.adapter.test", appContext.getPackageName());
- }
-}
diff --git a/adapter/src/test/java/ca/allanwang/kau/adapter/ExampleUnitTest.java b/adapter/src/test/java/ca/allanwang/kau/adapter/ExampleUnitTest.java
deleted file mode 100644
index 5684bab..0000000
--- a/adapter/src/test/java/ca/allanwang/kau/adapter/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ca.allanwang.kau.adapter;
-
-import org.junit.Test;
-
-import static org.junit.Assert.*;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file
diff --git a/android.gradle b/android-lib.gradle
index 7d3db8f..558e99d 100644
--- a/android.gradle
+++ b/android-lib.gradle
@@ -17,8 +17,6 @@ android {
defaultConfig {
minSdkVersion Integer.parseInt(project.MIN_SDK)
targetSdkVersion Integer.parseInt(project.TARGET_SDK)
-// versionCode androidGitVersion.code()
-// versionName androidGitVersion.name()
consumerProguardFiles 'progress-proguard.txt'
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
@@ -29,7 +27,7 @@ android {
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
-
+
lintOptions {
abortOnError false
checkReleaseBuilds false
diff --git a/build.gradle b/build.gradle
index 960f7e6..fcd2d23 100644
--- a/build.gradle
+++ b/build.gradle
@@ -4,7 +4,6 @@ buildscript {
repositories {
jcenter()
maven { url 'https://maven.fabric.io/public' }
- maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
@@ -15,69 +14,9 @@ buildscript {
}
}
-//plugins {
-// id 'com.gladed.androidgitversion' version '0.3.4' apply false
-//}
-
-//configure(subprojects - project(':sample')) {
-//// apply plugin: 'com.gladed.androidgitversion'
-//// apply from: '../extra.gradle'
-// apply plugin: 'com.android.library'
-// apply plugin: 'kotlin-android'
-// apply plugin: 'com.github.dcendents.android-maven'
-//
-//// if (!it.plugins.hasPlugin('com.gladed.androidgitversion')) apply plugin: 'com.gladed.androidgitversion'
-//// else dependencies {
-//// compile project(':core')
-//// }
-//
-// group = project.APP_GROUP
-//
-// repositories {
-// jcenter()
-// mavenCentral()
-// maven { url "https://jitpack.io" }
-// maven { url "https://maven.google.com" }
-// }
-//
-// android {
-// compileSdkVersion Integer.parseInt(project.TARGET_SDK)
-// buildToolsVersion project.BUILD_TOOLS
-//
-//// androidGitVersion {
-//// codeFormat = 'MMNNPPBB'
-//// prefix 'v'
-//// }
-//
-// defaultConfig {
-// minSdkVersion Integer.parseInt(project.MIN_SDK)
-// targetSdkVersion Integer.parseInt(project.TARGET_SDK)
-//// versionCode androidGitVersion.code()
-//// versionName androidGitVersion.name()
-// consumerProguardFiles 'progress-proguard.txt'
-// testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
-// }
-// buildTypes {
-// release {
-// minifyEnabled false
-// proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
-// }
-// }
-// lintOptions {
-// abortOnError false
-// checkReleaseBuilds false
-// }
-// resourcePrefix "kau_color"
-// sourceSets {
-// main.java.srcDirs += 'src/main/kotlin'
-// test.java.srcDirs += 'src/test/kotlin'
-// }
-// }
-//}
-
-//task clean(type: Delete) {
-// delete rootProject.buildDir
-//}
+task clean(type: Delete) {
+ delete rootProject.buildDir
+}
task generateChangelogMd() {
def parsedProjectXml = (new XmlParser()).parse("$project.rootDir/sample/src/main/res/xml/changelog.xml")
diff --git a/colorpicker/build.gradle b/colorpicker/build.gradle
index 5972ea3..c522e9f 100644
--- a/colorpicker/build.gradle
+++ b/colorpicker/build.gradle
@@ -1,20 +1,12 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_color_"
}
dependencies {
- compile fileTree(dir: 'libs', include: ['*.jar'])
- androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
- exclude group: 'com.android.support', module: 'support-annotations'
- })
- testCompile 'junit:junit:4.12'
compile project(':core')
- compile "org.jetbrains.kotlin:kotlin-stdlib:${KOTLIN}"
- testCompile "org.jetbrains.kotlin:kotlin-test-junit:${KOTLIN}"
-
compile "com.afollestad.material-dialogs:commons:${MATERIAL_DIALOG}"
}
diff --git a/colorpicker/src/androidTest/java/ca/allanwang/kau/colorpicker/ExampleInstrumentedTest.java b/colorpicker/src/androidTest/java/ca/allanwang/kau/colorpicker/ExampleInstrumentedTest.java
deleted file mode 100644
index 2b22d0f..0000000
--- a/colorpicker/src/androidTest/java/ca/allanwang/kau/colorpicker/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ca.allanwang.kau.colorpicker;
-
-import android.content.Context;
-import android.support.test.InstrumentationRegistry;
-import android.support.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.*;
-
-/**
- * Instrumentation test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ca.allanwang.kau.colorpicker.test", appContext.getPackageName());
- }
-}
diff --git a/colorpicker/src/test/java/ca/allanwang/kau/colorpicker/ExampleUnitTest.java b/colorpicker/src/test/java/ca/allanwang/kau/colorpicker/ExampleUnitTest.java
deleted file mode 100644
index f974ff7..0000000
--- a/colorpicker/src/test/java/ca/allanwang/kau/colorpicker/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ca.allanwang.kau.colorpicker;
-
-import org.junit.Test;
-
-import static org.junit.Assert.*;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file
diff --git a/core-ui/build.gradle b/core-ui/build.gradle
index 99f4567..2562de3 100644
--- a/core-ui/build.gradle
+++ b/core-ui/build.gradle
@@ -1,21 +1,14 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
}
dependencies {
- compile fileTree(dir: 'libs', include: ['*.jar'])
- androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
- exclude group: 'com.android.support', module: 'support-annotations'
- })
- testCompile 'junit:junit:4.12'
+
compile project(':core')
compile project(':adapter')
- compile "org.jetbrains.kotlin:kotlin-stdlib:${KOTLIN}"
- testCompile "org.jetbrains.kotlin:kotlin-test-junit:${KOTLIN}"
-
compile "io.reactivex.rxjava2:rxkotlin:${RX_KOTLIN}"
compile "io.reactivex.rxjava2:rxandroid:${RX_ANDROID}"
compile "com.jakewharton.rxbinding2:rxbinding-kotlin:${RX_BINDING}"
diff --git a/core-ui/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java b/core-ui/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
deleted file mode 100644
index 7b079b2..0000000
--- a/core-ui/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ca.allanwang.kau;
-
-import android.content.Context;
-import android.support.test.InstrumentationRegistry;
-import android.support.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.*;
-
-/**
- * Instrumentation test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ca.allanwang.kau.test", appContext.getPackageName());
- }
-}
diff --git a/core-ui/src/test/java/ca/allanwang/kau/ExampleUnitTest.java b/core-ui/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
deleted file mode 100644
index a29b447..0000000
--- a/core-ui/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ca.allanwang.kau;
-
-import org.junit.Test;
-
-import static org.junit.Assert.*;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file
diff --git a/core/build.gradle b/core/build.gradle
index bcdf89a..258f85a 100644
--- a/core/build.gradle
+++ b/core/build.gradle
@@ -1,4 +1,4 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
diff --git a/core/src/androidTest/java/ca/allanwang/kprefs/library/ExampleInstrumentedTest.java b/core/src/androidTest/java/ca/allanwang/kprefs/library/ExampleInstrumentedTest.java
index 8a80585..6d80338 100644
--- a/core/src/androidTest/java/ca/allanwang/kprefs/library/ExampleInstrumentedTest.java
+++ b/core/src/androidTest/java/ca/allanwang/kprefs/library/ExampleInstrumentedTest.java
@@ -7,7 +7,7 @@ import android.support.test.runner.AndroidJUnit4;
import org.junit.Test;
import org.junit.runner.RunWith;
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertEquals;
/**
* Instrumentation test, which will execute on an Android device.
diff --git a/core/src/main/res/values/strings_about.xml b/core/src/main/res/values/strings_about.xml
deleted file mode 100644
index 4c3c38d..0000000
--- a/core/src/main/res/values/strings_about.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<resources xmlns:tools="http://schemas.android.com/tools">
- <string name="library_kau_libraryVersion" tools:ignore="ResourceName">1.5</string>
-
- <string name="define_kau" tools:ignore="ResourceName" />
- <!-- Author section -->
- <string name="library_kau_author" tools:ignore="ResourceName">Allan Wang</string>
- <string name="library_kau_authorWebsite" tools:ignore="ResourceName">https://www.allanwang.ca/dev/</string>
- <!-- Library section -->
- <string name="library_kau_libraryName" tools:ignore="ResourceName">KAU</string>
- <string name="library_kau_libraryDescription" tools:ignore="ResourceName">
- <![CDATA[
- An extensive collection of Kotlin Android Utilities.
- <br/><br/>
- KAU aims to make many common functions executable in one line. It adds numerous extensions to match Kotlin\'s DSL,
- and supports completely customizable view groups that are used in almost any app project.
- ]]>
- </string>
- <string name="library_kau_libraryWebsite" tools:ignore="ResourceName">https://allanwang.github.io/KAU/</string>
- <!-- OpenSource section -->
- <string name="library_kau_isOpenSource" tools:ignore="ResourceName">true</string>
- <string name="library_kau_repositoryLink" tools:ignore="ResourceName">https://github.com/AllanWang/KAU</string>
- <!-- ClassPath for autoDetect section -->
- <string name="library_kau_classPath" tools:ignore="ResourceName">ca.allanwang.kau</string>
- <!-- License section -->
- <string name="library_kau_licenseId" tools:ignore="ResourceName">apache_2_0</string>
- <!-- Custom variables section -->
-</resources> \ No newline at end of file
diff --git a/imagepicker/build.gradle b/imagepicker/build.gradle
index b98b736..14c07ac 100644
--- a/imagepicker/build.gradle
+++ b/imagepicker/build.gradle
@@ -1,11 +1,13 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
}
dependencies {
+
compile project(':core-ui')
+
compile "com.github.bumptech.glide:glide:${GLIDE}"
kapt "com.github.bumptech.glide:compiler:${GLIDE}"
}
diff --git a/imagepicker/src/main/kotlin/ca/allanwang/kau/imagepicker/ImagePickerActivityBase.kt b/imagepicker/src/main/kotlin/ca/allanwang/kau/imagepicker/ImagePickerActivityBase.kt
index 47d57c2..8dfbeab 100644
--- a/imagepicker/src/main/kotlin/ca/allanwang/kau/imagepicker/ImagePickerActivityBase.kt
+++ b/imagepicker/src/main/kotlin/ca/allanwang/kau/imagepicker/ImagePickerActivityBase.kt
@@ -10,7 +10,6 @@ import android.support.v7.app.AppCompatActivity
import android.support.v7.widget.GridLayoutManager
import android.support.v7.widget.RecyclerView
import android.support.v7.widget.Toolbar
-import android.transition.TransitionInflater
import ca.allanwang.kau.logging.KL
import ca.allanwang.kau.ui.widgets.ElasticDragDismissFrameLayout
import ca.allanwang.kau.utils.bindView
diff --git a/kpref-activity/build.gradle b/kpref-activity/build.gradle
index dac2b69..80be774 100644
--- a/kpref-activity/build.gradle
+++ b/kpref-activity/build.gradle
@@ -1,23 +1,15 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
}
dependencies {
- compile fileTree(dir: 'libs', include: ['*.jar'])
- androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
- exclude group: 'com.android.support', module: 'support-annotations'
- })
- testCompile 'junit:junit:4.12'
compile project(':core-ui')
compile project(':adapter')
compile project(':colorpicker')
- compile "org.jetbrains.kotlin:kotlin-stdlib:${KOTLIN}"
- testCompile "org.jetbrains.kotlin:kotlin-test-junit:${KOTLIN}"
-
}
apply from: '../artifacts.gradle'
diff --git a/kpref-activity/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java b/kpref-activity/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
deleted file mode 100644
index 7b079b2..0000000
--- a/kpref-activity/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ca.allanwang.kau;
-
-import android.content.Context;
-import android.support.test.InstrumentationRegistry;
-import android.support.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.*;
-
-/**
- * Instrumentation test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ca.allanwang.kau.test", appContext.getPackageName());
- }
-}
diff --git a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemBase.kt b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemBase.kt
index ac54cb0..e21d483 100644
--- a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemBase.kt
+++ b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemBase.kt
@@ -2,8 +2,8 @@ package ca.allanwang.kau.kpref.activity.items
import android.support.annotation.CallSuper
import android.view.View
-import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.kpref.activity.GlobalOptions
+import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.utils.resolveDrawable
/**
diff --git a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemCore.kt b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemCore.kt
index 61d5ea3..908c139 100644
--- a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemCore.kt
+++ b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefItemCore.kt
@@ -11,11 +11,11 @@ import android.view.ViewGroup
import android.widget.ImageView
import android.widget.LinearLayout
import android.widget.TextView
-import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.adapters.ThemableIItem
import ca.allanwang.kau.adapters.ThemableIItemDelegate
import ca.allanwang.kau.kpref.activity.GlobalOptions
import ca.allanwang.kau.kpref.activity.KPrefMarker
+import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.utils.*
import com.mikepenz.fastadapter.items.AbstractItem
import com.mikepenz.iconics.typeface.IIcon
diff --git a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefPlainText.kt b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefPlainText.kt
index c0afe13..b83df69 100644
--- a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefPlainText.kt
+++ b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefPlainText.kt
@@ -1,8 +1,8 @@
package ca.allanwang.kau.kpref.activity.items
import android.view.View
-import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.kpref.activity.GlobalOptions
+import ca.allanwang.kau.kpref.activity.R
/**
* Created by Allan Wang on 2017-06-14.
diff --git a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSeekbar.kt b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSeekbar.kt
index 6ca7fcd..f1429e7 100644
--- a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSeekbar.kt
+++ b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSeekbar.kt
@@ -3,9 +3,9 @@ package ca.allanwang.kau.kpref.activity.items
import android.view.View
import android.widget.SeekBar
import android.widget.TextView
-import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.kpref.KPrefException
import ca.allanwang.kau.kpref.activity.GlobalOptions
+import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.utils.tint
/**
diff --git a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSubItems.kt b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSubItems.kt
index 9081ec8..9313a3f 100644
--- a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSubItems.kt
+++ b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefSubItems.kt
@@ -1,9 +1,9 @@
package ca.allanwang.kau.kpref.activity.items
import android.view.View
-import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.kpref.activity.GlobalOptions
import ca.allanwang.kau.kpref.activity.KPrefAdapterBuilder
+import ca.allanwang.kau.kpref.activity.R
/**
* Created by Allan Wang on 2017-06-14.
diff --git a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefText.kt b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefText.kt
index a1603ce..277a842 100644
--- a/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefText.kt
+++ b/kpref-activity/src/main/kotlin/ca/allanwang/kau/kpref/activity/items/KPrefText.kt
@@ -2,8 +2,8 @@ package ca.allanwang.kau.kpref.activity.items
import android.view.View
import android.widget.TextView
-import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.kpref.activity.GlobalOptions
+import ca.allanwang.kau.kpref.activity.R
import ca.allanwang.kau.utils.toast
/**
diff --git a/kpref-activity/src/main/res/values/strings.xml b/kpref-activity/src/main/res/values/strings.xml
deleted file mode 100644
index 0402364..0000000
--- a/kpref-activity/src/main/res/values/strings.xml
+++ /dev/null
@@ -1,3 +0,0 @@
-<resources>
- <string name="app_name">kpref-activity</string>
-</resources>
diff --git a/kpref-activity/src/test/java/ca/allanwang/kau/ExampleUnitTest.java b/kpref-activity/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
deleted file mode 100644
index a29b447..0000000
--- a/kpref-activity/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ca.allanwang.kau;
-
-import org.junit.Test;
-
-import static org.junit.Assert.*;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file
diff --git a/sample/build.gradle b/sample/build.gradle
index be204d0..abbfac3 100644
--- a/sample/build.gradle
+++ b/sample/build.gradle
@@ -16,7 +16,7 @@ android {
buildToolsVersion project.BUILD_TOOLS
androidGitVersion {
- codeFormat = 'MMNNPPBB'
+ codeFormat = 'MMNNBBBB'
prefix 'v'
}
diff --git a/sample/proguard-rules.pro b/sample/proguard-rules.pro
index b76c0ff..f3a65f0 100644
--- a/sample/proguard-rules.pro
+++ b/sample/proguard-rules.pro
@@ -1,31 +1,2 @@
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in C:\Users\User7681\AppData\Local\Android\Sdk/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the proguardFiles
-# directive in build.gradle.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
-
-# Uncomment this to preserve the line number information for
-# debugging indexStack traces.
-#-keepattributes SourceFile,LineNumberTable
-
-# If you keep the line number information, uncomment this to
-# hide the original source file name.
-#-renamesourcefileattribute SourceFile
-
-# About library
--keep class .R
--keep class **.R$* {
- <fields>;
-} \ No newline at end of file
+-ignorewarnings
+-dontwarn kotlin.** \ No newline at end of file
diff --git a/searchbar/build.gradle b/searchbar/build.gradle
index 78054b3..694e5a5 100644
--- a/searchbar/build.gradle
+++ b/searchbar/build.gradle
@@ -1,22 +1,14 @@
-apply from: '../android.gradle'
+apply from: '../android-lib.gradle'
android {
resourcePrefix "kau_"
}
dependencies {
- compile fileTree(dir: 'libs', include: ['*.jar'])
- androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
- exclude group: 'com.android.support', module: 'support-annotations'
- })
- testCompile 'junit:junit:4.12'
compile project(':core-ui')
compile project(':adapter')
- compile "org.jetbrains.kotlin:kotlin-stdlib:${KOTLIN}"
- testCompile "org.jetbrains.kotlin:kotlin-test-junit:${KOTLIN}"
-
}
apply from: '../artifacts.gradle'
diff --git a/searchbar/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java b/searchbar/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
deleted file mode 100644
index 58d0f29..0000000
--- a/searchbar/src/androidTest/java/ca/allanwang/kau/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ca.allanwang.kau;
-
-import android.content.Context;
-import android.support.test.InstrumentationRegistry;
-import android.support.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.assertEquals;
-
-/**
- * Instrumentation test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ca.allanwang.kau.test", appContext.getPackageName());
- }
-}
diff --git a/searchbar/src/test/java/ca/allanwang/kau/ExampleUnitTest.java b/searchbar/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
deleted file mode 100644
index a641a60..0000000
--- a/searchbar/src/test/java/ca/allanwang/kau/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ca.allanwang.kau;
-
-import org.junit.Test;
-
-import static org.junit.Assert.assertEquals;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file