1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-20 15:18:08 +02:00

Make worker support work again after file split. Add PDFJS_WORKER_DIR/PDFJS_WORKER_FILE to specify where to load files if worker support is enabled

This commit is contained in:
Julian Viereck 2011-10-28 14:32:36 +02:00
parent 21a6467b23
commit 1e6d1f9922
8 changed files with 91 additions and 46 deletions

View file

@ -1,2 +1,7 @@
<!-- This snippet is used in production, see Makefile -->
<script type="text/javascript" src="../build/pdf.js"></script>
<script type="text/javascript">
// This specifies the location of the pdf.js file. This is necessary to
// spawn the web worker.
var PDFJS_WORKER_FILE = "../build/pdf.js";
</script>

View file

@ -3,9 +3,9 @@
<head>
<title>Simple pdf.js page viewer</title>
<link rel="stylesheet" href="viewer.css"/>
<!-- PDFJSSCRIPT_INCLUDE_BUILD -->
<script type="text/javascript">var PDFJS_WORKER_DIR = "../src/"</script> <!-- PDFJSSCRIPT_REMOVE -->
<script type="text/javascript" src="../src/core.js"></script> <!-- PDFJSSCRIPT_REMOVE -->
<script type="text/javascript" src="../src/util.js"></script> <!-- PDFJSSCRIPT_REMOVE -->
<script type="text/javascript" src="../src/canvas.js"></script> <!-- PDFJSSCRIPT_REMOVE -->
@ -114,7 +114,7 @@
</div>
</div>
</div>
<div id="loading">Loading... 0%</div>
<div id="viewer"></div>
</body>