//Drag ongoing when mouse is moving and left mouse button is clicked internal void DragMove_MouseMove(object sender, MouseEventArgs e) { //If left mouse button is not clicked exit method if (!pinDragInProgress) { return; } Pin pin = (Pin)sender; pin.DragMove(Canvas_map, e); }