aboutsummaryrefslogtreecommitdiff
path: root/js/components
diff options
context:
space:
mode:
authorJose Antonio Marquez Russo2012-07-23 23:05:06 -0700
committerJose Antonio Marquez Russo2012-07-23 23:05:06 -0700
commit2952c2465b9a66076344087f899c5c836ad15ad6 (patch)
tree34274616fd6e0964c9102dde2dd32f20d0cd0089 /js/components
parent5946ec8651547f846520add097850470a09df635 (diff)
downloadninja-2952c2465b9a66076344087f899c5c836ad15ad6.tar.gz
New: Adding method to display document in code view
Added method to parse in memory document in code view. This allows users to view current in memory document in code view while not saving the document or external files. Still need to handle naming of paths for files that require saving but are not saved (webGL and Montage libraries). Also, need to implement method to switch back from code view to design view, but will need Timeline fixes.
Diffstat (limited to 'js/components')
-rwxr-xr-xjs/components/layout/document-bar.reel/document-bar.js13
1 files changed, 12 insertions, 1 deletions
diff --git a/js/components/layout/document-bar.reel/document-bar.js b/js/components/layout/document-bar.reel/document-bar.js
index f5e61a18..77f05bc1 100755
--- a/js/components/layout/document-bar.reel/document-bar.js
+++ b/js/components/layout/document-bar.reel/document-bar.js
@@ -238,7 +238,18 @@ exports.DocumentBar = Montage.create(Component, {
238 iBtn.setAttribute('class', 'inactive'); 238 iBtn.setAttribute('class', 'inactive');
239 aBtn.removeAttribute('class'); 239 aBtn.removeAttribute('class');
240 //TODO: Add document parsing to reload view 240 //TODO: Add document parsing to reload view
241 this._currentDocument.reloadView(view, this.fileTemplate); 241 this._currentDocument.reloadView(view, this.fileTemplate, {
242 mode: 'html',
243 libs: this._currentDocument.model.libs,
244 file: this._currentDocument.model.file,
245 webgl: this._currentDocument.model.webGlHelper.glData,
246 styles: this._currentDocument.model.getStyleSheets(),
247 template: this._currentDocument.fileTemplate,
248 document: this._currentDocument.model.views.design.iframe.contentWindow.document,
249 head: this._currentDocument.model.views.design.iframe.contentWindow.document.head,
250 body: this._currentDocument.model.views.design.iframe.contentWindow.document.body,
251 mjsTemplateCreator: this._currentDocument.model.views.design.iframe.contentWindow.mjsTemplateCreator
252 });
242 } 253 }
243 } 254 }
244 }, 255 },