/** @license SoundManager 2: JavaScript Sound for the Web ---------------------------------------------- http://schillmania.com/projects/soundmanager2/ Copyright (c) 2007, Scott Schiller. All rights reserved. Code provided under the BSD License: http://schillmania.com/projects/soundmanager2/license.txt V2.97a.20120916 */ (function(Z){function $($,oa){function aa(a){return c.preferFlash&&z&&!c.ignoreFlash&&"undefined"!==typeof c.flash[a]&&c.flash[a]}function q(a){return function(d){var e=this._t;!e||!e._a?(e&&e.id?c._wD(s+"ignoring "+d.type+": "+e.id):c._wD(s+"ignoring "+d.type),d=null):d=a.call(this,d);return d}}this.setupOptions={url:$||null,flashVersion:8,debugMode:!0,debugFlash:!1,useConsole:!0,consoleOnly:!0,waitForWindowLoad:!1,bgColor:"#ffffff",useHighPerformance:!1,flashPollingInterval:null,html5PollingInterval:null, flashLoadTimeout:1E3,wmode:null,allowScriptAccess:"always",useFlashBlock:!1,useHTML5Audio:!0,html5Test:/^(probably|maybe)$/i,preferFlash:!0,noSWFCache:!1};this.defaultOptions={autoLoad:!1,autoPlay:!1,from:null,loops:1,onid3:null,onload:null,whileloading:null,onplay:null,onpause:null,onresume:null,whileplaying:null,onposition:null,onstop:null,onfailure:null,onfinish:null,multiShot:!0,multiShotEvents:!1,position:null,pan:0,stream:!0,to:null,type:null,usePolicyFile:!1,volume:100};this.flash9Options= {isMovieStar:null,usePeakData:!1,useWaveformData:!1,useEQData:!1,onbufferchange:null,ondataerror:null};this.movieStarOptions={bufferTime:3,serverURL:null,onconnect:null,duration:null};this.audioFormats={mp3:{type:['audio/mpeg; codecs="mp3"',"audio/mpeg","audio/mp3","audio/MPA","audio/mpa-robust"],required:!0},mp4:{related:["aac","m4a","m4b"],type:['audio/mp4; codecs="mp4a.40.2"',"audio/aac","audio/x-m4a","audio/MP4A-LATM","audio/mpeg4-generic"],required:!1},ogg:{type:["audio/ogg; codecs=vorbis"], required:!1},wav:{type:['audio/wav; codecs="1"',"audio/wav","audio/wave","audio/x-wav"],required:!1}};this.movieID="sm2-container";this.id=oa||"sm2movie";this.debugID="soundmanager-debug";this.debugURLParam=/([#?&])debug=1/i;this.versionNumber="V2.97a.20120916";this.altURL=this.movieURL=this.version=null;this.enabled=this.swfLoaded=!1;this.oMC=null;this.sounds={};this.soundIDs=[];this.didFlashBlock=this.muted=!1;this.filePattern=null;this.filePatterns={flash8:/\.mp3(\?.*)?$/i,flash9:/\.mp3(\?.*)?$/i}; this.features={buffering:!1,peakData:!1,waveformData:!1,eqData:!1,movieStar:!1};this.sandbox={type:null,types:{remote:"remote (domain-based) rules",localWithFile:"local with file access (no internet access)",localWithNetwork:"local with network (internet access only, no local access)",localTrusted:"local, trusted (local+internet access)"},description:null,noRemote:null,noLocal:null};var pa;try{pa="undefined"!==typeof Audio&&"undefined"!==typeof(qa&&10>opera.version()?new Audio(null):new Audio).canPlayType}catch(ib){pa= !1}this.hasHTML5=pa;this.html5={usingFlash:null};this.flash={};this.ignoreFlash=this.html5Only=!1;var Ka,c=this,h=null,s="HTML5::",A,v=navigator.userAgent,k=Z,Q=k.location.href.toString(),i=document,ra,La,sa,j,D=[],ta=!0,x,R=!1,S=!1,m=!1,o=!1,ba=!1,n,eb=0,T,w,ua,H,va,I,J,K,Ma,wa,ca,da,ea,L,xa,U,fa,ga,M,Na,ya,fb=["log","info","warn","error"],Oa,ha,Pa,V=null,za=null,p,Aa,N,Qa,ia,ja,O,t,W=!1,Ba=!1,Ra,Sa,Ta,ka=0,X=null,la,B=null,Ua,ma,Y,E,Ca,Da,Va,u,Wa=Array.prototype.slice,G=!1,z,Ea,Xa,C,Ya,Fa=v.match(/(ipad|iphone|ipod)/i), F=v.match(/msie/i),gb=v.match(/webkit/i),Ga=v.match(/safari/i)&&!v.match(/chrome/i),qa=v.match(/opera/i),Ha=v.match(/(mobile|pre\/|xoom)/i)||Fa,Ia=!Q.match(/usehtml5audio/i)&&!Q.match(/sm2\-ignorebadua/i)&&Ga&&!v.match(/silk/i)&&v.match(/OS X 10_6_([3-7])/i),Za="undefined"!==typeof console&&"undefined"!==typeof console.log,Ja="undefined"!==typeof i.hasFocus?i.hasFocus():null,na=Ga&&("undefined"===typeof i.hasFocus||!i.hasFocus()),$a=!na,ab=/(mp3|mp4|mpa|m4a|m4b)/i,P=i.location?i.location.protocol.match(/http/i): null,bb=!P?"http://":"",cb=/^\s*audio\/(?:x-)?(?:mpeg4|aac|flv|mov|mp4||m4v|m4a|m4b|mp4v|3gp|3g2)\s*(?:$|;)/i,db="mpeg4,aac,flv,mov,mp4,m4v,f4v,m4a,m4b,mp4v,3gp,3g2".split(","),hb=RegExp("\\.("+db.join("|")+")(\\?.*)?$","i");this.mimePattern=/^\s*audio\/(?:x-)?(?:mp(?:eg|3))\s*(?:$|;)/i;this.useAltURL=!P;this._global_a=null;if(Ha&&(c.useHTML5Audio=!0,c.preferFlash=!1,Fa))G=c.ignoreFlash=!0;this.setup=function(a){var d=!c.url;"undefined"!==typeof a&&m&&B&&c.ok()&&("undefined"!==typeof a.flashVersion|| "undefined"!==typeof a.url)&&O(p("setupLate"));ua(a);d&&U&&"undefined"!==typeof a.url&&c.beginDelayedInit();!U&&"undefined"!==typeof a.url&&"complete"===i.readyState&&setTimeout(L,1);return c};this.supported=this.ok=function(){return B?m&&!o:c.useHTML5Audio&&c.hasHTML5};this.getMovie=function(c){return A(c)||i[c]||k[c]};this.createSound=function(a,d){function e(){g=ia(g);c.sounds[f.id]=new Ka(f);c.soundIDs.push(f.id);return c.sounds[f.id]}var b,g=null,f=b=null;b="soundManager.createSound(): "+p(!m? "notReady":"notOK");if(!m||!c.ok())return O(b),!1;"undefined"!==typeof d&&(a={id:a,url:d});g=w(a);g.url=la(g.url);f=g;f.id.toString().charAt(0).match(/^[0-9]$/)&&c._wD("soundManager.createSound(): "+p("badID",f.id),2);c._wD("soundManager.createSound(): "+f.id+" ("+f.url+")",1);if(t(f.id,!0))return c._wD("soundManager.createSound(): "+f.id+" exists",1),c.sounds[f.id];if(ma(f))b=e(),c._wD("Creating sound "+f.id+", using HTML5"),b._setup_html5(f);else{if(8=a)return!1;for(a-=1;0<=a;a--)if(c=y[a],!c.fired&&b.position>=c.position)c.fired=!0,q++,c.method.apply(c.scope,[c.position]);return!0};this._resetOnPosition=function(b){var a,c;a=y.length;if(!a)return!1;for(a-=1;0<=a;a--)if(c=y[a],c.fired&&b<=c.position)c.fired=!1,q--; return!0};v=function(){var a=b._iO,d=a.from,e=a.to,f,g;g=function(){c._wD(b.id+': "to" time of '+e+" reached.");b.clearOnPosition(e,g);b.stop()};f=function(){c._wD(b.id+': playing "from" '+d);if(null!==e&&!isNaN(e))b.onPosition(e,g)};if(null!==d&&!isNaN(d))a.position=d,a.multiShot=!1,f();return a};k=function(){var a,c=b._iO.onposition;if(c)for(a in c)if(c.hasOwnProperty(a))b.onPosition(parseInt(a,10),c[a])};u=function(){var a,c=b._iO.onposition;if(c)for(a in c)c.hasOwnProperty(a)&&b.clearOnPosition(parseInt(a, 10))};i=function(){b.isHTML5&&Ra(b)};l=function(){b.isHTML5&&Sa(b)};g=function(a){a||(y=[],q=0);m=!1;b._hasTimer=null;b._a=null;b._html5_canplay=!1;b.bytesLoaded=null;b.bytesTotal=null;b.duration=b._iO&&b._iO.duration?b._iO.duration:null;b.durationEstimate=null;b.buffered=[];b.eqData=[];b.eqData.left=[];b.eqData.right=[];b.failures=0;b.isBuffering=!1;b.instanceOptions={};b.instanceCount=0;b.loaded=!1;b.metadata={};b.readyState=0;b.muted=!1;b.paused=!1;b.peakData={left:0,right:0};b.waveformData={left:[], right:[]};b.playState=0;b.position=null;b.id3={}};g();this._onTimer=function(a){var c,f=!1,g={};if(b._hasTimer||a){if(b._a&&(a||(0opera.version()?new Audio(null):new Audio,e=b._a,e._called_load=!1,G)c._global_a=e;b.isHTML5=!0;b._a=e;e._t=b;f();b._apply_loop(e,a.loops);a.autoLoad||a.autoPlay?b.load():(e.autobuffer=!1,e.preload="auto");return e};f=function(){if(b._a._added_events)return!1;var a;b._a._added_events=!0;for(a in C)C.hasOwnProperty(a)&&b._a&&b._a.addEventListener(a,C[a],!1); return!0};r=function(){var a;c._wD(s+"removing event listeners: "+b.id);b._a._added_events=!1;for(a in C)C.hasOwnProperty(a)&&b._a&&b._a.removeEventListener(a,C[a],!1)};this._onload=function(a){a=!!a||!b.isHTML5&&8===j&&b.duration;c._wD('SMSound._onload(): "'+b.id+'"'+(a?" loaded.":" failed to load? - "+b.url),a?1:2);!a&&!b.isHTML5&&(!0===c.sandbox.noRemote&&c._wD("SMSound._onload(): "+p("noNet"),1),!0===c.sandbox.noLocal&&c._wD("SMSound._onload(): "+p("noLocal"),1));b.loaded=a;b.readyState=a?3:2; b._onbufferchange(0);b._iO.onload&&b._iO.onload.apply(b,[a]);return!0};this._onbufferchange=function(a){if(0===b.playState||a&&b.isBuffering||!a&&!b.isBuffering)return!1;b.isBuffering=1===a;b._iO.onbufferchange&&(c._wD("SMSound._onbufferchange(): "+a),b._iO.onbufferchange.apply(b));return!0};this._onsuspend=function(){b._iO.onsuspend&&(c._wD("SMSound._onsuspend()"),b._iO.onsuspend.apply(b));return!0};this._onfailure=function(a,d,e){b.failures++;c._wD('SMSound._onfailure(): "'+b.id+'" count '+b.failures); if(b._iO.onfailure&&1===b.failures)b._iO.onfailure(b,a,d,e);else c._wD("SMSound._onfailure(): ignoring")};this._onfinish=function(){var a=b._iO.onfinish;b._onbufferchange(0);b._resetOnPosition(0);if(b.instanceCount){b.instanceCount--;if(!b.instanceCount&&(u(),b.playState=0,b.paused=!1,b.instanceCount=0,b.instanceOptions={},b._iO={},l(),b.isHTML5))b.position=0;if((!b.instanceCount||b._iO.multiShotEvents)&&a)c._wD('SMSound._onfinish(): "'+b.id+'"'),a.apply(b)}};this._whileloading=function(a,c,d,e){var f= b._iO;b.bytesLoaded=a;b.bytesTotal=c;b.duration=Math.floor(d);b.bufferLength=e;b.durationEstimate=!b.isHTML5&&!f.isMovieStar?f.duration?b.duration>f.duration?b.duration:f.duration:parseInt(b.bytesTotal/b.bytesLoaded*b.duration,10):b.duration;if(!b.isHTML5)b.buffered=[{start:0,end:b.duration}];(3!==b.readyState||b.isHTML5)&&f.whileloading&&f.whileloading.apply(b)};this._whileplaying=function(a,c,d,e,f){var g=b._iO;if(isNaN(a)||null===a)return!1;b.position=Math.max(0,a);b._processOnPosition();if(!b.isHTML5&& 8opera.version()?new Audio(null): new Audio:null,e,b,g={},f;f=c.audioFormats;for(e in f)if(f.hasOwnProperty(e)&&(b="audio/"+e,g[e]=a(f[e].type),g[b]=g[e],e.match(ab)?(c.flash[e]=!0,c.flash[b]=!0):(c.flash[e]=!1,c.flash[b]=!1),f[e]&&f[e].related))for(b=f[e].related.length-1;0<=b;b--)g["audio/"+f[e].related[b]]=g[e],c.html5[f[e].related[b]]=g[e],c.flash[f[e].related[b]]=g[e];g.canPlayType=d?a:null;c.html5=w(c.html5,g);return!0};da={notReady:"Not loaded yet - wait for soundManager.onready()",notOK:"Audio support is not available.",domError:"soundManager::createMovie(): appendChild/innerHTML call failed. DOM not ready or other error.", spcWmode:"soundManager::createMovie(): Removing wmode, preventing known SWF loading issue(s)",swf404:"soundManager: Verify that %s is a valid path.",tryDebug:"Try soundManager.debugFlash = true for more security details (output goes to SWF.)",checkSWF:"See SWF output for more debug info.",localFail:"soundManager: Non-HTTP page ("+i.location.protocol+" URL?) Review Flash player security settings for this special case:\nhttp://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html\nMay need to add/allow path, eg. c:/sm2/ or /users/me/sm2/", waitFocus:"soundManager: Special case: Waiting for SWF to load with window focus...",waitImpatient:"soundManager: Getting impatient, still waiting for Flash%s...",waitForever:"soundManager: Waiting indefinitely for Flash (will recover if unblocked)...",waitSWF:"soundManager: Retrying, waiting for 100% SWF load...",needFunction:"soundManager: Function object expected for %s",badID:'Warning: Sound ID "%s" should be a string, starting with a non-numeric character',currentObj:"--- soundManager._debug(): Current sound objects ---", waitEI:"soundManager::initMovie(): Waiting for ExternalInterface call from Flash...",waitOnload:"soundManager: Waiting for window.onload()",docLoaded:"soundManager: Document already loaded",onload:"soundManager::initComplete(): calling soundManager.onload()",onloadOK:"soundManager.onload() complete",init:"soundManager::init()",didInit:"soundManager::init(): Already called?",flashJS:"soundManager: Attempting JS to Flash call...",secNote:"Flash security note: Network/internet URLs will not load due to security restrictions. Access can be configured via Flash Player Global Security Settings Page: http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html", badRemove:"Warning: Failed to remove flash movie.",shutdown:"soundManager.disable(): Shutting down",queue:"soundManager: Queueing %s handler",smFail:"soundManager: Failed to initialise.",smError:"SMSound.load(): Exception: JS-Flash communication failed, or JS error.",fbTimeout:"No flash response, applying .swf_timedout CSS...",fbLoaded:"Flash loaded",fbHandler:"soundManager::flashBlockHandler()",manURL:"SMSound.load(): Using manually-assigned URL",onURL:"soundManager.load(): current URL already assigned.", badFV:'soundManager.flashVersion must be 8 or 9. "%s" is invalid. Reverting to %s.',as2loop:"Note: Setting stream:false so looping can work (flash 8 limitation)",noNSLoop:"Note: Looping not implemented for MovieStar formats",needfl9:"Note: Switching to flash 9, required for MP4 formats.",mfTimeout:"Setting flashLoadTimeout = 0 (infinite) for off-screen, mobile flash case",needFlash:"soundManager: Fatal error: Flash is needed to play some required formats, but is not available.",gotFocus:"soundManager: Got window focus.", mfOn:"mobileFlash::enabling on-screen flash repositioning",policy:"Enabling usePolicyFile for data access",setup:"soundManager.setup(): allowed parameters: %s",setupError:'soundManager.setup(): "%s" cannot be assigned with this method.',setupUndef:'soundManager.setup(): Could not find option "%s"',setupLate:"soundManager.setup(): url + flashVersion changes will not take effect until reboot().",h5a:"creating HTML5 Audio() object",noURL:"soundManager: Flash URL required. Call soundManager.setup({url:...}) to get started."}; p=function(){var a=Wa.call(arguments),c=a.shift(),c=da&&da[c]?da[c]:"",e,b;if(c&&a&&a.length)for(e=0,b=a.length;ej)c._wD(p("needfl9")),c.flashVersion=j=9;c.version=c.versionNumber+(c.html5Only?" (HTML5-only mode)":9===j?" (AS3/Flash 9)":" (AS2/Flash 8)");8'}if(R&&S)return!1;if(c.html5Only)return wa(),e(),c.oMC=A(c.movieID),sa(),S=R=!0,!1;var g=d||c.url,f=c.altURL||g,h=fa(),l=N(),k=null,k=i.getElementsByTagName("html")[0],j,o,m,k=k&&k.dir&&k.dir.match(/rtl/i),a="undefined"===typeof a?c.id:a;wa();c.url=Pa(P?g:f);d=c.url;c.wmode=!c.wmode&&c.useHighPerformance?"transparent":c.wmode;if(null!== c.wmode&&(v.match(/msie 8/i)||!F&&!c.useHighPerformance)&&navigator.platform.match(/win32|win64/i))n("spcWmode"),c.wmode=null;h={name:a,id:a,src:d,quality:"high",allowScriptAccess:c.allowScriptAccess,bgcolor:c.bgColor,pluginspage:bb+"www.macromedia.com/go/getflashplayer",title:"JS/Flash audio component (SoundManager 2)",type:"application/x-shockwave-flash",wmode:c.wmode,hasPriority:"true"};if(c.debugFlash)h.FlashVars="debug=1";c.wmode||delete h.wmode;if(F)g=i.createElement("div"),o=['',b("movie",d),b("AllowScriptAccess",c.allowScriptAccess),b("quality",h.quality),c.wmode?b("wmode",c.wmode):"",b("bgcolor",c.bgColor),b("hasPriority","true"),c.debugFlash?b("FlashVars",h.FlashVars):"",""].join("");else for(j in g=i.createElement("embed"),h)h.hasOwnProperty(j)&&g.setAttribute(j, h[j]);ya();l=N();if(h=fa())if(c.oMC=A(c.movieID)||i.createElement("div"),c.oMC.id){m=c.oMC.className;c.oMC.className=(m?m+" ":"movieContainer")+(l?" "+l:"");c.oMC.appendChild(g);if(F)j=c.oMC.appendChild(i.createElement("div")),j.className="sm2-object-box",j.innerHTML=o;S=!0}else{c.oMC.id=c.movieID;c.oMC.className="movieContainer "+l;j=l=null;if(!c.useFlashBlock)if(c.useHighPerformance)l={position:"fixed",width:"8px",height:"8px",bottom:"0px",left:"0px",overflow:"hidden"};else if(l={position:"absolute", width:"6px",height:"6px",top:"-9999px",left:"-9999px"},k)l.left=Math.abs(parseInt(l.left,10))+"px";if(gb)c.oMC.style.zIndex=1E4;if(!c.debugFlash)for(m in l)l.hasOwnProperty(m)&&(c.oMC.style[m]=l[m]);try{F||c.oMC.appendChild(g);h.appendChild(c.oMC);if(F)j=c.oMC.appendChild(i.createElement("div")),j.className="sm2-object-box",j.innerHTML=o;S=!0}catch(q){throw Error(p("domError")+" \n"+q.toString());}}R=!0;e();c._wD("soundManager::createMovie(): Trying to load "+d+(!P&&c.altURL?" (alternate URL)":""), 1);return!0};ea=function(){if(c.html5Only)return ga(),!1;if(h)return!1;if(!c.url)return n("noURL"),!1;h=c.getMovie(c.id);if(!h)V?(F?c.oMC.innerHTML=za:c.oMC.appendChild(V),V=null,R=!0):ga(c.id,c.url),h=c.getMovie(c.id);h&&n("waitEI");"function"===typeof c.oninitmovie&&setTimeout(c.oninitmovie,1);return!0};K=function(){setTimeout(Ma,1E3)};Ma=function(){var a,d=!1;if(!c.url||W)return!1;W=!0;u.remove(k,"load",K);if(na&&!Ja)return n("waitFocus"),!1;m||(a=c.getMoviePercent(),c._wD(p("waitImpatient",0< a?" (SWF "+a+"% loaded)":"")),0a&&(d=!0));setTimeout(function(){a=c.getMoviePercent();if(d)return W=!1,c._wD(p("waitSWF")),k.setTimeout(K,1),!1;m||(c._wD("soundManager: No Flash response within expected time.\nLikely causes: "+(0===a?"Loading "+c.movieURL+" may have failed (and/or Flash "+j+"+ not present?), ":"")+"Flash blocked or JS-Flash security error."+(c.debugFlash?" "+p("checkSWF"):""),2),!P&&a&&(n("localFail",2),c.debugFlash||n("tryDebug",2)),0===a&&c._wD(p("swf404",c.url)),x("flashtojs", !1,": Timed out"+P?" (Check flash security or flash blockers)":" (No plugin/missing SWF?)"));!m&&$a&&(null===a?c.useFlashBlock||0===c.flashLoadTimeout?(c.useFlashBlock&&Aa(),n("waitForever")):ha(!0):0===c.flashLoadTimeout?n("waitForever"):ha(!0))},c.flashLoadTimeout)};ca=function(){if(Ja||!na)return u.remove(k,"focus",ca),!0;Ja=$a=!0;n("gotFocus");W=!1;K();u.remove(k,"focus",ca);return!0};Ya=function(){var a,d=[];if(c.useHTML5Audio&&c.hasHTML5){for(a in c.audioFormats)c.audioFormats.hasOwnProperty(a)&& d.push(a+": "+c.html5[a]+(!c.html5[a]&&z&&c.flash[a]?" (using flash)":c.preferFlash&&c.flash[a]&&z?" (preferring flash)":!c.html5[a]?" ("+(c.audioFormats[a].required?"required, ":"")+"and no flash support)":""));c._wD("-- SoundManager 2: HTML5 support tests ("+c.html5Test+"): "+d.join(", ")+" --",1)}};T=function(a){if(m)return!1;if(c.html5Only)return c._wD("-- SoundManager 2: loaded --"),m=!0,J(),x("onload",!0),!0;var d=!0,e;if(!c.useFlashBlock||!c.flashLoadTimeout||c.getMoviePercent())m=!0,o&&(e= {type:!z&&B?"NO_FLASH":"INIT_TIMEOUT"});c._wD("-- SoundManager 2 "+(o?"failed to load":"loaded")+" ("+(o?"Flash security/load error":"OK")+") --",1);if(o||a){if(c.useFlashBlock&&c.oMC)c.oMC.className=N()+" "+(null===c.getMoviePercent()?"swf_timedout":"swf_error");I({type:"ontimeout",error:e,ignoreInit:!0});x("onload",!1);M(e);d=!1}else x("onload",!0);o||(c.waitForWindowLoad&&!ba?(n("waitOnload"),u.add(k,"load",J)):(c.waitForWindowLoad&&ba&&n("docLoaded"),J()));return d};La=function(){var a,d=c.setupOptions; for(a in d)d.hasOwnProperty(a)&&("undefined"===typeof c[a]?c[a]=d[a]:c[a]!==d[a]&&(c.setupOptions[a]=c[a]))};sa=function(){n("init");if(m)return n("didInit"),!1;if(c.html5Only){if(!m)u.remove(k,"load",c.beginDelayedInit),c.enabled=!0,T();return!0}ea();try{n("flashJS"),h._externalInterfaceTest(!1),Na(!0,c.flashPollingInterval||(c.useHighPerformance?10:50)),c.debugMode||h._disableDebug(),c.enabled=!0,x("jstoflash",!0),c.html5Only||u.add(k,"unload",ra)}catch(a){return c._wD("js/flash exception: "+a.toString()), x("jstoflash",!1),M({type:"JS_TO_FLASH_EXCEPTION",fatal:!0}),ha(!0),T(),!1}T();u.remove(k,"load",c.beginDelayedInit);return!0};L=function(){if(U)return!1;U=!0;La();ya();var a=null,a=null,d="undefined"!==typeof console&&"function"===typeof console.log,e=Q.toLowerCase();-1!==e.indexOf("sm2-usehtml5audio=")&&(a="1"===e.charAt(e.indexOf("sm2-usehtml5audio=")+18),d&&console.log((a?"Enabling ":"Disabling ")+"useHTML5Audio via URL parameter"),c.setup({useHTML5Audio:a}));-1!==e.indexOf("sm2-preferflash=")&& (a="1"===e.charAt(e.indexOf("sm2-preferflash=")+16),d&&console.log((a?"Enabling ":"Disabling ")+"preferFlash via URL parameter"),c.setup({preferFlash:a}));!z&&c.hasHTML5&&(c._wD("SoundManager: No Flash detected"+(!c.useHTML5Audio?", enabling HTML5.":". Trying HTML5-only mode.")),c.setup({useHTML5Audio:!0,preferFlash:!1}));Va();c.html5.usingFlash=Ua();B=c.html5.usingFlash;Ya();!z&&B&&(n("needFlash"),c.setup({flashLoadTimeout:1}));i.removeEventListener&&i.removeEventListener("DOMContentLoaded",L,!1); ea();return!0};Da=function(){"complete"===i.readyState&&(L(),i.detachEvent("onreadystatechange",Da));return!0};xa=function(){ba=!0;u.remove(k,"load",xa)};Ea();u.add(k,"focus",ca);u.add(k,"load",K);u.add(k,"load",xa);i.addEventListener?i.addEventListener("DOMContentLoaded",L,!1):i.attachEvent?i.attachEvent("onreadystatechange",Da):(x("onload",!1),M({type:"NO_DOM2_EVENTS",fatal:!0}))}var oa=null;if("undefined"===typeof SM2_DEFER||!SM2_DEFER)oa=new $;Z.SoundManager=$;Z.soundManager=oa})(window);