Skip to content

Commit 43a51c0

Browse files
committed
blah
1 parent af460a6 commit 43a51c0

3 files changed

Lines changed: 12 additions & 23 deletions

File tree

v3/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ <h1><span id="shareHeading">EMBED</span> <span class="smallH1"> in any Web page<
211211
href="http://www.jsplumb.org/">jsPlumb</a>,
212212
<a href="https://togetherjs.com/">TogetherJS</a>,
213213
and <a
214-
href="http://codemirror.net/">CodeMirror</a> for the frontend
214+
href="http://ace.c9.io/">Ace</a> for the frontend
215215

216216
<li/>Free, open-source BSD-licensed code on <a
217217
href="https://github.com/pgbovine/OnlinePythonTutor/">GitHub</a>

v3/js/opt-office-mix.js

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ function officeMixFinishSuccessfulExecution() {
9191
$('#pyOutputPane #editCodeLinkDiv').hide(); // don't have explicit "Edit code" link
9292
$('#loadingPane').hide();
9393

94-
$("#toggleModebtn").html("Edit");
94+
$("#toggleModebtn").html("Edit code");
9595
}
9696

9797

@@ -145,12 +145,13 @@ function officeMixEnterViewMode(firstTime) {
145145
pyInputSetValue(savedAppState.code);
146146
}
147147
}
148-
149-
executeCodeFromScratch();
150148
}
151149
});
152150

153-
$("#footer").hide();
151+
executeCodeFromScratch(); // unconditionally execute since it's more reliable
152+
153+
// on second thought, don't hide this
154+
//$("#toggleModebtn").hide();
154155
}
155156

156157
function officeMixEnterEditMode(firstTime) {
@@ -186,9 +187,8 @@ function officeMixEnterEditMode(firstTime) {
186187
}
187188
});
188189

189-
$("#toggleModebtn").html("Preview");
190+
$("#toggleModebtn").html("Visualize code").show();
190191
enterEditMode();
191-
$("#footer").show();
192192
}
193193

194194
function saveCurrentConfiguration() {
@@ -206,7 +206,7 @@ $(document).ready(function() {
206206
if (appMode == 'edit') {
207207
executeCodeFromScratch();
208208
} else {
209-
$("#toggleModebtn").html("Preview");
209+
$("#toggleModebtn").html("Visualize code");
210210
enterEditMode();
211211
}
212212
});
@@ -299,4 +299,6 @@ $(document).ready(function() {
299299
Labs.on(Labs.Core.EventTypes.Deactivate, function() {
300300
});
301301
});
302+
303+
pyInputSetValue('x = "world"\nprint("hello " + x)')
302304
});

v3/opt-office-mix.html

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -119,30 +119,17 @@
119119
<div id="footer">
120120

121121
<p>
122-
<button id="toggleModebtn" style="font-size: 16pt;">???</button>
122+
<button id="toggleModebtn" style="font-size: 14pt;">???</button>
123123
</p>
124124

125125
<p>
126-
127126
<a href="http://pythontutor.com/" target="_blank">Online Python Tutor</a> supports
128127
Python 2.7 and 3.3 with limited module imports and no file I/O.
129-
The following modules may be imported:
130-
bisect,
131-
collections,
132-
datetime,
133-
functools,
134-
heapq,
135-
itertools,
136-
json,
137-
math,
138-
operator,
139-
random,
140-
re,
141-
string
142128
</p>
143129

144130
<p style="margin-top: 8px;">
145131
Copyright &copy; 2010-2014 <a href="http://www.pgbovine.net/" target="_blank">Philip Guo</a>. All rights reserved.
132+
Read <a href="support-and-privacy.html">Privacy and Terms of Use information</a>.
146133
</p>
147134

148135
</div>

0 commit comments

Comments
 (0)