document.observe('q:loaded',function(){Q.set({image_path:"/images/q"});Informer=new Q.Informer();setupPairFinder(gRunMode);new Q.Tooltip({delay:0.1,style:'notice'});});function setupPairFinder(r)
{var docHeight=document.viewport.getHeight();var numToShow=15;if(docHeight>800)
{numToShow=20;}
var useURL="/cgi-perl/cass/pair_finder.mpl?r="+r;var dParts=document.domain.split('.');pairFinder=$j('#pairfinder').dataTable({"bProcessing":true,"bServerSide":true,"bStateSave":true,"bFilter":false,"bLengthChange":true,"iDisplayLength":numToShow,"aLengthMenu":[10,15,20,30,40,50],"aaSorting":[[12,'desc']],"sCookiePrefix":"cass_datatable_","sCookieDomain":dParts[dParts.length-2]+"."+dParts[dParts.length-1],"aoColumnDefs":[{"bSortable":false,"aTargets":[4,9,13]}],"sPaginationType":"full_numbers","sAjaxSource":useURL});setTimeout("pendURL.push('/cgi-perl/cass/pair_finder.mpl?rm=checkin');",1000);}
function makeTopDropDown(anchorDivID,onOff)
{var menuID='swarmDropContent'+anchorDivID;if(onOff)
{var divx=findPosX($(anchorDivID));var divy=findPosY($(anchorDivID));var woffset=-1;var hoffset=27;var ie7=(document.all&&!window.opera&&window.XMLHttpRequest);if(ie7)
{woffset=woffset-40;}
var xoffset=divx+woffset;var yoffset=divy+hoffset;$(menuID).style.position="absolute";$(menuID).style.top=yoffset+'px';$(menuID).style.left=xoffset+'px';clearTimeout(gMenuTimeoutID[menuID]);turnOffMenuOtherThanThis(menuID);gDropDownMenuOn[menuID]=1;$(menuID).style.zIndex=99999;$(menuID).style.display='block';}
else
{var timeoutId=setTimeout("turnOffThisMenu('"+menuID+"')",1000);gMenuTimeoutID[menuID]=timeoutId;}}
function turnOffThisMenu(menuID)
{gDropDownMenuOn[menuID]=0;$(menuID).style.display='none';}
function turnOffMenuOtherThanThis(menuID)
{for(var k in gDropDownMenuOn)
{if(gDropDownMenuOn[k]==1)
{if(k!==menuID)
{$(k).style.display='none';}}}}
