diff options
author | Hakim El Hattab <hakim.elhattab@gmail.com> | 2016-01-08 14:32:03 +0100 |
---|---|---|
committer | Hakim El Hattab <hakim.elhattab@gmail.com> | 2016-01-08 14:32:03 +0100 |
commit | 3df2129bd6d369c45fadaf1f14c4d6c23a55ad50 (patch) | |
tree | f948f34dc0a44debb7ce83d7533d06a63a68ebb4 | |
parent | 993526ff67a46ff3d7749014b7b0841a00831ad5 (diff) | |
parent | f79210c6c1451bb4ae2942068de6c7d543f58d89 (diff) | |
download | perl-software-in-gnu-guix-3df2129bd6d369c45fadaf1f14c4d6c23a55ad50.tar perl-software-in-gnu-guix-3df2129bd6d369c45fadaf1f14c4d6c23a55ad50.tar.gz |
Merge branch 'patch-1' of https://github.com/danieltdt/reveal.js into dev
-rw-r--r-- | plugin/notes/notes.js | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/plugin/notes/notes.js b/plugin/notes/notes.js index deb4891..4299034 100644 --- a/plugin/notes/notes.js +++ b/plugin/notes/notes.js @@ -11,10 +11,14 @@ */ var RevealNotes = (function() { - function openNotes() { - var jsFileLocation = document.querySelector('script[src$="notes.js"]').src; // this js file path - jsFileLocation = jsFileLocation.replace(/notes\.js(\?.*)?$/, ''); // the js folder path - var notesPopup = window.open( jsFileLocation + 'notes.html', 'reveal.js - Notes', 'width=1100,height=700' ); + function openNotes(notes_html_file_path) { + if (!notes_html_file_path) { + var jsFileLocation = document.querySelector('script[src$="notes.js"]').src; // this js file path + jsFileLocation = jsFileLocation.replace(/notes\.js(\?.*)?$/, ''); // the js folder path + notes_html_file_path = jsFileLocation + 'notes.html'; + } + + var notesPopup = window.open(notes_html_file_path, 'reveal.js - Notes', 'width=1100,height=700' ); /** * Connect to the notes window through a postmessage handshake. |