[OpenLayers-Commits] r3134 - sandbox/ominiverdi/openlayers/lib/OpenLayers/Control
commits at openlayers.org
commits at openlayers.org
Fri May 4 12:03:44 EDT 2007
Author: ominiverdi
Date: 2007-05-04 12:03:44 -0400 (Fri, 04 May 2007)
New Revision: 3134
Modified:
sandbox/ominiverdi/openlayers/lib/OpenLayers/Control/WMSManager.js
Log:
WMSManager (ticket #687): fix bug when LatLonBoundingBox is not set. Substitution with BoundingBox.
Modified: sandbox/ominiverdi/openlayers/lib/OpenLayers/Control/WMSManager.js
===================================================================
--- sandbox/ominiverdi/openlayers/lib/OpenLayers/Control/WMSManager.js 2007-05-04 15:00:47 UTC (rev 3133)
+++ sandbox/ominiverdi/openlayers/lib/OpenLayers/Control/WMSManager.js 2007-05-04 16:03:44 UTC (rev 3134)
@@ -610,7 +610,12 @@
//alert('1');
//get Extent (to implent BoundingBox alternative)
+ /*
+ * this part drammatically need to set the right extent, somehow to every layer.
+ * for the moment it catches the first bbox available.
+ */
var bbox = xml.getElementsByTagName('LatLonBoundingBox')[0];
+ if(!bbox) bbox = xml.getElementsByTagName('BoundingBox')[0];
this.extent = [bbox.getAttribute('minx'),bbox.getAttribute('miny'),bbox.getAttribute('maxx'),bbox.getAttribute('maxy')];
this.mapCenter = [((bbox.getAttribute('maxx') - bbox.getAttribute('minx'))/2),((bbox.getAttribute('maxy') - bbox.getAttribute('miny'))/2)]
@@ -663,6 +668,7 @@
}
formObj.appendChild(select);
+ //alert('5');
//add radio for overlay selection
/* var radioSbase = document.createElement('span');
radioSbase.innerHTML = 'base';
More information about the Commits
mailing list