2013-05-27 15:48:58 -04:00
|
|
|
/*
|
|
|
|
* Paper.js - The Swiss Army Knife of Vector Graphics Scripting.
|
|
|
|
* http://paperjs.org/
|
|
|
|
*
|
|
|
|
* Copyright (c) 2011 - 2013, Juerg Lehni & Jonathan Puckey
|
|
|
|
* http://lehni.org/ & http://jonathanpuckey.com/
|
|
|
|
*
|
|
|
|
* Distributed under the MIT license. See LICENSE file for details.
|
|
|
|
*
|
|
|
|
* All rights reserved.
|
|
|
|
*/
|
|
|
|
|
2013-06-27 06:58:14 -04:00
|
|
|
// First add Base and a couple of other objects that are not automatically
|
|
|
|
// exported to exports (Numerical, Key, etc), then inject all exports into
|
2013-06-24 07:40:07 -04:00
|
|
|
// PaperScope, and create the initial paper object, all in one statement:
|
2013-06-02 19:17:54 -04:00
|
|
|
paper = new (PaperScope.inject(Base.merge(Base.exports, {
|
2013-05-30 17:37:04 -04:00
|
|
|
// Mark fields as enumeralbe so PaperScope.inject can pick them up
|
|
|
|
enumerable: true,
|
|
|
|
Base: Base,
|
2013-06-24 07:40:07 -04:00
|
|
|
Numerical: Numerical,
|
|
|
|
DomElement: DomElement,
|
2013-06-27 06:58:14 -04:00
|
|
|
DomEvent: DomEvent,
|
|
|
|
Key: Key
|
2013-05-27 21:28:35 -04:00
|
|
|
})))();
|
2013-06-24 07:40:35 -04:00
|
|
|
|
|
|
|
// Support AMD (e.g. require.js)
|
|
|
|
if (typeof define === 'function' && define.amd)
|
|
|
|
define(paper);
|