Fix OpenLayers.Pixel and OpenLayers.Size apidoc

'px' parameter for OpenLayers.Pixel.offset and OpenLayers.Pixel.equals
can be either a Pixel or a simple javascript object.
'sz' parameter for OpenLayers.Size.equals can be either a Size or a
simple javascript object.
This commit is contained in:
Frederic Junod
2012-01-15 10:59:08 +01:00
parent a9aa6d031e
commit 4d0a53ab31
2 changed files with 6 additions and 4 deletions

View File

@@ -68,7 +68,8 @@ OpenLayers.Pixel = OpenLayers.Class({
* Determine whether one pixel is equivalent to another
*
* Parameters:
* px - {<OpenLayers.Pixel>}
* px - {<OpenLayers.Pixel>|Object} An OpenLayers.Pixel or an object with
* a 'x' and 'y' properties.
*
* Returns:
* {Boolean} The point passed in as parameter is equal to this. Note that
@@ -123,7 +124,8 @@ OpenLayers.Pixel = OpenLayers.Class({
* APIMethod: offset
*
* Parameters
* px - {<OpenLayers.Pixel>}
* px - {<OpenLayers.Pixel>|Object} An OpenLayers.Pixel or an object with
* a 'x' and 'y' properties.
*
* Returns:
* {<OpenLayers.Pixel>} A new Pixel with this pixel's x&y augmented by the

View File

@@ -69,12 +69,12 @@ OpenLayers.Size = OpenLayers.Class({
* Determine where this size is equal to another
*
* Parameters:
* sz - {<OpenLayers.Size>}
* sz - {<OpenLayers.Size>|Object} An OpenLayers.Size or an object with
* a 'w' and 'h' properties.
*
* Returns:
* {Boolean} The passed in size has the same h and w properties as this one.
* Note that if sz passed in is null, returns false.
*
*/
equals:function(sz) {
var equals = false;