if(typeof jwplayer=="undefined"){var jwplayer=function(b){if(jwplayer.api){return jwplayer.api.selectPlayer(b)}};var $jw=jwplayer;jwplayer.version="5.9.2118 (Licensed version)";jwplayer.vid=document.createElement("video");jwplayer.audio=document.createElement("audio");jwplayer.source=document.createElement("source");(function(c){c.utils=function(){};c.utils.typeOf=function(a){var b=typeof a;if(b==="object"){if(a){if(a instanceof Array){b="array"}}else{b="null"}}return b};c.utils.extend=function(){var f=c.utils.extend["arguments"];if(f.length>1){for(var a=1;a-1){return a.substr(a.lastIndexOf(".")+1,a.length).toLowerCase()}return};c.utils.html=function(b,a){b.innerHTML=a};c.utils.wrap=function(b,a){if(b.parentNode){b.parentNode.replaceChild(a,b)}a.appendChild(b)};c.utils.ajax=function(a,b,k){var h;if(window.XMLHttpRequest){h=new XMLHttpRequest()}else{h=new ActiveXObject("Microsoft.XMLHTTP")}h.onreadystatechange=function(){if(h.readyState===4){if(h.status===200){if(b){if(!c.utils.exists(h.responseXML)){try{if(window.DOMParser){var f=(new DOMParser()).parseFromString(h.responseText,"text/xml");if(f){h=c.utils.extend({},h,{responseXML:f})}}else{f=new ActiveXObject("Microsoft.XMLDOM");f.async="false";f.loadXML(h.responseText);h=c.utils.extend({},h,{responseXML:f})}}catch(e){if(k){k(a)}}}b(h)}}else{if(k){k(a)}}}};try{h.open("GET",a,true);h.send(null)}catch(j){if(k){k(a)}}return h};c.utils.load=function(b,a,f){b.onreadystatechange=function(){if(b.readyState===4){if(b.status===200){if(a){a()}}else{if(f){f()}}}}};c.utils.find=function(a,b){return a.getElementsByTagName(b)};c.utils.append=function(b,a){b.appendChild(a)};c.utils.isIE=function(){return((!+"\v1")||(typeof window.ActiveXObject!="undefined"))};c.utils.userAgentMatch=function(a){var b=navigator.userAgent.toLowerCase();return(b.match(a)!==null)};c.utils.isIOS=function(){return c.utils.userAgentMatch(/iP(hone|ad|od)/i)};c.utils.isIPad=function(){return c.utils.userAgentMatch(/iPad/i)};c.utils.isIPod=function(){return c.utils.userAgentMatch(/iP(hone|od)/i)};c.utils.isAndroid=function(){return c.utils.userAgentMatch(/android/i)};c.utils.isLegacyAndroid=function(){return c.utils.userAgentMatch(/android 2.[012]/i)};c.utils.isBlackberry=function(){return c.utils.userAgentMatch(/blackberry/i)};c.utils.isMobile=function(){return c.utils.userAgentMatch(/(iP(hone|ad|od))|android/i)};c.utils.getFirstPlaylistItemFromConfig=function(f){var b={};var a;if(f.playlist&&f.playlist.length){a=f.playlist[0]}else{a=f}b.file=a.file;b.levels=a.levels;b.streamer=a.streamer;b.playlistfile=a.playlistfile;b.provider=a.provider;if(!b.provider){if(b.file&&(b.file.toLowerCase().indexOf("youtube.com")>-1||b.file.toLowerCase().indexOf("youtu.be")>-1)){b.provider="youtube"}if(b.streamer&&b.streamer.toLowerCase().indexOf("rtmp://")==0){b.provider="rtmp"}if(a.type){b.provider=a.type.toLowerCase()}}if(b.provider=="audio"){b.provider="sound"}return b};c.utils.getOuterHTML=function(b){if(b.outerHTML){return b.outerHTML}else{try{return new XMLSerializer().serializeToString(b)}catch(a){return""}}};c.utils.setOuterHTML=function(b,h){if(b.outerHTML){b.outerHTML=h}else{var a=document.createElement("div");a.innerHTML=h;var k=document.createRange();k.selectNodeContents(a);var j=k.extractContents();b.parentNode.insertBefore(j,b);b.parentNode.removeChild(b)}};c.utils.hasFlash=function(){if(typeof navigator.plugins!="undefined"&&typeof navigator.plugins["Shockwave Flash"]!="undefined"){return true}if(typeof window.ActiveXObject!="undefined"){try{new ActiveXObject("ShockwaveFlash.ShockwaveFlash");return true}catch(a){}}return false};c.utils.getPluginName=function(a){if(a.lastIndexOf("/")>=0){a=a.substring(a.lastIndexOf("/")+1,a.length)}if(a.lastIndexOf("-")>=0){a=a.substring(0,a.lastIndexOf("-"))}if(a.lastIndexOf(".swf")>=0){a=a.substring(0,a.lastIndexOf(".swf"))}if(a.lastIndexOf(".js")>=0){a=a.substring(0,a.lastIndexOf(".js"))}return a};c.utils.getPluginVersion=function(a){if(a.lastIndexOf("-")>=0){if(a.lastIndexOf(".js")>=0){return a.substring(a.lastIndexOf("-")+1,a.lastIndexOf(".js"))}else{if(a.lastIndexOf(".swf")>=0){return a.substring(a.lastIndexOf("-")+1,a.lastIndexOf(".swf"))}else{return a.substring(a.lastIndexOf("-")+1)}}}return""};c.utils.getAbsolutePath=function(b,l){if(!c.utils.exists(l)){l=document.location.href}if(!c.utils.exists(b)){return undefined}if(d(b)){return b}var a=l.substring(0,l.indexOf("://")+3);var m=l.substring(a.length,l.indexOf("/",a.length+1));var p;if(b.indexOf("/")===0){p=b.split("/")}else{var o=l.split("?")[0];o=o.substring(a.length+m.length+1,o.lastIndexOf("/"));p=o.split("/").concat(b.split("/"))}var q=[];for(var n=0;n0&&(f<0||(f>a)))}c.utils.pluginPathType={ABSOLUTE:"ABSOLUTE",RELATIVE:"RELATIVE",CDN:"CDN"};c.utils.getPluginPathType=function(g){if(typeof g!="string"){return}g=g.split("?")[0];var b=g.indexOf("://");if(b>0){return c.utils.pluginPathType.ABSOLUTE}var h=g.indexOf("/");var a=c.utils.extension(g);if(b<0&&h<0&&(!a||!isNaN(a))){return c.utils.pluginPathType.CDN}return c.utils.pluginPathType.RELATIVE};c.utils.mapEmpty=function(b){for(var a in b){return false}return true};c.utils.mapLength=function(b){var f=0;for(var a in b){f++}return f};c.utils.log=function(a,b){if(typeof console!="undefined"&&typeof console.log!="undefined"){if(b){console.log(a,b)}else{console.log(a)}}};c.utils.css=function(j,a,k){if(c.utils.exists(j)){for(var h in a){try{if(typeof a[h]==="undefined"){continue}else{if(typeof a[h]=="number"&&!(h=="zIndex"||h=="opacity")){if(isNaN(a[h])){continue}if(h.match(/color/i)){a[h]="#"+c.utils.strings.pad(a[h].toString(16),6)}else{a[h]=Math.ceil(a[h])+"px"}}}j.style[h]=a[h]}catch(b){}}}};c.utils.isYouTube=function(a){return(a.indexOf("youtube.com")>-1||a.indexOf("youtu.be")>-1)};c.utils.transform=function(k,l,m,b,a){if(!c.utils.exists(l)){l=1}if(!c.utils.exists(m)){m=1}if(!c.utils.exists(b)){b=0}if(!c.utils.exists(a)){a=0}if(l==1&&m==1&&b==0&&a==0){k.style.webkitTransform="";k.style.MozTransform="";k.style.OTransform=""}else{var j="scale("+l+","+m+") translate("+b+"px,"+a+"px)";k.style.webkitTransform=j;k.style.MozTransform=j;k.style.OTransform=j}};c.utils.stretch=function(v,a,b,y,s,x){if(typeof b=="undefined"||typeof y=="undefined"||typeof s=="undefined"||typeof x=="undefined"){return}var B=b/s;var z=y/x;var t=0;var u=0;var A=false;var C={};if(a.parentElement){a.parentElement.style.overflow="hidden"}c.utils.transform(a);switch(v.toUpperCase()){case c.utils.stretching.NONE:C.width=s;C.height=x;C.top=(y-C.height)/2;C.left=(b-C.width)/2;break;case c.utils.stretching.UNIFORM:if(B>z){C.width=s*z;C.height=x*z;if(C.width/b>0.95){A=true;B=Math.ceil(100*b/C.width)/100;z=1;C.width=b}}else{C.width=s*B;C.height=x*B;if(C.height/y>0.95){A=true;B=1;z=Math.ceil(100*y/C.height)/100;C.height=y}}C.top=(y-C.height)/2;C.left=(b-C.width)/2;break;case c.utils.stretching.FILL:if(B>z){C.width=s*B;C.height=x*B}else{C.width=s*z;C.height=x*z}C.top=(y-C.height)/2;C.left=(b-C.width)/2;break;case c.utils.stretching.EXACTFIT:C.width=s;C.height=x;var r=Math.round((s/2)*(1-1/B));var w=Math.round((x/2)*(1-1/z));A=true;C.top=C.left=0;break;default:break}if(A){c.utils.transform(a,B,z,r,w)}c.utils.css(a,C)};c.utils.stretching={NONE:"NONE",FILL:"FILL",UNIFORM:"UNIFORM",EXACTFIT:"EXACTFIT"};c.utils.deepReplaceKeyName=function(a,o,q){switch(c.utils.typeOf(a)){case"array":for(var m=0;m0);break;case"object":return(a!==null);case"undefined":return false}return true};c.utils.empty=function(a){if(typeof a.hasChildNodes=="function"){while(a.hasChildNodes()){a.removeChild(a.firstChild)}}};c.utils.parseDimension=function(a){if(typeof a=="string"){if(a===""){return 0}else{if(a.lastIndexOf("%")>-1){return a}else{return parseInt(a.replace("px",""),10)}}}return a};c.utils.getDimensions=function(a){if(a&&a.style){return{x:c.utils.parseDimension(a.style.left),y:c.utils.parseDimension(a.style.top),width:c.utils.parseDimension(a.style.width),height:c.utils.parseDimension(a.style.height)}}else{return{}}};c.utils.getElementWidth=function(a){if(!a){return null}else{if(a==document.body){return c.utils.parentNode(a).clientWidth}else{if(a.clientWidth>0){return a.clientWidth}else{if(a.style){return c.utils.parseDimension(a.style.width)}else{return null}}}}};c.utils.getElementHeight=function(a){if(!a){return null}else{if(a==document.body){return c.utils.parentNode(a).clientHeight}else{if(a.clientHeight>0){return a.clientHeight}else{if(a.style){return c.utils.parseDimension(a.style.height)}else{return null}}}}};c.utils.timeFormat=function(a){str="00:00";if(a>0){str=Math.floor(a/60)<10?"0"+Math.floor(a/60)+":":Math.floor(a/60)+":";str+=Math.floor(a%60)<10?"0"+Math.floor(a%60):Math.floor(a%60)}return str};c.utils.useNativeFullscreen=function(){return(navigator&&navigator.vendor&&navigator.vendor.indexOf("Apple")==0)};c.utils.parentNode=function(a){if(!a){return docuemnt.body}else{if(a.parentNode){return a.parentNode}else{if(a.parentElement){return a.parentElement}else{return a}}}};c.utils.getBoundingClientRect=function(a){if(typeof a.getBoundingClientRect=="function"){return a.getBoundingClientRect()}else{return{left:a.offsetLeft+document.body.scrollLeft,top:a.offsetTop+document.body.scrollTop,width:a.offsetWidth,height:a.offsetHeight}}};c.utils.translateEventResponse=function(h,k){var a=c.utils.extend({},k);if(h==c.api.events.JWPLAYER_FULLSCREEN&&!a.fullscreen){a.fullscreen=a.message=="true"?true:false;delete a.message}else{if(typeof a.data=="object"){a=c.utils.extend(a,a.data);delete a.data}else{if(typeof a.metadata=="object"){c.utils.deepReplaceKeyName(a.metadata,["__dot__","__spc__","__dsh__"],["."," ","-"])}}}var j=["position","duration","offset"];for(var b in j){if(a[j[b]]){a[j[b]]=Math.round(a[j[b]]*1000)/1000}}return a};c.utils.saveCookie=function(b,a){document.cookie="jwplayer."+b+"="+a+"; path=/"};c.utils.getCookies=function(){var a={};var b=document.cookie.split("; ");for(var g=0;g0){_listeners[type][listenerIndex].count=_listeners[type][listenerIndex].count-1}}}}}for(var globalListenerIndex=0;globalListenerIndex<_globallisteners.length;globalListenerIndex++){try{_globallisteners[globalListenerIndex].listener(data)}catch(err){jwplayer.utils.log("There was an error while handling a listener: "+err.toString(),_globallisteners[globalListenerIndex].listener)}if(_globallisteners[globalListenerIndex]){if(_globallisteners[globalListenerIndex].count===1){delete _globallisteners[globalListenerIndex]}else{if(_globallisteners[globalListenerIndex].count>0){_globallisteners[globalListenerIndex].count=_globallisteners[globalListenerIndex].count-1}}}}}}})(jwplayer);(function(d){var c={};d.utils.animations=function(){};d.utils.animations.transform=function(b,a){b.style.webkitTransform=a;b.style.MozTransform=a;b.style.OTransform=a;b.style.msTransform=a};d.utils.animations.transformOrigin=function(b,a){b.style.webkitTransformOrigin=a;b.style.MozTransformOrigin=a;b.style.OTransformOrigin=a;b.style.msTransformOrigin=a};d.utils.animations.rotate=function(b,a){d.utils.animations.transform(b,["rotate(",a,"deg)"].join(""))};d.utils.cancelAnimation=function(a){delete c[a.id]};d.utils.fadeTo=function(a,r,s,o,p,t){if(c[a.id]!=t&&d.utils.exists(t)){return}if(a.style.opacity==r){return}var u=new Date().getTime();if(t>u){setTimeout(function(){d.utils.fadeTo(a,r,s,o,0,t)},t-u)}if(a.style.display=="none"){a.style.display="block"}if(!d.utils.exists(o)){o=a.style.opacity===""?1:a.style.opacity}if(a.style.opacity==r&&a.style.opacity!==""&&d.utils.exists(t)){if(r===0){a.style.display="none"}return}if(!d.utils.exists(t)){t=u;c[a.id]=t}if(!d.utils.exists(p)){p=0}var n=(s>0)?((u-t)/(s*1000)):0;n=n>1?1:n;var b=r-o;var q=o+(n*b);if(q>1){q=1}else{if(q<0){q=0}}a.style.opacity=q;if(p>0){c[a.id]=t+p*1000;d.utils.fadeTo(a,r,s,o,0,c[a.id]);return}setTimeout(function(){d.utils.fadeTo(a,r,s,o,0,t)},10)}})(jwplayer);(function(b){b.utils.arrays=function(){};b.utils.arrays.indexOf=function(f,e){for(var a=0;a-1){f.splice(a,1)}}})(jwplayer);(function(b){b.utils.extensionmap={"3gp":{html5:"video/3gpp",flash:"video"},"3gpp":{html5:"video/3gpp"},"3g2":{html5:"video/3gpp2",flash:"video"},"3gpp2":{html5:"video/3gpp2"},flv:{flash:"video"},f4a:{html5:"audio/mp4"},f4b:{html5:"audio/mp4",flash:"video"},f4v:{html5:"video/mp4",flash:"video"},mov:{html5:"video/quicktime",flash:"video"},m4a:{html5:"audio/mp4",flash:"video"},m4b:{html5:"audio/mp4"},m4p:{html5:"audio/mp4"},m4v:{html5:"video/mp4",flash:"video"},mp4:{html5:"video/mp4",flash:"video"},rbs:{flash:"sound"},aac:{html5:"audio/aac",flash:"video"},mp3:{html5:"audio/mp3",flash:"sound"},ogg:{html5:"audio/ogg"},oga:{html5:"audio/ogg"},ogv:{html5:"video/ogg"},webm:{html5:"video/webm"},m3u8:{html5:"audio/x-mpegurl"},gif:{flash:"image"},jpeg:{flash:"image"},jpg:{flash:"image"},swf:{flash:"image"},png:{flash:"image"},wav:{html5:"audio/x-wav"}}})(jwplayer);(function(o){o.utils.mediaparser=function(){};var m={element:{width:"width",height:"height",id:"id","class":"className",name:"name"},media:{src:"file",preload:"preload",autoplay:"autostart",loop:"repeat",controls:"controls"},source:{src:"file",type:"type",media:"media","data-jw-width":"width","data-jw-bitrate":"bitrate"},video:{poster:"image"}};var n={};o.utils.mediaparser.parseMedia=function(a){return p(a)};function q(a,b){if(!o.utils.exists(b)){b=m[a]}else{o.utils.extend(b,m[a])}return b}function p(f,d){if(n[f.tagName.toLowerCase()]&&!o.utils.exists(d)){return n[f.tagName.toLowerCase()](f)}else{d=q("element",d);var e={};for(var c in d){if(c!="length"){var a=f.getAttribute(c);if(o.utils.exists(a)){e[d[c]]=a}}}var b=f.style["#background-color"];if(b&&!(b=="transparent"||b=="rgba(0, 0, 0, 0)")){e.screencolor=b}return e}}function l(f,c){c=q("media",c);var b=[];var d=o.utils.selectors("source",f);for(var a in d){if(!isNaN(a)){b.push(k(d[a]))}}var e=p(f,c);if(o.utils.exists(e.file)){b[0]={file:e.file}}e.levels=b;return e}function k(a,b){b=q("source",b);var c=p(a,b);c.width=c.width?c.width:0;c.bitrate=c.bitrate?c.bitrate:0;return c}function j(a,b){b=q("video",b);var c=l(a,b);return c}n.media=l;n.audio=l;n.source=k;n.video=j})(jwplayer);(function(b){b.utils.loaderstatus={NEW:"NEW",LOADING:"LOADING",ERROR:"ERROR",COMPLETE:"COMPLETE"};b.utils.scriptloader=function(f){var e=b.utils.loaderstatus.NEW;var a=new b.events.eventdispatcher();b.utils.extend(this,a);this.load=function(){if(e==b.utils.loaderstatus.NEW){e=b.utils.loaderstatus.LOADING;var c=document.createElement("script");c.onload=function(d){e=b.utils.loaderstatus.COMPLETE;a.sendEvent(b.events.COMPLETE)};c.onerror=function(d){e=b.utils.loaderstatus.ERROR;a.sendEvent(b.events.ERROR)};c.onreadystatechange=function(){if(c.readyState=="loaded"||c.readyState=="complete"){e=b.utils.loaderstatus.COMPLETE;a.sendEvent(b.events.COMPLETE)}};document.getElementsByTagName("head")[0].appendChild(c);c.src=f}};this.getStatus=function(){return e}}})(jwplayer);(function(b){b.utils.selectors=function(a,f){if(!b.utils.exists(f)){f=document}a=b.utils.strings.trim(a);var h=a.charAt(0);if(h=="#"){return f.getElementById(a.substr(1))}else{if(h=="."){if(f.getElementsByClassName){return f.getElementsByClassName(a.substr(1))}else{return b.utils.selectors.getElementsByTagAndClass("*",a.substr(1))}}else{if(a.indexOf(".")>0){var g=a.split(".");return b.utils.selectors.getElementsByTagAndClass(g[0],g[1])}else{return f.getElementsByTagName(a)}}}return null};b.utils.selectors.getElementsByTagAndClass=function(o,l,m){var k=[];if(!b.utils.exists(m)){m=document}var n=m.getElementsByTagName(o);for(var p=0;p5||a.length==0){return a}else{return Number(a)}}}}};b.utils.strings.seconds=function(e){e=e.replace(",",".");var a=e.split(":");var f=0;if(e.substr(-1)=="s"){f=Number(e.substr(0,e.length-1))}else{if(e.substr(-1)=="m"){f=Number(e.substr(0,e.length-1))*60}else{if(e.substr(-1)=="h"){f=Number(e.substr(0,e.length-1))*3600}else{if(a.length>1){f=Number(a[a.length-1]);f+=Number(a[a.length-2])*60;if(a.length==3){f+=Number(a[a.length-3])*3600}}else{f=Number(e)}}}}return f};b.utils.strings.xmlAttribute=function(a,f){for(var e=0;e=0){return"boolean"}else{if(j.test(b)){return"color"}else{if(!isNaN(parseInt(b,10))&&parseInt(b,10).toString().length==b.length){return"integer"}else{if(!isNaN(parseFloat(b))&&parseFloat(b).toString().length==b.length){return"float"}}}}return"string"}function h(a,b){if(!k.utils.exists(b)){return a}switch(b){case"color":if(a.length>0){return g(a)}return null;case"integer":return parseInt(a,10);case"float":return parseFloat(a);case"boolean":if(a.toLowerCase()=="true"){return true}else{if(a=="1"){return true}}return false}return a}function g(a){switch(a.toLowerCase()){case"blue":return parseInt("0000FF",16);case"green":return parseInt("00FF00",16);case"red":return parseInt("FF0000",16);case"cyan":return parseInt("00FFFF",16);case"magenta":return parseInt("FF00FF",16);case"yellow":return parseInt("FFFF00",16);case"black":return parseInt("000000",16);case"white":return parseInt("FFFFFF",16);default:a=a.replace(/(#|0x)?([0-9A-F]{3,6})$/gi,"$2");if(a.length==3){a=a.charAt(0)+a.charAt(0)+a.charAt(1)+a.charAt(1)+a.charAt(2)+a.charAt(2)}return parseInt(a,16)}return parseInt("000000",16)}})(jwplayer);(function(b){b.utils.parsers=function(){};b.utils.parsers.localName=function(a){if(!a){return""}else{if(a.localName){return a.localName}else{if(a.baseName){return a.baseName}else{return""}}}};b.utils.parsers.textContent=function(a){if(!a){return""}else{if(a.textContent){return a.textContent}else{if(a.text){return a.text}else{return""}}}}})(jwplayer);(function(b){b.utils.parsers.jwparser=function(){};b.utils.parsers.jwparser.PREFIX="jwplayer";b.utils.parsers.jwparser.parseEntry=function(f,e){for(var a=0;a-1){e.file=e.link}}return e};b.utils.parsers.jwparser.getProvider=function(d){if(d.type){return d.type}else{if(d.file.indexOf("youtube.com/w")>-1||d.file.indexOf("youtube.com/v")>-1||d.file.indexOf("youtu.be/")>-1){return"youtube"}else{if(d.streamer&&d.streamer.indexOf("rtmp")==0){return"rtmp"}else{if(d.streamer&&d.streamer.indexOf("http")==0){return"http"}else{var a=b.utils.strings.extension(d.file);if(extensions.hasOwnProperty(a)){return extensions[a]}}}}}return""}})(jwplayer);(function(b){b.utils.parsers.mediaparser=function(){};b.utils.parsers.mediaparser.PREFIX="media";b.utils.parsers.mediaparser.parseGroup=function(j,g){var h=false;for(var k=0;k0){g=b.utils.parsers.mediaparser.parseGroup(j.childNodes[k],g)}if(b.utils.strings.xmlAttribute(j.childNodes[k],"width")||b.utils.strings.xmlAttribute(j.childNodes[k],"bitrate")||b.utils.strings.xmlAttribute(j.childNodes[k],"url")){if(!g.levels){g.levels=[]}g.levels.push({width:b.utils.strings.xmlAttribute(j.childNodes[k],"width"),bitrate:b.utils.strings.xmlAttribute(j.childNodes[k],"bitrate"),file:b.utils.strings.xmlAttribute(j.childNodes[k],"url")})}break;case"title":g.title=b.utils.parsers.textContent(j.childNodes[k]);break;case"description":g.description=b.utils.parsers.textContent(j.childNodes[k]);break;case"keywords":g.tags=b.utils.parsers.textContent(j.childNodes[k]);break;case"thumbnail":g.image=b.utils.strings.xmlAttribute(j.childNodes[k],"url");break;case"credit":g.author=b.utils.parsers.textContent(j.childNodes[k]);break;case"player":var a=j.childNodes[k].url;if(a.indexOf("youtube.com")>=0||a.indexOf("youtu.be")>=0){h=true;g.file=b.utils.strings.xmlAttribute(j.childNodes[k],"url")}break;case"group":b.utils.parsers.mediaparser.parseGroup(j.childNodes[k],g);break}}}return g}})(jwplayer);(function(c){c.utils.parsers.rssparser=function(){};c.utils.parsers.rssparser.parse=function(a){var h=[];for(var b=0;b0){m=u;n=b.utils.loaderstatus.COMPLETE;t.sendEvent(b.events.COMPLETE);return}n=b.utils.loaderstatus.LOADING;var c=new b.utils.scriptloader(r());c.addEventListener(b.events.COMPLETE,p);c.addEventListener(b.events.ERROR,q);c.load()}};this.registerPlugin=function(d,e,c){if(a){clearTimeout(a);a=undefined}if(e&&c){m=c;o=e}else{if(typeof e=="string"){m=e}else{if(typeof e=="function"){o=e}else{if(!e&&!c){m=d}}}}n=b.utils.loaderstatus.COMPLETE;t.sendEvent(b.events.COMPLETE)};this.getStatus=function(){return n};this.getPluginName=function(){return b.utils.getPluginName(u)};this.getFlashPath=function(){if(m){switch(b.utils.getPluginPathType(m)){case b.utils.pluginPathType.ABSOLUTE:return m;case b.utils.pluginPathType.RELATIVE:if(u.lastIndexOf(".swf")>0){return b.utils.getAbsolutePath(m,window.location.href)}return b.utils.getAbsolutePath(m,r());case b.utils.pluginPathType.CDN:if(m.indexOf("-")>-1){return m+"h"}return m+"-h"}}return null};this.getJS=function(){return o};this.getPluginmode=function(){if(typeof m!="undefined"&&typeof o!="undefined"){return b.plugins.pluginmodes.HYBRID}else{if(typeof m!="undefined"){return b.plugins.pluginmodes.FLASH}else{if(typeof o!="undefined"){return b.plugins.pluginmodes.JAVASCRIPT}}}};this.getNewInstance=function(e,c,d){return new o(e,c,d)};this.getURL=function(){return u}}})(jwplayer);(function(b){b.plugins.pluginloader=function(m,p){var n={};var a=b.utils.loaderstatus.NEW;var q=false;var s=false;var r=new b.events.eventdispatcher();b.utils.extend(this,r);function o(){if(!s){s=true;a=b.utils.loaderstatus.COMPLETE;r.sendEvent(b.events.COMPLETE)}}function l(){if(!s){var c=0;for(plugin in n){var d=n[plugin].getStatus();if(d==b.utils.loaderstatus.LOADING||d==b.utils.loaderstatus.NEW){c++}}if(c==0){o()}}}this.setupPlugins=function(k,d,e){var c={length:0,plugins:{}};var h={length:0,plugins:{}};for(var j in n){var g=n[j].getPluginName();if(n[j].getFlashPath()){c.plugins[n[j].getFlashPath()]=d.plugins[j];c.plugins[n[j].getFlashPath()].pluginmode=n[j].getPluginmode();c.length++}if(n[j].getJS()){var f=document.createElement("div");f.id=k.id+"_"+g;f.style.position="absolute";f.style.zIndex=h.length+10;h.plugins[g]=n[j].getNewInstance(k,d.plugins[j],f);h.length++;if(typeof h.plugins[g].resize!="undefined"){k.onReady(e(h.plugins[g],f,true));k.onResize(e(h.plugins[g],f))}}}k.plugins=h.plugins;return c};this.load=function(){a=b.utils.loaderstatus.LOADING;q=true;for(var c in p){if(b.utils.exists(c)){n[c]=m.addPlugin(c);n[c].addEventListener(b.events.COMPLETE,l);n[c].addEventListener(b.events.ERROR,l)}}for(c in n){n[c].load()}q=false;l()};this.pluginFailed=function(){o()};this.getStatus=function(){return a}}})(jwplayer);(function(c){var d=[];c.api=function(E){this.container=E;this.id=E.id;var w={};var G={};var t={};var F=[];var B=undefined;var y=false;var A=[];var b=undefined;var u=c.utils.getOuterHTML(E);var a={};var z={};this.getBuffer=function(){return this.callInternal("jwGetBuffer")};this.getContainer=function(){return this.container};function D(e,f){return function(k,j,h,g){if(e.renderingMode=="flash"||e.renderingMode=="html5"){var l;if(j){z[k]=j;l="jwplayer('"+e.id+"').callback('"+k+"')"}else{if(!j&&z[k]){delete z[k]}}B.jwDockSetButton(k,l,h,g)}return f}}this.getPlugin=function(g){var e=this;var f={};if(g=="dock"){return c.utils.extend(f,{setButton:D(e,f),show:function(){e.callInternal("jwDockShow");return f},hide:function(){e.callInternal("jwDockHide");return f},onShow:function(h){e.componentListener("dock",c.api.events.JWPLAYER_COMPONENT_SHOW,h);return f},onHide:function(h){e.componentListener("dock",c.api.events.JWPLAYER_COMPONENT_HIDE,h);return f}})}else{if(g=="controlbar"){return c.utils.extend(f,{show:function(){e.callInternal("jwControlbarShow");return f},hide:function(){e.callInternal("jwControlbarHide");return f},onShow:function(h){e.componentListener("controlbar",c.api.events.JWPLAYER_COMPONENT_SHOW,h);return f},onHide:function(h){e.componentListener("controlbar",c.api.events.JWPLAYER_COMPONENT_HIDE,h);return f}})}else{if(g=="display"){return c.utils.extend(f,{show:function(){e.callInternal("jwDisplayShow");return f},hide:function(){e.callInternal("jwDisplayHide");return f},onShow:function(h){e.componentListener("display",c.api.events.JWPLAYER_COMPONENT_SHOW,h);return f},onHide:function(h){e.componentListener("display",c.api.events.JWPLAYER_COMPONENT_HIDE,h);return f}})}else{return this.plugins[g]}}}};this.callback=function(e){if(z[e]){return z[e]()}};this.getDuration=function(){return this.callInternal("jwGetDuration")};this.getFullscreen=function(){return this.callInternal("jwGetFullscreen")};this.getHeight=function(){return this.callInternal("jwGetHeight")};this.getLockState=function(){return this.callInternal("jwGetLockState")};this.getMeta=function(){return this.getItemMeta()};this.getMute=function(){return this.callInternal("jwGetMute")};this.getPlaylist=function(){var e=this.callInternal("jwGetPlaylist");if(this.renderingMode=="flash"){c.utils.deepReplaceKeyName(e,["__dot__","__spc__","__dsh__"],["."," ","-"])}for(var f=0;f0){this.callInternal.apply(this,A.shift())}};this.getItemMeta=function(){return a};this.getCurrentItem=function(){return this.callInternal("jwGetPlaylistIndex")};function v(g,e,f){var j=[];if(!e){e=0}if(!f){f=g.length-1}for(var h=e;h<=f;h++){j.push(g[h])}return j}return this};c.api.selectPlayer=function(b){var f;if(!c.utils.exists(b)){b=0}if(b.nodeType){f=b}else{if(typeof b=="string"){f=document.getElementById(b)}}if(f){var a=c.api.playerById(f.id);if(a){return a}else{return c.api.addPlayer(new c.api(f))}}else{if(typeof b=="number"){return c.getPlayers()[b]}}return null};c.api.events={API_READY:"jwplayerAPIReady",JWPLAYER_READY:"jwplayerReady",JWPLAYER_FULLSCREEN:"jwplayerFullscreen",JWPLAYER_RESIZE:"jwplayerResize",JWPLAYER_ERROR:"jwplayerError",JWPLAYER_MEDIA_BEFOREPLAY:"jwplayerMediaBeforePlay",JWPLAYER_MEDIA_BEFORECOMPLETE:"jwplayerMediaBeforeComplete",JWPLAYER_COMPONENT_SHOW:"jwplayerComponentShow",JWPLAYER_COMPONENT_HIDE:"jwplayerComponentHide",JWPLAYER_MEDIA_BUFFER:"jwplayerMediaBuffer",JWPLAYER_MEDIA_BUFFER_FULL:"jwplayerMediaBufferFull",JWPLAYER_MEDIA_ERROR:"jwplayerMediaError",JWPLAYER_MEDIA_LOADED:"jwplayerMediaLoaded",JWPLAYER_MEDIA_COMPLETE:"jwplayerMediaComplete",JWPLAYER_MEDIA_SEEK:"jwplayerMediaSeek",JWPLAYER_MEDIA_TIME:"jwplayerMediaTime",JWPLAYER_MEDIA_VOLUME:"jwplayerMediaVolume",JWPLAYER_MEDIA_META:"jwplayerMediaMeta",JWPLAYER_MEDIA_MUTE:"jwplayerMediaMute",JWPLAYER_PLAYER_STATE:"jwplayerPlayerState",JWPLAYER_PLAYLIST_LOADED:"jwplayerPlaylistLoaded",JWPLAYER_PLAYLIST_ITEM:"jwplayerPlaylistItem",JWPLAYER_INSTREAM_CLICK:"jwplayerInstreamClicked",JWPLAYER_INSTREAM_DESTROYED:"jwplayerInstreamDestroyed"};c.api.events.state={BUFFERING:"BUFFERING",IDLE:"IDLE",PAUSED:"PAUSED",PLAYING:"PLAYING"};c.api.playerById=function(a){for(var b=0;b=0){var o=document.getElementById(d[l].id);if(document.getElementById(d[l].id+"_wrapper")){o=document.getElementById(d[l].id+"_wrapper")}if(o){if(n){c.utils.setOuterHTML(o,n)}else{var b=document.createElement("div");var m=o.id;if(o.id.indexOf("_wrapper")==o.id.length-8){newID=o.id.substring(0,o.id.length-8)}b.setAttribute("id",m);o.parentNode.replaceChild(b,o)}}d.splice(l,1)}return null};c.getPlayers=function(){return d.slice(0)}})(jwplayer);var _userPlayerReady=(typeof playerReady=="function")?playerReady:undefined;playerReady=function(c){var d=jwplayer.api.playerById(c.id);if(d){d.playerReady(c)}else{jwplayer.api.selectPlayer(c.id).playerReady(c)}if(_userPlayerReady){_userPlayerReady.call(this,c)}};(function(b){b.api.instream=function(D,x,t,a){var y=D;var E=x;var z=t;var w=a;var B={};var r={};function A(){y.callInternal("jwLoadInstream",t,a)}function u(d,c){E.jwInstreamAddEventListener(c,'function(dat) { jwplayer("'+y.id+'").dispatchInstreamEvent("'+c+'", dat); }')}function C(d,c){if(!B[d]){B[d]=[];u(E,d)}B[d].push(c);return this}function s(d,c){if(!r[d]){r[d]=[];C(b.api.events.JWPLAYER_PLAYER_STATE,v(d))}r[d].push(c);return this}function v(c){return function(g){var h=g.newstate,e=g.oldstate;if(h==c){var f=r[h];if(f){for(var d=0;d-1){return parseInt(a)}}return a}var o=["playlist","dock","controlbar","logo","display"];function p(b){var d={};switch(l.typeOf(b.plugins)){case"object":for(var e in b.plugins){d[l.getPluginName(e)]=e}break;case"string":var c=b.plugins.split(",");for(var a=0;a-1){var d=c.split(".");var e=d[0];var c=d[1];if(l.isInArray(o,e)){r(a,"components",e,c)}else{if(f[e]){r(a,"plugins",f[e],c)}}}}return a};q.embed.config=function(g,h){var j=l.extend({},g);var w;if(s(j.playlist)){w=j.playlist;delete j.playlist}j=q.embed.deserialize(j);j.height=m(j.height);j.width=m(j.width);if(typeof j.plugins=="string"){var f=j.plugins.split(",");if(typeof j.plugins!="object"){j.plugins={}}for(var b=0;b-1)){return true}if(!d||(d&&d=="video")){var c=b.utils.extension(f);if(c&&b.utils.extensionmap[c]){return true}}return false}}})(jwplayer);(function(b){b.embed.flash=function(s,r,n,t,p){function a(e,f,d){var c=document.createElement("param");c.setAttribute("name",f);c.setAttribute("value",d);e.appendChild(c)}function o(d,c,e){return function(h){if(e){document.getElementById(p.id+"_wrapper").appendChild(c)}var f=document.getElementById(p.id).getPluginConfig("display");d.resize(f.width,f.height);var g={left:f.x,top:f.y};b.utils.css(c,g)}}function u(e){if(!e){return{}}var c={};for(var f in e){var g=e[f];for(var d in g){c[f+"."+d]=g[d]}}return c}function q(e,f){if(e[f]){var c=e[f];for(var g in c){var h=c[g];if(typeof h=="string"){if(!e[g]){e[g]=h}}else{for(var d in h){if(!e[g+"."+d]){e[g+"."+d]=h[d]}}}}delete e[f]}}function w(f){if(!f){return{}}var c={},d=[];for(var j in f){var g=b.utils.getPluginName(j);var h=f[j];d.push(j);for(var e in h){c[g+"."+e]=h[e]}}c.plugins=d.join(",");return c}function v(c){var e=c.netstreambasepath?"":"netstreambasepath="+encodeURIComponent(window.location.href.split("#")[0])+"&";for(var d in c){if(typeof(c[d])=="object"){e+=d+"="+encodeURIComponent("[[JSON]]"+b.utils.strings.jsonToString(c[d]))+"&"}else{e+=d+"="+encodeURIComponent(c[d])+"&"}}return e.substring(0,e.length-1)}this.embed=function(){n.id=p.id;var g;var c=b.utils.extend({},n);var f=c.width;var k=c.height;if(s.id+"_wrapper"==s.parentNode.id){g=document.getElementById(s.id+"_wrapper")}else{g=document.createElement("div");g.id=s.id+"_wrapper";b.utils.wrap(s,g);b.utils.css(g,{position:"relative",width:f,height:k})}var e=t.setupPlugins(p,c,o);if(e.length>0){b.utils.extend(c,w(e.plugins))}else{delete c.plugins}var E=["height","width","modes","events"];for(var B=0;B';m+='';m+='';m+='';m+='';m+='';m+='';m+="";b.utils.setOuterHTML(s,m);C=document.getElementById(s.id)}else{var D=document.createElement("object");D.setAttribute("type","application/x-shockwave-flash");D.setAttribute("data",r.src);D.setAttribute("width","100%");D.setAttribute("height","100%");D.setAttribute("bgcolor","#000000");D.setAttribute("id",s.id);D.setAttribute("name",s.id);D.setAttribute("tabindex",0);a(D,"allowfullscreen","true");a(D,"allowscriptaccess","always");a(D,"seamlesstabbing","true");a(D,"wmode",d);a(D,"flashvars",v(c));s.parentNode.replaceChild(D,s);C=D}p.container=C;p.setPlayer(C,"flash")};this.supportsConfig=function(){if(b.utils.hasFlash()){if(n){var c=b.utils.getFirstPlaylistItemFromConfig(n);if(typeof c.file=="undefined"&&typeof c.levels=="undefined"){return true}else{if(c.file){return flashCanPlay(c.file,c.provider)}else{if(c.levels&&c.levels.length){for(var d=0;d0){e.skin=e.skin.replace(/\.zip/i,".xml")}var c=new (b.html5(m)).setup(e);j.container=document.getElementById(j.id);j.setPlayer(c,"html5")}else{return null}};this.supportsConfig=function(){if(!!b.vid.canPlayType){if(a){var c=b.utils.getFirstPlaylistItemFromConfig(a);if(typeof c.file=="undefined"&&typeof c.levels=="undefined"){return true}else{if(c.file){return html5CanPlay(b.vid,c.file,c.provider,c.playlistfile)}else{if(c.levels&&c.levels.length){for(var d=0;d0){ao=f.getElementWidth(f.parentNode(af))*parseInt(r.replace("%"),"")/100}else{ao=r}if(typeof h=="string"&&h.indexOf("%")>0){b=f.getElementHeight(f.parentNode(af))*parseInt(h.replace("%"),"")/100}else{b=h}var n={top:0,bottom:0,left:0,right:0,width:ao,height:b,position:"absolute"};d(T,n);var g={};var k;try{k=ac.plugins.object.display.getDisplayElement()}catch(l){}if(k){g.width=f.parseDimension(k.style.width);g.height=f.parseDimension(k.style.height)}var j=f.extend({},n,g,{zIndex:_instreamArea.style.zIndex,display:_instreamArea.style.display});d(_instreamArea,j);d(af,{height:b,width:ao});var m=ae(P,o);if(m.length>0){a+=m.length;var p=m.indexOf("playlist"),q=m.indexOf("controlbar");if(p>=0&&q>=0){m[p]=m.splice(q,1,m[p])[0]}ae(ak,m,true)}W=f.getElementWidth(T);ad=f.getElementHeight(T)}else{if(!U()){ae(c,o,true)}}aa()}function ae(h,m,l){var k=[];for(var n=0;n-1)}function U(){if(ah.jwGetState()!=e.api.events.state.IDLE&&!Z&&(ac.getMedia()&&ac.getMedia().getDisplayElement()&&ac.getMedia().getDisplayElement().webkitSupportsFullscreen)&&f.useNativeFullscreen()){return true}return false}this.setupInstream=function(h,g){f.css(_instreamArea,{display:"block",position:"absolute"});T.style.display="none";_instreamArea.appendChild(h);ar=g;aq=true};var O=this.destroyInstream=function(){_instreamArea.style.display="none";_instreamArea.innerHTML="";T.style.display="block";ar=null;aq=false;am(ac.width,ac.height)}};e.html5.view.positions={TOP:"TOP",RIGHT:"RIGHT",BOTTOM:"BOTTOM",LEFT:"LEFT",OVER:"OVER",NONE:"NONE"}})(jwplayer);(function(d){var c={backgroundcolor:"",margin:10,font:"Arial,sans-serif",fontsize:10,fontcolor:parseInt("000000",16),fontstyle:"normal",fontweight:"bold",buttoncolor:parseInt("ffffff",16),position:d.html5.view.positions.BOTTOM,idlehide:false,hideplaylistcontrols:false,forcenextprev:false,layout:{left:{position:"left",elements:[{name:"play",type:"button"},{name:"divider",type:"divider"},{name:"prev",type:"button"},{name:"divider",type:"divider"},{name:"next",type:"button"},{name:"divider",type:"divider"},{name:"elapsed",type:"text"}]},center:{position:"center",elements:[{name:"time",type:"slider"}]},right:{position:"right",elements:[{name:"duration",type:"text"},{name:"blank",type:"button"},{name:"divider",type:"divider"},{name:"mute",type:"button"},{name:"volume",type:"slider"},{name:"divider",type:"divider"},{name:"fullscreen",type:"button"}]}}};_utils=d.utils;_css=_utils.css;_hide=function(a){_css(a,{display:"none"})};_show=function(a){_css(a,{display:"block"})};d.html5.controlbar=function(ba,am){window.controlbar=this;var bb=ba;var aP=_utils.extend({},c,bb.skin.getComponentSettings("controlbar"),am);if(aP.position==d.html5.view.positions.NONE||typeof d.html5.view.positions[aP.position]=="undefined"){return}if(_utils.mapLength(bb.skin.getComponentLayout("controlbar"))>0){aP.layout=bb.skin.getComponentLayout("controlbar")}var aM;var au;var aO;var aN;var a0="none";var be;var bc;var aL;var bf;var bg;var aX;var at={};var a6=false;var bj={};var aU;var bd=false;var a7;var bi;var ap=false;var aJ=false;var aH;var a=new d.html5.eventdispatcher();_utils.extend(this,a);function aB(){if(!aU){aU=bb.skin.getSkinElement("controlbar","background");if(!aU){aU={width:0,height:0,src:null}}}return aU}function aw(){aO=0;aN=0;au=0;if(!a6){var e={height:aB().height,backgroundColor:aP.backgroundcolor};aM=document.createElement("div");aM.id=bb.id+"_jwplayer_controlbar";_css(aM,e)}var f=(bb.skin.getSkinElement("controlbar","capLeft"));var g=(bb.skin.getSkinElement("controlbar","capRight"));if(f){aY("capLeft","left",false,aM)}aT("background",aM,{position:"absolute",height:aB().height,left:(f?f.width:0),zIndex:0},"img");if(aB().src){at.background.src=aB().src}aT("elements",aM,{position:"relative",height:aB().height,zIndex:1});if(g){aY("capRight","right",false,aM)}}this.getDisplayElement=function(){return aM};this.resize=function(e,g){ar();_utils.cancelAnimation(aM);bg=e;aX=g;if(aJ!=bb.jwGetFullscreen()){aJ=bb.jwGetFullscreen();if(!aJ){b()}bi=undefined}var f=aZ();aC({id:bb.id,duration:aL,position:bc});a1({id:bb.id,bufferPercent:bf});return f};this.show=function(){if(bd){bd=false;_show(aM);ao()}};this.hide=function(){if(!bd){bd=true;_hide(aM);aR()}};function a5(){var f=["timeSlider","volumeSlider","timeSliderRail","volumeSliderRail"];for(var e in f){var g=f[e];if(typeof at[g]!="undefined"){bj[g]=_utils.getBoundingClientRect(at[g])}}}var bh;function b(e){if(bd){return}clearTimeout(a7);if(aP.position==d.html5.view.positions.OVER||bb.jwGetFullscreen()){switch(bb.jwGetState()){case d.api.events.state.PAUSED:case d.api.events.state.IDLE:if(aM&&aM.style.opacity<1&&(!aP.idlehide||_utils.exists(e))){bh=false;setTimeout(function(){if(!bh){an()}},100)}if(aP.idlehide){a7=setTimeout(function(){aV()},2000)}break;default:bh=true;if(e){an()}a7=setTimeout(function(){aV()},2000);break}}else{an()}}function aV(){if(!bd){aR();if(aM.style.opacity==1){_utils.cancelAnimation(aM);_utils.fadeTo(aM,0,0.1,1,0)}}}function an(){if(!bd){ao();if(aM.style.opacity==0){_utils.cancelAnimation(aM);_utils.fadeTo(aM,1,0.1,0,0)}}}function aF(e){return function(){if(ap&&bi!=e){bi=e;a.sendEvent(e,{component:"controlbar",boundingRect:av()})}}}var ao=aF(d.api.events.JWPLAYER_COMPONENT_SHOW);var aR=aF(d.api.events.JWPLAYER_COMPONENT_HIDE);function av(){if(aP.position==d.html5.view.positions.OVER||bb.jwGetFullscreen()){return _utils.getDimensions(aM)}else{return{x:0,y:0,width:0,height:0}}}function aT(e,f,g,j){var h;if(!a6){if(!j){j="div"}h=document.createElement(j);at[e]=h;h.id=aM.id+"_"+e;f.appendChild(h)}else{h=document.getElementById(aM.id+"_"+e)}if(_utils.exists(g)){_css(h,g)}return h}function ax(){if(bb.jwGetHeight()<=40){aP.layout=_utils.clone(aP.layout);for(var e=0;e0||m.indexOf("divider")===0){var k={height:"100%",position:l?l:"relative",display:"block","float":"left",styleFloat:"left",cssFloat:"left"};if((m.indexOf("next")===0||m.indexOf("prev")===0)&&(bb.jwGetPlaylist().length<2||aP.hideplaylistcontrols.toString()=="true")){if(aP.forcenextprev.toString()!="true"){o=false;k.display="none"}}var e;if(m.indexOf("Text")>0){m.innerhtml="00:00";k.font=aP.fontsize+"px/"+(aB().height+1)+"px "+aP.font;k.color=aP.fontcolor;k.textAlign="center";k.fontWeight=aP.fontweight;k.fontStyle=aP.fontstyle;k.cursor="default";if(n){k.background="url("+n.src+") no-repeat center";k.backgroundSize="100% "+aB().height+"px"}k.padding="0 5px"}else{if(m.indexOf("divider")===0){if(p){if(!isNaN(parseInt(p))){e=parseInt(p)}}else{if(n){var h=bb.skin.getSkinElement("controlbar",n);if(h){k.background="url("+h.src+") repeat-x center left";e=h.width}}else{k.background="url("+bb.skin.getSkinElement("controlbar","divider").src+") repeat-x center left";e=bb.skin.getSkinElement("controlbar","divider").width}}}else{k.background="url("+bb.skin.getSkinElement("controlbar",m).src+") repeat-x center left";e=bb.skin.getSkinElement("controlbar",m).width}}if(j=="left"){if(o){aO+=e}}else{if(j=="right"){if(o){aN+=e}}}if(_utils.typeOf(f)=="undefined"){f=at.elements}k.width=e;if(a6){_css(at[m],k)}else{var g=aT(m,f,k);if(_utils.exists(bb.skin.getSkinElement("controlbar",m+"Over"))){g.onmouseover=function(q){g.style.backgroundImage=["url(",bb.skin.getSkinElement("controlbar",m+"Over").src,")"].join("")};g.onmouseout=function(q){g.style.backgroundImage=["url(",bb.skin.getSkinElement("controlbar",m).src,")"].join("")}}if(m.indexOf("divider")==0){g.setAttribute("class","divider")}g.innerHTML=" "}}}function aK(){bb.jwAddEventListener(d.api.events.JWPLAYER_PLAYLIST_LOADED,aS);bb.jwAddEventListener(d.api.events.JWPLAYER_PLAYLIST_ITEM,a3);bb.jwAddEventListener(d.api.events.JWPLAYER_MEDIA_BUFFER,a1);bb.jwAddEventListener(d.api.events.JWPLAYER_PLAYER_STATE,a4);bb.jwAddEventListener(d.api.events.JWPLAYER_MEDIA_TIME,aC);bb.jwAddEventListener(d.api.events.JWPLAYER_MEDIA_MUTE,aD);bb.jwAddEventListener(d.api.events.JWPLAYER_MEDIA_VOLUME,a9);bb.jwAddEventListener(d.api.events.JWPLAYER_MEDIA_COMPLETE,ay)}function aS(){if(!aP.hideplaylistcontrols){if(bb.jwGetPlaylist().length>1||aP.forcenextprev.toString()=="true"){_show(at.nextButton);_show(at.prevButton)}else{_hide(at.nextButton);_hide(at.prevButton)}aZ();aI()}}function a3(e){aL=bb.jwGetPlaylist()[e.index].duration;aC({id:bb.id,duration:aL,position:0});a1({id:bb.id,bufferProgress:0})}function aI(){aC({id:bb.id,duration:bb.jwGetDuration(),position:0});a1({id:bb.id,bufferProgress:0});aD({id:bb.id,mute:bb.jwGetMute()});a4({id:bb.id,newstate:d.api.events.state.IDLE});a9({id:bb.id,volume:bb.jwGetVolume()})}function aq(f,e,g){if(a6){return}if(_utils.exists(bb.skin.getSkinElement("controlbar",f))){var h=at[f];if(_utils.exists(h)){_css(h,{cursor:"pointer"});if(e=="fullscreen"){h.onmouseup=function(j){j.stopPropagation();bb.jwSetFullscreen(!bb.jwGetFullscreen())}}else{h.onmouseup=function(j){j.stopPropagation();if(_utils.exists(g)){bb[e](g)}else{bb[e]()}}}}}}function aW(f){if(a6){return}var e=at[f+"Slider"];_css(at.elements,{cursor:"pointer"});_css(e,{cursor:"pointer"});e.onmousedown=function(g){a0=f};e.onmouseup=function(g){g.stopPropagation();aE(g.pageX)};e.onmousemove=function(h){if(a0=="time"){be=true;var g=h.pageX-bj[f+"Slider"].left-window.pageXOffset;_css(at[a0+"SliderThumb"],{left:g})}}}function aE(g){be=false;var h;if(a0=="time"){h=g-bj.timeSliderRail.left+window.pageXOffset;var e=h/bj.timeSliderRail.width*aL;if(e<0){e=0}else{if(e>aL){e=aL-3}}if(bb.jwGetState()==d.api.events.state.PAUSED||bb.jwGetState()==d.api.events.state.IDLE){bb.jwPlay()}bb.jwSeek(e)}else{if(a0=="volume"){h=g-bj.volumeSliderRail.left-window.pageXOffset;var f=Math.round(h/bj.volumeSliderRail.width*100);if(f<10){f=0}else{if(f>100){f=100}}if(bb.jwGetMute()){bb.jwSetMute(false)}bb.jwSetVolume(f)}}a0="none"}function a1(g){if(_utils.exists(g.bufferPercent)){bf=g.bufferPercent}if(bj.timeSliderRail){var e=bb.skin.getSkinElement("controlbar","timeSliderCapLeft");var f=bj.timeSliderRail.width;var h=isNaN(Math.round(f*bf/100))?0:Math.round(f*bf/100);_css(at.timeSliderBuffer,{width:h,left:e?e.width:0})}}function aD(e){if(e.mute){_hide(at.muteButton);_show(at.unmuteButton);_hide(at.volumeSliderProgress)}else{_show(at.muteButton);_hide(at.unmuteButton);_show(at.volumeSliderProgress)}}function a4(e){if(e.newstate==d.api.events.state.BUFFERING||e.newstate==d.api.events.state.PLAYING){_show(at.pauseButton);_hide(at.playButton)}else{_hide(at.pauseButton);_show(at.playButton)}b();if(e.newstate==d.api.events.state.IDLE){_hide(at.timeSliderBuffer);_hide(at.timeSliderProgress);_hide(at.timeSliderThumb);aC({id:bb.id,duration:bb.jwGetDuration(),position:0})}else{_show(at.timeSliderBuffer);if(e.newstate!=d.api.events.state.BUFFERING){_show(at.timeSliderProgress);_show(at.timeSliderThumb)}}}function ay(e){a1({bufferPercent:0});aC(_utils.extend(e,{position:0,duration:aL}))}function aC(g){if(_utils.exists(g.position)){bc=g.position}if(_utils.exists(g.duration)){aL=g.duration}var j=(bc===aL===0)?0:bc/aL;var e=bj.timeSliderRail;if(e){var k=isNaN(Math.round(e.width*j))?0:Math.round(e.width*j);var f=bb.skin.getSkinElement("controlbar","timeSliderCapLeft");var h=k+(f?f.width:0);if(at.timeSliderProgress){_css(at.timeSliderProgress,{width:k,left:f?f.width:0});if(!be){if(at.timeSliderThumb){at.timeSliderThumb.style.left=h+"px"}}}}if(at.durationText){at.durationText.innerHTML=_utils.timeFormat(aL)}if(at.elapsedText){at.elapsedText.innerHTML=_utils.timeFormat(bc)}}function a8(){var k=at.elements.childNodes;var e,g;for(var h=0;h0?bb.id.replace("_instream",""):bb.id);aH=document.getElementById(e);aH.addEventListener("mousemove",b)}catch(f){_utils.log("Could not add mouse listeners to controlbar: "+f)}}function a2(){aw();ax();a5();a6=true;aK();aP.idlehide=(aP.idlehide.toString().toLowerCase()=="true");if(aP.position==d.html5.view.positions.OVER&&aP.idlehide){aM.style.opacity=0;ap=true}else{aM.style.opacity=1;setTimeout((function(){ap=true;ao()}),1)}ar();aI()}a2();return this}})(jwplayer);(function(d){var e=["width","height","state","playlist","item","position","buffer","duration","volume","mute","fullscreen"];var f=d.utils;d.html5.controller=function(av,Y,aD,aB){var aw=av,ax=aD,aA=aB,ak=Y,W=true,ac=-1,ai=false,aF=false,T,ag=[],at=false;var af=(f.exists(ax.config.debug)&&(ax.config.debug.toString().toLowerCase()=="console")),V=new d.html5.eventdispatcher(ak.id,af);f.extend(this,V);function X(g){if(at){V.sendEvent(g.type,g)}else{ag.push(g)}}function aq(j){if(!at){at=true;V.sendEvent(d.api.events.JWPLAYER_READY,j);if(d.utils.exists(window.playerReady)){playerReady(j)}if(d.utils.exists(window[aD.config.playerReady])){window[aD.config.playerReady](j)}while(ag.length>0){var g=ag.shift();V.sendEvent(g.type,g)}if(aD.config.autostart&&!d.utils.isIOS()){U()}while(al.length>0){var h=al.shift();ah(h.method,h.arguments)}}}ax.addGlobalListener(X);ax.addEventListener(d.api.events.JWPLAYER_MEDIA_BUFFER_FULL,function(){ax.getMedia().play()});ax.addEventListener(d.api.events.JWPLAYER_MEDIA_TIME,function(g){if(g.position>=ax.playlist[ax.item].start&&ac>=0){ax.playlist[ax.item].start=ac;ac=-1}});ax.addEventListener(d.api.events.JWPLAYER_MEDIA_COMPLETE,function(g){setTimeout(ae,25)});ax.addEventListener(d.api.events.JWPLAYER_PLAYLIST_LOADED,U);ax.addEventListener(d.api.events.JWPLAYER_FULLSCREEN,au);function ad(){try{T=ad;if(!ai){ai=true;V.sendEvent(d.api.events.JWPLAYER_MEDIA_BEFOREPLAY);ai=false;if(aF){aF=false;T=null;return}}an(ax.item);if(ax.playlist[ax.item].levels[0].file.length>0){if(W||ax.state==d.api.events.state.IDLE){ax.getMedia().load(ax.playlist[ax.item]);W=false}else{if(ax.state==d.api.events.state.PAUSED){ax.getMedia().play()}}}return true}catch(g){V.sendEvent(d.api.events.JWPLAYER_ERROR,g);T=null}return false}function aE(){try{if(ax.playlist[ax.item].levels[0].file.length>0){switch(ax.state){case d.api.events.state.PLAYING:case d.api.events.state.BUFFERING:if(ax.getMedia()){ax.getMedia().pause()}break;default:if(ai){aF=true}}}return true}catch(g){V.sendEvent(d.api.events.JWPLAYER_ERROR,g)}return false}function aj(h){try{if(ax.playlist[ax.item].levels[0].file.length>0){if(typeof h!="number"){h=parseFloat(h)}switch(ax.state){case d.api.events.state.IDLE:if(ac<0){ac=ax.playlist[ax.item].start;ax.playlist[ax.item].start=h}if(!ai){ad()}break;case d.api.events.state.PLAYING:case d.api.events.state.PAUSED:case d.api.events.state.BUFFERING:ax.seek(h);break}}return true}catch(g){V.sendEvent(d.api.events.JWPLAYER_ERROR,g)}return false}function am(h){T=null;if(!f.exists(h)){h=true}try{if((ax.state!=d.api.events.state.IDLE||h)&&ax.getMedia()){ax.getMedia().stop(h)}if(ai){aF=true}return true}catch(g){V.sendEvent(d.api.events.JWPLAYER_ERROR,g)}return false}function az(){try{if(ax.playlist[ax.item].levels[0].file.length>0){if(ax.config.shuffle){an(a())}else{if(ax.item+1==ax.playlist.length){an(0)}else{an(ax.item+1)}}}if(ax.state!=d.api.events.state.IDLE){var g=ax.state;ax.state=d.api.events.state.IDLE;V.sendEvent(d.api.events.JWPLAYER_PLAYER_STATE,{oldstate:g,newstate:d.api.events.state.IDLE})}ad();return true}catch(h){V.sendEvent(d.api.events.JWPLAYER_ERROR,h)}return false}function aa(){try{if(ax.playlist[ax.item].levels[0].file.length>0){if(ax.config.shuffle){an(a())}else{if(ax.item===0){an(ax.playlist.length-1)}else{an(ax.item-1)}}}if(ax.state!=d.api.events.state.IDLE){var g=ax.state;ax.state=d.api.events.state.IDLE;V.sendEvent(d.api.events.JWPLAYER_PLAYER_STATE,{oldstate:g,newstate:d.api.events.state.IDLE})}ad();return true}catch(h){V.sendEvent(d.api.events.JWPLAYER_ERROR,h)}return false}function a(){var g=null;if(ax.playlist.length>1){while(!f.exists(g)){g=Math.floor(Math.random()*ax.playlist.length);if(g==ax.item){g=null}}}else{g=0}return g}function ab(h){if(!ax.playlist||!ax.playlist[h]){return false}try{if(ax.playlist[h].levels[0].file.length>0){var g=ax.state;if(g!==d.api.events.state.IDLE){if(ax.playlist[ax.item]&&ax.playlist[ax.item].provider==ax.playlist[h].provider){am(false)}else{am()}}an(h);ad()}return true}catch(j){V.sendEvent(d.api.events.JWPLAYER_ERROR,j)}return false}function an(g){if(!ax.playlist[g]){return}ax.setActiveMediaProvider(ax.playlist[g]);if(ax.item!=g){ax.item=g;W=true;V.sendEvent(d.api.events.JWPLAYER_PLAYLIST_ITEM,{index:g})}}function aC(h){try{an(ax.item);var g=ax.getMedia();switch(typeof(h)){case"number":g.volume(h);break;case"string":g.volume(parseInt(h,10));break}ax.setVolume(h);return true}catch(j){V.sendEvent(d.api.events.JWPLAYER_ERROR,j)}return false}function ar(h){try{an(ax.item);var g=ax.getMedia();if(typeof h=="undefined"){g.mute(!ax.mute);ax.setMute(!ax.mute)}else{if(h.toString().toLowerCase()=="true"){g.mute(true);ax.setMute(true)}else{g.mute(false);ax.setMute(false)}}return true}catch(j){V.sendEvent(d.api.events.JWPLAYER_ERROR,j)}return false}function Z(h,j){try{ax.width=h;ax.height=j;aA.resize(h,j);V.sendEvent(d.api.events.JWPLAYER_RESIZE,{width:ax.width,height:ax.height});return true}catch(g){V.sendEvent(d.api.events.JWPLAYER_ERROR,g)}return false}function ao(h,g){try{if(typeof h=="undefined"){h=!ax.fullscreen}if(typeof g=="undefined"){g=true}if(h!=ax.fullscreen){ax.fullscreen=(h.toString().toLowerCase()=="true");aA.fullscreen(ax.fullscreen);if(g){V.sendEvent(d.api.events.JWPLAYER_FULLSCREEN,{fullscreen:ax.fullscreen})}V.sendEvent(d.api.events.JWPLAYER_RESIZE,{width:ax.width,height:ax.height})}return true}catch(j){V.sendEvent(d.api.events.JWPLAYER_ERROR,j)}return false}function b(h){try{am();if(ai){aF=false}ax.loadPlaylist(h);if(ax.playlist[ax.item].provider){an(ax.item);if(ax.config.autostart.toString().toLowerCase()=="true"&&!f.isIOS()&&!ai){ad()}return true}else{return false}}catch(g){V.sendEvent(d.api.events.JWPLAYER_ERROR,g)}return false}function U(g){if(!f.isIOS()){an(ax.item);if(ax.config.autostart.toString().toLowerCase()=="true"&&!f.isIOS()){ad()}}}function au(g){ao(g.fullscreen,false)}function ap(){try{return ax.getMedia().detachMedia()}catch(g){return null}}function ay(){try{var h=ax.getMedia().attachMedia();if(typeof T=="function"){T()}}catch(g){return null}}d.html5.controller.repeatoptions={LIST:"LIST",ALWAYS:"ALWAYS",SINGLE:"SINGLE",NONE:"NONE"};function ae(){if(ax.state!=d.api.events.state.IDLE){return}T=ae;switch(ax.config.repeat.toUpperCase()){case d.html5.controller.repeatoptions.SINGLE:ad();break;case d.html5.controller.repeatoptions.ALWAYS:if(ax.item==ax.playlist.length-1&&!ax.config.shuffle){ab(0)}else{az()}break;case d.html5.controller.repeatoptions.LIST:if(ax.item==ax.playlist.length-1&&!ax.config.shuffle){am();an(0)}else{az()}break;default:am();break}}var al=[];function c(g){return function(){if(at){ah(g,arguments)}else{al.push({method:g,arguments:arguments})}}}function ah(g,h){var j=[];for(i=0;i