mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-04 03:45:58 -05:00
Merge pull request #916 from sapics/group-draw
Remove unused variable in group._draw
This commit is contained in:
commit
381d015f98
1 changed files with 6 additions and 9 deletions
|
@ -169,8 +169,7 @@ var Group = Item.extend(/** @lends Group# */{
|
||||||
|
|
||||||
_draw: function(ctx, param) {
|
_draw: function(ctx, param) {
|
||||||
var clip = param.clip,
|
var clip = param.clip,
|
||||||
clipItem = !clip && this._getClipItem(),
|
clipItem = !clip && this._getClipItem();
|
||||||
draw = true;
|
|
||||||
param = param.extend({ clipItem: clipItem, clip: false });
|
param = param.extend({ clipItem: clipItem, clip: false });
|
||||||
if (clip) {
|
if (clip) {
|
||||||
// If told to clip with a group, we start our own path and draw each
|
// If told to clip with a group, we start our own path and draw each
|
||||||
|
@ -180,13 +179,11 @@ var Group = Item.extend(/** @lends Group# */{
|
||||||
} else if (clipItem) {
|
} else if (clipItem) {
|
||||||
clipItem.draw(ctx, param.extend({ clip: true }));
|
clipItem.draw(ctx, param.extend({ clip: true }));
|
||||||
}
|
}
|
||||||
if (draw) {
|
var children = this._children;
|
||||||
var children = this._children;
|
for (var i = 0, l = children.length; i < l; i++) {
|
||||||
for (var i = 0, l = children.length; i < l; i++) {
|
var item = children[i];
|
||||||
var item = children[i];
|
if (item !== clipItem)
|
||||||
if (item !== clipItem)
|
item.draw(ctx, param);
|
||||||
item.draw(ctx, param);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue