aboutsummaryrefslogtreecommitdiff
path: root/js/ninja.reel
diff options
context:
space:
mode:
Diffstat (limited to 'js/ninja.reel')
-rwxr-xr-xjs/ninja.reel/ninja.html4
-rwxr-xr-xjs/ninja.reel/ninja.js22
2 files changed, 4 insertions, 22 deletions
diff --git a/js/ninja.reel/ninja.html b/js/ninja.reel/ninja.html
index d9bebc36..031d68e9 100755
--- a/js/ninja.reel/ninja.html
+++ b/js/ninja.reel/ninja.html
@@ -278,7 +278,9 @@
278 "selectionController": { 278 "selectionController": {
279 "prototype": "js/controllers/selection-controller", 279 "prototype": "js/controllers/selection-controller",
280 "bindings" : { 280 "bindings" : {
281 "selectionContainer": {"<-": "@owner.currentSelectedContainer"} 281 "selectionContainer": {"<-": "@owner.currentSelectedContainer"},
282 "currentDocument": {"<-": "@documentList.selectedObjects.0"},
283 "selectedElements": {"<-": "@documentList.selectedObjects.0.model.selection"}
282 } 284 }
283 }, 285 },
284 286
diff --git a/js/ninja.reel/ninja.js b/js/ninja.reel/ninja.js
index 3c60bb41..4c1efff4 100755
--- a/js/ninja.reel/ninja.js
+++ b/js/ninja.reel/ninja.js
@@ -151,7 +151,6 @@ exports.Ninja = Montage.create(Component, {
151 } 151 }
152 }, 152 },
153 153
154
155 selectedElements: { 154 selectedElements: {
156 value: [] 155 value: []
157 }, 156 },
@@ -196,7 +195,6 @@ exports.Ninja = Montage.create(Component, {
196 195
197 this.eventManager.addEventListener("selectTool", this, false); 196 this.eventManager.addEventListener("selectTool", this, false);
198 this.eventManager.addEventListener("selectSubTool", this, false); 197 this.eventManager.addEventListener("selectSubTool", this, false);
199 this.eventManager.addEventListener("onSwitchDocument", this, false);
200 198
201 this.addPropertyChangeListener("appModel.livePreview", this.executeLivePreview, false); 199 this.addPropertyChangeListener("appModel.livePreview", this.executeLivePreview, false);
202 this.addPropertyChangeListener("appModel.chromePreview", this.executeChromePreview, false); 200 this.addPropertyChangeListener("appModel.chromePreview", this.executeChromePreview, false);
@@ -311,15 +309,9 @@ exports.Ninja = Montage.create(Component, {
311 this.currentSelectedContainer = doc.model.documentRoot; 309 this.currentSelectedContainer = doc.model.documentRoot;
312 } 310 }
313 311
314// if(this.currentDocument.model.documentRoot) {
315// this.currentSelectedContainer = this.currentDocument.model.documentRoot;
316// } else {
317// alert("The current document has not loaded yet");
318// return;
319// }
320 312
321// this.appModel.show3dGrid = this.currentDocument.draw3DGrid; 313// this.appModel.show3dGrid = this.currentDocument.draw3DGrid;
322// NJevent("openDocument"); 314
323 315
324 } 316 }
325 }, 317 },
@@ -332,18 +324,6 @@ exports.Ninja = Montage.create(Component, {
332 } 324 }
333 }, 325 },
334 326
335 handleOnSwitchDocument: {
336 value: function() {
337 this.currentDocument = this.documentController.activeDocument;
338
339 if(this.currentDocument.model.documentRoot) {
340 this._currentSelectedContainer = this.selectionController._selectionContainer = this.currentDocument.model.documentRoot;
341 }
342
343 NJevent("switchDocument");
344 }
345 },
346
347 executeLivePreview: { 327 executeLivePreview: {
348 value: function() { 328 value: function() {
349 var background, overflow, transitionStopRule; 329 var background, overflow, transitionStopRule;