Update MainActivity.kt
This commit is contained in:
parent
b45e6990d7
commit
7429a0c9e5
1 changed files with 4 additions and 4 deletions
|
|
@ -357,17 +357,17 @@ class MainActivity : SimpleActivity() {
|
||||||
|
|
||||||
if (cached && config.appRunCount == 1) {
|
if (cached && config.appRunCount == 1) {
|
||||||
// there are no cached conversations on the first run so we show the loading placeholder and progress until we are done loading from telephony
|
// there are no cached conversations on the first run so we show the loading placeholder and progress until we are done loading from telephony
|
||||||
showOrHideProgress(show = conversations.isEmpty())
|
showOrHideProgress(conversations.isEmpty())
|
||||||
} else {
|
} else {
|
||||||
showOrHideProgress(show = false)
|
showOrHideProgress(false)
|
||||||
showOrHidePlaceholder(show = conversations.isEmpty())
|
showOrHidePlaceholder(conversations.isEmpty())
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
getOrCreateConversationsAdapter().apply {
|
getOrCreateConversationsAdapter().apply {
|
||||||
updateConversations(sortedConversations) {
|
updateConversations(sortedConversations) {
|
||||||
if (!cached) {
|
if (!cached) {
|
||||||
showOrHidePlaceholder(show = currentList.isEmpty())
|
showOrHidePlaceholder(currentList.isEmpty())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue