/*! Woodman - v1.1.0 - 2014-01-28 Copyright 2014 Joshfire; MIT license https://github.com/joshfire/woodman Based on Apache Log4j 2 Copyright © 1999-2013 Apache Software Foundation. All Rights Reserved. Apache License, Version 2.0 http://logging.apache.org/log4j/2.x/ Built with RequireJS optimizer r.js 2.1.2 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved. new BSD or MIT licensed http://github.com/jrburke/requirejs Includes Almond 0.2.3 Copyright (c) 2011-2012, The Dojo Foundation All Rights Reserved Available via the MIT or new BSD license http://github.com/jrburke/almond Includes Socket.IO.js build:0.9.11, development Copyright(c) 2011 LearnBoost MIT Licensed Portions adapted from log4javascript Copyright Tim Down Apache License, Version 2.0 http://log4javascript.org/ */ (function(root,rootRequire,rootModule){var requirejs,require,define;(function(e){function c(e,t){return f.call(e,t)}function h(e,t){var n,r,i,s,o,a,f,l,c,h,p=t&&t.split("/"),d=u.map,v=d&&d["*"]||{};if(e&&e.charAt(0)===".")if(t){p=p.slice(0,p.length-1),e=p.concat(e.split("/"));for(l=0;l0&&(e.splice(l-1,2),l-=2)}}e=e.join("/")}else e.indexOf("./")===0&&(e=e.substring(2));if((p||v)&&d){n=e.split("/");for(l=n.length;l>0;l-=1){r=n.slice(0,l).join("/");if(p)for(c=p.length;c>0;c-=1){i=d[p.slice(0,c).join("/")];if(i){i=i[r];if(i){s=i,o=l;break}}}if(s)break;!a&&v&&v[r]&&(a=v[r],f=l)}!s&&a&&(s=a,o=f),s&&(n.splice(0,o,s),e=n.join("/"))}return e}function p(t,r){return function(){return n.apply(e,l.call(arguments,0).concat([t,r]))}}function d(e){return function(t){return h(t,e)}}function v(e){return function(t){s[e]=t}}function m(n){if(c(o,n)){var r=o[n];delete o[n],a[n]=!0,t.apply(e,r)}if(!c(s,n)&&!c(a,n))throw new Error("No "+n);return s[n]}function g(e){var t,n=e?e.indexOf("!"):-1;return n>-1&&(t=e.substring(0,n),e=e.substring(n+1,e.length)),[t,e]}function y(e){return function(){return u&&u.config&&u.config[e]||{}}}var t,n,r,i,s={},o={},u={},a={},f=Object.prototype.hasOwnProperty,l=[].slice;r=function(e,t){var n,r=g(e),i=r[0];return e=r[1],i&&(i=h(i,t),n=m(i)),i?n&&n.normalize?e=n.normalize(e,d(t)):e=h(e,t):(e=h(e,t),r=g(e),i=r[0],e=r[1],i&&(n=m(i))),{f:i?i+"!"+e:e,n:e,pr:i,p:n}},i={require:function(e){return p(e)},exports:function(e){var t=s[e];return typeof t!="undefined"?t:s[e]={}},module:function(e){return{id:e,uri:"",exports:s[e],config:y(e)}}},t=function(t,n,u,f){var l,h,d,g,y,b=[],w;f=f||t;if(typeof u=="function"){n=!n.length&&u.length?["require","exports","module"]:n;for(y=0;y0&&t.isString(e[0])&&e[0].indexOf("{}")!==-1?(this.formatString=e[0],this.params=e.slice(1)):this.params=e};return r.prototype.getFormattedMessage=function(e){e=e||{},e.separator=t.isString(e.separator)?e.separator:" ";var n=this.getFormattedParams(e);return n.join(e.separator)},r.prototype.getFormattedParams=function(e){e=e||{},e.separator=t.isString(e.separator)?e.separator:" ",e.compactObjects=e.compactObjects||!1,e.objectDepth=e.objectDepth||2;var n=0,r=0,i=this.params.length,s="",o=[],u={compactObjects:e.compactObjects,objectDepth:e.objectDepth},a=0,f=this.formatString.indexOf("{}");while(f!==-1)s+=this.formatString.substring(a,f),n=this.maxPendingEvents&&(n=Math.floor(this.maxPendingEvents/10),this.discardedPendingEvents+=n,this.pendingEvents.splice(0,n)),this.pendingEvents.push({evt:e,logger:t})},f.prototype.tracePendingEvents=function(){var e=0,t=null,r=null;this.discardedPendingEvents>0&&this.rootLogger.traceLogEvent(new n(this.rootLogger.name,"warn",new i("Too many messages received before loading was over. "+this.discardedPendingEvents+" messages were discarded."+" To avoid losing messages, consider waiting for Woodman to load"+" before you start logging messages.")),"accept");for(e=0;e1?r=new u(n):n.length===1&&(r=n[0]),r):null},f.prototype.initialize=function(e,t){t=t||function(e){if(e)throw e};var n=!1,r=null;e&&o.isString(e)&&e.match(/^console(\s|$)/i)?(n=!!(typeof global!="undefined"&&global.process&&global.process.versions&&global.process.versions.node),e={loggers:[{level:"all",appenders:[{type:"Console",name:"console",layout:{type:"pattern",pattern:e.substring("console ".length)||(n?"%d{yyyy-MM-dd HH:mm:ss} [%logger] %level - %m%n":"%d{yyyy-MM-dd HH:mm:ss} [%logger] %m%n")},appendStrings:n}]}]}):e=JSON.parse(JSON.stringify(e||{}));var i=[],s=[],u={};return this.reset(),o.isArray(e)?i=e:(e.configuration&&(e=e.configuration),e.properties&&(e.properties.property?o.isArray(e.properties.property)?o.each(e.properties.property,function(e){e.name==="maxPendingEvents"&&(this.maxPendingEvents=e.value)}):e.properties.property.name==="maxPendingEvents"&&(this.maxPendingEvents=e.properties.property.value):e.properties.maxPendingEvents&&(this.maxPendingEvents=e.properties.maxPendingEvents)),o.isArray(e.loggers)?i=e.loggers:(i=[],i=o.each(e.loggers,function(e,t){t==="root"&&(e.root=!0),o.isArray(e)?o.each(e,function(e){i.push(e)}):i.push(e)})),o.isArray(e.appenders)?s=e.appenders:o.each(e.appenders,function(e,t){o.isArray(e)?(o.each(e,function(e){e.type||(e.type=t)}),s=s.concat(e)):(e.type||(e.type=t),s.push(e))})),o.each(i,function(e){var t=[];e["appender-ref"]&&(o.isArray(e["appender-ref"])?t=o.map(e["appender-ref"],function(e){return e.ref}):t.push(e["appender-ref"].ref),delete e["appender-ref"]),o.isArray(e.appenders)&&o.each(e.appenders,function(e){o.isObject(e)?(s.push(e),t.push(e.name)):t.push(e)}),e.appenders=t}),this.filter=this.createFilter(e.filters),o.each(s,function(e){var t=this.appenders[e.type],n=null,i=null,s=null;if(r)return;if(!t){r=new a('Unknown appender type for "'+e.name+'": '+e.type);return}if(u[e.name]){r=new a('Appender "'+e.name+'" referenced twice in the configuration');return}e.layout?(n=e.layout,i=this.layouts[n.type]):o.each(this.layouts,function(t,r){e[r]&&(n=e[r],i=t)});if(!i){r=new a('No proper layout defined for appender "'+e.name+'"');return}e.layout=new i(n,this),e.filters?e.filter=this.createFilter(e.filters):e.filter&&(e.filter=this.createFilter([e.filter]));var f=this;e.isLogLevelBelow=function(e,t){return f.logLevel.isBelow(e,t)},s=new t(e),this.createdAppenders.push(s),u[e.name]=s},this),r?t(r):(o.each(i,function(e){var t=null;if(r)return;e.appenders=o.map(e.appenders,function(t){var n=u[t];if(!n){r=new a('Logger "'+e.name+'" references undefined appender "'+t+'"');return}return u[t]}),e.filters?e.filter=this.createFilter(e.filters):e.filter&&(e.filter=this.createFilter(e.filter)),e.root||!e.name?t=this.getLogger():t=this.getLogger(e.name),t.initialize(e)},this),r?t(r):(this.propagateLevels(),this.propagateTraceFunctions(),t()))},f.prototype.getLogger=function(e){var t=null,n="",r=0;return e?(t=this.loggers[e],t?t:(t=new s(e,this),r=e.lastIndexOf("."),r!==-1?n=this.getLogger(e.substring(0,r)):n=this.rootLogger,t.parent=n,t.level=n.level,t.filter=n.filter,n.children=n.children||[],n.children.push(t),this.loggers[e]=t,t)):this.rootLogger},f.prototype.getStartTime=function(){return this.startTime.getTime()},f.prototype.reset=function(){var e="";for(e in this.loggers)this.loggers[e].reset();this.rootLogger.reset(),this.rootLogger.level="all",this.createdAppenders=[],this.started=!1},f.prototype.propagateLevels=function(){this.rootLogger.level==="inherit"&&(this.rootLogger.level="all"),o.each(this.loggers,function(e){var t=e;while(t.level==="inherit")t=t.parent;e.level=t.level,e.filter||(e.filter=t.filter)})},f.prototype.propagateTraceFunctions=function(){o.each(this.logLevel.getLevels(),function(e){var t=this.rootLogger;t[e]||(t[e]=function(){t.traceAtLevel(e,arguments)})},this),o.each(this.loggers,function(e){o.each(this.logLevel.getLevels(),function(t){e[t]||(e[t]=function(){e.traceAtLevel(t,arguments)})})},this)},f.prototype.start=function(e){e=e||function(e){if(e)throw e};var t=this,n=this.createdAppenders.length,r=!1,i=function(i){if(r)return;if(i)return r=!0,e(i);n-=1;if(n===0)return t.started=!0,t.tracePendingEvents(),e()};if(!(n>0))return this.started=!0,this.pendingEvents=[],e();o.each(this.createdAppenders,function(e){e.start(function(e){return i(e)})})},f.prototype.stop=function(e){e=e||function(e){if(e)throw e};var t=this,n=this.createdAppenders.length,r=!1,i=function(i){if(r)return;if(i)return r=!0,e(i);n-=1;if(n===0)return t.started=!1,e()};if(!(n>0))return this.started=!1,e();o.each(this.createdAppenders,function(e){e.stop(function(e){return i(e)})})},f.prototype.load=function(e,t){var n=this;t=t||function(e){if(e)throw e},this.initialize(e,function(e){if(e)return t(e);n.start(t)})},f}),define("logmanager",["require","./loggercontext","./error"],function(e){var t=e("./loggercontext"),n=e("./error"),r=new t;return{registerAppender:function(e,t){return r.registerAppender(e,t)},registerFilter:function(e,t){return r.registerFilter(e,t)},registerLayout:function(e,t){return r.registerLayout(e,t)},registerLevel:function(e,t){return r.registerLevel(e,t)},registerStandardLevels:function(e,t){return r.registerStandardLevels(e,t)},load:function(e,t){return r.load(e,t)},unload:function(e){return r.stop(e)},initialize:function(e){return r.initialize(e)},start:function(e){return r.start(e)},stop:function(e){return r.stop(e)},getLogger:function(e){return r.getLogger(e)},Error:n}}),define("appender",["require","./lifecycle","./error"],function(e){var t=e("./lifecycle"),n=e("./error"),r=function(e){e=e||{},t.call(this),this.name=e.name,this.layout=e.layout,this.filter=e.filter,this.level=e.level||"all",this.isBelow=e.isLogLevelBelow||function(){return!0}};return r.prototype=new t,r.prototype.getName=function(){return this.name},r.prototype.append=function(e){if(!this.isStarted())throw new n('Appender "'+this.name+'" '+"must be started before it may be used");var t="neutral";this.filter&&(t=this.filter.filter(e)),t==="neutral"&&(this.isBelow(e.getLevel(),this.level)?t="accept":t="deny");if(t!=="accept")return;this.doAppend(e)},r.prototype.doAppend=function(){},r.prototype.getLayout=function(){return this.layout},r}),define("appenders/consoleappender",["require","../appender"],function(e){var t=e("../appender"),n=function(e){e=e||{},t.call(this,e),this.appendStrings=typeof e.appendStrings!="undefined"?e.appendStrings:!0};return n.prototype=new t,n.prototype.doAppend=function(e){var t=this.getLayout(),n=e.getLevel(),r=null,i=null;this.appendStrings?(r=t.toMessageString(e),r&&r.lastIndexOf("\n")===r.length-1&&(r=r.substring(0,r.length-1)),this.doAppendMessages(n,[r])):(r=t.toMessageBits(e,{preserveObjects:!0}),r&&(i=r[r.length-1],i&&i.lastIndexOf("\n")===i.length-1&&(r[r.length-1]=i.substring(0,i.length-1))),this.doAppendMessages(n,r))},n.prototype.doAppendMessages=function(e,t){if(typeof console=="undefined")return;e==="info"?console.info.apply(console,t):e==="warn"?console.warn.apply(console,t):e==="error"?console.error.apply(console,t):console.log.apply(console,t)},n});var io="undefined"==typeof module?{}:module.exports;(function(){(function(e,t){var n=e;n.version="0.9.11",n.protocol=1,n.transports=[],n.j=[],n.sockets={},n.connect=function(e,r){var i=n.util.parseUri(e),s,o;t&&t.location&&(i.protocol=i.protocol||t.location.protocol.slice(0,-1),i.host=i.host||(t.document?t.document.domain:t.location.hostname),i.port=i.port||t.location.port),s=n.util.uniqueUri(i);var u={host:i.host,secure:"https"==i.protocol,port:i.port||("https"==i.protocol?443:80),query:i.query||""};n.util.merge(u,r);if(u["force new connection"]||!n.sockets[s])o=new n.Socket(u);return!u["force new connection"]&&o&&(n.sockets[s]=o),o=o||n.sockets[s],o.of(i.path.length>1?i.path:"")}})("object"==typeof module?module.exports:io={},this),function(e,t){var n=e.util={},r=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,i=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];n.parseUri=function(e){var t=r.exec(e||""),n={},s=14;while(s--)n[i[s]]=t[s]||"";return n},n.uniqueUri=function(e){var n=e.protocol,r=e.host,i=e.port;return"document"in t?(r=r||document.domain,i=i||(n=="https"&&document.location.protocol!=="https:"?443:document.location.port)):(r=r||"localhost",!i&&n=="https"&&(i=443)),(n||"http")+"://"+r+":"+(i||80)},n.query=function(e,t){var r=n.chunkQuery(e||""),i=[];n.merge(r,n.chunkQuery(t||""));for(var s in r)r.hasOwnProperty(s)&&i.push(s+"="+r[s]);return i.length?"?"+i.join("&"):""},n.chunkQuery=function(e){var t={},n=e.split("&"),r=0,i=n.length,s;for(;rt.length?e:t,s=e.length>t.length?t:e;for(var o=0,u=s.length;o0&&e.splice(0,1)[0]!=n.transport.name);e.length?u(e):n.publish("connect_failed")}}},n.options["connect timeout"]))})}n.sessionid=r,n.closeTimeout=s*1e3,n.heartbeatTimeout=i*1e3,n.transports||(n.transports=n.origTransports=o?t.util.intersect(o.split(","),n.options.transports):n.options.transports),n.setHeartbeatTimeout(),u(n.transports),n.once("connect",function(){clearTimeout(n.connectTimeoutTimer),e&&typeof e=="function"&&e()})}),this},r.prototype.setHeartbeatTimeout=function(){clearTimeout(this.heartbeatTimeoutTimer);if(this.transport&&!this.transport.heartbeats())return;var e=this;this.heartbeatTimeoutTimer=setTimeout(function(){e.transport.onClose()},this.heartbeatTimeout)},r.prototype.packet=function(e){return this.connected&&!this.doBuffer?this.transport.packet(e):this.buffer.push(e),this},r.prototype.setBuffer=function(e){this.doBuffer=e,!e&&this.connected&&this.buffer.length&&(this.options.manualFlush||this.flushBuffer())},r.prototype.flushBuffer=function(){this.transport.payload(this.buffer),this.buffer=[]},r.prototype.disconnect=function(){if(this.connected||this.connecting)this.open&&this.of("").packet({type:"disconnect"}),this.onDisconnect("booted");return this},r.prototype.disconnectSync=function(){var e=t.util.request(),n=["http"+(this.options.secure?"s":"")+":/",this.options.host+":"+this.options.port,this.options.resource,t.protocol,"",this.sessionid].join("/")+"/?disconnect=1";e.open("GET",n,!1),e.send(null),this.onDisconnect("booted")},r.prototype.isXDomain=function(){var e=n.location.port||("https:"==n.location.protocol?443:80);return this.options.host!==n.location.hostname||this.options.port!=e},r.prototype.onConnect=function(){this.connected||(this.connected=!0,this.connecting=!1,this.doBuffer||this.setBuffer(!1),this.emit("connect"))},r.prototype.onOpen=function(){this.open=!0},r.prototype.onClose=function(){this.open=!1,clearTimeout(this.heartbeatTimeoutTimer)},r.prototype.onPacket=function(e){this.of(e.endpoint).onPacket(e)},r.prototype.onError=function(e){e&&e.advice&&e.advice==="reconnect"&&(this.connected||this.connecting)&&(this.disconnect(),this.options.reconnect&&this.reconnect()),this.publish("error",e&&e.reason?e.reason:e)},r.prototype.onDisconnect=function(e){var t=this.connected,n=this.connecting;this.connected=!1,this.connecting=!1,this.open=!1;if(t||n)this.transport.close(),this.transport.clearTimeouts(),t&&(this.publish("disconnect",e),"booted"!=e&&this.options.reconnect&&!this.reconnecting&&this.reconnect())},r.prototype.reconnect=function(){function i(){if(e.connected){for(var t in e.namespaces)e.namespaces.hasOwnProperty(t)&&""!==t&&e.namespaces[t].packet({type:"connect"});e.publish("reconnect",e.transport.name,e.reconnectionAttempts)}clearTimeout(e.reconnectionTimer),e.removeListener("connect_failed",s),e.removeListener("connect",s),e.reconnecting=!1,delete e.reconnectionAttempts,delete e.reconnectionDelay,delete e.reconnectionTimer,delete e.redoTransports,e.options["try multiple transports"]=n}function s(){if(!e.reconnecting)return;if(e.connected)return i();if(e.connecting&&e.reconnecting)return e.reconnectionTimer=setTimeout(s,1e3);e.reconnectionAttempts++>=t?e.redoTransports?(e.publish("reconnect_failed"),i()):(e.on("connect_failed",s),e.options["try multiple transports"]=!0,e.transports=e.origTransports,e.transport=e.getTransport(),e.redoTransports=!0,e.connect()):(e.reconnectionDelay=10:!1},n.xdomainCheck=function(){return!0},typeof window!="undefined"&&(WEB_SOCKET_DISABLE_AUTO_INITIALIZATION=!0),t.transports.push("flashsocket")}("undefined"!=typeof io?io.Transport:module.exports,"undefined"!=typeof io?io:module.parent.exports);if("undefined"!=typeof window)var swfobject=function(){function C(){if(b)return;try{var e=a.getElementsByTagName("body")[0].appendChild(U("span"));e.parentNode.removeChild(e)}catch(t){return}b=!0;var n=c.length;for(var r=0;r0)for(var n=0;n0){var o=R(r);if(o)if(W(h[n].swfVersion)&&!(T.wk&&T.wk<312))V(r,!0),i&&(s.success=!0,s.ref=_(r),i(s));else if(h[n].expressInstall&&D()){var u={};u.data=h[n].expressInstall,u.width=o.getAttribute("width")||"0",u.height=o.getAttribute("height")||"0",o.getAttribute("class")&&(u.styleclass=o.getAttribute("class")),o.getAttribute("align")&&(u.align=o.getAttribute("align"));var a={},f=o.getElementsByTagName("param"),l=f.length;for(var c=0;c');u.outerHTML='"+l+"",p[p.length]=n.id,o=R(n.id)}else{var h=U(t);h.setAttribute("type",i);for(var d in n)n[d]!=Object.prototype[d]&&(d.toLowerCase()=="styleclass"?h.setAttribute("class",n[d]):d.toLowerCase()!="classid"&&h.setAttribute(d,n[d]));for(var v in r)r[v]!=Object.prototype[v]&&v.toLowerCase()!="movie"&&F(h,v,r[v]);u.parentNode.replaceChild(h,u),o=h}}return o}function F(e,t,n){var r=U("param");r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)}function I(e){var t=R(e);t&&t.nodeName=="OBJECT"&&(T.ie&&T.win?(t.style.display="none",function(){t.readyState==4?q(e):setTimeout(arguments.callee,10)}()):t.parentNode.removeChild(t))}function q(e){var t=R(e);if(t){for(var n in t)typeof t[n]=="function"&&(t[n]=null);t.parentNode.removeChild(t)}}function R(e){var t=null;try{t=a.getElementById(e)}catch(n){}return t}function U(e){return a.createElement(e)}function z(e,t,n){e.attachEvent(t,n),d[d.length]=[e,t,n]}function W(e){var t=T.pv,n=e.split(".");return n[0]=parseInt(n[0],10),n[1]=parseInt(n[1],10)||0,n[2]=parseInt(n[2],10)||0,t[0]>n[0]||t[0]==n[0]&&t[1]>n[1]||t[0]==n[0]&&t[1]==n[1]&&t[2]>=n[2]?!0:!1}function X(n,r,i,s){if(T.ie&&T.mac)return;var o=a.getElementsByTagName("head")[0];if(!o)return;var u=i&&typeof i=="string"?i:"screen";s&&(E=null,S=null);if(!E||S!=u){var f=U("style");f.setAttribute("type","text/css"),f.setAttribute("media",u),E=o.appendChild(f),T.ie&&T.win&&typeof a.styleSheets!=e&&a.styleSheets.length>0&&(E=a.styleSheets[a.styleSheets.length-1]),S=u}T.ie&&T.win?E&&typeof E.addRule==t&&E.addRule(n,r):E&&typeof a.createTextNode!=e&&E.appendChild(a.createTextNode(n+" {"+r+"}"))}function V(e,t){if(!x)return;var n=t?"visible":"hidden";b&&R(e)?R(e).style.visibility=n:X("#"+e,"visibility:"+n)}function $(t){var n=/[\\\"<>\.;]/,r=n.exec(t)!=null;return r&&typeof encodeURIComponent!=e?encodeURIComponent(t):t}var e="undefined",t="object",n="Shockwave Flash",r="ShockwaveFlash.ShockwaveFlash",i="application/x-shockwave-flash",s="SWFObjectExprInst",o="onreadystatechange",u=window,a=document,f=navigator,l=!1,c=[A],h=[],p=[],d=[],v,m,g,y,b=!1,w=!1,E,S,x=!0,T=function(){var s=typeof a.getElementById!=e&&typeof a.getElementsByTagName!=e&&typeof a.createElement!=e,o=f.userAgent.toLowerCase(),c=f.platform.toLowerCase(),h=c?/win/.test(c):/win/.test(o),p=c?/mac/.test(c):/mac/.test(o),d=/webkit/.test(o)?parseFloat(o.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):!1,v=!1,m=[0,0,0],g=null;if(typeof f.plugins!=e&&typeof f.plugins[n]==t)g=f.plugins[n].description,g&&(typeof f.mimeTypes==e||!f.mimeTypes[i]||!!f.mimeTypes[i].enabledPlugin)&&(l=!0,v=!1,g=g.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),m[0]=parseInt(g.replace(/^(.*)\..*$/,"$1"),10),m[1]=parseInt(g.replace(/^.*\.(.*)\s.*$/,"$1"),10),m[2]=/[a-zA-Z]/.test(g)?parseInt(g.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0);else if(typeof u[["Active"].concat("Object").join("X")]!=e)try{var y=new(window[["Active"].concat("Object").join("X")])(r);y&&(g=y.GetVariable("$version"),g&&(v=!0,g=g.split(" ")[1].split(","),m=[parseInt(g[0],10),parseInt(g[1],10),parseInt(g[2],10)]))}catch(b){}return{w3:s,pv:m,wk:d,ie:v,win:h,mac:p}}(),N=function(){if(!T.w3)return;(typeof a.readyState!=e&&a.readyState=="complete"||typeof a.readyState==e&&(a.getElementsByTagName("body")[0]||a.body))&&C(),b||(typeof a.addEventListener!=e&&a.addEventListener("DOMContentLoaded",C,!1),T.ie&&T.win&&(a.attachEvent(o,function(){a.readyState=="complete"&&(a.detachEvent(o,arguments.callee),C())}),u==top&&function(){if(b)return;try{a.documentElement.doScroll("left")}catch(e){setTimeout(arguments.callee,0);return}C()}()),T.wk&&function(){if(b)return;if(!/loaded|complete/.test(a.readyState)){setTimeout(arguments.callee,0);return}C()}(),L(C))}(),J=function(){T.ie&&T.win&&window.attachEvent("onunload",function(){var e=d.length;for(var t=0;t= 10.0.0 is required.");return}location.protocol=="file:"&&e.error("WARNING: web-socket-js doesn't work in file:///... URL unless you set Flash Security Settings properly. Open the page via Web server i.e. http://..."),WebSocket=function(e,t,n,r,i){var s=this;s.__id=WebSocket.__nextId++,WebSocket.__instances[s.__id]=s,s.readyState=WebSocket.CONNECTING,s.bufferedAmount=0,s.__events={},t?typeof t=="string"&&(t=[t]):t=[],setTimeout(function(){WebSocket.__addTask(function(){WebSocket.__flash.create(s.__id,e,t,n||null,r||0,i||null)})},0)},WebSocket.prototype.send=function(e){if(this.readyState==WebSocket.CONNECTING)throw"INVALID_STATE_ERR: Web Socket connection has not been established";var t=WebSocket.__flash.send(this.__id,encodeURIComponent(e));return t<0?!0:(this.bufferedAmount+=t,!1)},WebSocket.prototype.close=function(){if(this.readyState==WebSocket.CLOSED||this.readyState==WebSocket.CLOSING)return;this.readyState=WebSocket.CLOSING,WebSocket.__flash.close(this.__id)},WebSocket.prototype.addEventListener=function(e,t,n){e in this.__events||(this.__events[e]=[]),this.__events[e].push(t)},WebSocket.prototype.removeEventListener=function(e,t,n){if(!(e in this.__events))return;var r=this.__events[e];for(var i=r.length-1;i>=0;--i)if(r[i]===t){r.splice(i,1);break}},WebSocket.prototype.dispatchEvent=function(e){var t=this.__events[e.type]||[];for(var n=0;n"),this.doc.close(),this.doc.parentWindow.s=this;var e=this.doc.createElement("div");e.className="socketio",this.doc.body.appendChild(e),this.iframe=this.doc.createElement("iframe"),e.appendChild(this.iframe);var n=this,r=t.util.query(this.socket.options.query,"t="+ +(new Date));this.iframe.src=this.prepareUrl()+r,t.util.on(window,"unload",function(){n.destroy()})},n.prototype._=function(e,t){this.onData(e);try{var n=t.getElementsByTagName("script")[0];n.parentNode.removeChild(n)}catch(r){}},n.prototype.destroy=function(){if(this.iframe){try{this.iframe.src="about:blank"}catch(e){}this.doc=null,this.iframe.parentNode.removeChild(this.iframe),this.iframe=null,CollectGarbage()}},n.prototype.close=function(){return this.destroy(),t.Transport.XHR.prototype.close.call(this)},n.check=function(e){if(typeof window!="undefined"&&["Active"].concat("Object").join("X")in window)try{var n=new(window[["Active"].concat("Object").join("X")])("htmlfile");return n&&t.Transport.XHR.check(e)}catch(r){}return!1},n.xdomainCheck=function(){return!1},t.transports.push("htmlfile")}("undefined"!=typeof io?io.Transport:module.exports,"undefined"!=typeof io?io:module.parent.exports),function(e,t,n){function r(){t.Transport.XHR.apply(this,arguments)}function i(){}e["xhr-polling"]=r,t.util.inherit(r,t.Transport.XHR),t.util.merge(r,t.Transport.XHR),r.prototype.name="xhr-polling",r.prototype.heartbeats=function(){return!1},r.prototype.open=function(){var e=this;return t.Transport.XHR.prototype.open.call(e),!1},r.prototype.get=function(){function t(){this.readyState==4&&(this.onreadystatechange=i,this.status==200?(e.onData(this.responseText),e.get()):e.onClose())}function r(){this.onload=i,this.onerror=i,e.retryCounter=1,e.onData(this.responseText),e.get()}function s(){e.retryCounter++,!e.retryCounter||e.retryCounter>3?e.onClose():e.get()}if(!this.isOpen)return;var e=this;this.xhr=this.request(),n.XDomainRequest&&this.xhr instanceof XDomainRequest?(this.xhr.onload=r,this.xhr.onerror=s):this.xhr.onreadystatechange=t,this.xhr.send(null)},r.prototype.onClose=function(){t.Transport.XHR.prototype.onClose.call(this);if(this.xhr){this.xhr.onreadystatechange=this.xhr.onload=this.xhr.onerror=i;try{this.xhr.abort()}catch(e){}this.xhr=null}},r.prototype.ready=function(e,n){var r=this;t.util.defer(function(){n.call(r)})},t.transports.push("xhr-polling")}("undefined"!=typeof io?io.Transport:module.exports,"undefined"!=typeof io?io:module.parent.exports,this),function(e,t,n){function i(e){t.Transport["xhr-polling"].apply(this,arguments),this.index=t.j.length;var n=this;t.j.push(function(e){n._(e)})}var r=n.document&&"MozAppearance"in n.document.documentElement.style;e["jsonp-polling"]=i,t.util.inherit(i,t.Transport["xhr-polling"]),i.prototype.name="jsonp-polling",i.prototype.post=function(e){function a(){f(),n.socket.setBuffer(!1)}function f(){n.iframe&&n.form.removeChild(n.iframe);try{u=document.createElement('