c3d2-web/content/static/script/podlove-web-player.min.js

3 lines
82 KiB
JavaScript

!function e(t,n,i){function r(a,s){if(!n[a]){if(!t[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(o)return o(a,!0);throw new Error("Cannot find module '"+a+"'")}var l=n[a]={exports:{}};t[a][0].call(l.exports,function(e){var n=t[a][1][e];return r(n?n:e)},l,l.exports,e,t,n,i)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<i.length;a++)r(i[a]);return r}({1:[function(e){(function(){var e=e||{};e.version="2.16.4",e.meIndex=0,e.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","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},e.Utility={encodeUrl:function(e){return encodeURIComponent(e)},escapeHTML:function(e){return e.toString().split("&").join("&amp;").split("<").join("&lt;").split('"').join("&quot;")},absolutizeUrl:function(e){var t=document.createElement("div");return t.innerHTML='<a href="'+this.escapeHTML(e)+'">x</a>',t.firstChild.href},getScriptPath:function(e){for(var t,n,i,r,o,a,s=0,u="",l="",d=document.getElementsByTagName("script"),c=d.length,p=e.length;c>s;s++){for(r=d[s].src,n=r.lastIndexOf("/"),n>-1?(a=r.substring(n+1),o=r.substring(0,n+1)):(a=r,o=""),t=0;p>t;t++)if(l=e[t],i=a.indexOf(l),i>-1){u=o;break}if(""!==u)break}return u},secondsToTimeCode:function(e,t,n,i){"undefined"==typeof n?n=!1:"undefined"==typeof i&&(i=25);var r=Math.floor(e/3600)%24,o=Math.floor(e/60)%60,a=Math.floor(e%60),s=Math.floor((e%1*i).toFixed(3)),u=(t||r>0?(10>r?"0"+r:r)+":":"")+(10>o?"0"+o:o)+":"+(10>a?"0"+a:a)+(n?":"+(10>s?"0"+s:s):"");return u},timeCodeToSeconds:function(e,t,n,i){"undefined"==typeof n?n=!1:"undefined"==typeof i&&(i=25);var r=e.split(":"),o=parseInt(r[0],10),a=parseInt(r[1],10),s=parseInt(r[2],10),u=0,l=0;return n&&(u=parseInt(r[3])/i),l=3600*o+60*a+s+u},convertSMPTEtoSeconds:function(e){if("string"!=typeof e)return!1;e=e.replace(",",".");var t=0,n=-1!=e.indexOf(".")?e.split(".")[1].length:0,i=1;e=e.split(":").reverse();for(var r=0;r<e.length;r++)i=1,r>0&&(i=Math.pow(60,r)),t+=Number(e[r])*i;return Number(t.toFixed(n))},removeSwf:function(t){var n=document.getElementById(t);n&&/object|embed/i.test(n.nodeName)&&(e.MediaFeatures.isIE?(n.style.display="none",function(){4==n.readyState?e.Utility.removeObjectInIE(t):setTimeout(arguments.callee,10)}()):n.parentNode.removeChild(n))},removeObjectInIE:function(e){var t=document.getElementById(e);if(t){for(var n in t)"function"==typeof t[n]&&(t[n]=null);t.parentNode.removeChild(t)}}},e.PluginDetector={hasPluginVersion:function(e,t){var n=this.plugins[e];return t[1]=t[1]||0,t[2]=t[2]||0,n[0]>t[0]||n[0]==t[0]&&n[1]>t[1]||n[0]==t[0]&&n[1]==t[1]&&n[2]>=t[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(e,t,n,i,r){this.plugins[e]=this.detectPlugin(t,n,i,r)},detectPlugin:function(e,t,n,i){var r,o,a,s=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[e]){if(r=this.nav.plugins[e].description,r&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[t]||this.nav.mimeTypes[t].enabledPlugin))for(s=r.replace(e,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),o=0;o<s.length;o++)s[o]=parseInt(s[o].match(/\d+/),10)}else if("undefined"!=typeof window.ActiveXObject)try{a=new ActiveXObject(n),a&&(s=i(a))}catch(u){}return s}},e.PluginDetector.addPlugin("flash","Shockwave Flash","application/x-shockwave-flash","ShockwaveFlash.ShockwaveFlash",function(e){var t=[],n=e.GetVariable("$version");return n&&(n=n.split(" ")[1].split(","),t=[parseInt(n[0],10),parseInt(n[1],10),parseInt(n[2],10)]),t}),e.PluginDetector.addPlugin("silverlight","Silverlight Plug-In","application/x-silverlight-2","AgControl.AgControl",function(e){var t=[0,0,0,0],n=function(e,t,n,i){for(;e.isVersionSupported(t[0]+"."+t[1]+"."+t[2]+"."+t[3]);)t[n]+=i;t[n]-=i};return n(e,t,0,1),n(e,t,1,1),n(e,t,2,1e4),n(e,t,2,1e3),n(e,t,2,100),n(e,t,2,10),n(e,t,2,1),n(e,t,3,1),t}),e.MediaFeatures={init:function(){var t,n,i=this,r=document,o=e.PluginDetector.nav,a=e.PluginDetector.ua.toLowerCase(),s=["source","track","audio","video"];i.isiPad=null!==a.match(/ipad/i),i.isiPhone=null!==a.match(/iphone/i),i.isiOS=i.isiPhone||i.isiPad,i.isAndroid=null!==a.match(/android/i),i.isBustedAndroid=null!==a.match(/android 2\.[12]/),i.isBustedNativeHTTPS="https:"===location.protocol&&(null!==a.match(/android [12]\./)||null!==a.match(/macintosh.* version.* safari/)),i.isIE=-1!=o.appName.toLowerCase().indexOf("microsoft")||null!==o.appName.toLowerCase().match(/trident/gi),i.isChrome=null!==a.match(/chrome/gi),i.isChromium=null!==a.match(/chromium/gi),i.isFirefox=null!==a.match(/firefox/gi),i.isWebkit=null!==a.match(/webkit/gi),i.isGecko=null!==a.match(/gecko/gi)&&!i.isWebkit&&!i.isIE,i.isOpera=null!==a.match(/opera/gi),i.hasTouch="ontouchstart"in window,i.svg=!!document.createElementNS&&!!document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect;for(t=0;t<s.length;t++)n=document.createElement(s[t]);i.supportsMediaTag="undefined"!=typeof n.canPlayType||i.isBustedAndroid;try{n.canPlayType("video/mp4")}catch(u){i.supportsMediaTag=!1}i.hasSemiNativeFullScreen="undefined"!=typeof n.webkitEnterFullscreen,i.hasNativeFullscreen="undefined"!=typeof n.requestFullscreen,i.hasWebkitNativeFullScreen="undefined"!=typeof n.webkitRequestFullScreen,i.hasMozNativeFullScreen="undefined"!=typeof n.mozRequestFullScreen,i.hasMsNativeFullScreen="undefined"!=typeof n.msRequestFullscreen,i.hasTrueNativeFullScreen=i.hasWebkitNativeFullScreen||i.hasMozNativeFullScreen||i.hasMsNativeFullScreen,i.nativeFullScreenEnabled=i.hasTrueNativeFullScreen,i.hasMozNativeFullScreen?i.nativeFullScreenEnabled=document.mozFullScreenEnabled:i.hasMsNativeFullScreen&&(i.nativeFullScreenEnabled=document.msFullscreenEnabled),i.isChrome&&(i.hasSemiNativeFullScreen=!1),i.hasTrueNativeFullScreen&&(i.fullScreenEventName="",i.hasWebkitNativeFullScreen?i.fullScreenEventName="webkitfullscreenchange":i.hasMozNativeFullScreen?i.fullScreenEventName="mozfullscreenchange":i.hasMsNativeFullScreen&&(i.fullScreenEventName="MSFullscreenChange"),i.isFullScreen=function(){return i.hasMozNativeFullScreen?r.mozFullScreen:i.hasWebkitNativeFullScreen?r.webkitIsFullScreen:i.hasMsNativeFullScreen?null!==r.msFullscreenElement:void 0},i.requestFullScreen=function(e){i.hasWebkitNativeFullScreen?e.webkitRequestFullScreen():i.hasMozNativeFullScreen?e.mozRequestFullScreen():i.hasMsNativeFullScreen&&e.msRequestFullscreen()},i.cancelFullScreen=function(){i.hasWebkitNativeFullScreen?document.webkitCancelFullScreen():i.hasMozNativeFullScreen?document.mozCancelFullScreen():i.hasMsNativeFullScreen&&document.msExitFullscreen()}),i.hasSemiNativeFullScreen&&a.match(/mac os x 10_5/i)&&(i.hasNativeFullScreen=!1,i.hasSemiNativeFullScreen=!1)}},e.MediaFeatures.init(),e.HtmlMediaElement={pluginType:"native",isFullScreen:!1,setCurrentTime:function(e){this.currentTime=e},setMuted:function(e){this.muted=e},setVolume:function(e){this.volume=e},stop:function(){this.pause()},setSrc:function(e){for(var t=this.getElementsByTagName("source");t.length>0;)this.removeChild(t[0]);if("string"==typeof e)this.src=e;else{var n,i;for(n=0;n<e.length;n++)if(i=e[n],this.canPlayType(i.type)){this.src=i.src;break}}},setVideoSize:function(e,t){this.width=e,this.height=t}},e.PluginMediaElement=function(e,t,n){this.id=e,this.pluginType=t,this.src=n,this.events={},this.attributes={}},e.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||"vimeo"==this.pluginType?this.pluginApi.playVideo():this.pluginApi.playMedia(),this.paused=!1)},load:function(){null!=this.pluginApi&&("youtube"==this.pluginType||"vimeo"==this.pluginType||this.pluginApi.loadMedia(),this.paused=!1)},pause:function(){null!=this.pluginApi&&("youtube"==this.pluginType||"vimeo"==this.pluginType?this.pluginApi.pauseVideo():this.pluginApi.pauseMedia(),this.paused=!0)},stop:function(){null!=this.pluginApi&&("youtube"==this.pluginType||"vimeo"==this.pluginType?this.pluginApi.stopVideo():this.pluginApi.stopMedia(),this.paused=!0)},canPlayType:function(t){var n,i,r,o=e.plugins[this.pluginType];for(n=0;n<o.length;n++)if(r=o[n],e.PluginDetector.hasPluginVersion(this.pluginType,r.version))for(i=0;i<r.types.length;i++)if(t==r.types[i])return"probably";return""},positionFullscreenButton:function(e,t,n){null!=this.pluginApi&&this.pluginApi.positionFullscreenButton&&this.pluginApi.positionFullscreenButton(Math.floor(e),Math.floor(t),n)},hideFullscreenButton:function(){null!=this.pluginApi&&this.pluginApi.hideFullscreenButton&&this.pluginApi.hideFullscreenButton()},setSrc:function(t){if("string"==typeof t)this.pluginApi.setSrc(e.Utility.absolutizeUrl(t)),this.src=e.Utility.absolutizeUrl(t);else{var n,i;for(n=0;n<t.length;n++)if(i=t[n],this.canPlayType(i.type)){this.pluginApi.setSrc(e.Utility.absolutizeUrl(i.src)),this.src=e.Utility.absolutizeUrl(t);break}}},setCurrentTime:function(e){null!=this.pluginApi&&("youtube"==this.pluginType||"vimeo"==this.pluginType?this.pluginApi.seekTo(e):this.pluginApi.setCurrentTime(e),this.currentTime=e)},setVolume:function(e){null!=this.pluginApi&&("youtube"==this.pluginType?this.pluginApi.setVolume(100*e):this.pluginApi.setVolume(e),this.volume=e)},setMuted:function(e){null!=this.pluginApi&&("youtube"==this.pluginType?(e?this.pluginApi.mute():this.pluginApi.unMute(),this.muted=e,this.dispatchEvent("volumechange")):this.pluginApi.setMuted(e),this.muted=e)},setVideoSize:function(e,t){this.pluginElement&&this.pluginElement.style&&(this.pluginElement.style.width=e+"px",this.pluginElement.style.height=t+"px"),null!=this.pluginApi&&this.pluginApi.setVideoSize&&this.pluginApi.setVideoSize(e,t)},setFullscreen:function(e){null!=this.pluginApi&&this.pluginApi.setFullscreen&&this.pluginApi.setFullscreen(e)},enterFullScreen:function(){null!=this.pluginApi&&this.pluginApi.setFullscreen&&this.setFullscreen(!0)},exitFullScreen:function(){null!=this.pluginApi&&this.pluginApi.setFullscreen&&this.setFullscreen(!1)},addEventListener:function(e,t){this.events[e]=this.events[e]||[],this.events[e].push(t)},removeEventListener:function(e,t){if(!e)return this.events={},!0;var n=this.events[e];if(!n)return!0;if(!t)return this.events[e]=[],!0;for(var i=0;i<n.length;i++)if(n[i]===t)return this.events[e].splice(i,1),!0;return!1},dispatchEvent:function(e){var t,n,i=this.events[e];if(i)for(n=Array.prototype.slice.call(arguments,1),t=0;t<i.length;t++)i[t].apply(this,n)},hasAttribute:function(e){return e in this.attributes},removeAttribute:function(e){delete this.attributes[e]},getAttribute:function(e){return this.hasAttribute(e)?this.attributes[e]:""},setAttribute:function(e,t){this.attributes[e]=t},remove:function(){e.Utility.removeSwf(this.pluginElement.id),e.MediaPluginBridge.unregisterPluginElement(this.pluginElement.id)}},e.MediaPluginBridge={pluginMediaElements:{},htmlMediaElements:{},registerPluginElement:function(e,t,n){this.pluginMediaElements[e]=t,this.htmlMediaElements[e]=n},unregisterPluginElement:function(e){delete this.pluginMediaElements[e],delete this.htmlMediaElements[e]},initPlugin:function(e){var t=this.pluginMediaElements[e],n=this.htmlMediaElements[e];if(t){switch(t.pluginType){case"flash":t.pluginElement=t.pluginApi=document.getElementById(e);break;case"silverlight":t.pluginElement=document.getElementById(t.id),t.pluginApi=t.pluginElement.Content.MediaElementJS}null!=t.pluginApi&&t.success&&t.success(t,n)}},fireEvent:function(e,t,n){var i,r,o,a=this.pluginMediaElements[e];if(a){i={type:t,target:a};for(r in n)a[r]=n[r],i[r]=n[r];o=n.bufferedTime||0,i.target.buffered=i.buffered={start:function(){return 0},end:function(){return o},length:1},a.dispatchEvent(i.type,i)}}},e.MediaElementDefaults={mode:"auto",plugins:["flash","silverlight","youtube","vimeo"],enablePluginDebug:!1,httpsBasicAuthSite:!1,type:"",pluginPath:e.Utility.getScriptPath(["mediaelement.js","mediaelement.min.js","mediaelement-and-player.js","mediaelement-and-player.min.js"]),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(){}},e.MediaElement=function(t,n){return e.HtmlMediaElementShim.create(t,n)},e.HtmlMediaElementShim={create:function(t,n){var i,r,o=e.MediaElementDefaults,a="string"==typeof t?document.getElementById(t):t,s=a.tagName.toLowerCase(),u="audio"===s||"video"===s,l=u?a.getAttribute("src"):a.getAttribute("href"),d=a.getAttribute("poster"),c=a.getAttribute("autoplay"),p=a.getAttribute("preload"),f=a.getAttribute("controls");for(r in n)o[r]=n[r];return l="undefined"==typeof l||null===l||""==l?null:l,d="undefined"==typeof d||null===d?"":d,p="undefined"==typeof p||null===p||"false"===p?"none":p,c=!("undefined"==typeof c||null===c||"false"===c),f=!("undefined"==typeof f||null===f||"false"===f),i=this.determinePlayback(a,o,e.MediaFeatures.supportsMediaTag,u,l),i.url=null!==i.url?e.Utility.absolutizeUrl(i.url):"","native"==i.method?(e.MediaFeatures.isBustedAndroid&&(a.src=i.url,a.addEventListener("click",function(){a.play()},!1)),this.updateNative(i,o,c,p)):""!==i.method?this.createPlugin(i,o,d,c,p,f):(this.createErrorMessage(i,o,d),this)},determinePlayback:function(t,n,i,r,o){var a,s,u,l,d,c,p,f,h,m,g,v=[],b={method:"",url:"",htmlMediaElement:t,isVideo:"audio"!=t.tagName.toLowerCase()};if("undefined"!=typeof n.type&&""!==n.type)if("string"==typeof n.type)v.push({type:n.type,url:o});else for(a=0;a<n.type.length;a++)v.push({type:n.type[a],url:o});else if(null!==o)c=this.formatType(o,t.getAttribute("type")),v.push({type:c,url:o});else for(a=0;a<t.childNodes.length;a++)d=t.childNodes[a],1==d.nodeType&&"source"==d.tagName.toLowerCase()&&(o=d.getAttribute("src"),c=this.formatType(o,d.getAttribute("type")),g=d.getAttribute("media"),(!g||!window.matchMedia||window.matchMedia&&window.matchMedia(g).matches)&&v.push({type:c,url:o}));if(!r&&v.length>0&&null!==v[0].url&&this.getTypeFromFile(v[0].url).indexOf("audio")>-1&&(b.isVideo=!1),e.MediaFeatures.isBustedAndroid&&(t.canPlayType=function(e){return null!==e.match(/video\/(mp4|m4v)/gi)?"maybe":""}),e.MediaFeatures.isChromium&&(t.canPlayType=function(e){return null!==e.match(/video\/(webm|ogv|ogg)/gi)?"maybe":""}),!(!i||"auto"!==n.mode&&"auto_plugin"!==n.mode&&"native"!==n.mode||e.MediaFeatures.isBustedNativeHTTPS&&n.httpsBasicAuthSite===!0)){for(r||(m=document.createElement(b.isVideo?"video":"audio"),t.parentNode.insertBefore(m,t),t.style.display="none",b.htmlMediaElement=t=m),a=0;a<v.length;a++)if("video/m3u8"==v[a].type||""!==t.canPlayType(v[a].type).replace(/no/,"")||""!==t.canPlayType(v[a].type.replace(/mp3/,"mpeg")).replace(/no/,"")||""!==t.canPlayType(v[a].type.replace(/m4a/,"mp4")).replace(/no/,"")){b.method="native",b.url=v[a].url;break}if("native"===b.method&&(null!==b.url&&(t.src=b.url),"auto_plugin"!==n.mode))return b}if("auto"===n.mode||"auto_plugin"===n.mode||"shim"===n.mode)for(a=0;a<v.length;a++)for(c=v[a].type,s=0;s<n.plugins.length;s++)for(p=n.plugins[s],f=e.plugins[p],u=0;u<f.length;u++)if(h=f[u],null==h.version||e.PluginDetector.hasPluginVersion(p,h.version))for(l=0;l<h.types.length;l++)if(c==h.types[l])return b.method=p,b.url=v[a].url,b;return"auto_plugin"===n.mode&&"native"===b.method?b:(""===b.method&&v.length>0&&(b.url=v[0].url),b)},formatType:function(e,t){return e&&!t?this.getTypeFromFile(e):t&&~t.indexOf(";")?t.substr(0,t.indexOf(";")):t},getTypeFromFile:function(e){e=e.split("?")[0];var t=e.substring(e.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(t)?"video":"audio")+"/"+this.getTypeFromExtension(t)},getTypeFromExtension:function(e){switch(e){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return e}},createErrorMessage:function(t,n,i){var r=t.htmlMediaElement,o=document.createElement("div");o.className="me-cannotplay";try{o.style.width=r.width+"px",o.style.height=r.height+"px"}catch(a){}o.innerHTML=n.customError?n.customError:""!==i?'<a href="'+t.url+'"><img src="'+i+'" width="100%" height="100%" /></a>':'<a href="'+t.url+'"><span>'+e.i18n.t("Download File")+"</span></a>",r.parentNode.insertBefore(o,r),r.style.display="none",n.error(r)},createPlugin:function(t,n,i,r,o,a){var s,u,l,d=t.htmlMediaElement,c=1,p=1,f="me_"+t.method+"_"+e.meIndex++,h=new e.PluginMediaElement(f,t.method,t.url),m=document.createElement("div");h.tagName=d.tagName;for(var g=0;g<d.attributes.length;g++){var v=d.attributes[g];1==v.specified&&h.setAttribute(v.name,v.value)}for(u=d.parentNode;null!==u&&"body"!==u.tagName.toLowerCase()&&null!=u.parentNode;){if("p"===u.parentNode.tagName.toLowerCase()){u.parentNode.parentNode.insertBefore(u,u.parentNode);break}u=u.parentNode}switch(t.isVideo?(c=n.pluginWidth>0?n.pluginWidth:n.videoWidth>0?n.videoWidth:null!==d.getAttribute("width")?d.getAttribute("width"):n.defaultVideoWidth,p=n.pluginHeight>0?n.pluginHeight:n.videoHeight>0?n.videoHeight:null!==d.getAttribute("height")?d.getAttribute("height"):n.defaultVideoHeight,c=e.Utility.encodeUrl(c),p=e.Utility.encodeUrl(p)):n.enablePluginDebug&&(c=320,p=240),h.success=n.success,e.MediaPluginBridge.registerPluginElement(f,h,d),m.className="me-plugin",m.id=f+"_container",t.isVideo?d.parentNode.insertBefore(m,d):document.body.insertBefore(m,document.body.childNodes[0]),l=["id="+f,"jsinitfunction=mejs.MediaPluginBridge.initPlugin","jscallbackfunction=mejs.MediaPluginBridge.fireEvent","isvideo="+(t.isVideo?"true":"false"),"autoplay="+(r?"true":"false"),"preload="+o,"width="+c,"startvolume="+n.startVolume,"timerrate="+n.timerRate,"flashstreamer="+n.flashStreamer,"height="+p,"pseudostreamstart="+n.pseudoStreamingStartQueryParam],null!==t.url&&("flash"==t.method?l.push("file="+e.Utility.encodeUrl(t.url)):l.push("file="+t.url)),n.enablePluginDebug&&l.push("debug=true"),n.enablePluginSmoothing&&l.push("smoothing=true"),n.enablePseudoStreaming&&l.push("pseudostreaming=true"),a&&l.push("controls=true"),n.pluginVars&&(l=l.concat(n.pluginVars)),t.method){case"silverlight":m.innerHTML='<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" id="'+f+'" name="'+f+'" width="'+c+'" height="'+p+'" class="mejs-shim"><param name="initParams" value="'+l.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="'+n.pluginPath+n.silverlightName+'" /></object>';break;case"flash":e.MediaFeatures.isIE?(s=document.createElement("div"),m.appendChild(s),s.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" id="'+f+'" width="'+c+'" height="'+p+'" class="mejs-shim"><param name="movie" value="'+n.pluginPath+n.flashName+"?x="+new Date+'" /><param name="flashvars" value="'+l.join("&amp;")+'" /><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" /><param name="scale" value="default" /></object>'):m.innerHTML='<embed id="'+f+'" name="'+f+'" 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="'+n.pluginPath+n.flashName+'" flashvars="'+l.join("&")+'" width="'+c+'" height="'+p+'" scale="default"class="mejs-shim"></embed>';break;case"youtube":var b;-1!=t.url.lastIndexOf("youtu.be")?(b=t.url.substr(t.url.lastIndexOf("/")+1),-1!=b.indexOf("?")&&(b=b.substr(0,b.indexOf("?")))):b=t.url.substr(t.url.lastIndexOf("=")+1),youtubeSettings={container:m,containerId:m.id,pluginMediaElement:h,pluginId:f,videoId:b,height:p,width:c},e.PluginDetector.hasPluginVersion("flash",[10,0,0])?e.YouTubeApi.createFlash(youtubeSettings):e.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var y=f+"_player";if(h.vimeoid=t.url.substr(t.url.lastIndexOf("/")+1),m.innerHTML='<iframe src="//player.vimeo.com/video/'+h.vimeoid+"?api=1&portrait=0&byline=0&title=0&player_id="+y+'" width="'+c+'" height="'+p+'" frameborder="0" class="mejs-shim" id="'+y+'" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>',"function"==typeof $f){var w=$f(m.childNodes[0]);w.addEvent("ready",function(){function t(e,t,n,i){var r={type:n,target:t};"timeupdate"==n&&(t.currentTime=r.currentTime=i.seconds,t.duration=r.duration=i.duration),t.dispatchEvent(r.type,r)}w.playVideo=function(){w.api("play")},w.stopVideo=function(){w.api("unload")},w.pauseVideo=function(){w.api("pause")},w.seekTo=function(e){w.api("seekTo",e)},w.setVolume=function(e){w.api("setVolume",e)},w.setMuted=function(e){e?(w.lastVolume=w.api("getVolume"),w.api("setVolume",0)):(w.api("setVolume",w.lastVolume),delete w.lastVolume)},w.addEvent("play",function(){t(w,h,"play"),t(w,h,"playing")}),w.addEvent("pause",function(){t(w,h,"pause")}),w.addEvent("finish",function(){t(w,h,"ended")}),w.addEvent("playProgress",function(e){t(w,h,"timeupdate",e)}),h.pluginElement=m,h.pluginApi=w,e.MediaPluginBridge.initPlugin(f)})}else console.warn("You need to include froogaloop for vimeo to work")}return d.style.display="none",d.removeAttribute("autoplay"),h},updateNative:function(t,n){var i,r=t.htmlMediaElement;for(i in e.HtmlMediaElement)r[i]=e.HtmlMediaElement[i];return n.success(r,r),r}},e.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var e=document.createElement("script");e.src="//www.youtube.com/player_api";var t=document.getElementsByTagName("script")[0];t.parentNode.insertBefore(e,t),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(e){this.isLoaded?this.createIframe(e):(this.loadIframeApi(),this.iframeQueue.push(e))},createIframe:function(t){var n=t.pluginMediaElement,i=new YT.Player(t.containerId,{height:t.height,width:t.width,videoId:t.videoId,playerVars:{controls:0},events:{onReady:function(){t.pluginMediaElement.pluginApi=i,e.MediaPluginBridge.initPlugin(t.pluginId),setInterval(function(){e.YouTubeApi.createEvent(i,n,"timeupdate")},250)},onStateChange:function(t){e.YouTubeApi.handleStateChange(t.data,i,n)}}})},createEvent:function(e,t,n){var i={type:n,target:t};if(e&&e.getDuration){t.currentTime=i.currentTime=e.getCurrentTime(),t.duration=i.duration=e.getDuration(),i.paused=t.paused,i.ended=t.ended,i.muted=e.isMuted(),i.volume=e.getVolume()/100,i.bytesTotal=e.getVideoBytesTotal(),i.bufferedBytes=e.getVideoBytesLoaded();var r=i.bufferedBytes/i.bytesTotal*i.duration;i.target.buffered=i.buffered={start:function(){return 0},end:function(){return r},length:1}}t.dispatchEvent(i.type,i)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var e=this.iframeQueue.pop();this.createIframe(e)}},flashPlayers:{},createFlash:function(t){this.flashPlayers[t.pluginId]=t;var n,i="//www.youtube.com/apiplayer?enablejsapi=1&amp;playerapiid="+t.pluginId+"&amp;version=3&amp;autoplay=0&amp;controls=0&amp;modestbranding=1&loop=0";e.MediaFeatures.isIE?(n=document.createElement("div"),t.container.appendChild(n),n.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" id="'+t.pluginId+'" width="'+t.width+'" height="'+t.height+'" class="mejs-shim"><param name="movie" value="'+i+'" /><param name="wmode" value="transparent" /><param name="allowScriptAccess" value="always" /><param name="allowFullScreen" value="true" /></object>'):t.container.innerHTML='<object type="application/x-shockwave-flash" id="'+t.pluginId+'" data="'+i+'" width="'+t.width+'" height="'+t.height+'" style="visibility: visible; " class="mejs-shim"><param name="allowScriptAccess" value="always"><param name="wmode" value="transparent"></object>'},flashReady:function(t){var n=this.flashPlayers[t],i=document.getElementById(t),r=n.pluginMediaElement;r.pluginApi=r.pluginElement=i,e.MediaPluginBridge.initPlugin(t),i.cueVideoById(n.videoId);var o=n.containerId+"_callback";window[o]=function(t){e.YouTubeApi.handleStateChange(t,i,r)},i.addEventListener("onStateChange",o),setInterval(function(){e.YouTubeApi.createEvent(i,r,"timeupdate")},250),e.YouTubeApi.createEvent(i,r,"canplay")},handleStateChange:function(t,n,i){switch(t){case-1:i.paused=!0,i.ended=!0,e.YouTubeApi.createEvent(n,i,"loadedmetadata");break;case 0:i.paused=!1,i.ended=!0,e.YouTubeApi.createEvent(n,i,"ended");break;case 1:i.paused=!1,i.ended=!1,e.YouTubeApi.createEvent(n,i,"play"),e.YouTubeApi.createEvent(n,i,"playing");break;case 2:i.paused=!0,i.ended=!1,e.YouTubeApi.createEvent(n,i,"pause");break;case 3:e.YouTubeApi.createEvent(n,i,"progress");break;case 5:}}},window.mejs=e,window.MediaElement=e.MediaElement,function(e,t){"use strict";var n={locale:{language:t.i18n&&t.i18n.locale.language||"",strings:t.i18n&&t.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};n.getLanguage=function(){var e=n.locale.language||window.navigator.userLanguage||window.navigator.language;return n.ietf_lang_regex.exec(e)?e:null},"undefined"!=typeof mejsL10n&&(n.locale.language=mejsL10n.language),n.methods.checkPlain=function(e){var t,n,i={"&":"&amp;",'"':"&quot;","<":"&lt;",">":"&gt;"};e=String(e);for(t in i)i.hasOwnProperty(t)&&(n=new RegExp(t,"g"),e=e.replace(n,i[t]));return e},n.methods.t=function(e,t){return n.locale.strings&&n.locale.strings[t.context]&&n.locale.strings[t.context][e]&&(e=n.locale.strings[t.context][e]),n.methods.checkPlain(e)},n.t=function(e,t){if("string"==typeof e&&e.length>0){var i=n.getLanguage();return t=t||{context:i},n.methods.t(e,t)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},t.i18n=n}(document,e),function(e){"use strict";"undefined"!=typeof mejsL10n&&(e[mejsL10n.language]=mejsL10n.strings)}(e.i18n.locale.strings)}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/../../bower_components/mediaelement/build/mediaelement.js","/../../bower_components/mediaelement/build")},{buffer:2,oMfpAn:5}],2:[function(e,t,n){(function(t,i,r){function r(e,t,n){if(!(this instanceof r))return new r(e,t,n);var i=typeof e;if("base64"===t&&"string"===i)for(e=B(e);e.length%4!==0;)e+="=";var o;if("number"===i)o=F(e);else if("string"===i)o=r.byteLength(e,t);else{if("object"!==i)throw new Error("First argument needs to be a number, array or string.");o=F(e.length)}var a;r._useTypedArrays?a=r._augment(new Uint8Array(o)):(a=this,a.length=o,a._isBuffer=!0);var s;if(r._useTypedArrays&&"number"==typeof e.byteLength)a._set(e);else if(N(e))for(s=0;o>s;s++)a[s]=r.isBuffer(e)?e.readUInt8(s):e[s];else if("string"===i)a.write(e,0,t);else if("number"===i&&!r._useTypedArrays&&!n)for(s=0;o>s;s++)a[s]=0;return a}function o(e,t,n,i){n=Number(n)||0;var o=e.length-n;i?(i=Number(i),i>o&&(i=o)):i=o;var a=t.length;R(a%2===0,"Invalid hex string"),i>a/2&&(i=a/2);for(var s=0;i>s;s++){var u=parseInt(t.substr(2*s,2),16);R(!isNaN(u),"Invalid hex string"),e[n+s]=u}return r._charsWritten=2*s,s}function a(e,t,n,i){var o=r._charsWritten=D($(t),e,n,i);return o}function s(e,t,n,i){var o=r._charsWritten=D(L(t),e,n,i);return o}function u(e,t,n,i){return s(e,t,n,i)}function l(e,t,n,i){var o=r._charsWritten=D(j(t),e,n,i);return o}function d(e,t,n,i){var o=r._charsWritten=D(_(t),e,n,i);return o}function c(e,t,n){return 0===t&&n===e.length?W.fromByteArray(e):W.fromByteArray(e.slice(t,n))}function p(e,t,n){var i="",r="";n=Math.min(e.length,n);for(var o=t;n>o;o++)e[o]<=127?(i+=V(r)+String.fromCharCode(e[o]),r=""):r+="%"+e[o].toString(16);return i+V(r)}function f(e,t,n){var i="";n=Math.min(e.length,n);for(var r=t;n>r;r++)i+=String.fromCharCode(e[r]);return i}function h(e,t,n){return f(e,t,n)}function m(e,t,n){var i=e.length;(!t||0>t)&&(t=0),(!n||0>n||n>i)&&(n=i);for(var r="",o=t;n>o;o++)r+=P(e[o]);return r}function g(e,t,n){for(var i=e.slice(t,n),r="",o=0;o<i.length;o+=2)r+=String.fromCharCode(i[o]+256*i[o+1]);return r}function v(e,t,n,i){i||(R("boolean"==typeof n,"missing or invalid endian"),R(void 0!==t&&null!==t,"missing offset"),R(t+1<e.length,"Trying to read beyond buffer length"));var r=e.length;if(!(t>=r)){var o;return n?(o=e[t],r>t+1&&(o|=e[t+1]<<8)):(o=e[t]<<8,r>t+1&&(o|=e[t+1])),o}}function b(e,t,n,i){i||(R("boolean"==typeof n,"missing or invalid endian"),R(void 0!==t&&null!==t,"missing offset"),R(t+3<e.length,"Trying to read beyond buffer length"));var r=e.length;if(!(t>=r)){var o;return n?(r>t+2&&(o=e[t+2]<<16),r>t+1&&(o|=e[t+1]<<8),o|=e[t],r>t+3&&(o+=e[t+3]<<24>>>0)):(r>t+1&&(o=e[t+1]<<16),r>t+2&&(o|=e[t+2]<<8),r>t+3&&(o|=e[t+3]),o+=e[t]<<24>>>0),o}}function y(e,t,n,i){i||(R("boolean"==typeof n,"missing or invalid endian"),R(void 0!==t&&null!==t,"missing offset"),R(t+1<e.length,"Trying to read beyond buffer length"));var r=e.length;if(!(t>=r)){var o=v(e,t,n,!0),a=32768&o;return a?-1*(65535-o+1):o}}function w(e,t,n,i){i||(R("boolean"==typeof n,"missing or invalid endian"),R(void 0!==t&&null!==t,"missing offset"),R(t+3<e.length,"Trying to read beyond buffer length"));var r=e.length;if(!(t>=r)){var o=b(e,t,n,!0),a=2147483648&o;return a?-1*(4294967295-o+1):o}}function T(e,t,n,i){return i||(R("boolean"==typeof n,"missing or invalid endian"),R(t+3<e.length,"Trying to read beyond buffer length")),q.read(e,t,n,23,4)}function E(e,t,n,i){return i||(R("boolean"==typeof n,"missing or invalid endian"),R(t+7<e.length,"Trying to read beyond buffer length")),q.read(e,t,n,52,8)}function A(e,t,n,i,r){r||(R(void 0!==t&&null!==t,"missing value"),R("boolean"==typeof i,"missing or invalid endian"),R(void 0!==n&&null!==n,"missing offset"),R(n+1<e.length,"trying to write beyond buffer length"),z(t,65535));var o=e.length;if(!(n>=o))for(var a=0,s=Math.min(o-n,2);s>a;a++)e[n+a]=(t&255<<8*(i?a:1-a))>>>8*(i?a:1-a)}function M(e,t,n,i,r){r||(R(void 0!==t&&null!==t,"missing value"),R("boolean"==typeof i,"missing or invalid endian"),R(void 0!==n&&null!==n,"missing offset"),R(n+3<e.length,"trying to write beyond buffer length"),z(t,4294967295));var o=e.length;if(!(n>=o))for(var a=0,s=Math.min(o-n,4);s>a;a++)e[n+a]=t>>>8*(i?a:3-a)&255}function C(e,t,n,i,r){r||(R(void 0!==t&&null!==t,"missing value"),R("boolean"==typeof i,"missing or invalid endian"),R(void 0!==n&&null!==n,"missing offset"),R(n+1<e.length,"Trying to write beyond buffer length"),H(t,32767,-32768));var o=e.length;n>=o||(t>=0?A(e,t,n,i,r):A(e,65535+t+1,n,i,r))}function S(e,t,n,i,r){r||(R(void 0!==t&&null!==t,"missing value"),R("boolean"==typeof i,"missing or invalid endian"),R(void 0!==n&&null!==n,"missing offset"),R(n+3<e.length,"Trying to write beyond buffer length"),H(t,2147483647,-2147483648));var o=e.length;n>=o||(t>=0?M(e,t,n,i,r):M(e,4294967295+t+1,n,i,r))}function k(e,t,n,i,r){r||(R(void 0!==t&&null!==t,"missing value"),R("boolean"==typeof i,"missing or invalid endian"),R(void 0!==n&&null!==n,"missing offset"),R(n+3<e.length,"Trying to write beyond buffer length"),O(t,3.4028234663852886e38,-3.4028234663852886e38));var o=e.length;
n>=o||q.write(e,t,n,i,23,4)}function I(e,t,n,i,r){r||(R(void 0!==t&&null!==t,"missing value"),R("boolean"==typeof i,"missing or invalid endian"),R(void 0!==n&&null!==n,"missing offset"),R(n+7<e.length,"Trying to write beyond buffer length"),O(t,1.7976931348623157e308,-1.7976931348623157e308));var o=e.length;n>=o||q.write(e,t,n,i,52,8)}function B(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function x(e,t,n){return"number"!=typeof e?n:(e=~~e,e>=t?t:e>=0?e:(e+=t,e>=0?e:0))}function F(e){return e=~~Math.ceil(+e),0>e?0:e}function U(e){return(Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)})(e)}function N(e){return U(e)||r.isBuffer(e)||e&&"object"==typeof e&&"number"==typeof e.length}function P(e){return 16>e?"0"+e.toString(16):e.toString(16)}function $(e){for(var t=[],n=0;n<e.length;n++){var i=e.charCodeAt(n);if(127>=i)t.push(e.charCodeAt(n));else{var r=n;i>=55296&&57343>=i&&n++;for(var o=encodeURIComponent(e.slice(r,n+1)).substr(1).split("%"),a=0;a<o.length;a++)t.push(parseInt(o[a],16))}}return t}function L(e){for(var t=[],n=0;n<e.length;n++)t.push(255&e.charCodeAt(n));return t}function _(e){for(var t,n,i,r=[],o=0;o<e.length;o++)t=e.charCodeAt(o),n=t>>8,i=t%256,r.push(i),r.push(n);return r}function j(e){return W.toByteArray(e)}function D(e,t,n,i){for(var r=0;i>r&&!(r+n>=t.length||r>=e.length);r++)t[r+n]=e[r];return r}function V(e){try{return decodeURIComponent(e)}catch(t){return String.fromCharCode(65533)}}function z(e,t){R("number"==typeof e,"cannot write a non-number as a number"),R(e>=0,"specified a negative value for writing an unsigned value"),R(t>=e,"value is larger than maximum value for type"),R(Math.floor(e)===e,"value has a fractional component")}function H(e,t,n){R("number"==typeof e,"cannot write a non-number as a number"),R(t>=e,"value larger than maximum allowed value"),R(e>=n,"value smaller than minimum allowed value"),R(Math.floor(e)===e,"value has a fractional component")}function O(e,t,n){R("number"==typeof e,"cannot write a non-number as a number"),R(t>=e,"value larger than maximum allowed value"),R(e>=n,"value smaller than minimum allowed value")}function R(e,t){if(!e)throw new Error(t||"Failed assertion")}var W=e("base64-js"),q=e("ieee754");n.Buffer=r,n.SlowBuffer=r,n.INSPECT_MAX_BYTES=50,r.poolSize=8192,r._useTypedArrays=function(){try{var e=new ArrayBuffer(0),t=new Uint8Array(e);return t.foo=function(){return 42},42===t.foo()&&"function"==typeof t.subarray}catch(n){return!1}}(),r.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},r.isBuffer=function(e){return!(null===e||void 0===e||!e._isBuffer)},r.byteLength=function(e,t){var n;switch(e+="",t||"utf8"){case"hex":n=e.length/2;break;case"utf8":case"utf-8":n=$(e).length;break;case"ascii":case"binary":case"raw":n=e.length;break;case"base64":n=j(e).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":n=2*e.length;break;default:throw new Error("Unknown encoding")}return n},r.concat=function(e,t){if(R(U(e),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===e.length)return new r(0);if(1===e.length)return e[0];var n;if("number"!=typeof t)for(t=0,n=0;n<e.length;n++)t+=e[n].length;var i=new r(t),o=0;for(n=0;n<e.length;n++){var a=e[n];a.copy(i,o),o+=a.length}return i},r.prototype.write=function(e,t,n,i){if(isFinite(t))isFinite(n)||(i=n,n=void 0);else{var r=i;i=t,t=n,n=r}t=Number(t)||0;var c=this.length-t;n?(n=Number(n),n>c&&(n=c)):n=c,i=String(i||"utf8").toLowerCase();var p;switch(i){case"hex":p=o(this,e,t,n);break;case"utf8":case"utf-8":p=a(this,e,t,n);break;case"ascii":p=s(this,e,t,n);break;case"binary":p=u(this,e,t,n);break;case"base64":p=l(this,e,t,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":p=d(this,e,t,n);break;default:throw new Error("Unknown encoding")}return p},r.prototype.toString=function(e,t,n){var i=this;if(e=String(e||"utf8").toLowerCase(),t=Number(t)||0,n=void 0!==n?Number(n):n=i.length,n===t)return"";var r;switch(e){case"hex":r=m(i,t,n);break;case"utf8":case"utf-8":r=p(i,t,n);break;case"ascii":r=f(i,t,n);break;case"binary":r=h(i,t,n);break;case"base64":r=c(i,t,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":r=g(i,t,n);break;default:throw new Error("Unknown encoding")}return r},r.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},r.prototype.copy=function(e,t,n,i){var o=this;if(n||(n=0),i||0===i||(i=this.length),t||(t=0),i!==n&&0!==e.length&&0!==o.length){R(i>=n,"sourceEnd < sourceStart"),R(t>=0&&t<e.length,"targetStart out of bounds"),R(n>=0&&n<o.length,"sourceStart out of bounds"),R(i>=0&&i<=o.length,"sourceEnd out of bounds"),i>this.length&&(i=this.length),e.length-t<i-n&&(i=e.length-t+n);var a=i-n;if(100>a||!r._useTypedArrays)for(var s=0;a>s;s++)e[s+t]=this[s+n];else e._set(this.subarray(n,n+a),t)}},r.prototype.slice=function(e,t){var n=this.length;if(e=x(e,n,0),t=x(t,n,n),r._useTypedArrays)return r._augment(this.subarray(e,t));for(var i=t-e,o=new r(i,void 0,!0),a=0;i>a;a++)o[a]=this[a+e];return o},r.prototype.get=function(e){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(e)},r.prototype.set=function(e,t){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(e,t)},r.prototype.readUInt8=function(e,t){return t||(R(void 0!==e&&null!==e,"missing offset"),R(e<this.length,"Trying to read beyond buffer length")),e>=this.length?void 0:this[e]},r.prototype.readUInt16LE=function(e,t){return v(this,e,!0,t)},r.prototype.readUInt16BE=function(e,t){return v(this,e,!1,t)},r.prototype.readUInt32LE=function(e,t){return b(this,e,!0,t)},r.prototype.readUInt32BE=function(e,t){return b(this,e,!1,t)},r.prototype.readInt8=function(e,t){if(t||(R(void 0!==e&&null!==e,"missing offset"),R(e<this.length,"Trying to read beyond buffer length")),!(e>=this.length)){var n=128&this[e];return n?-1*(255-this[e]+1):this[e]}},r.prototype.readInt16LE=function(e,t){return y(this,e,!0,t)},r.prototype.readInt16BE=function(e,t){return y(this,e,!1,t)},r.prototype.readInt32LE=function(e,t){return w(this,e,!0,t)},r.prototype.readInt32BE=function(e,t){return w(this,e,!1,t)},r.prototype.readFloatLE=function(e,t){return T(this,e,!0,t)},r.prototype.readFloatBE=function(e,t){return T(this,e,!1,t)},r.prototype.readDoubleLE=function(e,t){return E(this,e,!0,t)},r.prototype.readDoubleBE=function(e,t){return E(this,e,!1,t)},r.prototype.writeUInt8=function(e,t,n){n||(R(void 0!==e&&null!==e,"missing value"),R(void 0!==t&&null!==t,"missing offset"),R(t<this.length,"trying to write beyond buffer length"),z(e,255)),t>=this.length||(this[t]=e)},r.prototype.writeUInt16LE=function(e,t,n){A(this,e,t,!0,n)},r.prototype.writeUInt16BE=function(e,t,n){A(this,e,t,!1,n)},r.prototype.writeUInt32LE=function(e,t,n){M(this,e,t,!0,n)},r.prototype.writeUInt32BE=function(e,t,n){M(this,e,t,!1,n)},r.prototype.writeInt8=function(e,t,n){n||(R(void 0!==e&&null!==e,"missing value"),R(void 0!==t&&null!==t,"missing offset"),R(t<this.length,"Trying to write beyond buffer length"),H(e,127,-128)),t>=this.length||(e>=0?this.writeUInt8(e,t,n):this.writeUInt8(255+e+1,t,n))},r.prototype.writeInt16LE=function(e,t,n){C(this,e,t,!0,n)},r.prototype.writeInt16BE=function(e,t,n){C(this,e,t,!1,n)},r.prototype.writeInt32LE=function(e,t,n){S(this,e,t,!0,n)},r.prototype.writeInt32BE=function(e,t,n){S(this,e,t,!1,n)},r.prototype.writeFloatLE=function(e,t,n){k(this,e,t,!0,n)},r.prototype.writeFloatBE=function(e,t,n){k(this,e,t,!1,n)},r.prototype.writeDoubleLE=function(e,t,n){I(this,e,t,!0,n)},r.prototype.writeDoubleBE=function(e,t,n){I(this,e,t,!1,n)},r.prototype.fill=function(e,t,n){if(e||(e=0),t||(t=0),n||(n=this.length),"string"==typeof e&&(e=e.charCodeAt(0)),R("number"==typeof e&&!isNaN(e),"value is not a number"),R(n>=t,"end < start"),n!==t&&0!==this.length){R(t>=0&&t<this.length,"start out of bounds"),R(n>=0&&n<=this.length,"end out of bounds");for(var i=t;n>i;i++)this[i]=e}},r.prototype.inspect=function(){for(var e=[],t=this.length,i=0;t>i;i++)if(e[i]=P(this[i]),i===n.INSPECT_MAX_BYTES){e[i+1]="...";break}return"<Buffer "+e.join(" ")+">"},r.prototype.toArrayBuffer=function(){if("undefined"!=typeof Uint8Array){if(r._useTypedArrays)return new r(this).buffer;for(var e=new Uint8Array(this.length),t=0,n=e.length;n>t;t+=1)e[t]=this[t];return e.buffer}throw new Error("Buffer.toArrayBuffer not supported in this browser")};var Y=r.prototype;r._augment=function(e){return e._isBuffer=!0,e._get=e.get,e._set=e.set,e.get=Y.get,e.set=Y.set,e.write=Y.write,e.toString=Y.toString,e.toLocaleString=Y.toString,e.toJSON=Y.toJSON,e.copy=Y.copy,e.slice=Y.slice,e.readUInt8=Y.readUInt8,e.readUInt16LE=Y.readUInt16LE,e.readUInt16BE=Y.readUInt16BE,e.readUInt32LE=Y.readUInt32LE,e.readUInt32BE=Y.readUInt32BE,e.readInt8=Y.readInt8,e.readInt16LE=Y.readInt16LE,e.readInt16BE=Y.readInt16BE,e.readInt32LE=Y.readInt32LE,e.readInt32BE=Y.readInt32BE,e.readFloatLE=Y.readFloatLE,e.readFloatBE=Y.readFloatBE,e.readDoubleLE=Y.readDoubleLE,e.readDoubleBE=Y.readDoubleBE,e.writeUInt8=Y.writeUInt8,e.writeUInt16LE=Y.writeUInt16LE,e.writeUInt16BE=Y.writeUInt16BE,e.writeUInt32LE=Y.writeUInt32LE,e.writeUInt32BE=Y.writeUInt32BE,e.writeInt8=Y.writeInt8,e.writeInt16LE=Y.writeInt16LE,e.writeInt16BE=Y.writeInt16BE,e.writeInt32LE=Y.writeInt32LE,e.writeInt32BE=Y.writeInt32BE,e.writeFloatLE=Y.writeFloatLE,e.writeFloatBE=Y.writeFloatBE,e.writeDoubleLE=Y.writeDoubleLE,e.writeDoubleBE=Y.writeDoubleBE,e.fill=Y.fill,e.inspect=Y.inspect,e.toArrayBuffer=Y.toArrayBuffer,e}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/buffer/index.js","/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/buffer")},{"base64-js":3,buffer:2,ieee754:4,oMfpAn:5}],3:[function(e,t,n){(function(){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(t){"use strict";function n(e){var t=e.charCodeAt(0);return t===a||t===c?62:t===s||t===p?63:u>t?-1:u+10>t?t-u+26+26:d+26>t?t-d:l+26>t?t-l+26:void 0}function i(e){function t(e){l[c++]=e}var i,r,a,s,u,l;if(e.length%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var d=e.length;u="="===e.charAt(d-2)?2:"="===e.charAt(d-1)?1:0,l=new o(3*e.length/4-u),a=u>0?e.length-4:e.length;var c=0;for(i=0,r=0;a>i;i+=4,r+=3)s=n(e.charAt(i))<<18|n(e.charAt(i+1))<<12|n(e.charAt(i+2))<<6|n(e.charAt(i+3)),t((16711680&s)>>16),t((65280&s)>>8),t(255&s);return 2===u?(s=n(e.charAt(i))<<2|n(e.charAt(i+1))>>4,t(255&s)):1===u&&(s=n(e.charAt(i))<<10|n(e.charAt(i+1))<<4|n(e.charAt(i+2))>>2,t(s>>8&255),t(255&s)),l}function r(t){function n(t){return e.charAt(t)}function i(e){return n(e>>18&63)+n(e>>12&63)+n(e>>6&63)+n(63&e)}var r,o,a,s=t.length%3,u="";for(r=0,a=t.length-s;a>r;r+=3)o=(t[r]<<16)+(t[r+1]<<8)+t[r+2],u+=i(o);switch(s){case 1:o=t[t.length-1],u+=n(o>>2),u+=n(o<<4&63),u+="==";break;case 2:o=(t[t.length-2]<<8)+t[t.length-1],u+=n(o>>10),u+=n(o>>4&63),u+=n(o<<2&63),u+="="}return u}var o="undefined"!=typeof Uint8Array?Uint8Array:Array,a="+".charCodeAt(0),s="/".charCodeAt(0),u="0".charCodeAt(0),l="a".charCodeAt(0),d="A".charCodeAt(0),c="-".charCodeAt(0),p="_".charCodeAt(0);t.toByteArray=i,t.fromByteArray=r}("undefined"==typeof n?this.base64js={}:n)}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/buffer/node_modules/base64-js/lib/b64.js","/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/buffer/node_modules/base64-js/lib")},{buffer:2,oMfpAn:5}],4:[function(e,t,n){(function(){n.read=function(e,t,n,i,r){var o,a,s=8*r-i-1,u=(1<<s)-1,l=u>>1,d=-7,c=n?r-1:0,p=n?-1:1,f=e[t+c];for(c+=p,o=f&(1<<-d)-1,f>>=-d,d+=s;d>0;o=256*o+e[t+c],c+=p,d-=8);for(a=o&(1<<-d)-1,o>>=-d,d+=i;d>0;a=256*a+e[t+c],c+=p,d-=8);if(0===o)o=1-l;else{if(o===u)return a?0/0:1/0*(f?-1:1);a+=Math.pow(2,i),o-=l}return(f?-1:1)*a*Math.pow(2,o-i)},n.write=function(e,t,n,i,r,o){var a,s,u,l=8*o-r-1,d=(1<<l)-1,c=d>>1,p=23===r?Math.pow(2,-24)-Math.pow(2,-77):0,f=i?0:o-1,h=i?1:-1,m=0>t||0===t&&0>1/t?1:0;for(t=Math.abs(t),isNaN(t)||1/0===t?(s=isNaN(t)?1:0,a=d):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),t+=a+c>=1?p/u:p*Math.pow(2,1-c),t*u>=2&&(a++,u/=2),a+c>=d?(s=0,a=d):a+c>=1?(s=(t*u-1)*Math.pow(2,r),a+=c):(s=t*Math.pow(2,c-1)*Math.pow(2,r),a=0));r>=8;e[n+f]=255&s,f+=h,s/=256,r-=8);for(a=a<<r|s,l+=r;l>0;e[n+f]=255&a,f+=h,a/=256,l-=8);e[n+f-h]|=128*m}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/buffer/node_modules/ieee754/index.js","/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/buffer/node_modules/ieee754")},{buffer:2,oMfpAn:5}],5:[function(e,t){(function(e){function n(){}var e=t.exports={};e.nextTick=function(){var e="undefined"!=typeof window&&window.setImmediate,t="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(e)return function(e){return window.setImmediate(e)};if(t){var n=[];return window.addEventListener("message",function(e){var t=e.source;if((t===window||null===t)&&"process-tick"===e.data&&(e.stopPropagation(),n.length>0)){var i=n.shift();i()}},!0),function(e){n.push(e),window.postMessage("process-tick","*")}}return function(e){setTimeout(e,0)}}(),e.title="browser",e.browser=!0,e.env={},e.argv=[],e.on=n,e.addListener=n,e.once=n,e.off=n,e.removeListener=n,e.removeAllListeners=n,e.emit=n,e.binding=function(){throw new Error("process.binding is not supported")},e.cwd=function(){return"/"},e.chdir=function(){throw new Error("process.chdir is not supported")}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/process/browser.js","/../../node_modules/gulp-browserify/node_modules/browserify/node_modules/process")},{buffer:2,oMfpAn:5}],6:[function(e,t){(function(){"use strict";function n(){return $('<ul class="timecontrolbar"></ul>')}function i(){return $('<div class="controlbar bar"></div>')}function r(e){return"number"==typeof e.currentTime&&e.currentTime>0}function o(e){return function(t){console.debug("Controls","controlbutton clicked",t),t.preventDefault(),console.debug("Controls","player started?",r(this.player)),r(this.player)||this.player.play();var n=e.bind(this);n()}}function a(e){this.player=e.player,this.timeline=e,this.box=i(),this.timeControlElement=n(),this.box.append(this.timeControlElement)}var s=e("./modules/chapter");a.prototype.createTimeControls=function(e){var t=e instanceof s;t||console.info("Controls","createTimeControls","no chapterTab found"),t&&this.createButton("pwp-controls-previous-chapter","Zurück zum vorigen Kapitel",function(){var t=e.getActiveChapter();return this.timeline.getTime()>t.start+10?(console.debug("Controls","Zurück zum Kapitelanfang",e.currentChapter,"from",this.timeline.getTime()),e.playCurrentChapter()):(console.debug("Controls","Zurück zum vorigen Kapitel",e.currentChapter),e.previous())}),this.createButton("pwp-controls-back-30","30 Sekunden zurück",function(){console.debug("Controls","rewind before",this.timeline.getTime()),this.timeline.setTime(this.timeline.getTime()-30),console.debug("Controls","rewind after",this.timeline.getTime())}),this.createButton("pwp-controls-forward-30","30 Sekunden vor",function(){console.debug("Controls","ffwd before",this.timeline.getTime()),this.timeline.setTime(this.timeline.getTime()+30),console.debug("Controls","ffwd after",this.timeline.getTime())}),t&&this.createButton("pwp-controls-next-chapter","Zum nächsten Kapitel springen",function(){console.debug("Controls","next Chapter before",this.timeline.getTime()),e.next(),console.debug("Controls","next Chapter after",this.timeline.getTime())})},a.prototype.createButton=function(e,t,n){var i=$('<li><a href="#" class="button button-control" title="'+t+'"><i class="icon '+e+'"></i></a></li>');this.timeControlElement.append(i);var r=o(n);i.on("click",r.bind(this))},t.exports=a}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/controls.js","/")},{"./modules/chapter":9,buffer:2,oMfpAn:5}],7:[function(e,t){(function(){"use strict";function e(e){console.debug("postToOpener",e),window.parent.postMessage(e,"*")}function n(e){var t=e.originalEvent;"pause"===t.data.action&&s.forEach(function(e){e.pause()})}function i(e){function t(t){var n=t.originalEvent;n.data.playerOptions&&e(n.data.playerOptions)}$(window).on("message",t)}function r(){var t=a.height();u!==t&&e({action:"resize",arg:t}),u=t,requestAnimationFrame(r,document.body)}function o(e,t){s=t,a=e(document.body),e(window).on("message",n),r()}var a,s=[],u=0;t.exports={postToOpener:e,waitForMetadata:i,init:o}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/embed.js","/")},{buffer:2,oMfpAn:5}],8:[function(e){(function(){"use strict";function t(e,t){return e?(t&&(e='<a href="'+t+'" target="_blank" title="Link zur Show">'+e+"</a>"),'<h3 class="showtitle">'+e+"</h3>"):""}function n(e,t){var n='<h1 class="episodetitle">',i="</h1>";return void 0!==e&&void 0!==t&&(e='<a href="'+t+'" target="_blank" title="Link zur Episode">'+e+"</a>"),n+e+i}function i(e){return e?'<h2 class="subtitle">'+e+"</h2>":""}function r(e){return"<header>"+t(e.show.title,e.show.url)+n(e.title,e.permalink)+i(e.subtitle)+"</header>"}function o(){return $('<a class="play" title="Abspielen" href="javascript:;"></a>')}function a(e){return e?'<div class="coverart"><img class="coverimg" src="'+e+'" data-img="'+e+'" alt="Poster Image"></div>':""}function s(){var e=["hidden","mozHidden","msHidden","webkitHidden"];for(var t in e)if(e[t]in document)return!!document[e[t]];return!1}function u(e,t,n){var i,r=new p,o=e.hasChapters,a=new w(e),s=a.box;o&&(i=new b(e,n),e.addModule(i)),a.createTimeControls(i);var u=new y(e,n);e.addModule(u);var l=new E(e);e.addModule(l);var d=new g(n),c=new v(n),f=new m(n);o&&r.add(i.tab),r.add(d.tab),r.add(c.tab),r.add(f.tab),r.openInitial(n.activeTab);var h=$('<div class="controlbar-wrapper"></div>');h.append(r.togglebar),h.append(s),t.append(l.render()).append(h).append(r.container),l.addEvents()}function l(t,n,i){var l,d=$(t),p=new h(t,n),m=$('<div class="titlebar"></div>'),g=n.type,v=o(),b=n.poster||d.attr("poster");if(console.debug("webplayer","metadata",p.getData()),d.prop({controls:null,preload:"metadata"}),i.addClass("podlovewebplayer_"+g).data("podlovewebplayer",{player:d}),"audio"===g&&(m.prepend(v),m.append(a(b)),i.prepend(m)),"video"===g){var y=$('<div class="video-pane"></div>'),w=$('<div class="video-overlay"></div>');w.append(v),w.on("click",function(){return t.paused?(v.addClass("playing"),t.play(),void 0):(v.removeClass("playing"),t.pause(),void 0)}),y.append(w).append(d),i.append(m).append(y),d.prop({poster:b})}if(m.append(r(n)),l=e("./url").checkCurrent(),l[0]&&1===c.players.length){var T={preload:"auto"};s()||(T.autoplay="autoplay"),d.attr(T),p.playRange(l),$("html, body").delay(150).animate({scrollTop:$(".container:first").offset().top-25})}v.on("click",function(e){return e.preventDefault(),e.stopPropagation(),t.currentTime&&t.currentTime>0&&!t.paused?(v.removeClass("playing"),t.pause(),"flash"===t.pluginType&&t.pause(),void 0):(v.hasClass("playing")||v.addClass("playing"),t.play(),void 0)}),$(document).on("keydown",function(e){console.log("progress","keydown",e);var t=e.which,n=p.player.duration,i=p.player.currentTime;switch(t){case 37:i-=1;break;case 39:i+=1;break;case 38:if(p.hasChapters)return p.modules[0].next(),!1;i+=Math.floor(.1*n);break;case 40:if(p.hasChapters)return p.modules[0].previous(),!1;i-=Math.floor(.1*n);break;case 36:i=0;break;case 35:i=n;break;case 10:case 32:return p.player.paused?(p.player.play(),!1):(p.player.pause(),!1);default:return!0}return p.setTime(i),!1}),d.on("timelineElement",function(e){console.log(e.currentTarget.id,e)}).on("timeupdate progress",function(e){p.update(e)}).on("play",function(){}).on("playing",function(){v.addClass("playing"),f.postToOpener({action:"play",arg:t.currentTime})}).on("pause",function(){v.removeClass("playing"),f.postToOpener({action:"pause",arg:t.currentTime})}).on("ended",function(){f.postToOpener({action:"stop",arg:t.currentTime}),p.rewind()});var E=!p.duration||isNaN(p.duration)||p.duration<=0;E||u(p,i,n),d.one("canplay",function(){p.duration=t.duration,E&&u(p,i,n)})}function d(e){return function(t){var n=$.extend({},T.defaults,t);t.sources.forEach(function(t){$("<source>",t).appendTo(e)}),T.create(e,n,l)}}var c,p=e("./tabregistry"),f=e("./embed"),h=e("./timeline"),m=e("./modules/info"),g=e("./modules/share"),v=e("./modules/downloads"),b=e("./modules/chapter"),y=e("./modules/savetime"),w=e("./controls"),T=e("./player"),E=e("./modules/progressbar");e("../../bower_components/mediaelement/build/mediaelement.js"),$.fn.podlovewebplayer=function(e){if(e.deferred){var t=this[0],n=d(t);return f.waitForMetadata(n),f.postToOpener({action:"waiting"}),this}var i=$.extend({},T.defaults,e);return this.each(function(e,t){T.create(t,i,l)})},c={players:T.players},f.init($,T.players),window.pwp=c}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_87eefe3.js","/")},{"../../bower_components/mediaelement/build/mediaelement.js":1,"./controls":6,"./embed":7,"./modules/chapter":9,"./modules/downloads":10,"./modules/info":11,"./modules/progressbar":12,"./modules/savetime":13,"./modules/share":14,"./player":15,"./tabregistry":20,"./timeline":22,"./url":23,buffer:2,oMfpAn:5}],9:[function(e,t){(function(){"use strict";function n(e){e.preventDefault();var t=e.data.module;return console.log("Chapter","clickHandler","setCurrentChapter to",e.data.index),t.setCurrentChapter(e.data.index),t.playCurrentChapter(),t.timeline.player.play(),!1}function i(e){return e.code=e.title,"string"==typeof e.start&&(e.start=p.getStartTimeCode(e.start)),e}function r(e){return function(t,n,i){var r=i[n+1];return t.end=r?r.start:e,t}}function o(e){return $(e)}function a(){return o('<table class="podlovewebplayer_chapters"><caption>Kapitel</caption><thead><tr><th scope="col">Kapitelnummer</th><th scope="col">Startzeit</th><th scope="col">Titel</th><th scope="col">Dauer</th></tr></thead><tbody></tbody></table>')}function s(e,t){return o('<tr class="chapter"><td class="chapter-number"><span class="badge">'+(t+1)+'</span></td><td class="chapter-name"><span>'+e.code+'</span></td><td class="chapter-duration"><span>'+e.duration+"</span></td></tr>")}function u(e){function t(e){return e.start}return Math.max.apply(Math,$.map(e,t))}function l(e,t){return e?t>e.start-h&&t<=e.end:!1}function d(e){function t(e,t){var n=l(e,i);n&&this.setCurrentChapter(t)}var n=this.getActiveChapter(),i=e.getTime();return console.debug("Chapters","update",this,n,i),l(n,i)?(console.log("Chapters","update","already set",this.currentChapter),void 0):(this.chapters.forEach(t,this),void 0)}function c(e,t){return e&&e.hasChapters?(0===e.duration&&console.warn("Chapters","constructor","Zero length media?",e),this.timeline=e,this.duration=e.duration,this.chapterlinks=!!e.chapterlinks,this.currentChapter=0,this.chapters=this.parseSimpleChapter(t),this.data=this.chapters,this.tab=new f({icon:"pwp-chapters",title:"Kapitel anzeigen / verbergen",headline:"Kapitel",name:"chapters"}),this.tab.createMainContent("").append(this.generateTable()),this.update=d.bind(this),void 0):null}var p=e("../timecode"),f=e("../tab"),h=.1;c.prototype.generateTable=function(){function e(e,t){var r=Math.round(e.end-e.start);e.duration=p.generate([r],!1),e.startTime=p.generate([Math.round(e.start)],!0,o);var a=s(e,t);a.on("click",{module:this,index:t},n),a.appendTo(i),e.element=a}var t,i,r,o;return t=a(),i=t.children("tbody"),r=u(this.chapters),o=r>=3600,this.chapters.forEach(e,this),t},c.prototype.getActiveChapter=function(){var e=this.chapters[this.currentChapter];return console.log("Chapters","getActiveChapter",e),e},c.prototype.setCurrentChapter=function(e){e<this.chapters.length&&e>=0&&(this.currentChapter=e),this.markActiveChapter(),console.log("Chapters","setCurrentChapter","to",this.currentChapter)},c.prototype.markActiveChapter=function(){var e=this.getActiveChapter();$.each(this.chapters,function(){this.element.removeClass("active")}),e.element.addClass("active")},c.prototype.next=function(){var e=this.currentChapter,t=this.setCurrentChapter(e+1);return e===t?(console.log("Chapters","next","already in last chapter"),e):(console.log("Chapters","next","chapter",this.currentChapter),this.playCurrentChapter(),t)},c.prototype.previous=function(){var e=this.currentChapter,t=this.setCurrentChapter(e-1);return e===t?(console.debug("Chapters","previous","already in first chapter"),this.playCurrentChapter(),e):(console.debug("Chapters","previous","chapter",this.currentChapter),this.playCurrentChapter(),t)},c.prototype.playCurrentChapter=function(){var e=this.getActiveChapter().start;console.log("Chapters","#playCurrentChapter","start",e);var t=this.timeline.setTime(e);console.log("Chapters","#playCurrentChapter","currentTime",t)},c.prototype.parseSimpleChapter=function(e){var t=e.chapters;return t?t.map(i).map(r(this.duration)).sort(function(e,t){return e.start-t.start}):[]},t.exports=c}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/modules/chapter.js","/modules")},{"../tab":19,"../timecode":21,buffer:2,oMfpAn:5}],10:[function(e,t){(function(){"use strict";function n(e){var t=1048576,n=parseInt(e,10),i=Math.round(n/1024),r=Math.round(n/1024/1024);return e?t>n?i+" KB":r+" MB":" -- "}function i(e){return console.log(e),'<option value="'+e.downloadUrl+'">'+e.assetTitle+" &#8226; "+n(e.size)+"</option>"}function r(e){return{assetTitle:e.name,downloadUrl:e.dlurl,url:e.url,size:e.size}}function o(e){var t="string"==typeof e?e:e.src,n=t.split(".");return{assetTitle:n[n.length-1],downloadUrl:t,url:t,size:-1}}function a(e){return e.downloads&&e.downloads[0].assetTitle?e.downloads:e.downloads?e.downloads.map(r):e.sources.map(o)}function s(e){this.list=a(e),this.tab=this.createDownloadTab(e)}var u=e("../tab");s.prototype.createDownloadTab=function(e){function t(){s.val(a.val())}if(!e.downloads&&!e.sources||e.hidedownloadbutton===!0)return null;var n=new u({icon:"pwp-download",title:"Downloads anzeigen / verbergen",name:"downloads",headline:"Download"}),r=n.createMainContent('<div class="download"><form action="#"><select class="select" name="select-file">'+this.list.map(i)+'</select><button class="download button-submit icon pwp-download" name="download-file"><span class="download label">Download</span></button></form></div>');n.box.append(r);var o=r.find("button.pwp-download"),a=r.find("select.select");o.on("click",function(e){e.preventDefault(),window.open(a.val(),"_self")});var s=$('<input name="download-link-url" type="url" readonly>');return t(),a.on("change",t),n.createFooter("<h3>Direkter Link</h3>").append(s),n},t.exports=s}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/modules/downloads.js","/modules")},{"../tab":19,buffer:2,oMfpAn:5}],11:[function(e,t){(function(){"use strict";function n(e){if(!e)return"";var t=new Date(e);return"<p>Veröffentlicht am: "+t.getDate()+"."+(t.getMonth()+1)+"."+t.getFullYear()+"</p>"}function i(e){return e&&e.length>0?"<p>"+e+"</p>":""}function r(e,t){e.createMainContent("<h2>"+t.title+"</h2><h3>"+t.subtitle+"</h3>"+i(t.summary)+"<p>Dauer: "+h.fromTimeStamp(t.duration)+"</p>"+n(t.publicationDate)+'<p>Permalink:<br><a href="'+t.permalink+'" target="_blank" title="Permalink für die Episode">'+t.permalink+"</a></p>")}function o(e){return e?'<div class="poster-image"><img src="'+e+'" data-img="'+e+'" alt="Poster Image"></div>':""}function a(e){return e.subscribeButton?'<button class="button-submit"><span class="showtitle-label">'+e.show.title+'</span><span class="submit-label">'+e.subscribeButton+"</span></button>":""}function s(e,t){e.createAside("<h2>"+t.show.title+"</h2><h3>"+t.show.subtitle+"</h3>"+o(t.show.poster)+a(t)+'<p>Link zur Show:<br><a href="'+t.show.url+'" target="_blank" title="Link zur Show">'+t.show.url+"</a></p>")}function u(e){var t=m.get(e.serviceName),n=$("<li></li>"),i=t.getButton(e);n.append(i.element),this.append(n)}function l(e){if(!e)return null;var t=$("<ul></ul>");e.forEach(u,t);var n=$('<div class="social-links"><h3>Bleib in Verbindung</h3></div>');return n.append(t),n}function d(e,t){if(t.license&&t.show){var n=e.createFooter('<p>Die Show "'+t.show.title+'" ist lizensiert unter<br><a href="'+t.license.url+'" target="_blank" title="Lizenz ansehen">'+t.license.name+"</a></p>");n.prepend(l(t.profiles))}}function c(e){var t=new f({icon:"pwp-info",title:"Infos anzeigen / verbergen",headline:"Info",name:"info"});return r(t,e),s(t,e),d(t,e),t}function p(e){this.tab=c(e)}var f=e("../tab"),h=e("../timecode"),m=e("../social-networks");t.exports=p}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/modules/info.js","/modules")},{"../social-networks":18,"../tab":19,"../timecode":21,buffer:2,oMfpAn:5}],12:[function(e,t){(function(){"use strict";function n(e,t){return $('<div class="time time-'+e+'">'+t+"</div>")}function i(){var e=$('<div class="chapter"></div>');if(!this.chapterModule)return e;var t=this.chapterModule.currentChapter,n=this.chapterModule.chapters[t];return console.debug("Progressbar","renderCurrentChapterElement",t,n),this.chapterBadge=$('<span class="badge">'+(t+1)+"</span>"),this.chapterTitle=$('<span class="chapter-title">'+n.title+"</span>"),e.append(this.chapterBadge).append(this.chapterTitle),e}function r(e){var t=$('<div class="progress-info"></div>');return t.append(e.currentTime).append(i.call(e)).append(e.durationTimeElement)}function o(e){var t=e.timeline.getTime();if(e.currentTime.html(c.fromTimeStamp(t)),!e.showDuration){var n=Math.abs(t-e.duration);e.durationTimeElement.text("-"+c.fromTimeStamp(n))}}function a(e){var t=c.fromTimeStamp(e.duration),i=n("duration",0);return i.on("click",function(){return e.showDuration=!e.showDuration,e.showDuration?(i.text(t),void 0):(o(e),void 0)}),i}function s(e){var t=100*e/this.duration;return $('<div class="marker" style="left:'+t+'%;"></div>')}function u(e){return s.call(this,e.start)}function l(e){this.setProgress(e.getTime()),this.buffer.val(e.getBuffered()),this.setChapter()}function d(e){return e?(this.timeline=e,this.duration=e.duration,this.bar=null,this.currentTime=null,e.hasChapters&&(this.chapterModule=this.timeline.modules[0],this.chapterBadge=null,this.chapterTitle=null),this.showDuration=!1,this.progress=null,this.buffer=null,this.update=l.bind(this),void 0):(console.error("Timeline missing",arguments),void 0)}var c=e("../timecode"),p=e("../util").cap;d.prototype.setHandlePosition=function(e){var t=e/this.duration*100,n=t+"%";console.debug("ProgressBar","setHandlePosition","time",e,"newLeftOffset",n),this.handle.css("left",n)},d.prototype.setProgress=function(e){this.progress.val(e),this.setHandlePosition(e),o(this)
},d.prototype.setChapter=function(){if(this.chapterModule){var e=this.chapterModule.currentChapter,t=this.chapterModule.chapters[e];this.chapterBadge.text(e+1),this.chapterTitle.text(t.title)}},d.prototype.render=function(){var e=c.fromTimeStamp(this.timeline.getTime());this.currentTime=n("current",e),this.durationTimeElement=a(this);var t=r(this);o(this);var i=$('<div class="progress"></div>'),s=$('<progress class="current"></progress>').attr({min:0,max:this.duration}),l=$('<progress class="buffer"></progress>').attr({min:0,max:this.duration}),d=$('<div class="handle"><div class="inner-handle"></div></div>');if(i.append(s).append(l).append(d),this.progress=s,this.buffer=l,this.handle=d,this.setProgress(this.timeline.getTime()),this.chapterModule){var p=this.chapterModule.chapters.map(u,this);p.shift(),i.append(p)}var f=$('<div class="progressbar"></div>');return f.append(t).append(i),this.bar=f,f},d.prototype.addEvents=function(){function e(e){var t=a.outerWidth(!0),n=a.offset(),i=p(e-n.left,0,t),r=i/t;return r*o.duration}function t(t){t.preventDefault(),t.stopPropagation();var n=t.pageX;if(t.originalEvent.changedTouches&&(n=t.originalEvent.changedTouches[0].pageX),"number"==typeof o.duration&&r){var i=e(n);i!==o.getTime()&&o.seek(i)}}function n(){r=!1,$(document).unbind("touchend.dur mouseup.dur touchmove.dur mousemove.dur")}function i(e){(0===e.which||1===e.which)&&(r=!0,t(e),$(document).bind("mousemove.dur touchmove.dur",t).bind("mouseup.dur touchend.dur",n))}var r=!1,o=this.timeline,a=this.progress;this.progress.bind("mousedown touchstart",i),this.handle.bind("touchstart mousedown",i)},t.exports=d}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/modules/progressbar.js","/modules")},{"../timecode":21,"../util":24,buffer:2,oMfpAn:5}],13:[function(e,t){(function(){"use strict";function e(){return+localStorage[this.key]}function n(){return localStorage.removeItem(this.key)}function i(){return this.key in localStorage}function r(){return console.debug("SaveTime","update",this.timeline.getTime()),0===this.timeline.getTime()?n.call(this):(this.setItem(this.timeline.getTime()),void 0)}function o(t,o){this.timeline=t,this.key=a+o.permalink,this.getItem=e.bind(this),this.removeItem=n.bind(this),this.hasItem=i.bind(this),this.update=r.bind(this),this.hasItem()&&t.setTime(this.getItem())}var a="podlove-web-player-playtime-";o.prototype.setItem=function(e){localStorage[this.key]=e},t.exports=o}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/modules/savetime.js","/modules")},{buffer:2,oMfpAn:5}],14:[function(e,t){(function(){"use strict";function n(e){if("show"===e)return g.show;var t=g.episode;return t}function i(e){d.update(e),c.update(e)}function r(e,t){var r=n(t),o=e.find("[type=radio]");return function(){l.removeClass("selected"),o.prop("checked",!0),e.addClass("selected"),l=e,console.log("sharing options changed",e,t),i(r)}}function o(e){if(e.disabled)return console.log("Share","createOption","omit disabled option",e.name),null;var t=n(e.value);if(!t)return console.log("Share","createOption","omit option without data",e.name),null;var o=$('<tr class="share-select-option"><td class="share-description">'+e.name+'</td><td class="share-radio"><input type="radio" id="share-option-'+e.name+'" name="r-group" value="'+e.title+'"></td><td class="share-label"><label for="share-option-'+e.name+'">'+e.title+"</label></td></tr>"),a=o.find("[type=radio]");e.default&&(l=o,o.addClass("selected"),a.prop("checked",!0),i(t));var s=r(o,e.value);return o.on("click",s),o}function a(e){m[0].title=e.show.title,m[1].title=e.title;var t=$('<table class="share-button-wrapper" data-toggle="buttons"><caption>Podcast teilen</caption><tbody></tbody</table>');return t.append(m.map(o)),t}function s(e){var t=$("<form><h3>Was möchtest du teilen?</h3></form>");return t.append(a(e)),t}function u(e){if(!e.permalink||e.hidesharebutton===!0)return null;var t=new p({icon:"pwp-share",title:"Teilen anzeigen / verbergen",name:"share",headline:"Teilen"});return d=new f(h,n("episode")),c=$('<h3>Direkter Link</h3><input type="url" name="share-link-url" readonly>'),c.update=function(e){this.val(e.rawUrl)},t.createMainContent("").append(s(e)).append("<h3>Teilen via ...</h3>").append(d.list),t.createFooter("").append(c),t}var l,d,c,p=e("../tab"),f=e("../social-button-list"),h=["twitter","facebook","gplus","tumblr","email"],m=[{name:"Show",value:"show"},{name:"Episode",value:"episode","default":!0},{name:"Chapter",value:"chapter",disabled:!0},{name:"Exactly this part here",value:"timed",disabled:!0}],g={};t.exports=function(e){g.episode={poster:e.poster,title:encodeURIComponent(e.title),url:encodeURIComponent(e.permalink),rawUrl:e.permalink,text:encodeURIComponent(e.title+" "+e.permalink)},g.chapters=e.chapters,e.show.url&&(g.show={poster:e.show.poster,title:encodeURIComponent(e.show.title),url:encodeURIComponent(e.show.url),rawUrl:e.show.url,text:encodeURIComponent(e.show.title+" "+e.show.url)}),l="episode",this.tab=u(e)}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/modules/share.js","/modules")},{"../social-button-list":16,"../tab":19,buffer:2,oMfpAn:5}],15:[function(e,t){(function(){"use strict";function n(e){return"auto"===e.toLowerCase()?"100%":e.replace("px","")}function i(e){return e.tagName.toLowerCase()}function r(e){$.each(e.features,function(t){"playpause"===this&&e.features.splice(t,1)})}function o(){var e=$(this);if(e.attr("src"))return e.removeAttr("src"),void 0;var t=e.children("source");t.length&&t.first().remove()}function a(e,t,a){var d,c,p,f=i(e);d=$(e),p=$('<div class="container"></div>'),d.replaceWith(p),t.width=n(t.width),"audio"===f&&(void 0!==t.audioWidth&&(t.width=t.audioWidth),l.audioWidth=t.width,$.each(l.features,function(e){"fullscreen"===this&&l.features.splice(e,1)}),r(l)),t.duration&&t.duration!==parseInt(t.duration,10)&&(c=s(t.duration),t.duration=c[0]),$.each(l,function(e){e in t&&(l[e]=t[e])}),t.width.toString().trim()===parseInt(t.width,10).toString()&&(t.width=parseInt(t.width,10)+"px"),u.push(e),d.find("source").each(function(){t.sources||(t.sources=[]),t.sources.push($(this).attr("src"))}),t.type=f,l.success=function(e){d.on("error",o),a(e,t,p)};var h=new MediaElement(e,l);console.log("MediaElement",h)}var s=e("./timecode").parse,u=[],l={defaultVideoWidth:480,defaultVideoHeight:270,videoWidth:-1,videoHeight:-1,audioWidth:-1,audioHeight:30,startVolume:.8,loop:!1,enableAutosize:!0,features:["playpause","current","progress","duration","tracks","fullscreen"],alwaysShowControls:!1,iPadUseNativeControls:!1,iPhoneUseNativeControls:!1,AndroidUseNativeControls:!1,alwaysShowHours:!1,showTimecodeFrameCount:!1,framesPerSecond:25,enableKeyboard:!0,pauseOtherPlayers:!0,duration:!1,plugins:["flash","silverlight"],pluginPath:"./bin/",flashName:"flashmediaelement.swf",silverlightName:"silverlightmediaelement.xap"},d={chapterlinks:"all",width:"100%",duration:!1,chaptersVisible:!1,timecontrolsVisible:!1,sharebuttonsVisible:!1,downloadbuttonsVisible:!1,summaryVisible:!1,hidetimebutton:!1,hidedownloadbutton:!1,hidesharebutton:!1,sharewholeepisode:!1,sources:[]};t.exports={create:a,defaults:d,players:u}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/player.js","/")},{"./timecode":21,buffer:2,oMfpAn:5}],16:[function(e,t){(function(){"use strict";function n(e){return function(t){var n=r.get(t);return n.getButton(e)}}function i(e,t){var i=n(t);this.buttons=e.map(i),this.list=$('<ul class="social-network-buttons"></ul>'),this.buttons.forEach(function(e){var t=$("<li></li>").append(e.element);this.list.append(t)},this)}var r=e("./social-networks");i.prototype.update=function(e){this.buttons.forEach(function(t){t.updateUrl(e)})},t.exports=i}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/social-button-list.js","/")},{"./social-networks":18,buffer:2,oMfpAn:5}],17:[function(e,t){(function(){"use strict";function e(e){return $('<a class="pwp-contrast-'+e.icon+'" target="_blank" href="'+e.url+'" title="'+e.title+'"><i class="icon pwp-'+e.icon+'"></i></a><span>'+e.title+"</span>")}function n(e){this.icon=e.icon,this.title=e.title,this.url=e.profileUrl,this.shareUrl=e.shareUrl}n.prototype.getShareUrl=function(e){var t=this.shareUrl.replace("$text$",e.text).replace("$title$",e.title).replace("$url$",e.url);return this.url+t},n.prototype.getProfileUrl=function(e){return this.url+e},n.prototype.getProfileButton=function(t){return t.profile?{element:e({url:this.getProfileUrl(t.profile),title:this.title,icon:this.icon})}:null},n.prototype.getShareButton=function(t){if(!this.shareUrl||!t.title||!t.url)return null;t.text||(t.text=t.title+"%20"+t.url);var n=e({url:this.getShareUrl(t),title:this.title,icon:this.icon}),i=function(e){n.get(0).href=this.getShareUrl(e)}.bind(this);return{element:n,updateUrl:i}},n.prototype.getButton=function(e){return e.profile?this.getProfileButton(e):this.shareUrl&&e.title&&e.url?this.getShareButton(e):null},t.exports=n}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/social-network.js","/")},{buffer:2,oMfpAn:5}],18:[function(e,t){(function(){"use strict";function n(e){var t=r[e];return t||console.error("Unknown service",e),t}var i=e("./social-network"),r={twitter:new i({icon:"twitter",title:"Twitter",profileUrl:"https://twitter.com/",shareUrl:"share?text=$text$&url=$url$"}),flattr:new i({icon:"flattr",title:"Flattr",profileUrl:"https://flattr.com/profile/",shareUrl:"share?text=$text$&url=$url$"}),facebook:new i({icon:"facebook",title:"Facebook",profileUrl:"https://facebook.com/",shareUrl:"share.php?t=$text$&u=$url$"}),adn:new i({icon:"adn",title:"App.net",profileUrl:"https://alpha.app.net/",shareUrl:"intent/post?text=$text$"}),soundcloud:new i({icon:"soundcloud",title:"SoundCloud",profileUrl:"https://soundcloud.com/",shareUrl:"share?title=$title$&url=$url$"}),instagram:new i({icon:"instagram",title:"Instagram",profileUrl:"http://instagram.com/",shareUrl:"share?title=$title$&url=$url$"}),tumblr:new i({icon:"tumblr",title:"Tumblr",profileUrl:"https://www.tumblr.com/",shareUrl:"share?title=$title$&url=$url$"}),email:new i({icon:"message",title:"E-Mail",profileUrl:"mailto:",shareUrl:"?subject=$title$&body=$text$"}),gplus:new i({icon:"google-plus",title:"Google+",profileUrl:"https://plus.google.com/",shareUrl:"share?title=$title$&url=$url$"})};t.exports={get:n}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/social-networks.js","/")},{"./social-network":17,buffer:2,oMfpAn:5}],19:[function(e,t){(function(){"use strict";function e(e){var t=e.currentTarget.scrollTop;e.data.header.toggleClass("scrolled",t>=5)}function n(e){var t=["tab"];return t.push(e.name),e.active&&t.push("active"),$('<section class="'+t.join(" ")+'"></section>')}function i(t){this.icon=t.icon,this.title=t.title,this.headline=t.headline,this.name=t.name,this.box=n(t);var i=this.createHeader();this.box.on("scroll",{header:i},e),this.active=!1,this.toggle=null}i.prototype.open=function(){this.active=!0,this.box.addClass("active"),this.toggle.addClass("active")},i.prototype.close=function(){this.active=!1,this.box.removeClass("active"),this.toggle.removeClass("active")},i.prototype.createHeader=function(){var e=$('<header class="tab-header"><h2 class="tab-headline"><i class="icon '+this.icon+'"></i>'+this.headline+"</h2></header>");return this.box.append(e),e},i.prototype.createMainContent=function(e){var t=$('<div class="main">'+e+"</div");return this.box.append(t),t},i.prototype.createAside=function(e){var t=$('<aside class="aside">'+e+"</aside>");return this.box.append(t),t},i.prototype.createFooter=function(e){var t=$("<footer>"+e+"</footer>");return this.box.append(t),t},t.exports=i}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/tab.js","/")},{buffer:2,oMfpAn:5}],20:[function(e,t){(function(){"use strict";function e(e){return console.debug("TabRegistry","activeTab",this.activeTab),this.activeTab&&this.activeTab.close(),this.activeTab===e?(this.activeTab=null,!1):(this.activeTab=e,this.activeTab.open(),!1)}function n(e){console.log("player.currentTime",e.currentTime)}function i(){this.activeTab=null,this.togglebar=$('<div class="togglebar bar"></div>'),this.toggleList=$('<ul class="tablist"></ul>'),this.togglebar.append(this.toggleList),this.container=$('<div class="tabs"></div>'),this.listeners=[n],this.tabs=[]}i.prototype.createToggleFor=function(t){var n=$('<li title="'+t.title+'"><a href="javascript:;" class="button button-toggle '+t.icon+'"></a></li>');return n.on("click",e.bind(this,t)),this.toggleList.append(n),n},i.prototype.add=function(e){null!==e&&(this.tabs.push(e),this.container.append(e.box),e.toggle=this.createToggleFor(e))},i.prototype.openInitial=function(e){if(e){var t=this.tabs.filter(function(t){return t.name===e});if(0===t.length)return console.warn("TabRegistry.openInitial: Could not open tab",e),void 0;var n=t.pop();n.open(),this.activeTab=n}},i.prototype.addModule=function(e){e.tab&&this.add(e.tab),e.update&&this.listeners.push(e.update)},i.prototype.update=function(e){console.log("TabRegistry#update",e);var t=e.currentTarget;$.each(this.listeners,function(e,n){n(t)})},t.exports=i}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/tabregistry.js","/")},{buffer:2,oMfpAn:5}],21:[function(e,t){(function(){"use strict";function n(e){if(!e)return!1;var t=o.exec(e);if(!t)return console.warn("Could not extract time from",e),!1;var n=0;return n+=t[1]?60*parseInt(t[1],10)*60:0,n+=60*parseInt(t[2],10),n+=parseInt(t[3],10),n+=t[4]?parseFloat(t[4]):0,n=Math.max(n,0)}function i(e,t,n,i){var o,a,s,u,l="";return 0===e?n?"00:00:00":"00:00":!e||0>=e?n?"--:--:--":"--:--":(o=Math.floor(e/60/60),a=Math.floor(e/60)%60,s=Math.floor(e%60)%60,u=Math.floor(e%1*1e3),i&&u&&(l="."+r(u,3)),l=":"+r(s,2)+l,0!==o||n||t?(l=r(a,2)+l,0!==o||n?t?r(o,2)+":"+l:o+":"+l:l):a.toString()+l)}var r=e("./util").zeroFill,o=/(?:(\d+):)?(\d{1,2}):(\d\d)(\.\d{1,3})?/;t.exports={fromTimeStamp:function(e){return i(e,!0,!0)},generate:function(e,t,n){return e[1]>0&&e[1]<9999999&&e[0]<e[1]?i(e[0],t,n)+","+i(e[1],t,n):i(e[0],t,n)},parse:function(e){if(!e)return[!1,!1];var t=e.split("-");if(!t.length)return console.warn("no timeparts:",e),[!1,!1];var i=n(t.shift()),r=n(t.shift());return r>i?[i,r]:[i,!1]},getStartTimeCode:function(e){return this.parse(e)[0]}}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/timecode.js","/")},{"./util":24,buffer:2,oMfpAn:5}],22:[function(e,t){(function(){"use strict";function n(e){e(this)}function i(e){return function(t){return t.type===e}}function r(e){console.log("Timeline","currentTime",e.getTime())}function o(e){return!!e.chapters&&"object"==typeof e.chapters&&e.chapters.length>1}function a(){this.currentTime>=this.endTime&&(console.log("ENDTIME REACHED"),this.player.stop(),delete this.endTime)}function s(e,t){this.player=e,this.hasChapters=o(t),this.modules=[],this.listeners=[r],this.currentTime=-1,this.duration=t.duration,this.bufferedTime=0,this.resume=e.paused,this.seeking=!1}var u=e("./util").cap;s.prototype.getData=function(){return this.data},s.prototype.getDataByType=function(e){return this.data.filter(i(e))},s.prototype.addModule=function(e){e.update&&this.listeners.push(e.update),e.data&&(this.data=e.data),this.modules.push(e)},s.prototype.playRange=function(e){if(!e||!e.length||!e.shift)throw new TypeError("Timeline.playRange called without a range");this.setTime(e.shift()),this.stopAt(e.shift())},s.prototype.update=function(e){console.log("Timeline","update",e),this.setBufferedTime(e),e&&"timeupdate"===e.type&&(this.currentTime=this.player.currentTime),this.listeners.forEach(n,this)},s.prototype.emitEventsBetween=function(e,t){var n=!1,i=function(e){var t=new $.Event(e.type,e);$(this).trigger(t)}.bind(this);this.data.map(function(r){var o=r.start>e,a=r.end<e,s=r.end<t;(o&&a&&!s||n)&&(console.log("Timeline","Emit",r),i(r)),n=o})},s.prototype.isValidTime=function(e){return"number"==typeof e&&!isNaN(e)&&e>=0&&e<=this.duration},s.prototype.setTime=function(e){return this.isValidTime(e)?(console.log("Timeline","setTime","time",e),this.currentTime=e,this.update(),console.log("canplay","setTime","playerState",this.player.readyState),this.player.readyState===this.player.HAVE_ENOUGH_DATA?(this.player.setCurrentTime(e),this.currentTime):($(this.player).one("canplay",function(){console.log("Player","canplay","buffered",e),this.setCurrentTime(e)}),this.currentTime)):(console.warn("Timeline","setTime","time out of bounds",e),this.currentTime)},s.prototype.seek=function(e){console.debug("Timeline","seek",e),this.currentTime=u(e,0,this.duration),this.setTime(this.currentTime)},s.prototype.stopAt=function(e){if(!e||0>=e||e>this.duration)return console.warn("Timeline","stopAt","time out of bounds",e);var t=this;this.endTime=e,this.listeners.push(function(){a.call(t)})},s.prototype.getTime=function(){return this.currentTime},s.prototype.getBuffered=function(){return isNaN(this.bufferedTime)?(console.warn("Timeline","getBuffered","bufferedTime is not a number"),0):this.bufferedTime},s.prototype.setBufferedTime=function(e){var t=void 0!==e?e.target:this.player,n=0;t&&t.buffered&&t.buffered.length>0&&t.buffered.end&&t.duration?n=t.buffered.end(t.buffered.length-1):t&&void 0!==t.bytesTotal&&t.bytesTotal>0&&void 0!==t.bufferedBytes?n=t.bufferedBytes/t.bytesTotal*t.duration:e&&e.lengthComputable&&0!==e.total&&(n=e.loaded/e.total*t.duration);var i=u(n,0,t.duration);console.log("Timeline","setBufferedTime",i),this.bufferedTime=i},s.prototype.rewind=function(){this.setTime(0);var e=function(e,t){t(this)}.bind(this);$.each(this.listeners,e)},t.exports=s}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/timeline.js","/")},{"./util":24,buffer:2,oMfpAn:5}],23:[function(e,t){(function(){"use strict";function n(e){var t=window.location.hash.substring(1),n=t.split("&");if(-1===t.indexOf(e))return!1;for(var i=0,r=n.length;r>i;i++){var o=n[i].split("=");if(o[0]===e)return 1===o.length?!0:decodeURIComponent(o[1])}return!1}var i=e("./timecode");t.exports={getFragment:n,checkCurrent:function(){var e=n("t");return i.parse(e)}}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/url.js","/")},{"./timecode":21,buffer:2,oMfpAn:5}],24:[function(e,t){(function(){"use strict";function e(e,t,n){return e=Math.max(e,t),e=Math.min(e,n)}function n(e,t){for(var n=e.toString();n.length<t;)n="0"+n;return n}t.exports={cap:e,zeroFill:n}}).call(this,e("oMfpAn"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/util.js","/")},{buffer:2,oMfpAn:5}]},{},[8]);