Skip to content

Commit

Permalink
Merge pull request #49 from tcyrus/patch-1
Browse files Browse the repository at this point in the history
Update index.html
  • Loading branch information
manuels committed Jan 24, 2017
2 parents 56e790f + ce72490 commit 8bc93d9
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!doctype html>
<html>
<head>
<style>
Expand Down Expand Up @@ -160,9 +161,10 @@ <h2>Related Projects</h2>
var showOpenButton = visibilityChanger("tab_open_pdf")

var appendOutput = function(msg) {
var content = document.getElementById("output").textContent;

var output = document.getElementById("output");

var content = output.textContent;

output.textContent = content + "\r\n" + msg;

output.scrollTop = 999999;
Expand All @@ -182,16 +184,16 @@ <h2>Related Projects</h2>
pdftex.on_stdout = appendOutput;
pdftex.on_stderr = appendOutput;

var start_time = new Date().getTime();
console.time("Execution time");

pdftex.compile(source_code).then(function(pdf_dataurl) {
var end_time = new Date().getTime();
console.info("Execution time: " + (end_time-start_time)/1000+' sec');
console.timeEnd("Execution time");

showLoadingIndicator(false);

if(pdf_dataurl === false)
if (pdf_dataurl === false)
return;

showOpenButton(true);
window.location.href = "#open_pdf";
document.getElementById("open_pdf_btn").focus();
Expand Down

0 comments on commit 8bc93d9

Please sign in to comment.