aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes
diff options
context:
space:
mode:
authorhwc4872012-04-27 13:52:40 -0700
committerhwc4872012-04-27 13:52:40 -0700
commite73fba18b095f0c270f5d954e5993c155b488c73 (patch)
treeda18c6c0117fec3652b823bddc198add47632fc8 /js/helper-classes
parent4b83774cdbfbf30add9a8fa2f11b1c4ff35179fa (diff)
downloadninja-e73fba18b095f0c270f5d954e5993c155b488c73.tar.gz
Creating shapes in a container
Diffstat (limited to 'js/helper-classes')
-rwxr-xr-xjs/helper-classes/3D/snap-manager.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/js/helper-classes/3D/snap-manager.js b/js/helper-classes/3D/snap-manager.js
index dcfd5ddc..7fc492a5 100755
--- a/js/helper-classes/3D/snap-manager.js
+++ b/js/helper-classes/3D/snap-manager.js
@@ -1011,7 +1011,8 @@ var SnapManager = exports.SnapManager = Montage.create(Component, {
1011 } 1011 }
1012 // hit test the current object 1012 // hit test the current object
1013 var hit; 1013 var hit;
1014 if (depth > 0) // don't snap to the root 1014 var snapToStage = ((depth === 0) && (elt === this.application.ninja.currentSelectedContainer) && (elt.nodeName === 'CANVAS'));
1015 if ((depth > 0) || snapToStage) // don't snap to the root unles we are working inside a canvas
1015 { 1016 {
1016 // if the element is in the 2D cache snapping is done there 1017 // if the element is in the 2D cache snapping is done there
1017 if (elt.elementModel && !elt.elementModel.isIn2DSnapCache) 1018 if (elt.elementModel && !elt.elementModel.isIn2DSnapCache)