Commit 62c7a1fc authored by Amanda Ghassaei's avatar Amanda Ghassaei

debugging for new plist structure

parent 83bd9fb5
......@@ -27,7 +27,7 @@ define(['jquery', 'underscore', 'plist', 'backbone', 'lattice', 'appState', 'tex
//bind events
this.listenTo(this.model, "change:currentNav", this.render);
this.listenTo(lattice, "change:cellType change:connectionType", this._populateAndShow);
this.listenTo(lattice, "change:cellType change:connectionType change:latticeType", this._populateAndShow);
this.listenTo(this.model, "change:currentTab", function(){
if (!this.model.changedAttributes() || this.model.changedAttributes()["currentNav"]) return;
this._updateCurrentTab();
......
......@@ -27,7 +27,7 @@ define(['jquery', 'underscore', 'backbone', 'plist', 'lattice', 'appState', 'tex
this.listenTo(this.model, "change:highlightMode", this.render);
this.listenTo(this.model, "change:cellsVisible", this.render);
this.listenTo(this.model, "change:axesAreVisible", this.render);
this.listenTo(lattice, "change:cellType change:connectionType", this.render);
this.listenTo(lattice, "change:cellType change:connectionType change:latticeType", this.render);
this.render();
},
......
<% var latticeData = allLattices[cellType].connection[connectionType].type[latticeType]; %>
Part Type: &nbsp;&nbsp;
<div class="btn-group">
<button data-toggle="dropdown" class="btn dropdown-toggle" type="button"><%= allPartTypes[cellType][connectionType][partType] %><span class="caret"></span></button>
<button data-toggle="dropdown" class="btn dropdown-toggle" type="button"><%= latticeData.parts[partType].name %><span class="caret"></span></button>
<ul role="menu" class="dropdown-menu">
<% _.each(_.keys(allPartTypes[cellType][connectionType]), function(key){ %>
<li><a class="lattice dropdownSelector" data-property="partType" data-value="<%= key %>" href="#"><%= allPartTypes[cellType][connectionType][key] %></a></li>
<% _.each(latticeData.parts, function(val, key){ %>
<li><a class="lattice dropdownSelector" data-property="partType" data-value="<%= key %>" href="#"><%= val.name %></a></li>
<% }); %>
</ul>
</div><br/><br/>
......
......@@ -99,7 +99,9 @@ define(['three'], function(THREE){
octaTruss: {
name: "Matt's Truss",
parts: {
triangle:"Triangle"
triangle: {
name: "Triangle"
}
},
aspectRatio: new THREE.Vector3(1,1,1),
materialClasses: ['mechanical']
......@@ -122,8 +124,12 @@ define(['three'], function(THREE){
snapVoxel: {
name: "Ben's Voxels",
parts: {
vox: "Snap Voxel (high res)",
voxLowPoly: "Snap Voxel (low res)"
vox: {
name: "Snap Voxel (high res)"
},
voxLowPoly: {
name: "Snap Voxel (low res)"
}
},
aspectRatio: new THREE.Vector3(1,1,1),
materialClasses: ['mechanical']
......@@ -142,9 +148,15 @@ define(['three'], function(THREE){
kennyVertex: {
name: "Kenny's Lattice",
parts: {
kennyTeq: "Kenny Teq",
kennyTeqHighRes: "Kenny Teq (High Res)",
samTeq: "Square"
kennyTeq: {
name: "Kenny Tech"
},
kennyTeqHighRes: {
name: "Kenny Tech (High Res)"
},
samTeq: {
name: "Square"
}
// xShape:"X"
},
aspectRatio: new THREE.Vector3(1,1,1),
......@@ -196,8 +208,12 @@ define(['three'], function(THREE){
willGik: {
name: "Will's Lattice",
parts: {
lego: "Micro LEGO (high res)",
legoLowPoly: "Micro LEGO (low res)"
lego: {
name: "Micro LEGO (high res)"
},
legoLowPoly: {
name: "Micro LEGO (low res)"
}
},
aspectRatio: new THREE.Vector3(1,1,1.28),
materialClasses: ['electronic']
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment