diff options
author | Valerio Virgillito | 2012-07-24 16:56:52 -0700 |
---|---|---|
committer | Valerio Virgillito | 2012-07-24 16:56:52 -0700 |
commit | 8f4a3e260622cd51dfa93b8dfd765f764c80fa6b (patch) | |
tree | 7f5004c61a3486cc0f547cf1e2d3d11183a1e36e /js/document/views | |
parent | 5454cc462903c83a8c3651065b03cc1855db125e (diff) | |
download | ninja-8f4a3e260622cd51dfa93b8dfd765f764c80fa6b.tar.gz |
adding a viewIdentifier to the model to enable design/code switch
Todo:
- Cleanup and remove listeners
- Finish stage reload
- Add remaining bindings.
Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'js/document/views')
-rwxr-xr-x | js/document/views/code.js | 4 | ||||
-rw-r--r-- | js/document/views/design-code.js | 27 | ||||
-rwxr-xr-x | js/document/views/design.js | 4 |
3 files changed, 6 insertions, 29 deletions
diff --git a/js/document/views/code.js b/js/document/views/code.js index 05f671b2..0ca87fa9 100755 --- a/js/document/views/code.js +++ b/js/document/views/code.js | |||
@@ -39,8 +39,8 @@ var Montage = require("montage/core/core").Montage, | |||
39 | exports.CodeDocumentView = Montage.create(BaseDocumentView, { | 39 | exports.CodeDocumentView = Montage.create(BaseDocumentView, { |
40 | //////////////////////////////////////////////////////////////////// | 40 | //////////////////////////////////////////////////////////////////// |
41 | // | 41 | // |
42 | hasTemplate: { | 42 | identifier: { |
43 | value: false | 43 | value: "code" |
44 | }, | 44 | }, |
45 | //////////////////////////////////////////////////////////////////// | 45 | //////////////////////////////////////////////////////////////////// |
46 | // | 46 | // |
diff --git a/js/document/views/design-code.js b/js/document/views/design-code.js index 25073833..44d12549 100644 --- a/js/document/views/design-code.js +++ b/js/document/views/design-code.js | |||
@@ -40,8 +40,8 @@ var Montage = require("montage/core/core").Montage, | |||
40 | exports.DesignCodeView = Montage.create(CodeDocumentView, { | 40 | exports.DesignCodeView = Montage.create(CodeDocumentView, { |
41 | //////////////////////////////////////////////////////////////////// | 41 | //////////////////////////////////////////////////////////////////// |
42 | // | 42 | // |
43 | hasTemplate: { | 43 | identifier: { |
44 | value: false | 44 | value: "design-code" |
45 | }, | 45 | }, |
46 | //////////////////////////////////////////////////////////////////// | 46 | //////////////////////////////////////////////////////////////////// |
47 | // | 47 | // |
@@ -75,22 +75,6 @@ exports.DesignCodeView = Montage.create(CodeDocumentView, { | |||
75 | this.textViewContainer.style.background = "white"; | 75 | this.textViewContainer.style.background = "white"; |
76 | this.textViewContainer.style.height = "100%"; | 76 | this.textViewContainer.style.height = "100%"; |
77 | 77 | ||
78 | |||
79 | ///todo-remove after the switch view logic is added in all the components | ||
80 | this.application.ninja.stage.collapseAllPanels(); | ||
81 | this.application.ninja.stage.hideCanvas(true); | ||
82 | this.application.ninja.stage.hideRulers(); | ||
83 | |||
84 | document.getElementsByClassName("bindingView")[0].style.display = "none"; | ||
85 | |||
86 | //bindingView div needs to be display noned | ||
87 | //timeline error on switching back to design view | ||
88 | |||
89 | ///-end todo-remove | ||
90 | |||
91 | |||
92 | |||
93 | |||
94 | //todo : update options bar | 78 | //todo : update options bar |
95 | 79 | ||
96 | // | 80 | // |
@@ -106,13 +90,6 @@ exports.DesignCodeView = Montage.create(CodeDocumentView, { | |||
106 | } | 90 | } |
107 | this.textViewContainer.style.display = "none"; | 91 | this.textViewContainer.style.display = "none"; |
108 | 92 | ||
109 | ///todo-remove after the switch view logic is added in all the components | ||
110 | this.application.ninja.stage.restoreAllPanels(false); | ||
111 | this.application.ninja.stage.hideCanvas(false); | ||
112 | this.application.ninja.stage.showRulers(); | ||
113 | ///-end todo-remove | ||
114 | |||
115 | |||
116 | //todo : update options bar | 93 | //todo : update options bar |
117 | 94 | ||
118 | // | 95 | // |
diff --git a/js/document/views/design.js b/js/document/views/design.js index 548e45e9..97558408 100755 --- a/js/document/views/design.js +++ b/js/document/views/design.js | |||
@@ -39,8 +39,8 @@ var Montage = require("montage/core/core").Montage, | |||
39 | exports.DesignDocumentView = Montage.create(BaseDocumentView, { | 39 | exports.DesignDocumentView = Montage.create(BaseDocumentView, { |
40 | //////////////////////////////////////////////////////////////////// | 40 | //////////////////////////////////////////////////////////////////// |
41 | // | 41 | // |
42 | hasTemplate: { | 42 | identifier: { |
43 | value: false | 43 | value: "design" |
44 | }, | 44 | }, |
45 | //////////////////////////////////////////////////////////////////// | 45 | //////////////////////////////////////////////////////////////////// |
46 | // | 46 | // |