Fix camera icon tint bug

This commit is contained in:
Matéo Duparc 2022-05-01 16:59:18 +02:00
parent c8d266150c
commit ec348383c6
Signed by untrusted user: hardcoresushi
GPG Key ID: AFE384344A45E13A

View File

@ -7,7 +7,7 @@ import android.view.ViewGroup
import android.widget.BaseAdapter
import android.widget.ImageView
import android.widget.TextView
import androidx.appcompat.content.res.AppCompatResources
import androidx.core.content.ContextCompat
import sushi.hardcore.droidfs.R
open class IconTextDialogAdapter(private val context: Context): BaseAdapter() {
@ -19,7 +19,7 @@ open class IconTextDialogAdapter(private val context: Context): BaseAdapter() {
val text = view.findViewById<TextView>(R.id.text)
text.text = context.getString(items[position][1] as Int)
val icon = view.findViewById<ImageView>(R.id.icon)
icon.setImageDrawable(AppCompatResources.getDrawable(context, items[position][2] as Int))
icon.setImageDrawable(ContextCompat.getDrawable(context, items[position][2] as Int))
return view
}