Completed composting alert of dialogs (testing still needed)

UI improvements
This commit is contained in:
Juha Heinanen
2025-04-15 18:10:58 +03:00
parent c1b7e4b01e
commit fb35f9fbd8
12 changed files with 580 additions and 702 deletions
@@ -272,13 +272,11 @@ sealed class Contact {
contactsUpdate()
}
fun updateBaresipContact(contact: BaresipContact) {
fun updateBaresipContact(id: Long, contact: BaresipContact) {
val updatedContacts = BaresipService.baresipContacts.value.toMutableList()
val updatedContact = contact.copy() as BaresipContact
updatedContact.id = System.currentTimeMillis()
updatedContacts.removeIf { it.id == contact.id }
updatedContacts.add(updatedContact)
BaresipService.baresipContacts.value = updatedContacts
updatedContacts.removeIf { it.id == id }
updatedContacts.add(contact)
BaresipService.baresipContacts.value = updatedContacts.toList()
saveBaresipContacts()
contactsUpdate()
}