Skip to content
Snippets Groups Projects
Commit f42cbbd8 authored by Neil Gershenfeld's avatar Neil Gershenfeld
Browse files

fix draw

parent 39ee9c92
No related branches found
No related tags found
No related merge requests found
...@@ -322,8 +322,6 @@ var interface = function(div){ ...@@ -322,8 +322,6 @@ var interface = function(div){
mod.label.nodeValue = 'calculating' mod.label.nodeValue = 'calculating'
mod.labelspan.style.fontWeight = 'bold' mod.labelspan.style.fontWeight = 'bold'
mod.depth = parseFloat(mod.cut_mm.value) mod.depth = parseFloat(mod.cut_mm.value)
mod.offset = 0.5
mod.offsetCount = 0
mod.toolpath = [] mod.toolpath = []
clear_path() clear_path()
outputs.diameter.event() outputs.diameter.event()
...@@ -410,6 +408,8 @@ function set_values(settings) { ...@@ -410,6 +408,8 @@ function set_values(settings) {
// //
function clear_path() { function clear_path() {
mod.path = [] mod.path = []
mod.offset = 0.5
mod.offsetCount = 0
var svg = document.getElementById(mod.div.id+'svg') var svg = document.getElementById(mod.div.id+'svg')
svg.setAttribute('viewBox',"0 0 "+(mod.img.width-1)+" "+(mod.img.height-1)) svg.setAttribute('viewBox',"0 0 "+(mod.img.width-1)+" "+(mod.img.height-1))
var g = document.getElementById(mod.div.id+'g') var g = document.getElementById(mod.div.id+'g')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment