﻿function ts(n, t) { if (!document.getElementById) return; var o = document, f = null, i = startSz, u, r, e; for (i += t, i < 0 && (i = 0), i > 4 && (i = 4), startSz = i, (f = o.getElementById(n)) || (f = o.getElementsByTagName(n)[0]), f.style.fontSize = szs[i], u = 0; u < tgs.length; u++) for (e = f.getElementsByTagName(tgs[u]), r = 0; r < e.length; r++) e[r].style.fontSize = szs[i] } function MM_swapImgRestore() { for (var n, i = document.MM_sr, t = 0; i && t < i.length && (n = i[t]) && n.oSrc; t++) n.src = n.oSrc } function MM_preloadImages() { var n = document, t, r, i; if (n.images) for (n.MM_p || (n.MM_p = []), r = n.MM_p.length, i = MM_preloadImages.arguments, t = 0; t < i.length; t++) i[t].indexOf("#") != 0 && (n.MM_p[r] = new Image, n.MM_p[r++].src = i[t]) } function MM_findObj(n, t) { var u, r, i; for (t || (t = document), (u = n.indexOf("?")) > 0 && parent.frames.length && (t = parent.frames[n.substring(u + 1)].document, n = n.substring(0, u)), (i = t[n]) || !t.all || (i = t.all[n]), r = 0; !i && r < t.forms.length; r++) i = t.forms[r][n]; for (r = 0; !i && t.layers && r < t.layers.length; r++) i = MM_findObj(n, t.layers[r].document); return !i && t.getElementById && (i = t.getElementById(n)), i } function MM_swapImage() { var t, r = 0, n, i = MM_swapImage.arguments; for (document.MM_sr = [], t = 0; t < i.length - 2; t += 3) (n = MM_findObj(i[t])) != null && (document.MM_sr[r++] = n, n.oSrc || (n.oSrc = n.src), n.src = i[t + 2]) } function mostrarDialogo(n, t, i) { showajaxpreloader(), url = "", $(".ui-dialog").removeClass("dialogo-amarillo"), $(".ui-dialog").removeClass("dialogo-marron"); switch (n) { case "mp": url = "/calcula-tu-seguro/calculadora-multirriesgo-personal.aspx"; break; case "piv": url = "/calcula-tu-seguro/calculadora-vida-invalidez.aspx"; break; case "dec": url = "/calcula-tu-seguro/calculadora-decesos.aspx"; break; case "paj": url = "/calcula-tu-seguro/calculadora-plan-ahorro-jubilacion.aspx"; break; case "carnepuntos": url = "/calcula-tu-seguro/calculadora-carne-por-puntos.aspx"; break; case "salud": url = "/calcula-tu-seguro/calculadora-seguro-salud.aspx?o=" + i; break; case "dental": url = "/calcula-tu-seguro/calculadora-seguro-dental.aspx"; break; case "defensa": url = "/calcula-tu-seguro/calculadora-defensa-juridica-legal.aspx"; break; case "autonomos": url = "/calcula-tu-seguro/calculadora-proteccion-autonomo.aspx"; break; case "baremodental": url = "/seguro-dental/baremo-dental.aspx"; break; case "CondicionesVida": url = "/seguro-vida-invalidez/condiciones-generales-vida.aspx"; break; case "formcontacto": url = "/corporativo/formulario-contacto.aspx?o=" + i; break; default: url = "/corporativo/formulario-contacto.aspx?o=" + i } return $("#modalIframeId").attr("src", url), $(".ui-dialog").addClass(t), $("#divId").dialog("open"), !1 } function showajaxpreloader() { document.getElementById("iframeajax").style.display = "block" } function hideajax() { document.getElementById("iframeajax").style.display = "none" } (function(n) { n.fn.accordion2 = function(t) { var r = { keepOpen: !0, startingOpen: !0 }, i = n.extend({}, r, t); return i.startingOpen && n(i.startingOpen).show(), this.each(function() { var t = n(this); n(".mostrar", t).click(function(r) { var u = n(this).next(); u.is("ul") && (r.preventDefault(), i.keepOpen || t.find("ul:visible").not(u).not(u.parents("ul:visible")).slideUp(), u.slideDown()) }) }) } })(jQuery), function(n) { var t = function(t, i) { var r = n.extend({}, n.fn.nivoSlider.defaults, i), f = { currentSlide: 0, currentImage: "", totalSlides: 0, running: !1, paused: !1, stop: !1 }, u = n(t), e, v, o, a, h, l; u.data("nivo:vars", f), u.css("position", "relative"), u.addClass("nivoSlider"), e = u.children(), e.each(function() { var t = n(this), e = "", i, r; t.is("img") || (t.is("a") && (t.addClass("nivo-imageLink"), e = t), t = t.find("img:first")), i = t.width(), i == 0 && (i = t.attr("width")), r = t.height(), r == 0 && (r = t.attr("height")), i > u.width() && u.width(i), r > u.height() && u.height(r), e != "" && e.css("display", "none"), t.css("display", "none"), f.totalSlides++ }), r.randomStart && (r.startSlide = Math.floor(Math.random() * f.totalSlides)), r.startSlide > 0 && (r.startSlide < f.totalSlides || (r.startSlide = f.totalSlides - 1), f.currentSlide = r.startSlide), f.currentImage = n(e[f.currentSlide]).is("img") ? n(e[f.currentSlide]) : n(e[f.currentSlide]).find("img:first"), n(e[f.currentSlide]).is("a") && n(e[f.currentSlide]).css("display", "block"), u.css("background", 'url("' + f.currentImage.attr("src") + '") no-repeat'), u.append(n('<div class="nivo-caption"><p></p></div>').css({ display: "none", opacity: r.captionOpacity })), n(".nivo-caption", u).css("opacity", 0), v = function(t) { var r = n(".nivo-caption", u), i; f.currentImage.attr("title") != "" && f.currentImage.attr("title") != undefined ? (i = f.currentImage.attr("title"), i.substr(0, 1) == "#" && (i = n(i).html()), r.css("opacity") != 0 ? r.find("p").stop().fadeTo(t.animSpeed, 0, function() { n(this).html(i), n(this).stop().fadeTo(t.animSpeed, 1) }) : r.find("p").html(i), r.stop().fadeTo(t.animSpeed, t.captionOpacity)) : r.stop().fadeTo(t.animSpeed, 0) }, v(r), o = 0, !r.manualAdvance && e.length > 1 && (o = setInterval(function() { s(u, e, r, !1) }, r.pauseTime)), r.directionNav && (u.append('<div class="nivo-directionNav"><a class="nivo-prevNav">' + r.prevText + '</a><a class="nivo-nextNav">' + r.nextText + "</a></div>"), r.directionNavHide && (n(".nivo-directionNav", u).hide(), u.hover(function() { n(".nivo-directionNav", u).show() }, function() { n(".nivo-directionNav", u).hide() })), n("a.nivo-prevNav", u).live("click", function() { if (f.running) return !1; clearInterval(o), o = "", f.currentSlide -= 2, s(u, e, r, "prev") }), n("a.nivo-nextNav", u).live("click", function() { if (f.running) return !1; clearInterval(o), o = "", s(u, e, r, "next") })); if (r.controlNav) { for (a = n('<div class="nivo-controlNav"></div>'), u.append(a), h = 0; h < e.length; h++) r.controlNavThumbs ? (l = e.eq(h), l.is("img") || (l = l.find("img:first")), r.controlNavThumbsFromRel ? a.append('<a class="nivo-control" rel="' + h + '"><img src="' + l.attr("rel") + '" alt="" /></a>') : a.append('<a class="nivo-control" rel="' + h + '"><img src="' + l.attr("src").replace(r.controlNavThumbsSearch, r.controlNavThumbsReplace) + '" alt="" /></a>')) : a.append('<a class="nivo-control" rel="' + h + '">' + (h + 1) + "</a>"); n(".nivo-controlNav a:eq(" + f.currentSlide + ")", u).addClass("active"), n(".nivo-controlNav a", u).live("click", function() { if (f.running) return !1; if (n(this).hasClass("active")) return !1; clearInterval(o), o = "", u.css("background", 'url("' + f.currentImage.attr("src") + '") no-repeat'), f.currentSlide = n(this).attr("rel") - 1, s(u, e, r, "control") }) } r.keyboardNav && n(window).keypress(function(n) { if (n.keyCode == "37") { if (f.running) return !1; clearInterval(o), o = "", f.currentSlide -= 2, s(u, e, r, "prev") } if (n.keyCode == "39") { if (f.running) return !1; clearInterval(o), o = "", s(u, e, r, "next") } }), r.pauseOnHover && u.hover(function() { f.paused = !0, clearInterval(o), o = "" }, function() { f.paused = !1, o != "" || r.manualAdvance || (o = setInterval(function() { s(u, e, r, !1) }, r.pauseTime)) }), u.bind("nivo:animFinished", function() { f.running = !1, n(e).each(function() { n(this).is("a") && n(this).css("display", "none") }), n(e[f.currentSlide]).is("a") && n(e[f.currentSlide]).css("display", "block"), o != "" || f.paused || r.manualAdvance || (o = setInterval(function() { s(u, e, r, !1) }, r.pauseTime)), r.afterChange.call(this) }); var c = function(t, i, r) { for (var u, f = 0; f < i.slices; f++) u = Math.round(t.width() / i.slices), f == i.slices - 1 ? t.append(n('<div class="nivo-slice"></div>').css({ left: u * f + "px", width: t.width() - u * f + "px", height: "0px", opacity: "0", background: 'url("' + r.currentImage.attr("src") + '") no-repeat -' + (u + f * u - u) + "px 0%" })) : t.append(n('<div class="nivo-slice"></div>').css({ left: u * f + "px", width: u + "px", height: "0px", opacity: "0", background: 'url("' + r.currentImage.attr("src") + '") no-repeat -' + (u + f * u - u) + "px 0%" })) }, p = function(t, i, r) { for (var f = Math.round(t.width() / i.boxCols), u = Math.round(t.height() / i.boxRows), e, o = 0; o < i.boxRows; o++) for (e = 0; e < i.boxCols; e++) e == i.boxCols - 1 ? t.append(n('<div class="nivo-box"></div>').css({ opacity: 0, left: f * e + "px", top: u * o + "px", width: t.width() - f * e + "px", height: u + "px", background: 'url("' + r.currentImage.attr("src") + '") no-repeat -' + (f + e * f - f) + "px -" + (u + o * u - u) + "px" })) : t.append(n('<div class="nivo-box"></div>').css({ opacity: 0, left: f * e + "px", top: u * o + "px", width: f + "px", height: u + "px", background: 'url("' + r.currentImage.attr("src") + '") no-repeat -' + (f + e * f - f) + "px -" + (u + o * u - u) + "px" })) }, s = function(t, i, r, u) { var e = t.data("nivo:vars"), f, a, o, s, h, nt, d, y, tt; e && e.currentSlide == e.totalSlides - 1 && r.lastSlide.call(this); if ((!e || e.stop) && !u) return !1; r.beforeChange.call(this), u ? (u == "prev" && t.css("background", 'url("' + e.currentImage.attr("src") + '") no-repeat'), u == "next" && t.css("background", 'url("' + e.currentImage.attr("src") + '") no-repeat')) : t.css("background", 'url("' + e.currentImage.attr("src") + '") no-repeat'), e.currentSlide++, e.currentSlide == e.totalSlides && (e.currentSlide = 0, r.slideshowEnd.call(this)), e.currentSlide < 0 && (e.currentSlide = e.totalSlides - 1), e.currentImage = n(i[e.currentSlide]).is("img") ? n(i[e.currentSlide]) : n(i[e.currentSlide]).find("img:first"), r.controlNav && (n(".nivo-controlNav a", t).removeClass("active"), n(".nivo-controlNav a:eq(" + e.currentSlide + ")", t).addClass("active")), v(r), n(".nivo-slice", t).remove(), n(".nivo-box", t).remove(), f = r.effect, r.effect == "random" && (a = ["sliceDownRight", "sliceDownLeft", "sliceUpRight", "sliceUpLeft", "sliceUpDown", "sliceUpDownLeft", "fold", "fade", "boxRandom", "boxRain", "boxRainReverse", "boxRainGrow", "boxRainGrowReverse"], f = a[Math.floor(Math.random() * (a.length + 1))], f == undefined && (f = "fade")), r.effect.indexOf(",") != -1 && (a = r.effect.split(","), f = a[Math.floor(Math.random() * a.length)], f == undefined && (f = "fade")), e.currentImage.attr("data-transition") && (f = e.currentImage.attr("data-transition")), e.running = !0; if (f == "sliceDown" || f == "sliceDownRight" || f == "sliceDownLeft") { c(t, r, e); var o = 0, s = 0, l = n(".nivo-slice", t); f == "sliceDownLeft" && (l = n(".nivo-slice", t)._reverse()), l.each(function() { var i = n(this); i.css({ top: "0px" }), s == r.slices - 1 ? setTimeout(function() { i.animate({ height: "100%", opacity: "1.0" }, r.animSpeed, "", function() { t.trigger("nivo:animFinished") }) }, 100 + o) : setTimeout(function() { i.animate({ height: "100%", opacity: "1.0" }, r.animSpeed) }, 100 + o), o += 50, s++ }) } else if (f == "sliceUp" || f == "sliceUpRight" || f == "sliceUpLeft") { c(t, r, e); var o = 0, s = 0, l = n(".nivo-slice", t); f == "sliceUpLeft" && (l = n(".nivo-slice", t)._reverse()), l.each(function() { var i = n(this); i.css({ bottom: "0px" }), s == r.slices - 1 ? setTimeout(function() { i.animate({ height: "100%", opacity: "1.0" }, r.animSpeed, "", function() { t.trigger("nivo:animFinished") }) }, 100 + o) : setTimeout(function() { i.animate({ height: "100%", opacity: "1.0" }, r.animSpeed) }, 100 + o), o += 50, s++ }) } else if (f == "sliceUpDown" || f == "sliceUpDownRight" || f == "sliceUpDownLeft") { c(t, r, e); var o = 0, s = 0, it = 0, l = n(".nivo-slice", t); f == "sliceUpDownLeft" && (l = n(".nivo-slice", t)._reverse()), l.each(function() { var i = n(this); s == 0 ? (i.css("top", "0px"), s++) : (i.css("bottom", "0px"), s = 0), it == r.slices - 1 ? setTimeout(function() { i.animate({ height: "100%", opacity: "1.0" }, r.animSpeed, "", function() { t.trigger("nivo:animFinished") }) }, 100 + o) : setTimeout(function() { i.animate({ height: "100%", opacity: "1.0" }, r.animSpeed) }, 100 + o), o += 50, it++ }) } else if (f == "fold") c(t, r, e), o = 0, s = 0, n(".nivo-slice", t).each(function() { var i = n(this), u = i.width(); i.css({ top: "0px", height: "100%", width: "0px" }), s == r.slices - 1 ? setTimeout(function() { i.animate({ width: u, opacity: "1.0" }, r.animSpeed, "", function() { t.trigger("nivo:animFinished") }) }, 100 + o) : setTimeout(function() { i.animate({ width: u, opacity: "1.0" }, r.animSpeed) }, 100 + o), o += 50, s++ }); else if (f == "fade") c(t, r, e), h = n(".nivo-slice:first", t), h.css({ height: "100%", width: t.width() + "px" }), h.animate({ opacity: "1.0" }, r.animSpeed * 2, "", function() { t.trigger("nivo:animFinished") }); else if (f == "slideInRight") c(t, r, e), h = n(".nivo-slice:first", t), h.css({ height: "100%", width: "0px", opacity: "1" }), h.animate({ width: t.width() + "px" }, r.animSpeed * 2, "", function() { t.trigger("nivo:animFinished") }); else if (f == "slideInLeft") c(t, r, e), h = n(".nivo-slice:first", t), h.css({ height: "100%", width: "0px", opacity: "1", left: "", right: "0px" }), h.animate({ width: t.width() + "px" }, r.animSpeed * 2, "", function() { h.css({ left: "0px", right: "" }), t.trigger("nivo:animFinished") }); else if (f == "boxRandom") { p(t, r, e); var rt = r.boxCols * r.boxRows, s = 0, o = 0, nt = w(n(".nivo-box", t)); nt.each(function() { var i = n(this); s == rt - 1 ? setTimeout(function() { i.animate({ opacity: "1" }, r.animSpeed, "", function() { t.trigger("nivo:animFinished") }) }, 100 + o) : setTimeout(function() { i.animate({ opacity: "1" }, r.animSpeed) }, 100 + o), o += 20, s++ }) } else if (f == "boxRain" || f == "boxRainReverse" || f == "boxRainGrow" || f == "boxRainGrowReverse") { p(t, r, e); var rt = r.boxCols * r.boxRows, s = 0, o = 0, g = 0, b = 0, k = []; for (k[g] = [], nt = n(".nivo-box", t), (f == "boxRainReverse" || f == "boxRainGrowReverse") && (nt = n(".nivo-box", t)._reverse()), nt.each(function() { k[g][b] = n(this), b++, b == r.boxCols && (g++, b = 0, k[g] = []) }), d = 0; d < r.boxCols * 2; d++) { for (y = d, tt = 0; tt < r.boxRows; tt++) y >= 0 && y < r.boxCols && (function(i, u, e, o, s) { var h = n(k[i][u]), l = h.width(), c = h.height(); (f == "boxRainGrow" || f == "boxRainGrowReverse") && h.width(0).height(0), o == s - 1 ? setTimeout(function() { h.animate({ opacity: "1", width: l, height: c }, r.animSpeed / 1.3, "", function() { t.trigger("nivo:animFinished") }) }, 100 + e) : setTimeout(function() { h.animate({ opacity: "1", width: l, height: c }, r.animSpeed / 1.3) }, 100 + e) } (tt, y, o, s, rt), s++), y--; o += 100 } } }, w = function(n) { for (var i, r, t = n.length; t; i = parseInt(Math.random() * t), r = n[--t], n[t] = n[i], n[i] = r); return n }, y = function(n) { this.console && typeof console.log != "undefined" && console.log(n) }; return this.stop = function() { n(t).data("nivo:vars").stop || (n(t).data("nivo:vars").stop = !0, y("Stop Slider")) }, this.start = function() { n(t).data("nivo:vars").stop && (n(t).data("nivo:vars").stop = !1, y("Start Slider")) }, r.afterLoad.call(this), this }; n.fn.nivoSlider = function(i) { return this.each(function() { var f = n(this), e; if (f.data("nivoslider")) return f.data("nivoslider"); e = new t(this, i), f.data("nivoslider", e) }) }, n.fn.nivoSlider.defaults = { effect: "random", slices: 15, boxCols: 8, boxRows: 4, animSpeed: 500, pauseTime: 3e3, startSlide: 0, directionNav: !0, directionNavHide: !0, controlNav: !0, controlNavThumbs: !1, controlNavThumbsFromRel: !1, controlNavThumbsSearch: ".jpg", controlNavThumbsReplace: "_thumb.jpg", keyboardNav: !0, pauseOnHover: !0, manualAdvance: !1, captionOpacity: .8, prevText: "Prev", nextText: "Next", randomStart: !1, beforeChange: function() { }, afterChange: function() { }, slideshowEnd: function() { }, lastSlide: function() { }, afterLoad: function() { } }, n.fn._reverse = [].reverse } (jQuery); var tgs = ["div", "h1", "p"], szs = ["xx-small", "x-small", "small", "medium", "large"], startSz = 2; $(function() { $("#divId").dialog({ autoOpen: !1, modal: !0, height: 590, width: 401, closeText: "", beforeClose: function() { $("#modalIframeId").attr("src", "") }, title: '<div id="iframeajax"> <img src="/img/progress.gif" style="vertical-align:middle;"/> <strong>Cargando</strong></div>', dialogClass: "dialogo-marron" }) })
