[openlayers] Add hidpi option and test for ImageArcGISRest source (#25348)

* Add hidpi option to ImageArcGISRestOptions

* Add tests for the ImageArcGISRest source
This commit is contained in:
Hauke Stieler
2018-04-27 23:27:48 -07:00
committed by Wesley Wigham
parent ab7694a033
commit e8e909253b
2 changed files with 19 additions and 0 deletions
+2
View File
@@ -8,6 +8,7 @@
// Dan Manastireanu <https://github.com/danmana>
// Yair Tawil <https://github.com/yairtawil>
// Pierre Marchand <https://github.com/pierremarc>
// Hauke Stieler <https://github.com/hauke96>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// Definitions partially generated using tsd-jsdoc (https://github.com/englercj/tsd-jsdoc)
@@ -12087,6 +12088,7 @@ export namespace olx {
interface ImageArcGISRestOptions {
attributions?: ol.Attribution[];
crossOrigin?: (string);
hidpi?: boolean;
logo?: (string | LogoOptions);
imageLoadFunction?: ol.ImageLoadFunctionType;
params?: { [k: string]: any };
+17
View File
@@ -718,6 +718,23 @@ const wmts: ol.source.WMTS = new ol.source.WMTS({
wrapX: true,
});
//
// ol.source.ImageArcGISRest
//
const arcGISImageLoadFunction: ol.ImageLoadFunctionType = (image, url) => {};
const imageArcGISRest: ol.source.ImageArcGISRest = new ol.source.ImageArcGISRest({
attributions: [attribution],
crossOrigin: stringValue,
hidpi: booleanValue,
logo: logoOptions,
imageLoadFunction: arcGISImageLoadFunction,
params: {},
projection: projectionLike,
ratio: numberValue,
resolutions: [numberValue, numberValue, numberValue, numberValue, numberValue],
url: stringValue
});
//
// ol.coordinate
//