diff options
author | Reinier Zwitserloot <r.zwitserloot@projectlombok.org> | 2019-04-24 00:41:05 +0200 |
---|---|---|
committer | Reinier Zwitserloot <r.zwitserloot@projectlombok.org> | 2019-04-24 00:41:28 +0200 |
commit | 031da25e35cc3ca3bdc1e2783415d27fe83dc8d9 (patch) | |
tree | 05f6623da0c08b71e07ed53bdee1052f839c31ca /website/resources/js | |
parent | 4cbe67361ba58f86e8847926f07a5172db1f6d2f (diff) | |
download | lombok-031da25e35cc3ca3bdc1e2783415d27fe83dc8d9.tar.gz lombok-031da25e35cc3ca3bdc1e2783415d27fe83dc8d9.tar.bz2 lombok-031da25e35cc3ca3bdc1e2783415d27fe83dc8d9.zip |
[website] added the 7-lessons presentation as video
Diffstat (limited to 'website/resources/js')
-rw-r--r-- | website/resources/js/main.js | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/website/resources/js/main.js b/website/resources/js/main.js index 5608a3c3..eaaf2df5 100644 --- a/website/resources/js/main.js +++ b/website/resources/js/main.js @@ -94,7 +94,23 @@ }); } + function seekVideo() { + var t = window.location.hash; + if (!t) return; + var s = /^#?(?:(\d\d?):)?(\d\d?):(\d\d?)$/.exec(t); + if (!s) return; + var videoj = $("#presentationVideo"); + if (!videoj || videoj.length == 0) return; + var video = videoj[0]; + var h = parseInt(s[1]); + if (!h) h = 0; + var m = parseInt(s[2]); + var s = parseInt(s[3]); + video.currentTime = (((h * 60) + m) * 60) + s; + } + $(ajaxFeaturePages); $(clickToTap); $(clickForVideo); + $(seekVideo); })($); |