diff options
Diffstat (limited to 'js/stage')
-rwxr-xr-x | js/stage/stage.reel/stage.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/js/stage/stage.reel/stage.js b/js/stage/stage.reel/stage.js index a3903ac7..ad05f1cc 100755 --- a/js/stage/stage.reel/stage.js +++ b/js/stage/stage.reel/stage.js | |||
@@ -248,6 +248,7 @@ exports.Stage = Montage.create(Component, { | |||
248 | 248 | ||
249 | 249 | ||
250 | this.eventManager.addEventListener( "openDocument", this, false); | 250 | this.eventManager.addEventListener( "openDocument", this, false); |
251 | this.eventManager.addEventListener( "switchDocument", this, false); | ||
251 | this.eventManager.addEventListener( "enableStageMove", this, false); | 252 | this.eventManager.addEventListener( "enableStageMove", this, false); |
252 | this.eventManager.addEventListener( "disableStageMove", this, false); | 253 | this.eventManager.addEventListener( "disableStageMove", this, false); |
253 | 254 | ||
@@ -261,6 +262,18 @@ exports.Stage = Montage.create(Component, { | |||
261 | // Event details will contain the active document prior to opening a new one | 262 | // Event details will contain the active document prior to opening a new one |
262 | handleOpenDocument: { | 263 | handleOpenDocument: { |
263 | value: function(evt) { | 264 | value: function(evt) { |
265 | this._initFromDocument(evt); | ||
266 | } | ||
267 | }, | ||
268 | |||
269 | handleSwitchDocument: { | ||
270 | value: function(evt) { | ||
271 | this._initFromDocument(evt); | ||
272 | } | ||
273 | }, | ||
274 | |||
275 | _initFromDocument: { | ||
276 | value: function(evt) { | ||
264 | var designView = this.application.ninja.currentDocument.model.views.design; | 277 | var designView = this.application.ninja.currentDocument.model.views.design; |
265 | 278 | ||
266 | this.hideCanvas(false); | 279 | this.hideCanvas(false); |