SimpleTaskSystem.Web/Content/theme/Js/jquery-plugin/mediaelement/2.13.1/mediaelement-and-player.js
(完整代码) 67KBdefine("jquery-plugin/mediaelement/2.13.1/mediaelement-and-player",["$"],function(a){var b=a("$"),c=c||{};c.version="2.13.1",c.meIndex=0,c.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},c.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='<a href="'+this.escapeHTML(a)+'">x</a>',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e<a.length;e++)d=1,e>0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(c.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?c.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},c.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f<h.length;f++)h[f]=parseInt(h[f].match(/\d+/),10)}else if("undefined"!=typeof window.ActiveXObject)try{g=new ActiveXObject(c),g&&(h=d(g))}catch(i){}return h}},c.PluginDetector.addPlugin("flash","Shockwave Flash","application/x-shockwave-flash","ShockwaveFlash.ShockwaveFlash",function(a){var b=[],c=a.GetVariable("$version");return c&&(c=c.split(" ")[1].split(","),b=[parseInt(c[0],10),parseInt(c[1],10),parseInt(c[2],10)]),b}),c.PluginDetector.addPlugin("silverlight","Silverlight Plug-In","application/x-silverlight-2","AgControl.AgControl",function(a){var b=[0,0,0,0],c=function(a,b,c,d){for(;a.isVersionSupported(b[0]+"."+b[1]+"."+b[2]+"."+b[3]);)b[c]+=d;b[c]-=d};return c(a,b,0,1),c(a,b,1,1),c(a,b,2,1e4),c(a,b,2,1e3),c(a,b,2,100),c(a,b,2,10),c(a,b,2,1),c(a,b,3,1),b}),c.MediaFeatures={init:function(){var a,b,d=this,e=document,f=c.PluginDetector.nav,g=c.PluginDetector.ua.toLowerCase(),h=["source","track","audio","video"];d.isiPad=null!==g.match(/ipad/i),d.isiPhone=null!==g.match(/iphone/i),d.isiOS=d.isiPhone||d.isiPad,d.isAndroid=null!==g.match(/android/i),d.isBustedAndroid=null!==g.match(/android 2\.[12]/),d.isBustedNativeHTTPS="https:"===location.protocol&&(null!==g.match(/android [12]\./)||null!==g.match(/macintosh.* version.* safari/)),d.isIE=null!==f.appName.toLowerCase().match(/trident/gi),d.isChrome=null!==g.match(/chrome/gi),d.isFirefox=null!==g.match(/firefox/gi),d.isWebkit=null!==g.match(/webkit/gi),d.isGecko=null!==g.match(/gecko/gi)&&!d.isWebkit&&!d.isIE,d.isOpera=null!==g.match(/opera/gi),d.hasTouch="ontouchstart"in window,d.svg=!!document.createElementNS&&!!document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect;for(a=0;a<h.length;a++)b=document.createElement(h[a]);d.supportsMediaTag="undefined"!=typeof b.canPlayType||d.isBustedAndroid;try{b.canPlayType("video/mp4")}catch(i){d.supportsMediaTag=!1}d.hasSemiNativeFullScreen="undefined"!=typeof b.webkitEnterFullscreen,d.hasNativeFullscreen="undefined"!=typeof b.requestFullscreen,d.hasWebkitNativeFullScreen="undefined"!=typeof b.webkitRequestFullScreen,d.hasMozNativeFullScreen="undefined"!=typeof b.mozRequestFullScreen,d.hasMsNativeFullScreen="undefined"!=typeof b.msRequestFullscreen,d.hasTrueNativeFullScreen=d.hasWebkitNativeFullScreen||d.hasMozNativeFullScreen||d.hasMsNativeFullScreen,d.nativeFullScreenEnabled=d.hasTrueNativeFullScreen,d.hasMozNativeFullScreen?d.nativeFullScreenEnabled=document.mozFullScreenEnabled:d.hasMsNativeFullScreen&&(d.nativeFullScreenEnabled=document.msFullscreenEnabled),d.isChrome&&(d.hasSemiNativeFullScreen=!1),d.hasTrueNativeFullScreen&&(d.fullScreenEventName="",d.hasWebkitNativeFullScreen?d.fullScreenEventName="webkitfullscreenchange":d.hasMozNativeFullScreen?d.fullScreenEventName="mozfullscreenchange":d.hasMsNativeFullScreen&&(d.fullScreenEventName="MSFullscreenChange"),d.isFullScreen=function(){return b.mozRequestFullScreen?e.mozFullScreen:b.webkitRequestFullScreen?e.webkitIsFullScreen:b.hasMsNativeFullScreen?null!==e.msFullscreenElement:void 0},d.requestFullScreen=function(a){d.hasWebkitNativeFullScreen?a.webkitRequestFullScreen():d.hasMozNativeFullScreen?a.mozRequestFullScreen():d.hasMsNativeFullScreen&&a.msRequestFullscreen()},d.cancelFullScreen=function(){d.hasWebkitNativeFullScreen?document.webkitCancelFullScreen():d.hasMozNativeFullScreen?document.mozCancelFullScreen():d.hasMsNativeFullScreen&&document.msExitFullscreen()}),d.hasSemiNativeFullScreen&&g.match(/mac os x 10_5/i)&&(d.hasNativeFullScreen=!1,d.hasSemiNativeFullScreen=!1)}},c.MediaFeatures.init(),c.HtmlMediaElement={pluginType:"native",isFullScreen:!1,setCurrentTime:function(a){this.currentTime=a},setMuted:function(a){this.muted=a},setVolume:function(a){this.volume=a},stop:function(){this.pause()},setSrc:function(a){for(var b=this.getElementsByTagName("source");b.length>0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c<a.length;c++)if(d=a[c],this.canPlayType(d.type)){this.src=d.src;break}}},setVideoSize:function(a,b){this.width=a,this.height=b}},c.PluginMediaElement=function(a,b,c){this.id=a,this.pluginType=b,this.src=c,this.events={},this.attributes={}},c.PluginMediaElement.prototype={pluginElement:null,pluginType:"",isFullScreen:!1,playbackRate:-1,defaultPlaybackRate:-1,seekable:[],played:[],paused:!0,ended:!1,seeking:!1,duration:0,error:null,tagName:"",muted:!1,volume:1,currentTime:0,play:function(){null!=this.pluginApi&&("youtube"==this.pluginType?this.pluginApi.playVideo():this.pluginApi.playMedia(),this.paused=!1)},load:function(){null!=this.pluginApi&&("youtube"==this.pluginType||this.pluginApi.loadMedia(),this.paused=!1)},pause:function(){null!=this.pluginApi&&("youtube"==this.pluginType?this.pluginApi.pauseVideo():this.pluginApi.pauseMedia(),this.paused=!0)},stop:function(){null!=this.pluginApi&&("youtube"==this.pluginType?this.pluginApi.stopVideo():this.pluginApi.stopMedia(),this.paused=!0)},canPlayType:function(a){var b,d,e,f=c.plugins[this.pluginType];for(b=0;b<f.length;b++)if(e=f[b],c.PluginDetector.hasPluginVersion(this.pluginType,e.version))for(d=0;d<e.types.length;d++)if(a==e.types[d])return"probably";return""},positionFullscreenButton:function(a,b,c){null!=this.pluginApi&&this.pluginApi.positionFullscreenButton&&this.pluginApi.positionFullscreenButton(Math.floor(a),Math.floor(b),c)},hideFullscreenButton:function(){null!=this.pluginApi&&this.pluginApi.hideFullscreenButton&&this.pluginApi.hideFullscreenButton()},setSrc:function(a){if("string"==typeof a)this.pluginApi.setSrc(c.Utility.absolutizeUrl(a)),this.src=c.Utility.absolutizeUrl(a);else{var b,d;for(b=0;b<a.length;b++)if(d=a[b],this.canPlayType(d.type)){this.pluginApi.setSrc(c.Utility.absolutizeUrl(d.src)),this.src=c.Utility.absolutizeUrl(a);break}}},setCurrentTime:function(a){null!=this.pluginApi&&("youtube"==this.pluginType?this.pluginApi.seekTo(a):this.pluginApi.setCurrentTime(a),this.currentTime=a)},setVolume:function(a){null!=this.pluginApi&&("youtube"==this.pluginType?this.pluginApi.setVolume(100*a):this.pluginApi.setVolume(a),this.volume=a)},setMuted:function(a){null!=this.pluginApi&&("youtube"==this.pluginType?(a?this.pluginApi.mute():this.pluginApi.unMute(),this.muted=a,this.dispatchEvent("volumechange")):this.pluginApi.setMuted(a),this.muted=a)},setVideoSize:function(a,b){this.pluginElement.style&&(this.pluginElement.style.width=a+"px",this.pluginElement.style.height=b+"px"),null!=this.pluginApi&&this.pluginApi.setVideoSize&&this.pluginApi.setVideoSize(a,b)},setFullscreen:function(a){null!=this.pluginApi&&this.pluginApi.setFullscreen&&this.pluginApi.setFullscreen(a)},enterFullScreen:function(){null!=this.pluginApi&&this.pluginApi.setFullscreen&&this.setFullscreen(!0)},exitFullScreen:function(){null!=this.pluginApi&&this.pluginApi.setFullscreen&&this.setFullscreen(!1)},addEventListener:function(a,b){this.events[a]=this.events[a]||[],this.events[a].push(b)},removeEventListener:function(a,b){if(!a)return this.events={},!0;var c=this.events[a];if(!c)return!0;if(!b)return this.events[a]=[],!0;for(i=0;i<c.length;i++)if(c[i]===b)return this.events[a].splice(i,1),!0;return!1},dispatchEvent:function(a){var b,c,d=this.events[a];if(d)for(c=Array.prototype.slice.call(arguments,1),b=0;b<d.length;b++)d[b].apply(null,c)},hasAttribute:function(a){return a in this.attributes},removeAttribute:function(a){delete this.attributes[a]},getAttribute:function(a){return this.hasAttribute(a)?this.attributes[a]:""},setAttribute:function(a,b){this.attributes[a]=b},remove:function(){c.Utility.removeSwf(this.pluginElement.id),c.MediaPluginBridge.unregisterPluginElement(this.pluginElement.id)}},c.MediaPluginBridge={pluginMediaElements:{},htmlMediaElements:{},registerPluginElement:function(a,b,c){this.pluginMediaElements[a]=b,this.htmlMediaElements[a]=c},unregisterPluginElement:function(a){delete this.pluginMediaElements[a],delete this.htmlMediaElements[a]},initPlugin:function(a){var b=this.pluginMediaElements[a],c=this.htmlMediaElements[a];if(b){switch(b.pluginType){case"flash":b.pluginElement=b.pluginApi=document.getElementById(a);break;case"silverlight":b.pluginElement=document.getElementById(b.id),b.pluginApi=b.pluginElement.Content.MediaElementJS}null!=b.pluginApi&&b.success&&b.success(b,c)}},fireEvent:function(a,b,c){var d,e,f,g=this.pluginMediaElements[a];if(g){d={type:b,target:g};for(e in c)g[e]=c[e],d[e]=c[e];f=c.bufferedTime||0,d.target.buffered=d.buffered={start:function(){return 0},end:function(){return f},length:1},g.dispatchEvent(d.type,d)}}},c.MediaElementDefaults={mode:"auto",plugins:["flash","silverlight","youtube","vimeo"],enablePluginDebug:!1,httpsBasicAuthSite:!1,type:"",pluginPath:a.resolve("./"),flashName:"flashmediaelement.swf",flashStreamer:"",enablePluginSmoothing:!1,enablePseudoStreaming:!1,pseudoStreamingStartQueryParam:"start",silverlightName:"silverlightmediaelement.xap",defaultVideoWidth:480,defaultVideoHeight:270,pluginWidth:-1,pluginHeight:-1,pluginVars:[],timerRate:250,startVolume:.8,success:function(){},error:function(){}},c.MediaElement=function(a,b){return c.HtmlMediaElementShim.create(a,b)},c.HtmlMediaElementShim={create:function(a,b){var d,e,f=c.MediaElementDefaults,g="string"==typeof a?document.getElementById(a):a,h=g.tagName.toLowerCase(),i="audio"===h||"video"===h,j=i?g.getAttribute("src"):g.getAttribute("href"),k=g.getAttribute("poster"),l=g.getAttribute("autoplay"),m=g.getAttribute("preload"),n=g.getAttribute("controls");for(e in b)f[e]=b[e];return j="undefined"==typeof j||null===j||""==j?null:j,k="undefined"==typeof k||null===k?"":k,m="undefined"==typeof m||null===m||"false"===m?"none":m,l=!("undefined"==typeof l||null===l||"false"===l),n=!("undefined"==typeof n||null===n||"false"===n),d=this.determinePlayback(g,f,c.MediaFeatures.supportsMediaTag,i,j),d.url=null!==d.url?c.Utility.absolutizeUrl(d.url):"","native"==d.method?(c.MediaFeatures.isBustedAndroid&&(g.src=d.url,g.addEventListener("click",function(){g.play()},!1)),this.updateNative(d,f,l,m)):""!==d.method?this.createPlugin(d,f,k,l,m,n):(this.createErrorMessage(d,f,k),this)},determinePlayback:function(a,b,d,e,f){var g,h,i,j,k,l,m,n,o,p,q,r=[],s={method:"",url:"",htmlMediaElement:a,isVideo:"audio"!=a.tagName.toLowerCase()};if("undefined"!=typeof b.type&&""!==b.type)if("string"==typeof b.type)r.push({type:b.type,url:f});else for(g=0;g<b.type.length;g++)r.push({type:b.type[g],url:f});else if(null!==f)l=this.formatType(f,a.getAttribute("type")),r.push({type:l,url:f});else for(g=0;g<a.childNodes.length;g++)k=a.childNodes[g],1==k.nodeType&&"source"==k.tagName.toLowerCase()&&(f=k.getAttribute("src"),l=this.formatType(f,k.getAttribute("type")),q=k.getAttribute("media"),(!q||!window.matchMedia||window.matchMedia&&window.matchMedia(q).matches)&&r.push({type:l,url:f}));if(!e&&r.length>0&&null!==r[0].url&&this.getTypeFromFile(r[0].url).indexOf("audio")>-1&&(s.isVideo=!1),c.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!d||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||c.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(e||(p=document.createElement(s.isVideo?"video":"audio"),a.parentNode.insertBefore(p,a),a.style.display="none",s.htmlMediaElement=a=p),g=0;g<r.length;g++)if(""!==a.canPlayType(r[g].type).replace(/no/,"")||""!==a.canPlayType(r[g].type.replace(/mp3/,"mpeg")).replace(/no/,"")){s.method="native",s.url=r[g].url;break}if("native"===s.method&&(null!==s.url&&(a.src=s.url),"auto_plugin"!==b.mode))return s}if("auto"===b.mode||"auto_plugin"===b.mode||"shim"===b.mode)for(g=0;g<r.length;g++)for(l=r[g].type,h=0;h<b.plugins.length;h++)for(m=b.plugins[h],n=c.plugins[m],i=0;i<n.length;i++)if(o=n[i],null==o.version||c.PluginDetector.hasPluginVersion(m,o.version))for(j=0;j<o.types.length;j++)if(l==o.types[j])return s.method=m,s.url=r[g].url,s;return"auto_plugin"===b.mode&&"native"===s.method?s:(""===s.method&&r.length>0&&(s.url=r[0].url),s)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,d){var e=a.htmlMediaElement,f=document.createElement("div");f.className="me-cannotplay";try{f.style.width=e.width+"px",f.style.height=e.height+"px"}catch(g){}f.innerHTML=b.customError?b.customError:""!==d?'<a href="'+a.url+'"><img src="'+d+'" width="100%" height="100%" /></a>':'<a href="'+a.url+'"><span>'+c.i18n.t("Download File")+"</span></a>",e.parentNode.insertBefore(f,e),e.style.display="none",b.error(e)},createPlugin:function(a,b,d,e,f,g){var h,i,j,k=a.htmlMediaElement,l=1,m=1,n="me_"+a.method+"_"+c.meIndex++,o=new c.PluginMediaElement(n,a.method,a.url),p=document.createElement("div");o.tagName=k.tagName;for(var q=0;q<k.attributes.length;q++){var r=k.attributes[q];1==r.specified&&o.setAttribute(r.name,r.value)}for(i=k.parentNode;null!==i&&"body"!=i.tagName.toLowerCase();){if("p"==i.parentNode.tagName.toLowerCase()){i.parentNode.parentNode.insertBefore(i,i.parentNode);break}i=i.parentNode}switch(a.isVideo?(l=b.pluginWidth>0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==k.getAttribute("width")?k.getAttribute("width"):b.defaultVideoWidth,m=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==k.getAttribute("height")?k.getAttribute("height"):b.defaultVideoHeight,l=c.Utility.encodeUrl(l),m=c.Utility.encodeUrl(m)):b.enablePluginDebug&&(l=320,m=240),o.success=b.success,c.MediaPluginBridge.registerPluginElement(n,o,k),p.className="me-plugin",p.id=n+"_container",a.isVideo?k.parentNode.insertBefore(p,k):document.body.insertBefore(p,document.body.childNodes[0]),j=["id="+n,"isvideo="+(a.isVideo?"true":"false"),"autoplay="+(e?"true":"false"),"preload="+f,"width="+l,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+m,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&("flash"==a.method?j.push("file="+c.Utility.encodeUrl(a.url)):j.push("file="+a.url)),b.enablePluginDebug&&j.push("debug=true"),b.enablePluginSmoothing&&j.push("smoothing=true"),b.enablePseudoStreaming&&j.push("pseudostreaming=true"),g&&j.push("controls=true"),b.pluginVars&&(j=j.concat(b.pluginVars)),a.method){case"silverlight":p.innerHTML='<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" id="'+n+'" name="'+n+'" width="'+l+'" height="'+m+'" class="mejs-shim">'+'<param name="initParams" value="'+j.join(",")+'" />'+'<param name="windowless" value="true" />'+'<param name="background" value="black" />'+'<param name="minRuntimeVersion" value="3.0.0.0" />'+'<param name="autoUpgrade" value="true" />'+'<param name="source" value="'+b.pluginPath+b.silverlightName+'" />'+"</object>";break;case"flash":c.MediaFeatures.isIE?(h=document.createElement("div"),p.appendChild(h),h.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" id="'+n+'" width="'+l+'" height="'+m+'" class="mejs-shim">'+'<param name="movie" value="'+b.pluginPath+b.flashName+"?x="+new Date+'" />'+'<param name="flashvars" value="'+j.join("&")+'" />'+'<param name="quality" value="high" />'+'<param name="bgcolor" value="#000000" />'+'<param name="wmode" value="transparent" />'+'<param name="allowScriptAccess" value="always" />'+'<param name="allowFullScreen" value="true" />'+"</object>"):p.innerHTML='<embed id="'+n+'" name="'+n+'" '+'play="true" '+'loop="false" '+'quality="high" '+'bgcolor="#000000" '+'wmode="transparent" '+'allowScriptAccess="always" '+'allowFullScreen="true" '+'type="application/x-shockwave-flash" pluginspage="//www.macromedia.com/go/getflashplayer" '+'src="'+b.pluginPath+b.flashName+'" '+'flashvars="'+j.join("&")+'" '+'width="'+l+'" '+'height="'+m+'" '+'class="mejs-shim"></embed>';break;case"youtube":var s=a.url.substr(a.url.lastIndexOf("=")+1);youtubeSettings={container:p,containerId:p.id,pluginMediaElement:o,pluginId:n,videoId:s,height:m,width:l},c.PluginDetector.hasPluginVersion("flash",[10,0,0])?c.YouTubeApi.createFlash(youtubeSettings):c.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":o.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),p.innerHTML='<iframe src="http://player.vimeo.com/video/'+o.vimeoid+'?portrait=0&byline=0&title=0" width="'+l+'" height="'+m+'" frameborder="0" class="mejs-shim"></iframe>'}return k.style.display="none",k.removeAttribute("autoplay"),o},updateNative:function(a,b){var d,e=a.htmlMediaElement;for(d in c.HtmlMediaElement)e[d]=c.HtmlMediaElement[d];return b.success(e,e),e}},c.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,d=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=d,c.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){c.YouTubeApi.createEvent(d,b,"timeupdate")},250)},onStateChange:function(a){c.YouTubeApi.handleStateChange(a.data,d,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,d="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";c.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" id="'+a.pluginId+'" width="'+a.width+'" height="'+a.height+'" class="mejs-shim">'+'<param name="movie" value="'+d+'" />'+'<param name="wmode" value="transparent" />'+'<param name="allowScriptAccess" value="always" />'+'<param name="allowFullScreen" value="true" />'+"</object>"):a.container.innerHTML='<object type="application/x-shockwave-flash" id="'+a.pluginId+'" data="'+d+'" '+'width="'+a.width+'" height="'+a.height+'" style="visibility: visible; " class="mejs-shim">'+'<param name="allowScriptAccess" value="always">'+'<param name="wmode" value="transparent">'+"</object>"},flashReady:function(a){var b=this.flashPlayers[a],d=document.getElementById(a),e=b.pluginMediaElement;e.pluginApi=e.pluginElement=d,c.MediaPluginBridge.initPlugin(a),d.cueVideoById(b.videoId);var f=b.containerId+"_callback";window[f]=function(a){c.YouTubeApi.handleStateChange(a,d,e)},d.addEventListener("onStateChange",f),setInterval(function(){c.YouTubeApi.createEvent(d,e,"timeupdate")},250)},handleStateChange:function(a,b,d){switch(a){case-1:d.paused=!0,d.ended=!0,c.YouTubeApi.createEvent(b,d,"loadedmetadata");break;case 0:d.paused=!1,d.ended=!0,c.YouTubeApi.createEvent(b,d,"ended");break;case 1:d.paused=!1,d.ended=!1,c.YouTubeApi.createEvent(b,d,"play"),c.YouTubeApi.createEvent(b,d,"playing");break;case 2:d.paused=!0,d.ended=!1,c.YouTubeApi.createEvent(b,d,"pause");break;case 3:c.YouTubeApi.createEvent(b,d,"progress");break;case 5:}}},window.mejs=c,window.MediaElement=c.MediaElement,function(a,b){"use strict";var c={locale:{language:"",strings:{}},methods:{}};c.locale.getLanguage=function(){return c.locale.language||navigator.language},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.locale.INIT_LANGUAGE=c.locale.getLanguage(),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.formatString=function(a,b){for(var d in b){switch(d.charAt(0)){case"@":b[d]=c.methods.checkPlain(b[d]);break;case"!":break;case"%":default:b[d]='<em class="placeholder">'+c.methods.checkPlain(b[d])+"</em>"}a=a.replace(d,b[d])}return a},c.methods.t=function(a,b,d){return c.locale.strings&&c.locale.strings[d.context]&&c.locale.strings[d.context][a]&&(a=c.locale.strings[d.context][a]),b&&(a=c.methods.formatString(a,b)),a},c.t=function(a,b,d){if("string"==typeof a&&a.length>0){var e=c.locale.getLanguage();return d=d||{context:e},c.methods.t(a,b,d)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,c),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(c.i18n.locale.strings),function(a){"use strict";a.de={Fullscreen:"Vollbild","Go Fullscreen":"Vollbild an","Turn off Fullscreen":"Vollbild aus",Close:"Schließen"}}(c.i18n.locale.strings),function(a){"use strict";a.zh={Fullscreen:"全螢幕","Go Fullscreen":"全屏模式","Turn off Fullscreen":"退出全屏模式",Close:"關閉"}}(c.i18n.locale.strings),"undefined"!=typeof b?c.$=b:"undefined"!=typeof ender&&(c.$=ender),function(a){c.MepDefaults={poster:"",showPosterWhenEnded:!1,defaultVideoWidth:480,defaultVideoHeight:270,videoWidth:-1,videoHeight:-1,defaultAudioWidth:400,defaultAudioHeight:30,defaultSeekBackwardInterval:function(a){return.05*a.duration},defaultSeekForwardInterval:function(a){return.05*a.duration},audioWidth:-1,audioHeight:-1,startVolume:.8,loop:!1,autoRewind:!0,enableAutosize:!0,alwaysShowHours:!1,showTimecodeFrameCount:!1,framesPerSecond:25,autosizeProgress:!0,alwaysShowControls:!1,hideVideoControlsOnLoad:!1,clickToPlayPause:!0,iPadUseNativeControls:!1,iPhoneUseNativeControls:!1,AndroidUseNativeControls:!1,features:["playpause","current","progress","duration","tracks","volume","fullscreen"],isVideo:!0,enableKeyboard:!0,pauseOtherPlayers:!0,keyActions:[{keys:[32,179],action:function(a,b){b.paused||b.ended?b.play():b.pause()}},{keys:[38],action:function(a,b){var c=Math.min(b.volume+.1,1);b.setVolume(c)}},{keys:[40],action:function(a,b){var c=Math.max(b.volume-.1,0);b.setVolume(c)}},{keys:[37,227],action:function(a,b){if(!isNaN(b.duration)&&b.duration>0){a.isVideo&&(a.showControls(),a.startControlsTimer());var c=Math.max(b.currentTime-a.options.defaultSeekBackwardInterval(b),0);b.setCurrentTime(c)}}},{keys:[39,228],action:function(a,b){if(!isNaN(b.duration)&&b.duration>0){a.isVideo&&(a.showControls(),a.startControlsTimer());var c=Math.min(b.currentTime+a.options.defaultSeekForwardInterval(b),b.duration);b.setCurrentTime(c)}}},{keys:[70],action:function(a){"undefined"!=typeof a.enterFullScreen&&(a.isFullScreen?a.exitFullScreen():a.enterFullScreen())}}]},c.mepIndex=0,c.players={},c.MediaElementPlayer=function(b,d){if(!(this instanceof c.MediaElementPlayer))return new c.MediaElementPlayer(b,d);var e=this;return e.$media=e.$node=a(b),e.node=e.media=e.$media[0],"undefined"!=typeof e.node.player?e.node.player:(e.node.player=e,"undefined"==typeof d&&(d=e.$node.data("mejsoptions")),e.options=a.extend({},c.MepDefaults,d),e.id="mep_"+c.mepIndex++,c.players[e.id]=e,e.init(),e)},c.MediaElementPlayer.prototype={hasFocus:!1,controlsAreVisible:!0,init:function(){var b=this,d=c.MediaFeatures,e=a.extend(!0,{},b.options,{success:function(a,c){b.meReady(a,c)},error:function(a){b.handleError(a)}}),f=b.media.tagName.toLowerCase();if(b.isDynamic="audio"!==f&&"video"!==f,b.isVideo=b.isDynamic?b.options.isVideo:"audio"!==f&&b.options.isVideo,d.isiPad&&b.options.iPadUseNativeControls||d.isiPhone&&b.options.iPhoneUseNativeControls)b.$media.attr("controls","controls"),d.isiPad&&null!==b.media.getAttribute("autoplay")&&(b.media.load(),b.media.play());else if(d.isAndroid&&b.options.AndroidUseNativeControls);else{if(b.$media.removeAttr("controls"),b.container=a('<div id="'+b.id+'" class="mejs-container '+(c.MediaFeatures.svg?"svg":"no-svg")+'">'+'<div class="mejs-inner">'+'<div class="mejs-mediaelement"></div>'+'<div class="mejs-layers"></div>'+'<div class="mejs-controls"></div>'+'<div class="mejs-clear"></div>'+"</div>"+"</div>").addClass(b.$media[0].className).insertBefore(b.$media),b.container.addClass((d.isAndroid?"mejs-android ":"")+(d.isiOS?"mejs-ios ":"")+(d.isiPad?"mejs-ipad ":"")+(d.isiPhone?"mejs-iphone ":"")+(b.isVideo?"mejs-video ":"mejs-audio ")),d.isiOS){var g=b.$media.clone();b.container.find(".mejs-mediaelement").append(g),b.$media.remove(),b.$node=b.$media=g,b.node=b.media=g[0]}else b.container.find(".mejs-mediaelement").append(b.$media);b.controls=b.container.find(".mejs-controls"),b.layers=b.container.find(".mejs-layers");var h=b.isVideo?"video":"audio",i=h.substring(0,1).toUpperCase()+h.substring(1);b.width=b.options[h+"Width"]>0||b.options[h+"Width"].toString().indexOf("%")>-1?b.options[h+"Width"]:""!==b.media.style.width&&null!==b.media.style.width?b.media.style.width:null!==b.media.getAttribute("width")?b.$media.attr("width"):b.options["default"+i+"Width"],b.height=b.options[h+"Height"]>0||b.options[h+"Height"].toString().indexOf("%")>-1?b.options[h+"Height"]:""!==b.media.style.height&&null!==b.media.style.height?b.media.style.height:null!==b.$media[0].getAttribute("height")?b.$media.attr("height"):b.options["default"+i+"Height"],b.setPlayerSize(b.width,b.height),e.pluginWidth=b.width,e.pluginHeight=b.height}c.MediaElement(b.$media[0],e),"undefined"!=typeof b.container&&b.controlsAreVisible&&b.container.trigger("controlsshown")},showControls:function(a){var b=this;a="undefined"==typeof a||a,b.controlsAreVisible||(a?(b.controls.css("visibility","visible").stop(!0,!0).fadeIn(200,function(){b.controlsAreVisible=!0,b.container.trigger("controlsshown")}),b.container.find(".mejs-control").css("visibility","visible").stop(!0,!0).fadeIn(200,function(){b.controlsAreVisible=!0})):(b.controls.css("visibility","visible").css("display","block"),b.container.find(".mejs-control").css("visibility","visible").css("display","block"),b.controlsAreVisible=!0,b.container.trigger("controlsshown")),b.setControlsSize())},hideControls:function(b){var c=this;b="undefined"==typeof b||b,c.controlsAreVisible&&!c.options.alwaysShowControls&&(b?(c.controls.stop(!0,!0).fadeOut(200,function(){a(this).css("visibility","hidden").css("display","block"),c.controlsAreVisible=!1,c.container.trigger("controlshidden")}),c.container.find(".mejs-control").stop(!0,!0).fadeOut(200,function(){a(this).css("visibility","hidden").css("display","block")})):(c.controls.css("visibility","hidden").css("display","block"),c.container.find(".mejs-control").css("visibility","hidden").css("display","block"),c.controlsAreVisible=!1,c.container.trigger("controlshidden")))},controlsTimer:null,startControlsTimer:function(a){var b=this;a="undefined"!=typeof a?a:1500,b.killControlsTimer("start"),b.controlsTimer=setTimeout(function(){b.hideControls(),b.killControlsTimer("hide")},a)},killControlsTimer:function(){var a=this;null!==a.controlsTimer&&(clearTimeout(a.controlsTimer),delete a.controlsTimer,a.controlsTimer=null)},controlsEnabled:!0,disableControls:function(){var a=this;a.killControlsTimer(),a.hideControls(!1),this.controlsEnabled=!1},enableControls:function(){var a=this;a.showControls(!1),a.controlsEnabled=!0},meReady:function(a,b){var d,e,f=this,g=c.MediaFeatures,h=b.getAttribute("autoplay"),i=!("undefined"==typeof h||null===h||"false"===h);if(!f.created){if(f.created=!0,f.media=a,f.domNode=b,!(g.isAndroid&&f.options.AndroidUseNativeControls||g.isiPad&&f.options.iPadUseNativeControls||g.isiPhone&&f.options.iPhoneUseNativeControls)){f.buildposter(f,f.controls,f.layers,f.media),f.buildkeyboard(f,f.controls,f.layers,f.media),f.buildoverlays(f,f.controls,f.layers,f.media),f.findTracks();for(d in f.options.features)if(e=f.options.features[d],f["build"+e])try{f["build"+e](f,f.controls,f.layers,f.media)}catch(j){}f.container.trigger("controlsready"),f.setPlayerSize(f.width,f.height),f.setControlsSize(),f.isVideo&&(c.MediaFeatures.hasTouch?f.$media.bind("touchstart",function(){f.controlsAreVisible?f.hideControls(!1):f.controlsEnabled&&f.showControls(!1)}):(c.MediaElementPlayer.prototype.clickToPlayPauseCallback=function(){f.options.clickToPlayPause&&(f.media.paused?f.media.play():f.media.pause())
},f.media.addEventListener("click",f.clickToPlayPauseCallback,!1),f.container.bind("mouseenter mouseover",function(){f.controlsEnabled&&(f.options.alwaysShowControls||(f.killControlsTimer("enter"),f.showControls(),f.startControlsTimer(2500)))}).bind("mousemove",function(){f.controlsEnabled&&(f.controlsAreVisible||f.showControls(),f.options.alwaysShowControls||f.startControlsTimer(2500))}).bind("mouseleave",function(){f.controlsEnabled&&(f.media.paused||f.options.alwaysShowControls||f.startControlsTimer(1e3))})),f.options.hideVideoControlsOnLoad&&f.hideControls(!1),i&&!f.options.alwaysShowControls&&f.hideControls(),f.options.enableAutosize&&f.media.addEventListener("loadedmetadata",function(a){f.options.videoHeight<=0&&null===f.domNode.getAttribute("height")&&!isNaN(a.target.videoHeight)&&(f.setPlayerSize(a.target.videoWidth,a.target.videoHeight),f.setControlsSize(),f.media.setVideoSize(a.target.videoWidth,a.target.videoHeight))},!1)),a.addEventListener("play",function(){var a;for(a in c.players){var b=c.players[a];b.id==f.id||!f.options.pauseOtherPlayers||b.paused||b.ended||b.pause(),b.hasFocus=!1}f.hasFocus=!0},!1),f.media.addEventListener("ended",function(){if(f.options.autoRewind)try{f.media.setCurrentTime(0)}catch(a){}f.media.pause(),f.setProgressRail&&f.setProgressRail(),f.setCurrentRail&&f.setCurrentRail(),f.options.loop?f.media.play():!f.options.alwaysShowControls&&f.controlsEnabled&&f.showControls()},!1),f.media.addEventListener("loadedmetadata",function(){f.updateDuration&&f.updateDuration(),f.updateCurrent&&f.updateCurrent(),f.isFullScreen||(f.setPlayerSize(f.width,f.height),f.setControlsSize())},!1),setTimeout(function(){f.setPlayerSize(f.width,f.height),f.setControlsSize()},50),f.globalBind("resize",function(){f.isFullScreen||c.MediaFeatures.hasTrueNativeFullScreen&&document.webkitIsFullScreen||f.setPlayerSize(f.width,f.height),f.setControlsSize()}),"youtube"==f.media.pluginType&&f.container.find(".mejs-overlay-play").hide()}i&&"native"==a.pluginType&&(a.load(),a.play()),f.options.success&&("string"==typeof f.options.success?window[f.options.success](f.media,f.domNode,f):f.options.success(f.media,f.domNode,f))}},handleError:function(a){var b=this;b.controls.hide(),b.options.error&&b.options.error(a)},setPlayerSize:function(b,c){var d=this;if("undefined"!=typeof b&&(d.width=b),"undefined"!=typeof c&&(d.height=c),d.height.toString().indexOf("%")>0||"100%"===d.$node.css("max-width")||1===parseInt(d.$node.css("max-width").replace(/px/,""),10)/d.$node.offsetParent().width()||d.$node[0].currentStyle&&"100%"===d.$node[0].currentStyle.maxWidth){var e=d.isVideo?d.media.videoWidth&&d.media.videoWidth>0?d.media.videoWidth:d.options.defaultVideoWidth:d.options.defaultAudioWidth,f=d.isVideo?d.media.videoHeight&&d.media.videoHeight>0?d.media.videoHeight:d.options.defaultVideoHeight:d.options.defaultAudioHeight,g=d.container.parent().closest(":visible").width(),h=d.isVideo||!d.options.autosizeProgress?parseInt(g*f/e,10):f;"body"===d.container.parent()[0].tagName.toLowerCase()&&(g=a(window).width(),h=a(window).height()),0!=h&&0!=g&&(d.container.width(g).height(h),d.$media.add(d.container.find(".mejs-shim")).width("100%").height("100%"),d.isVideo&&d.media.setVideoSize&&d.media.setVideoSize(g,h),d.layers.children(".mejs-layer").width("100%").height("100%"))}else d.container.width(d.width).height(d.height),d.layers.children(".mejs-layer").width(d.width).height(d.height);var i=d.layers.find(".mejs-overlay-play"),j=i.find(".mejs-overlay-button");i.height(d.container.height()-d.controls.height()),j.css("margin-top","-"+(j.height()/2-d.controls.height()/2).toString()+"px")},setControlsSize:function(){var b=this,c=0,d=0,e=b.controls.find(".mejs-time-rail"),f=b.controls.find(".mejs-time-total"),g=(b.controls.find(".mejs-time-current"),b.controls.find(".mejs-time-loaded"),e.siblings());b.options&&!b.options.autosizeProgress&&(d=parseInt(e.css("width"))),0!==d&&d||(g.each(function(){var b=a(this);"absolute"!=b.css("position")&&b.is(":visible")&&(c+=a(this).outerWidth(!0))}),d=b.controls.width()-c-(e.outerWidth(!0)-e.width())),e.width(d),f.width(d-(f.outerWidth(!0)-f.width())),b.setProgressRail&&b.setProgressRail(),b.setCurrentRail&&b.setCurrentRail()},buildposter:function(b,c,d,e){var f=this,g=a('<div class="mejs-poster mejs-layer"></div>').appendTo(d),h=b.$media.attr("poster");""!==b.options.poster&&(h=b.options.poster),""!==h&&null!=h?f.setPoster(h):g.hide(),e.addEventListener("play",function(){g.hide()},!1),b.options.showPosterWhenEnded&&b.options.autoRewind&&e.addEventListener("ended",function(){g.show()},!1)},setPoster:function(b){var c=this,d=c.container.find(".mejs-poster"),e=d.find("img");0==e.length&&(e=a('<img width="100%" height="100%" />').appendTo(d)),e.attr("src",b),d.css({"background-image":"url("+b+")"})},buildoverlays:function(b,d,e,f){var g=this;if(b.isVideo){var h=a('<div class="mejs-overlay mejs-layer"><div class="mejs-overlay-loading"><span></span></div></div>').hide().appendTo(e),i=a('<div class="mejs-overlay mejs-layer"><div class="mejs-overlay-error"></div></div>').hide().appendTo(e),j=a('<div class="mejs-overlay mejs-layer mejs-overlay-play"><div class="mejs-overlay-button"></div></div>').appendTo(e).click(function(){g.options.clickToPlayPause&&(f.paused?f.play():f.pause())});f.addEventListener("play",function(){j.hide(),h.hide(),d.find(".mejs-time-buffering").hide(),i.hide()},!1),f.addEventListener("playing",function(){j.hide(),h.hide(),d.find(".mejs-time-buffering").hide(),i.hide()},!1),f.addEventListener("seeking",function(){h.show(),d.find(".mejs-time-buffering").show()},!1),f.addEventListener("seeked",function(){h.hide(),d.find(".mejs-time-buffering").hide()},!1),f.addEventListener("pause",function(){c.MediaFeatures.isiPhone||j.show()},!1),f.addEventListener("waiting",function(){h.show(),d.find(".mejs-time-buffering").show()},!1),f.addEventListener("loadeddata",function(){h.show(),d.find(".mejs-time-buffering").show()},!1),f.addEventListener("canplay",function(){h.hide(),d.find(".mejs-time-buffering").hide()},!1),f.addEventListener("error",function(){h.hide(),d.find(".mejs-time-buffering").hide(),i.show(),i.find("mejs-overlay-error").html("Error loading this resource")},!1)}},buildkeyboard:function(b,c,d,e){var f=this;f.globalBind("keydown",function(a){if(b.hasFocus&&b.options.enableKeyboard)for(var c=0,d=b.options.keyActions.length;d>c;c++)for(var f=b.options.keyActions[c],g=0,h=f.keys.length;h>g;g++)if(a.keyCode==f.keys[g])return a.preventDefault(),f.action(b,e,a.keyCode),!1;return!0}),f.globalBind("click",function(c){0==a(c.target).closest(".mejs-container").length&&(b.hasFocus=!1)})},findTracks:function(){var b=this,c=b.$media.find("track");b.tracks=[],c.each(function(c,d){d=a(d),b.tracks.push({srclang:d.attr("srclang")?d.attr("srclang").toLowerCase():"",src:d.attr("src"),kind:d.attr("kind"),label:d.attr("label")||"",entries:[],isLoaded:!1})})},changeSkin:function(a){this.container[0].className="mejs-container "+a,this.setPlayerSize(this.width,this.height),this.setControlsSize()},play:function(){this.media.play()},pause:function(){try{this.media.pause()}catch(a){}},load:function(){this.media.load()},setMuted:function(a){this.media.setMuted(a)},setCurrentTime:function(a){this.media.setCurrentTime(a)},getCurrentTime:function(){return this.media.currentTime},setVolume:function(a){this.media.setVolume(a)},getVolume:function(){return this.media.volume},setSrc:function(a){this.media.setSrc(a)},remove:function(){var a,b,d=this;for(a in d.options.features)if(b=d.options.features[a],d["clean"+b])try{d["clean"+b](d)}catch(e){}d.isDynamic?d.$node.insertBefore(d.container):(d.$media.prop("controls",!0),d.$node.clone().show().insertBefore(d.container),d.$node.remove()),"native"!==d.media.pluginType&&d.media.remove(),delete c.players[d.id],d.container.remove(),d.globalUnbind(),delete d.node.player}},function(){function b(b,c){var e={d:[],w:[]};return a.each((b||"").split(" "),function(a,b){var f=b+"."+c;0===f.indexOf(".")?(e.d.push(f),e.w.push(f)):e[d.test(b)?"w":"d"].push(f)}),e.d=e.d.join(" "),e.w=e.w.join(" "),e}var d=/^((after|before)print|(before)?unload|hashchange|message|o(ff|n)line|page(hide|show)|popstate|resize|storage)\b/;c.MediaElementPlayer.prototype.globalBind=function(c,d,e){var f=this;c=b(c,f.id),c.d&&a(document).bind(c.d,d,e),c.w&&a(window).bind(c.w,d,e)},c.MediaElementPlayer.prototype.globalUnbind=function(c,d){var e=this;c=b(c,e.id),c.d&&a(document).unbind(c.d,d),c.w&&a(window).unbind(c.w,d)}}(),"undefined"!=typeof b&&(b.fn.mediaelementplayer=function(a){return a===!1?this.each(function(){var a=b(this).data("mediaelementplayer");a&&a.remove(),b(this).removeData("mediaelementplayer")}):this.each(function(){b(this).data("mediaelementplayer",new c.MediaElementPlayer(this,a))}),this}),a(document).ready(function(){a(".mejs-player").mediaelementplayer()}),window.MediaElementPlayer=c.MediaElementPlayer}(c.$),function(a){a.extend(c.MepDefaults,{playpauseText:c.i18n.t("Play/Pause")}),a.extend(MediaElementPlayer.prototype,{buildplaypause:function(b,c,d,e){var f=this,g=a('<div class="mejs-button mejs-playpause-button mejs-play" ><button type="button" aria-controls="'+f.id+'" title="'+f.options.playpauseText+'" aria-label="'+f.options.playpauseText+'"></button>'+"</div>").appendTo(c).click(function(a){return a.preventDefault(),e.paused?e.play():e.pause(),!1});e.addEventListener("play",function(){g.removeClass("mejs-play").addClass("mejs-pause")},!1),e.addEventListener("playing",function(){g.removeClass("mejs-play").addClass("mejs-pause")},!1),e.addEventListener("pause",function(){g.removeClass("mejs-pause").addClass("mejs-play")},!1),e.addEventListener("paused",function(){g.removeClass("mejs-pause").addClass("mejs-play")},!1)}})}(c.$),function(a){a.extend(c.MepDefaults,{stopText:"Stop"}),a.extend(MediaElementPlayer.prototype,{buildstop:function(b,d,e,f){var g=this;a('<div class="mejs-button mejs-stop-button mejs-stop"><button type="button" aria-controls="'+g.id+'" title="'+g.options.stopText+'" aria-label="'+g.options.stopText+'"></button>'+"</div>").appendTo(d).click(function(){f.paused||f.pause(),f.currentTime>0&&(f.setCurrentTime(0),f.pause(),d.find(".mejs-time-current").width("0px"),d.find(".mejs-time-handle").css("left","0px"),d.find(".mejs-time-float-current").html(c.Utility.secondsToTimeCode(0)),d.find(".mejs-currenttime").html(c.Utility.secondsToTimeCode(0)),e.find(".mejs-poster").show())})}})}(c.$),function(a){a.extend(MediaElementPlayer.prototype,{buildprogress:function(b,d,e,f){a('<div class="mejs-time-rail"><span class="mejs-time-total"><span class="mejs-time-buffering"></span><span class="mejs-time-loaded"></span><span class="mejs-time-current"></span><span class="mejs-time-handle"></span><span class="mejs-time-float"><span class="mejs-time-float-current">00:00</span><span class="mejs-time-float-corner"></span></span></span></div>').appendTo(d),d.find(".mejs-time-buffering").hide();var g=this,h=d.find(".mejs-time-total"),i=d.find(".mejs-time-loaded"),j=d.find(".mejs-time-current"),k=d.find(".mejs-time-handle"),l=d.find(".mejs-time-float"),m=d.find(".mejs-time-float-current"),n=function(a){var b=a.pageX,d=h.offset(),e=h.outerWidth(!0),g=0,i=0,j=0;f.duration&&(b<d.left?b=d.left:b>e+d.left&&(b=e+d.left),j=b-d.left,g=j/e,i=.02>=g?0:g*f.duration,o&&i!==f.currentTime&&f.setCurrentTime(i),c.MediaFeatures.hasTouch||(l.css("left",j),m.html(c.Utility.secondsToTimeCode(i)),l.show()))},o=!1,p=!1;h.bind("mousedown",function(a){return 1===a.which?(o=!0,n(a),g.globalBind("mousemove.dur",function(a){n(a)}),g.globalBind("mouseup.dur",function(){o=!1,l.hide(),g.globalUnbind(".dur")}),!1):void 0}).bind("mouseenter",function(){p=!0,g.globalBind("mousemove.dur",function(a){n(a)}),c.MediaFeatures.hasTouch||l.show()}).bind("mouseleave",function(){p=!1,o||(g.globalUnbind(".dur"),l.hide())}),f.addEventListener("progress",function(a){b.setProgressRail(a),b.setCurrentRail(a)},!1),f.addEventListener("timeupdate",function(a){b.setProgressRail(a),b.setCurrentRail(a)},!1),g.loaded=i,g.total=h,g.current=j,g.handle=k},setProgressRail:function(a){var b=this,c=void 0!=a?a.target:b.media,d=null;c&&c.buffered&&c.buffered.length>0&&c.buffered.end&&c.duration?d=c.buffered.end(0)/c.duration:c&&void 0!=c.bytesTotal&&c.bytesTotal>0&&void 0!=c.bufferedBytes?d=c.bufferedBytes/c.bytesTotal:a&&a.lengthComputable&&0!=a.total&&(d=a.loaded/a.total),null!==d&&(d=Math.min(1,Math.max(0,d)),b.loaded&&b.total&&b.loaded.width(b.total.width()*d))},setCurrentRail:function(){var a=this;if(void 0!=a.media.currentTime&&a.media.duration&&a.total&&a.handle){var b=Math.round(a.total.width()*a.media.currentTime/a.media.duration),c=b-Math.round(a.handle.outerWidth(!0)/2);a.current.width(b),a.handle.css("left",c)}}})}(c.$),function(a){a.extend(c.MepDefaults,{duration:-1,timeAndDurationSeparator:"<span> | </span>"}),a.extend(MediaElementPlayer.prototype,{buildcurrent:function(b,c,d,e){var f=this;a('<div class="mejs-time"><span class="mejs-currenttime">'+(b.options.alwaysShowHours?"00:":"")+(b.options.showTimecodeFrameCount?"00:00:00":"00:00")+"</span>"+"</div>").appendTo(c),f.currenttime=f.controls.find(".mejs-currenttime"),e.addEventListener("timeupdate",function(){b.updateCurrent()},!1)},buildduration:function(b,d,e,f){var g=this;d.children().last().find(".mejs-currenttime").length>0?a(g.options.timeAndDurationSeparator+'<span class="mejs-duration">'+(g.options.duration>0?c.Utility.secondsToTimeCode(g.options.duration,g.options.alwaysShowHours||g.media.duration>3600,g.options.showTimecodeFrameCount,g.options.framesPerSecond||25):(b.options.alwaysShowHours?"00:":"")+(b.options.showTimecodeFrameCount?"00:00:00":"00:00"))+"</span>").appendTo(d.find(".mejs-time")):(d.find(".mejs-currenttime").parent().addClass("mejs-currenttime-container"),a('<div class="mejs-time mejs-duration-container"><span class="mejs-duration">'+(g.options.duration>0?c.Utility.secondsToTimeCode(g.options.duration,g.options.alwaysShowHours||g.media.duration>3600,g.options.showTimecodeFrameCount,g.options.framesPerSecond||25):(b.options.alwaysShowHours?"00:":"")+(b.options.showTimecodeFrameCount?"00:00:00":"00:00"))+"</span>"+"</div>").appendTo(d)),g.durationD=g.controls.find(".mejs-duration"),f.addEventListener("timeupdate",function(){b.updateDuration()},!1)},updateCurrent:function(){var a=this;a.currenttime&&a.currenttime.html(c.Utility.secondsToTimeCode(a.media.currentTime,a.options.alwaysShowHours||a.media.duration>3600,a.options.showTimecodeFrameCount,a.options.framesPerSecond||25))},updateDuration:function(){var a=this;a.container.toggleClass("mejs-long-video",a.media.duration>3600),a.durationD&&(a.options.duration>0||a.media.duration)&&a.durationD.html(c.Utility.secondsToTimeCode(a.options.duration>0?a.options.duration:a.media.duration,a.options.alwaysShowHours,a.options.showTimecodeFrameCount,a.options.framesPerSecond||25))}})}(c.$),function(a){a.extend(c.MepDefaults,{muteText:c.i18n.t("Mute Toggle"),hideVolumeOnTouchDevices:!0,audioVolume:"horizontal",videoVolume:"vertical"}),a.extend(MediaElementPlayer.prototype,{buildvolume:function(b,d,e,f){if(!c.MediaFeatures.hasTouch||!this.options.hideVolumeOnTouchDevices){var g=this,h=g.isVideo?g.options.videoVolume:g.options.audioVolume,i="horizontal"==h?a('<div class="mejs-button mejs-volume-button mejs-mute"><button type="button" aria-controls="'+g.id+'" title="'+g.options.muteText+'" aria-label="'+g.options.muteText+'"></button>'+"</div>"+'<div class="mejs-horizontal-volume-slider">'+'<div class="mejs-horizontal-volume-total"></div>'+'<div class="mejs-horizontal-volume-current"></div>'+'<div class="mejs-horizontal-volume-handle"></div>'+"</div>").appendTo(d):a('<div class="mejs-button mejs-volume-button mejs-mute"><button type="button" aria-controls="'+g.id+'" title="'+g.options.muteText+'" aria-label="'+g.options.muteText+'"></button>'+'<div class="mejs-volume-slider">'+'<div class="mejs-volume-total"></div>'+'<div class="mejs-volume-current"></div>'+'<div class="mejs-volume-handle"></div>'+"</div>"+"</div>").appendTo(d),j=g.container.find(".mejs-volume-slider, .mejs-horizontal-volume-slider"),k=g.container.find(".mejs-volume-total, .mejs-horizontal-volume-total"),l=g.container.find(".mejs-volume-current, .mejs-horizontal-volume-current"),m=g.container.find(".mejs-volume-handle, .mejs-horizontal-volume-handle"),n=function(a,b){if(!j.is(":visible")&&"undefined"==typeof b)return j.show(),n(a,!0),j.hide(),void 0;if(a=Math.max(0,a),a=Math.min(a,1),0==a?i.removeClass("mejs-mute").addClass("mejs-unmute"):i.removeClass("mejs-unmute").addClass("mejs-mute"),"vertical"==h){var c=k.height(),d=k.position(),e=c-c*a;m.css("top",Math.round(d.top+e-m.height()/2)),l.height(c-e),l.css("top",d.top+e)}else{var f=k.width(),d=k.position(),g=f*a;m.css("left",Math.round(d.left+g-m.width()/2)),l.width(Math.round(g))}},o=function(a){var b=null,c=k.offset();if("vertical"==h){var d=k.height(),e=(parseInt(k.css("top").replace(/px/,""),10),a.pageY-c.top);if(b=(d-e)/d,0==c.top||0==c.left)return}else{var g=k.width(),i=a.pageX-c.left;b=i/g}b=Math.max(0,b),b=Math.min(b,1),n(b),0==b?f.setMuted(!0):f.setMuted(!1),f.setVolume(b)},p=!1,q=!1;i.hover(function(){j.show(),q=!0},function(){q=!1,p||"vertical"!=h||j.hide()}),j.bind("mouseover",function(){q=!0}).bind("mousedown",function(a){return o(a),g.globalBind("mousemove.vol",function(a){o(a)}),g.globalBind("mouseup.vol",function(){p=!1,g.globalUnbind(".vol"),q||"vertical"!=h||j.hide()}),p=!0,!1}),i.find("button").click(function(){f.setMuted(!f.muted)}),f.addEventListener("volumechange",function(){p||(f.muted?(n(0),i.removeClass("mejs-mute").addClass("mejs-unmute")):(n(f.volume),i.removeClass("mejs-unmute").addClass("mejs-mute")))},!1),g.container.is(":visible")&&(n(b.options.startVolume),0===b.options.startVolume&&f.setMuted(!0),"native"===f.pluginType&&f.setVolume(b.options.startVolume))}}})}(c.$),function(a){a.extend(c.MepDefaults,{usePluginFullScreen:!0,newWindowCallback:function(){return""},fullscreenText:c.i18n.t("Fullscreen")}),a.extend(MediaElementPlayer.prototype,{isFullScreen:!1,isNativeFullScreen:!1,isInIframe:!1,buildfullscreen:function(b,d,e,f){if(b.isVideo){if(b.isInIframe=window.location!=window.parent.location,c.MediaFeatures.hasTrueNativeFullScreen){var g=function(){b.isFullScreen&&(c.MediaFeatures.isFullScreen()?(b.isNativeFullScreen=!0,b.setControlsSize()):(b.isNativeFullScreen=!1,b.exitFullScreen()))};c.MediaFeatures.hasMozNativeFullScreen?b.globalBind(c.MediaFeatures.fullScreenEventName,g):b.container.bind(c.MediaFeatures.fullScreenEventName,g)}var h=this,i=(b.container,a('<div class="mejs-button mejs-fullscreen-button"><button type="button" aria-controls="'+h.id+'" title="'+h.options.fullscreenText+'" aria-label="'+h.options.fullscreenText+'"></button>'+"</div>").appendTo(d));if("native"===h.media.pluginType||!h.options.usePluginFullScreen&&!c.MediaFeatures.isFirefox)i.click(function(){var a=c.MediaFeatures.hasTrueNativeFullScreen&&c.MediaFeatures.isFullScreen()||b.isFullScreen;a?b.exitFullScreen():b.enterFullScreen()});else{var j=null,k=function(){var a,b=document.createElement("x"),c=document.documentElement,d=window.getComputedStyle;return"pointerEvents"in b.style?(b.style.pointerEvents="auto",b.style.pointerEvents="x",c.appendChild(b),a=d&&"auto"===d(b,"").pointerEvents,c.removeChild(b),!!a):!1}();if(k&&!c.MediaFeatures.isOpera){var l,m,n=!1,o=function(){if(n){for(var a in p)p[a].hide();i.css("pointer-events",""),h.controls.css("pointer-events",""),h.media.removeEventListener("click",h.clickToPlayPauseCallback),n=!1}},p={},q=["top","left","right","bottom"],r=function(){var a=i.offset().left-h.container.offset().left,b=i.offset().top-h.container.offset().top,c=i.outerWidth(!0),d=i.outerHeight(!0),e=h.container.width(),f=h.container.height();for(l in p)p[l].css({position:"absolute",top:0,left:0});p.top.width(e).height(b),p.left.width(a).height(d).css({top:b}),p.right.width(e-a-c).height(d).css({top:b,left:a+c}),p.bottom.width(e).height(f-d-b).css({top:b+d})};for(h.globalBind("resize",function(){r()}),l=0,m=q.length;m>l;l++)p[q[l]]=a('<div class="mejs-fullscreen-hover" />').appendTo(h.container).mouseover(o).hide();i.on("mouseover",function(){if(!h.isFullScreen){var a=i.offset(),c=b.container.offset();f.positionFullscreenButton(a.left-c.left,a.top-c.top,!1),i.css("pointer-events","none"),h.controls.css("pointer-events","none"),h.media.addEventListener("click",h.clickToPlayPauseCallback);for(l in p)p[l].show();r(),n=!0}}),f.addEventListener("fullscreenchange",function(){h.isFullScreen=!h.isFullScreen,h.isFullScreen?h.media.removeEventListener("click",h.clickToPlayPauseCallback):h.media.addEventListener("click",h.clickToPlayPauseCallback),o()}),h.globalBind("mousemove",function(a){if(n){var b=i.offset();(a.pageY<b.top||a.pageY>b.top+i.outerHeight(!0)||a.pageX<b.left||a.pageX>b.left+i.outerWidth(!0))&&(i.css("pointer-events",""),h.controls.css("pointer-events",""),n=!1)}})}else i.on("mouseover",function(){null!==j&&(clearTimeout(j),delete j);var a=i.offset(),c=b.container.offset();f.positionFullscreenButton(a.left-c.left,a.top-c.top,!0)}).on("mouseout",function(){null!==j&&(clearTimeout(j),delete j),j=setTimeout(function(){f.hideFullscreenButton()},1500)})}b.fullscreenBtn=i,h.globalBind("keydown",function(a){(c.MediaFeatures.hasTrueNativeFullScreen&&c.MediaFeatures.isFullScreen()||h.isFullScreen)&&27==a.keyCode&&b.exitFullScreen()})}},cleanfullscreen:function(a){a.exitFullScreen()},containerSizeTimeout:null,enterFullScreen:function(){var b=this;if("native"===b.media.pluginType||!c.MediaFeatures.isFirefox&&!b.options.usePluginFullScreen){if(a(document.documentElement).addClass("mejs-fullscreen"),normalHeight=b.container.height(),normalWidth=b.container.width(),"native"===b.media.pluginType)if(c.MediaFeatures.hasTrueNativeFullScreen)c.MediaFeatures.requestFullScreen(b.container[0]),b.isInIframe&&setTimeout(function e(){b.isNativeFullScreen&&(a(window).width()!==screen.width?b.exitFullScreen():setTimeout(e,500))},500);else if(c.MediaFeatures.hasSemiNativeFullScreen)return b.media.webkitEnterFullscreen(),void 0;if(b.isInIframe){var d=b.options.newWindowCallback(this);if(""!==d){if(!c.MediaFeatures.hasTrueNativeFullScreen)return b.pause(),window.open(d,b.id,"top=0,left=0,width="+screen.availWidth+",height="+screen.availHeight+",resizable=yes,scrollbars=no,status=no,toolbar=no"),void 0;setTimeout(function(){b.isNativeFullScreen||(b.pause(),window.open(d,b.id,"top=0,left=0,width="+screen.availWidth+",height="+screen.availHeight+",resizable=yes,scrollbars=no,status=no,toolbar=no"))},250)}}b.container.addClass("mejs-container-fullscreen").width("100%").height("100%"),b.containerSizeTimeout=setTimeout(function(){b.container.css({width:"100%",height:"100%"}),b.setControlsSize()},500),"native"===b.media.pluginType?b.$media.width("100%").height("100%"):(b.container.find(".mejs-shim").width("100%").height("100%"),b.media.setVideoSize(a(window).width(),a(window).height())),b.layers.children("div").width("100%").height("100%"),b.fullscreenBtn&&b.fullscreenBtn.removeClass("mejs-fullscreen").addClass("mejs-unfullscreen"),b.setControlsSize(),b.isFullScreen=!0}},exitFullScreen:function(){var b=this;return clearTimeout(b.containerSizeTimeout),"native"!==b.media.pluginType&&c.MediaFeatures.isFirefox?(b.media.setFullscreen(!1),void 0):(c.MediaFeatures.hasTrueNativeFullScreen&&(c.MediaFeatures.isFullScreen()||b.isFullScreen)&&c.MediaFeatures.cancelFullScreen(),a(document.documentElement).removeClass("mejs-fullscreen"),b.container.removeClass("mejs-container-fullscreen").width(normalWidth).height(normalHeight),"native"===b.media.pluginType?b.$media.width(normalWidth).height(normalHeight):(b.container.find(".mejs-shim").width(normalWidth).height(normalHeight),b.media.setVideoSize(normalWidth,normalHeight)),b.layers.children("div").width(normalWidth).height(normalHeight),b.fullscreenBtn.removeClass("mejs-unfullscreen").addClass("mejs-fullscreen"),b.setControlsSize(),b.isFullScreen=!1,void 0)}})}(c.$),function(a){a.extend(c.MepDefaults,{startLanguage:"",tracksText:c.i18n.t("Captions/Subtitles"),hideCaptionsButtonWhenEmpty:!0,toggleCaptionsButtonWhenOnlyOne:!1,slidesSelector:""}),a.extend(MediaElementPlayer.prototype,{hasChapters:!1,buildtracks:function(b,d,e,f){if(0!=b.tracks.length){var g,h=this;if(h.domNode.textTracks)for(var g=h.domNode.textTracks.length-1;g>=0;g--)h.domNode.textTracks[g].mode="hidden";b.chapters=a('<div class="mejs-chapters mejs-layer"></div>').prependTo(e).hide(),b.captions=a('<div class="mejs-captions-layer mejs-layer"><div class="mejs-captions-position mejs-captions-position-hover"><span class="mejs-captions-text"></span></div></div>').prependTo(e).hide(),b.captionsText=b.captions.find(".mejs-captions-text"),b.captionsButton=a('<div class="mejs-button mejs-captions-button"><button type="button" aria-controls="'+h.id+'" title="'+h.options.tracksText+'" aria-label="'+h.options.tracksText+'"></button>'+'<div class="mejs-captions-selector">'+"<ul>"+"<li>"+'<input type="radio" name="'+b.id+'_captions" id="'+b.id+'_captions_none" value="none" checked="checked" />'+'<label for="'+b.id+'_captions_none">'+c.i18n.t("None")+"</label>"+"</li>"+"</ul>"+"</div>"+"</div>").appendTo(d);var i=0;for(g=0;g<b.tracks.length;g++)"subtitles"==b.tracks[g].kind&&i++;for(h.options.toggleCaptionsButtonWhenOnlyOne&&1==i?b.captionsButton.on("click",function(){if(null==b.selectedTrack)var a=b.tracks[0].srclang;else var a="none";b.setTrack(a)}):b.captionsButton.hover(function(){a(this).find(".mejs-captions-selector").css("visibility","visible")},function(){a(this).find(".mejs-captions-selector").css("visibility","hidden")}).on("click","input[type=radio]",function(){lang=this.value,b.setTrack(lang)}),b.options.alwaysShowControls?b.container.find(".mejs-captions-position").addClass("mejs-captions-position-hover"):b.container.bind("controlsshown",function(){b.container.find(".mejs-captions-position").addClass("mejs-captions-position-hover")}).bind("controlshidden",function(){f.paused||b.container.find(".mejs-captions-position").removeClass("mejs-captions-position-hover")}),b.trackToLoad=-1,b.selectedTrack=null,b.isLoadingTrack=!1,g=0;g<b.tracks.length;g++)"subtitles"==b.tracks[g].kind&&b.addTrackButton(b.tracks[g].srclang,b.tracks[g].label);b.loadNextTrack(),f.addEventListener("timeupdate",function(){b.displayCaptions()},!1),""!=b.options.slidesSelector&&(b.slidesContainer=a(b.options.slidesSelector),f.addEventListener("timeupdate",function(){b.displaySlides()},!1)),f.addEventListener("loadedmetadata",function(){b.displayChapters()},!1),b.container.hover(function(){b.hasChapters&&(b.chapters.css("visibility","visible"),b.chapters.fadeIn(200).height(b.chapters.find(".mejs-chapter").outerHeight()))},function(){b.hasChapters&&!f.paused&&b.chapters.fadeOut(200,function(){a(this).css("visibility","hidden"),a(this).css("display","block")})}),null!==b.node.getAttribute("autoplay")&&b.chapters.css("visibility","hidden")}},setTrack:function(a){var b,c=this;if("none"==a)c.selectedTrack=null,c.captionsButton.removeClass("mejs-captions-enabled");else for(b=0;b<c.tracks.length;b++)if(c.tracks[b].srclang==a){null==c.selectedTrack&&c.captionsButton.addClass("mejs-captions-enabled"),c.selectedTrack=c.tracks[b],c.captions.attr("lang",c.selectedTrack.srclang),c.displayCaptions();break}},loadNextTrack:function(){var a=this;a.trackToLoad++,a.trackToLoad<a.tracks.length?(a.isLoadingTrack=!0,a.loadTrack(a.trackToLoad)):(a.isLoadingTrack=!1,a.checkForTracks())},loadTrack:function(b){var d=this,e=d.tracks[b],f=function(){e.isLoaded=!0,d.enableTrackButton(e.srclang,e.label),d.loadNextTrack()};a.ajax({url:e.src,dataType:"text",success:function(a){e.entries="string"==typeof a&&/<tt\s+xml/gi.exec(a)?c.TrackFormatParser.dfxp.parse(a):c.TrackFormatParser.webvvt.parse(a),f(),"chapters"==e.kind&&d.media.addEventListener("play",function(){d.media.duration>0&&d.displayChapters(e)},!1),"slides"==e.kind&&d.setupSlides(e)},error:function(){d.loadNextTrack()}})},enableTrackButton:function(b,d){var e=this;""===d&&(d=c.language.codes[b]||b),e.captionsButton.find("input[value="+b+"]").prop("disabled",!1).siblings("label").html(d),e.options.startLanguage==b&&a("#"+e.id+"_captions_"+b).click(),e.adjustLanguageBox()},addTrackButton:function(b,d){var e=this;""===d&&(d=c.language.codes[b]||b),e.captionsButton.find("ul").append(a('<li><input type="radio" name="'+e.id+'_captions" id="'+e.id+"_captions_"+b+'" value="'+b+'" disabled="disabled" />'+'<label for="'+e.id+"_captions_"+b+'">'+d+" (loading)"+"</label>"+"</li>")),e.adjustLanguageBox(),e.container.find(".mejs-captions-translations option[value="+b+"]").remove()},adjustLanguageBox:function(){var a=this;a.captionsButton.find(".mejs-captions-selector").height(a.captionsButton.find(".mejs-captions-selector ul").outerHeight(!0)+a.captionsButton.find(".mejs-captions-translations").outerHeight(!0))},checkForTracks:function(){var a=this,b=!1;if(a.options.hideCaptionsButtonWhenEmpty){for(i=0;i<a.tracks.length;i++)if("subtitles"==a.tracks[i].kind){b=!0;break}b||(a.captionsButton.hide(),a.setControlsSize())}},displayCaptions:function(){if("undefined"!=typeof this.tracks){var a,b=this,c=b.selectedTrack;if(null!=c&&c.isLoaded){for(a=0;a<c.entries.times.length;a++)if(b.media.currentTime>=c.entries.times[a].start&&b.media.currentTime<=c.entries.times[a].stop)return b.captionsText.html(c.entries.text[a]),b.captions.show().height(0),void 0;b.captions.hide()}else b.captions.hide()}},setupSlides:function(a){var b=this;b.slides=a,b.slides.entries.imgs=[b.slides.entries.text.length],b.showSlide(0)},showSlide:function(b){if("undefined"!=typeof this.tracks&&"undefined"!=typeof this.slidesContainer){var c=this,d=c.slides.entries.text[b],e=c.slides.entries.imgs[b];"undefined"==typeof e||"undefined"==typeof e.fadeIn?c.slides.entries.imgs[b]=e=a('<img src="'+d+'">').on("load",function(){e.appendTo(c.slidesContainer).hide().fadeIn().siblings(":visible").fadeOut()}):e.is(":visible")||e.is(":animated")||e.fadeIn().siblings(":visible").fadeOut()}},displaySlides:function(){if("undefined"!=typeof this.slides){var a,b=this,c=b.slides;for(a=0;a<c.entries.times.length;a++)if(b.media.currentTime>=c.entries.times[a].start&&b.media.currentTime<=c.entries.times[a].stop)return b.showSlide(a),void 0}},displayChapters:function(){var a,b=this;for(a=0;a<b.tracks.length;a++)if("chapters"==b.tracks[a].kind&&b.tracks[a].isLoaded){b.drawChapters(b.tracks[a]),b.hasChapters=!0;break}},drawChapters:function(b){var d,e,f=this,g=0,h=0;for(f.chapters.empty(),d=0;d<b.entries.times.length;d++)e=b.entries.times[d].stop-b.entries.times[d].start,g=Math.floor(100*(e/f.media.duration)),(g+h>100||d==b.entries.times.length-1&&100>g+h)&&(g=100-h),f.chapters.append(a('<div class="mejs-chapter" rel="'+b.entries.times[d].start+'" style="left: '+h.toString()+"%;width: "+g.toString()+'%;">'+'<div class="mejs-chapter-block'+(d==b.entries.times.length-1?" mejs-chapter-block-last":"")+'">'+'<span class="ch-title">'+b.entries.text[d]+"</span>"+'<span class="ch-time">'+c.Utility.secondsToTimeCode(b.entries.times[d].start)+"–"+c.Utility.secondsToTimeCode(b.entries.times[d].stop)+"</span>"+"</div>"+"</div>")),h+=g;f.chapters.find("div.mejs-chapter").click(function(){f.media.setCurrentTime(parseFloat(a(this).attr("rel"))),f.media.paused&&f.media.play()}),f.chapters.show()}}),c.language={codes:{af:"Afrikaans",sq:"Albanian",ar:"Arabic",be:"Belarusian",bg:"Bulgarian",ca:"Catalan",zh:"Chinese","zh-cn":"Chinese Simplified","zh-tw":"Chinese Traditional",hr:"Croatian",cs:"Czech",da:"Danish",nl:"Dutch",en:"English",et:"Estonian",tl:"Filipino",fi:"Finnish",fr:"French",gl:"Galician",de:"German",el:"Greek",ht:"Haitian Creole",iw:"Hebrew",hi:"Hindi",hu:"Hungarian",is:"Icelandic",id:"Indonesian",ga:"Irish",it:"Italian",ja:"Japanese",ko:"Korean",lv:"Latvian",lt:"Lithuanian",mk:"Macedonian",ms:"Malay",mt:"Maltese",no:"Norwegian",fa:"Persian",pl:"Polish",pt:"Portuguese",ro:"Romanian",ru:"Russian",sr:"Serbian",sk:"Slovak",sl:"Slovenian",es:"Spanish",sw:"Swahili",sv:"Swedish",tl:"Tagalog",th:"Thai",tr:"Turkish",uk:"Ukrainian",vi:"Vietnamese",cy:"Welsh",yi:"Yiddish"}},c.TrackFormatParser={webvvt:{pattern_identifier:/^([a-zA-z]+-)?[0-9]+$/,pattern_timecode:/^([0-9]{2}:[0-9]{2}:[0-9]{2}([,.][0-9]{1,3})?) --\> ([0-9]{2}:[0-9]{2}:[0-9]{2}([,.][0-9]{3})?)(.*)$/,parse:function(b){for(var d,e,f=0,g=c.TrackFormatParser.split2(b,/\r?\n/),h={text:[],times:[]};f<g.length;f++)if(this.pattern_identifier.exec(g[f])&&(f++,d=this.pattern_timecode.exec(g[f]),d&&f<g.length)){for(f++,e=g[f],f++;""!==g[f]&&f<g.length;)e=e+"\n"+g[f],f++;
e=a.trim(e).replace(/(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/gi,"<a href='$1' target='_blank'>$1</a>"),h.text.push(e),h.times.push({start:0==c.Utility.convertSMPTEtoSeconds(d[1])?.2:c.Utility.convertSMPTEtoSeconds(d[1]),stop:c.Utility.convertSMPTEtoSeconds(d[3]),settings:d[5]})}return h}},dfxp:{parse:function(b){b=a(b).filter("tt");var d,e,f=0,g=b.children("div").eq(0),h=g.find("p"),i=b.find("#"+g.attr("style")),j={text:[],times:[]};if(i.length){var k=i.removeAttr("id").get(0).attributes;if(k.length)for(d={},f=0;f<k.length;f++)d[k[f].name.split(":")[1]]=k[f].value}for(f=0;f<h.length;f++){var l,m={start:null,stop:null,style:null};if(h.eq(f).attr("begin")&&(m.start=c.Utility.convertSMPTEtoSeconds(h.eq(f).attr("begin"))),!m.start&&h.eq(f-1).attr("end")&&(m.start=c.Utility.convertSMPTEtoSeconds(h.eq(f-1).attr("end"))),h.eq(f).attr("end")&&(m.stop=c.Utility.convertSMPTEtoSeconds(h.eq(f).attr("end"))),!m.stop&&h.eq(f+1).attr("begin")&&(m.stop=c.Utility.convertSMPTEtoSeconds(h.eq(f+1).attr("begin"))),d){l="";for(var n in d)l+=n+":"+d[n]+";"}l&&(m.style=l),0==m.start&&(m.start=.2),j.times.push(m),e=a.trim(h.eq(f).html()).replace(/(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/gi,"<a href='$1' target='_blank'>$1</a>"),j.text.push(e),0==j.times.start&&(j.times.start=2)}return j}},split2:function(a,b){return a.split(b)}},3!="x\n\ny".split(/\n/gi).length&&(c.TrackFormatParser.split2=function(a,b){var c,d=[],e="";for(c=0;c<a.length;c++)e+=a.substring(c,c+1),b.test(e)&&(d.push(e.replace(b,"")),e="");return d.push(e),d})}(c.$),function(a){a.extend(c.MepDefaults,{contextMenuItems:[{render:function(a){return"undefined"==typeof a.enterFullScreen?null:a.isFullScreen?c.i18n.t("Turn off Fullscreen"):c.i18n.t("Go Fullscreen")},click:function(a){a.isFullScreen?a.exitFullScreen():a.enterFullScreen()}},{render:function(a){return a.media.muted?c.i18n.t("Unmute"):c.i18n.t("Mute")},click:function(a){a.media.muted?a.setMuted(!1):a.setMuted(!0)}},{isSeparator:!0},{render:function(){return c.i18n.t("Download Video")},click:function(a){window.location.href=a.media.currentSrc}}]}),a.extend(MediaElementPlayer.prototype,{buildcontextmenu:function(b){b.contextMenu=a('<div class="mejs-contextmenu"></div>').appendTo(a("body")).hide(),b.container.bind("contextmenu",function(a){return b.isContextMenuEnabled?(a.preventDefault(),b.renderContextMenu(a.clientX-1,a.clientY-1),!1):void 0}),b.container.bind("click",function(){b.contextMenu.hide()}),b.contextMenu.bind("mouseleave",function(){b.startContextMenuTimer()})},cleancontextmenu:function(a){a.contextMenu.remove()},isContextMenuEnabled:!0,enableContextMenu:function(){this.isContextMenuEnabled=!0},disableContextMenu:function(){this.isContextMenuEnabled=!1},contextMenuTimeout:null,startContextMenuTimer:function(){var a=this;a.killContextMenuTimer(),a.contextMenuTimer=setTimeout(function(){a.hideContextMenu(),a.killContextMenuTimer()},750)},killContextMenuTimer:function(){var a=this.contextMenuTimer;null!=a&&(clearTimeout(a),delete a,a=null)},hideContextMenu:function(){this.contextMenu.hide()},renderContextMenu:function(b,c){for(var d=this,e="",f=d.options.contextMenuItems,g=0,h=f.length;h>g;g++)if(f[g].isSeparator)e+='<div class="mejs-contextmenu-separator"></div>';else{var i=f[g].render(d);null!=i&&(e+='<div class="mejs-contextmenu-item" data-itemindex="'+g+'" id="element-'+1e6*Math.random()+'">'+i+"</div>")}d.contextMenu.empty().append(a(e)).css({top:c,left:b}).show(),d.contextMenu.find(".mejs-contextmenu-item").each(function(){var b=a(this),c=parseInt(b.data("itemindex"),10),e=d.options.contextMenuItems[c];"undefined"!=typeof e.show&&e.show(b,d),b.click(function(){"undefined"!=typeof e.click&&e.click(d),d.contextMenu.hide()})}),setTimeout(function(){d.killControlsTimer("rev3")},100)}})}(c.$),function(a){a.extend(c.MepDefaults,{postrollCloseText:c.i18n.t("Close")}),a.extend(MediaElementPlayer.prototype,{buildpostroll:function(b,c,d){var e=this,f=e.container.find('link[rel="postroll"]').attr("href");"undefined"!=typeof f&&(b.postroll=a('<div class="mejs-postroll-layer mejs-layer"><a class="mejs-postroll-close" onclick="$(this).parent().hide();return false;">'+e.options.postrollCloseText+'</a><div class="mejs-postroll-layer-content"></div></div>').prependTo(d).hide(),e.media.addEventListener("ended",function(){a.ajax({dataType:"html",url:f,success:function(a){d.find(".mejs-postroll-layer-content").html(a)}}),b.postroll.show()},!1))}})}(c.$)});
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
