Rename ol.projection to ol.proj
This commit is contained in:
@@ -9,7 +9,7 @@ goog.require('ol.Size');
|
||||
goog.require('ol.TileRange');
|
||||
goog.require('ol.TileUrlFunction');
|
||||
goog.require('ol.extent');
|
||||
goog.require('ol.projection');
|
||||
goog.require('ol.proj');
|
||||
goog.require('ol.source.ImageTileSource');
|
||||
goog.require('ol.tilegrid.XYZ');
|
||||
|
||||
@@ -25,7 +25,7 @@ ol.source.BingMaps = function(options) {
|
||||
goog.base(this, {
|
||||
crossOrigin: 'anonymous',
|
||||
opaque: true,
|
||||
projection: ol.projection.get('EPSG:3857')
|
||||
projection: ol.proj.get('EPSG:3857')
|
||||
});
|
||||
|
||||
/**
|
||||
@@ -95,7 +95,7 @@ ol.source.BingMaps.prototype.handleImageryMetadataResponse =
|
||||
* @return {string|undefined} Tile URL.
|
||||
*/
|
||||
function(tileCoord, projection) {
|
||||
goog.asserts.assert(ol.projection.equivalent(
|
||||
goog.asserts.assert(ol.proj.equivalent(
|
||||
projection, this.getProjection()));
|
||||
if (goog.isNull(tileCoord)) {
|
||||
return undefined;
|
||||
@@ -106,8 +106,8 @@ ol.source.BingMaps.prototype.handleImageryMetadataResponse =
|
||||
});
|
||||
})));
|
||||
|
||||
var transform = ol.projection.getTransformFromProjections(
|
||||
ol.projection.get('EPSG:4326'), this.getProjection());
|
||||
var transform = ol.proj.getTransformFromProjections(
|
||||
ol.proj.get('EPSG:4326'), this.getProjection());
|
||||
var attributions = goog.array.map(
|
||||
resource.imageryProviders,
|
||||
function(imageryProvider) {
|
||||
|
||||
@@ -5,7 +5,7 @@ goog.require('goog.events.EventType');
|
||||
goog.require('goog.functions');
|
||||
goog.require('ol.Attribution');
|
||||
goog.require('ol.Extent');
|
||||
goog.require('ol.projection');
|
||||
goog.require('ol.proj');
|
||||
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ ol.source.Source = function(options) {
|
||||
* @private
|
||||
* @type {ol.Projection}
|
||||
*/
|
||||
this.projection_ = ol.projection.get(options.projection);
|
||||
this.projection_ = ol.proj.get(options.projection);
|
||||
|
||||
/**
|
||||
* @private
|
||||
|
||||
@@ -3,7 +3,7 @@ goog.provide('ol.source.StaticImage');
|
||||
goog.require('ol.Image');
|
||||
goog.require('ol.ImageUrlFunctionType');
|
||||
goog.require('ol.extent');
|
||||
goog.require('ol.projection');
|
||||
goog.require('ol.proj');
|
||||
goog.require('ol.source.ImageSource');
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ ol.source.StaticImage = function(options) {
|
||||
var imageExtent = options.imageExtent;
|
||||
var imageSize = options.imageSize;
|
||||
var imageResolution = (imageExtent[3] - imageExtent[2]) / imageSize.height;
|
||||
var projection = ol.projection.get(options.projection);
|
||||
var projection = ol.proj.get(options.projection);
|
||||
|
||||
goog.base(this, {
|
||||
attributions: options.attributions,
|
||||
|
||||
@@ -14,7 +14,7 @@ goog.require('ol.Attribution');
|
||||
goog.require('ol.TileRange');
|
||||
goog.require('ol.TileUrlFunction');
|
||||
goog.require('ol.extent');
|
||||
goog.require('ol.projection');
|
||||
goog.require('ol.proj');
|
||||
goog.require('ol.source.ImageTileSource');
|
||||
goog.require('ol.tilegrid.XYZ');
|
||||
|
||||
@@ -45,7 +45,7 @@ ol.source.TileJSON = function(options) {
|
||||
|
||||
goog.base(this, {
|
||||
crossOrigin: options.crossOrigin,
|
||||
projection: ol.projection.get('EPSG:3857')
|
||||
projection: ol.proj.get('EPSG:3857')
|
||||
});
|
||||
|
||||
/**
|
||||
@@ -72,13 +72,13 @@ ol.source.TileJSON.prototype.handleTileJSONResponse = function() {
|
||||
|
||||
var tileJSON = ol.tilejson.grids_.pop();
|
||||
|
||||
var epsg4326Projection = ol.projection.get('EPSG:4326');
|
||||
var epsg4326Projection = ol.proj.get('EPSG:4326');
|
||||
|
||||
var extent;
|
||||
if (goog.isDef(tileJSON.bounds)) {
|
||||
var bounds = tileJSON.bounds;
|
||||
var epsg4326Extent = [bounds[0], bounds[2], bounds[1], bounds[3]];
|
||||
var transform = ol.projection.getTransformFromProjections(
|
||||
var transform = ol.proj.getTransformFromProjections(
|
||||
epsg4326Projection, this.getProjection());
|
||||
extent = ol.extent.transform(epsg4326Extent, transform);
|
||||
this.setExtent(extent);
|
||||
|
||||
@@ -10,7 +10,7 @@ goog.require('ol.TileCoord');
|
||||
goog.require('ol.TileUrlFunction');
|
||||
goog.require('ol.TileUrlFunctionType');
|
||||
goog.require('ol.extent');
|
||||
goog.require('ol.projection');
|
||||
goog.require('ol.proj');
|
||||
goog.require('ol.source.ImageTileSource');
|
||||
goog.require('ol.tilegrid.WMTS');
|
||||
|
||||
@@ -212,7 +212,7 @@ ol.source.WMTS.optionsFromCapabilities = function(wmtsCap, layer) {
|
||||
var tileGrid = ol.tilegrid.WMTS.createFromCapabilitiesMatrixSet(
|
||||
matrixSetObj);
|
||||
|
||||
var projection = ol.projection.get(matrixSetObj['supportedCRS']);
|
||||
var projection = ol.proj.get(matrixSetObj['supportedCRS']);
|
||||
|
||||
var gets = wmtsCap['operationsMetadata']['GetTile']['dcp']['http']['get'];
|
||||
var encodings = goog.object.getKeys(
|
||||
|
||||
@@ -5,7 +5,7 @@ goog.require('ol.Attribution');
|
||||
goog.require('ol.Projection');
|
||||
goog.require('ol.TileUrlFunction');
|
||||
goog.require('ol.TileUrlFunctionType');
|
||||
goog.require('ol.projection');
|
||||
goog.require('ol.proj');
|
||||
goog.require('ol.source.ImageTileSource');
|
||||
goog.require('ol.tilegrid.XYZ');
|
||||
|
||||
@@ -33,7 +33,7 @@ ol.source.XYZOptions;
|
||||
*/
|
||||
ol.source.XYZ = function(options) {
|
||||
|
||||
var projection = options.projection || ol.projection.get('EPSG:3857');
|
||||
var projection = options.projection || ol.proj.get('EPSG:3857');
|
||||
|
||||
/**
|
||||
* @type {ol.TileUrlFunctionType}
|
||||
|
||||
Reference in New Issue
Block a user