mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-07 13:22:07 -05:00
Add expected parameters to function signature.
This commit is contained in:
parent
c4c4f51eb9
commit
54161f81f1
2 changed files with 3 additions and 3 deletions
|
@ -83,7 +83,7 @@ var CompoundPath = this.CompoundPath = PathItem.extend({
|
|||
}
|
||||
|
||||
var fields = {
|
||||
moveTo: function() {
|
||||
moveTo: function(point) {
|
||||
var path = new Path();
|
||||
this.appendTop(path);
|
||||
path.moveTo.apply(path, arguments);
|
||||
|
|
|
@ -762,14 +762,14 @@ var Path = this.Path = PathItem.extend({
|
|||
* execute a moveTo() command first.
|
||||
*/
|
||||
return {
|
||||
moveTo: function() {
|
||||
moveTo: function(point) {
|
||||
// Let's not be picky about calling moveTo() when not at the
|
||||
// beginning of a path, just bail out:
|
||||
if (!this._segments.length)
|
||||
this._add([ new Segment(Point.read(arguments)) ]);
|
||||
},
|
||||
|
||||
lineTo: function() {
|
||||
lineTo: function(point) {
|
||||
// Let's not be picky about calling moveTo() first:
|
||||
this._add([ new Segment(Point.read(arguments)) ]);
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue