Rename ol.source.ImageSource to ol.source.Image
This commit is contained in:
@@ -5,7 +5,7 @@ goog.require('ol.Size');
|
||||
|
||||
|
||||
/**
|
||||
* @typedef {function(this:ol.source.ImageSource, ol.Extent, ol.Size,
|
||||
* @typedef {function(this:ol.source.Image, ol.Extent, ol.Size,
|
||||
* ol.Projection): (string|undefined)}
|
||||
*/
|
||||
ol.ImageUrlFunctionType;
|
||||
@@ -22,7 +22,7 @@ ol.ImageUrlFunction.createFromParamsFunction =
|
||||
function(baseUrl, params, paramsFunction) {
|
||||
return (
|
||||
/**
|
||||
* @this {ol.source.ImageSource}
|
||||
* @this {ol.source.Image}
|
||||
* @param {ol.Extent} extent Extent.
|
||||
* @param {ol.Size} size Size.
|
||||
* @param {ol.Projection} projection Projection.
|
||||
@@ -35,7 +35,7 @@ ol.ImageUrlFunction.createFromParamsFunction =
|
||||
|
||||
|
||||
/**
|
||||
* @this {ol.source.ImageSource}
|
||||
* @this {ol.source.Image}
|
||||
* @param {ol.Extent} extent Extent.
|
||||
* @param {ol.Size} size Size.
|
||||
* @return {string|undefined} Image URL.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
goog.provide('ol.layer.ImageLayer');
|
||||
|
||||
goog.require('ol.layer.Layer');
|
||||
goog.require('ol.source.ImageSource');
|
||||
goog.require('ol.source.Image');
|
||||
|
||||
|
||||
|
||||
@@ -17,8 +17,8 @@ goog.inherits(ol.layer.ImageLayer, ol.layer.Layer);
|
||||
|
||||
|
||||
/**
|
||||
* @return {ol.source.ImageSource} Single image source.
|
||||
* @return {ol.source.Image} Single image source.
|
||||
*/
|
||||
ol.layer.ImageLayer.prototype.getImageSource = function() {
|
||||
return /** @type {ol.source.ImageSource} */ (this.getSource());
|
||||
return /** @type {ol.source.Image} */ (this.getSource());
|
||||
};
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
goog.provide('ol.source.ImageSource');
|
||||
goog.provide('ol.source.Image');
|
||||
|
||||
goog.require('goog.array');
|
||||
goog.require('goog.asserts');
|
||||
@@ -23,16 +23,16 @@ goog.require('ol.source.Source');
|
||||
* imageUrlFunction: (ol.ImageUrlFunctionType|
|
||||
* undefined)}}
|
||||
*/
|
||||
ol.source.ImageSourceOptions;
|
||||
ol.source.ImageOptions;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
* @extends {ol.source.Source}
|
||||
* @param {ol.source.ImageSourceOptions} options Single image source options.
|
||||
* @param {ol.source.ImageOptions} options Single image source options.
|
||||
*/
|
||||
ol.source.ImageSource = function(options) {
|
||||
ol.source.Image = function(options) {
|
||||
|
||||
goog.base(this, {
|
||||
attributions: options.attributions,
|
||||
@@ -70,7 +70,7 @@ ol.source.ImageSource = function(options) {
|
||||
}, true));
|
||||
|
||||
};
|
||||
goog.inherits(ol.source.ImageSource, ol.source.Source);
|
||||
goog.inherits(ol.source.Image, ol.source.Source);
|
||||
|
||||
|
||||
/**
|
||||
@@ -81,7 +81,7 @@ goog.inherits(ol.source.ImageSource, ol.source.Source);
|
||||
* @param {ol.Projection} projection Projection.
|
||||
* @return {ol.Image} Single image.
|
||||
*/
|
||||
ol.source.ImageSource.prototype.createImage =
|
||||
ol.source.Image.prototype.createImage =
|
||||
function(extent, resolution, size, projection) {
|
||||
var image = null;
|
||||
var imageUrl = this.imageUrlFunction(extent, size, projection);
|
||||
@@ -99,7 +99,7 @@ ol.source.ImageSource.prototype.createImage =
|
||||
* @param {number} resolution Resolution.
|
||||
* @return {number} Resolution.
|
||||
*/
|
||||
ol.source.ImageSource.prototype.findNearestResolution =
|
||||
ol.source.Image.prototype.findNearestResolution =
|
||||
function(resolution) {
|
||||
if (!goog.isNull(this.resolutions_)) {
|
||||
var idx = ol.array.linearFindNearest(this.resolutions_, resolution, 0);
|
||||
@@ -115,4 +115,4 @@ ol.source.ImageSource.prototype.findNearestResolution =
|
||||
* @param {ol.Projection} projection Projection.
|
||||
* @return {ol.Image} Single image.
|
||||
*/
|
||||
ol.source.ImageSource.prototype.getImage = goog.abstractMethod;
|
||||
ol.source.Image.prototype.getImage = goog.abstractMethod;
|
||||
|
||||
@@ -5,14 +5,14 @@ goog.require('ol.Image');
|
||||
goog.require('ol.ImageUrlFunction');
|
||||
goog.require('ol.extent');
|
||||
goog.require('ol.source.FeatureInfoSource');
|
||||
goog.require('ol.source.ImageSource');
|
||||
goog.require('ol.source.Image');
|
||||
goog.require('ol.source.wms');
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
* @extends {ol.source.ImageSource}
|
||||
* @extends {ol.source.Image}
|
||||
* @implements {ol.source.FeatureInfoSource}
|
||||
* @param {ol.source.SingleImageWMSOptions} options Options.
|
||||
*/
|
||||
@@ -52,7 +52,7 @@ ol.source.SingleImageWMS = function(options) {
|
||||
options.ratio : 1.5;
|
||||
|
||||
};
|
||||
goog.inherits(ol.source.SingleImageWMS, ol.source.ImageSource);
|
||||
goog.inherits(ol.source.SingleImageWMS, ol.source.Image);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -4,13 +4,13 @@ goog.require('ol.Image');
|
||||
goog.require('ol.ImageUrlFunctionType');
|
||||
goog.require('ol.extent');
|
||||
goog.require('ol.proj');
|
||||
goog.require('ol.source.ImageSource');
|
||||
goog.require('ol.source.Image');
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
* @extends {ol.source.ImageSource}
|
||||
* @extends {ol.source.Image}
|
||||
* @param {ol.source.StaticImageOptions} options Static image options.
|
||||
*/
|
||||
ol.source.StaticImage = function(options) {
|
||||
@@ -40,7 +40,7 @@ ol.source.StaticImage = function(options) {
|
||||
imageExtent, imageResolution, imageSize, projection);
|
||||
|
||||
};
|
||||
goog.inherits(ol.source.StaticImage, ol.source.ImageSource);
|
||||
goog.inherits(ol.source.StaticImage, ol.source.Image);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user