mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-01 02:38:43 -05:00
Fix issue with local paper variable shielding global one.
We need a cleaner fix for this on the long run.
This commit is contained in:
parent
d76d573eb2
commit
178b09caa7
2 changed files with 2 additions and 2 deletions
|
@ -27,7 +27,7 @@ var PaperScopeItem = Base.extend(Callback, /** @lends PaperScopeItem# */{
|
|||
initialize: function(activate) {
|
||||
// Store reference to the currently active global paper scope:
|
||||
this._scope = paper;
|
||||
// Push it onto this._scope.projects and set index:
|
||||
// Push it onto this._scope[this._list] and set _index:
|
||||
this._index = this._scope[this._list].push(this) - 1;
|
||||
// If the project has no active reference, activate this one
|
||||
if (activate || !this._scope[this._reference])
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
// Add PaperScript and Numerical to exports, inject all exports into PaperScope,
|
||||
// and create the initial paper object, all in one condensed statement:
|
||||
var paper = new (PaperScope.inject(Base.exports.inject({
|
||||
paper = new (PaperScope.inject(Base.exports.inject({
|
||||
PaperScript: PaperScript,
|
||||
Numerical: Numerical
|
||||
})))();
|
||||
|
|
Loading…
Reference in a new issue