Example #1
0
        public void CoerceCurrentValue(DependencyProperty dependencyProperty, PropertyMetadata propertyMetadata)
        {
            INTERNAL_PropertyStorage storage;

            INTERNAL_PropertyStore.TryGetStorage(this, dependencyProperty, true /*create*/, out storage);
            INTERNAL_PropertyStore.CoerceValueCommon(storage);
        }
Example #2
0
        public void CoerceValue(DependencyProperty dp)
        {
            if (dp == null)
            {
                throw new ArgumentNullException("No property specified.");
            }

            INTERNAL_PropertyStorage storage;

            INTERNAL_PropertyStore.TryGetStorage(this, dp, true /*create*/, out storage);
            INTERNAL_PropertyStore.CoerceValueCommon(storage);
        }