My ListView has the following handler attached.
((ListView)MediaList).ItemSelected += (sender, args) => TriggerMedia((MediaViewModel)args.SelectedItem);
And when TriggerMedia()
is run, it runs twice. The first time, it has a hydrated MediaViewModel
passed in, and the second time it's null (because I set it to null
within the TriggerMedia method).
I can fix it simply by checking for null
. But I wonder why it runs twice?