updating jsdoc comments for accuracy

git-svn-id: http://svn.openlayers.org/trunk/openlayers@2039 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
euzuro
2006-12-13 13:15:29 +00:00
parent ba89ea595e
commit d5a7f1ef5c

View File

@@ -10,17 +10,20 @@
*/
OpenLayers.Marker.Box = OpenLayers.Class.create();
OpenLayers.Marker.Box.prototype = OpenLayers.Class.inherit( OpenLayers.Marker, {
/** @type OpenLayers.LonLat */
/** @type OpenLayers.Bounds */
bounds: null,
/** @type DOMElement */
div: null,
/**
* @constructor
*
* @param {OpenLayers.Icon} icon
* @param {OpenLayers.LonLat lonlat
*/
* @constructor
*
* @param {OpenLayers.Bounds} bounds
* @param {String} borderColor
* @param {int} borderWidth
*/
initialize: function(bounds, borderColor, borderWidth) {
this.bounds = bounds;
this.div = OpenLayers.Util.createDiv();
@@ -29,14 +32,20 @@ OpenLayers.Marker.Box.prototype = OpenLayers.Class.inherit( OpenLayers.Marker, {
this.setBorder(borderColor, borderWidth);
},
/** Allow the user to change the box's color and border width
*
* @param {String} color Default is "red"
* @param {int} width Default is 2
*/
setBorder: function (color, width) {
if (!color) color = "red";
if (!width) width = 2;
color = color || "red";
width = width || 2;
this.div.style.border = width + "px solid " + color;
},
/**
* @param {OpenLayers.Pixel} px
* @param {OpenLayers.Size} sz
*
* @return A new DOM Image with this marker<65>s icon set at the
* location passed-in