fix #730, make sure Duplicate event works as expected

This commit is contained in:
tibbi 2018-12-25 23:43:05 +01:00
parent 2efe4289bc
commit e921009093
1 changed files with 2 additions and 1 deletions

View File

@ -701,13 +701,14 @@ class EventActivity : SimpleActivity() {
} }
private fun duplicateEvent() { private fun duplicateEvent() {
// the activity has the singleTask launchMode to avoid some glitches, so finish it before relaunching
finish()
Intent(this, EventActivity::class.java).apply { Intent(this, EventActivity::class.java).apply {
putExtra(EVENT_ID, mEvent.id) putExtra(EVENT_ID, mEvent.id)
putExtra(EVENT_OCCURRENCE_TS, mEventOccurrenceTS) putExtra(EVENT_OCCURRENCE_TS, mEventOccurrenceTS)
putExtra(IS_DUPLICATE_INTENT, true) putExtra(IS_DUPLICATE_INTENT, true)
startActivity(this) startActivity(this)
} }
finish()
} }
private fun saveCurrentEvent() { private fun saveCurrentEvent() {