mirror of https://github.com/readrops/Readrops.git
Hide Fab when synchronizing in TimelineTab
This commit is contained in:
parent
14af99c8df
commit
c54a14e616
|
@ -146,7 +146,8 @@ class TimelineScreenModel(
|
|||
emptyFlow()
|
||||
},
|
||||
isAccountLocal = currentAccount!!.isLocal,
|
||||
scrollToTop = true
|
||||
scrollToTop = true,
|
||||
hideReadAllFAB = !currentAccount!!.config.canMarkAllItemsAsRead
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -175,7 +176,10 @@ class TimelineScreenModel(
|
|||
|
||||
if (!currentAccount!!.isLocal) {
|
||||
_timelineState.update {
|
||||
it.copy(isRefreshing = true)
|
||||
it.copy(
|
||||
isRefreshing = true,
|
||||
hideReadAllFAB = true
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -216,7 +220,6 @@ class TimelineScreenModel(
|
|||
_timelineState.update {
|
||||
it.copy(
|
||||
isRefreshing = true,
|
||||
hideReadAllFAB = true,
|
||||
currentFeed = workInfo.progress.getString(SyncWorker.FEED_NAME_KEY)
|
||||
?: "",
|
||||
feedCount = workInfo.progress.getInt(SyncWorker.FEED_COUNT_KEY, 0),
|
||||
|
|
|
@ -9,7 +9,8 @@ data class AccountConfig(
|
|||
val canUpdateFolder: Boolean = true,
|
||||
val canUpdateFeed: Boolean = true,
|
||||
val canDeleteFeed: Boolean = true,
|
||||
val canDeleteFolder: Boolean = true
|
||||
val canDeleteFolder: Boolean = true,
|
||||
val canMarkAllItemsAsRead: Boolean = true
|
||||
) {
|
||||
|
||||
companion object {
|
||||
|
@ -18,7 +19,6 @@ data class AccountConfig(
|
|||
canCreateFolder = true,
|
||||
addNoFolder = true,
|
||||
useSeparateState = false,
|
||||
|
||||
)
|
||||
|
||||
val NEXTCLOUD_NEWS = AccountConfig(
|
||||
|
@ -44,7 +44,8 @@ data class AccountConfig(
|
|||
canUpdateFolder = false,
|
||||
canUpdateFeed = false,
|
||||
canDeleteFeed = false,
|
||||
canDeleteFolder = false
|
||||
canDeleteFolder = false,
|
||||
canMarkAllItemsAsRead = false
|
||||
)
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue