aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--buildSrc/src/main/kotlin/kau/Versions.kt4
-rw-r--r--core/src/main/kotlin/ca/allanwang/kau/kpref/KPrefTransaction.kt2
-rw-r--r--core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt2
-rw-r--r--docs/Changelog.md3
-rw-r--r--sample/src/main/res/xml/kau_changelog.xml5
5 files changed, 10 insertions, 6 deletions
diff --git a/buildSrc/src/main/kotlin/kau/Versions.kt b/buildSrc/src/main/kotlin/kau/Versions.kt
index 7133ed5..515f702 100644
--- a/buildSrc/src/main/kotlin/kau/Versions.kt
+++ b/buildSrc/src/main/kotlin/kau/Versions.kt
@@ -3,10 +3,10 @@ package kau
object Versions {
const val coreMinSdk = 19
const val minSdk = 21
- const val targetSdk = 28
+ const val targetSdk = 29
// https://developer.android.com/studio/releases/build-tools
- const val buildTools = "28.0.3"
+ const val buildTools = "29.0.0"
// https://mvnrepository.com/artifact/androidx.appcompat/appcompat?repo=google
const val appcompat = "1.0.2"
diff --git a/core/src/main/kotlin/ca/allanwang/kau/kpref/KPrefTransaction.kt b/core/src/main/kotlin/ca/allanwang/kau/kpref/KPrefTransaction.kt
index 1070e11..3f8fe28 100644
--- a/core/src/main/kotlin/ca/allanwang/kau/kpref/KPrefTransaction.kt
+++ b/core/src/main/kotlin/ca/allanwang/kau/kpref/KPrefTransaction.kt
@@ -60,7 +60,7 @@ internal object KPrefFloatTransaction : KPrefTransaction<Float> {
internal object KPrefStringTransaction : KPrefTransaction<String> {
override fun get(prefs: SharedPreferences, key: String, fallback: String) =
- prefs.getString(key, fallback)
+ prefs.getString(key, fallback) ?: ""
override fun set(editor: SharedPreferences.Editor, key: String, data: String) {
editor.putString(key, data)
diff --git a/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt b/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt
index e8680dc..d002fb8 100644
--- a/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt
+++ b/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt
@@ -239,7 +239,7 @@ fun Context.hasPermission(permissions: String) = !buildIsMarshmallowAndUp || Con
fun Context.copyToClipboard(text: String?, label: String = "Copied Text", showToast: Boolean = true) {
val clipboard = getSystemService(Context.CLIPBOARD_SERVICE) as ClipboardManager
- clipboard.primaryClip = ClipData.newPlainText(label, text ?: "")
+ clipboard.setPrimaryClip(ClipData.newPlainText(label, text ?: ""))
if (showToast) toast(R.string.kau_text_copied)
}
diff --git a/docs/Changelog.md b/docs/Changelog.md
index 61e5fb7..689fbd9 100644
--- a/docs/Changelog.md
+++ b/docs/Changelog.md
@@ -1,8 +1,11 @@
# Changelog
## v5.0.0
+* Update Android SDK to 29 and Kotlin to 1.3.31
* :core: Update Material Dialogs to 3.x
+* :core: Change ProgressAnimator API
* :colorpicker: Strip down to just the interface; unless you require the accent palette, it may be fine to just use MD's color extension
+* :gradle-plugin: Convert to kotlin, rework dependencies, and remove extension hooks
## v4.1.0
* :core: Deprecate NetworkUtils, as the underlying functions are deprecated
diff --git a/sample/src/main/res/xml/kau_changelog.xml b/sample/src/main/res/xml/kau_changelog.xml
index 53265d0..b5ec47c 100644
--- a/sample/src/main/res/xml/kau_changelog.xml
+++ b/sample/src/main/res/xml/kau_changelog.xml
@@ -7,10 +7,11 @@
-->
<version title="v5.0.0" />
+ <item text="Update Android SDK to 29 and Kotlin to 1.3.31" />
<item text=":core: Update Material Dialogs to 3.x" />
+ <item text=":core: Change ProgressAnimator API" />
<item text=":colorpicker: Strip down to just the interface; unless you require the accent palette, it may be fine to just use MD's color extension" />
- <item text="" />
- <item text="" />
+ <item text=":gradle-plugin: Convert to kotlin, rework dependencies, and remove extension hooks" />
<item text="" />
<item text="" />