ContentElement.TouchDown 事件
定义
当悬停在此元素上方的手指触摸屏幕时发生。Occurs when a finger touches the screen while the finger is over this element.
public:
event EventHandler<System::Windows::Input::TouchEventArgs ^> ^ TouchDown;
public event EventHandler<System.Windows.Input.TouchEventArgs> TouchDown;
member this.TouchDown : EventHandler<System.Windows.Input.TouchEventArgs>
Public Custom Event TouchDown As EventHandler(Of TouchEventArgs)
事件类型
注解
默认情况下, PreviewTouchDown 在 TouchDown 手指触摸屏幕并移动之前,和事件不会发生。By default, the PreviewTouchDown and TouchDown events do not occur until a finger touches the screen and moves. 在屏幕上按一根手指并在不移动它的情况下,将导致的按下和保持行为 Stylus 。Pressing a finger on the screen and holding it without moving it causes the press and hold behavior of a Stylus. 按住行为等效于鼠标右键单击。The press and hold behavior is equivalent to a mouse right-click.
若要使 PreviewTouchDown 和 TouchDown 事件在手指触摸屏幕时立即发生,请将 Stylus.IsPressAndHoldEnabled 此元素的附加属性设置为 false
。To cause the PreviewTouchDown and TouchDown events to occur as soon as a finger touches the screen, set the Stylus.IsPressAndHoldEnabled attached property to false
for this element.
路由事件信息Routed Event Information
标识符字段Identifier field | TouchDownEvent |
路由策略Routing strategy | 冒泡Bubbling |
委托Delegate | EventHandler<TEventArgs>类型TouchEventArgs。EventHandler<TEventArgs> of type TouchEventArgs. |
对应的隧道事件为 PreviewTouchDown 。The corresponding tunneling event is PreviewTouchDown.
重写 OnTouchDown 以在派生类中实现此事件的类处理。Override OnTouchDown to implement class handling for this event in derived classes.