Skip to content

Commit

Permalink
Minor change in the interface of tests page
Browse files Browse the repository at this point in the history
  • Loading branch information
PierreQuentel committed Sep 11, 2014
1 parent eeebd72 commit ce59a86
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 9 deletions.
2 changes: 2 additions & 0 deletions site/speed/editor.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ def set_value(x):editor.value=x
else:
storage = False

__BRYTHON__.debug = int(doc['set_debug'].checked)

def reset_src():
if storage and "py_src" in storage:
editor.setValue(storage["py_src"])
Expand Down
9 changes: 2 additions & 7 deletions site/tests/editor.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ def set_value(x):editor.value=x
else:
storage = False

__BRYTHON__.debug = int(doc['set_debug'].checked)

def reset_src():
if storage and "py_src" in storage:
editor.setValue(storage["py_src"])
Expand Down Expand Up @@ -66,13 +68,6 @@ def show_console(ev):
doc["console"].value = output
doc["console"].cols = 60

def clear_text(ev):
editor.setValue('')
if sys.has_local_storage:
storage["py_src"]=''

doc["console"].value=''

def run(*args):
global output
doc["console"].value=''
Expand Down
2 changes: 0 additions & 2 deletions site/tests/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@
# next functions are defined in editor.py
doc['show_js'].bind('click',show_js)
doc['run'].bind('click',run)
doc['clear_text'].bind('click',clear_text)
doc['show_console'].bind('click',show_console)
doc['files'].bind('change',load)
</script>
Expand Down Expand Up @@ -211,7 +210,6 @@
<div style="padding: 3px 3px 3px 3px;">
<div style="float:left">
<button id="run">run</button>
<button id="clear_text">clear</button>
debug<input type="checkbox" id="set_debug" checked>
</div>
<div style="float:right">
Expand Down

0 comments on commit ce59a86

Please sign in to comment.