Add opaque option to olx.source.OSMOptions
This commit is contained in:
@@ -4573,6 +4573,7 @@ olx.source.TileDebugOptions.prototype.wrapX;
|
||||
* @typedef {{attributions: (Array.<ol.Attribution>|undefined),
|
||||
* crossOrigin: (null|string|undefined),
|
||||
* maxZoom: (number|undefined),
|
||||
* opaque: (boolean|undefined),
|
||||
* reprojectionErrorThreshold: (number|undefined),
|
||||
* tileLoadFunction: (ol.TileLoadFunctionType|undefined),
|
||||
* url: (string|undefined),
|
||||
@@ -4612,6 +4613,14 @@ olx.source.OSMOptions.prototype.crossOrigin;
|
||||
olx.source.OSMOptions.prototype.maxZoom;
|
||||
|
||||
|
||||
/**
|
||||
* Whether the layer is opaque. Default is `true`.
|
||||
* @type {boolean|undefined}
|
||||
* @api
|
||||
*/
|
||||
olx.source.OSMOptions.prototype.opaque;
|
||||
|
||||
|
||||
/**
|
||||
* Maximum allowed reprojection error (in pixels). Default is `0.5`.
|
||||
* Higher values can increase reprojection performance, but decrease precision.
|
||||
|
||||
@@ -33,7 +33,7 @@ ol.source.OSM = function(opt_options) {
|
||||
goog.base(this, {
|
||||
attributions: attributions,
|
||||
crossOrigin: crossOrigin,
|
||||
opaque: true,
|
||||
opaque: options.opaque !== undefined ? options.opaque : true,
|
||||
maxZoom: options.maxZoom !== undefined ? options.maxZoom : 19,
|
||||
reprojectionErrorThreshold: options.reprojectionErrorThreshold,
|
||||
tileLoadFunction: options.tileLoadFunction,
|
||||
|
||||
Reference in New Issue
Block a user