debug: trying to resolve Canvas: trying to use a recycled bitmap.

This commit is contained in:
aminecmi 2022-12-29 20:40:39 +01:00
parent 966a082147
commit db75c5b74a

View File

@ -67,6 +67,7 @@ class FilterSheetFragment : BottomSheetDialogFragment(), DIAware {
val c = Chip(context) val c = Chip(context)
c.text = tag.tag c.text = tag.tag
try {
val gd = GradientDrawable() val gd = GradientDrawable()
val gdColor = try { val gdColor = try {
Color.parseColor(tag.color) Color.parseColor(tag.color)
@ -79,6 +80,9 @@ class FilterSheetFragment : BottomSheetDialogFragment(), DIAware {
gd.setSize(30, 30) gd.setSize(30, 30)
gd.cornerRadius = 30F gd.cornerRadius = 30F
c.chipIcon = gd c.chipIcon = gd
} catch (e: Exception) {
e.sendSilentlyWithAcraWithName("tags > GradientDrawable")
}
c.setOnCloseIconClickListener { c.setOnCloseIconClickListener {
(it as Chip).isCloseIconVisible = false (it as Chip).isCloseIconVisible = false
@ -127,7 +131,11 @@ class FilterSheetFragment : BottomSheetDialogFragment(), DIAware {
dataSource: DataSource?, dataSource: DataSource?,
isFirstResource: Boolean isFirstResource: Boolean
): Boolean { ): Boolean {
try {
c.chipIcon = resource c.chipIcon = resource
} catch (e: Exception) {
e.sendSilentlyWithAcraWithName("sources > onResourceReady")
}
return false return false
} }
}).preload() }).preload()