diff options
author | Valerio Virgillito | 2012-05-30 17:45:38 -0700 |
---|---|---|
committer | Valerio Virgillito | 2012-05-30 17:45:38 -0700 |
commit | 0a769756547acb93346d8e1b4126931a78845255 (patch) | |
tree | c901c0522eb74eb56250d5df591ac14432e76aed /js/ninja.reel | |
parent | cbb888376282c7f6a5151478956b037e71d3b027 (diff) | |
download | ninja-0a769756547acb93346d8e1b4126931a78845255.tar.gz |
opening code view documents
Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'js/ninja.reel')
-rwxr-xr-x | js/ninja.reel/ninja.html | 5 | ||||
-rwxr-xr-x | js/ninja.reel/ninja.js | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/js/ninja.reel/ninja.html b/js/ninja.reel/ninja.html index ab4eed84..d9bebc36 100755 --- a/js/ninja.reel/ninja.html +++ b/js/ninja.reel/ninja.html | |||
@@ -345,7 +345,10 @@ | |||
345 | }, | 345 | }, |
346 | 346 | ||
347 | "codeEditorController": { | 347 | "codeEditorController": { |
348 | "prototype": "js/controllers/code-editor-controller" | 348 | "prototype": "js/controllers/code-editor-controller", |
349 | "bindings": { | ||
350 | "currentDocument": {"<-": "@documentList.selectedObjects.0"} | ||
351 | } | ||
349 | }, | 352 | }, |
350 | 353 | ||
351 | "owner": { | 354 | "owner": { |
diff --git a/js/ninja.reel/ninja.js b/js/ninja.reel/ninja.js index 987c32fd..3c60bb41 100755 --- a/js/ninja.reel/ninja.js +++ b/js/ninja.reel/ninja.js | |||
@@ -306,8 +306,10 @@ exports.Ninja = Montage.create(Component, { | |||
306 | // TODO: Remove this when integrating the next montage | 306 | // TODO: Remove this when integrating the next montage |
307 | this.documentList.selectedObjects = [doc]; | 307 | this.documentList.selectedObjects = [doc]; |
308 | 308 | ||
309 | // TODO: Bind directly to the model of the document in components instead of this property | 309 | if(doc.currentView === "design") { |
310 | this.currentSelectedContainer = doc.model.documentRoot; | 310 | // TODO: Bind directly to the model of the document in components instead of this property |
311 | this.currentSelectedContainer = doc.model.documentRoot; | ||
312 | } | ||
311 | 313 | ||
312 | // if(this.currentDocument.model.documentRoot) { | 314 | // if(this.currentDocument.model.documentRoot) { |
313 | // this.currentSelectedContainer = this.currentDocument.model.documentRoot; | 315 | // this.currentSelectedContainer = this.currentDocument.model.documentRoot; |