void OnPointerReleased(object sender, PointerRoutedEventArgs e) { if (_pointerID != e.Pointer.PointerId) { return; } ReleasePointerCapture(e.Pointer); e.Handled = true; _pointerID = null; if (e.IsMouse()) { Point pt = e.GetCurrentPoint(null).Position; if (this.ContainPoint(pt)) { _owner.Lv.ScrollIntoGroup(Group); } } else if (!_isMoved) { _owner.Lv.ScrollIntoGroup(Group); } _isMoved = false; }
void OnPointerCaptureLost(object sender, PointerRoutedEventArgs e) { if (e.IsMouse()) { ResetMouseState(); } }
void OnPointerExited(object sender, PointerRoutedEventArgs e) { if (e.IsMouse() && !IsSelected) { e.Handled = true; VisualStateManager.GoToState(this, "Normal", true); } }
void OnPointerExited(object sender, PointerRoutedEventArgs e) { if (e.IsMouse() && !_isDragging && _resizingCol == null) { SetCursor(CoreCursorType.Arrow); VisualStateManager.GoToState(this, "Normal", true); } }
void OnPointerEntered(object sender, PointerRoutedEventArgs e) { if (!_menuOpened && e.IsMouse() && (_owner.SelectionMode == SelectionMode.None || !_row.IsSelected)) { _rcPointer.Fill = _owner.EnteredBrush; } }
void OnPointerPressed(object sender, PointerRoutedEventArgs e) { if (CapturePointer(e.Pointer)) { e.Handled = true; _pointerID = e.Pointer.PointerId; _isMoved = false; _ptLast = e.GetCurrentPoint(null).Position; if (e.IsMouse() && !IsSelected) { VisualStateManager.GoToState(this, "Pressed", true); } } }
void OnPointerEntered(object sender, PointerRoutedEventArgs e) { if (e.IsMouse() && !_isDragging && _resizingCol == null) { Point pt = e.GetCurrentPoint(this).Position; if (pt.X >= _resizePadding && Col.Width - pt.X >= _resizePadding) { SetCursor(CoreCursorType.Arrow); VisualStateManager.GoToState(this, "PointerOver", true); } else { SetCursor(CoreCursorType.SizeWestEast); VisualStateManager.GoToState(this, "Normal", true); } } }