aboutsummaryrefslogtreecommitdiff
path: root/js/lib/geom/rectangle.js
diff options
context:
space:
mode:
authorNivesh Rajbhandari2012-03-13 13:05:16 -0700
committerNivesh Rajbhandari2012-03-13 13:05:16 -0700
commite19376c54eedd1f1c457ba405b2f110be376a559 (patch)
treed48c090f71ed2cd6bd6ce38ff68c36ab69299985 /js/lib/geom/rectangle.js
parent970c2e63aa8ec3f70df2bf073cedb9e3b7617755 (diff)
parentf56b8cf4d3316d250c0f0045fb78f0dbd5c56e94 (diff)
downloadninja-e19376c54eedd1f1c457ba405b2f110be376a559.tar.gz
Merge branch 'refs/heads/ninja-internal' into WebGLFixes
Diffstat (limited to 'js/lib/geom/rectangle.js')
-rwxr-xr-xjs/lib/geom/rectangle.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/js/lib/geom/rectangle.js b/js/lib/geom/rectangle.js
index 6abaef2f..a47295e0 100755
--- a/js/lib/geom/rectangle.js
+++ b/js/lib/geom/rectangle.js
@@ -79,6 +79,8 @@ var Rectangle = function GLRectangle() {
79 } else { 79 } else {
80 this._fillMaterial = MaterialsModel.exportFlatMaterial(); 80 this._fillMaterial = MaterialsModel.exportFlatMaterial();
81 } 81 }
82
83 this.exportMaterials();
82 }; 84 };
83 85
84 /////////////////////////////////////////////////////////////////////// 86 ///////////////////////////////////////////////////////////////////////
@@ -230,7 +232,6 @@ var Rectangle = function GLRectangle() {
230 } else { 232 } else {
231 rtnStr += "flatMaterial"; 233 rtnStr += "flatMaterial";
232 } 234 }
233
234 rtnStr += "\n"; 235 rtnStr += "\n";
235 236
236 rtnStr += "fillMat: "; 237 rtnStr += "fillMat: ";
@@ -239,9 +240,10 @@ var Rectangle = function GLRectangle() {
239 } else { 240 } else {
240 rtnStr += "flatMaterial"; 241 rtnStr += "flatMaterial";
241 } 242 }
242
243 rtnStr += "\n"; 243 rtnStr += "\n";
244 244
245 rtnStr += this.exportMaterials();
246
245 return rtnStr; 247 return rtnStr;
246 }; 248 };
247 249
@@ -292,8 +294,9 @@ var Rectangle = function GLRectangle() {
292 console.log( "object material not found in library: " + fillMaterialName ); 294 console.log( "object material not found in library: " + fillMaterialName );
293 fillMat = MaterialsModel.exportFlatMaterial(); 295 fillMat = MaterialsModel.exportFlatMaterial();
294 } 296 }
295
296 this._fillMaterial = fillMat; 297 this._fillMaterial = fillMat;
298
299 this.importMaterials( importStr );
297 }; 300 };
298 301
299 this.buildBuffers = function() { 302 this.buildBuffers = function() {