disable repetition if no day is selected
This commit is contained in:
parent
992b1f0b00
commit
c166ce8f1c
|
@ -143,12 +143,16 @@ class EventActivity : SimpleActivity(), DBHelper.EventUpdateListener {
|
|||
|
||||
private fun showRepeatIntervalDialog() {
|
||||
showEventRepeatIntervalDialog(mRepeatInterval) {
|
||||
mRepeatInterval = it
|
||||
updateRepetitionText()
|
||||
checkRepeatTexts(it)
|
||||
setRepeatInterval(it)
|
||||
}
|
||||
}
|
||||
|
||||
private fun setRepeatInterval(interval: Int) {
|
||||
mRepeatInterval = interval
|
||||
updateRepetitionText()
|
||||
checkRepeatTexts(interval)
|
||||
}
|
||||
|
||||
private fun checkRepeatTexts(limit: Int) {
|
||||
event_repetition_limit_holder.beGoneIf(limit == 0)
|
||||
checkRepetitionLimitText()
|
||||
|
@ -188,6 +192,9 @@ class EventActivity : SimpleActivity(), DBHelper.EventUpdateListener {
|
|||
RepeatRuleDailyDialog(this, mRepeatRule) {
|
||||
mRepeatRule = it
|
||||
checkRepetitionRuleText()
|
||||
if (it == 0) {
|
||||
setRepeatInterval(0)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue