Improve docs of Point#equals and Rectangle#equals.

This commit is contained in:
Jonathan Puckey 2011-05-29 14:20:15 +02:00
parent f75570078a
commit 556c927448
2 changed files with 6 additions and 4 deletions

View file

@ -558,7 +558,7 @@ var Point = this.Point = Base.extend({
* console.log(point != new Point(1, 1)); // true
*
* @param {Point} point
* @return {boolean}
* @return {boolean} {@true if the points are equal}
*/
equals: function(point) {
point = Point.read(arguments);

View file

@ -28,7 +28,7 @@ var Rectangle = this.Rectangle = Base.extend({
*
* @class A Rectangle specifies an area that is enclosed by it's top-left
* point (x, y), its width, and its height. It should not be confused with a
* rectangular path ({@link Path.Rectangle(point,size)}), it is not an item.
* rectangular path, it is not an item.
*/
/**
* Creates a rectangle object.
@ -347,10 +347,12 @@ var Rectangle = this.Rectangle = Base.extend({
* @type Point
*/
// DOCS: Rectangle#equals
/**
* Checks whether the coordinates and size of the rectangle are equal to
* that of the supplied rectangle.
*
* @param {Rectangle} rect
* @return {boolean}
* @return {boolean} {@true if the rectangles are equal}
*/
equals: function(rect) {
rect = Rectangle.read(arguments);