-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RemoveMany
from a merged SourceList
causes Clear
#10
Comments
If this is the wrong place for this, I'm sorry. I can create it somewhere else. |
Sorry, activity on this particular repo doesn't pop up in my feed, and probably the same for @dwcullop. And @RolandPheasant has been on vacation. No need to move, now that it's here, but yeah, in the future, https://github.com/reactivemarbles/DynamicData is the best spot for submitting issues. The problem is that you cannot use At a glance, what you probably want is... namespace DynamicData;
public static class ObservableListEx
{
public static IObservable<IChangeSet<TObject>> MergeChangeSets<TObject>(
this IObservable<IChangeSet<TObject>> source,
IObservable<IChangeSet<TObject>> other,
IEqualityComparer<TObject>? equalityComparer = null,
IScheduler? scheduler = null,
bool completable = true)
where TObject : notnull;
} |
Ah, great. I suspected there would be something like that. I was trying to find relevant examples in the various places you have them, but couldn't see anything similar to what I was trying to do (I guess because I was doing the wrong thing). It's great that you have examples, but they're a bit fragmented and it seems like there are some holes. Also, it's not clear when should or shouldn't use something as in this case. When should I use Merge rather than the suffixed method you mentioned? Could it be an overload which does the right thing based on the input types? Another example I got even less far with was trying to join two sets of different data together into view models. I found the Join method, but I had no idea what to do with the duration delegates. I expected to have a left and right key selector then to need to transform them into my VMs. It seems like this system should be really powerful and flexible, but I don't understand it well enough yet and need a crash course. |
I'm guessing it's due to some optimisation, but this test fails, and the console output shows a clear.
I've worked around the issue by removing items gradially rather than all in one go, but if I do a
.Clear()
the whole merged collection is cleared, which is also wrong. Is there more correct way to do this?Thanks
Update: seems likely to be coming from here:
https://github.com/reactivemarbles/DynamicData/blob/76fd915924fab0e6756038f50a4fff4464a4ed00/src/DynamicData/List/ChangeAwareList.cs#L139
Is there a better way to prevent this than to remove all items individually?
The text was updated successfully, but these errors were encountered: