Update event.js

pull/4159/head
IgorA100 2024-10-01 13:32:12 +03:00 committed by GitHub
parent f530d096a6
commit 0d3205c9eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 3 deletions

View File

@ -1654,9 +1654,10 @@ function initPage() {
// Event listener for double click
//var elStream = document.querySelectorAll('[id ^= "liveStream"], [id ^= "evtStream"]');
// When using video.js, the document will have both #videoobj and #wrapperEventVideo, but we only need #videoobj
const elStreamVideoJS = document.querySelectorAll("[id = 'videoobj']");
const elStream = (elStreamVideoJS.length > 0) ? elStreamVideoJS : document.querySelectorAll("[id = 'wrapperEventVideo']");
//// When using video.js, the document will have both #videoobj and #wrapperEventVideo, but we only need #videoobj
//const elStreamVideoJS = document.querySelectorAll("[id = 'videoobj']");
//const elStream = (elStreamVideoJS.length > 0) ? elStreamVideoJS : document.querySelectorAll("[id = 'wrapperEventVideo']");
const elStream = document.querySelectorAll("[id = 'wrapperEventVideo']");
Array.prototype.forEach.call(elStream, (el) => {
el.addEventListener('touchstart', doubleTouch);
el.addEventListener('dblclick', doubleClickOnStream);