[UI] Fix SettingsAboutCard having duplicate items.

This commit is contained in:
Kuba Szczodrzyński 2022-10-25 19:58:26 +02:00
parent f52cc1b197
commit c21d89cf60
No known key found for this signature in database
GPG Key ID: 70CB8A85BA1633CB
2 changed files with 7 additions and 12 deletions

View File

@ -39,16 +39,13 @@ class SettingsAboutCard(util: SettingsUtil) : SettingsCard(util), CoroutineScope
MediaPlayer.create(activity, R.raw.ogarnij_sie)
}
override fun buildCard(): MaterialAboutCard =
util.createCard(
override fun buildCard() = util.createCard(
null,
items = ::getItems,
itemsMore = ::getItemsMore,
backgroundColor = 0xff1976d2.toInt(),
theme = R.style.AppTheme_Dark
).also {
it.items.addAll(getItems(it))
}
)
private val versionDetailsItem by lazy {
util.createActionItem(

View File

@ -4,9 +4,7 @@
package pl.szczodrzynski.edziennik.ui.settings.cards
import com.danielstone.materialaboutlibrary.items.MaterialAboutItem
import com.danielstone.materialaboutlibrary.model.MaterialAboutCard
import com.google.android.material.dialog.MaterialAlertDialogBuilder
import com.mikepenz.iconics.typeface.library.community.material.CommunityMaterial
import eu.szkolny.font.SzkolnyFont
import pl.szczodrzynski.edziennik.App