Beispiel #1
0
        /// <summary>
        /// Detaches binding reference from the binding source.
        /// </summary>
        /// <param name="propVal"></param>
        internal void RemoveBinding(RadPropertyValue propVal)
        {
            PropertyBinding binding = propVal.PropertyBinding;

            if (binding != null)
            {
                //we need to reset current binding (unregister from source object's bound objects list)
                RadObject bindingSource = binding.SourceObject;
                if (bindingSource != null &&
                    ((binding.BindingOptions & PropertyBindingOptions.NoChangeNotify) == 0))
                {
                    bindingSource.OnPropertyUnboundExternally(binding, this);
                }
            }
        }
Beispiel #2
0
        internal void RemoveBinding(RadPropertyValue propVal)
        {
            PropertyBinding propertyBinding = propVal.PropertyBinding;

            if (propertyBinding == null)
            {
                return;
            }
            RadObject sourceObject = propertyBinding.SourceObject;

            if (sourceObject == null || (propertyBinding.BindingOptions & PropertyBindingOptions.NoChangeNotify) != (PropertyBindingOptions)0)
            {
                return;
            }
            sourceObject.OnPropertyUnboundExternally(propertyBinding, this);
        }