Persist sub id when sending sms messages
This commit is contained in:
parent
75bbd5ea0e
commit
e0787d7c83
2 changed files with 0 additions and 24 deletions
|
|
@ -676,16 +676,6 @@ fun Context.updateMessageStatus(id: Long, status: Int) {
|
|||
contentResolver.update(uri, contentValues, selection, selectionArgs)
|
||||
}
|
||||
|
||||
fun Context.updateMessageSubscriptionId(messageId: Long, subscriptionId: Int) {
|
||||
val uri = Sms.CONTENT_URI
|
||||
val contentValues = ContentValues().apply {
|
||||
put(Sms.SUBSCRIPTION_ID, subscriptionId)
|
||||
}
|
||||
val selection = "${Sms._ID} = ?"
|
||||
val selectionArgs = arrayOf(messageId.toString())
|
||||
contentResolver.update(uri, contentValues, selection, selectionArgs)
|
||||
}
|
||||
|
||||
fun Context.updateUnreadCountBadge(conversations: List<Conversation>) {
|
||||
val unreadCount = conversations.count { !it.read }
|
||||
if (unreadCount == 0) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue