aboutsummaryrefslogtreecommitdiff
path: root/js/controllers
diff options
context:
space:
mode:
authorValerio Virgillito2012-05-16 23:19:32 -0700
committerValerio Virgillito2012-05-16 23:19:32 -0700
commit402a369c7bf164c3c6686be3a33f5e36f25e4130 (patch)
tree96550b64edc3d6b4fc63c40b957fb1ff5ff3babe /js/controllers
parentc26de5fa7b909a53b103b72027b5cbe7c3e1c49f (diff)
downloadninja-402a369c7bf164c3c6686be3a33f5e36f25e4130.tar.gz
document controller and stage view code cleanup
Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'js/controllers')
-rwxr-xr-xjs/controllers/document-controller.js33
1 files changed, 16 insertions, 17 deletions
diff --git a/js/controllers/document-controller.js b/js/controllers/document-controller.js
index 1796f9b5..cf46e73e 100755
--- a/js/controllers/document-controller.js
+++ b/js/controllers/document-controller.js
@@ -458,8 +458,10 @@ var DocumentController = exports.DocumentController = Montage.create(Component,
458 if(this.activeDocument) { 458 if(this.activeDocument) {
459 // There is a document currently opened 459 // There is a document currently opened
460 460
461// this.application.ninja.stage.stageView.showCodeViewBar(false); 461
462// this.application.ninja.stage.stageView.restoreAllPanels(); 462
463 //this.application.ninja.stage.stageView.showCodeViewBar(false);
464 //this.application.ninja.stage.stageView.restoreAllPanels();
463 465
464 // 466 //
465 /* 467 /*
@@ -472,6 +474,18 @@ var DocumentController = exports.DocumentController = Montage.create(Component,
472 474
473 this.activeDocument.container.style["display"] = "none"; 475 this.activeDocument.container.style["display"] = "none";
474 */ 476 */
477
478 /*
479 this.activeDocument.container.style["display"] = "block";
480 if(this.activeDocument.currentView === "design"){
481 this.activeDocument.container.parentNode.style["display"] = "block";
482 this.activeDocument.restoreAppState();
483 }else{
484 //hide the iframe when switching to code view
485 document.getElementById("iframeContainer").style.display = "none";
486 }
487
488 */
475 // hide current document 489 // hide current document
476 } else { 490 } else {
477 // There is no document opened 491 // There is no document opened
@@ -564,21 +578,6 @@ var DocumentController = exports.DocumentController = Montage.create(Component,
564 } 578 }
565 }, 579 },
566 580
567 _showCurrentDocument: {
568 value: function() {
569 if(this.activeDocument) {
570 this.activeDocument.container.style["display"] = "block";
571 if(this.activeDocument.currentView === "design"){
572 this.activeDocument.container.parentNode.style["display"] = "block";
573 this.activeDocument.restoreAppState();
574 }else{
575 //hide the iframe when switching to code view
576 document.getElementById("iframeContainer").style.display = "none";
577 }
578 }
579 }
580 },
581
582 handleStyleSheetDirty:{ 581 handleStyleSheetDirty:{
583 value:function(){ 582 value:function(){
584 if(!this._hackInitialStyles) { 583 if(!this._hackInitialStyles) {