aboutsummaryrefslogtreecommitdiff
path: root/js/controllers/document-controller.js
diff options
context:
space:
mode:
authorJose Antonio Marquez2012-05-24 11:38:51 -0700
committerJose Antonio Marquez2012-05-24 11:38:51 -0700
commite64328dc08418730ca580d33381cb2001c7a96fd (patch)
tree74e3996696adfea94158c29575e9393e56169930 /js/controllers/document-controller.js
parentd57cd68741f340a45be780675ed79b5caf2094e9 (diff)
parenta8eb5c65a21af3bf8d8b8eb3e65b494b8bd9bc01 (diff)
downloadninja-e64328dc08418730ca580d33381cb2001c7a96fd.tar.gz
Merge branch 'refs/heads/Ninja-DOM-Architecture' into Document
Conflicts: js/document/document-html.js js/helper-classes/3D/view-utils.js js/stage/stage.reel/stage.js
Diffstat (limited to 'js/controllers/document-controller.js')
-rwxr-xr-xjs/controllers/document-controller.js18
1 files changed, 10 insertions, 8 deletions
diff --git a/js/controllers/document-controller.js b/js/controllers/document-controller.js
index eecf9146..2c34eedf 100755
--- a/js/controllers/document-controller.js
+++ b/js/controllers/document-controller.js
@@ -377,10 +377,10 @@ exports.DocumentController = Montage.create(Component, {
377 377
378 if(this._documents.length > 0) { 378 if(this._documents.length > 0) {
379 previousFocusedDocument = this._documents[this._documents.length - 1]; 379 previousFocusedDocument = this._documents[this._documents.length - 1];
380 this._activeDocument = previousFocusedDocument; 380 this.activeDocument = previousFocusedDocument;
381 this.switchDocuments(this.activeDocument, previousFocusedDocument, true); 381 this.switchDocuments(this.activeDocument, previousFocusedDocument, false);
382 } else { 382 } else {
383 this._activeDocument = null; 383 this.activeDocument = null;
384 this.application.ninja.stage.hideRulers(); 384 this.application.ninja.stage.hideRulers();
385 385
386 this.application.ninja.stage.hideCanvas(true); 386 this.application.ninja.stage.hideCanvas(true);
@@ -502,14 +502,16 @@ exports.DocumentController = Montage.create(Component, {
502 this.application.ninja.stage.restoreAllPanels(); 502 this.application.ninja.stage.restoreAllPanels();
503 this.application.ninja.stage.hideCanvas(false); 503 this.application.ninja.stage.hideCanvas(false);
504 this.application.ninja.stage.showRulers(); 504 this.application.ninja.stage.showRulers();
505 } else if(currentDocument.currentView === "design" && newDocument.currentView === "code") {
506 this.application.ninja.stage.showCodeViewBar(true);
507 this.application.ninja.stage.collapseAllPanels();
508 this.application.ninja.stage.hideCanvas(true);
509 this.application.ninja.stage.hideRulers();
510 } 505 }
511 } 506 }
512 507
508 if(newDocument.currentView === "code") {
509 this.application.ninja.stage.showCodeViewBar(true);
510 this.application.ninja.stage.collapseAllPanels();
511 this.application.ninja.stage.hideCanvas(true);
512 this.application.ninja.stage.hideRulers();
513 }
514
513 this.application.ninja.stage.clearAllCanvas(); 515 this.application.ninja.stage.clearAllCanvas();
514 516
515 if(didCreate) { 517 if(didCreate) {