From 7793b66c8ea99a34194574419dc0a169770ea0c1 Mon Sep 17 00:00:00 2001 From: Amanda Ghassaei <amandaghassaei@gmail.com> Date: Sat, 15 Aug 2015 22:38:22 -0400 Subject: [PATCH] reset cells working properly --- js/cam/Cam.js | 2 +- js/lattice/LatticeBase.js | 5 +++-- js/plists/PList.js | 4 ++-- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/js/cam/Cam.js b/js/cam/Cam.js index ceccf6e6..4aad7f5e 100644 --- a/js/cam/Cam.js +++ b/js/cam/Cam.js @@ -261,7 +261,7 @@ define(['underscore', 'three', 'backbone', 'appState', 'latticeCAM', 'threeModel this.set("simLineNumber", 0, {silent:true}); appState.set("stockSimulationPlaying", false); three.stopAnimationLoop(); - lattice.showCells(); + lattice.showCells("cells"); }, _stockSimulation: function(){ diff --git a/js/lattice/LatticeBase.js b/js/lattice/LatticeBase.js index ade2d7cc..c54c27b9 100644 --- a/js/lattice/LatticeBase.js +++ b/js/lattice/LatticeBase.js @@ -464,9 +464,10 @@ define(['underscore', 'backbone', 'appState', 'globals', 'plist', 'three', 'thre three.render(); }, - showCells: function(){ + showCells: function(whichArray){ + if (!whichArray) whichArray = "sparseCells"; var cellMode = appState.get("cellMode"); - this._iterCells(this.sparseCells, function(cell){ + this._iterCells(this[whichArray], function(cell){ if (cell) cell.show(cellMode) }); three.render(); diff --git a/js/plists/PList.js b/js/plists/PList.js index 35a719cf..dfade1ae 100644 --- a/js/plists/PList.js +++ b/js/plists/PList.js @@ -11,8 +11,8 @@ define(['three'], function(THREE){ //sketch:"Sketch", material:"Materials", import:"Import", - part:"Part", - script:"Script" + part:"Part" +// script:"Script" }, electronicNavSim:{ eSetup:"Connectivity", -- GitLab