aboutsummaryrefslogtreecommitdiff
path: root/js/stage
diff options
context:
space:
mode:
Diffstat (limited to 'js/stage')
-rwxr-xr-xjs/stage/layout.js4
-rw-r--r--js/stage/objects-tray.reel/objects-tray.js10
-rwxr-xr-xjs/stage/stage.reel/stage.js2
-rwxr-xr-xjs/stage/tool-handle.js28
4 files changed, 22 insertions, 22 deletions
diff --git a/js/stage/layout.js b/js/stage/layout.js
index 3fcfe9eb..bf7e79c3 100755
--- a/js/stage/layout.js
+++ b/js/stage/layout.js
@@ -309,7 +309,7 @@ exports.Layout = Montage.create(Component, {
309 { 309 {
310 return; 310 return;
311 } 311 }
312 312
313 try { 313 try {
314 if(element.nodeType == 1 && this.application.ninja.currentDocument.inExclusion(element) === -1 ) { 314 if(element.nodeType == 1 && this.application.ninja.currentDocument.inExclusion(element) === -1 ) {
315 315
@@ -393,5 +393,5 @@ exports.Layout = Montage.create(Component, {
393 } 393 }
394 } 394 }
395 395
396 396
397}); 397});
diff --git a/js/stage/objects-tray.reel/objects-tray.js b/js/stage/objects-tray.reel/objects-tray.js
index 2494c2b5..d81c2a8c 100644
--- a/js/stage/objects-tray.reel/objects-tray.js
+++ b/js/stage/objects-tray.reel/objects-tray.js
@@ -46,19 +46,19 @@ exports.ObjectsTray = Montage.create(Component, {
46 offStageObjectsController : { 46 offStageObjectsController : {
47 value: null 47 value: null
48 }, 48 },
49 49
50 _showAllObjects : { value: null }, 50 _showAllObjects : { value: null },
51 showAllObjects : { 51 showAllObjects : {
52 get : function() { return this._showAllObjects; }, 52 get : function() { return this._showAllObjects; },
53 set : function(value) { 53 set : function(value) {
54 if(value === this._showAllObjects) { return; } 54 if(value === this._showAllObjects) { return; }
55 55
56 this._showAllObjects = value; 56 this._showAllObjects = value;
57 57
58 this.needsDraw = true; 58 this.needsDraw = true;
59 } 59 }
60 }, 60 },
61 61
62 workspaceMode : { 62 workspaceMode : {
63 get : function() { return this._workspaceMode; }, 63 get : function() { return this._workspaceMode; },
64 set : function(value) { 64 set : function(value) {
@@ -119,7 +119,7 @@ exports.ObjectsTray = Montage.create(Component, {
119 Draw Cycle 119 Draw Cycle
120 --------------------- */ 120 --------------------- */
121 121
122 templateDidLoad: { 122 templateDidLoad: {
123 value: function() { 123 value: function() {
124 this.offStageObjectsController.filterFunction = this.offStageObjectFilter.bind(this); 124 this.offStageObjectsController.filterFunction = this.offStageObjectFilter.bind(this);
125 } 125 }
diff --git a/js/stage/stage.reel/stage.js b/js/stage/stage.reel/stage.js
index 67ce5081..49e7b641 100755
--- a/js/stage/stage.reel/stage.js
+++ b/js/stage/stage.reel/stage.js
@@ -567,7 +567,7 @@ exports.Stage = Montage.create(Component, {
567 this._clickPoint.y = point.y; // event.layerY; 567 this._clickPoint.y = point.y; // event.layerY;
568 568
569 this.enableMouseInOut(); 569 this.enableMouseInOut();
570 570
571 this.application.ninja.toolsData.selectedToolInstance.downPoint.x = point.x; 571 this.application.ninja.toolsData.selectedToolInstance.downPoint.x = point.x;
572 this.application.ninja.toolsData.selectedToolInstance.downPoint.y = point.y; 572 this.application.ninja.toolsData.selectedToolInstance.downPoint.y = point.y;
573 this.application.ninja.toolsData.selectedToolInstance.HandleLeftButtonDown(event); 573 this.application.ninja.toolsData.selectedToolInstance.HandleLeftButtonDown(event);
diff --git a/js/stage/tool-handle.js b/js/stage/tool-handle.js
index e5b0a22f..ecd16951 100755
--- a/js/stage/tool-handle.js
+++ b/js/stage/tool-handle.js
@@ -111,7 +111,7 @@ var ToolHandle = exports.ToolHandle = Montage.create(Component, {
111 return true; 111 return true;
112 } 112 }
113 } 113 }
114 114
115}); 115});
116 116
117 117
@@ -302,7 +302,7 @@ exports.RotateHandle = Montage.create(ToolHandle, {
302 this._planeEq[3] = -vecUtils.vecDot(3, this._planeEq, this._origin); 302 this._planeEq[3] = -vecUtils.vecDot(3, this._planeEq, this._origin);
303 303
304 this._dirVecL = MathUtils.transformPoint(this._dirVec, this._matL); 304 this._dirVecL = MathUtils.transformPoint(this._dirVec, this._matL);
305 305
306 context.beginPath(); 306 context.beginPath();
307 307
308 var pt = [this._radius, 0.0, 0.0]; 308 var pt = [this._radius, 0.0, 0.0];
@@ -322,7 +322,7 @@ exports.RotateHandle = Montage.create(ToolHandle, {
322 322
323 // Draw the transform handle 323 // Draw the transform handle
324 context.beginPath(); 324 context.beginPath();
325 325
326 pt = [this._transformCenterRadius, 0.0, 0.0]; 326 pt = [this._transformCenterRadius, 0.0, 0.0];
327 327
328 for (var i=0; i<this._nTriangles; i++) 328 for (var i=0; i<this._nTriangles; i++)
@@ -336,7 +336,7 @@ exports.RotateHandle = Montage.create(ToolHandle, {
336 context.stroke(); 336 context.stroke();
337 337
338 338
339 339
340 context.restore(); 340 context.restore();
341 } 341 }
342 }, 342 },
@@ -384,7 +384,7 @@ exports.RotateHandle = Montage.create(ToolHandle, {
384 384
385 return 0; 385 return 0;
386 } 386 }
387 387
388 localPt = MathUtils.transformPoint(localPt, this._matL); 388 localPt = MathUtils.transformPoint(localPt, this._matL);
389 389
390 var theta = Math.atan2(localPt[1], localPt[0]); 390 var theta = Math.atan2(localPt[1], localPt[0]);
@@ -398,13 +398,13 @@ exports.RotateHandle = Montage.create(ToolHandle, {
398 { 398 {
399 return 1; 399 return 1;
400 } 400 }
401 401
402 xC = this._radius*Math.cos(theta); 402 xC = this._radius*Math.cos(theta);
403 yC = this._radius*Math.sin(theta); 403 yC = this._radius*Math.sin(theta);
404 ptOnCircle = [xC, yC, 0]; 404 ptOnCircle = [xC, yC, 0];
405 405
406 dist = vecUtils.vecDist( 2, localPt, ptOnCircle ); 406 dist = vecUtils.vecDist( 2, localPt, ptOnCircle );
407 407
408 if ( dist <= 5 ) 408 if ( dist <= 5 )
409 { 409 {
410 return 2; 410 return 2;
@@ -414,7 +414,7 @@ exports.RotateHandle = Montage.create(ToolHandle, {
414 } 414 }
415 }, 415 },
416 416
417 417
418 drawShadedAngle: { 418 drawShadedAngle: {
419 value: function(angle, localPt) { 419 value: function(angle, localPt) {
420 420
@@ -448,7 +448,7 @@ exports.RotateHandle = Montage.create(ToolHandle, {
448 } 448 }
449 449
450 context.lineTo(this._origin[0], this._origin[1]); 450 context.lineTo(this._origin[0], this._origin[1]);
451 451
452 context.stroke(); 452 context.stroke();
453 context.fill(); 453 context.fill();
454 454
@@ -675,7 +675,7 @@ exports.TranslateHandle = Montage.create(ToolHandle, {
675 context.stroke(); 675 context.stroke();
676 676
677 this._drawArrowHead(this._origin, this._endPt, context); 677 this._drawArrowHead(this._origin, this._endPt, context);
678 678
679 context.restore(); 679 context.restore();
680 } 680 }
681 }, 681 },
@@ -734,10 +734,10 @@ exports.TranslateHandle = Montage.create(ToolHandle, {
734 context.restore(); 734 context.restore();
735 } 735 }
736 }, 736 },
737 737
738 collidesWithPoint: 738 collidesWithPoint:
739 { 739 {
740 value:function (x, y) 740 value:function (x, y)
741 { 741 {
742 var globalPt = [x, y, this._origin[2]]; 742 var globalPt = [x, y, this._origin[2]];
743 743
@@ -750,7 +750,7 @@ exports.TranslateHandle = Montage.create(ToolHandle, {
750 { 750 {
751 return 0; 751 return 0;
752 } 752 }
753 753
754 var t = MathUtils.parameterizePointOnLine2D( this._origin, this._dirVec, nearPt ); 754 var t = MathUtils.parameterizePointOnLine2D( this._origin, this._dirVec, nearPt );
755 dist = vecUtils.vecDist( 2, globalPt, nearPt ); 755 dist = vecUtils.vecDist( 2, globalPt, nearPt );
756 if (dist <= 5) 756 if (dist <= 5)