diff options
author | jfrijters <jfrijters> | 2015-05-06 10:17:40 +0300 |
---|---|---|
committer | jfrijters <jfrijters> | 2015-05-06 10:17:40 +0300 |
commit | 8c1f4b82c64ab915af3ca8edc68f449690599b36 (patch) | |
tree | 686de2bc22ca215679762fab5a57795966f93594 | |
parent | df62b0786fba26feffd00268d7ae7de7cc873a69 (diff) |
Fixed drag-n-drop coordinates. Patch by Daniel Zatonyi <dzatonyi@chemaxon.com>.
-rw-r--r-- | awt/toolkit-0.95.cs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/awt/toolkit-0.95.cs b/awt/toolkit-0.95.cs index 00abb17f..a8a055aa 100644 --- a/awt/toolkit-0.95.cs +++ b/awt/toolkit-0.95.cs @@ -1414,7 +1414,11 @@ namespace ikvm.awt int eventID, bool dispatchType) { - return base.postDropTargetEvent(component, x, y, + NetComponentPeer peer = (NetComponentPeer)component.getPeer(); + Control control = peer.Control; + Point screenPt = new Point(x, y); + Point clientPt = control.PointToClient(screenPt); + return base.postDropTargetEvent(component, clientPt.X, clientPt.Y, dropAction, actions, formats, nativeCtxt, eventID, dispatchType); } |