aboutsummaryrefslogtreecommitdiff
path: root/js/lib/NJUtils.js
diff options
context:
space:
mode:
authorEric Guzman2012-04-09 15:44:09 -0700
committerEric Guzman2012-04-09 15:44:09 -0700
commita27915e900eb768dd9db1f0dd441961ea80bfaa6 (patch)
tree593f429f0b3294103a059ae9f6ed03858288deb7 /js/lib/NJUtils.js
parentafcaa157f7bc067cf00de91b43b2a71e9b64b7b3 (diff)
parentbd43ce383b050d03b0f92cc923c517febc66ca28 (diff)
downloadninja-a27915e900eb768dd9db1f0dd441961ea80bfaa6.tar.gz
Merge branch 'refs/heads/master' into CSSPanelUpdates
Diffstat (limited to 'js/lib/NJUtils.js')
-rwxr-xr-xjs/lib/NJUtils.js12
1 files changed, 10 insertions, 2 deletions
diff --git a/js/lib/NJUtils.js b/js/lib/NJUtils.js
index 96e1d6da..f6284b6c 100755
--- a/js/lib/NJUtils.js
+++ b/js/lib/NJUtils.js
@@ -96,7 +96,10 @@ exports.NJUtils = Object.create(Object.prototype, {
96 ///// TODO: find a different place for this function 96 ///// TODO: find a different place for this function
97 makeElementModel: { 97 makeElementModel: {
98 value: function(el, selection, controller, isShape) { 98 value: function(el, selection, controller, isShape) {
99 var p3d = Montage.create(Properties3D).init(el); 99 var p3d = Montage.create(Properties3D);
100 if(selection === "Stage") {
101 p3d.init(el, true);
102 }
100 var shapeProps = null; 103 var shapeProps = null;
101 var pi = controller + "Pi"; 104 var pi = controller + "Pi";
102 105
@@ -138,7 +141,8 @@ exports.NJUtils = Object.create(Object.prototype, {
138 controller: { value: ControllerFactory.getController(controller)}, 141 controller: { value: ControllerFactory.getController(controller)},
139 pi: { value: pi}, 142 pi: { value: pi},
140 props3D: { value: p3d}, 143 props3D: { value: p3d},
141 shapeModel: { value: shapeProps} 144 shapeModel: { value: shapeProps},
145 isShape: { value: isShape}
142 }); 146 });
143 147
144 } 148 }
@@ -170,6 +174,7 @@ exports.NJUtils = Object.create(Object.prototype, {
170 // TODO - Need more info about the shape 174 // TODO - Need more info about the shape
171 selection = "canvas"; 175 selection = "canvas";
172 controller = "shape"; 176 controller = "shape";
177 isShape = true;
173 } 178 }
174 else 179 else
175 { 180 {
@@ -181,6 +186,9 @@ exports.NJUtils = Object.create(Object.prototype, {
181 break; 186 break;
182 } 187 }
183 this.makeElementModel(el, selection, controller, isShape); 188 this.makeElementModel(el, selection, controller, isShape);
189 if(el.elementModel && el.elementModel.props3D) {
190 el.elementModel.props3D.init(el, (selection === "Stage"));
191 }
184 } 192 }
185 }, 193 },
186 194