(function(){var a=Function.prototype.call,b=Object.prototype,h=Array.prototype.slice,k,j;if(!Function.prototype.bind)Function.prototype.bind=function(a){var e=this;if("function"!=typeof e)throw new TypeError;var d=h.call(arguments,1),m=function(){if(this instanceof m){var b=function(){};b.prototype=e.prototype;var b=new b,j=e.apply(b,d.concat(h.call(arguments)));return null!==j&&Object(j)===j?j:b}return e.apply(a,d.concat(h.call(arguments)))};return m};j=a.bind(b.toString);k=a.bind(b.hasOwnProperty); if(!Array.isArray)Array.isArray=function(a){return"[object Array]"==j(a)};if(!Array.prototype.forEach)Array.prototype.forEach=function(a,e){var b=q(this),d=0,l=b.length>>>0;if("[object Function]"!=j(a))throw new TypeError;for(;d>>0,l=Array(d);if("[object Function]"!=j(a))throw new TypeError;for(var g=0;g>>0,l=[];if("[object Function]"!=j(a))throw new TypeError;for(var g=0;g>>0;if("[object Function]"!=j(a))throw new TypeError;for(var g=0;g>>0;if("[object Function]"!=j(a))throw new TypeError; for(var g=0;g>>0;if("[object Function]"!=j(a))throw new TypeError;if(!b&&1==arguments.length)throw new TypeError;var e=0,g;if(2<=arguments.length)g=arguments[1];else{do{if(e in d){g=d[e++];break}if(++e>=b)throw new TypeError;}while(1)}for(;e>>0;if("[object Function]"!=j(a))throw new TypeError;if(!b&&1==arguments.length)throw new TypeError;var e,b=b-1;if(2<=arguments.length)e=arguments[1];else{do{if(b in d){e=d[b--];break}if(0>--b)throw new TypeError;}while(1)}do b in this&&(e=a.call(void 0,e,d[b],b,d));while(b--);return e};if(!Array.prototype.indexOf)Array.prototype.indexOf=function(a){var b=q(this),d=b.length>>>0;if(!d)return-1;var e=0;1>>0;if(!b)return-1;var d=b-1;1b&&(a[d]="0"+b);return a.slice(0,3).join("-")+"T"+ a.slice(3).join(":")+"."+("000"+this.getUTCMilliseconds()).slice(-3)+"Z"};if(!Date.now)Date.now=function(){return(new Date).getTime()};if(!Date.prototype.toJSON)Date.prototype.toJSON=function(){if("function"!=typeof this.toISOString)throw new TypeError;return this.toISOString()};a="\t\n\u000b\u000c\r \u00a0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029\ufeff";if(!String.prototype.trim||a.trim()){var a="["+a+"]",o=RegExp("^"+a+a+"*"),l= RegExp(a+a+"*$");String.prototype.trim=function(){return(""+this).replace(o,"").replace(l,"")}}var s=function(a){a=+a;a!==a?a=-1:0!==a&&a!==1/0&&a!==-(1/0)&&(a=(0h&&7=c.duration||c.duration===c._lastDuration)c.duration=d}catch(f){}c.duration&& c.duration!=c._lastDuration?(m(c._elem,"durationchange"),("audio"==c._elemNodeName||c._callMeta)&&e.jwEvents.Model.META(a.extend({duration:c.duration},b),c),c._durationCalcs--):c._durationCalcs++}},c=function(a,b){3>a&&clearTimeout(b._canplaythroughTimer);if(3<=a&&3>b.readyState)b.readyState=a,m(b._elem,"canplay"),clearTimeout(b._canplaythroughTimer),b._canplaythroughTimer=setTimeout(function(){c(4,b)},4E3);if(4<=a&&4>b.readyState)b.readyState=a,m(b._elem,"canplaythrough");b.readyState=a};e.jwEvents= {View:{PLAY:function(a){var c=n(a.id);if(c&&!c.stopPlayPause&&(c._ppFlag=!0,c.paused==a.state)){c.paused=!a.state;if(c.ended)c.ended=!1;m(c._elem,a.state?"play":"pause")}}},Model:{BUFFER:function(b){var d=n(b.id);if(d&&"percentage"in b&&d._bufferedEnd!=b.percentage){d.networkState=100==b.percentage?1:2;(isNaN(d.duration)||5b.percentage||100===b.percentage)&&f(d,b);if(d.ended)d.ended=!1;if(d.duration){2b.percentage?c(3,d):20b.percentage)d._bufferedStart=d.currentTime||0;d._bufferedEnd=b.percentage;d.buffered.length=1;if(100==b.percentage)d.networkState=1,c(4,d);a.event.trigger("progress",j,d._elem,!0)}}},META:function(a,b){if(b=b&&b.networkState?b:n(a.id))if("duration"in a){if(!b._metadata||!((!a.height||b.videoHeight==a.height)&&a.duration===b.duration)){b._metadata=!0;var d=b.duration;if(a.duration)b.duration=a.duration;b._lastDuration=b.duration;if(a.height||a.width)b.videoHeight=a.height||0,b.videoWidth= a.width||0;if(!b.networkState)b.networkState=2;1>b.readyState&&c(1,b);b.duration&&d!==b.duration&&m(b._elem,"durationchange");m(b._elem,"loadedmetadata")}}else b._callMeta=!0},TIME:function(a){var b=n(a.id);if(b&&b.currentTime!==a.position){b.currentTime=a.position;b.duration&&b.durationb.readyState&&c(2,b);if(b.ended)b.ended=!1;m(b._elem,"timeupdate")}},STATE:function(a){var b=n(a.id);if(b)switch(a.newstate){case "BUFFERING":if(b.ended)b.ended=!1;c(1,b);m(b._elem,"waiting"); break;case "PLAYING":b.paused=!1;b._ppFlag=!0;b.duration||f(b,a);3>b.readyState&&c(3,b);if(b.ended)b.ended=!1;m(b._elem,"playing");break;case "PAUSED":if(!b.paused&&!b.stopPlayPause)b.paused=!0,b._ppFlag=!0,m(b._elem,"pause");break;case "COMPLETED":4>b.readyState&&c(4,b),b.ended=!0,m(b._elem,"ended")}}},Controller:{ERROR:function(a){var b=n(a.id);b&&e.setError(b._elem,a.message)},SEEK:function(a){var b=n(a.id);if(b){if(b.ended)b.ended=!1;if(b.paused)try{b.jwapi.sendEvent("play","false")}catch(c){}if(b.currentTime!= a.position)b.currentTime=a.position,m(b._elem,"timeupdate")}},VOLUME:function(a){var b=n(a.id);if(b&&(a=a.percentage/100,b.volume!=a))b.volume=a,m(b._elem,"volumechange")},MUTE:function(a){if(!a.state){var b=n(a.id);if(b&&b.muted!=a.state)b.muted=a.state,m(b._elem,"volumechange")}}}};var i=function(b){var c=!0;a.each(e.jwEvents,function(d,e){a.each(e,function(a){try{b.jwapi["add"+d+"Listener"](a,"jQuery.webshims.mediaelement.jwEvents."+d+"."+a)}catch(e){return c=!1}})});return c},D=function(a){var b= a.actionQueue.length,c=0,d;if(b&&"flash"==a.isActive)for(;a.actionQueue.length&&b>c;)c++,d=a.actionQueue.shift(),a.jwapi[d.fn].apply(a.jwapi,d.args);if(a.actionQueue.length)a.actionQueue=[]},F=function(b){b&&(b._ppFlag===j&&a.prop(b._elem,"autoplay")||!b.paused)&&setTimeout(function(){if("flash"==b.isActive&&(b._ppFlag===j||!b.paused))try{a(b._elem).play()}catch(c){}},1)},I=function(b){if(b&&"video"==b._elemNodeName){var c,d,e,f,g,h,j,l,i=function(i,k){if(k&&i&&!(1>k||1>i||"flash"!=b.isActive))if(c&& (c.remove(),c=!1),f=i,g=k,clearTimeout(j),d="auto"==b._elem.style.width,e="auto"==b._elem.style.height,d||e){h=h||a(b._elem).getShadowElement();var m;d&&!e?(m=h.height(),i*=m/k,k=m):!d&&e&&(m=h.width(),k*=m/i,i=m);l=!0;setTimeout(function(){l=!1},9);h.css({width:i,height:k})}},k=function(){if(!("flash"!=b.isActive||a.prop(b._elem,"readyState")&&a.prop(this,"videoWidth"))){var f=a.prop(b._elem,"poster");if(f&&(d="auto"==b._elem.style.width,e="auto"==b._elem.style.height,d||e))c&&(c.remove(),c=!1), c=a(''),c.bind("load error alreadycomplete",function(){clearTimeout(j);var b=this,d=b.naturalWidth||b.width||b.offsetWidth,e=b.naturalHeight||b.height||b.offsetHeight;e&&d?(i(d,e),b=null):setTimeout(function(){d=b.naturalWidth||b.width||b.offsetWidth;e=b.naturalHeight||b.height||b.offsetHeight;i(d,e);c&&(c.remove(),c=!1);b=null},9);a(this).unbind()}).prop("src",f).appendTo("body").each(function(){this.complete|| this.error?a(this).triggerHandler("alreadycomplete"):(clearTimeout(j),j=setTimeout(function(){a(b._elem).triggerHandler("error")},9999))})}};a(b._elem).bind("loadedmetadata",function(){i(a.prop(this,"videoWidth"),a.prop(this,"videoHeight"))}).bind("emptied",k).bind("swfstageresize",function(){l||i(f,g)}).bind("emptied",function(){f=void 0;g=void 0}).triggerHandler("swfstageresize");k();a.prop(b._elem,"readyState")&&i(a.prop(b._elem,"videoWidth"),a.prop(b._elem,"videoHeight"))}};e.playerResize=function(b){b&& (b=k.getElementById(b.replace(u,"")))&&a(b).triggerHandler("swfstageresize")};a(k).bind("emptied",function(a){a=p(a.target);F(a)});var E;e.jwPlayerReady=function(c){var d=n(c.id),e=0,f=function(){if(!(9g||6<=g)&&b.warn("mediaelement-swf is only testet with jwplayer 5.6+")}d.wasSwfReady=!0;d.tryedReframeing=0;D(d);F(d)}else clearTimeout(d.reframeTimer),d.reframeTimer=setTimeout(f,9*e),2d.tryedReframeing&& (d.tryedReframeing++,d.shadowElem.css({overflow:"visible"}),setTimeout(function(){d.shadowElem.css({overflow:"hidden"})},16))};if(d&&d.jwapi){if(!d.tryedReframeing)d.tryedReframeing=0;clearTimeout(E);d.jwData=c;d.shadowElem.removeClass("flashblocker-assumed");a.prop(d._elem,"volume",d.volume);a.prop(d._elem,"muted",d.muted);f()}};var z=a.noop;if(g){var A={play:1,playing:1},x="play,pause,playing,canplay,progress,waiting,ended,loadedmetadata,durationchange,emptied".split(","),G=x.map(function(a){return a+ ".webshimspolyfill"}).join(" "),J=function(c){var d=b.data(c.target,"mediaelement");d&&(c.originalEvent&&c.originalEvent.type===c.type)==("flash"==d.activating)&&(c.stopImmediatePropagation(),A[c.type]&&d.isActive!=d.activating&&a(c.target).pause())},z=function(c){a(c).unbind(G).bind(G,J);x.forEach(function(a){b.moveToFirstEvent(c,a)})};z(k)}e.setActive=function(c,d,e){e||(e=b.data(c,"mediaelement"));if(e&&e.isActive!=d){"html5"!=d&&"flash"!=d&&b.warn("wrong type for mediaelement activating: "+d); var f=b.data(c,"shadowData");e.activating=d;a(c).pause();e.isActive=d;"flash"==d?(f.shadowElement=f.shadowFocusElement=e.shadowElem[0],a(c).hide().getShadowElement().show()):(a(c).show().getShadowElement().hide(),f.shadowElement=f.shadowFocusElement=!1)}};var K=function(){var a="_bufferedEnd,_bufferedStart,_metadata,_ppFlag,currentSrc,currentTime,duration,ended,networkState,paused,videoHeight,videoWidth,_callMeta,_durationCalcs".split(","),b=a.length;return function(d){if(d){var e=b,f=d.networkState; for(c(0,d);--e;)delete d[a[e]];d.actionQueue=[];d.buffered.length=0;f&&m(d._elem,"emptied")}}}(),H=function(b,c){var d=b._elem,e=b.shadowElem;a(d)[c?"addClass":"removeClass"]("webshims-controls");"audio"==b._elemNodeName&&!c?e.css({width:0,height:0}):e.css({width:d.style.width||a(d).width(),height:d.style.height||a(d).height()})};e.createSWF=function(c,f,h){if(o){1>l?l=1:l++;var i=a.extend({},d.jwVars,{image:a.prop(c,"poster")||"",file:f.srcProp}),j=a(c).data("jwvars")||{};if(h&&h.swfCreated)e.setActive(c, "flash",h),K(h),h.currentSrc=f.srcProp,a.extend(i,j),d.changeJW(i,c,f,h,"load"),B(c,"sendEvent",["LOAD",i]);else{var k=a.prop(c,"controls"),C="jwplayer-"+b.getID(c),m=a.extend({},d.jwParams,a(c).data("jwparams")),n=c.nodeName.toLowerCase(),s=a.extend({},d.jwAttrs,{name:C,id:C},a(c).data("jwattrs")),p=a('
').css({position:"relative",overflow:"hidden"}),h=b.data(c,"mediaelement",b.objectCreate(q,{actionQueue:{value:[]}, shadowElem:{value:p},_elemNodeName:{value:n},_elem:{value:c},currentSrc:{value:f.srcProp},swfCreated:{value:!0},buffered:{value:{start:function(a){if(a>=h.buffered.length)b.error("buffered index size error");else return 0},end:function(a){if(a>=h.buffered.length)b.error("buffered index size error");else return(h.duration-h._bufferedStart)*h._bufferedEnd/100+h._bufferedStart},length:0}}}));H(h,k);p.insertBefore(c);g&&a.extend(h,{volume:a.prop(c,"volume"),muted:a.prop(c,"muted")});a.extend(i,{id:C, controlbar:k?d.jwVars.controlbar||("video"==n?"over":"bottom"):"video"==n?"none":"bottom",icons:""+(k&&"video"==n)},j,{playerready:"jQuery.webshims.mediaelement.jwPlayerReady"});i.plugins=i.plugins?i.plugins+(","+w):w;b.addShadowDom(c,p);z(c);e.setActive(c,"flash",h);d.changeJW(i,c,f,h,"embed");I(h);t.embedSWF(r,C,"100%","100%","9.0.0",!1,i,m,s,function(d){if(d.success)h.jwapi=d.ref,k||a(d.ref).attr("tabindex","-1").css("outline","none"),setTimeout(function(){if(!d.ref.parentNode&&p[0].parentNode|| "none"==d.ref.style.display)p.addClass("flashblocker-assumed"),a(c).trigger("flashblocker"),b.warn("flashblocker assumed");a(d.ref).css({minHeight:"2px",minWidth:"2px",display:"block"})},9),E||(clearTimeout(E),E=setTimeout(function(){var c=a(d.ref);1c[0].offsetWidth||2>c[0].offsetHeight)&&b.info("JS-SWF connection can't be established on hidden or unconnected flash objects")},8E3))})}}else setTimeout(function(){a(c).mediaLoad()},1)};var B=function(a,b,c,d){return(d=d||p(a))?(d.jwapi&&d.jwapi[b]?d.jwapi[b].apply(d.jwapi,c||[]):(d.actionQueue.push({fn:b,args:c}),10a||100b.browserVersion,N={object:1,OBJECT:1};a.cleanData=function(a){var b,c,d;if(a&&(c=a.length)&&l)for(b=0;b