updated jsdocs

This commit is contained in:
Eric Rowell
2012-06-14 14:56:13 -07:00
parent 73ad904de6
commit 9a5f9006b8
3 changed files with 19 additions and 33 deletions

View File

@@ -27,28 +27,21 @@ Kinetic.Polygon = function(config) {
// call super constructor
Kinetic.Shape.apply(this, [config]);
};
/*
* Polygon methods
*/
Kinetic.Polygon.prototype = {
/**
* set points array
* @param {Array} points can be an array of point objects or an array
* of Numbers. e.g. [{x:1,y:2},{x:3,y:4}] or [1,2,3,4]
*/
setPoints: function(points) {
this.setAttrs({
points: points
});
}
};
// extend Shape
Kinetic.GlobalObject.extend(Kinetic.Polygon, Kinetic.Shape);
// add setters and getters
Kinetic.GlobalObject.addSetters(Kinetic.Polygon, ['points']);
Kinetic.GlobalObject.addGetters(Kinetic.Polygon, ['points']);
/**
* set points array
* @name setPoints
* @methodOf Kinetic.Polygon.prototype
* @param {Array} points can be an array of point objects or an array
* of Numbers. e.g. [{x:1,y:2},{x:3,y:4}] or [1,2,3,4]
*/
/**
* get points array
* @name getPoints