Overriding onImageLoad to set the opacity on the correct element.
This commit is contained in:
@@ -196,6 +196,19 @@ OpenLayers.Tile.Image.IFrame = {
|
||||
OpenLayers.Tile.Image.prototype.setImgSrc.apply(this, arguments);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Method: onImageLoad
|
||||
* Handler for the image onload event
|
||||
*/
|
||||
onImageLoad: function() {
|
||||
//TODO de-uglify opacity handling
|
||||
OpenLayers.Tile.Image.prototype.onImageLoad.apply(this, arguments);
|
||||
if (this.useIFrame === true) {
|
||||
this.imgDiv.style.opacity = 1;
|
||||
this.frame.style.opacity = this.layer.opacity;
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Method: createBackBuffer
|
||||
|
||||
Reference in New Issue
Block a user