aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2017-06-19 20:48:51 -0700
committerAllan Wang <me@allanwang.ca>2017-06-19 20:48:51 -0700
commit283a6be759751715d2c479cec16ce2487e47f3c1 (patch)
tree1052f82312f9016eb6f853c01166372fc997fea8
parent6c6740f497c944a02c847dee2c805ebc1b1b6913 (diff)
downloadkau-283a6be759751715d2c479cec16ce2487e47f3c1.tar.gz
kau-283a6be759751715d2c479cec16ce2487e47f3c1.tar.bz2
kau-283a6be759751715d2c479cec16ce2487e47f3c1.zip
Fix changelog title
-rw-r--r--library/src/main/kotlin/ca/allanwang/kau/changelog/Changelog.kt2
-rw-r--r--sample/src/main/res/xml/changelog.xml9
2 files changed, 10 insertions, 1 deletions
diff --git a/library/src/main/kotlin/ca/allanwang/kau/changelog/Changelog.kt b/library/src/main/kotlin/ca/allanwang/kau/changelog/Changelog.kt
index d2ea985..ae4c8f9 100644
--- a/library/src/main/kotlin/ca/allanwang/kau/changelog/Changelog.kt
+++ b/library/src/main/kotlin/ca/allanwang/kau/changelog/Changelog.kt
@@ -51,7 +51,7 @@ internal fun parse(context: Context, @XmlRes xmlRes: Int): List<Pair<String, Cha
}
internal enum class ChangelogType(val tag: String, val attr: String, @LayoutRes val layout: Int) {
- TITLE("title", "version", R.layout.kau_changelog_title),
+ TITLE("version", "title", R.layout.kau_changelog_title),
ITEM("item", "text", R.layout.kau_changelog_content);
companion object {
diff --git a/sample/src/main/res/xml/changelog.xml b/sample/src/main/res/xml/changelog.xml
index eb594ca..015171f 100644
--- a/sample/src/main/res/xml/changelog.xml
+++ b/sample/src/main/res/xml/changelog.xml
@@ -6,6 +6,15 @@
<item text="" />
-->
+ <version title="v1.2"/>
+ <item text="Fix title attribute in changelog" />
+ <item text="" />
+ <item text="" />
+ <item text="" />
+ <item text="" />
+ <item text="" />
+ <item text="" />
+
<version title="v1.1"/>
<item text="Created kpref items" />
<item text="Attached source files" />