DragDropManager
Provides helper methods and fields for initiating drag-and-drop operations, including a method to begin a drag-and-drop operation, and facilities for adding and removing drag-and-drop related event handlers.
Definition
Namespace:Telerik.Windows.DragDrop
Assembly:Telerik.Windows.Controls.dll
Syntax:
public static class DragDropManager
Inheritance: objectDragDropManager
Fields
AllowCapturedDragProperty
DependencyProperty
Identifies the AllowCapturedDrag attached dependency property.
public static readonly DependencyProperty AllowCapturedDragProperty
AllowDragProperty
DependencyProperty
Identifies the AllowDrag attached dependency property.
public static readonly DependencyProperty AllowDragProperty
Properties
DefaultDragDropEffects
DragDropEffects
Gets or sets the AllowedEffect for a drag-and-drop operation if such are not specified in DragInitialize event arguments.
public static DragDropEffects DefaultDragDropEffects { get; set; }
Gets a value indicating whether a drag is in progress.
public static bool IsDragInProgress { get; }
Gets whether application have FullTrust permissions.
public static bool IsFullTrust { get; }
Gets or sets the width of a rectangle centered on a drag point to allow for limited movement of the mouse pointer before a drag operation begins. The default value is 4.0.
public static double MinimumHorizontalDragDistance { get; set; }
Gets or sets the height of a rectangle centered on a drag point to allow for limited movement of the mouse pointer before a drag operation begins.
public static double MinimumVerticalDragDistance { get; set; }
Gets or sets a value that indicates whether drag visual will be displayed in the adorner layer or in separate window.
public static bool UseAdornerLayer { get; set; }
Methods
Adds a DragDropCompleted event handler to a specified dependency object.
public static void AddDragDropCompletedHandler(DependencyObject element, DragDropCompletedEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragDropCompletedEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The DragDropCompleted event occurs when an drag-and-drop operation ends(On Drop or Cancel).
Adds a DragDropCompleted event handler to a specified dependency object.
public static void AddDragDropCompletedHandler(DependencyObject element, DragDropCompletedEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragDropCompletedEventHandlerA delegate that references the handler method to be added.
The DragDropCompleted event occurs when an drag-and-drop operation ends(On Drop or Cancel).
Adds a DragEnter event handler to a specified dependency object.
public static void AddDragEnterHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The DragEnter event occurs when an object is dragged into the element's bounds. This method adds a handler for the bubbling version of the DragEnter event. To add a handler for the tunneling version of this event, see AddPreviewDragEnterHandler.
Adds a DragEnter event handler to a specified dependency object.
public static void AddDragEnterHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The DragEnter event occurs when an object is dragged into the element's bounds. This method adds a handler for the bubbling version of the DragEnter event. To add a handler for the tunneling version of this event, see AddPreviewDragEnterHandler.
Adds a DragInitialize event handler to a specified dependency object.
public static void AddDragInitializeHandler(DependencyObject element, DragInitializeEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragInitializeEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The DragInitialize event occurs when an object is about to be dragged. All needed information about the drag should be passed to the event arguments. Drag start can be stopped by setting Cancel=true.
Adds a DragInitialize event handler to a specified dependency object.
public static void AddDragInitializeHandler(DependencyObject element, DragInitializeEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragInitializeEventHandlerA delegate that references the handler method to be added.
The DragInitialize event occurs when an object is about to be dragged. All needed information about the drag should be passed to the event arguments. Drag start can be stopped by setting Cancel=true.
Adds a DragLeave event handler to a specified dependency object.
public static void AddDragLeaveHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The DragLeave event occurs when an object is dragged out of the element's bounds. This method adds a handler for the bubbling version of the DragLeave event. To add a handler for the tunneling version of this event, see AddPreviewDragLeaveHandler.
Adds a DragLeave event handler to a specified dependency object.
public static void AddDragLeaveHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The DragLeave event occurs when an object is dragged out of the element's bounds. This method adds a handler for the bubbling version of the DragLeave event. To add a handler for the tunneling version of this event, see AddPreviewDragLeaveHandler.
Adds a DragOver event handler to a specified dependency object.
public static void AddDragOverHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The DragOver event occurs when an object is dragged over the element's bounds. This method adds a handler for the bubbling version of the DragOver event. To add a handler for the tunneling version of this event, see AddPreviewDragOverHandler.
Adds a DragOver event handler to a specified dependency object.
public static void AddDragOverHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The DragOver event occurs when an object is dragged over the element's bounds. This method adds a handler for the bubbling version of the DragOver event. To add a handler for the tunneling version of this event, see AddPreviewDragOverHandler.
Adds a Drop event handler to a specified dependency object.
public static void AddDropHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The Drop event occurs when an object is dropped within an element's bounds. This method adds a handler for the bubbling version of the Drop event. To add a handler for the tunneling version of this event, see AddPreviewDropHandler.
Adds a Drop event handler to a specified dependency object.
public static void AddDropHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The Drop event occurs when an object is dropped within an element's bounds. This method adds a handler for the bubbling version of the Drop event. To add a handler for the tunneling version of this event, see AddPreviewDropHandler.
Adds a GiveFeedback event handler to a specified dependency object.
public static void AddGiveFeedbackHandler(DependencyObject element, GiveFeedbackEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerGiveFeedbackEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The GiveFeedback event occurs during a drag operation. This method adds a handler for the bubbling version of the GiveFeedback event. To add a handler for the tunneling version of this event, see AddPreviewGiveFeedbackHandler.
Adds a GiveFeedback event handler to a specified dependency object.
public static void AddGiveFeedbackHandler(DependencyObject element, GiveFeedbackEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerGiveFeedbackEventHandlerA delegate that references the handler method to be added.
The GiveFeedback event occurs during a drag operation. This method adds a handler for the bubbling version of the GiveFeedback event. To add a handler for the tunneling version of this event, see AddPreviewGiveFeedbackHandler.
Adds a PreviewDragEnter event handler to a specified dependency object.
public static void AddPreviewDragEnterHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The PreviewDragEnter event occurs when an object is dragged into the element's bounds. This method adds a handler for the tunneling version of the PreviewDragEnter event. To add a handler for the bubbling version of this event, see AddDragEnterHandler.
Adds a PreviewDragEnter event handler to a specified dependency object.
public static void AddPreviewDragEnterHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The PreviewDragEnter event occurs when an object is dragged into the element's bounds. This method adds a handler for the tunneling version of the PreviewDragEnter event. To add a handler for the bubbling version of this event, see AddDragEnterHandler.
Adds a PreviewDragLeave event handler to a specified dependency object.
public static void AddPreviewDragLeaveHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The PreviewDragLeave event occurs when an object is dragged out of the element's bounds. This method adds a handler for the tunneling version of the PreviewDragLeave event. To add a handler for the bubbling version of this event, see AddDragLeaveHandler.
Adds a PreviewDragLeave event handler to a specified dependency object.
public static void AddPreviewDragLeaveHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The PreviewDragLeave event occurs when an object is dragged out of the element's bounds. This method adds a handler for the tunneling version of the PreviewDragLeave event. To add a handler for the bubbling version of this event, see AddDragLeaveHandler.
Adds a PreviewDragOver event handler to a specified dependency object.
public static void AddPreviewDragOverHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The PreviewDragOver event occurs when an object is dragged over the element's bounds. This method adds a handler for the tunneling version of the PreviewDragOver event. To add a handler for the bubbling version of this event, see AddDragOverHandler.
Adds a PreviewDragOver event handler to a specified dependency object.
public static void AddPreviewDragOverHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The PreviewDragOver event occurs when an object is dragged over the element's bounds. This method adds a handler for the tunneling version of the PreviewDragOver event. To add a handler for the bubbling version of this event, see AddDragOverHandler.
Adds a PreviewDrop event handler to a specified dependency object.
public static void AddPreviewDropHandler(DependencyObject element, DragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The PreviewDrop event occurs when an object is dropped within an element's bounds. This method adds a handler for the tunneling version of the PreviewDrop event. To add a handler for the bubbling version of this event, see AddDropHandler.
Adds a PreviewDrop event handler to a specified dependency object.
public static void AddPreviewDropHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerDragEventHandlerA delegate that references the handler method to be added.
The PreviewDrop event occurs when an object is dropped within an element's bounds. This method adds a handler for the tunneling version of the PreviewDrop event. To add a handler for the bubbling version of this event, see AddDropHandler.
Adds a PreviewGiveFeedback event handler to a specified dependency object.
public static void AddPreviewGiveFeedbackHandler(DependencyObject element, GiveFeedbackEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerGiveFeedbackEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The PreviewGiveFeedback event occurs during a drag operation. This method adds a handler for the tunneling version of the PreviewGiveFeedback event. To add a handler for the bubbling version of this event, see AddGiveFeedbackHandler.
Adds a PreviewGiveFeedback event handler to a specified dependency object.
public static void AddPreviewGiveFeedbackHandler(DependencyObject element, GiveFeedbackEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerGiveFeedbackEventHandlerA delegate that references the handler method to be added.
The PreviewGiveFeedback event occurs during a drag operation. This method adds a handler for the tunneling version of the PreviewGiveFeedback event. To add a handler for the bubbling version of this event, see AddGiveFeedbackHandler.
Adds a PreviewQueryContinueDrag event handler to a specified dependency object.
public static void AddPreviewQueryContinueDragHandler(DependencyObject element, QueryContinueDragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerQueryContinueDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The PreviewQueryContinueDrag event occurs during a drag-and-drop operation, and enables the drag source to determine whether the drag-and-drop operation should be canceled. This method adds a handler for the tunneling version of the PreviewQueryContinueDrag event. To add a handler for the bubbling version of this event, see AddQueryContinueDragHandler.
Adds a PreviewQueryContinueDrag event handler to a specified dependency object.
public static void AddPreviewQueryContinueDragHandler(DependencyObject element, QueryContinueDragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerQueryContinueDragEventHandlerA delegate that references the handler method to be added.
The PreviewQueryContinueDrag event occurs during a drag-and-drop operation, and enables the drag source to determine whether the drag-and-drop operation should be canceled. This method adds a handler for the tunneling version of the PreviewQueryContinueDrag event. To add a handler for the bubbling version of this event, see AddQueryContinueDragHandler.
Adds a QueryContinueDrag event handler to a specified dependency object.
public static void AddQueryContinueDragHandler(DependencyObject element, QueryContinueDragEventHandler handler, bool handledEventsToo)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerQueryContinueDragEventHandlerA delegate that references the handler method to be added.
handledEventsTooboolTrue to register the handler such that it is invoked even when the routed event is marked handled in its event data; false to register the handler with the default condition that it will not be invoked if the routed event is already marked handled. The default is false.
The QueryContinueDrag event occurs during a drag-and-drop operation, and enables the drag source to determine whether the drag-and-drop operation should be canceled. This method adds a handler for the tunneling version of the QueryContinueDrag event. To add a handler for the bubbling version of this event, see AddPreviewQueryContinueDragHandler.
Adds a QueryContinueDrag event handler to a specified dependency object.
public static void AddQueryContinueDragHandler(DependencyObject element, QueryContinueDragEventHandler handler)
The dependency object (a UIElement or ContentElement) to which to add the event handler.
handlerQueryContinueDragEventHandlerA delegate that references the handler method to be added.
The QueryContinueDrag event occurs during a drag-and-drop operation, and enables the drag source to determine whether the drag-and-drop operation should be canceled. This method adds a handler for the tunneling version of the QueryContinueDrag event. To add a handler for the bubbling version of this event, see AddPreviewQueryContinueDragHandler.
Initiates a drag-and-drop operation.
public static void DoDragDrop(DependencyObject dragSource, object data, DragDropEffects allowedEffects, DragDropKeyStates initialKeyState, object dragVisual, Point relativeStartPoint, Point dragVisualOffset)
A reference to the dependency object that is the source of the data being dragged.
dataobjectA data object that contains the data being dragged.
allowedEffectsDragDropEffectsOne of the System.Windows.DragDropEffects values that specifies permitted effects of the drag-and-drop operation.
initialKeyStateDragDropKeyStatesThe initial key state when the drag operation begins.
dragVisualobjectThe object to show while drag-and-drop operation is in progress.
relativeStartPointPointCursor offset relative to dragSource element.
dragVisualOffsetPointDragVisual offset relative to dragSource element.
Initiates a drag-and-drop operation.
public static void DoDragDrop(DependencyObject dragSource, object data, DragDropEffects allowedEffects, DragDropKeyStates initialKeyState)
A reference to the dependency object that is the source of the data being dragged.
dataobjectA data object that contains the data being dragged.
allowedEffectsDragDropEffectsOne of the System.Windows.DragDropEffects values that specifies permitted effects of the drag-and-drop operation.
initialKeyStateDragDropKeyStatesThe initial key state when the drag operation begins.
Gets a value indicating whether this element can raise DragInitialize event and be used as the source of a drag-and-drop operation.
public static bool GetAllowCapturedDrag(DependencyObject obj)
The object from which the property value is read.
Returns:True if element can start automatic drag-and-drop operation, otherwise False. The default value is False.
Gets a value indicating whether this element can raise DragInitialize event and be used as the source of a drag-and-drop operation.
public static bool GetAllowDrag(DependencyObject obj)
The object from which the property value is read.
Returns:True if element can start automatic drag-and-drop operation, otherwise False. The default value is False.
Removes a DragDropCompleted event handler from a specified dependency object.
public static void RemoveDragDropCompletedHandler(DependencyObject element, DragDropCompletedEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragDropCompletedEventHandlerA delegate that references the handler method to be removed.
The DragDropCompleted event occurs when an drag-and-drop operation ends(On Drop or Cancel).
Removes a DragEnter event handler from a specified dependency object.
public static void RemoveDragEnterHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The DragEnter event occurs when an object is dragged into the element's bounds. This method removes a handler for the bubbling version of the DragEnter event. To remove a handler for the tunneling version of this event, see RemovePreviewDragEnterHandler.
Removes a DragInitialize event handler from a specified dependency object.
public static void RemoveDragInitializeHandler(DependencyObject element, DragInitializeEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragInitializeEventHandlerA delegate that references the handler method to be removed.
The DragInitialize event occurs when an object is about to be dragged. All needed information about the drag should be passed to the event arguments. Drag start can be stopped by setting Cancel=true.
Removes a DragLeave event handler from a specified dependency object.
public static void RemoveDragLeaveHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The DragLeave event occurs when an object is dragged out of the element's bounds. This method removes a handler for the bubbling version of the DragLeave event. To remove a handler for the tunneling version of this event, see RemovePreviewDragLeaveHandler.
Removes a DragOver event handler from a specified dependency object.
public static void RemoveDragOverHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The DragOver event occurs when an object is dragged over the element's bounds. This method removes a handler for the bubbling version of the DragOver event. To remove a handler for the tunneling version of this event, see RemovePreviewDragOverHandler.
Removes a Drop event handler from a specified dependency object.
public static void RemoveDropHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The Drop event occurs when an object is dropped within an element's bounds. This method removes a handler for the bubbling version of the Drop event. To remove a handler for the bubbling version of this event, see RemovePreviewDropHandler.
Removes a GiveFeedback event handler from a specified dependency object.
public static void RemoveGiveFeedbackHandler(DependencyObject element, GiveFeedbackEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerGiveFeedbackEventHandlerA delegate that references the handler method to be removed.
The GiveFeedback event occurs during a drag operation. This method removes a handler for the bubbling version of the GiveFeedback event. To remove a handler for the tunneling version of this event, see RemovePreviewGiveFeedbackHandler.
Removes a PreviewDragEnter event handler from a specified dependency object.
public static void RemovePreviewDragEnterHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The PreviewDragEnter event occurs when an object is dragged into the element's bounds. This method removes a handler for the tunneling version of the PreviewDragEnter event. To remove a handler for the bubbling version of this event, see RemoveDragEnterHandler.
Removes a PreviewDragLeave event handler from a specified dependency object.
public static void RemovePreviewDragLeaveHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The PreviewDragLeave event occurs when an object is dragged out of the element's bounds. This method removes a handler for the tunneling version of the PreviewDragLeave event. To remove a handler for the bubbling version of this event, see RemoveDragLeaveHandler.
Removes a PreviewDragOver event handler from a specified dependency object.
public static void RemovePreviewDragOverHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The PreviewDragOver event occurs when an object is dragged over the element's bounds. This method removes a handler for the tunneling version of the PreviewDragOver event. To remove a handler for the bubbling version of this event, see RemoveDragOverHandler.
Removes a PreviewDrop event handler from a specified dependency object.
public static void RemovePreviewDropHandler(DependencyObject element, DragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerDragEventHandlerA delegate that references the handler method to be removed.
The PreviewDrop event occurs when an object is dropped within an element's bounds. This method removes a handler for the tunneling version of the PreviewDrop event. To remove a handler for the bubbling version of this event, see RemoveDropHandler.
Removes a PreviewGiveFeedback event handler from a specified dependency object.
public static void RemovePreviewGiveFeedbackHandler(DependencyObject element, GiveFeedbackEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerGiveFeedbackEventHandlerA delegate that references the handler method to be removed.
The PreviewGiveFeedback event occurs during a drag operation. This method removes a handler for the tunneling version of the PreviewGiveFeedback event. To remove a handler for the bubbling version of this event, see RemoveGiveFeedbackHandler.
Removes a PreviewQueryContinueDrag event handler from a specified dependency object.
public static void RemovePreviewQueryContinueDragHandler(DependencyObject element, QueryContinueDragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerQueryContinueDragEventHandlerA delegate that references the handler method to be removed.
The PreviewQueryContinueDrag event occurs during a drag-and-drop operation, and enables the drag source to determine whether the drag-and-drop operation should be canceled. This method removes a handler for the tunneling version of the PreviewQueryContinueDrag event. To remove a handler for the bubbling version of this event, see RemoveQueryContinueDragHandler.
Removes a QueryContinueDrag event handler from a specified dependency object.
public static void RemoveQueryContinueDragHandler(DependencyObject element, QueryContinueDragEventHandler handler)
The dependency object (a UIElement or ContentElement) from which to remove the event handler.
handlerQueryContinueDragEventHandlerA delegate that references the handler method to be removed.
The QueryContinueDrag event occurs during a drag-and-drop operation, and enables the drag source to determine whether the drag-and-drop operation should be canceled. This method removes a handler for the bubbling version of the QueryContinueDrag event. To remove a handler for the tunneling version of this event, see RemovePreviewQueryContinueDragHandler.
Sets a value indicating whether this element can raise DragInitialize event and be used as the source of a drag-and-drop operation. When set the dragged element will steal mouse capture (WPF only).
public static void SetAllowCapturedDrag(DependencyObject obj, bool value)
The object on which to set the value.
valueboolBoolean value specifying if this element can automatically raise DragInitialize event and be used as the source of a drag-and-drop operation and steal mouse capture.
Sets a value indicating whether this element can raise DragInitialize event and be used as the source of a drag-and-drop operation.
public static void SetAllowDrag(DependencyObject obj, bool value)
The object on which to set the value.
valueboolBoolean value specifying if this element can automatically raise DragInitialize event and be used as the source of a drag-and-drop operation.