diff --git a/app/src/main/java/de/jeanlucmakiola/calendula/ui/edit/EventEditScreen.kt b/app/src/main/java/de/jeanlucmakiola/calendula/ui/edit/EventEditScreen.kt index b05edfa..b14978f 100644 --- a/app/src/main/java/de/jeanlucmakiola/calendula/ui/edit/EventEditScreen.kt +++ b/app/src/main/java/de/jeanlucmakiola/calendula/ui/edit/EventEditScreen.kt @@ -1125,10 +1125,17 @@ private fun EventEditContent( viewModel.setCalendar(it) showCalendarPicker = false }, - // Leaves the form and its picker standing underneath: the manager - // slides over, and a calendar switched on there is in the list on - // the way back (the provider notifies, the flow re-queries). - onManageCalendars = onManageCalendars, + // Close the picker on the way out. It is a Compose Dialog — its own + // window, always above the activity's content — so the manager would + // otherwise open behind it and the tap would look dead. The form + // stays standing underneath, its calendar row one tap from a picker + // that re-queries on open. + onManageCalendars = onManageCalendars?.let { openManager -> + { + showCalendarPicker = false + openManager() + } + }, onDismiss = { showCalendarPicker = false }, ) }