diff --git a/app/src/main/java/net/pokeranalytics/android/ui/fragment/components/bottomsheet/BottomSheetDoubleListFragment.kt b/app/src/main/java/net/pokeranalytics/android/ui/fragment/components/bottomsheet/BottomSheetListGameFragment.kt similarity index 60% rename from app/src/main/java/net/pokeranalytics/android/ui/fragment/components/bottomsheet/BottomSheetDoubleListFragment.kt rename to app/src/main/java/net/pokeranalytics/android/ui/fragment/components/bottomsheet/BottomSheetListGameFragment.kt index 672817f2..595f25f0 100644 --- a/app/src/main/java/net/pokeranalytics/android/ui/fragment/components/bottomsheet/BottomSheetDoubleListFragment.kt +++ b/app/src/main/java/net/pokeranalytics/android/ui/fragment/components/bottomsheet/BottomSheetListGameFragment.kt @@ -4,17 +4,17 @@ import android.os.Bundle import android.view.LayoutInflater import android.view.View import androidx.recyclerview.widget.LinearLayoutManager -import kotlinx.android.synthetic.main.bottom_sheet_double_list.* +import kotlinx.android.synthetic.main.bottom_sheet_game_list.* import kotlinx.android.synthetic.main.fragment_bottom_sheet.view.* import net.pokeranalytics.android.R import net.pokeranalytics.android.model.realm.Game +import net.pokeranalytics.android.ui.adapter.LimitTypesAdapter import net.pokeranalytics.android.ui.adapter.components.LiveDataAdapter import net.pokeranalytics.android.ui.adapter.components.LiveDataDataSource import net.pokeranalytics.android.ui.adapter.components.LiveDataDelegate -class BottomSheetDoubleListFragment : BottomSheetFragment(), LiveDataDelegate { - +class BottomSheetGameListFragment : BottomSheetFragment(), LiveDataDelegate { override fun onViewCreated(view: View, savedInstanceState: Bundle?) { super.onViewCreated(view, savedInstanceState) @@ -47,15 +47,29 @@ class BottomSheetDoubleListFragment : BottomSheetFragment(), LiveDataDelegate { * Init UI */ private fun initUI() { - LayoutInflater.from(requireContext()).inflate(R.layout.bottom_sheet_double_list, view?.bottomSheetContainer, true) + LayoutInflater.from(requireContext()).inflate(R.layout.bottom_sheet_game_list, view?.bottomSheetContainer, true) + + val limits = ArrayList() + limits.add("--") + limits.addAll(resources.getStringArray(R.array.limit_short_name)) - val viewManager = LinearLayoutManager(requireContext()) - val dataAdapter = LiveDataAdapter(this, R.layout.row_bottom_sheet_title) + val viewManager1 = LinearLayoutManager(requireContext()) + val gameDataAdapter1 = LimitTypesAdapter(limits) reyclerView1.apply { setHasFixedSize(true) - layoutManager = viewManager - adapter = dataAdapter + layoutManager = viewManager1 + adapter = gameDataAdapter1 + } + + + val viewManager2 = LinearLayoutManager(requireContext()) + val gameDataAdapter2 = LiveDataAdapter(this, R.layout.row_bottom_sheet_title) + + reyclerView2.apply { + setHasFixedSize(true) + layoutManager = viewManager2 + adapter = gameDataAdapter2 } } diff --git a/app/src/main/res/layout/bottom_sheet_double_list.xml b/app/src/main/res/layout/bottom_sheet_game_list.xml similarity index 100% rename from app/src/main/res/layout/bottom_sheet_double_list.xml rename to app/src/main/res/layout/bottom_sheet_game_list.xml diff --git a/app/src/main/res/values/array_blind.xml b/app/src/main/res/values/array_blind.xml new file mode 100644 index 00000000..ec11808d --- /dev/null +++ b/app/src/main/res/values/array_blind.xml @@ -0,0 +1,44 @@ + + + + 2 + 4 + 6 + 10 + 20 + 40 + 50 + 60 + 80 + 100 + 150 + 200 + 250 + 300 + 400 + 500 + 600 + 800 + 1000 + 1200 + 1600 + 2000 + 2500 + 3000 + 4000 + 5000 + 6000 + 8000 + 10000 + 12000 + 15000 + 20000 + 25000 + 30000 + 40000 + 50000 + 60000 + 80000 + 100000 + + \ No newline at end of file diff --git a/app/src/main/res/values/array_limit.xml b/app/src/main/res/values/array_limit.xml new file mode 100644 index 00000000..096fef29 --- /dev/null +++ b/app/src/main/res/values/array_limit.xml @@ -0,0 +1,17 @@ + + + + No Limit + Pot Limit + Fixed Limit + Spread Limit + Mixed Limit + + + NL + PL + FL + SL + ML + + \ No newline at end of file diff --git a/app/src/main/res/values/array_variant.xml b/app/src/main/res/values/array_variant.xml new file mode 100644 index 00000000..3f6dd1b0 --- /dev/null +++ b/app/src/main/res/values/array_variant.xml @@ -0,0 +1,21 @@ + + + + Hold\'em + Omaha + Omaha Hi-Low + Seven Card Stud + Seven Card Stud Hi-Low + H.O.R.S.E. + Seven Card Razz + + + HE + OH + OH8 + 7S + Stud8 + HORSE + Razz + + \ No newline at end of file