protected override void OnPreviewDragLeave(DragEventArgs e) { base.OnPreviewDragLeave(e); //Debug.WriteLine("PreviewDragLeave"); _insertionAdorner?.Dispose(); _insertionAdorner = null; }
private void ResetDragAndDropParameter() { //Debug.WriteLine("ResetParameter"); _targetContainer = null; _startPosition = new Point(); _dragAdorner?.Dispose(); _dragAdorner = null; _insertionAdorner?.Dispose(); _insertionAdorner = null; }
protected override void OnPreviewDragEnter(DragEventArgs e) { base.OnPreviewDragEnter(e); //Debug.WriteLine("PreviewDragEnter"); // のっかったコンテナを取得 var isBottom = false; var entered = GetContainer(e.OriginalSource as FrameworkElement); if (entered == null) { // 最後にしてみる entered = ItemContainerGenerator.ContainerFromIndex(Items.Count - 1) as FrameworkElement; isBottom = true; } _insertionAdorner = InsertionAdorner.Create(entered, isBottom); }
protected override void OnPreviewDragEnter(DragEventArgs e) { base.OnPreviewDragEnter(e); //Debug.WriteLine("PreviewDragEnter"); // のっかったコンテナを取得 var isBottom = false; var entered = GetContainer(e.OriginalSource as FrameworkElement); if (entered == null) { // 最後にしてみる entered = ItemContainerGenerator.ContainerFromIndex(Items.Count - 1) as FrameworkElement; isBottom = true; } _insertionAdorner = InsertionAdorner.Create(entered, isBottom); }
private void ResetDragAndDropParameter() { //Debug.WriteLine("ResetParameter"); _targetContainer = null; _startPosition = new Point(); _dragAdorner?.Dispose(); _dragAdorner = null; _insertionAdorner?.Dispose(); _insertionAdorner = null; }
protected override void OnPreviewDragLeave(DragEventArgs e) { base.OnPreviewDragLeave(e); //Debug.WriteLine("PreviewDragLeave"); _insertionAdorner?.Dispose(); _insertionAdorner = null; }