2019-05-07 22:28:38 +02:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
2019-07-12 20:38:15 +02:00
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2019-05-07 22:28:38 +02:00
|
|
|
|
2020-07-31 22:24:14 +02:00
|
|
|
package org.mozilla.fenix.exceptions.viewholders
|
2019-05-07 22:28:38 +02:00
|
|
|
|
|
|
|
import android.view.View
|
2020-07-31 22:24:14 +02:00
|
|
|
import androidx.annotation.StringRes
|
2019-05-07 22:28:38 +02:00
|
|
|
import androidx.recyclerview.widget.RecyclerView
|
2020-07-02 04:37:03 +02:00
|
|
|
import kotlinx.android.synthetic.main.exceptions_description.view.*
|
2019-05-07 22:28:38 +02:00
|
|
|
import org.mozilla.fenix.R
|
|
|
|
|
2020-07-31 22:24:14 +02:00
|
|
|
class ExceptionsHeaderViewHolder(
|
|
|
|
view: View,
|
|
|
|
@StringRes description: Int
|
2019-05-07 22:28:38 +02:00
|
|
|
) : RecyclerView.ViewHolder(view) {
|
2020-07-02 04:37:03 +02:00
|
|
|
|
|
|
|
init {
|
2020-07-31 22:24:14 +02:00
|
|
|
view.exceptions_description.text = view.context.getString(description)
|
2020-07-02 04:37:03 +02:00
|
|
|
}
|
2020-07-17 23:25:45 +02:00
|
|
|
|
|
|
|
companion object {
|
|
|
|
const val LAYOUT_ID = R.layout.exceptions_description
|
|
|
|
}
|
2019-05-07 22:28:38 +02:00
|
|
|
}
|