2013-05-27 12:48:58 -07: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 03:58:14 -07: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 04:40:07 -07:00
|
|
|
// PaperScope, and create the initial paper object, all in one statement:
|
2013-06-02 16:17:54 -07:00
|
|
|
paper = new (PaperScope.inject(Base.merge(Base.exports, {
|
2013-05-30 14:37:04 -07:00
|
|
|
// Mark fields as enumeralbe so PaperScope.inject can pick them up
|
|
|
|
enumerable: true,
|
|
|
|
Base: Base,
|
2013-06-24 04:40:07 -07:00
|
|
|
Numerical: Numerical,
|
|
|
|
DomElement: DomElement,
|
2013-06-27 03:58:14 -07:00
|
|
|
DomEvent: DomEvent,
|
|
|
|
Key: Key
|
2013-05-27 18:28:35 -07:00
|
|
|
})))();
|
2013-06-24 04:40:35 -07:00
|
|
|
|
|
|
|
// Support AMD (e.g. require.js)
|
|
|
|
if (typeof define === 'function' && define.amd)
|
|
|
|
define(paper);
|