Edit task list: fix saving of task list colour.

Fixes #60
pull/61/head
Tom Hacohen 5 years ago
parent 96fc87cad4
commit e161233453

@ -113,9 +113,13 @@ open class CreateCollectionActivity : BaseActivity() {
info.description = StringUtils.trimToNull(edit.text.toString())
if (ok) {
if (info.type == CollectionInfo.Type.CALENDAR) {
val view = findViewById<View>(R.id.color)
info.color = (view.background as ColorDrawable).color
when (info.type) {
CollectionInfo.Type.CALENDAR, CollectionInfo.Type.TASKS -> {
val view = findViewById<View>(R.id.color)
info.color = (view.background as ColorDrawable).color
}
CollectionInfo.Type.ADDRESS_BOOK -> {
}
}
info.selected = true

Loading…
Cancel
Save