mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-01 02:38:43 -05:00
Cleanup last merged pull request.
This commit is contained in:
parent
0d53b284e3
commit
7093b73d31
2 changed files with 4 additions and 5 deletions
|
@ -828,7 +828,6 @@ var Path = this.Path = PathItem.extend(/** @lends Path# */{
|
|||
var handleIn = segment._handleIn;
|
||||
segment._handleIn = segment._handleOut;
|
||||
segment._handleOut = handleIn;
|
||||
// Adjust index
|
||||
segment._index = i;
|
||||
}
|
||||
// Flip clockwise state if it's defined
|
||||
|
|
|
@ -265,12 +265,12 @@ test('Path#reverse', function() {
|
|||
equals(path.segments.toString(), '{ point: { x: 100, y: 130 }, handleIn: { x: -16.56854, y: 0 }, handleOut: { x: 16.56854, y: 0 } },{ point: { x: 130, y: 100 }, handleIn: { x: 0, y: 16.56854 }, handleOut: { x: 0, y: -16.56854 } },{ point: { x: 100, y: 70 }, handleIn: { x: 16.56854, y: 0 }, handleOut: { x: -16.56854, y: 0 } },{ point: { x: 70, y: 100 }, handleIn: { x: 0, y: -16.56854 }, handleOut: { x: 0, y: 16.56854 } }');
|
||||
});
|
||||
|
||||
test('#reverse should adjust segment indices', function() {
|
||||
test('Path#reverse should adjust segment indices', function() {
|
||||
var path = new Path([[0, 0], [10, 10], [20, 20]]);
|
||||
path.reverse();
|
||||
equals(path.segments[0]._index, 0);
|
||||
equals(path.segments[1]._index, 1);
|
||||
equals(path.segments[2]._index, 2);
|
||||
equals(path.segments[0].index, 0);
|
||||
equals(path.segments[1].index, 1);
|
||||
equals(path.segments[2].index, 2);
|
||||
});
|
||||
|
||||
test('Path#fullySelected', function() {
|
||||
|
|
Loading…
Reference in a new issue