Closed pmcleish closed 8 years ago
Cool I'll test it. Did you figure out the WPF thing?
No. I tracked it down to the lbGroups Listbox in GroupFilterAdmin.xaml. I think it is a pre-existing issue. I can do a RecreateAllGroups from the client 10 or more times without issue, but at random that particular listbox's view of the data goes out of sync with the underlying data. I'm unable to reliably reproduce it. It could be a timing thing, I'm not really sure. But I'm somewhat sure it isn't related to my change since all I've done is correctly update a couple of dictionaries.
OK, if it's like that, it's prolly just a design error from long ago
I agree, one of the reasons for Client V2. :)
Right PMC isn't in the dev list yet is he. He prolly hasn't heard much conjecture about such topics.
He is, I added him awhile back.
@elementalcrisis he's earned his spot, you should grant him a golden name
Oh
I prolly should've merged this into recreateallgroupsrewrite, but the fix should be independent, while necessary, for it.
Yeah, there isn't anything specific to do with RecreateAllGroups, It was a bug that was always there, just happened to show up white testing RecreateAllGroups.
Modified MainListHelperVM.UpdateAll so that it processes Groups/Series in the correct order. When UpdateAll was called due to executing "Recreate All Groups" it was processing Series changes before Group changes. This resulted in KeyNotFoundException being thrown because the AnimeSeriesVM was referencing AllGroupsDictionary, which was out of date.
This change makes it so that Group changes are processed first so that AllGroupsDictionary is up to date before processing the Series changes.
(I also removed a few redundant dictionary lookups with just Remove/TryGetValue)