Prebuilt module for commit 6975690824

This commit is contained in:
Paper.js Bot 2016-02-15 23:08:48 +00:00
parent 913d182d0e
commit 9aff77ec34
5 changed files with 40 additions and 43 deletions

View file

@ -9,7 +9,7 @@
* *
* All rights reserved. * All rights reserved.
* *
* Date: Tue Feb 16 00:01:36 2016 +0100 * Date: Tue Feb 16 00:06:26 2016 +0100
* *
*** ***
* *
@ -13177,26 +13177,25 @@ new function() {
return exportShape(shape, options); return exportShape(shape, options);
} }
var segments = item._segments, var segments = item._segments,
length = segments.length,
type, type,
attrs = getTransform(item._matrix); attrs = getTransform(item._matrix);
if (segments.length === 0 && !item.isClipMask()) if (matchShapes && length >= 2 && !item.hasHandles()) {
return null; if (length > 2) {
if (matchShapes && !item.hasHandles()) {
if (segments.length >= 3) {
type = item._closed ? 'polygon' : 'polyline'; type = item._closed ? 'polygon' : 'polyline';
var parts = []; var parts = [];
for(var i = 0, l = segments.length; i < l; i++) for(var i = 0; i < length; i++)
parts.push(formatter.point(segments[i]._point)); parts.push(formatter.point(segments[i]._point));
attrs.points = parts.join(' '); attrs.points = parts.join(' ');
} else { } else {
type = 'line'; type = 'line';
var first = segments[0]._point, var start = segments[0]._point,
last = segments[segments.length - 1]._point; end = segments[1]._point;
attrs.set({ attrs.set({
x1: first.x, x1: start.x,
y1: first.y, y1: start.y,
x2: last.x, x2: end.x,
y2: last.y y2: end.y
}); });
} }
} else { } else {

23
dist/paper-core.js vendored
View file

@ -9,7 +9,7 @@
* *
* All rights reserved. * All rights reserved.
* *
* Date: Tue Feb 16 00:01:36 2016 +0100 * Date: Tue Feb 16 00:06:26 2016 +0100
* *
*** ***
* *
@ -13177,26 +13177,25 @@ new function() {
return exportShape(shape, options); return exportShape(shape, options);
} }
var segments = item._segments, var segments = item._segments,
length = segments.length,
type, type,
attrs = getTransform(item._matrix); attrs = getTransform(item._matrix);
if (segments.length === 0 && !item.isClipMask()) if (matchShapes && length >= 2 && !item.hasHandles()) {
return null; if (length > 2) {
if (matchShapes && !item.hasHandles()) {
if (segments.length >= 3) {
type = item._closed ? 'polygon' : 'polyline'; type = item._closed ? 'polygon' : 'polyline';
var parts = []; var parts = [];
for(var i = 0, l = segments.length; i < l; i++) for(var i = 0; i < length; i++)
parts.push(formatter.point(segments[i]._point)); parts.push(formatter.point(segments[i]._point));
attrs.points = parts.join(' '); attrs.points = parts.join(' ');
} else { } else {
type = 'line'; type = 'line';
var first = segments[0]._point, var start = segments[0]._point,
last = segments[segments.length - 1]._point; end = segments[1]._point;
attrs.set({ attrs.set({
x1: first.x, x1: start.x,
y1: first.y, y1: start.y,
x2: last.x, x2: end.x,
y2: last.y y2: end.y
}); });
} }
} else { } else {

File diff suppressed because one or more lines are too long

23
dist/paper-full.js vendored
View file

@ -9,7 +9,7 @@
* *
* All rights reserved. * All rights reserved.
* *
* Date: Tue Feb 16 00:01:36 2016 +0100 * Date: Tue Feb 16 00:06:26 2016 +0100
* *
*** ***
* *
@ -13177,26 +13177,25 @@ new function() {
return exportShape(shape, options); return exportShape(shape, options);
} }
var segments = item._segments, var segments = item._segments,
length = segments.length,
type, type,
attrs = getTransform(item._matrix); attrs = getTransform(item._matrix);
if (segments.length === 0 && !item.isClipMask()) if (matchShapes && length >= 2 && !item.hasHandles()) {
return null; if (length > 2) {
if (matchShapes && !item.hasHandles()) {
if (segments.length >= 3) {
type = item._closed ? 'polygon' : 'polyline'; type = item._closed ? 'polygon' : 'polyline';
var parts = []; var parts = [];
for(var i = 0, l = segments.length; i < l; i++) for(var i = 0; i < length; i++)
parts.push(formatter.point(segments[i]._point)); parts.push(formatter.point(segments[i]._point));
attrs.points = parts.join(' '); attrs.points = parts.join(' ');
} else { } else {
type = 'line'; type = 'line';
var first = segments[0]._point, var start = segments[0]._point,
last = segments[segments.length - 1]._point; end = segments[1]._point;
attrs.set({ attrs.set({
x1: first.x, x1: start.x,
y1: first.y, y1: start.y,
x2: last.x, x2: end.x,
y2: last.y y2: end.y
}); });
} }
} else { } else {

File diff suppressed because one or more lines are too long