I have a Usercontrol that I use as my cell's DataTemplate (actually I stick it directly into my controltemplate, but shouldn't make a difference)
I have a DependencyProperty that is bound to the Value of the cell, and the changed-listener looks like this
however, this animation fires when I am scrolling, because of UI virtualization.
I use this animation to flash the cell when the value changes. Is there a better way to do this to avoid getting the animation fired when UI virtualization is in effect? When I turn the virtualization off the problem goes away.
I have a DependencyProperty that is bound to the Value of the cell, and the changed-listener looks like this
public static void TextChanged(DependencyObject o, DependencyPropertyChangedEventArgs e) { double dub; if (e.OldValue != null && e.NewValue != null && (e.NewValue is double || (e.NewValue is string && double.TryParse(e.NewValue.ToString(), out dub)))) { var control = o as ValueCellPresenter; if (control.IsLoaded) { ((Storyboard)control.Resources["CellFlash"]).Begin(); } } }however, this animation fires when I am scrolling, because of UI virtualization.
I use this animation to flash the cell when the value changes. Is there a better way to do this to avoid getting the animation fired when UI virtualization is in effect? When I turn the virtualization off the problem goes away.
