remove event type list from Events (lazy listener initialization) p=tschaub,me r=erilem (closes #2555)

git-svn-id: http://svn.openlayers.org/trunk/openlayers@12384 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
Frédéric Junod
2011-09-17 19:09:40 +00:00
parent 67a5743d91
commit 501b42228a
25 changed files with 85 additions and 295 deletions
+6 -4
View File
@@ -26,10 +26,12 @@
OpenLayers.Tile = OpenLayers.Class({
/**
* Constant: EVENT_TYPES
* {Array(String)} Supported application event types
* Supported event types:
* - *loadstart* Triggered when tile loading starts.
* - *loadend* Triggered when tile loading ends.
* - *reload* Triggered when an already loading tile is reloaded.
* - *unload* Triggered before a tile is unloaded.
*/
EVENT_TYPES: [ "loadstart", "loadend", "reload", "unload"],
/**
* APIProperty: events
@@ -110,7 +112,7 @@ OpenLayers.Tile = OpenLayers.Class({
//give the tile a unique id based on its BBOX.
this.id = OpenLayers.Util.createUniqueID("Tile_");
this.events = new OpenLayers.Events(this, null, this.EVENT_TYPES);
this.events = new OpenLayers.Events(this);
OpenLayers.Util.extend(this, options);
},