Add support for ArcIMS/ArcXML to OpenLayers.

Thanks for the killer effort from David Zwarg from Avencia in building this, 
and for Tim Schaub from OpenGeo for his excellent review. r=me,tschaub
(Closes #213)


git-svn-id: http://svn.openlayers.org/trunk/openlayers@9249 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
crschmidt
2009-04-09 00:15:48 +00:00
parent 08077f0f42
commit 2b7e8f5198
12 changed files with 2120 additions and 7 deletions

View File

@@ -284,15 +284,44 @@ OpenLayers.Tile.Image = OpenLayers.Class(OpenLayers.Tile, {
this.imgDiv.viewRequestID = this.layer.map.viewRequestID;
// needed for changing to a different serve for onload error
if (this.layer.url instanceof Array) {
this.imgDiv.urls = this.layer.url.slice();
if (this.layer.async) {
// Asyncronous image requests call the asynchronous getURL method
// on the layer to fetch an image that covers 'this.bounds', in the scope of
// 'this', setting the 'url' property of the layer itself, and running
// the callback 'positionFrame' when the image request returns.
this.layer.getURLasync(this.bounds, this, "url", this.positionImage);
} else {
// syncronous image requests get the url and position the frame immediately,
// and don't wait for an image request to come back.
// needed for changing to a different server for onload error
if (this.layer.url instanceof Array) {
this.imgDiv.urls = this.layer.url.slice();
}
this.url = this.layer.getURL(this.bounds);
// position the frame immediately
this.positionImage();
}
return true;
},
/**
* Method: positionImage
* Using the properties currenty set on the layer, position the tile correctly.
* This method is used both by the async and non-async versions of the Tile.Image
* code.
*/
positionImage: function() {
// if the this layer doesn't exist at the point the image is
// returned, do not attempt to use it for size computation
if ( this.layer == null )
return;
this.url = this.layer.getURL(this.bounds);
// position the frame
OpenLayers.Util.modifyDOMElement(this.frame,
null, this.position, this.size);
null, this.position, this.size);
if (this.layerAlphaHack) {
OpenLayers.Util.modifyAlphaImageDiv(this.imgDiv,
@@ -302,7 +331,6 @@ OpenLayers.Tile.Image = OpenLayers.Class(OpenLayers.Tile, {
null, null, this.size) ;
this.imgDiv.src = this.url;
}
return true;
},
/**