Use ol.LEGACY_IE_SUPPORT and ol.IS_LEGACY_IE define

See #1605
This commit is contained in:
Frederic Junod
2014-09-06 17:52:11 +02:00
parent 2876902333
commit 23745cd043

View File

@@ -113,9 +113,11 @@ ol.ImageTile.prototype.handleImageError_ = function() {
* @private
*/
ol.ImageTile.prototype.handleImageLoad_ = function() {
if (!goog.isDef(this.image_.naturalWidth)) {
this.image_.naturalWidth = this.image_.width;
this.image_.naturalHeight = this.image_.height;
if (ol.LEGACY_IE_SUPPORT && ol.IS_LEGACY_IE) {
if (!goog.isDef(this.image_.naturalWidth)) {
this.image_.naturalWidth = this.image_.width;
this.image_.naturalHeight = this.image_.height;
}
}
if (this.image_.naturalWidth && this.image_.naturalHeight) {