1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

use new script format

This commit is contained in:
Luke Pulverenti 2013-04-10 15:33:19 -04:00
parent 42acb4ae14
commit d198b2e10b
3 changed files with 706 additions and 705 deletions

View file

@ -193,11 +193,10 @@
}
self.canPlay = function (item) {
var media;
if (item.MediaType === "Video") {
var media = testableVideoElement;
media = testableVideoElement;
if (media.canPlayType) {
return media.canPlayType('video/mp4').replace(/no/, '') || media.canPlayType('video/mp2t').replace(/no/, '') || media.canPlayType('video/webm').replace(/no/, '') || media.canPlayType('application/x-mpegURL').replace(/no/, '') || media.canPlayType('video/ogv').replace(/no/, '');
@ -207,9 +206,7 @@
}
if (item.MediaType === "Audio") {
var media = testableAudioElement;
media = testableAudioElement;
if (media.canPlayType) {
return media.canPlayType('audio/mpeg').replace(/no/, '') || media.canPlayType('audio/webm').replace(/no/, '') || media.canPlayType('audio/aac').replace(/no/, '') || media.canPlayType('audio/ogg').replace(/no/, '');