/// <inheritdoc/>
        protected override void OnValueDisassociated(FrameworkElement targetObject, BehaviorActionCollection <DependencyObject> oldValue)
        {
            base.OnValueDisassociated(targetObject, oldValue);

            Require.NotNull(targetObject, nameof(targetObject));

            targetObject.RemoveHandler(_routedEvent, (RoutedEventHandler)OnEvent);
        }
        private void OnEvent(object sender, RoutedEventArgs e)
        {
            var targetObject = (DependencyObject)sender;

            BehaviorActionCollection <DependencyObject> actions = GetAttachment(targetObject, HostedActionsProperty);

            foreach (BehaviorAction <DependencyObject> action in actions)
            {
                if (!action.Execute())
                {
                    return;
                }
            }
        }