// ========================================
        // method
        // ========================================
        public void PrepareDnDOnMouseDown(IMouseOperatable target, MouseEventArgs e)
        {
            if (target == null)
            {
                return;
            }
            ClearDnDState();
            var dragSource = target.DragSource as DragSource;

            if (dragSource == null)
            {
                return;
            }
            var dragSourceEventArgs = new DragSourceEventArgs(e);

            dragSource.HandleJudgeDragStart(target, dragSourceEventArgs);
            if (dragSourceEventArgs.DoIt)
            {
                _currentProceededDragSource     = dragSource;
                _lastCreatedDragSourceEventArgs = dragSourceEventArgs;
                _isPrepared = true;
            }
        }
        public bool ShouldDnDOnDragOut(IDragSource dragSource, object eventSender, MouseEventArgs e)
        {
            ClearDnDState();
            var dragSrc = dragSource as DragSource;

            if (dragSource == null)
            {
                return(false);
            }
            var dragSourceEventArgs = new DragSourceEventArgs(e);

            dragSrc.HandleJudgeDragStart(eventSender, dragSourceEventArgs);
            if (dragSourceEventArgs.DoIt)
            {
                _currentProceededDragSource     = dragSrc;
                _lastCreatedDragSourceEventArgs = dragSourceEventArgs;
                _isPrepared = true;
                return(true);
            }
            else
            {
                return(false);
            }
        }
 public void ClearDnDState()
 {
     _currentProceededDragSource     = null;
     _lastCreatedDragSourceEventArgs = null;
     _isPrepared = false;
 }