Batch UI notifications #980
Unanswered
lwsouzaaht
asked this question in
Q&A
Replies: 1 comment
-
In your example query, you'd want to put The var changeCount = new BehaviorSubject<int>(0);
changeCount.DisposeWith(_disposable);
columnFilteredObservable
.Filter(_filterSubject) // the "Counter" filter
.Sort(this.WhenAnyObservable(model => model.CurrentSortFilter.SortObservable), SortOptimisations.None, 500)
.Do(changes => changeCount.Value += changes.Count)
.BatchIf(changeCount
.Select(changeCount => changeCount < 200))
.Do(_ => changeCount.Value = 0)
.ObserveOn(RxApp.MainThreadScheduler)
.Bind(IncidentListItems)
.Subscribe()
.DisposeWith(_disposable); |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello!
I have a very large cache, with 20K items, linked to a grid.
Currently, the grid updates every time the collection changes, but for performance reasons, I would like to batch, let's say, 200 changes before update the UI.
I tried to use Batch and other operator, but could no find good examples.
Here is the last part of my code:
Beta Was this translation helpful? Give feedback.
All reactions