Commit 2c922ae3 by doszhang

dos

parent cc4323f1
...@@ -90,6 +90,9 @@ const linkAddress = { ...@@ -90,6 +90,9 @@ const linkAddress = {
$('.video1').append('<video src="../media/video1.mp4" id="video1"></video>'); $('.video1').append('<video src="../media/video1.mp4" id="video1"></video>');
$('.video2').append('<video src="../media/video2.mp4" id="video2"></video>'); $('.video2').append('<video src="../media/video2.mp4" id="video2"></video>');
$('.video3').append('<video src="../media/video3.mp4" id="video3"></video>'); $('.video3').append('<video src="../media/video3.mp4" id="video3"></video>');
const video1 = document.getElementById("video1");
const video2 = document.getElementById("video2");
const video3 = document.getElementById("video3");
preloadimages(preloadImageList, function () { preloadimages(preloadImageList, function () {
$('.home-page').show(); $('.home-page').show();
...@@ -186,7 +189,13 @@ function jumpTolink(event) { ...@@ -186,7 +189,13 @@ function jumpTolink(event) {
function playVideo(event) { function playVideo(event) {
const id = event.data.id; const id = event.data.id;
$('#' + id)[0].play(); if (id == 1) {
video1.play()
} else if (id == 2) {
video2.play()
} else if (id == 3) {
video3.play()
}
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment