private void UpdateBehavior(DependencyObject host, IBehavior behavior)
    {
        if (behavior.IsApplicable())
        {
            behavior.Update();
        }
        else
        {
            host.ClearValue(_property);

            behavior.Detach();
        }
    }
Exemple #2
0
        private void UpdateBehavior(DependencyObject host, IBehavior behavior, DependencyPropertyChangedEventArgs propertyChangedEventArgs)
        {
            if (behavior.IsApplicable())
            {
                behavior.Update(propertyChangedEventArgs);
            }
            else
            {
                host.ClearValue(_property);

                behavior.Detach();
            }
        }
		private void UpdateBehavior(DependencyObject host, IBehavior behavior)
		{
			if(behavior.IsApplicable())
			{
				behavior.Update();
			}
			else
			{
				host.ClearValue(_property);

				behavior.Detach();
			}
		}