Пример #1
0
 protected override void OnPreviewMouseMove(MouseEventArgs e)
 {
     // consume event if touch is down
     if (_lastTouchEvent != null)
     {
         e.Handled = true;
     }
 }
Пример #2
0
 public void MouseCaptureTestMouseMove(object sender, MouseEventArgs e)
 {
   UIElement element;
   if (MouseCaptureTestCaptureOriginalSource)
   {
     element = e.OriginalSource as UIElement;
   }
   else
   {
     element = e.Source as UIElement;
   }
   if (element != null)
   {
     var pt = e.GetPosition(element);
     MouseCaptureTestMousePos = String.Format("{0:F1}/{1:F1}", pt.X, pt.Y);
   }
 }
Пример #3
0
 /// <summary>
 /// Invoked when unhandled MouseMove event reaches this element. This method is called before the MouseMove event is fired.
 /// </summary>
 /// <param name="e">The event arguments for the event.</param>
 /// <remarks>This base implementation is empty.</remarks>
 protected virtual void OnMouseMove(MouseEventArgs e)
 { }
Пример #4
0
 private static void OnMouseMoveThunk(object sender, MouseEventArgs e)
 {
   var uiElement = sender as UIElement;
   if (uiElement != null)
   {
     uiElement.OnMouseMove(e);
   }
 }
Пример #5
0
 /// <summary>
 /// Invoked when unhandled PreviewMouseMove event reaches this element. This method is called before the PreviewMouseMove event is fired.
 /// </summary>
 /// <param name="e">The event arguments for the event.</param>
 /// <remarks>This base implementation is empty.</remarks>
 protected virtual void OnPreviewMouseMove(MouseEventArgs e)
 { }
Пример #6
0
 protected override void OnPreviewMouseMove(MouseEventArgs e)
 {
   // consume event if touch is down
   if (_lastTouchEvent != null)
   {
     e.Handled = true;
   }
 }