|
|
|
|
@ -7,7 +7,7 @@ import android.view.ViewGroup |
|
|
|
|
import androidx.recyclerview.widget.LinearLayoutManager |
|
|
|
|
import kotlinx.android.synthetic.main.fragment_stats.* |
|
|
|
|
import net.pokeranalytics.android.R |
|
|
|
|
import net.pokeranalytics.android.model.MoreItem |
|
|
|
|
import net.pokeranalytics.android.model.MoreTabRepresentable |
|
|
|
|
import net.pokeranalytics.android.ui.activity.BankrollActivity |
|
|
|
|
import net.pokeranalytics.android.ui.activity.SettingsActivity |
|
|
|
|
import net.pokeranalytics.android.ui.adapter.RowRepresentableAdapter |
|
|
|
|
@ -56,8 +56,8 @@ class MoreFragment : PokerAnalyticsFragment(), StaticRowRepresentableDataSource, |
|
|
|
|
override fun onRowSelected(position: Int, row: RowRepresentable, fromAction: Boolean) { |
|
|
|
|
super.onRowSelected(position, row, fromAction) |
|
|
|
|
when(row) { |
|
|
|
|
MoreItem.BANKROLL -> BankrollActivity.newInstance(requireContext()) |
|
|
|
|
MoreItem.SETTINGS -> SettingsActivity.newInstance(requireContext()) |
|
|
|
|
MoreTabRepresentable.BANKROLL -> BankrollActivity.newInstance(requireContext()) |
|
|
|
|
MoreTabRepresentable.SETTINGS -> SettingsActivity.newInstance(requireContext()) |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -67,7 +67,7 @@ class MoreFragment : PokerAnalyticsFragment(), StaticRowRepresentableDataSource, |
|
|
|
|
* Init data |
|
|
|
|
*/ |
|
|
|
|
private fun initData() { |
|
|
|
|
rowRepresentables.addAll(MoreItem.values()) |
|
|
|
|
rowRepresentables.addAll(MoreTabRepresentable.values()) |
|
|
|
|
moreAdapter = RowRepresentableAdapter(this, this) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|