diff --git a/lcl/include/dragdock.inc b/lcl/include/dragdock.inc index f9208194a1..2ec0d52e9b 100644 --- a/lcl/include/dragdock.inc +++ b/lcl/include/dragdock.inc @@ -255,9 +255,9 @@ Begin else ActiveDrag := dopDock; - // if Target changed, send dmDragLeave to old target and dmDragEnter to new if TargetControl <> DragObject.DragTarget then begin + // Target changed => send dmDragLeave to old target and dmDragEnter to new SendDragOver(dmDragLeave); if DragObject = nil then Exit; DragObject.DragTarget := TargetControl; @@ -268,6 +268,11 @@ Begin DragObject.DragPos := Position; SendDragOver(dmDragEnter); if DragObject = nil then Exit; + end else begin + // same target => send dmDragMove + DragObject.DragPos := Position; + SendDragOver(dmDragMove); + if DragObject = nil then Exit; end; // update Position