Prebuilt module for commit c82e5d41f7

This commit is contained in:
Paper.js Bot 2019-12-14 18:43:59 +00:00
parent 60bd47c5ef
commit a604f09a99
8 changed files with 82 additions and 88 deletions

View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Fri Dec 13 18:36:07 2019 +0100
* Date: Sat Dec 14 19:40:00 2019 +0100
*
***
*
@ -2364,8 +2364,7 @@ var Matrix = Base.extend({
apply: function(recursively, _setApplyMatrix) {
var owner = this._owner;
if (owner) {
owner.transform(null, true, Base.pick(recursively, true),
_setApplyMatrix);
owner.transform(null, Base.pick(recursively, true), _setApplyMatrix);
return this.isIdentity();
}
return false;
@ -4470,13 +4469,16 @@ new function() {
return this.transform(mx.translate.apply(mx, arguments));
},
transform: function(matrix, _applyMatrix, _applyRecursively,
_setApplyMatrix) {
transform: function(matrix, _applyRecursively, _setApplyMatrix) {
var _matrix = this._matrix,
transformMatrix = matrix && !matrix.isIdentity(),
applyMatrix = (_applyMatrix || this._applyMatrix)
&& ((!_matrix.isIdentity() || transformMatrix)
|| _applyMatrix && _applyRecursively && this._children);
applyMatrix = (
_setApplyMatrix && this._canApplyMatrix ||
this._applyMatrix && (
transformMatrix || !_matrix.isIdentity() ||
_applyRecursively && this._children
)
);
if (!transformMatrix && !applyMatrix)
return this;
if (transformMatrix) {
@ -4491,16 +4493,15 @@ new function() {
if (strokeColor)
strokeColor.transform(matrix);
}
if (applyMatrix) {
if (applyMatrix && (applyMatrix = this._transformContent(
_matrix, _applyRecursively, _setApplyMatrix))) {
var pivot = this._pivot;
if (pivot)
_matrix._transformPoint(pivot, pivot, true);
_matrix.reset(true);
if (_setApplyMatrix && this._canApplyMatrix)
this._applyMatrix = true;
if (this._applyMatrix && (applyMatrix = this._transformContent(_matrix,
_applyRecursively, _setApplyMatrix))) {
var pivot = this._pivot;
if (pivot)
_matrix._transformPoint(pivot, pivot, true);
_matrix.reset(true);
}
}
var bounds = this._bounds,
position = this._position;
@ -4533,9 +4534,9 @@ new function() {
_transformContent: function(matrix, applyRecursively, setApplyMatrix) {
var children = this._children;
if (children) {
for (var i = 0, l = children.length; i < l; i++)
children[i].transform(matrix, true, applyRecursively,
setApplyMatrix);
for (var i = 0, l = children.length; i < l; i++) {
children[i].transform(matrix, applyRecursively, setApplyMatrix);
}
return true;
}
},

View file

@ -694,7 +694,7 @@ Array of <tt>Numbers</tt>
<li>
<tt>recursively:</tt>
<tt>Boolean</tt>
&mdash;&nbsp;controls whether to apply transformations recursively on children
&mdash;&nbsp;controls whether to apply transformations recursively on children
&mdash;&nbsp;optional, default: <tt>true</tt>
</li>

39
dist/paper-core.js vendored
View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Fri Dec 13 18:36:07 2019 +0100
* Date: Sat Dec 14 19:40:00 2019 +0100
*
***
*
@ -2361,8 +2361,7 @@ var Matrix = Base.extend({
apply: function(recursively, _setApplyMatrix) {
var owner = this._owner;
if (owner) {
owner.transform(null, true, Base.pick(recursively, true),
_setApplyMatrix);
owner.transform(null, Base.pick(recursively, true), _setApplyMatrix);
return this.isIdentity();
}
return false;
@ -4467,13 +4466,16 @@ new function() {
return this.transform(mx.translate.apply(mx, arguments));
},
transform: function(matrix, _applyMatrix, _applyRecursively,
_setApplyMatrix) {
transform: function(matrix, _applyRecursively, _setApplyMatrix) {
var _matrix = this._matrix,
transformMatrix = matrix && !matrix.isIdentity(),
applyMatrix = (_applyMatrix || this._applyMatrix)
&& ((!_matrix.isIdentity() || transformMatrix)
|| _applyMatrix && _applyRecursively && this._children);
applyMatrix = (
_setApplyMatrix && this._canApplyMatrix ||
this._applyMatrix && (
transformMatrix || !_matrix.isIdentity() ||
_applyRecursively && this._children
)
);
if (!transformMatrix && !applyMatrix)
return this;
if (transformMatrix) {
@ -4488,16 +4490,15 @@ new function() {
if (strokeColor)
strokeColor.transform(matrix);
}
if (applyMatrix) {
if (applyMatrix && (applyMatrix = this._transformContent(
_matrix, _applyRecursively, _setApplyMatrix))) {
var pivot = this._pivot;
if (pivot)
_matrix._transformPoint(pivot, pivot, true);
_matrix.reset(true);
if (_setApplyMatrix && this._canApplyMatrix)
this._applyMatrix = true;
if (this._applyMatrix && (applyMatrix = this._transformContent(_matrix,
_applyRecursively, _setApplyMatrix))) {
var pivot = this._pivot;
if (pivot)
_matrix._transformPoint(pivot, pivot, true);
_matrix.reset(true);
}
}
var bounds = this._bounds,
position = this._position;
@ -4530,9 +4531,9 @@ new function() {
_transformContent: function(matrix, applyRecursively, setApplyMatrix) {
var children = this._children;
if (children) {
for (var i = 0, l = children.length; i < l; i++)
children[i].transform(matrix, true, applyRecursively,
setApplyMatrix);
for (var i = 0, l = children.length; i < l; i++) {
children[i].transform(matrix, applyRecursively, setApplyMatrix);
}
return true;
}
},

File diff suppressed because one or more lines are too long

39
dist/paper-full.js vendored
View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Fri Dec 13 18:36:07 2019 +0100
* Date: Sat Dec 14 19:40:00 2019 +0100
*
***
*
@ -2364,8 +2364,7 @@ var Matrix = Base.extend({
apply: function(recursively, _setApplyMatrix) {
var owner = this._owner;
if (owner) {
owner.transform(null, true, Base.pick(recursively, true),
_setApplyMatrix);
owner.transform(null, Base.pick(recursively, true), _setApplyMatrix);
return this.isIdentity();
}
return false;
@ -4470,13 +4469,16 @@ new function() {
return this.transform(mx.translate.apply(mx, arguments));
},
transform: function(matrix, _applyMatrix, _applyRecursively,
_setApplyMatrix) {
transform: function(matrix, _applyRecursively, _setApplyMatrix) {
var _matrix = this._matrix,
transformMatrix = matrix && !matrix.isIdentity(),
applyMatrix = (_applyMatrix || this._applyMatrix)
&& ((!_matrix.isIdentity() || transformMatrix)
|| _applyMatrix && _applyRecursively && this._children);
applyMatrix = (
_setApplyMatrix && this._canApplyMatrix ||
this._applyMatrix && (
transformMatrix || !_matrix.isIdentity() ||
_applyRecursively && this._children
)
);
if (!transformMatrix && !applyMatrix)
return this;
if (transformMatrix) {
@ -4491,16 +4493,15 @@ new function() {
if (strokeColor)
strokeColor.transform(matrix);
}
if (applyMatrix) {
if (applyMatrix && (applyMatrix = this._transformContent(
_matrix, _applyRecursively, _setApplyMatrix))) {
var pivot = this._pivot;
if (pivot)
_matrix._transformPoint(pivot, pivot, true);
_matrix.reset(true);
if (_setApplyMatrix && this._canApplyMatrix)
this._applyMatrix = true;
if (this._applyMatrix && (applyMatrix = this._transformContent(_matrix,
_applyRecursively, _setApplyMatrix))) {
var pivot = this._pivot;
if (pivot)
_matrix._transformPoint(pivot, pivot, true);
_matrix.reset(true);
}
}
var bounds = this._bounds,
position = this._position;
@ -4533,9 +4534,9 @@ new function() {
_transformContent: function(matrix, applyRecursively, setApplyMatrix) {
var children = this._children;
if (children) {
for (var i = 0, l = children.length; i < l; i++)
children[i].transform(matrix, true, applyRecursively,
setApplyMatrix);
for (var i = 0, l = children.length; i < l; i++) {
children[i].transform(matrix, applyRecursively, setApplyMatrix);
}
return true;
}
},

File diff suppressed because one or more lines are too long

6
dist/paper.d.ts vendored
View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Fri Dec 13 18:36:07 2019 +0100
* Date: Sat Dec 14 19:40:00 2019 +0100
*
* This is an auto-generated type definition.
*/
@ -2901,8 +2901,8 @@ declare namespace paper {
* Attempts to apply the matrix to the content of item that it belongs to,
* meaning its transformation is baked into the item's content or children.
*
* @param recursively - controls whether to apply transformations
* recursively on children
* @param recursively - controls whether to apply
* transformations recursively on children
*
* @return true if the matrix was applied
*/

23
package-lock.json generated
View file

@ -363,12 +363,6 @@
"integrity": "sha1-bJ7csRztTw3S8tQNsNSaEJwIiqs=",
"dev": true
},
"async-limiter": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==",
"dev": true
},
"asynckit": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
@ -1692,9 +1686,9 @@
"dev": true
},
"fast-json-stable-stringify": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz",
"integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=",
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz",
"integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==",
"dev": true
},
"fast-levenshtein": {
@ -6573,13 +6567,10 @@
"dev": true
},
"ws": {
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.0.tgz",
"integrity": "sha512-+SqNqFbwTm/0DC18KYzIsMTnEWpLwJsiasW/O17la4iDRRIO9uaHbvKiAS3AHgTiuuWerK/brj4O6MYZkei9xg==",
"dev": true,
"requires": {
"async-limiter": "^1.0.0"
}
"version": "7.2.1",
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.1.tgz",
"integrity": "sha512-sucePNSafamSKoOqoNfBd8V0StlkzJKL2ZAhGQinCfNQ+oacw+Pk7lcdAElecBF2VkLNZRiIb5Oi1Q5lVUVt2A==",
"dev": true
},
"xml-name-validator": {
"version": "3.0.0",