From 7a9ca234c3245047ccda9597345a26884e9d3290 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sun, 31 Dec 2017 15:37:47 -0500 Subject: Fix up constraint layouts for about (#121) --- .../main/kotlin/ca/allanwang/kau/about/FaqIItem.kt | 2 +- .../kotlin/ca/allanwang/kau/about/LibraryIItem.kt | 13 ++++---- about/src/main/res/layout/kau_iitem_library.xml | 38 +++++++++------------- docs/Changelog.md | 3 ++ gradle.properties | 4 +-- 5 files changed, 28 insertions(+), 32 deletions(-) diff --git a/about/src/main/kotlin/ca/allanwang/kau/about/FaqIItem.kt b/about/src/main/kotlin/ca/allanwang/kau/about/FaqIItem.kt index b153fc9..0729ea4 100644 --- a/about/src/main/kotlin/ca/allanwang/kau/about/FaqIItem.kt +++ b/about/src/main/kotlin/ca/allanwang/kau/about/FaqIItem.kt @@ -19,7 +19,7 @@ import com.mikepenz.fastadapter.listeners.ClickEventHook * Created by Allan Wang on 2017-08-02. */ class FaqIItem(val content: FaqItem) : KauIItem( - R.layout.kau_iitem_faq, { ViewHolder(it) }, R.id.kau_item_faq + R.layout.kau_iitem_faq, ::ViewHolder, R.id.kau_item_faq ), ThemableIItem by ThemableIItemDelegate() { companion object { 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 f61c72c..89906c3 100644 --- a/about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt +++ b/about/src/main/kotlin/ca/allanwang/kau/about/LibraryIItem.kt @@ -21,21 +21,20 @@ import com.mikepenz.fastadapter.IItem * Created by Allan Wang on 2017-06-27. */ class LibraryIItem(val lib: Library) : KauIItem( - R.layout.kau_iitem_library, { ViewHolder(it) }, R.id.kau_item_library + R.layout.kau_iitem_library, ::ViewHolder, R.id.kau_item_library ), ThemableIItem by ThemableIItemDelegate() { companion object { fun bindEvents(fastAdapter: FastAdapter>) { fastAdapter.withSelectable(false) .withOnClickListener { v, _, item, _ -> - if (item !is LibraryIItem) false - else { - val c = v.context + if (item !is LibraryIItem) + false + else with(item.lib) { - c.startLink(libraryWebsite, repositoryLink, authorWebsite) + v.context.startLink(libraryWebsite, repositoryLink, authorWebsite) + true } - true - } } } } diff --git a/about/src/main/res/layout/kau_iitem_library.xml b/about/src/main/res/layout/kau_iitem_library.xml index 759a622..47b4e01 100644 --- a/about/src/main/res/layout/kau_iitem_library.xml +++ b/about/src/main/res/layout/kau_iitem_library.xml @@ -16,50 +16,45 @@ android:paddingStart="@dimen/kau_padding_normal" android:paddingTop="@dimen/kau_padding_normal"> - - + - + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintTop_toBottomOf="@id/lib_item_name" /> diff --git a/docs/Changelog.md b/docs/Changelog.md index 1e75ba0..e6e4488 100644 --- a/docs/Changelog.md +++ b/docs/Changelog.md @@ -1,5 +1,8 @@ # Changelog +## v3.6.1 +* :core: [Breaking] Removed private text field and introduced lazy logging functions + ## v3.6.0 * :adapter: Create withOnRepeatedClickListener * :core: Create kotlin flyweight diff --git a/gradle.properties b/gradle.properties index 5c72b0e..f8f5c0b 100644 --- a/gradle.properties +++ b/gradle.properties @@ -23,10 +23,10 @@ TARGET_SDK=27 BUILD_TOOLS=27.0.2 ANDROID_SUPPORT_LIBS=27.0.2 -VERSION_NAME=3.5.1.0 +VERSION_NAME=3.6.1.0 KOTLIN=1.2.10 -ABOUT_LIBRARIES=6.0.0 +ABOUT_LIBRARIES=6.0.1 ANKO=0.10.3 BLURRY=2.1.1 CONSTRAINT_LAYOUT=1.1.0-beta4 -- cgit v1.2.3