aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xjs/ninja.reel/ninja.js2
-rwxr-xr-xjs/stage/binding-view.reel/binding-hud.reel/binding-hud.js17
-rwxr-xr-xjs/stage/binding-view.reel/binding-view.js8
-rw-r--r--js/tools/bindingTool.js2
4 files changed, 17 insertions, 12 deletions
diff --git a/js/ninja.reel/ninja.js b/js/ninja.reel/ninja.js
index 859268a0..9942300c 100755
--- a/js/ninja.reel/ninja.js
+++ b/js/ninja.reel/ninja.js
@@ -519,10 +519,12 @@ exports.Ninja = Montage.create(Component, {
519// background = "#000000"; 519// background = "#000000";
520// overflow = "hidden"; 520// overflow = "hidden";
521 transitionStopRule = "nj-css-garbage-selector"; 521 transitionStopRule = "nj-css-garbage-selector";
522 this.stage.bindingView.hide = true;
522 } else { 523 } else {
523// background = "#808080"; 524// background = "#808080";
524// overflow = "visible"; 525// overflow = "visible";
525 transitionStopRule = "*" 526 transitionStopRule = "*"
527 this.stage.bindingView.hide = false;
526 } 528 }
527 529
528 // TODO: Remove marker for old template: NINJA-STAGE-REWORK 530 // TODO: Remove marker for old template: NINJA-STAGE-REWORK
diff --git a/js/stage/binding-view.reel/binding-hud.reel/binding-hud.js b/js/stage/binding-view.reel/binding-hud.reel/binding-hud.js
index 0f1b99c9..6b802cb0 100755
--- a/js/stage/binding-view.reel/binding-hud.reel/binding-hud.js
+++ b/js/stage/binding-view.reel/binding-hud.reel/binding-hud.js
@@ -76,12 +76,7 @@ exports.BindingHud = Montage.create(Component, {
76 this.title = icon.name; 76 this.title = icon.name;
77 this.x = iconOffsets.x; 77 this.x = iconOffsets.x;
78 this.y = iconOffsets.y - 80; 78 this.y = iconOffsets.y - 80;
79 } else {
80 this.title = val.identifier;
81 this.x = val.element.offsetLeft;
82 this.y = val.element.offsetTop;
83 } 79 }
84
85 this.needsDraw = true; 80 this.needsDraw = true;
86 81
87 } 82 }
@@ -236,6 +231,12 @@ exports.BindingHud = Montage.create(Component, {
236 this.scrollUp.style.display = "block"; 231 this.scrollUp.style.display = "block";
237 this.scrollDown.style.display = "block"; 232 this.scrollDown.style.display = "block";
238 } 233 }
234 var isOffStage = this.application.ninja.objectsController.isOffStageObject(this.userComponent);
235 if(!isOffStage) {
236 this.title = this.userComponent.identifier;
237 this.x = this.userComponent.element.offsetLeft;
238 this.y = this.userComponent.element.offsetTop;
239 }
239 } 240 }
240 }, 241 },
241 242
@@ -323,6 +324,12 @@ exports.BindingHud = Montage.create(Component, {
323 } 324 }
324 }, 325 },
325 326
327 willDraw: {
328 value: function() {
329
330 }
331 },
332
326 draw: { 333 draw: {
327 value: function() { 334 value: function() {
328 this.titleElement.innerHTML = this.title; 335 this.titleElement.innerHTML = this.title;
diff --git a/js/stage/binding-view.reel/binding-view.js b/js/stage/binding-view.reel/binding-view.js
index 1fc4d583..94c84d02 100755
--- a/js/stage/binding-view.reel/binding-view.js
+++ b/js/stage/binding-view.reel/binding-view.js
@@ -198,7 +198,7 @@ exports.BindingView = Montage.create(Component, {
198 } 198 }
199 }, 199 },
200 200
201 _hide : { value: null }, 201 _hide : { value: true },
202 hide : { 202 hide : {
203 get : function() { return this._hide; }, 203 get : function() { return this._hide; },
204 set : function(value) { 204 set : function(value) {
@@ -247,12 +247,6 @@ exports.BindingView = Montage.create(Component, {
247 } 247 }
248 }, 248 },
249 249
250 didDraw: {
251 value: function() {
252
253 }
254 },
255
256 drawLine: { 250 drawLine: {
257 value: function(fromX,fromY,toX,toY, color, width) { 251 value: function(fromX,fromY,toX,toY, color, width) {
258 if(width === null) width = 1; 252 if(width === null) width = 1;
diff --git a/js/tools/bindingTool.js b/js/tools/bindingTool.js
index 1e1c9e5b..3f8e960f 100644
--- a/js/tools/bindingTool.js
+++ b/js/tools/bindingTool.js
@@ -33,6 +33,7 @@ exports.BindingTool = Montage.create(ModifierToolBase, {
33 { 33 {
34 NJevent("enableStageMove"); 34 NJevent("enableStageMove");
35 this.application.ninja.workspaceMode = "binding"; 35 this.application.ninja.workspaceMode = "binding";
36 this.application.ninja.stage.bindingView.hide = false;
36 if (this.application.ninja.selectedElements.length !== 0 ) { 37 if (this.application.ninja.selectedElements.length !== 0 ) {
37 if(typeof(this.application.ninja.selectedElements[0].controller) !== "undefined") { 38 if(typeof(this.application.ninja.selectedElements[0].controller) !== "undefined") {
38 this.selectedComponent = this.application.ninja.selectedElements[0].controller; 39 this.selectedComponent = this.application.ninja.selectedElements[0].controller;
@@ -47,6 +48,7 @@ exports.BindingTool = Montage.create(ModifierToolBase, {
47 NJevent("disableStageMove"); 48 NJevent("disableStageMove");
48 this.application.ninja.workspaceMode = "default"; 49 this.application.ninja.workspaceMode = "default";
49 this.selectedComponent = null; 50 this.selectedComponent = null;
51 this.application.ninja.stage.bindingView.hide = true;
50 } 52 }
51 53
52 } 54 }