document.getElementById("XPLSS_Trans"); if (trans_div == null) return; trans_div.style.visibility = "visible"; trans_div.onmouseout = function(){ avglsflyover.hide(event); }; avglsflyover.poppedUp = false; } }, show: function () { var div = document.getElementById("XPLSS_Flyover"); if (div == null) return; div.style.visibility = "visible"; var trans_div = document.getElementById("XPLSS_Trans"); if (trans_div == null) return; trans_div.style.visible = "visible"; }};var avglsinlineflyover = { build: function (riskCategory, riskName, bgColor, borderColor) { var html = ''; html += ''; html += ''; html += riskCategory + ''; html += riskName + ''; html += ''; return html; }, popup: function (event, flyover, nSeverity, blUrl) { //set verdict info var div = document.getElementById('XPLSS_InlineFlyover'); if (div == null) return; // blUrl is an object for a blacklisted short url // when it is passed get the final url if (blUrl != undefined) { var finalUrl = searchshield.avgCallFunc(document, 'GetFinalUrl', blUrl.sUrl); var riskUrl = blUrl.sUrl; if ((finalUrl) && (searchshield.FilterUrl(finalUrl, xplSearch.engine.shortened_urls))) finalUrl = avglsinlineflyover.getUrlFromQueryString(finalUrl); var riskName = blUrl.riskNameLabel + finalUrl; flyover = avglsinlineflyover.build(blUrl.riskCategory, riskName, blUrl.bgColor, blUrl.borderColor); } div.innerHTML = flyover; div.style.width = "auto"; //reset width div.style.position = "absolute"; if (searchshield.quirksMode || searchshield.docMode <= 7) { var className = xplSearch.engine.inline.color.classname[nSeverity]; var imgBase = "linkscanner://" + className + "_inline_border_"; var divWidth = searchshield.elementSize(div)[0]; //round up to nearest 10 to avoid intentional wrapping in div var flyoverWidth = divWidth + (10 - Math.ceil(10*((divWidth/10) - Math.floor(divWidth/10)))); var ilfoDivs = div.getElementsByTagName("div"); if (ilfoDivs && ilfoDivs.length == 5) { //div.style.fontSize = "10px"; div.style.backgroundImage = "url(" + imgBase + "tl.png)"; div.style.backgroundPosition = "0 0"; div.style.backgroundRepeat = "no-repeat"; div.style.width = flyoverWidth + "px"; div.style.zIndex = "9999"; // avgILFO_head ilfoDivs[0].style.backgroundImage = "url(" + imgBase + "tr.png)"; ilfoDivs[0].style.backgroundPosition = "top right"; ilfoDivs[0].style.backgroundRepeat = "no-repeat"; ilfoDivs[0].style.width = flyoverWidth + "px"; ilfoDivs[0].style.height = "5px"; // avgILFO_head div ilfoDivs[1].style.height = "5px"; // avgILFO_content ilfoDivs[2].style.backgroundImage = "url(" + imgBase + "r.png)"; ilfoDivs[2].style.backgroundPosition = "top right"; ilfoDivs[2].style.backgroundRepeat = "repeat-y"; ilfoDivs[2].style.fontSize = "10px"; ilfoDivs[2].style.color = "black"; ilfoDivs[2].style.padding = "0px 10px"; ilfoDivs[2].style.textAlign = "left"; ilfoDivs[2].style.wordWrap = "break-word"; ilfoDivs[2].style.lineHeight = "130%"; // avgILFO_foot ilfoDivs[3].style.backgroundImage = "url(" + imgBase + "bl.png)"; ilfoDivs[3].style.backgroundPosition = "bottom left"; ilfoDivs[3].style.backgroundRepeat = "no-repeat"; ilfoDivs[3].style.height = "5px"; // avgILFO_foot div ilfoDivs[4].style.backgroundImage = "url(" + imgBase + "br.png)"; ilfoDivs[4].style.backgroundPosition = "bottom right"; ilfoDivs[4].style.backgroundRepeat = "no-repeat"; ilfoDivs[4].style.width = flyoverWidth + "px"; ilfoDivs[4].style.height = "5px"; } else { div.style.fontSize = "10px"; div.style.backgroundColor = xplSearch.engine.inline.color.background[nSeverity]; div.style.border = xplSearch.engine.inline.color.border[nSeverity] + " solid 3px"; div.style.padding = "3px 8px"; } } else { // apply updated styles for new flyover content var sheets = document.styleSheets; for (var i=0; i < sheets.length; i++) { if (sheets[i].id && sheets[i].id == "avgILFOStyle") { var avgILFOStyle = sheets[i]; break; } } if (typeof(avgILFOStyle) !== "undefined") { var className = xplSearch.engine.inline.color.classname[nSeverity]; var divWidth = searchshield.elementSize(div)[0]; //round up to nearest 10 to avoid intentional wrapping in div var flyoverWidth = divWidth + (10 - Math.ceil(10*((divWidth/10) - Math.floor(divWidth/10)))); var rules = avgILFOStyle.rules; for (var i=0; i < rules.length; i++) { var bgImg = rules[i].style.backgroundImage; var selText = rules[i].selectorText.toLowerCase(); if (bgImg) { var bgImgStyle = bgImg.replace(/default/, className); rules[i].style.backgroundImage = bgImgStyle; } if (((selText == ".avgilfo") || (selText == ".avgilfo_head") || (selText == ".avgilfo_foot div")) && (rules[i].style.width) && (rules[i].style.width == "0px")) { rules[i].style.width = (flyoverWidth) + "px"; } } } } if