Merge all changes from the naturaldocs sandbox. This brings all the work that
has been done in the NaturalDocs branch back to trunk. Thanks to everyone who helped out in making this happen. (I could list people, but the list would be long, and I'm already mentally on vacation.) git-svn-id: http://svn.openlayers.org/trunk/openlayers@3545 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -4,29 +4,53 @@
|
||||
|
||||
|
||||
/**
|
||||
* @class
|
||||
*
|
||||
* @requires OpenLayers/Layer/Grid.js
|
||||
*
|
||||
* Class: OpenLayers.Layer.KaMap
|
||||
*
|
||||
* Inherits:
|
||||
* - <OpenLayers.Layer.Grid>
|
||||
*/
|
||||
OpenLayers.Layer.KaMap = OpenLayers.Class.create();
|
||||
OpenLayers.Layer.KaMap.prototype =
|
||||
OpenLayers.Class.inherit( OpenLayers.Layer.Grid, {
|
||||
|
||||
/** KaMap Layer is always a base layer
|
||||
*
|
||||
* @type Boolean
|
||||
/**
|
||||
* APIProperty: isBaseLayer
|
||||
* {Boolean} KaMap Layer is always a base layer
|
||||
*/
|
||||
isBaseLayer: true,
|
||||
|
||||
|
||||
/**
|
||||
* APIProperty: units
|
||||
* {?}
|
||||
*/
|
||||
units: null,
|
||||
|
||||
/**
|
||||
* APIProperty: resolution
|
||||
* {Float}
|
||||
*/
|
||||
resolution: OpenLayers.DOTS_PER_INCH,
|
||||
|
||||
/**
|
||||
* Constant: DEFAULT_PARAMS
|
||||
* {Object}
|
||||
*/
|
||||
DEFAULT_PARAMS: {
|
||||
i: 'jpeg',
|
||||
map: ''
|
||||
},
|
||||
|
||||
/**
|
||||
* Constructor: OpenLayers.Layer.KaMap
|
||||
*
|
||||
* Parameters:
|
||||
* name - {String}
|
||||
* url - {String}
|
||||
* params - {Object}
|
||||
* options - {Object}
|
||||
*/
|
||||
initialize: function(name, url, params, options) {
|
||||
var newArguments = new Array();
|
||||
newArguments.push(name, url, params, options);
|
||||
@@ -41,12 +65,15 @@ OpenLayers.Layer.KaMap.prototype =
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {OpenLayers.Bounds} bounds
|
||||
* Method: getURL
|
||||
*
|
||||
* @returns A string with the layer's url and parameters and also the
|
||||
* passed-in bounds and appropriate tile size specified as
|
||||
* parameters
|
||||
* @type String
|
||||
* Parameters:
|
||||
* bounds - {<OpenLayers.Bounds>}
|
||||
*
|
||||
* Return:
|
||||
* {String} A string with the layer's url and parameters and also the
|
||||
* passed-in bounds and appropriate tile size specified as
|
||||
* parameters
|
||||
*/
|
||||
getURL: function (bounds) {
|
||||
bounds = this.adjustBounds(bounds);
|
||||
@@ -60,13 +87,26 @@ OpenLayers.Layer.KaMap.prototype =
|
||||
s: scale
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Method: addTile
|
||||
*
|
||||
* Parameters:
|
||||
* bounds - {<OpenLayers.Bounds>}
|
||||
* position - {<OpenLayers.Pixel>}
|
||||
*
|
||||
* Return:
|
||||
* {<OpenLayers.Tile.Image>}
|
||||
*/
|
||||
addTile:function(bounds,position) {
|
||||
var url = this.getURL(bounds);
|
||||
return new OpenLayers.Tile.Image(this, position, bounds,
|
||||
url, this.tileSize);
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Method: _initTiles
|
||||
*/
|
||||
_initTiles:function() {
|
||||
|
||||
var viewSize = this.map.getSize();
|
||||
@@ -148,10 +188,13 @@ OpenLayers.Layer.KaMap.prototype =
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {Object} obj
|
||||
* APIMethod: clone
|
||||
*
|
||||
* @returns An exact clone of this OpenLayers.Layer.Grid
|
||||
* @type OpenLayers.Layer.Grid
|
||||
* Parameters:
|
||||
* obj - {Object}
|
||||
*
|
||||
* Return:
|
||||
* {<OpenLayers.Layer.Kamap>} An exact clone of this OpenLayers.Layer.KaMap
|
||||
*/
|
||||
clone: function (obj) {
|
||||
|
||||
@@ -176,7 +219,6 @@ OpenLayers.Layer.KaMap.prototype =
|
||||
return obj;
|
||||
},
|
||||
|
||||
|
||||
/** @final @type String */
|
||||
CLASS_NAME: "OpenLayers.Layer.KaMap"
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user