summaryrefslogtreecommitdiff
path: root/js/codeq/robot.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/codeq/robot.js')
-rw-r--r--js/codeq/robot.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/js/codeq/robot.js b/js/codeq/robot.js
index a1b76f1..be164ee 100644
--- a/js/codeq/robot.js
+++ b/js/codeq/robot.js
@@ -14,7 +14,7 @@
jqAllQuadrants = jqDescription.add(jqCode).add(jqConsole).add(jqInfo), // all the quadrants
// buttons
jqBtnPlan = jqScreen.find('.btn-plan'),
- jqBtnHint = jqScreen.find('.btn-hint'),
+ jqBtnHint = jqScreen.find('.btn-hint').ladda(),
jqBtnRun = jqScreen.find('.btn-run'),
jqBtnStop = jqScreen.find('.btn-stop'),
jqInfoButtons = jqBtnPlan.add(jqBtnHint), // all info-focusing buttons
@@ -199,7 +199,7 @@
}
});
jqBtnHint.on('click', function () {
- var doc = editor.getDoc();
+ jqBtnHint.ladda('start');
codeq.comms.sendHint({
'language': 'robot',
'program': editor.getDoc().getValue(),
@@ -215,6 +215,9 @@
}
})
.fail(commError)
+ .fin(function () {
+ jqBtnHint.ladda('stop');
+ })
.done();
});
jqBtnRun.on('click', function () {