Is it appropriate to only set the Visibility
-property of an unused virtualizing list-control to Collapsed
.
I have a ViewModel that implements IEnumerable<SomeType>
and have some virtualizing list-controls that bind directly to the ViewModel (declared in markup). At a time always only one of the list controls is visible.
Is it appropriate to set only the Visibility
of the unused lists to collapsed, because in this case no items will be produced for the invisible list-controls or should I better clear and set the ItemsSource
-property?
I’m aware that there is an overhead because the two or more controls track the collection changes (INotifyCollectionChanged
) but IMO this overhead is negligible. Am I right?