From 465636cc0676d7fb83939d6fdb9204e474d47d46 Mon Sep 17 00:00:00 2001 From: hwc487 Date: Mon, 6 Feb 2012 13:08:26 -0800 Subject: Removed an unnecessary (and incorrect) snapping calculation. --- js/helper-classes/3D/snap-manager.js | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'js/helper-classes/3D') diff --git a/js/helper-classes/3D/snap-manager.js b/js/helper-classes/3D/snap-manager.js index 8819f637..7e1260bf 100644 --- a/js/helper-classes/3D/snap-manager.js +++ b/js/helper-classes/3D/snap-manager.js @@ -977,7 +977,7 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { viewUtils.setViewportObj( stage ); MathUtils.makeDimension3( screenPt ); - this.hSnapToElements( stage, screenPt, hitRecs, 0, screenPt ); + this.hSnapToElements( stage, hitRecs, 0, screenPt ); return; } @@ -985,7 +985,7 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { hSnapToElements : { - value: function( elt, parentPt, hitRecs, depth, globalScrPt ) + value: function( elt, hitRecs, depth, globalScrPt ) { // hit test the current object var hit; @@ -994,8 +994,7 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { // if the element is in the 2D cache snapping is done there if (elt.elementModel && !elt.elementModel.isIn2DSnapCache) { - var scrPt = viewUtils.parentToChild( parentPt, elt, false ); - hit = this.snapToElement( elt, scrPt, globalScrPt ); + hit = this.snapToElement( elt, globalScrPt ); if (hit) { //hitRecs.push( hit ); @@ -1017,14 +1016,14 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { } // test the rest of the tree var n = elt.childElementCount; - var eltPt = viewUtils.parentToChild( parentPt, elt, true ); + //var eltPt = viewUtils.parentToChild( parentPt, elt, true ); if (n > 0) { for (var i=0; i