Skip to content

Commit

Permalink
Fixed Leaflet GET_COORDINATES_FROM_PIXEL_HOOK and GET_PIXEL_FROM_COOR…
Browse files Browse the repository at this point in the history
…DINATES_HOOK hooks
  • Loading branch information
kappu committed Aug 8, 2017
1 parent beab9f2 commit 901ce14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web/client/components/map/leaflet/Map.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ class LeafletMap extends React.Component {
});
mapUtils.registerHook(mapUtils.GET_PIXEL_FROM_COORDINATES_HOOK, (pos) => {
let latLng = CoordinatesUtils.reproject(pos, this.props.projection, 'EPSG:4326');
let pixel = this.map.latLngToContainerPoint([latLng.x, latLng.y]);
let pixel = this.map.latLngToContainerPoint([latLng.y, latLng.x]);
return [pixel.x, pixel.y];
});
mapUtils.registerHook(mapUtils.GET_COORDINATES_FROM_PIXEL_HOOK, (pixel) => {
Expand Down

0 comments on commit 901ce14

Please sign in to comment.