Reduces full screen updates to once a second.

This commit is contained in:
Vitor Pamplona 2023-06-27 12:02:55 -04:00
parent f2e9fbebea
commit fa7ccdfc20

View File

@ -1273,7 +1273,7 @@ class LocalCacheLiveData {
val newEventBundles = _newEventBundles.asSharedFlow() // read-only public view
// Refreshes observers in batches.
private val bundler = BundledInsert<Note>(300, Dispatchers.IO)
private val bundler = BundledInsert<Note>(1000, Dispatchers.IO)
fun invalidateData(newNote: Note) {
bundler.invalidateList(newNote) { bundledNewNotes ->