diff options
author | Allan Wang <me@allanwang.ca> | 2021-04-18 18:30:03 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-18 18:30:03 -0700 |
commit | bf55dbf9b46cd8826987ee6e556307e24f3d46cc (patch) | |
tree | aaca512641e6e4503859c4cb97a29a9296669f9d /app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt | |
parent | 88a5d17814ff9f7c44f79216510d405f057ae454 (diff) | |
parent | 997362de5aab00f8d258b6fe8a058a8b3e018694 (diff) | |
download | frost-bf55dbf9b46cd8826987ee6e556307e24f3d46cc.tar.gz frost-bf55dbf9b46cd8826987ee6e556307e24f3d46cc.tar.bz2 frost-bf55dbf9b46cd8826987ee6e556307e24f3d46cc.zip |
Merge pull request #1770 from AllanWang/hilt
Diffstat (limited to 'app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt')
-rw-r--r-- | app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt b/app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt index 0fd39d5c..f9f9064b 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/iitems/TabIItem.kt @@ -30,22 +30,23 @@ import com.mikepenz.fastadapter.drag.IDraggable import com.pitchedapps.frost.R import com.pitchedapps.frost.facebook.FbItem import com.pitchedapps.frost.injectors.ThemeProvider -import org.koin.core.component.KoinComponent -import org.koin.core.component.inject /** * Created by Allan Wang on 26/11/17. */ -class TabIItem(val item: FbItem) : KauIItem<TabIItem.ViewHolder>( - R.layout.iitem_tab_preview, - { ViewHolder(it) } -), IDraggable { +class TabIItem(val item: FbItem, private val themeProvider: ThemeProvider) : + KauIItem<TabIItem.ViewHolder>( + R.layout.iitem_tab_preview, + { ViewHolder(it, themeProvider) } + ), + IDraggable { override val isDraggable: Boolean = true - class ViewHolder(itemView: View) : FastAdapter.ViewHolder<TabIItem>(itemView), KoinComponent { - - private val themeProvider: ThemeProvider by inject() + class ViewHolder( + itemView: View, + private val themeProvider: ThemeProvider + ) : FastAdapter.ViewHolder<TabIItem>(itemView) { val image: ImageView by bindView(R.id.image) val text: TextView by bindView(R.id.text) |