(function(){function r(a){if(!a||typeof a!="object")return a;var b=new a.constructor,g;for(g in a)a.hasOwnProperty(g)&&(b[g]=r(a[g]));return b}function j(a,b){if(a){var g,d=0,c=a.length;if(c===void 0)for(g in a){if(b.call(a[g],g,a[g])===!1)break}else for(g=a[0];d<c&&b.call(g,d,g)!==!1;g=a[++d]);return a}}function l(a,b,g){if(typeof b!="object")return a;a&&b&&j(b,function(b,d){if(!g||typeof d!="function")a[b]=d});return a}function v(a){var b=a.indexOf(".");if(b!=-1){var g=a.substring(0,b)||"*",d=a.substring(b+
1,a.length),c=[];j(document.getElementsByTagName(g),function(){this.className&&this.className.indexOf(d)!=-1&&c.push(this)});return c}}function w(a){a=a||window.event;a.preventDefault?(a.stopPropagation(),a.preventDefault()):(a.returnValue=!1,a.cancelBubble=!0);return!1}function o(a,b,d){a[b]=a[b]||[];a[b].push(d)}function t(){return"_"+(""+Math.random()).substring(2,10)}function q(a,b,g){function k(){function y(a){!i.isLoaded()&&i._fireEvent("onBeforeClick")!==!1&&i.load();return w(a)}$f(a)?($f(a).getParent().innerHTML=
"",x=$f(a).getIndex(),e[x]=i):(e.push(i),x=e.length-1);z=parseInt(a.style.height,10)||a.clientHeight;typeof b=="string"&&(b={src:b});m=a.id||"fp"+t();q=b.id||m+"_api";b.id=q;g.playerId=m;typeof g=="string"&&(g={clip:{url:g}});if(typeof g.clip=="string")g.clip={url:g.clip};g.clip=g.clip||{};if(a.getAttribute("href",2)&&!g.clip.url)g.clip.url=a.getAttribute("href",2);u=new d(g.clip,-1,i);g.playlist=g.playlist||[g.clip];var h=0;j(g.playlist,function(){var a=this;typeof a=="object"&&a.length&&(a={url:""+
a});j(g.clip,function(b,d){d!==void 0&&a[b]===void 0&&typeof d!="function"&&(a[b]=d)});g.playlist[h]=a;a=new d(a,h,i);n.push(a);h++});j(g,function(a,b){typeof b=="function"&&(o(p,a,b),delete g[a])});j(g.plugins,function(a,b){b&&(s[a]=new c(a,b,i))});if(!g.plugins||g.plugins.controls===void 0)s.controls=new c("controls",null,i);s.canvas=new c("canvas",null,i);b.bgcolor=b.bgcolor||"#000000";b.version=b.version||[9,0];b.expressInstall="http://www.flowplayer.org/swf/expressinstall.swf";f=a.innerHTML;
f.replace(/\s/g,"")!==""?a.addEventListener?a.addEventListener("click",y,!1):a.attachEvent&&a.attachEvent("onclick",y):(a.addEventListener&&a.addEventListener("click",w,!1),i.load())}var i=this,h=null,f,u,n=[],s={},p={},m,q,x,A,v,z;l(i,{id:function(){return m},isLoaded:function(){return h!==null},getParent:function(){return a},hide:function(b){if(b)a.style.height="0px";if(h)h.style.height="0px";return i},show:function(){a.style.height=z+"px";if(h)h.style.height=v+"px";return i},isHidden:function(){return h&&
parseInt(h.style.height,10)===0},load:function(d){if(!h&&i._fireEvent("onBeforeLoad")!==!1){j(e,function(){this.unload()});if((f=a.innerHTML)&&!flashembed.isSupported(b.version))a.innerHTML="";flashembed(a,b,{config:g});if(d)d.cached=!0,o(p,"onLoad",d)}return i},unload:function(){try{if(!h||h.fp_isFullscreen())return i}catch(b){return i}if(f.replace(/\s/g,"")!==""){if(i._fireEvent("onBeforeUnload")===!1)return i;h.fp_close();h=null;a.innerHTML=f;i._fireEvent("onUnload")}return i},getClip:function(a){a===
void 0&&(a=A);return n[a]},getCommonClip:function(){return u},getPlaylist:function(){return n},getPlugin:function(a){var b=s[a];if(!b&&i.isLoaded()){var d=i._api().fp_getPlugin(a);d&&(b=new c(a,d,i),s[a]=b)}return b},getScreen:function(){return i.getPlugin("screen")},getControls:function(){return i.getPlugin("controls")},getConfig:function(a){return a?r(g):g},getFlashParams:function(){return b},loadPlugin:function(a,b,d,g){typeof d=="function"&&(g=d,d={});var u=g?t():"_";i._api().fp_loadPlugin(a,
b,d,u);b={};b[u]=g;g=new c(a,null,i,b);return s[a]=g},getState:function(){return h?h.fp_getState():-1},play:function(a,b){function d(){a!==void 0?i._api().fp_play(a,b):i._api().fp_play()}h?d():i.load(function(){d()});return i},getVersion:function(){if(h){var a=h.fp_getVersion();a.push("flowplayer.js 3.1.1");return a}return"flowplayer.js 3.1.1"},_api:function(){if(!h)throw"Flowplayer "+i.id()+" not loaded when calling an API method";return h},setClip:function(a){i.setPlaylist([a]);return i},getIndex:function(){return x}});
j("Click*,Load*,Unload*,Keypress*,Volume*,Mute*,Unmute*,PlaylistReplace,ClipAdd,Fullscreen*,FullscreenExit,Error".split(","),function(){var a="on"+this;if(a.indexOf("*")!=-1){var a=a.substring(0,a.length-1),b="onBefore"+a.substring(2);i[b]=function(a){o(p,b,a);return i}}i[a]=function(b){o(p,a,b);return i}});j("pause,resume,mute,unmute,stop,toggle,seek,getStatus,getVolume,setVolume,getTime,isPaused,isPlaying,startBuffering,stopBuffering,isFullscreen,toggleFullscreen,reset,close,setPlaylist,addClip".split(","),
function(){var a=this;i[a]=function(b,d){if(!h)return i;var g=null,g=b!==void 0&&d!==void 0?h["fp_"+a](b,d):b===void 0?h["fp_"+a]():h["fp_"+a](b);return g=="undefined"?i:g}});i._fireEvent=function(a){typeof a=="string"&&(a=[a]);var b=a[0],c=a[1],e=a[2],k=a[3],f=0;g.debug&&console.log("$f.fireEvent",[].slice.call(a));if(!h&&b=="onLoad"&&c=="player")h=h||document.getElementById(q),v=h.clientHeight,j(n,function(){this._fireEvent("onLoad")}),j(s,function(a,b){b._fireEvent("onUpdate")}),u._fireEvent("onLoad");
if(!(b=="onLoad"&&c!="player")){if(b=="onError"&&(typeof c=="string"||typeof c=="number"&&typeof e=="number"))c=e,e=k;if(b=="onContextMenu")j(g.contextMenu[c],function(a,b){b.call(i)});else if(b=="onPluginEvent"){if(k=s[c.name||c])k._fireEvent("onUpdate",c),k._fireEvent(e,a.slice(3))}else{if(b=="onPlaylistReplace"){n=[];var l=0;j(c,function(){n.push(new d(this,l++,i))})}if(b=="onClipAdd"){if(c.isInStream)return;c=new d(c,e,i);n.splice(e,0,c);for(f=e+1;f<n.length;f++)n[f].index++}var m=!0;if(typeof c==
"number"&&c<n.length&&(A=c,(a=n[c])&&(m=a._fireEvent(b,e,k)),!a||m!==!1))m=u._fireEvent(b,e,k,a);j(p[b],function(){m=this.call(i,c,e);this.cached&&p[b].splice(f,1);if(m===!1)return!1;f++});return m}}};typeof a=="string"?flashembed.domReady(function(){var b=document.getElementById(a);if(b)a=b,k();else throw"Flowplayer cannot access element: "+a;}):k()}function f(a){this.length=a.length;this.each=function(b){j(a,b)};this.size=function(){return a.length}}var d=function(a,b,d){var c=this,e={},h={};c.index=
b;typeof a=="string"&&(a={url:a});l(this,a,!0);j("Begin*,Start,Pause*,Resume*,Seek*,Stop*,Finish*,LastSecond,Update,BufferFull,BufferEmpty,BufferStop".split(","),function(){var a="on"+this;if(a.indexOf("*")!=-1){var a=a.substring(0,a.length-1),e="onBefore"+a.substring(2);c[e]=function(a){o(h,e,a);return c}}c[a]=function(b){o(h,a,b);return c};b==-1&&(c[e]&&(d[e]=c[e]),c[a]&&(d[a]=c[a]))});l(this,{onCuepoint:function(a,h){if(arguments.length==1)return e.embedded=[null,a],c;typeof a=="number"&&(a=[a]);
var f=t();e[f]=[a,h];d.isLoaded()&&d._api().fp_addCuepoints(a,b,f);return c},update:function(a){l(c,a);d.isLoaded()&&d._api().fp_updateClip(a,b);var e=d.getConfig();l(b==-1?e.clip:e.playlist[b],a,!0)},_fireEvent:function(a,n,f,p){if(a=="onLoad")return j(e,function(a,c){c[0]&&d._api().fp_addCuepoints(c[0],b,a)}),!1;p=p||c;if(a=="onCuepoint"){var m=e[n];if(m)return m[1].call(d,p,f)}if(a=="onStart"||a=="onUpdate"||a=="onResume")l(p,n),p.duration?p.fullDuration=n.metaData.duration:p.duration=n.metaData.duration;
var o=!0;j(h[a],function(){o=this.call(d,p,n,f)});return o}});if(a.onCuepoint){var f=a.onCuepoint;c.onCuepoint.apply(c,typeof f=="function"?[f]:f);delete a.onCuepoint}j(a,function(b,d){typeof d=="function"&&(o(h,b,d),delete a[b])});if(b==-1)d.onCuepoint=this.onCuepoint},c=function(a,b,d,c){var e={},h=this,f=!1;c&&l(e,c);j(b,function(a,d){typeof d=="function"&&(e[a]=d,delete b[a])});l(this,{animate:function(c,f,j){if(!c)return h;typeof f=="function"&&(j=f,f=500);if(typeof c=="string"){var k=c,c={};
c[k]=f;f=500}if(j){var m=t();e[m]=j}f===void 0&&(f=500);b=d._api().fp_animate(a,c,f,m);return h},css:function(c,e){if(e!==void 0){var f={};f[c]=e;c=f}b=d._api().fp_css(a,c);l(h,b);return h},show:function(){this.display="block";d._api().fp_showPlugin(a);return h},hide:function(){this.display="none";d._api().fp_hidePlugin(a);return h},toggle:function(){this.display=d._api().fp_togglePlugin(a);return h},fadeTo:function(b,c,f){typeof c=="function"&&(f=c,c=500);if(f){var j=t();e[j]=f}this.display=d._api().fp_fadeTo(a,
b,c,j);this.opacity=b;return h},fadeIn:function(a,b){return h.fadeTo(1,a,b)},fadeOut:function(a,b){return h.fadeTo(0,a,b)},getName:function(){return a},getPlayer:function(){return d},_fireEvent:function(b,c){if(b=="onUpdate"){var k=d._api().fp_getPlugin(a);if(!k)return;l(h,k);delete h.methods;f||(j(k.methods,function(){var b=""+this;h[b]=function(){var c=[].slice.call(arguments),c=d._api().fp_invoke(a,b,c);return c=="undefined"?h:c}}),f=!0)}if(k=e[b])k.apply(h,c),b.substring(0,1)=="_"&&delete e[b]}})},
e=[];window.flowplayer=window.$f=function(){var a=null,b=arguments[0];if(!arguments.length)return j(e,function(){if(this.isLoaded())return a=this,!1}),a||e[0];if(arguments.length==1)if(typeof b=="number")return e[b];else{if(b=="*")return new f(e);j(e,function(){if(this.id()==b.id||this.id()==b||this.getParent()==b)return a=this,!1});return a}if(arguments.length>1){var c=arguments[1],d=arguments.length==3?arguments[2]:{};if(typeof b=="string")if(b.indexOf(".")!=-1){var i=[];j(v(b),function(){i.push(new q(this,
r(c),r(d)))});return new f(i)}else{var h=document.getElementById(b);return new q(h!==null?h:b,c,d)}else if(b)return new q(b,c,d)}return null};l(window.$f,{fireEvent:function(){var a=[].slice.call(arguments),b=$f(a[0]);return b?b._fireEvent(a.slice(1)):null},addPlugin:function(a,b){q.prototype[a]=b;return $f},each:j,extend:l});if(typeof jQuery=="function")jQuery.prototype.flowplayer=function(a,b){if(!arguments.length||typeof arguments[0]=="number"){var c=[];this.each(function(){var a=$f(this);a&&c.push(a)});
return arguments.length?c[arguments[0]]:new f(c)}return this.each(function(){$f(this,r(a),b?r(b):{})})}})();
(function(){function r(){if(f.done)return!1;var d=document;if(d&&d.getElementsByTagName&&d.getElementById&&d.body){clearInterval(f.timer);f.timer=null;for(d=0;d<f.ready.length;d++)f.ready[d].call();f.ready=null;f.done=!0}}function j(d,c){if(c)for(key in c)c.hasOwnProperty(key)&&(d[key]=c[key]);return d}function l(d){switch(v(d)){case "string":return d=d.replace(RegExp('(["\\\\])',"g"),"\\$1"),d=d.replace(/^\s?(\d+)%/,"$1pct"),'"'+d+'"';case "array":return"["+w(d,function(a){return l(a)}).join(",")+
"]";case "function":return'"function()"';case "object":var c=[],e;for(e in d)d.hasOwnProperty(e)&&c.push('"'+e+'":'+l(d[e]));return"{"+c.join(",")+"}"}return String(d).replace(/\s/g," ").replace(/\'/g,'"')}function v(d){if(d===null||d===void 0)return!1;var c=typeof d;return c=="object"&&d.push?"array":c}function w(d,c){var e=[],a;for(a in d)d.hasOwnProperty(a)&&(e[a]=c(d[a]));return e}function o(d,c){var e=j({},d),a=document.all,b='<object width="'+e.width+'" height="'+e.height+'"';if(a&&!e.id)e.id=
"_"+(""+Math.random()).substring(9);e.id&&(b+=' id="'+e.id+'"');e.src+=(e.src.indexOf("?")!=-1?"&":"?")+Math.random();b+=e.w3c||!a?' data="'+e.src+'" type="application/x-shockwave-flash"':' classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"';b+=">";if(e.w3c||a)b+='<param name="movie" value="'+e.src+'" />';e.width=e.height=e.id=e.w3c=e.src=null;for(var g in e)e[g]!==null&&(b+='<param name="'+g+'" value="'+e[g]+'" />');e="";if(c){for(var f in c)c[f]!==null&&(e+=f+"="+(typeof c[f]=="object"?l(c[f]):
c[f])+"&");e=e.substring(0,e.length-1);b+='<param name="flashvars" value=\''+e+"' />"}b+="</object>";return b}function t(d,c,e){var a=flashembed.getVersion();j(this,{getContainer:function(){return d},getConf:function(){return c},getVersion:function(){return a},getFlashvars:function(){return e},getApi:function(){return d.firstChild},getHTML:function(){return o(c,e)}});var b=c.version,f=c.expressInstall,k=!b||flashembed.isSupported(b);if(k)c.onFail=c.version=c.expressInstall=null,d.innerHTML=o(c,e);
else if(b&&f&&flashembed.isSupported([6,65]))j(c,{src:f}),e={MMredirectURL:location.href,MMplayerType:"PlugIn",MMdoctitle:document.title},d.innerHTML=o(c,e);else if(d.innerHTML.replace(/\s/g,"")===""&&(d.innerHTML="<h2>Flash version "+b+" or greater is required</h2><h3>"+(a[0]>0?"Your version is "+a:"You have no flash plugin installed")+"</h3>"+(d.tagName=="A"?"<p>Click here to download latest version</p>":"<p>Download latest version from <a href='http://www.adobe.com/go/getflashplayer'>here</a></p>"),
d.tagName=="A"))d.onclick=function(){location.href="http://www.adobe.com/go/getflashplayer"};if(!k&&c.onFail&&(b=c.onFail.call(this),typeof b=="string"))d.innerHTML=b;document.all&&(window[c.id]=document.getElementById(c.id))}var q=typeof jQuery=="function",f=q?jQuery:function(d){if(f.done)return d();f.timer?f.ready.push(d):(f.ready=[d],f.timer=setInterval(r,13))};window.attachEvent&&window.attachEvent("onbeforeunload",function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){}});
window.flashembed=function(d,c,e){if(typeof d=="string"){var a=document.getElementById(d);if(a)d=a;else{f(function(){flashembed(d,c,e)});return}}if(d)return a={width:"100%",height:"100%",allowfullscreen:!0,allowscriptaccess:"always",quality:"high",version:null,onFail:null,expressInstall:null,w3c:!1},typeof c=="string"&&(c={src:c}),j(a,c),new t(d,a,e)};j(window.flashembed,{getVersion:function(){var d=[0,0];if(navigator.plugins&&typeof navigator.plugins["Shockwave Flash"]=="object"){var c=navigator.plugins["Shockwave Flash"].description;
typeof c!="undefined"&&(c=c.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),d=parseInt(c.replace(/^(.*)\..*$/,"$1"),10),c=/r/.test(c)?parseInt(c.replace(/^.*r(.*)$/,"$1"),10):0,d=[d,c])}else if(window.ActiveXObject){try{c=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7")}catch(e){try{c=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"),d=[6,0],c.AllowScriptAccess="always"}catch(a){if(d[0]==6)return}try{c=new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}catch(b){}}typeof c=="object"&&(c=c.GetVariable("$version"),
typeof c!="undefined"&&(c=c.replace(/^\S+\s+(.*)$/,"$1").split(","),d=[parseInt(c[0],10),parseInt(c[2],10)]))}return d},isSupported:function(d){var c=flashembed.getVersion();return c[0]>d[0]||c[0]==d[0]&&c[1]>=d[1]},domReady:f,asString:l,getHTML:o});if(q)jQuery.tools=jQuery.tools||{version:{}},jQuery.tools.version.flashembed="1.0.2",jQuery.fn.flashembed=function(d,c){var e=null;this.each(function(){e=flashembed(this,d,c)});return d.api===!1?this:e}})();

