1var thumbnailviewer = { 2 enableTitle: !0, 3 enableAnimation: !0, 4 definefooter: '<div class="footerbar">Cerrar</div>', 5 defineLoading: '<img src="/archivos/loadingAnimation.gif" /> Cargando...', 6 scrollbarwidth: 16, 7 opacitystring: "filter:progid:DXImageTransform.Microsoft.alpha(opacity=10); -moz-opacity: 0.1; opacity: 0.1", 8 targetlinks: [], 9 createthumbBox: function() { 10 document.write('<div id="thumbBox"><div id="thumbImage"></div>' + this.definefooter + "</div>"), document.write('<div id="thumbLoading">' + this.defineLoading + "</div>"), this.thumbBox = document.getElementById("thumbBox"), this.thumbImage = document.getElementById("thumbImage"), this.thumbLoading = document.getElementById("thumbLoading"), this.standardbody = document.compatMode == "CSS1Compat" ? document.documentElement : document.body; 11 }, 12 centerDiv: function(a) { 13 14 var b = document.all && !window.opera, c = document.getElementById, d = b ? this.standardbody.scrollTop : window.pageYOffset, e = b ? this.standardbody.scrollLeft : window.pageXOffset, f = b ? this.standardbody.clientWidth : window.innerWidth - this.scrollbarwidth, g = b ? this.standardbody.clientHeight : window.innerHeight, h = this.standardbody.offsetHeight > this.standardbody.scrollHeight ? this.standardbody.offsetHeight : this.standardbody.scrollHeight, i = a.offsetWidth, j = a.offsetHeight, k = g > j ? d + g / 2 - j / 2 + "px" : d + 10 + "px"; 15 a.style.left = f / 2 - i / 2 + "px", a.style.top = Math.floor(parseInt(k)) + "px", a.style.visibility = "visible"; 16 }, 17 showthumbBox: function() { 18 this.centerDiv(this.thumbBox), this.enableAnimation && (this.currentopacity = .1, this.opacitytimer = setInterval("thumbnailviewer.opacityanimation()", 20)); 19 }, 20 loadimage: function(a) { 21 this.thumbBox.style.visibility == "visible" && this.closeit(); 22 var b = '<img src="' + a.getAttribute("href") + '" style="' + this.opacitystring + '" />'; 23 this.enableTitle && a.getAttribute("title") && (b += "<br />" + a.getAttribute("title")), this.centerDiv(this.thumbLoading), this.thumbImage.innerHTML = b, this.featureImage = this.thumbImage.getElementsByTagName("img")[0], this.featureImage.onload = function() { 24 thumbnailviewer.thumbLoading.style.visibility = "hidden", thumbnailviewer.showthumbBox(); 25 }, document.all && !window.createPopup && (this.featureImage.src = a.getAttribute("href")), this.featureImage.onerror = function() { 26 thumbnailviewer.thumbLoading.style.visibility = "hidden"; 27 }; 28 setTimeout(function(){ 29 $(document.body).one('click',function(){ 30 thumbnailviewer.closeit(); 31 }); 32 },100); 33 }, 34 setimgopacity: function(a) { 35 var b = this.featureImage; 36 b.filters && b.filters[0] ? typeof b.filters[0].opacity == "number" ? b.filters[0].opacity = a * 100 : b.style.filter = "alpha(opacity=" + a * 100 + ")" : typeof b.style.MozOpacity != "undefined" ? b.style.MozOpacity = a : typeof b.style.opacity != "undefined" ? b.style.opacity = a : this.stopanimation(); 37 }, 38 opacityanimation: function() { 39 this.setimgopacity(this.currentopacity), this.currentopacity += .1, this.currentopacity > 1 && this.stopanimation(); 40 }, 41 stopanimation: function() { 42 typeof this.opacitytimer != "undefined" && clearInterval(this.opacitytimer); 43 }, 44 closeit: function() { 45 this.stopanimation(), this.thumbBox.style.visibility = "hidden", this.thumbImage.innerHTML = "", this.thumbBox.style.left = "-2000px", this.thumbBox.style.top = "-2000px"; 46 }, 47 cleanup: function() { 48 this.thumbLoading = null, this.featureImage && (this.featureImage.onload = null), this.featureImage = null, this.thumbImage = null; 49 for (var a = 0; a < this.targetlinks.length; a++) this.targetlinks[a].onclick = null; 50 this.thumbBox = null; 51 }, 52 dotask: function(a, b, c) { 53 var c = window.addEventListener ? c : "on" + c; 54 a.addEventListener ? a.addEventListener(c, b, !1) : a.attachEvent && a.attachEvent(c, b); 55 }, 56 init: function() { 57 this.enableAnimation || (this.opacitystring = ""); 58 var a = document.getElementsByTagName("a"); 59 for (var b = 0; b < a.length; b++) a[b].getAttribute("rel") && a[b].getAttribute("rel") == "thumbnail" && (a[b].onclick = function() { 60 return thumbnailviewer.stopanimation(), thumbnailviewer.loadimage(this), !1; 61 }, this.targetlinks[this.targetlinks.length] = a[b]); 62 this.dotask(window, function() { 63 thumbnailviewer.thumbBox.style.visibility == "visible" && thumbnailviewer.centerDiv(thumbnailviewer.thumbBox); 64 }, "resize"); 65 } 66}; 67 68thumbnailviewer.createthumbBox(), thumbnailviewer.dotask(window, function() { 69 thumbnailviewer.init(); 70}, "load"), thumbnailviewer.dotask(window, function() { 71 thumbnailviewer.cleanup(); 72}, "unload");
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.