clean up log
This commit is contained in:
parent
5dd7ce2f6a
commit
11d74e9d6f
|
@ -3,7 +3,6 @@ var GLOBAL_VOLUME;
|
||||||
let mediaElements = [];
|
let mediaElements = [];
|
||||||
|
|
||||||
document.addEventListener("DOMContentLoaded", () => {
|
document.addEventListener("DOMContentLoaded", () => {
|
||||||
console.log("Loaded");
|
|
||||||
|
|
||||||
mediaElements = Array.from(document.getElementsByTagName("audio"));
|
mediaElements = Array.from(document.getElementsByTagName("audio"));
|
||||||
mediaElements.push(...Array.from(document.getElementsByTagName("video")));
|
mediaElements.push(...Array.from(document.getElementsByTagName("video")));
|
||||||
|
@ -11,7 +10,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
||||||
return el.controls;
|
return el.controls;
|
||||||
});
|
});
|
||||||
|
|
||||||
console.log(`Watching: ${mediaElements.length} media elements`);
|
console.log(`AVControlSync: Watching ${mediaElements.length} media elements`);
|
||||||
mediaElements.forEach((el) => {
|
mediaElements.forEach((el) => {
|
||||||
el.addEventListener("volumechange", (e) => {
|
el.addEventListener("volumechange", (e) => {
|
||||||
updateGlobalVolume(e.target.volume);
|
updateGlobalVolume(e.target.volume);
|
||||||
|
|
Loading…
Reference in a new issue