couple more threading improvements here and there
This commit is contained in:
parent
8b37aab610
commit
156620c917
10 changed files with 64 additions and 132 deletions
|
|
@ -1,9 +1,12 @@
|
|||
package com.simplemobiletools.smsmessenger.models
|
||||
|
||||
import android.provider.Telephony
|
||||
import android.text.TextUtils
|
||||
|
||||
data class Message(
|
||||
val id: Int, val body: String, val type: Int, val participants: ArrayList<Contact>, val date: Int, val read: Boolean, val thread: Int
|
||||
) : ThreadItem() {
|
||||
fun isReceivedMessage() = type == Telephony.Sms.MESSAGE_TYPE_INBOX
|
||||
|
||||
fun getThreadTitle() = TextUtils.join(", ", participants.map { it.name }.toTypedArray())
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,3 +0,0 @@
|
|||
package com.simplemobiletools.smsmessenger.models
|
||||
|
||||
data class MessagingThread(val id: Int, val title: String, val address: String)
|
||||
Loading…
Add table
Add a link
Reference in a new issue