Add equals to Rectangle
This commit is contained in:
@@ -41,6 +41,16 @@ ol.Rectangle = function(minX, minY, maxX, maxY) {
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {ol.Rectangle} rectangle Rectangle.
|
||||
* @return {boolean} Equals.
|
||||
*/
|
||||
ol.Rectangle.prototype.equals = function(rectangle) {
|
||||
return this.minX == rectangle.minX && this.minY == rectangle.minY &&
|
||||
this.maxX == rectangle.maxX && this.maxY == rectangle.maxY;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {ol.Rectangle} rectangle Rectangle.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user