fixing gcode selection
This commit is contained in:
@@ -203,7 +203,7 @@ module.exports = {
|
|||||||
return Math.min(1, p);
|
return Math.min(1, p);
|
||||||
},
|
},
|
||||||
isMacrosPresent: function(){
|
isMacrosPresent: function(){
|
||||||
return this.config.macros==undefined;
|
return this.config.macros!=undefined;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -34,24 +34,23 @@ module.exports = {
|
|||||||
methods:{
|
methods:{
|
||||||
open: function() {
|
open: function() {
|
||||||
utils.clickFileInput("gcode-file-input");
|
utils.clickFileInput("gcode-file-input");
|
||||||
console.log("utils done");
|
|
||||||
},
|
},
|
||||||
load: function() {
|
load: function() {
|
||||||
const file_time = this.state.selected_time;
|
const file_time = this.state.selected_time;
|
||||||
console.log('file_time',this.state.selected_time);
|
console.log('file_time',this.state.selected_time);
|
||||||
const file = this.state.selected;
|
const file = this.state.selected;
|
||||||
console.log("file: ",this.state.selected);
|
console.log("file: ",this.state.selected);
|
||||||
if (this.last_file == file && this.last_file_time == file_time) {
|
// if (this.last_file == file && this.last_file_time == file_time) {
|
||||||
return;
|
// return;
|
||||||
}
|
// }
|
||||||
|
|
||||||
this.last_file = file;
|
// this.last_file = file;
|
||||||
this.last_file_time = file_time;
|
// this.last_file_time = file_time;
|
||||||
|
|
||||||
this.$broadcast("gcode-load", file);
|
// this.$broadcast("gcode-load", file);
|
||||||
this.$broadcast("gcode-line", this.state.line);
|
// this.$broadcast("gcode-line", this.state.line);
|
||||||
this.toolpath_progress = 0;
|
// this.toolpath_progress = 0;
|
||||||
this.load_toolpath(file, file_time);
|
// this.load_toolpath(file, file_time);
|
||||||
},
|
},
|
||||||
upload: function(e) {
|
upload: function(e) {
|
||||||
const files = e.target.files || e.dataTransfer.files;
|
const files = e.target.files || e.dataTransfer.files;
|
||||||
|
|||||||
Reference in New Issue
Block a user