diff options
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; |