mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-07-07 10:14:02 -04:00
Switch to #pathData for JSON serialization of Path and CompoundPath.
This commit is contained in:
parent
5fbc6e939d
commit
cef30f9dd1
5 changed files with 11 additions and 6 deletions
File diff suppressed because one or more lines are too long
|
@ -21,6 +21,9 @@
|
|||
*/
|
||||
var Group = this.Group = Item.extend(/** @lends Group# */{
|
||||
_type: 'group',
|
||||
_serializeFields: {
|
||||
children: []
|
||||
},
|
||||
|
||||
// DOCS: document new Group(item, item...);
|
||||
/**
|
||||
|
|
|
@ -39,7 +39,6 @@ var Item = this.Item = Base.extend(Callback, {
|
|||
// that can be ommited.
|
||||
_serializeFields: {
|
||||
name: null,
|
||||
children: [],
|
||||
matrix: new Matrix(),
|
||||
locked: false,
|
||||
visible: true,
|
||||
|
|
|
@ -22,6 +22,10 @@
|
|||
*/
|
||||
var CompoundPath = this.CompoundPath = PathItem.extend(/** @lends CompoundPath# */{
|
||||
_type: 'compoundpath',
|
||||
_serializeFields: {
|
||||
pathData: null
|
||||
},
|
||||
|
||||
/**
|
||||
* Creates a new compound path item and places it in the active layer.
|
||||
*
|
||||
|
|
|
@ -21,8 +21,7 @@
|
|||
var Path = this.Path = PathItem.extend(/** @lends Path# */{
|
||||
_type: 'path',
|
||||
_serializeFields: {
|
||||
segments: [],
|
||||
closed: false
|
||||
pathData: null
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue