UIElement.DragOver 事件

定义

在输入系统报告出现以此元素为可能放置目标的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the potential drop target.

public:
 event System::Windows::DragEventHandler ^ DragOver;
public event System.Windows.DragEventHandler DragOver;
member this.DragOver : System.Windows.DragEventHandler 
Public Custom Event DragOver As DragEventHandler 

注解

即使拖动源自元素边界,也会发生此事件。This event occurs even if the drag originates in the element bounds. 如果拖动从边界外开始,并在内部移动,则还会引发此事件,以及 DragEnter 和相关的预览事件。If the drag starts outside the bounds and then moves inside, this event is also raised, as well as DragEnter and related preview events.

此事件将为此类创建 DragDrop.DragOver 附加事件的别名,以便在将 UIElement 作为基元素继承时,UIElement.DragOver 是类成员列表的一部分。This event creates an alias for the DragDrop.DragOver attached event for this class so that UIElement.DragOver is part of the class members list when UIElement is inherited as a base element. 附加到 DragOver 事件的事件处理程序附加到基础 DragDrop.DragOver 附加事件,并接收相同的事件数据实例。Event handlers that are attached to the DragOver event are attached to the underlying DragDrop.DragOver attached event and receive the same event data instance.

路由事件信息Routed Event Information

标识符字段Identifier field DragOverEvent
路由策略Routing strategy 冒泡Bubbling
委托Delegate DragEventHandler

适用于

另请参阅