Skip to content
Snippets Groups Projects
Commit 50d00a14 authored by Amanda Ghassaei's avatar Amanda Ghassaei
Browse files

small changes

parent 5ace8fc6
No related branches found
No related tags found
No related merge requests found
......@@ -76,9 +76,6 @@ OneBitBot.prototype._moveTo = function(x, y, z, speed, wcs, callback){
if (totalThreads > 0) return;
callback();
}
x += this.position.x;
y += this.position.y;
z += this.position.z;
var startingPos = this.meshes["zAxis"].position.clone();
speed = this._normalizeSpeed(startingPos, x, y, this._reorganizeSpeed(speed));
this._moveXAxis(startingPos.x, x, "x", speed.x, sketchyCallback);
......
......@@ -18,6 +18,7 @@ Ribbon = Backbone.View.extend({
this.listenTo(this.model, "change:cellMode", this.render);
this.listenTo(this.model, "change:deleteMode", this.render);
this.listenTo(dmaGlobals.lattice, "change:cellType change:connectionType", this.render);
this.render();
},
......@@ -32,14 +33,16 @@ Ribbon = Backbone.View.extend({
},
render: function(){
this.$el.html(this.template(this.model.toJSON()));
this.$el.html(this.template(_.extend(dmaGlobals.lattice.toJSON(), this.model.toJSON())));
},
template: _.template('\
<div class="btn-toolbar">\
<div class="btn-group">\
<a data-type="cell" class="btn btn-primary btn-ribbon cellModeBtn<% if (cellMode == "cell"){ %> ribbon-selected<% } %>" href="#"><img data-type="cell" src="assets/imgs/cell-sm.png"></a>\
<% if (allPartTypes[cellType][connectionType]){ %>\
<a data-type="part" class="btn btn-primary btn-ribbon cellModeBtn<% if (cellMode == "part"){ %> ribbon-selected<% } %>" href="#"><img data-type="part" src="assets/imgs/part-sm.png"></a>\
<% } %>\
<a class="btn btn-primary btn-ribbon deleteMode<% if (deleteMode){ %> ribbon-selected"<% } %>"><span class="fui-cross"></span></a>\
</div>\
</div>\
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment