diff --git a/src/objectliterals.jsdoc b/src/objectliterals.jsdoc index 0813116336..f286244ff9 100644 --- a/src/objectliterals.jsdoc +++ b/src/objectliterals.jsdoc @@ -616,6 +616,8 @@ * @property {number|undefined} maxZoom Optional max zoom level. The default is * 18. * @property {number|undefined} minZoom Unsupported (TODO: remove this). + * @property {ol.TileLoadFunctionType|undefined} tileLoadFunction Optional + * function to load a tile given a URL. * @property {ol.TileUrlFunctionType|undefined} tileUrlFunction Optional * function to get tile URL given a tile coordinate and the projection. * Required if url or urls are not provided. diff --git a/src/ol/source/xyzsource.js b/src/ol/source/xyzsource.js index 51e5f43080..f25339064b 100644 --- a/src/ol/source/xyzsource.js +++ b/src/ol/source/xyzsource.js @@ -31,6 +31,7 @@ ol.source.XYZ = function(options) { logo: options.logo, projection: projection, tileGrid: tileGrid, + tileLoadFunction: options.tileLoadFunction, tileUrlFunction: ol.TileUrlFunction.nullTileUrlFunction });