mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-08-12 05:59:19 -04:00
Move and unify handling of Item#_set(props) to new Item#_initialize(), and add support for props.insert = false.
This commit is contained in:
parent
5e2654b490
commit
aa4d990c90
11 changed files with 44 additions and 46 deletions
src/project
|
@ -46,8 +46,9 @@ var Project = PaperScopeItem.extend(/** @lends Project# */{
|
|||
* Canvas element that should be wrapped in a newly created view.
|
||||
*/
|
||||
initialize: function Project(view) {
|
||||
// Activate straight away by passing true to base(), so paper.project is
|
||||
// set, as required by Layer and DoumentView constructors.
|
||||
// Activate straight away by passing true to PaperScopeItem constructor,
|
||||
// so paper.project is set, as required by Layer and DoumentView
|
||||
// constructors.
|
||||
PaperScopeItem.call(this, true);
|
||||
this.layers = [];
|
||||
this.symbols = [];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue