split dragknife out of laser and create new mode based on it. template for waterjet and wire-edm
This commit is contained in:
parent
f164353dd1
commit
85f48ef9b4
12 changed files with 137 additions and 56 deletions
|
|
@ -140,6 +140,7 @@ gapp.register("kiri.main", [], (root, exports) => {
|
|||
is_cam() { return MODE === MODES.CAM },
|
||||
is_sla() { return MODE === MODES.SLA },
|
||||
is_laser() { return MODE === MODES.LASER },
|
||||
is_drag() { return MODE === MODES.DRAG },
|
||||
},
|
||||
probe: {
|
||||
live: "https://live.grid.space",
|
||||
|
|
@ -902,18 +903,10 @@ gapp.register("kiri.main", [], (root, exports) => {
|
|||
current.mode = mode;
|
||||
MODE = MODES[mode];
|
||||
DRIVER = kiri.driver[mode];
|
||||
// update mode drop-down
|
||||
if (false) {
|
||||
const modename = $('mode-name');
|
||||
const options = modename.options;
|
||||
const optlist = ["FDM","CAM","SLA","LASER"];
|
||||
options.selectedIndex = optlist.indexOf(mode);
|
||||
modename.onchange = (ev) => setMode(optlist[options.selectedIndex]);
|
||||
}
|
||||
// gcode edit area for any non-SLA mode
|
||||
api.uc.setVisible($('gcode-edit'), mode !== 'SLA');
|
||||
// highlight selected mode menu item
|
||||
["FDM","CAM","SLA","LASER"].forEach(sm => {
|
||||
["FDM","CAM","SLA","LASER","DRAG"].forEach(sm => {
|
||||
const cl = $(`mode-${sm.toLowerCase()}`).classList;
|
||||
if (sm === mode) {
|
||||
cl.add('selected');
|
||||
|
|
|
|||
Loading…
Reference in a new issue