OpenStreetMap to OSM renaming

OSM is a well-known name, and is shorter than OpenStreetMap.
This commit is contained in:
Éric Lemoine
2013-04-10 10:07:49 +02:00
parent ee987bc951
commit a694661793
17 changed files with 41 additions and 41 deletions

View File

@@ -224,7 +224,7 @@
*/
/**
* @typedef {Object} ol.source.OpenStreetMapOptions
* @typedef {Object} ol.source.OSMOptions
* @property {ol.Attribution|undefined} attribution Attribution.
* @property {Array.<ol.Attribution>|undefined} attributions Attributions.
* @property {number|undefined} maxZoom Max zoom.

View File

@@ -2,7 +2,7 @@ goog.provide('ol.source.MapQuestOSM');
goog.provide('ol.source.MapQuestOpenAerial');
goog.require('ol.Attribution');
goog.require('ol.source.OpenStreetMap');
goog.require('ol.source.OSM');
goog.require('ol.source.XYZ');
@@ -17,7 +17,7 @@ ol.source.MapQuestOSM = function() {
new ol.Attribution(
'Tiles Courtesy of ' +
'<a href="http://www.mapquest.com/" target="_blank">MapQuest</a>'),
ol.source.OpenStreetMap.DATA_ATTRIBUTION
ol.source.OSM.DATA_ATTRIBUTION
];
goog.base(this, {

View File

@@ -1,3 +0,0 @@
@exportSymbol ol.source.OpenStreetMap
@exportProperty ol.source.OpenStreetMap.DATA_ATTRIBUTION
@exportProperty ol.source.OpenStreetMap.TILE_ATTRIBUTION

View File

@@ -0,0 +1,3 @@
@exportSymbol ol.source.OSM
@exportProperty ol.source.OSM.DATA_ATTRIBUTION
@exportProperty ol.source.OSM.TILE_ATTRIBUTION

View File

@@ -1,4 +1,4 @@
goog.provide('ol.source.OpenStreetMap');
goog.provide('ol.source.OSM');
goog.require('ol.Attribution');
goog.require('ol.source.XYZ');
@@ -8,9 +8,9 @@ goog.require('ol.source.XYZ');
/**
* @constructor
* @extends {ol.source.XYZ}
* @param {ol.source.OpenStreetMapOptions=} opt_options Open Street Map options.
* @param {ol.source.OSMOptions=} opt_options Open Street Map options.
*/
ol.source.OpenStreetMap = function(opt_options) {
ol.source.OSM = function(opt_options) {
var options = goog.isDef(opt_options) ? opt_options : {};
@@ -20,7 +20,7 @@ ol.source.OpenStreetMap = function(opt_options) {
} else if (goog.isDef(options.attribution)) {
attributions = [options.attribution];
} else {
attributions = ol.source.OpenStreetMap.ATTRIBUTIONS;
attributions = ol.source.OSM.ATTRIBUTIONS;
}
var maxZoom = goog.isDef(options.maxZoom) ? options.maxZoom : 18;
@@ -37,14 +37,14 @@ ol.source.OpenStreetMap = function(opt_options) {
});
};
goog.inherits(ol.source.OpenStreetMap, ol.source.XYZ);
goog.inherits(ol.source.OSM, ol.source.XYZ);
/**
* @const
* @type {ol.Attribution}
*/
ol.source.OpenStreetMap.DATA_ATTRIBUTION = new ol.Attribution(
ol.source.OSM.DATA_ATTRIBUTION = new ol.Attribution(
'Data &copy; <a href="http://www.openstreetmap.org/">OpenStreetMap</a> ' +
'contributors, ' +
'<a href="http://www.openstreetmap.org/copyright">ODbL</a>');
@@ -54,7 +54,7 @@ ol.source.OpenStreetMap.DATA_ATTRIBUTION = new ol.Attribution(
* @const
* @type {ol.Attribution}
*/
ol.source.OpenStreetMap.TILE_ATTRIBUTION = new ol.Attribution(
ol.source.OSM.TILE_ATTRIBUTION = new ol.Attribution(
'Tiles &copy; ' +
'<a href="http://www.openstreetmap.org/">OpenStreetMap</a> ' +
'contributors, ' +
@@ -65,7 +65,7 @@ ol.source.OpenStreetMap.TILE_ATTRIBUTION = new ol.Attribution(
* @const
* @type {Array.<ol.Attribution>}
*/
ol.source.OpenStreetMap.ATTRIBUTIONS = [
ol.source.OpenStreetMap.TILE_ATTRIBUTION,
ol.source.OpenStreetMap.DATA_ATTRIBUTION
ol.source.OSM.ATTRIBUTIONS = [
ol.source.OSM.TILE_ATTRIBUTION,
ol.source.OSM.DATA_ATTRIBUTION
];

View File

@@ -2,7 +2,7 @@ goog.provide('ol.source.Stamen');
goog.require('goog.asserts');
goog.require('ol.Attribution');
goog.require('ol.source.OpenStreetMap');
goog.require('ol.source.OSM');
goog.require('ol.source.XYZ');
@@ -83,7 +83,7 @@ ol.source.STAMEN_ATTRIBUTIONS = [
new ol.Attribution(
'Map tiles by <a href="http://stamen.com/">Stamen Design</a>, under ' +
'<a href="http://creativecommons.org/licenses/by/3.0/">CC BY 3.0</a>.'),
ol.source.OpenStreetMap.DATA_ATTRIBUTION
ol.source.OSM.DATA_ATTRIBUTION
];