Skip to content

Commit ab2b739

Browse files
author
Philip Guo
committed
nix hover to focus due to jerkiness
1 parent 64efc90 commit ab2b739

2 files changed

Lines changed: 12 additions & 3 deletions

File tree

‎PyTutorGAE/backend_test.py‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
1-
import pg_logger, pprint
1+
import pg_logger, pprint, json
22

33
pp = pprint.PrettyPrinter()
44

55
def pprint_finalizer(trace):
66
for e in trace:
77
pp.pprint(e)
88

9-
pg_logger.exec_script_str(open('example-code/closures/closure3.txt').read(), pprint_finalizer)
9+
10+
def json_finalizer(output_lst):
11+
json_output = json.dumps(output_lst, indent=None) # use indent=None for most compact repr
12+
print json_output
13+
14+
15+
pg_logger.exec_script_str(open('example-code/towers_of_hanoi.txt').read(), json_finalizer)

‎PyTutorGAE/js/pytutor.js‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ ExecutionVisualizer.prototype.render = function() {
8888
<button id="editBtn" class="medBtn" type="button">Edit code</button>\
8989
</div>\
9090
<div id="executionSliderCaption">\
91-
Hover here to focus and then use the left and right arrow keys to<br/>\
91+
Click to focus and then use the left and right arrow keys to<br/>\
9292
step through execution. Click on lines of code to set breakpoints.\
9393
</div>\
9494
<div id="executionSlider"/>\
@@ -288,9 +288,12 @@ ExecutionVisualizer.prototype.setKeyboardBindings = function() {
288288

289289
// focus on mouse entering td#left_pane (so that the user doesn't need
290290
// to click to focus)
291+
// This is actually annoying because the display JERKS to focus on elements ...
292+
/*
291293
leftTablePane.mouseenter(function() {
292294
leftTablePane.focus();
293295
});
296+
*/
294297

295298

296299
leftTablePane.keydown(function(k) {

0 commit comments

Comments
 (0)