[ol.Tile] register to image load
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
goog.provide('ol.Tile');
|
goog.provide('ol.Tile');
|
||||||
|
|
||||||
|
goog.require('goog.events');
|
||||||
goog.require('ol.Bounds');
|
goog.require('ol.Bounds');
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -27,6 +28,9 @@ ol.Tile = function(url, bounds) {
|
|||||||
* @type {Element}
|
* @type {Element}
|
||||||
*/
|
*/
|
||||||
this.img_ = ol.Tile.createImage();
|
this.img_ = ol.Tile.createImage();
|
||||||
|
goog.events.listenOnce(this.img_, goog.events.EventType.LOAD,
|
||||||
|
this.handleImageLoad, false, this);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -60,6 +64,12 @@ ol.Tile.prototype.getImg = function() {
|
|||||||
return this.img_;
|
return this.img_;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
ol.Tile.prototype.handleImageLoad = function() {
|
||||||
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create an image node. This is done by cloning
|
* Create an image node. This is done by cloning
|
||||||
* the same image element.
|
* the same image element.
|
||||||
|
|||||||
Reference in New Issue
Block a user