fixing dateline handling of Util.getFormattedLonLat. p=cayenne, r=me (closes #3411)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@12172 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -1865,6 +1865,9 @@ OpenLayers.Util.getFormattedLonLat = function(coordinate, axis, dmsOption) {
|
||||
if (!dmsOption) {
|
||||
dmsOption = 'dms'; //default to show degree, minutes, seconds
|
||||
}
|
||||
|
||||
coordinate = (coordinate+540)%360 - 180; // normalize for sphere being round
|
||||
|
||||
var abscoordinate = Math.abs(coordinate);
|
||||
var coordinatedegrees = Math.floor(abscoordinate);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user