aboutsummaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
Diffstat (limited to 'js')
-rwxr-xr-xjs/controllers/selection-controller.js2
-rwxr-xr-xjs/document/models/base.js11
-rwxr-xr-xjs/ninja.reel/ninja.html2
-rwxr-xr-xjs/ninja.reel/ninja.js1
4 files changed, 13 insertions, 3 deletions
diff --git a/js/controllers/selection-controller.js b/js/controllers/selection-controller.js
index 28c0f3d3..4bca0755 100755
--- a/js/controllers/selection-controller.js
+++ b/js/controllers/selection-controller.js
@@ -34,7 +34,7 @@ exports.SelectionController = Montage.create(Component, {
34 } 34 }
35 35
36 if(this._currentDocument && this._currentDocument.currentView === "design") { 36 if(this._currentDocument && this._currentDocument.currentView === "design") {
37 this._currentDocument.model.selection = this.application.ninja.selectedElements; 37 this._currentDocument.model._selection = this.application.ninja.selectedElements;
38 this._currentDocument.model.selectionContainer = this.application.ninja._currentSelectedContainer; 38 this._currentDocument.model.selectionContainer = this.application.ninja._currentSelectedContainer;
39 } 39 }
40 40
diff --git a/js/document/models/base.js b/js/document/models/base.js
index 886a4ef0..76a5e62b 100755
--- a/js/document/models/base.js
+++ b/js/document/models/base.js
@@ -62,9 +62,18 @@ exports.BaseDocumentModel = Montage.create(Component, {
62 }, 62 },
63 //////////////////////////////////////////////////////////////////// 63 ////////////////////////////////////////////////////////////////////
64 // 64 //
65 selection: { 65 _selection: {
66 value: [] 66 value: []
67 }, 67 },
68
69 selection: {
70 get: function() {
71 return this._selection;
72 },
73 set: function(value) {
74 this._selection = value;
75 }
76 },
68 //////////////////////////////////////////////////////////////////// 77 ////////////////////////////////////////////////////////////////////
69 // 78 //
70 fileTemplate: { 79 fileTemplate: {
diff --git a/js/ninja.reel/ninja.html b/js/ninja.reel/ninja.html
index 33c3080f..a98fca60 100755
--- a/js/ninja.reel/ninja.html
+++ b/js/ninja.reel/ninja.html
@@ -246,7 +246,7 @@
246 "element":{"#" : "breadCrumbComponent"} 246 "element":{"#" : "breadCrumbComponent"}
247 }, 247 },
248 "bindings" : { 248 "bindings" : {
249 "container": {"<<->": "@owner.currentSelectedContainer"}, 249 "container": {"<-": "@owner.currentSelectedContainer"},
250 "currentDocument": {"<-": "@documentList.selectedObjects.0"} 250 "currentDocument": {"<-": "@documentList.selectedObjects.0"}
251 } 251 }
252 }, 252 },
diff --git a/js/ninja.reel/ninja.js b/js/ninja.reel/ninja.js
index ac883923..a12270a0 100755
--- a/js/ninja.reel/ninja.js
+++ b/js/ninja.reel/ninja.js
@@ -292,6 +292,7 @@ exports.Ninja = Montage.create(Component, {
292 292
293 if(doc.currentView === "design") { 293 if(doc.currentView === "design") {
294 // TODO: Bind directly to the model of the document in components instead of this property 294 // TODO: Bind directly to the model of the document in components instead of this property
295 this._currentSelectedContainer = null;
295 this.currentSelectedContainer = doc.model.documentRoot; 296 this.currentSelectedContainer = doc.model.documentRoot;
296 } 297 }
297 } 298 }