diff options
Diffstat (limited to 'pointless/viewer/viewer.js')
-rw-r--r-- | pointless/viewer/viewer.js | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/pointless/viewer/viewer.js b/pointless/viewer/viewer.js new file mode 100644 index 0000000..00c6f76 --- /dev/null +++ b/pointless/viewer/viewer.js | |||
@@ -0,0 +1,23 @@ | |||
1 | /* | ||
2 | * viewer.js | ||
3 | * Part of Pointless Viewer, a Beamer presentation viewer | ||
4 | * Copyright 2018 Pacien TRAN-GIRARD | ||
5 | * License: GNU GPL v3 | ||
6 | */ | ||
7 | |||
8 | "use strict"; | ||
9 | |||
10 | var params = function() { | ||
11 | var queryDict = {}; | ||
12 | location.search.substr(1).split("&").forEach(function(item) { | ||
13 | var pair = item.split("="); | ||
14 | queryDict[pair[0]] = pair[1]; | ||
15 | }); | ||
16 | return queryDict; | ||
17 | }(); | ||
18 | |||
19 | if (window.opener == null) { | ||
20 | pdfjsLib.getDocument(params["file"]).then(function(pdf) { | ||
21 | var presentation = new Presentation(pdf); | ||
22 | }); | ||
23 | } | ||