Hi there,
would it be possible to change the constructor of org.geotools.swt.event.MapMouseEvent
public MapMouseEvent( SwtMapPane pane, MouseEvent event, boolean isWheel ) {
this.event = event;
this.event = event;
isWheelEvent = isWheel;
if (!isWheel) {
wheelAmount = 0;
if (!isWheel) {
wheelAmount = 0;
AffineTransform tr = pane.getScreenToWorldTransform();
geoCoords = new DirectPosition2D(event.x, event.y);
tr.transform(geoCoords, geoCoords);
geoCoords.setCoordinateReferenceSystem(pane.getMapContent().getCoordinateReferenceSystem());
} else {
wheelAmount = 3;// event.getWheelRotation();
}
}
geoCoords = new DirectPosition2D(event.x, event.y);
tr.transform(geoCoords, geoCoords);
geoCoords.setCoordinateReferenceSystem(pane.getMapContent().getCoordinateReferenceSystem());
} else {
wheelAmount = 3;// event.getWheelRotation();
}
}
to
public MapMouseEvent( SwtMapPane pane, MouseEvent event, boolean isWheel ) {
this.event = event;
this.event = event;
isWheelEvent = isWheel;
if (!isWheel) {
wheelAmount = 0;
} else {
wheelAmount = event.count;
}
if (!isWheel) {
wheelAmount = 0;
} else {
wheelAmount = event.count;
}
AffineTransform tr = pane.getScreenToWorldTransform();
geoCoords = new DirectPosition2D(event.x, event.y);
tr.transform(geoCoords, geoCoords);
geoCoords.setCoordinateReferenceSystem(pane.getMapContent().getCoordinateReferenceSystem());
}
geoCoords = new DirectPosition2D(event.x, event.y);
tr.transform(geoCoords, geoCoords);
geoCoords.setCoordinateReferenceSystem(pane.getMapContent().getCoordinateReferenceSystem());
}
.
Currently I have to use Reflection to get the needed information stored in the MouseEvent.
Best regards
Bastian
------------------------------------------------------------------------------ Managing the Performance of Cloud-Based Applications Take advantage of what the Cloud has to offer - Avoid Common Pitfalls. Read the Whitepaper. http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
_______________________________________________ GeoTools-Devel mailing list GeoTools-Devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-devel