segunda-feira, 17 de setembro de 2012

Jogaaa

|<!\\w[^>]*>|<\\?[^>*]*>|<(/)?([a-z][a-z0-9]*)|([^<&>]+)|([<&>]))','i');function makeSaxParser(handler){return function parse(htmlText,param){var attribName,attribs,dataEnd,decodedValue,eflags,encodedValue,htmlLower,inTag,m,openTag,tagName;htmlText=String(htmlText),htmlLower=null,inTag=false,attribs=[],tagName=void 0,eflags=void 0,openTag=void 0,handler.startDoc&&handler.startDoc(param);while(htmlText){m=htmlText.match(inTag?INSIDE_TAG_TOKEN:OUTSIDE_TAG_TOKEN),htmlText=htmlText.substring(m[0].length);if(inTag){if(m[1]){attribName=lcase(m[1]);if(m[2]){encodedValue=m[3];switch(encodedValue.charCodeAt(0)){case 34:case 39:encodedValue=encodedValue.substring(1,encodedValue.length-1)}decodedValue=unescapeEntities(stripNULs(encodedValue))}else decodedValue=attribName;attribs.push(attribName,decodedValue)}else if(m[4])eflags!==void 0&&(openTag?handler.startTag&&handler.startTag(tagName,attribs,param):handler.endTag&&handler.endTag(tagName,param)),openTag&&eflags&(html4.eflags.CDATA|html4.eflags.RCDATA)&&(htmlLower===null?(htmlLower=lcase(htmlText)):(htmlLower=htmlLower.substring(htmlLower.length-htmlText.length)),dataEnd=htmlLower.indexOf('</'+tagName),dataEnd<0 0="0" attribs.length="0,inTag=false}else" break="break" case="case" dataend="htmlText.length),eflags&html4.eflags.CDATA?handler.cdata&&handler.cdata(htmlText.substring(0,dataEnd),param):handler.rcdata&&handler.rcdata(normalizeRCData(htmlText.substring(0,dataEnd)),param),htmlText=htmlText.substring(dataEnd)),tagName=eflags=openTag=void" else="else" handler.pcdata="handler.pcdata" if="if" lt="lt" m="m" opentag="!m[2],inTag=true,tagName=lcase(m[3]),eflags=html4.ELEMENTS.hasOwnProperty(tagName)?html4.ELEMENTS[tagName]:void" param="param" switch="switch">':handler.pcdata('>',param);break;default:handler.pcdata('&',param)}}}handler.endDoc&&handler.endDoc(param)}}return{'normalizeRCData':normalizeRCData,'escapeAttrib':escapeAttrib,'unescapeEntities':unescapeEntities,'makeSaxParser':makeSaxParser}})(),html.makeHtmlSanitizer=function(sanitizeAttributes){var ignoring,stack;return html.makeSaxParser({'startDoc':function(_){stack=[],ignoring=false},'startTag':function(tagName,attribs,out){var attribName,eflags,i,n,value;if(ignoring)return;if(!html4.ELEMENTS.hasOwnProperty(tagName))return;eflags=html4.ELEMENTS[tagName];if(eflags&html4.eflags.FOLDABLE)return;else if(eflags&html4.eflags.UNSAFE)return ignoring=!(eflags&html4.eflags.EMPTY),void 0;attribs=sanitizeAttributes(tagName,attribs);if(attribs){eflags&html4.eflags.EMPTY||stack.push(tagName),out.push('<',tagName);for(i=0,n=attribs.length;i')}},'endTag':function(tagName,out){var eflags,i,index,stackEl;if(ignoring)return ignoring=false,void 0;if(!html4.ELEMENTS.hasOwnProperty(tagName))return;eflags=html4.ELEMENTS[tagName];if(!(eflags&(html4.eflags.UNSAFE|html4.eflags.EMPTY|html4.eflags.FOLDABLE))){if(eflags&html4.eflags.OPTIONAL_ENDTAG)for(index=stack.length;--index>=0;){stackEl=stack[index];if(stackEl===tagName)break;if(!(html4.ELEMENTS[stackEl]&html4.eflags.OPTIONAL_ENDTAG))return}else for(index=stack.length;--index>=0;)if(stack[index]===tagName)break;if(index<0 for="for" i="stack.length;--i" return="return">index;)stackEl=stack[i],html4.ELEMENTS[stackEl]&html4.eflags.OPTIONAL_ENDTAG||out.push('</',stackEl,'>');stack.length=index,out.push('</',tagName,'>')}},'pcdata':function(text,out){ignoring||out.push(text)},'rcdata':function(text,out){ignoring||out.push(text)},'cdata':function(text,out){ignoring||out.push(text)},'endDoc':function(out){var i;for(i=stack.length;--i>=0;)out.push('</',stack[i],'>');stack.length=0}})};function html_sanitize(htmlText,opt_uriPolicy,opt_nmTokenPolicy){var out=[];return html.makeHtmlSanitizer(function sanitizeAttribs(tagName,attribs){var attribKey,attribName,atype,i,value;for(i=0;iMAX_NIX_SEARCHES){gadgets.warn('Nix transport setup failed, falling back...');ready('..',false);return;} if(!handler&&window.opener&&"GetAuthToken"in window.opener){handler=window.opener;if(handler.GetAuthToken()==gadgets.rpc.getAuthToken('..')){var token=gadgets.rpc.getAuthToken('..');handler.CreateChannel(window[NIX_GET_WRAPPER]('..',token),token);nix_channels['..']=handler;window.opener=null;ready('..',true);return;}} window.setTimeout(function(){conductHandlerSearch();},NIX_SEARCH_PERIOD);} function getLocationNoHash(){var loc=window.location.href;var idx=loc.indexOf('#');if(idx==-1){return loc;} return loc.substring(0,idx);} function setupSecureRelayToParent(rpctoken){var childToken=(0x7FFFFFFF*Math.random())|0;var data=[getLocationNoHash(),childToken];gadgets.rpc._createRelayIframe(rpctoken,data);var hash=window.location.href.split('#')[1]||'';function relayTimer(){var newHash=window.location.href.split('#')[1]||'';if(newHash!==hash){clearInterval(relayTimerId);var params=gadgets.util.getUrlParameters(window.location.href);if(params.childtoken==childToken){conductHandlerSearch();return;} ready('..',false);}} var relayTimerId=setInterval(relayTimer,100);} return{getCode:function(){return'nix';},isParentVerifiable:function(opt_receiverId){if(opt_receiverId){return isForceSecure[opt_receiverId];} return false;},init:function(processFn,readyFn){ready=readyFn;if(typeof window[NIX_GET_WRAPPER]!=='unknown'){window[NIX_HANDLE_MESSAGE]=function(data){window.setTimeout(function(){processFn(gadgets.json.parse(data));},0);};window[NIX_CREATE_CHANNEL]=function(name,channel,token){if(gadgets.rpc.getAuthToken(name)===token){nix_channels[name]=channel;ready(name,true);}};var vbscript='Class '+NIX_WRAPPER+'\n ' +'Private m_Intended\n' +'Private m_Auth\n' +'Public Sub SetIntendedName(name)\n ' +'If isEmpty(m_Intended) Then\n' +'m_Intended = name\n' +'End If\n' +'End Sub\n' +'Public Sub SetAuth(auth)\n ' +'If isEmpty(m_Auth) Then\n' +'m_Auth = auth\n' +'End If\n' +'End Sub\n' +'Public Sub SendMessage(data)\n ' +NIX_HANDLE_MESSAGE+'(data)\n' +'End Sub\n' +'Public Function GetAuthToken()\n ' +'GetAuthToken = m_Auth\n' +'End Function\n' +'Public Sub CreateChannel(channel, auth)\n ' +'Call '+NIX_CREATE_CHANNEL+'(m_Intended, channel, auth)\n' +'End Sub\n' +'End Class\n' +'Function '+NIX_GET_WRAPPER+'(name, auth)\n' +'Dim wrap\n' +'Set wrap = New '+NIX_WRAPPER+'\n' +'wrap.SetIntendedName name\n' +'wrap.SetAuth auth\n' +'Set '+NIX_GET_WRAPPER+' = wrap\n' +'End Function';try{window.execScript(vbscript,'vbscript');}catch(e){return false;}} return true;},setup:function(receiverId,token,forcesecure){isForceSecure[receiverId]=!!forcesecure;if(receiverId==='..'){if(forcesecure){setupSecureRelayToParent(token);}else{conductHandlerSearch();} return true;} try{var frame=document.getElementById(receiverId);var wrapper=window[NIX_GET_WRAPPER](receiverId,token);frame.contentWindow.opener=wrapper;}catch(e){return false;} return true;},call:function(targetId,from,rpc){try{if(nix_channels[targetId]){nix_channels[targetId].SendMessage(gadgets.json.stringify(rpc));}}catch(e){return false;} return true;},relayOnload:function(receiverId,data){var src=data[0]+'#childtoken='+data[1];var childIframe=document.getElementById(receiverId);childIframe.src=src;}};}();} gadgets.rpctx=gadgets.rpctx||{};if(!gadgets.rpctx.rmr){gadgets.rpctx.rmr=function(){var RMR_SEARCH_TIMEOUT=500;var RMR_MAX_POLLS=10;var rmr_channels={};var process;var ready;function appendRmrFrame(channelFrame,relayUri,data,opt_frameId){var appendFn=function(){document.body.appendChild(channelFrame);channelFrame.src='about:blank';if(opt_frameId){channelFrame.onload=function(){processRmrData(opt_frameId);};} channelFrame.src=relayUri+'#'+data;};if(document.body){appendFn();}else{gadgets.util.registerOnLoadHandler(function(){appendFn();});}} function setupRmr(frameId){if(typeof rmr_channels[frameId]==="object"){return;} var channelFrame=document.createElement('iframe');var frameStyle=channelFrame.style;frameStyle.position='absolute';frameStyle.top='0px';frameStyle.border='0';frameStyle.opacity='0';frameStyle.width='10px';frameStyle.height='1px';channelFrame.id='rmrtransport-'+frameId;channelFrame.name=channelFrame.id;var relayUri=gadgets.rpc.getRelayUrl(frameId);if(!relayUri){relayUri=gadgets.rpc.getOrigin(gadgets.util.getUrlParameters()["parent"])+'/robots.txt';} rmr_channels[frameId]={frame:channelFrame,receiveWindow:null,relayUri:relayUri,searchCounter:0,width:10,waiting:true,queue:[],sendId:0,recvId:0};if(frameId!=='..'){appendRmrFrame(channelFrame,relayUri,getRmrData(frameId));} conductRmrSearch(frameId);} function conductRmrSearch(frameId){var channelWindow=null;rmr_channels[frameId].searchCounter++;try{var targetWin=gadgets.rpc._getTargetWin(frameId);if(frameId==='..'){channelWindow=targetWin.frames['rmrtransport-'+gadgets.rpc.RPC_ID];}else{channelWindow=targetWin.frames['rmrtransport-..'];}}catch(e){} var status=false;if(channelWindow){status=registerRmrChannel(frameId,channelWindow);} if(!status){if(rmr_channels[frameId].searchCounter>RMR_MAX_POLLS){return;} window.setTimeout(function(){conductRmrSearch(frameId);},RMR_SEARCH_TIMEOUT);}} function callRmr(targetId,serviceName,from,rpc){var handler=null;if(from!=='..'){handler=rmr_channels['..'];}else{handler=rmr_channels[targetId];} if(handler){if(serviceName!==gadgets.rpc.ACK){handler.queue.push(rpc);} if(handler.waiting||(handler.queue.length===0&&!(serviceName===gadgets.rpc.ACK&&rpc&&rpc.ackAlone===true))){return true;} if(handler.queue.length>0){handler.waiting=true;} var url=handler.relayUri+"#"+getRmrData(targetId);try{handler.frame.contentWindow.location=url;var newWidth=handler.width==10?20:10;handler.frame.style.width=newWidth+'px';handler.width=newWidth;}catch(e){return false;}} return true;} function getRmrData(toFrameId){var channel=rmr_channels[toFrameId];var rmrData={id:channel.sendId};if(channel){rmrData.d=Array.prototype.slice.call(channel.queue,0);rmrData.d.push({s:gadgets.rpc.ACK,id:channel.recvId});} return gadgets.json.stringify(rmrData);} function processRmrData(fromFrameId){var channel=rmr_channels[fromFrameId];var data=channel.receiveWindow.location.hash.substring(1);var rpcObj=gadgets.json.parse(decodeURIComponent(data))||{};var rpcArray=rpcObj.d||[];var nonAckReceived=false;var noLongerWaiting=false;var numBypassed=0;var numToBypass=(channel.recvId-rpcObj.id);for(var i=0;i0)){var from=(fromFrameId==='..')?gadgets.rpc.RPC_ID:'..';callRmr(fromFrameId,gadgets.rpc.ACK,from,{ackAlone:nonAckReceived});}} function registerRmrChannel(frameId,channelWindow){var channel=rmr_channels[frameId];try{var canAccess=false;canAccess='document'in channelWindow;if(!canAccess){return false;} canAccess=typeof channelWindow['document']=='object';if(!canAccess){return false;} var loc=channelWindow.location.href;if(loc==='about:blank'){return false;}}catch(ex){return false;} channel.receiveWindow=channelWindow;function onresize(){processRmrData(frameId);};if(typeof channelWindow.attachEvent==="undefined"){channelWindow.onresize=onresize;}else{channelWindow.attachEvent("onresize",onresize);} if(frameId==='..'){appendRmrFrame(channel.frame,channel.relayUri,getRmrData(frameId),frameId);}else{processRmrData(frameId);} return true;} return{getCode:function(){return'rmr';},isParentVerifiable:function(){return true;},init:function(processFn,readyFn){process=processFn;ready=readyFn;return true;},setup:function(receiverId,token){try{setupRmr(receiverId);}catch(e){gadgets.warn('Caught exception setting up RMR: '+e);return false;} return true;},call:function(targetId,from,rpc){return callRmr(targetId,rpc.s,from,rpc);}};}();} gadgets.rpctx=gadgets.rpctx||{};if(!gadgets.rpctx.ifpc){gadgets.rpctx.ifpc=function(){var iframePool=[];var callId=0;var ready;function encodeLegacyData(args){var argsEscaped=[];for(var i=0,j=args.length;i=0;--i){var ifr=iframePool[i];try{if(ifr&&(ifr.recyclable||ifr.readyState==='complete')){ifr.parentNode.removeChild(ifr);if(window.ActiveXObject){iframePool[i]=ifr=null;iframePool.splice(i,1);}else{ifr.recyclable=false;iframe=ifr;break;}}}catch(e){}} if(!iframe){iframe=document.createElement('iframe');iframe.style.border=iframe.style.width=iframe.style.height='0px';iframe.style.visibility='hidden';iframe.style.position='absolute';iframe.onload=function(){this.recyclable=true;};iframePool.push(iframe);} iframe.src=src;window.setTimeout(function(){document.body.appendChild(iframe);},0);} return{getCode:function(){return'ifpc';},isParentVerifiable:function(){return true;},init:function(processFn,readyFn){ready=readyFn;ready('..',true);return true;},setup:function(receiverId,token){ready(receiverId,true);return true;},call:function(targetId,from,rpc){var relay=gadgets.rpc.getRelayUrl(targetId);++callId;if(!relay){gadgets.warn('No relay file assigned for IFPC');return false;} var src=null;if(rpc.l){var callArgs=rpc.a;src=[relay,'#',encodeLegacyData([from,callId,1,0,encodeLegacyData([from,rpc.s,'','',from].concat(callArgs))])].join('');}else{src=[relay,'#',targetId,'&',from,'@',callId,'&1&0&',encodeURIComponent(gadgets.json.stringify(rpc))].join('');} emitInvisibleIframe(src);return true;}};}();} if(!gadgets.rpc){gadgets.rpc=function(){var CALLBACK_NAME='__cb';var DEFAULT_NAME='';var ACK='__ack';var SETUP_FRAME_TIMEOUT=500;var SETUP_FRAME_MAX_TRIES=10;var services={};var relayUrl={};var useLegacyProtocol={};var authToken={};var callId=0;var callbacks={};var setup={};var sameDomain={};var params={};var receiverTx={};var earlyRpcQueue={};var isChild=(window.top!==window.self);var rpcId=window.name;var securityCallback=function(){};var LOAD_TIMEOUT=0;var FRAME_PHISH=1;var FORGED_MSG=2;var fallbackTransport=(function(){function logFn(name){return function(){gadgets.log("gadgets.rpc."+name+"("+ gadgets.json.stringify(Array.prototype.slice.call(arguments))+"): call ignored. [caller: "+document.location+", isChild: "+isChild+"]");};} return{getCode:function(){return"noop";},isParentVerifiable:function(){return true;},init:logFn("init"),setup:logFn("setup"),call:logFn("call")};})();if(gadgets.util){params=gadgets.util.getUrlParameters();} function getTransport(){return typeof window.postMessage==='function'?gadgets.rpctx.wpm:typeof window.postMessage==='object'?gadgets.rpctx.wpm:window.ActiveXObject?gadgets.rpctx.nix:navigator.userAgent.indexOf('WebKit')>0?gadgets.rpctx.rmr:navigator.product==='Gecko'?gadgets.rpctx.frameElement:gadgets.rpctx.ifpc;} function transportReady(receiverId,readySuccess){var tx=transport;if(!readySuccess){tx=fallbackTransport;} receiverTx[receiverId]=tx;var earlyQueue=earlyRpcQueue[receiverId]||[];for(var i=0;i4){process(gadgets.json.parse(decodeURIComponent(fragment[fragment.length-1])));}else{relayOnload.apply(null,fragment.concat(otherWindow));}},receiveSameDomain:function(rpc){rpc.a=Array.prototype.slice.call(rpc.a);window.setTimeout(function(){process(rpc);},0);},getOrigin:getOrigin,getReceiverOrigin:function(receiverId){var channel=receiverTx[receiverId];if(!channel){return null;} if(!channel.isParentVerifiable(receiverId)){return null;} var origRelay=gadgets.rpc.getRelayUrl(receiverId)||gadgets.util.getUrlParameters().parent;return gadgets.rpc.getOrigin(origRelay);},init:function(){if(transport.init(process,transportReady)===false){transport=fallbackTransport;} if(isChild){setupReceiver('..');}},_getTargetWin:getTargetWin,_createRelayIframe:function(token,data){var relay=gadgets.rpc.getRelayUrl('..');if(!relay){return null;} var src=relay+'#..&'+rpcId+'&'+token+'&'+ encodeURIComponent(gadgets.json.stringify(data));var iframe=document.createElement('iframe');iframe.style.border=iframe.style.width=iframe.style.height='0px';iframe.style.visibility='hidden';iframe.style.position='absolute';function appendFn(){document.body.appendChild(iframe);iframe.src='javascript:""';iframe.src=src;} if(document.body){appendFn();}else{gadgets.util.registerOnLoadHandler(function(){appendFn();});} return iframe;},ACK:ACK,RPC_ID:rpcId,SEC_ERROR_LOAD_TIMEOUT:LOAD_TIMEOUT,SEC_ERROR_FRAME_PHISH:FRAME_PHISH,SEC_ERROR_FORGED_MSG:FORGED_MSG};}();gadgets.rpc.init();} gadgets.rpc.register('update_security_token',function(token){shindig.auth.updateSecurityToken(token);}); gadgets.window=gadgets.window||{};(function(){var oldHeight;function parseIntFromElemPxAttribute(elem,attr){var style=window.getComputedStyle(elem,"");var value=style.getPropertyValue(attr);value.match(/^([0-9]+)/);return parseInt(RegExp.$1,10);} function getHeightForWebkit(){var result=0;var queue=[document.body];while(queue.length>0){var elem=queue.shift();var children=elem.childNodes;for(var i=0;i=0){newHeight=getHeightForWebkit();}else if(body&&docEl){var sh=docEl.scrollHeight;var oh=docEl.offsetHeight;if(docEl.clientHeight!==oh){sh=body.scrollHeight;oh=body.offsetHeight;} if(sh>vh){newHeight=sh>oh?sh:oh;}else{newHeight=sh


spacer

spacer
-->