3532: Show badge on conversations tab on new conversations (#3890)
Fixes #3532 (Old PR, now closed: https://github.com/tuskyapp/Tusky/pull/3533) Listens on new notifications and if a "direct mention" is detected a badge (red dot) is shown on the conversations tab if present. I am missing things like this a lot and also big accounts are unhappy with the usability so far: https://mastodon.social/@pallenberg/110129889996182814
This commit is contained in:
parent
ff1c4a4b27
commit
b286255630
9 changed files with 1109 additions and 4 deletions
|
|
@ -33,6 +33,8 @@
|
|||
* see <http://www.gnu.org/licenses>. */
|
||||
package com.keylesspalace.tusky.util
|
||||
|
||||
import androidx.paging.CombinedLoadStates
|
||||
import androidx.paging.LoadState
|
||||
import com.keylesspalace.tusky.entity.Notification
|
||||
import com.keylesspalace.tusky.entity.Status
|
||||
import com.keylesspalace.tusky.entity.TrendingTag
|
||||
|
|
@ -87,3 +89,7 @@ fun List<TrendingTag>.toViewData(): List<TrendingViewData.Tag> {
|
|||
)
|
||||
}
|
||||
}
|
||||
|
||||
fun CombinedLoadStates.isAnyLoading(): Boolean {
|
||||
return this.refresh == LoadState.Loading || this.append == LoadState.Loading || this.prepend == LoadState.Loading
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue