summaryrefslogtreecommitdiffhomepage
path: root/plugin/notes-server/notes.html
diff options
context:
space:
mode:
authorHakim El Hattab2012-10-25 09:42:33 -0400
committerHakim El Hattab2012-10-25 09:42:33 -0400
commit6794f543e0d8ff589fe5258a6923f1afffc1e0da (patch)
tree4e01bc032d6959ebb6af9d6ac898dddfe80338e5 /plugin/notes-server/notes.html
parent5d1bac5790086cbd28fbcacd8a4cadb6c6e2e403 (diff)
parentb838522be43062bfeca2953506f514f5f88996fc (diff)
merge in support for stepped fragments in notes server
Diffstat (limited to 'plugin/notes-server/notes.html')
-rw-r--r--plugin/notes-server/notes.html25
1 files changed, 18 insertions, 7 deletions
diff --git a/plugin/notes-server/notes.html b/plugin/notes-server/notes.html
index 548bc12..d71d7f8 100644
--- a/plugin/notes-server/notes.html
+++ b/plugin/notes-server/notes.html
@@ -112,17 +112,28 @@
// ignore data from sockets that aren't ours
if (data.socketId !== socketId) { return; }
- if (data.markdown) {
- notes.innerHTML = (new Showdown.converter()).makeHtml(data.notes);
- }
- else {
- notes.innerHTML = data.notes;
- }
+ if (data.markdown) {
+ notes.innerHTML = (new Showdown.converter()).makeHtml(data.notes);
+ }
+ else {
+ notes.innerHTML = data.notes;
+ }
currentSlide.contentWindow.Reveal.slide(data.indexh, data.indexv);
nextSlide.contentWindow.Reveal.slide(data.nextindexh, data.nextindexv);
});
+ socket.on('fragmentdata', function(data) {
+ // ignore data from sockets that aren't ours
+ if (data.socketId !== socketId) { return; }
+
+ if (data.fragment === 'next') {
+ currentSlide.contentWindow.Reveal.nextFragment();
+ }
+ else if (data.fragment === 'previous') {
+ currentSlide.contentWindow.Reveal.prevFragment();
+ }
+ });
</script>
</body>
-</html> \ No newline at end of file
+</html>