/// <summary> /// Raises the attached DragLeave event on a element. /// </summary> /// <param name="element">The element to raise the event on.</param> /// <param name="args">Information about the event.</param> internal static void OnDragLeave(this DependencyObject element, SW.DragEventArgs args) { if (!args.Handled) { IAcceptDrop acceptDrop = element as IAcceptDrop; if (acceptDrop != null) { acceptDrop.OnDragLeave(args); } } ExtendedRoutedEventHandlerCollection <SW.DragEventHandler, SW.DragEventArgs> handlers = element.GetDragLeaveHandlers(); if (handlers != null) { handlers.Raise(args); } }
/// <summary> /// Raises the attached GiveFeedback event on a element. /// </summary> /// <param name="element">The element to raise the event on.</param> /// <param name="args">Information about the event.</param> internal static void OnGiveFeedback(this DependencyObject element, SW.GiveFeedbackEventArgs args) { if (!args.Handled) { IAcceptDrop acceptDrop = element as IAcceptDrop; if (acceptDrop != null) { acceptDrop.OnGiveFeedback(args); } } ExtendedRoutedEventHandlerCollection <GiveFeedbackEventHandler, SW.GiveFeedbackEventArgs> handlers = element.GetGiveFeedbackHandlers(); if (handlers != null) { handlers.Raise(args); } }