mirror of
https://github.com/Doodle3D/doodle3d-client.git
synced 2024-11-25 18:47:57 +01:00
NOTE: hack! this is temporary.
Hide stop button after print is started, until gcode sending is completed (to prevent sending gcode after stopping).
This commit is contained in:
parent
07fa1f62e8
commit
356630e7ba
@ -189,7 +189,7 @@ function initButtonBehavior() {
|
|||||||
}
|
}
|
||||||
function stopPrint() {
|
function stopPrint() {
|
||||||
console.log("f:stopPrint() >> sendPrintCommands = " + sendPrintCommands);
|
console.log("f:stopPrint() >> sendPrintCommands = " + sendPrintCommands);
|
||||||
if (!confirm("Weet je zeker dat je de huidige print wilt stoppen?")) return;
|
if (!confirm("Weet je zeker dat je huidige print wilt stoppen?")) return;
|
||||||
if (sendPrintCommands) printer.stop();
|
if (sendPrintCommands) printer.stop();
|
||||||
setState(Printer.STOPPING_STATE,printer.hasControl);
|
setState(Printer.STOPPING_STATE,printer.hasControl);
|
||||||
}
|
}
|
||||||
@ -206,6 +206,8 @@ function nextDoodle(e) {
|
|||||||
function print(e) {
|
function print(e) {
|
||||||
console.log("f:print() >> sendPrintCommands = " + sendPrintCommands);
|
console.log("f:print() >> sendPrintCommands = " + sendPrintCommands);
|
||||||
|
|
||||||
|
$(".btnPrint").css("display","none");
|
||||||
|
|
||||||
$("#textdump").text("");
|
$("#textdump").text("");
|
||||||
if (_points.length > 2) {
|
if (_points.length > 2) {
|
||||||
|
|
||||||
@ -230,7 +232,9 @@ function print(e) {
|
|||||||
console.log("f:print >> not enough points!");
|
console.log("f:print >> not enough points!");
|
||||||
}
|
}
|
||||||
|
|
||||||
alert("Je tekening zal nu geprint worden.");
|
alert("Je tekening zal nu geprint worden");
|
||||||
|
$(".btnPrint").css("display","block");
|
||||||
|
|
||||||
|
|
||||||
// $.post("/doodle3d.of", { data:output }, function(data) {
|
// $.post("/doodle3d.of", { data:output }, function(data) {
|
||||||
// btnPrint.disabled = false;
|
// btnPrint.disabled = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user