Remove unsupported formats from quality selector

This commit is contained in:
Omar Roth 2018-04-10 21:49:10 -05:00
parent 2a4b643539
commit 20c0bff96d
1 changed files with 9 additions and 0 deletions

View File

@ -103,6 +103,15 @@ function toggle_comments(target) {
body.style.display = '';
}
};
var currentSources = player.currentSources();
for ( var i = 0; i < currentSources.length; i++ ) {
if (player.canPlayType(currentSources[i]["type"].split(";")[0]) === "") {
currentSources.splice(i);
}
}
player.src(currentSources);
</script>
<div class="h-box">