File tree 2 files changed +8
-0
lines changed
app/src/main/java/com/ricknout/rugbyranker
rankings/src/main/java/com/ricknout/rugbyranker/rankings/ui
2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -84,17 +84,21 @@ class MainActivity : DaggerAppCompatActivity() {
84
84
R .id.mensFragment -> {
85
85
bottomNavigationView.post {
86
86
womensRankingsViewModel.endEditMatchPrediction()
87
+ womensRankingsViewModel.resetMatchPredictionInputState()
87
88
}
88
89
}
89
90
R .id.womensFragment -> {
90
91
bottomNavigationView.post {
91
92
mensRankingsViewModel.endEditMatchPrediction()
93
+ mensRankingsViewModel.resetMatchPredictionInputState()
92
94
}
93
95
}
94
96
R .id.infoFragment -> {
95
97
bottomNavigationView.post {
96
98
mensRankingsViewModel.endEditMatchPrediction()
99
+ mensRankingsViewModel.resetMatchPredictionInputState()
97
100
womensRankingsViewModel.endEditMatchPrediction()
101
+ womensRankingsViewModel.resetMatchPredictionInputState()
98
102
}
99
103
}
100
104
}
Original file line number Diff line number Diff line change @@ -183,4 +183,8 @@ open class RankingsViewModel(
183
183
get() = _matchPredictionInputState
184
184
185
185
data class MatchPredictionInputState (val showMatchPredictionInput : Boolean = true , val hasMatchPredictions : Boolean = false )
186
+
187
+ fun resetMatchPredictionInputState () {
188
+ showMatchPredictionInput.value = true
189
+ }
186
190
}
You can’t perform that action at this time.
0 commit comments