diff options
author | Jonathan Duran | 2012-04-19 13:22:38 -0700 |
---|---|---|
committer | Jonathan Duran | 2012-04-19 13:22:38 -0700 |
commit | 978c53b8e1e2476bb47c15717bf2bb3aacf3948d (patch) | |
tree | 889b4d7e496529688a5030b1fd8001e3d2846d57 /js/helper-classes/3D/snap-manager.js | |
parent | 3cc269d008ed9d95ae34adb6db34e6a0c2b272c0 (diff) | |
parent | 6d33345a9e609e36539d2efa25569f5eeb04a2af (diff) | |
download | ninja-978c53b8e1e2476bb47c15717bf2bb3aacf3948d.tar.gz |
Merge branch 'refs/heads/NINJAmaster' into TimelineUber
Diffstat (limited to 'js/helper-classes/3D/snap-manager.js')
-rwxr-xr-x | js/helper-classes/3D/snap-manager.js | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/js/helper-classes/3D/snap-manager.js b/js/helper-classes/3D/snap-manager.js index 02e81a62..cd8cc102 100755 --- a/js/helper-classes/3D/snap-manager.js +++ b/js/helper-classes/3D/snap-manager.js | |||
@@ -306,6 +306,8 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { | |||
306 | this.deactivateDragPlane(); | 306 | this.deactivateDragPlane(); |
307 | 307 | ||
308 | this.setLastHit( rtnHit ); | 308 | this.setLastHit( rtnHit ); |
309 | |||
310 | //rtnHit.test(); // DEBUG CODE. REMOVE THIS | ||
309 | return rtnHit; | 311 | return rtnHit; |
310 | } | 312 | } |
311 | }, | 313 | }, |
@@ -1086,15 +1088,6 @@ var SnapManager = exports.SnapManager = Montage.create(Component, { | |||
1086 | localPt = MathUtils.transformPoint( localPt, inv ); | 1088 | localPt = MathUtils.transformPoint( localPt, inv ); |
1087 | var hitContained = false; | 1089 | var hitContained = false; |
1088 | hitContained = this.snapToContainedElements( hitRec, localPt, globalScrPt ); | 1090 | hitContained = this.snapToContainedElements( hitRec, localPt, globalScrPt ); |
1089 | |||
1090 | // disable snapping to element bounds when the object isnot selected | ||
1091 | if (!hitContained && !this.application.ninja.selectionController.isObjectSelected(elt)) | ||
1092 | { | ||
1093 | if ((hitRec.getType() == hitRec.SNAP_TYPE_ELEMENT_EDGE) || | ||
1094 | (hitRec.getType() == hitRec.SNAP_TYPE_ELEMENT_VERTEX) || | ||
1095 | (hitRec.getType() == hitRec.SNAP_TYPE_ELEMENT)) | ||
1096 | hitRec = null; | ||
1097 | } | ||
1098 | } | 1091 | } |
1099 | 1092 | ||
1100 | return hitRec; | 1093 | return hitRec; |