Skip to content

Commit 4cec129

Browse files
committed
Make prototype of working question in the middle of running the program.
1 parent 831b432 commit 4cec129

File tree

5 files changed

+209
-3
lines changed

5 files changed

+209
-3
lines changed

v3/css/basic.css

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
/*
2+
* SimpleModal Basic Modal Dialog
3+
* http://www.ericmmartin.com/projects/simplemodal/
4+
* http://code.google.com/p/simplemodal/
5+
*
6+
* Copyright (c) 2010 Eric Martin - http://ericmmartin.com
7+
*
8+
* Licensed under the MIT license:
9+
* http://www.opensource.org/licenses/mit-license.php
10+
*
11+
* Revision: $Id: basic.css 257 2010-07-27 23:06:56Z emartin24 $
12+
*/
13+
14+
#basic-modal-content {display:none;}
15+
16+
/* Overlay */
17+
#simplemodal-overlay {background-color:#000; cursor:wait;}
18+
19+
/* Container */
20+
#simplemodal-container {height:360px; width:600px; color:#bbb; background-color:#333; border:4px solid #444; padding:12px;}
21+
#simplemodal-container .simplemodal-data {padding:8px;}
22+
#simplemodal-container code {background:#141414; border-left:3px solid #65B43D; color:#bbb; display:block; font-size:12px; margin-bottom:12px; padding:4px 6px 6px;}
23+
#simplemodal-container a {color:#ddd;}
24+
#simplemodal-container a.modalCloseImg {background:url(x.png) no-repeat; width:25px; height:29px; display:inline; z-index:3200; position:absolute; top:-15px; right:-16px; cursor:pointer;}
25+
#simplemodal-container h3 {color:#84b8d9;}

v3/embedding-demo.html

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,14 @@
77
<!-- dependencies for pytutor.js -->
88
<script type="text/javascript" src="js/d3.v2.min.js"></script>
99
<script type="text/javascript" src="js/jquery-1.8.2.min.js"></script>
10+
<script type="text/javascript" src="js/jquery.simplemodal.js"></script>
11+
<script type="text/javascript" src="js/basic.js"></script>
1012
<script type="text/javascript" src="js/jquery.ba-bbq.min.js"></script> <!-- for handling back button and URL hashes -->
1113
<script type="text/javascript" src="js/jquery.jsPlumb-1.3.10-all-min.js "></script> <!-- for rendering SVG connectors
1214
DO NOT UPGRADE ABOVE 1.3.10 OR ELSE BREAKAGE WILL OCCUR -->
1315
<script type="text/javascript" src="js/jquery-ui-1.8.24.custom.min.js"></script> <!-- for sliders and other UI elements -->
1416
<link type="text/css" href="css/ui-lightness/jquery-ui-1.8.24.custom.css" rel="stylesheet" />
15-
17+
<link type="text/css" href="css/basic.css" rel="stylesheet" />
1618

1719
<!-- Python Tutor frontend code and styles -->
1820
<script type="text/javascript" src="js/pytutor.js"></script>
@@ -29,6 +31,18 @@
2931
<body>
3032

3133
<!-- This demo shows three visualizations, each embedded within a div ... -->
34+
<div id="bradsDiv"></div>
35+
<div id="basic-modal-content">
36+
Enter the value of the variable a after the current line is executed.
37+
<input id="basic-textbox" type="textbox" />
38+
<button onclick="checkMe('basic-textbox','bradsDiv','globals.a')">Check
39+
Me</button>
40+
<button onclick="closeModal('bradsDiv')">Continue...</button>
41+
<p class="feedbacktext"></p>
42+
</div>
43+
<div style='display:none'>
44+
<img src='x.png' alt='' />
45+
</div>
3246

3347
<p>Recursive list sum (from <a href="http://pythontutor.com">pythontutor.com</a> home page):</p>
3448

0 commit comments

Comments
 (0)