Rename ol.source.TileEvent to ol.source.Tile.Event
This commit is contained in:
@@ -8,19 +8,21 @@ As last step in the removal of the dependency on Google Closure Library, the `go
|
|||||||
|
|
||||||
A number of internal types have been renamed. This will not affect those who use the API provided by the library, but if you are compiling your application together with OpenLayers and using type names, you'll need to do the following:
|
A number of internal types have been renamed. This will not affect those who use the API provided by the library, but if you are compiling your application together with OpenLayers and using type names, you'll need to do the following:
|
||||||
|
|
||||||
* rename `ol.style.IconAnchorUnits` to `ol.style.Icon.AnchorUnits`
|
|
||||||
* rename `ol.style.IconOrigin` to `ol.style.Icon.Origin`
|
|
||||||
* rename `ol.format.IGCZ` to `ol.format.IGC.Z`
|
|
||||||
* rename `ol.layer.GroupProperty` to `ol.layer.Group.Property`
|
|
||||||
* rename `ol.CollectionProperty` to `ol.Collection.Property`
|
* rename `ol.CollectionProperty` to `ol.Collection.Property`
|
||||||
* rename `ol.DeviceOrientationProperty` to `ol.DeviceOrientation.Property`
|
* rename `ol.DeviceOrientationProperty` to `ol.DeviceOrientation.Property`
|
||||||
* rename `ol.GeolocationProperty` to `ol.Geolocation.Property`
|
* rename `ol.GeolocationProperty` to `ol.Geolocation.Property`
|
||||||
* rename `ol.OverlayProperty` to `ol.Overlay.Property`
|
|
||||||
* rename `ol.OverlayPositioning` to `ol.Overlay.Positioning`
|
* rename `ol.OverlayPositioning` to `ol.Overlay.Positioning`
|
||||||
|
* rename `ol.OverlayProperty` to `ol.Overlay.Property`
|
||||||
* rename `ol.control.MousePositionProperty` to `ol.control.MousePosition.Property`
|
* rename `ol.control.MousePositionProperty` to `ol.control.MousePosition.Property`
|
||||||
* rename `ol.layer.VectorTileRenderType` to `ol.layer.VectorTile.RenderType`
|
* rename `ol.format.IGCZ` to `ol.format.IGC.Z`
|
||||||
* rename `ol.source.WMTSRequestEncoding` to `ol.source.WMTS.RequestEncoding`
|
* rename `ol.layer.GroupProperty` to `ol.layer.Group.Property`
|
||||||
* rename `ol.layer.HeatmapLayerProperty` to `ol.layer.Heatmap.Property`
|
* rename `ol.layer.HeatmapLayerProperty` to `ol.layer.Heatmap.Property`
|
||||||
|
* rename `ol.layer.VectorTileRenderType` to `ol.layer.VectorTile.RenderType`
|
||||||
|
* rename `ol.source.TileEvent` to `ol.source.Tile.Event`
|
||||||
|
* rename `ol.source.TileEventType` to `ol.source.Tile.EventType`
|
||||||
|
* rename `ol.source.WMTSRequestEncoding` to `ol.source.WMTS.RequestEncoding`
|
||||||
|
* rename `ol.style.IconAnchorUnits` to `ol.style.Icon.AnchorUnits`
|
||||||
|
* rename `ol.style.IconOrigin` to `ol.style.Icon.Origin`
|
||||||
|
|
||||||
### v3.18.0
|
### v3.18.0
|
||||||
|
|
||||||
|
|||||||
@@ -347,13 +347,13 @@ oli.source.RasterEvent.prototype.data;
|
|||||||
/**
|
/**
|
||||||
* @interface
|
* @interface
|
||||||
*/
|
*/
|
||||||
oli.source.TileEvent = function() {};
|
oli.source.Tile.Event = function() {};
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @type {ol.Tile}
|
* @type {ol.Tile}
|
||||||
*/
|
*/
|
||||||
oli.source.TileEvent.prototype.tile;
|
oli.source.Tile.Event.prototype.tile;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
goog.provide('ol.source.Tile');
|
goog.provide('ol.source.Tile');
|
||||||
goog.provide('ol.source.TileEvent');
|
|
||||||
|
|
||||||
goog.require('ol');
|
goog.require('ol');
|
||||||
goog.require('ol.Tile');
|
goog.require('ol.Tile');
|
||||||
@@ -318,11 +317,11 @@ ol.source.Tile.prototype.useTile = ol.nullFunction;
|
|||||||
*
|
*
|
||||||
* @constructor
|
* @constructor
|
||||||
* @extends {ol.events.Event}
|
* @extends {ol.events.Event}
|
||||||
* @implements {oli.source.TileEvent}
|
* @implements {oli.source.Tile.Event}
|
||||||
* @param {string} type Type.
|
* @param {string} type Type.
|
||||||
* @param {ol.Tile} tile The tile.
|
* @param {ol.Tile} tile The tile.
|
||||||
*/
|
*/
|
||||||
ol.source.TileEvent = function(type, tile) {
|
ol.source.Tile.Event = function(type, tile) {
|
||||||
|
|
||||||
ol.events.Event.call(this, type);
|
ol.events.Event.call(this, type);
|
||||||
|
|
||||||
@@ -334,31 +333,31 @@ ol.source.TileEvent = function(type, tile) {
|
|||||||
this.tile = tile;
|
this.tile = tile;
|
||||||
|
|
||||||
};
|
};
|
||||||
ol.inherits(ol.source.TileEvent, ol.events.Event);
|
ol.inherits(ol.source.Tile.Event, ol.events.Event);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @enum {string}
|
* @enum {string}
|
||||||
*/
|
*/
|
||||||
ol.source.TileEventType = {
|
ol.source.Tile.EventType = {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Triggered when a tile starts loading.
|
* Triggered when a tile starts loading.
|
||||||
* @event ol.source.TileEvent#tileloadstart
|
* @event ol.source.Tile.Event#tileloadstart
|
||||||
* @api stable
|
* @api stable
|
||||||
*/
|
*/
|
||||||
TILELOADSTART: 'tileloadstart',
|
TILELOADSTART: 'tileloadstart',
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Triggered when a tile finishes loading.
|
* Triggered when a tile finishes loading.
|
||||||
* @event ol.source.TileEvent#tileloadend
|
* @event ol.source.Tile.Event#tileloadend
|
||||||
* @api stable
|
* @api stable
|
||||||
*/
|
*/
|
||||||
TILELOADEND: 'tileloadend',
|
TILELOADEND: 'tileloadend',
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Triggered if tile loading results in an error.
|
* Triggered if tile loading results in an error.
|
||||||
* @event ol.source.TileEvent#tileloaderror
|
* @event ol.source.Tile.Event#tileloaderror
|
||||||
* @api stable
|
* @api stable
|
||||||
*/
|
*/
|
||||||
TILELOADERROR: 'tileloaderror'
|
TILELOADERROR: 'tileloaderror'
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ goog.require('ol.tilegrid');
|
|||||||
* Base class for sources providing images divided into a tile grid.
|
* Base class for sources providing images divided into a tile grid.
|
||||||
*
|
*
|
||||||
* @constructor
|
* @constructor
|
||||||
* @fires ol.source.TileEvent
|
* @fires ol.source.Tile.Event
|
||||||
* @extends {ol.source.UrlTile}
|
* @extends {ol.source.UrlTile}
|
||||||
* @param {olx.source.TileImageOptions} options Image tile options.
|
* @param {olx.source.TileImageOptions} options Image tile options.
|
||||||
* @api
|
* @api
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ goog.require('ol');
|
|||||||
goog.require('ol.Tile');
|
goog.require('ol.Tile');
|
||||||
goog.require('ol.TileUrlFunction');
|
goog.require('ol.TileUrlFunction');
|
||||||
goog.require('ol.source.Tile');
|
goog.require('ol.source.Tile');
|
||||||
goog.require('ol.source.TileEvent');
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -12,7 +11,7 @@ goog.require('ol.source.TileEvent');
|
|||||||
* Base class for sources providing tiles divided into a tile grid over http.
|
* Base class for sources providing tiles divided into a tile grid over http.
|
||||||
*
|
*
|
||||||
* @constructor
|
* @constructor
|
||||||
* @fires ol.source.TileEvent
|
* @fires ol.source.Tile.Event
|
||||||
* @extends {ol.source.Tile}
|
* @extends {ol.source.Tile}
|
||||||
* @param {ol.SourceUrlTileOptions} options Image tile options.
|
* @param {ol.SourceUrlTileOptions} options Image tile options.
|
||||||
*/
|
*/
|
||||||
@@ -112,15 +111,15 @@ ol.source.UrlTile.prototype.handleTileChange = function(event) {
|
|||||||
switch (tile.getState()) {
|
switch (tile.getState()) {
|
||||||
case ol.Tile.State.LOADING:
|
case ol.Tile.State.LOADING:
|
||||||
this.dispatchEvent(
|
this.dispatchEvent(
|
||||||
new ol.source.TileEvent(ol.source.TileEventType.TILELOADSTART, tile));
|
new ol.source.Tile.Event(ol.source.Tile.EventType.TILELOADSTART, tile));
|
||||||
break;
|
break;
|
||||||
case ol.Tile.State.LOADED:
|
case ol.Tile.State.LOADED:
|
||||||
this.dispatchEvent(
|
this.dispatchEvent(
|
||||||
new ol.source.TileEvent(ol.source.TileEventType.TILELOADEND, tile));
|
new ol.source.Tile.Event(ol.source.Tile.EventType.TILELOADEND, tile));
|
||||||
break;
|
break;
|
||||||
case ol.Tile.State.ERROR:
|
case ol.Tile.State.ERROR:
|
||||||
this.dispatchEvent(
|
this.dispatchEvent(
|
||||||
new ol.source.TileEvent(ol.source.TileEventType.TILELOADERROR, tile));
|
new ol.source.Tile.Event(ol.source.Tile.EventType.TILELOADERROR, tile));
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
// pass
|
// pass
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ goog.require('ol.source.UrlTile');
|
|||||||
* editing.
|
* editing.
|
||||||
*
|
*
|
||||||
* @constructor
|
* @constructor
|
||||||
* @fires ol.source.TileEvent
|
* @fires ol.source.Tile.Event
|
||||||
* @extends {ol.source.UrlTile}
|
* @extends {ol.source.UrlTile}
|
||||||
* @param {olx.source.VectorTileOptions} options Vector tile options.
|
* @param {olx.source.VectorTileOptions} options Vector tile options.
|
||||||
* @api
|
* @api
|
||||||
|
|||||||
Reference in New Issue
Block a user