System.Windows.DependencyObject.InvalidateProperty C# (CSharp) Method

InvalidateProperty() private method

private InvalidateProperty ( DependencyProperty dp ) : void
dp DependencyProperty
return void
        public void InvalidateProperty(DependencyProperty dp)
        {
            throw new NotImplementedException("InvalidateProperty(DependencyProperty dp)");
        }

Usage Example

        public void InvalidateDependents(DependencyObject source, DependencyPropertyChangedEventArgs sourceArgs)
        {
            // Take a snapshot of the list to protect against re-entrancy via Add / Remove.
            Dependent[] snapList = base.ToArray();

            for (int i = 0; i < snapList.Length; i++)
            {
                Expression expression = snapList[i].Expr;
                if (null != expression)
                {
                    expression.OnPropertyInvalidation(source, sourceArgs);

                    // Invalidate dependent, unless expression did it already
                    if (!expression.ForwardsInvalidations)
                    {
                        DependencyObject   dependencyObject   = snapList[i].DO;
                        DependencyProperty dependencyProperty = snapList[i].DP;

                        if (null != dependencyObject && null != dependencyProperty)
                        {
                            // recompute expression
                            dependencyObject.InvalidateProperty(dependencyProperty);
                        }
                    }
                }
            }
        }
All Usage Examples Of System.Windows.DependencyObject::InvalidateProperty