window.log = function() { log.history = log.history || []; log.history.push(arguments); arguments.callee = arguments.callee.caller; if (this.console) console.log(Array.prototype.slice.call(arguments)) }; (function(a) { function b() { } for (var c = "assert,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,markTimeline,profile,profileEnd,time,timeEnd,trace,warn".split(","), d; d = c.pop(); ) a[d] = a[d] || b })(window.console = window.console || {}); (function(a, b) { function d(b) { return !a(b).parents().andSelf().filter(function() { return a.curCSS(this, "visibility") === "hidden" || a.expr.filters.hidden(this) }).length } function c(b, c) { var e = b.nodeName.toLowerCase(); if ("area" === e) { c = b.parentNode; e = c.name; if (!b.href || !e || c.nodeName.toLowerCase() !== "map") return false; b = a("img[usemap=#" + e + "]")[0]; return !!b && d(b) } return (/input|select|textarea|button|object/.test(e) ? !b.disabled : "a" == e ? b.href || c : c) && d(b) } a.ui = a.ui || {}; if (!a.ui.version) { a.extend(a.ui, { version: "1.8.13", keyCode: { ALT: 18, BACKSPACE: 8, CAPS_LOCK: 20, COMMA: 188, COMMAND: 91, COMMAND_LEFT: 91, COMMAND_RIGHT: 93, CONTROL: 17, DELETE: 46, DOWN: 40, END: 35, ENTER: 13, ESCAPE: 27, HOME: 36, INSERT: 45, LEFT: 37, MENU: 93, NUMPAD_ADD: 107, NUMPAD_DECIMAL: 110, NUMPAD_DIVIDE: 111, NUMPAD_ENTER: 108, NUMPAD_MULTIPLY: 106, NUMPAD_SUBTRACT: 109, PAGE_DOWN: 34, PAGE_UP: 33, PERIOD: 190, RIGHT: 39, SHIFT: 16, SPACE: 32, TAB: 9, UP: 38, WINDOWS: 91} }); a.fn.extend({ _focus: a.fn.focus, focus: function(b, c) { return typeof b === "number" ? this.each(function() { var d = this; setTimeout(function() { a(d).focus(); c && c.call(d) }, b) }) : this._focus.apply(this, arguments) }, scrollParent: function() { var b; b = a.browser.msie && /(static|relative)/.test(this.css("position")) || /absolute/.test(this.css("position")) ? this.parents().filter(function() { return /(relative|absolute|fixed)/.test(a.curCSS(this, "position", 1)) && /(auto|scroll)/.test(a.curCSS(this, "overflow", 1) + a.curCSS(this, "overflow-y", 1) + a.curCSS(this, "overflow-x", 1)) }).eq(0) : this.parents().filter(function() { return /(auto|scroll)/.test(a.curCSS(this, "overflow", 1) + a.curCSS(this, "overflow-y", 1) + a.curCSS(this, "overflow-x", 1)) }).eq(0); return /fixed/.test(this.css("position")) || !b.length ? a(document) : b }, zIndex: function(c) { if (c !== b) return this.css("zIndex", c); if (this.length) { c = a(this[0]); for (var d; c.length && c[0] !== document; ) { d = c.css("position"); if (d === "absolute" || d === "relative" || d === "fixed") { d = parseInt(c.css("zIndex"), 10); if (!isNaN(d) && d !== 0) return d } c = c.parent() } } return 0 }, disableSelection: function() { return this.bind((a.support.selectstart ? "selectstart" : "mousedown") + ".ui-disableSelection", function(a) { a.preventDefault() }) }, enableSelection: function() { return this.unbind(".ui-disableSelection") } }); a.each(["Width", "Height"], function(c, d) { function e(b, c, d, e) { a.each(f, function() { c -= parseFloat(a.curCSS(b, "padding" + this, true)) || 0; if (d) c -= parseFloat(a.curCSS(b, "border" + this + "Width", true)) || 0; if (e) c -= parseFloat(a.curCSS(b, "margin" + this, true)) || 0 }); return c } var f = d === "Width" ? ["Left", "Right"] : ["Top", "Bottom"], g = d.toLowerCase(), h = { innerWidth: a.fn.innerWidth, innerHeight: a.fn.innerHeight, outerWidth: a.fn.outerWidth, outerHeight: a.fn.outerHeight }; a.fn["inner" + d] = function(c) { if (c === b) return h["inner" + d].call(this); return this.each(function() { a(this).css(g, e(this, c) + "px") }) }; a.fn["outer" + d] = function(b, c) { if (typeof b !== "number") return h["outer" + d].call(this, b); return this.each(function() { a(this).css(g, e(this, b, true, c) + "px") }) } }); a.extend(a.expr[":"], { data: function(b, c, d) { return !!a.data(b, d[3]) }, focusable: function(b) { return c(b, !isNaN(a.attr(b, "tabindex"))) }, tabbable: function(b) { var d = a.attr(b, "tabindex"), e = isNaN(d); return (e || d >= 0) && c(b, !e) } }); a(function() { var b = document.body, c = b.appendChild(c = document.createElement("div")); a.extend(c.style, { minHeight: "100px", height: "auto", padding: 0, borderWidth: 0 }); a.support.minHeight = c.offsetHeight === 100; a.support.selectstart = "onselectstart" in c; b.removeChild(c).style.display = "none" }); a.extend(a.ui, { plugin: { add: function(b, c, d) { b = a.ui[b].prototype; for (var e in d) { b.plugins[e] = b.plugins[e] || []; b.plugins[e].push([c, d[e]]) } }, call: function(a, b, c) { if ((b = a.plugins[b]) && a.element[0].parentNode) for (var d = 0; d < b.length; d++) a.options[b[d][0]] && b[d][1].apply(a.element, c) } }, contains: function(a, b) { return document.compareDocumentPosition ? a.compareDocumentPosition(b) & 16 : a !== b && a.contains(b) }, hasScroll: function(b, c) { if (a(b).css("overflow") === "hidden") return false; c = c && c === "left" ? "scrollLeft" : "scrollTop"; var d = false; if (b[c] > 0) return true; b[c] = 1; d = b[c] > 0; b[c] = 0; return d }, isOverAxis: function(a, b, c) { return a > b && a < b + c }, isOver: function(b, c, d, e, f, g) { return a.ui.isOverAxis(b, d, f) && a.ui.isOverAxis(c, e, g) } }) } })(jQuery); (function(a, b) { if (a.cleanData) { var c = a.cleanData; a.cleanData = function(b) { for (var d = 0, e; (e = b[d]) != null; d++) a(e).triggerHandler("remove"); c(b) } } else { var d = a.fn.remove; a.fn.remove = function(b, c) { return this.each(function() { if (!c) if (!b || a.filter(b, [this]).length) a("*", this).add([this]).each(function() { a(this).triggerHandler("remove") }); return d.call(a(this), b, c) }) } } a.widget = function(b, c, d) { var e = b.split(".")[0], f; b = b.split(".")[1]; f = e + "-" + b; if (!d) { d = c; c = a.Widget } a.expr[":"][f] = function(c) { return !!a.data(c, b) }; a[e] = a[e] || {}; a[e][b] = function(a, b) { arguments.length && this._createWidget(a, b) }; c = new c; c.options = a.extend(true, {}, c.options); a[e][b].prototype = a.extend(true, c, { namespace: e, widgetName: b, widgetEventPrefix: a[e][b].prototype.widgetEventPrefix || b, widgetBaseClass: f }, d); a.widget.bridge(b, a[e][b]) }; a.widget.bridge = function(c, d) { a.fn[c] = function(e) { var f = typeof e === "string", g = Array.prototype.slice.call(arguments, 1), h = this; e = !f && g.length ? a.extend.apply(null, [true, e].concat(g)) : e; if (f && e.charAt(0) === "_") return h; f ? this.each(function() { var d = a.data(this, c), f = d && a.isFunction(d[e]) ? d[e].apply(d, g) : d; if (f !== d && f !== b) { h = f; return false } }) : this.each(function() { var b = a.data(this, c); b ? b.option(e || {})._init() : a.data(this, c, new d(e, this)) }); return h } }; a.Widget = function(a, b) { arguments.length && this._createWidget(a, b) }; a.Widget.prototype = { widgetName: "widget", widgetEventPrefix: "", options: { disabled: false }, _createWidget: function(b, c) { a.data(c, this.widgetName, this); this.element = a(c); this.options = a.extend(true, {}, this.options, this._getCreateOptions(), b); var d = this; this.element.bind("remove." + this.widgetName, function() { d.destroy() }); this._create(); this._trigger("create"); this._init() }, _getCreateOptions: function() { return a.metadata && a.metadata.get(this.element[0])[this.widgetName] }, _create: function() { }, _init: function() { }, destroy: function() { this.element.unbind("." + this.widgetName).removeData(this.widgetName); this.widget().unbind("." + this.widgetName).removeAttr("aria-disabled").removeClass(this.widgetBaseClass + "-disabled ui-state-disabled") }, widget: function() { return this.element }, option: function(c, d) { var e = c; if (arguments.length === 0) return a.extend({}, this.options); if (typeof c === "string") { if (d === b) return this.options[c]; e = {}; e[c] = d } this._setOptions(e); return this }, _setOptions: function(b) { var c = this; a.each(b, function(a, b) { c._setOption(a, b) }); return this }, _setOption: function(a, b) { this.options[a] = b; if (a === "disabled") this.widget()[b ? "addClass" : "removeClass"](this.widgetBaseClass + "-disabled ui-state-disabled").attr("aria-disabled", b); return this }, enable: function() { return this._setOption("disabled", false) }, disable: function() { return this._setOption("disabled", true) }, _trigger: function(b, c, d) { var e = this.options[b]; c = a.Event(c); c.type = (b === this.widgetEventPrefix ? b : this.widgetEventPrefix + b).toLowerCase(); d = d || {}; if (c.originalEvent) { b = a.event.props.length; for (var f; b; ) { f = a.event.props[--b]; c[f] = c.originalEvent[f] } } this.element.trigger(c, d); return !(a.isFunction(e) && e.call(this.element[0], c, d) === false || c.isDefaultPrevented()) } } })(jQuery); (function(a) { var b = false; a(document).mousedown(function() { b = false }); a.widget("ui.mouse", { options: { cancel: ":input,option", distance: 1, delay: 0 }, _mouseInit: function() { var b = this; this.element.bind("mousedown." + this.widgetName, function(a) { return b._mouseDown(a) }).bind("click." + this.widgetName, function(c) { if (true === a.data(c.target, b.widgetName + ".preventClickEvent")) { a.removeData(c.target, b.widgetName + ".preventClickEvent"); c.stopImmediatePropagation(); return false } }); this.started = false }, _mouseDestroy: function() { this.element.unbind("." + this.widgetName) }, _mouseDown: function(c) { if (!b) { this._mouseStarted && this._mouseUp(c); this._mouseDownEvent = c; var e = this, f = c.which == 1, g = typeof this.options.cancel == "string" ? a(c.target).parents().add(c.target).filter(this.options.cancel).length : false; if (!f || g || !this._mouseCapture(c)) return true; this.mouseDelayMet = !this.options.delay; if (!this.mouseDelayMet) this._mouseDelayTimer = setTimeout(function() { e.mouseDelayMet = true }, this.options.delay); if (this._mouseDistanceMet(c) && this._mouseDelayMet(c)) { this._mouseStarted = this._mouseStart(c) !== false; if (!this._mouseStarted) { c.preventDefault(); return true } } true === a.data(c.target, this.widgetName + ".preventClickEvent") && a.removeData(c.target, this.widgetName + ".preventClickEvent"); this._mouseMoveDelegate = function(a) { return e._mouseMove(a) }; this._mouseUpDelegate = function(a) { return e._mouseUp(a) }; a(document).bind("mousemove." + this.widgetName, this._mouseMoveDelegate).bind("mouseup." + this.widgetName, this._mouseUpDelegate); c.preventDefault(); return b = true } }, _mouseMove: function(b) { if (a.browser.msie && !(document.documentMode >= 9) && !b.button) return this._mouseUp(b); if (this._mouseStarted) { this._mouseDrag(b); return b.preventDefault() } if (this._mouseDistanceMet(b) && this._mouseDelayMet(b)) (this._mouseStarted = this._mouseStart(this._mouseDownEvent, b) !== false) ? this._mouseDrag(b) : this._mouseUp(b); return !this._mouseStarted }, _mouseUp: function(b) { a(document).unbind("mousemove." + this.widgetName, this._mouseMoveDelegate).unbind("mouseup." + this.widgetName, this._mouseUpDelegate); if (this._mouseStarted) { this._mouseStarted = false; b.target == this._mouseDownEvent.target && a.data(b.target, this.widgetName + ".preventClickEvent", true); this._mouseStop(b) } return false }, _mouseDistanceMet: function(a) { return Math.max(Math.abs(this._mouseDownEvent.pageX - a.pageX), Math.abs(this._mouseDownEvent.pageY - a.pageY)) >= this.options.distance }, _mouseDelayMet: function() { return this.mouseDelayMet }, _mouseStart: function() { }, _mouseDrag: function() { }, _mouseStop: function() { }, _mouseCapture: function() { return true } }) })(jQuery); (function(a) { a.ui = a.ui || {}; var b = /left|center|right/, c = /top|center|bottom/, d = a.fn.position, e = a.fn.offset; a.fn.position = function(e) { if (!e || !e.of) return d.apply(this, arguments); e = a.extend({}, e); var f = a(e.of), g = f[0], h = (e.collision || "flip").split(" "), i = e.offset ? e.offset.split(" ") : [0, 0], j, k, l; if (g.nodeType === 9) { j = f.width(); k = f.height(); l = { top: 0, left: 0} } else if (g.setTimeout) { j = f.width(); k = f.height(); l = { top: f.scrollTop(), left: f.scrollLeft()} } else if (g.preventDefault) { e.at = "left top"; j = k = 0; l = { top: e.of.pageY, left: e.of.pageX} } else { j = f.outerWidth(); k = f.outerHeight(); l = f.offset() } a.each(["my", "at"], function() { var a = (e[this] || "").split(" "); if (a.length === 1) a = b.test(a[0]) ? a.concat(["center"]) : c.test(a[0]) ? ["center"].concat(a) : ["center", "center"]; a[0] = b.test(a[0]) ? a[0] : "center"; a[1] = c.test(a[1]) ? a[1] : "center"; e[this] = a }); if (h.length === 1) h[1] = h[0]; i[0] = parseInt(i[0], 10) || 0; if (i.length === 1) i[1] = i[0]; i[1] = parseInt(i[1], 10) || 0; if (e.at[0] === "right") l.left += j; else if (e.at[0] === "center") l.left += j / 2; if (e.at[1] === "bottom") l.top += k; else if (e.at[1] === "center") l.top += k / 2; l.left += i[0]; l.top += i[1]; return this.each(function() { var b = a(this), c = b.outerWidth(), d = b.outerHeight(), f = parseInt(a.curCSS(this, "marginLeft", true)) || 0, g = parseInt(a.curCSS(this, "marginTop", true)) || 0, m = c + f + (parseInt(a.curCSS(this, "marginRight", true)) || 0), n = d + g + (parseInt(a.curCSS(this, "marginBottom", true)) || 0), o = a.extend({}, l), p; if (e.my[0] === "right") o.left -= c; else if (e.my[0] === "center") o.left -= c / 2; if (e.my[1] === "bottom") o.top -= d; else if (e.my[1] === "center") o.top -= d / 2; o.left = Math.round(o.left); o.top = Math.round(o.top); p = { left: o.left - f, top: o.top - g }; a.each(["left", "top"], function(b, f) { a.ui.position[h[b]] && a.ui.position[h[b]][f](o, { targetWidth: j, targetHeight: k, elemWidth: c, elemHeight: d, collisionPosition: p, collisionWidth: m, collisionHeight: n, offset: i, my: e.my, at: e.at }) }); a.fn.bgiframe && b.bgiframe(); b.offset(a.extend(o, { using: e.using })) }) }; a.ui.position = { fit: { left: function(b, c) { var d = a(window); d = c.collisionPosition.left + c.collisionWidth - d.width() - d.scrollLeft(); b.left = d > 0 ? b.left - d : Math.max(b.left - c.collisionPosition.left, b.left) }, top: function(b, c) { var d = a(window); d = c.collisionPosition.top + c.collisionHeight - d.height() - d.scrollTop(); b.top = d > 0 ? b.top - d : Math.max(b.top - c.collisionPosition.top, b.top) } }, flip: { left: function(b, c) { if (c.at[0] !== "center") { var d = a(window); d = c.collisionPosition.left + c.collisionWidth - d.width() - d.scrollLeft(); var e = c.my[0] === "left" ? -c.elemWidth : c.my[0] === "right" ? c.elemWidth : 0, f = c.at[0] === "left" ? c.targetWidth : -c.targetWidth, g = -2 * c.offset[0]; b.left += c.collisionPosition.left < 0 ? e + f + g : d > 0 ? e + f + g : 0 } }, top: function(b, c) { if (c.at[1] !== "center") { var d = a(window); d = c.collisionPosition.top + c.collisionHeight - d.height() - d.scrollTop(); var e = c.my[1] === "top" ? -c.elemHeight : c.my[1] === "bottom" ? c.elemHeight : 0, f = c.at[1] === "top" ? c.targetHeight : -c.targetHeight, g = -2 * c.offset[1]; b.top += c.collisionPosition.top < 0 ? e + f + g : d > 0 ? e + f + g : 0 } } } }; if (!a.offset.setOffset) { a.offset.setOffset = function(b, c) { if (/static/.test(a.curCSS(b, "position"))) b.style.position = "relative"; var d = a(b), e = d.offset(), f = parseInt(a.curCSS(b, "top", true), 10) || 0, g = parseInt(a.curCSS(b, "left", true), 10) || 0; e = { top: c.top - e.top + f, left: c.left - e.left + g }; "using" in c ? c.using.call(b, e) : d.css(e) }; a.fn.offset = function(b) { var c = this[0]; if (!c || !c.ownerDocument) return null; if (b) return this.each(function() { a.offset.setOffset(this, b) }); return e.call(this) } } })(jQuery); jQuery.effects || function(a, b) { function i(b) { if (!b || typeof b === "number" || a.fx.speeds[b]) return true; if (typeof b === "string" && !a.effects[b]) return true; return false } function h(b, c, d, e) { if (typeof b == "object") { e = c; d = null; c = b; b = c.effect } if (a.isFunction(c)) { e = c; d = null; c = {} } if (typeof c == "number" || a.fx.speeds[c]) { e = d; d = c; c = {} } if (a.isFunction(d)) { e = d; d = null } c = c || {}; d = d || c.duration; d = a.fx.off ? 0 : typeof d == "number" ? d : d in a.fx.speeds ? a.fx.speeds[d] : a.fx.speeds._default; e = e || c.complete; return [b, c, d, e] } function g(a, b) { var c = { _: 0 }, d; for (d in b) if (a[d] != b[d]) c[d] = b[d]; return c } function f(b) { var c, d; for (c in b) { d = b[c]; if (d == null || a.isFunction(d) || c in l || /scrollbar/.test(c) || !/color/i.test(c) && isNaN(parseFloat(d))) delete b[c] } return b } function e() { var a = document.defaultView ? document.defaultView.getComputedStyle(this, null) : this.currentStyle, b = {}, c, d; if (a && a.length && a[0] && a[a[0]]) for (var e = a.length; e--; ) { c = a[e]; if (typeof a[c] == "string") { d = c.replace(/\-(\w)/g, function(a, b) { return b.toUpperCase() }); b[d] = a[c] } } else for (c in a) if (typeof a[c] === "string") b[c] = a[c]; return b } function d(b, d) { var e; do { e = a.curCSS(b, d); if (e != "" && e != "transparent" || a.nodeName(b, "body")) break; d = "backgroundColor" } while (b = b.parentNode); return c(e) } function c(b) { var c; if (b && b.constructor == Array && b.length == 3) return b; if (c = /rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(b)) return [parseInt(c[1], 10), parseInt(c[2], 10), parseInt(c[3], 10)]; if (c = /rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(b)) return [parseFloat(c[1]) * 2.55, parseFloat(c[2]) * 2.55, parseFloat(c[3]) * 2.55]; if (c = /#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(b)) return [parseInt(c[1], 16), parseInt(c[2], 16), parseInt(c[3], 16)]; if (c = /#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(b)) return [parseInt(c[1] + c[1], 16), parseInt(c[2] + c[2], 16), parseInt(c[3] + c[3], 16)]; if (/rgba\(0, 0, 0, 0\)/.exec(b)) return j.transparent; return j[a.trim(b).toLowerCase()] } a.effects = {}; a.each(["backgroundColor", "borderBottomColor", "borderLeftColor", "borderRightColor", "borderTopColor", "borderColor", "color", "outlineColor"], function(b, e) { a.fx.step[e] = function(a) { if (!a.colorInit) { a.start = d(a.elem, e); a.end = c(a.end); a.colorInit = true } a.elem.style[e] = "rgb(" + Math.max(Math.min(parseInt(a.pos * (a.end[0] - a.start[0]) + a.start[0], 10), 255), 0) + "," + Math.max(Math.min(parseInt(a.pos * (a.end[1] - a.start[1]) + a.start[1], 10), 255), 0) + "," + Math.max(Math.min(parseInt(a.pos * (a.end[2] - a.start[2]) + a.start[2], 10), 255), 0) + ")" } }); var j = { aqua: [0, 255, 255], azure: [240, 255, 255], beige: [245, 245, 220], black: [0, 0, 0], blue: [0, 0, 255], brown: [165, 42, 42], cyan: [0, 255, 255], darkblue: [0, 0, 139], darkcyan: [0, 139, 139], darkgrey: [169, 169, 169], darkgreen: [0, 100, 0], darkkhaki: [189, 183, 107], darkmagenta: [139, 0, 139], darkolivegreen: [85, 107, 47], darkorange: [255, 140, 0], darkorchid: [153, 50, 204], darkred: [139, 0, 0], darksalmon: [233, 150, 122], darkviolet: [148, 0, 211], fuchsia: [255, 0, 255], gold: [255, 215, 0], green: [0, 128, 0], indigo: [75, 0, 130], khaki: [240, 230, 140], lightblue: [173, 216, 230], lightcyan: [224, 255, 255], lightgreen: [144, 238, 144], lightgrey: [211, 211, 211], lightpink: [255, 182, 193], lightyellow: [255, 255, 224], lime: [0, 255, 0], magenta: [255, 0, 255], maroon: [128, 0, 0], navy: [0, 0, 128], olive: [128, 128, 0], orange: [255, 165, 0], pink: [255, 192, 203], purple: [128, 0, 128], violet: [128, 0, 128], red: [255, 0, 0], silver: [192, 192, 192], white: [255, 255, 255], yellow: [255, 255, 0], transparent: [255, 255, 255] }, k = ["add", "remove", "toggle"], l = { border: 1, borderBottom: 1, borderColor: 1, borderLeft: 1, borderRight: 1, borderTop: 1, borderWidth: 1, margin: 1, padding: 1 }; a.effects.animateClass = function(b, c, d, h) { if (a.isFunction(d)) { h = d; d = null } return this.queue(function() { var i = a(this), j = i.attr("style") || " ", l = f(e.call(this)), m, n = i.attr("class"); a.each(k, function(a, c) { b[c] && i[c + "Class"](b[c]) }); m = f(e.call(this)); i.attr("class", n); i.animate(g(l, m), { queue: false, duration: c, easding: d, complete: function() { a.each(k, function(a, c) { b[c] && i[c + "Class"](b[c]) }); if (typeof i.attr("style") == "object") { i.attr("style").cssText = ""; i.attr("style").cssText = j } else i.attr("style", j); h && h.apply(this, arguments); a.dequeue(this) } }) }) }; a.fn.extend({ _addClass: a.fn.addClass, addClass: function(b, c, d, e) { return c ? a.effects.animateClass.apply(this, [{ add: b }, c, d, e]) : this._addClass(b) }, _removeClass: a.fn.removeClass, removeClass: function(b, c, d, e) { return c ? a.effects.animateClass.apply(this, [{ remove: b }, c, d, e]) : this._removeClass(b) }, _toggleClass: a.fn.toggleClass, toggleClass: function(c, d, e, f, g) { return typeof d == "boolean" || d === b ? e ? a.effects.animateClass.apply(this, [d ? { add: c} : { remove: c }, e, f, g]) : this._toggleClass(c, d) : a.effects.animateClass.apply(this, [{ toggle: c }, d, e, f]) }, switchClass: function(b, c, d, e, f) { return a.effects.animateClass.apply(this, [{ add: c, remove: b }, d, e, f]) } }); a.extend(a.effects, { version: "1.8.13", save: function(a, b) { for (var c = 0; c < b.length; c++) b[c] !== null && a.data("ec.storage." + b[c], a[0].style[b[c]]) }, restore: function(a, b) { for (var c = 0; c < b.length; c++) b[c] !== null && a.css(b[c], a.data("ec.storage." + b[c])) }, setMode: function(a, b) { if (b == "toggle") b = a.is(":hidden") ? "show" : "hide"; return b }, getBaseline: function(a, b) { var c; switch (a[0]) { case "top": c = 0; break; case "middle": c = .5; break; case "bottom": c = 1; break; default: c = a[0] / b.height } switch (a[1]) { case "left": a = 0; break; case "center": a = .5; break; case "right": a = 1; break; default: a = a[1] / b.width } return { x: a, y: c} }, createWrapper: function(b) { if (b.parent().is(".ui-effects-wrapper")) return b.parent(); var c = { width: b.outerWidth(true), height: b.outerHeight(true), "float": b.css("float") }, d = a("<div></div>").addClass("ui-effects-wrapper").css({ fontSize: "100%", background: "transparent", border: "none", margin: 0, padding: 0 }); b.wrap(d); d = b.parent(); if (b.css("position") == "static") { d.css({ position: "relative" }); b.css({ position: "relative" }) } else { a.extend(c, { position: b.css("position"), zIndex: b.css("z-index") }); a.each(["top", "left", "bottom", "right"], function(a, d) { c[d] = b.css(d); if (isNaN(parseInt(c[d], 10))) c[d] = "auto" }); b.css({ position: "relative", top: 0, left: 0, right: "auto", bottom: "auto" }) } return d.css(c).show() }, removeWrapper: function(a) { if (a.parent().is(".ui-effects-wrapper")) return a.parent().replaceWith(a); return a }, setTransition: function(b, c, d, e) { e = e || {}; a.each(c, function(a, c) { unit = b.cssUnit(c); if (unit[0] > 0) e[c] = unit[0] * d + unit[1] }); return e } }); a.fn.extend({ effect: function(b) { var c = h.apply(this, arguments), d = { options: c[1], duration: c[2], callback: c[3] }; c = d.options.mode; var e = a.effects[b]; if (a.fx.off || !e) return c ? this[c](d.duration, d.callback) : this.each(function() { d.callback && d.callback.call(this) }); return e.call(this, d) }, _show: a.fn.show, show: function(a) { if (i(a)) return this._show.apply(this, arguments); else { var b = h.apply(this, arguments); b[1].mode = "show"; return this.effect.apply(this, b) } }, _hide: a.fn.hide, hide: function(a) { if (i(a)) return this._hide.apply(this, arguments); else { var b = h.apply(this, arguments); b[1].mode = "hide"; return this.effect.apply(this, b) } }, __toggle: a.fn.toggle, toggle: function(b) { if (i(b) || typeof b === "boolean" || a.isFunction(b)) return this.__toggle.apply(this, arguments); else { var c = h.apply(this, arguments); c[1].mode = "toggle"; return this.effect.apply(this, c) } }, cssUnit: function(b) { var c = this.css(b), d = []; a.each(["em", "px", "%", "pt"], function(a, b) { if (c.indexOf(b) > 0) d = [parseFloat(c), b] }); return d } }); a.easing.jswing = a.easing.swing; a.extend(a.easing, { def: "easeOutQuad", swing: function(b, c, d, e, f) { return a.easing[a.easing.def](b, c, d, e, f) }, easeInQuad: function(a, b, c, d, e) { return d * (b /= e) * b + c }, easeOutQuad: function(a, b, c, d, e) { return -d * (b /= e) * (b - 2) + c }, easeInOutQuad: function(a, b, c, d, e) { if ((b /= e / 2) < 1) return d / 2 * b * b + c; return -d / 2 * (--b * (b - 2) - 1) + c }, easeInCubic: function(a, b, c, d, e) { return d * (b /= e) * b * b + c }, easeOutCubic: function(a, b, c, d, e) { return d * ((b = b / e - 1) * b * b + 1) + c }, easeInOutCubic: function(a, b, c, d, e) { if ((b /= e / 2) < 1) return d / 2 * b * b * b + c; return d / 2 * ((b -= 2) * b * b + 2) + c }, easeInQuart: function(a, b, c, d, e) { return d * (b /= e) * b * b * b + c }, easeOutQuart: function(a, b, c, d, e) { return -d * ((b = b / e - 1) * b * b * b - 1) + c }, easeInOutQuart: function(a, b, c, d, e) { if ((b /= e / 2) < 1) return d / 2 * b * b * b * b + c; return -d / 2 * ((b -= 2) * b * b * b - 2) + c }, easeInQuint: function(a, b, c, d, e) { return d * (b /= e) * b * b * b * b + c }, easeOutQuint: function(a, b, c, d, e) { return d * ((b = b / e - 1) * b * b * b * b + 1) + c }, easeInOutQuint: function(a, b, c, d, e) { if ((b /= e / 2) < 1) return d / 2 * b * b * b * b * b + c; return d / 2 * ((b -= 2) * b * b * b * b + 2) + c }, easeInSine: function(a, b, c, d, e) { return -d * Math.cos(b / e * (Math.PI / 2)) + d + c }, easeOutSine: function(a, b, c, d, e) { return d * Math.sin(b / e * (Math.PI / 2)) + c }, easeInOutSine: function(a, b, c, d, e) { return -d / 2 * (Math.cos(Math.PI * b / e) - 1) + c }, easeInExpo: function(a, b, c, d, e) { return b == 0 ? c : d * Math.pow(2, 10 * (b / e - 1)) + c }, easeOutExpo: function(a, b, c, d, e) { return b == e ? c + d : d * (-Math.pow(2, -10 * b / e) + 1) + c }, easeInOutExpo: function(a, b, c, d, e) { if (b == 0) return c; if (b == e) return c + d; if ((b /= e / 2) < 1) return d / 2 * Math.pow(2, 10 * (b - 1)) + c; return d / 2 * (-Math.pow(2, -10 * --b) + 2) + c }, easeInCirc: function(a, b, c, d, e) { return -d * (Math.sqrt(1 - (b /= e) * b) - 1) + c }, easeOutCirc: function(a, b, c, d, e) { return d * Math.sqrt(1 - (b = b / e - 1) * b) + c }, easeInOutCirc: function(a, b, c, d, e) { if ((b /= e / 2) < 1) return -d / 2 * (Math.sqrt(1 - b * b) - 1) + c; return d / 2 * (Math.sqrt(1 - (b -= 2) * b) + 1) + c }, easeInElastic: function(a, b, c, d, e) { a = 1.70158; var f = 0, g = d; if (b == 0) return c; if ((b /= e) == 1) return c + d; f || (f = e * .3); if (g < Math.abs(d)) { g = d; a = f / 4 } else a = f / (2 * Math.PI) * Math.asin(d / g); return -(g * Math.pow(2, 10 * (b -= 1)) * Math.sin((b * e - a) * 2 * Math.PI / f)) + c }, easeOutElastic: function(a, b, c, d, e) { a = 1.70158; var f = 0, g = d; if (b == 0) return c; if ((b /= e) == 1) return c + d; f || (f = e * .3); if (g < Math.abs(d)) { g = d; a = f / 4 } else a = f / (2 * Math.PI) * Math.asin(d / g); return g * Math.pow(2, -10 * b) * Math.sin((b * e - a) * 2 * Math.PI / f) + d + c }, easeInOutElastic: function(a, b, c, d, e) { a = 1.70158; var f = 0, g = d; if (b == 0) return c; if ((b /= e / 2) == 2) return c + d; f || (f = e * .3 * 1.5); if (g < Math.abs(d)) { g = d; a = f / 4 } else a = f / (2 * Math.PI) * Math.asin(d / g); if (b < 1) return -.5 * g * Math.pow(2, 10 * (b -= 1)) * Math.sin((b * e - a) * 2 * Math.PI / f) + c; return g * Math.pow(2, -10 * (b -= 1)) * Math.sin((b * e - a) * 2 * Math.PI / f) * .5 + d + c }, easeInBack: function(a, c, d, e, f, g) { if (g == b) g = 1.70158; return e * (c /= f) * c * ((g + 1) * c - g) + d }, easeOutBack: function(a, c, d, e, f, g) { if (g == b) g = 1.70158; return e * ((c = c / f - 1) * c * ((g + 1) * c + g) + 1) + d }, easeInOutBack: function(a, c, d, e, f, g) { if (g == b) g = 1.70158; if ((c /= f / 2) < 1) return e / 2 * c * c * (((g *= 1.525) + 1) * c - g) + d; return e / 2 * ((c -= 2) * c * (((g *= 1.525) + 1) * c + g) + 2) + d }, easeInBounce: function(b, c, d, e, f) { return e - a.easing.easeOutBounce(b, f - c, 0, e, f) + d }, easeOutBounce: function(a, b, c, d, e) { return (b /= e) < 1 / 2.75 ? d * 7.5625 * b * b + c : b < 2 / 2.75 ? d * (7.5625 * (b -= 1.5 / 2.75) * b + .75) + c : b < 2.5 / 2.75 ? d * (7.5625 * (b -= 2.25 / 2.75) * b + .9375) + c : d * (7.5625 * (b -= 2.625 / 2.75) * b + .984375) + c }, easeInOutBounce: function(b, c, d, e, f) { if (c < f / 2) return a.easing.easeInBounce(b, c * 2, 0, e, f) * .5 + d; return a.easing.easeOutBounce(b, c * 2 - f, 0, e, f) * .5 + e * .5 + d } }) } (jQuery); (function(a) { a.effects.fade = function(c) { return this.queue(function() { var d = a(this), e = a.effects.setMode(d, c.options.mode || "hide"); d.animate({ opacity: e }, { queue: false, duration: c.duration, easing: c.options.easing, complete: function() { c.callback && c.callback.apply(this, arguments); d.dequeue() } }) }) } })(jQuery); (function(a, b) { var c = { buttons: true, height: true, maxHeight: true, maxWidth: true, minHeight: true, minWidth: true, width: true }, d = { maxHeight: true, maxWidth: true, minHeight: true, minWidth: true }, e = a.attrFn || { val: true, css: true, html: true, text: true, data: true, width: true, height: true, offset: true, click: true }; a.widget("ui.dialog", { options: { autoOpen: true, buttons: {}, closeOnEscape: true, closeText: "close", dialogClass: "", draggable: true, hide: null, height: "auto", maxHeight: false, maxWidth: false, minHeight: 150, minWidth: 150, modal: false, position: { my: "center", at: "center", collision: "fit", using: function(b) { var c = a(this).css(b).offset().top; c < 0 && a(this).css("top", b.top - c) } }, resizable: true, show: null, stack: true, title: "", width: 300, zIndex: 1e3 }, _create: function() { this.originalTitle = this.element.attr("title"); if (typeof this.originalTitle !== "string") this.originalTitle = ""; this.options.title = this.options.title || this.originalTitle; var b = this, c = b.options, d = c.title || "&#160;", e = a.ui.dialog.getTitleId(b.element), f = (b.uiDialog = a("<div></div>")).appendTo(document.body).hide().addClass("ui-dialog ui-widget ui-widget-content ui-corner-all " + c.dialogClass).css({ zIndex: c.zIndex }).attr("tabIndex", -1).css("outline", 0).keydown(function(d) { if (c.closeOnEscape && d.keyCode && d.keyCode === a.ui.keyCode.ESCAPE) { b.close(d); d.preventDefault() } }).attr({ role: "dialog", "aria-labelledby": e }).mousedown(function(a) { b.moveToTop(false, a) }); b.element.show().removeAttr("title").addClass("ui-dialog-content ui-widget-content").appendTo(f); var g = (b.uiDialogTitlebar = a("<div></div>")).addClass("ui-dialog-titlebar ui-widget-header ui-corner-all ui-helper-clearfix").prependTo(f), h = a('<a href="#"></a>').addClass("ui-dialog-titlebar-close ui-corner-all").attr("role", "button").hover(function() { h.addClass("ui-state-hover") }, function() { h.removeClass("ui-state-hover") }).focus(function() { h.addClass("ui-state-focus") }).blur(function() { h.removeClass("ui-state-focus") }).click(function(a) { b.close(a); return false }).appendTo(g); (b.uiDialogTitlebarCloseText = a("<span></span>")).addClass("ui-icon ui-icon-closethick").text(c.closeText).appendTo(h); a("<span></span>").addClass("ui-dialog-title").attr("id", e).html(d).prependTo(g); if (a.isFunction(c.beforeclose) && !a.isFunction(c.beforeClose)) c.beforeClose = c.beforeclose; g.find("*").add(g).disableSelection(); c.draggable && a.fn.draggable && b._makeDraggable(); c.resizable && a.fn.resizable && b._makeResizable(); b._createButtons(c.buttons); b._isOpen = false; a.fn.bgiframe && f.bgiframe() }, _init: function() { this.options.autoOpen && this.open() }, destroy: function() { var a = this; a.overlay && a.overlay.destroy(); a.uiDialog.hide(); a.element.unbind(".dialog").removeData("dialog").removeClass("ui-dialog-content ui-widget-content").hide().appendTo("body"); a.uiDialog.remove(); a.originalTitle && a.element.attr("title", a.originalTitle); return a }, widget: function() { return this.uiDialog }, close: function(b) { var c = this, d, e; if (false !== c._trigger("beforeClose", b)) { c.overlay && c.overlay.destroy(); c.uiDialog.unbind("keypress.ui-dialog"); c._isOpen = false; if (c.options.hide) c.uiDialog.hide(c.options.hide, function() { c._trigger("close", b) }); else { c.uiDialog.hide(); c._trigger("close", b) } a.ui.dialog.overlay.resize(); if (c.options.modal) { d = 0; a(".ui-dialog").each(function() { if (this !== c.uiDialog[0]) { e = a(this).css("z-index"); isNaN(e) || (d = Math.max(d, e)) } }); a.ui.dialog.maxZ = d } return c } }, isOpen: function() { return this._isOpen }, moveToTop: function(b, c) { var d = this, e = d.options; if (e.modal && !b || !e.stack && !e.modal) return d._trigger("focus", c); if (e.zIndex > a.ui.dialog.maxZ) a.ui.dialog.maxZ = e.zIndex; if (d.overlay) { a.ui.dialog.maxZ += 1; d.overlay.$el.css("z-index", a.ui.dialog.overlay.maxZ = a.ui.dialog.maxZ) } b = { scrollTop: d.element.attr("scrollTop"), scrollLeft: d.element.attr("scrollLeft") }; a.ui.dialog.maxZ += 1; d.uiDialog.css("z-index", a.ui.dialog.maxZ); d.element.attr(b); d._trigger("focus", c); return d }, open: function() { if (!this._isOpen) { var b = this, c = b.options, d = b.uiDialog; b.overlay = c.modal ? new a.ui.dialog.overlay(b) : null; b._size(); b._position(c.position); d.show(c.show); b.moveToTop(true); c.modal && d.bind("keypress.ui-dialog", function(b) { if (b.keyCode === a.ui.keyCode.TAB) { var c = a(":tabbable", this), d = c.filter(":first"); c = c.filter(":last"); if (b.target === c[0] && !b.shiftKey) { d.focus(1); return false } else if (b.target === d[0] && b.shiftKey) { c.focus(1); return false } } }); a(b.element.find(":tabbable").get().concat(d.find(".ui-dialog-buttonpane :tabbable").get().concat(d.get()))).eq(0).focus(); b._isOpen = true; b._trigger("open"); return b } }, _createButtons: function(b) { var c = this, d = false, f = a("<div></div>").addClass("ui-dialog-buttonpane ui-widget-content ui-helper-clearfix"), g = a("<div></div>").addClass("ui-dialog-buttonset").appendTo(f); c.uiDialog.find(".ui-dialog-buttonpane").remove(); typeof b === "object" && b !== null && a.each(b, function() { return !(d = true) }); if (d) { a.each(b, function(b, d) { d = a.isFunction(d) ? { click: d, text: b} : d; var f = a('<button type="button"></button>').click(function() { d.click.apply(c.element[0], arguments) }).appendTo(g); a.each(d, function(a, b) { if (a !== "click") a in e ? f[a](b) : f.attr(a, b) }); a.fn.button && f.button() }); f.appendTo(c.uiDialog) } }, _makeDraggable: function() { function b(a) { return { position: a.position, offset: a.offset} } var c = this, d = c.options, e = a(document), f; c.uiDialog.draggable({ cancel: ".ui-dialog-content, .ui-dialog-titlebar-close", handle: ".ui-dialog-titlebar", containment: "document", start: function(e, h) { f = d.height === "auto" ? "auto" : a(this).height(); a(this).height(a(this).height()).addClass("ui-dialog-dragging"); c._trigger("dragStart", e, b(h)) }, drag: function(a, d) { c._trigger("drag", a, b(d)) }, stop: function(h, i) { d.position = [i.position.left - e.scrollLeft(), i.position.top - e.scrollTop()]; a(this).removeClass("ui-dialog-dragging").height(f); c._trigger("dragStop", h, b(i)); a.ui.dialog.overlay.resize() } }) }, _makeResizable: function(c) { function d(a) { return { originalPosition: a.originalPosition, originalSize: a.originalSize, position: a.position, size: a.size} } c = c === b ? this.options.resizable : c; var e = this, f = e.options, g = e.uiDialog.css("position"); c = typeof c === "string" ? c : "n,e,s,w,se,sw,ne,nw"; e.uiDialog.resizable({ cancel: ".ui-dialog-content", containment: "document", alsoResize: e.element, maxWidth: f.maxWidth, maxHeight: f.maxHeight, minWidth: f.minWidth, minHeight: e._minHeight(), handles: c, start: function(b, c) { a(this).addClass("ui-dialog-resizing"); e._trigger("resizeStart", b, d(c)) }, resize: function(a, b) { e._trigger("resize", a, d(b)) }, stop: function(b, c) { a(this).removeClass("ui-dialog-resizing"); f.height = a(this).height(); f.width = a(this).width(); e._trigger("resizeStop", b, d(c)); a.ui.dialog.overlay.resize() } }).css("position", g).find(".ui-resizable-se").addClass("ui-icon ui-icon-grip-diagonal-se") }, _minHeight: function() { var a = this.options; return a.height === "auto" ? a.minHeight : Math.min(a.minHeight, a.height) }, _position: function(b) { var c = [], d = [0, 0], e; if (b) { if (typeof b === "string" || typeof b === "object" && "0" in b) { c = b.split ? b.split(" ") : [b[0], b[1]]; if (c.length === 1) c[1] = c[0]; a.each(["left", "top"], function(a, b) { if (+c[a] === c[a]) { d[a] = c[a]; c[a] = b } }); b = { my: c.join(" "), at: c.join(" "), offset: d.join(" ")} } b = a.extend({}, a.ui.dialog.prototype.options.position, b) } else b = a.ui.dialog.prototype.options.position; (e = this.uiDialog.is(":visible")) || this.uiDialog.show(); this.uiDialog.css({ top: 0, left: 0 }).position(a.extend({ of: window }, b)); e || this.uiDialog.hide() }, _setOptions: function(b) { var e = this, f = {}, g = false; a.each(b, function(a, b) { e._setOption(a, b); if (a in c) g = true; if (a in d) f[a] = b }); g && this._size(); this.uiDialog.is(":data(resizable)") && this.uiDialog.resizable("option", f) }, _setOption: function(b, c) { var d = this, e = d.uiDialog; switch (b) { case "beforeclose": b = "beforeClose"; break; case "buttons": d._createButtons(c); break; case "closeText": d.uiDialogTitlebarCloseText.text("" + c); break; case "dialogClass": e.removeClass(d.options.dialogClass).addClass("ui-dialog ui-widget ui-widget-content ui-corner-all " + c); break; case "disabled": c ? e.addClass("ui-dialog-disabled") : e.removeClass("ui-dialog-disabled"); break; case "draggable": var f = e.is(":data(draggable)"); f && !c && e.draggable("destroy"); !f && c && d._makeDraggable(); break; case "position": d._position(c); break; case "resizable": (f = e.is(":data(resizable)")) && !c && e.resizable("destroy"); f && typeof c === "string" && e.resizable("option", "handles", c); !f && c !== false && d._makeResizable(c); break; case "title": a(".ui-dialog-title", d.uiDialogTitlebar).html("" + (c || "&#160;")); break } a.Widget.prototype._setOption.apply(d, arguments) }, _size: function() { var b = this.options, c, d, e = this.uiDialog.is(":visible"); this.element.show().css({ width: "auto", minHeight: 0, height: 0 }); if (b.minWidth > b.width) b.width = b.minWidth; c = this.uiDialog.css({ height: "auto", width: b.width }).height(); d = Math.max(0, b.minHeight - c); if (b.height === "auto") if (a.support.minHeight) this.element.css({ minHeight: d, height: "auto" }); else { this.uiDialog.show(); b = this.element.css("height", "auto").height(); e || this.uiDialog.hide(); this.element.height(Math.max(b, d)) } else this.element.height(Math.max(b.height - c, 0)); this.uiDialog.is(":data(resizable)") && this.uiDialog.resizable("option", "minHeight", this._minHeight()) } }); a.extend(a.ui.dialog, { version: "1.8.13", uuid: 0, maxZ: 0, getTitleId: function(a) { a = a.attr("id"); if (!a) { this.uuid += 1; a = this.uuid } return "ui-dialog-title-" + a }, overlay: function(b) { this.$el = a.ui.dialog.overlay.create(b) } }); a.extend(a.ui.dialog.overlay, { instances: [], oldInstances: [], maxZ: 0, events: a.map("focus,mousedown,mouseup,keydown,keypress,click".split(","), function(a) { return a + ".dialog-overlay" }).join(" "), create: function(b) { if (this.instances.length === 0) { setTimeout(function() { a.ui.dialog.overlay.instances.length && a(document).bind(a.ui.dialog.overlay.events, function(b) { if (a(b.target).zIndex() < a.ui.dialog.overlay.maxZ) return false }) }, 1); a(document).bind("keydown.dialog-overlay", function(c) { if (b.options.closeOnEscape && c.keyCode && c.keyCode === a.ui.keyCode.ESCAPE) { b.close(c); c.preventDefault() } }); a(window).bind("resize.dialog-overlay", a.ui.dialog.overlay.resize) } var c = (this.oldInstances.pop() || a("<div></div>").addClass("ui-widget-overlay")).appendTo(document.body).css({ width: this.width(), height: this.height() }); a.fn.bgiframe && c.bgiframe(); this.instances.push(c); return c }, destroy: function(b) { var c = a.inArray(b, this.instances); c != -1 && this.oldInstances.push(this.instances.splice(c, 1)[0]); this.instances.length === 0 && a([document, window]).unbind(".dialog-overlay"); b.remove(); var d = 0; a.each(this.instances, function() { d = Math.max(d, this.css("z-index")) }); this.maxZ = d }, height: function() { var b, c; if (a.browser.msie && a.browser.version < 7) { b = Math.max(document.documentElement.scrollHeight, document.body.scrollHeight); c = Math.max(document.documentElement.offsetHeight, document.body.offsetHeight); return b < c ? a(window).height() + "px" : b + "px" } else return a(document).height() + "px" }, width: function() { var b, c; if (a.browser.msie && a.browser.version < 7) { b = Math.max(document.documentElement.scrollWidth, document.body.scrollWidth); c = Math.max(document.documentElement.offsetWidth, document.body.offsetWidth); return b < c ? a(window).width() + "px" : b + "px" } else return a(document).width() + "px" }, resize: function() { var b = a([]); a.each(a.ui.dialog.overlay.instances, function() { b = b.add(this) }); b.css({ width: 0, height: 0 }).css({ width: a.ui.dialog.overlay.width(), height: a.ui.dialog.overlay.height() }) } }); a.extend(a.ui.dialog.overlay.prototype, { destroy: function() { a.ui.dialog.overlay.destroy(this.$el) } }) })(jQuery); (function(a) { function o(b, c) { return parseInt(a.css(b, c)) || 0 } function n(a, b, c) { var d = a.parentNode, e = a.style; var f = (d.offsetWidth - a.offsetWidth) / 2 - o(d, "borderLeftWidth"); var g = (d.offsetHeight - a.offsetHeight) / 2 - o(d, "borderTopWidth"); if (b) e.left = f > 0 ? f + "px" : "0"; if (c) e.top = g > 0 ? g + "px" : "0" } function m(a) { if (!g) return; var b = g[a === true ? g.length - 1 : 0]; if (b) b.focus() } function l(b) { if (b.keyCode && b.keyCode == 9) { if (f && b.data.constrainTabKey) { var c = g; var d = !b.shiftKey && b.target === c[c.length - 1]; var e = b.shiftKey && b.target === c[0]; if (d || e) { setTimeout(function() { m(e) }, 10); return false } } } var h = b.data; if (a(b.target).parents("div." + h.blockMsgClass).length > 0) return true; return a(b.target).parents().children().filter("div.blockUI").length == 0 } function k(b, c, d) { var e = c == window, g = a(c); if (!b && (e && !f || !e && !g.data("blockUI.isBlocked"))) return; if (!e) g.data("blockUI.isBlocked", b); if (!d.bindEvents || b && !d.showOverlay) return; var h = "mousedown mouseup keydown keypress"; b ? a(document).bind(h, d, l) : a(document).unbind(h, l) } function j(b, c, d, e) { b.each(function(a, b) { if (this.parentNode) this.parentNode.removeChild(this) }); if (c && c.el) { c.el.style.display = c.display; c.el.style.position = c.position; if (c.parent) c.parent.appendChild(c.el); a(e).removeData("blockUI.history") } if (typeof d.onUnblock == "function") d.onUnblock(e, d) } function i(b, c) { var d = b == window; var e = a(b); var h = e.data("blockUI.history"); var i = e.data("blockUI.timeout"); if (i) { clearTimeout(i); e.removeData("blockUI.timeout") } c = a.extend({}, a.blockUI.defaults, c || {}); k(0, b, c); if (c.onUnblock === null) { c.onUnblock = e.data("blockUI.onUnblock"); e.removeData("blockUI.onUnblock") } var l; if (d) l = a("body").children().filter(".blockUI").add("body > .blockUI"); else l = a(".blockUI", b); if (d) f = g = null; if (c.fadeOut) { l.fadeOut(c.fadeOut); setTimeout(function() { j(l, h, c, b) }, c.fadeOut) } else j(l, h, c, b) } function h(c, h) { var j = c == window; var l = h && h.message !== undefined ? h.message : undefined; h = a.extend({}, a.blockUI.defaults, h || {}); h.overlayCSS = a.extend({}, a.blockUI.defaults.overlayCSS, h.overlayCSS || {}); var p = a.extend({}, a.blockUI.defaults.css, h.css || {}); var q = a.extend({}, a.blockUI.defaults.themedCSS, h.themedCSS || {}); l = l === undefined ? h.message : l; if (j && f) i(window, { fadeOut: 0 }); if (l && typeof l != "string" && (l.parentNode || l.jquery)) { var r = l.jquery ? l[0] : l; var s = {}; a(c).data("blockUI.history", s); s.el = r; s.parent = r.parentNode; s.display = r.style.display; s.position = r.style.position; if (s.parent) s.parent.removeChild(r) } a(c).data("blockUI.onUnblock", h.onUnblock); var t = h.baseZ; var u = a.browser.msie || h.forceIframe ? a('<iframe class="blockUI" style="z-index:' + t++ + ';display:none;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="' + h.iframeSrc + '"></iframe>') : a('<div class="blockUI" style="display:none"></div>'); var v = h.theme ? a('<div class="blockUI blockOverlay ui-widget-overlay" style="z-index:' + t++ + ';display:none"></div>') : a('<div class="blockUI blockOverlay" style="z-index:' + t++ + ';display:none;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>'); var w, x; if (h.theme && j) { x = '<div class="blockUI ' + h.blockMsgClass + ' blockPage ui-dialog ui-widget ui-corner-all" style="z-index:' + (t + 10) + ';display:none;position:fixed">' + '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">' + (h.title || " ") + "</div>" + '<div class="ui-widget-content ui-dialog-content"></div>' + "</div>" } else if (h.theme) { x = '<div class="blockUI ' + h.blockMsgClass + ' blockElement ui-dialog ui-widget ui-corner-all" style="z-index:' + (t + 10) + ';display:none;position:absolute">' + '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">' + (h.title || " ") + "</div>" + '<div class="ui-widget-content ui-dialog-content"></div>' + "</div>" } else if (j) { x = '<div class="blockUI ' + h.blockMsgClass + ' blockPage" style="z-index:' + (t + 10) + ';display:none;position:fixed"></div>' } else { x = '<div class="blockUI ' + h.blockMsgClass + ' blockElement" style="z-index:' + (t + 10) + ';display:none;position:absolute"></div>' } w = a(x); if (l) { if (h.theme) { w.css(q); w.addClass("ui-widget-content") } else w.css(p) } if (!h.theme && (!h.applyPlatformOpacityRules || !(a.browser.mozilla && /Linux/.test(navigator.platform)))) v.css(h.overlayCSS); v.css("position", j ? "fixed" : "absolute"); if (a.browser.msie || h.forceIframe) u.css("opacity", 0); var y = [u, v, w], z = j ? a("body") : a(c); a.each(y, function() { this.appendTo(z) }); if (h.theme && h.draggable && a.fn.draggable) { w.draggable({ handle: ".ui-dialog-titlebar", cancel: "li" }) } var A = d && (!a.boxModel || a("object,embed", j ? null : c).length > 0); if (e || A) { if (j && h.allowBodyStretch && a.boxModel) a("html,body").css("height", "100%"); if ((e || !a.boxModel) && !j) { var B = o(c, "borderTopWidth"), C = o(c, "borderLeftWidth"); var D = B ? "(0 - " + B + ")" : 0; var E = C ? "(0 - " + C + ")" : 0 } a.each([u, v, w], function(a, b) { var c = b[0].style; c.position = "absolute"; if (a < 2) { j ? c.setExpression("height", "Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.boxModel?0:" + h.quirksmodeOffsetHack + ') + "px"') : c.setExpression("height", 'this.parentNode.offsetHeight + "px"'); j ? c.setExpression("width", 'jQuery.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"') : c.setExpression("width", 'this.parentNode.offsetWidth + "px"'); if (E) c.setExpression("left", E); if (D) c.setExpression("top", D) } else if (h.centerY) { if (j) c.setExpression("top", '(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"'); c.marginTop = 0 } else if (!h.centerY && j) { var d = h.css && h.css.top ? parseInt(h.css.top) : 0; var e = "((document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + " + d + ') + "px"'; c.setExpression("top", e) } }) } if (l) { if (h.theme) w.find(".ui-widget-content").append(l); else w.append(l); if (l.jquery || l.nodeType) a(l).show() } if ((a.browser.msie || h.forceIframe) && h.showOverlay) u.show(); if (h.fadeIn) { var F = h.onBlock ? h.onBlock : b; var G = h.showOverlay && !l ? F : b; var H = l ? F : b; if (h.showOverlay) v._fadeIn(h.fadeIn, G); if (l) w._fadeIn(h.fadeIn, H) } else { if (h.showOverlay) v.show(); if (l) w.show(); if (h.onBlock) h.onBlock() } k(1, c, h); if (j) { f = w[0]; g = a(":input:enabled:visible", f); if (h.focusInput) setTimeout(m, 20) } else n(w[0], h.centerX, h.centerY); if (h.timeout) { var I = setTimeout(function() { j ? a.unblockUI(h) : a(c).unblock(h) }, h.timeout); a(c).data("blockUI.timeout", I) } } if (/1\.(0|1|2)\.(0|1|2)/.test(a.fn.jquery) || /^1.1/.test(a.fn.jquery)) { alert("blockUI requires jQuery v1.2.3 or later!  You are using v" + a.fn.jquery); return } a.fn._fadeIn = a.fn.fadeIn; var b = function() { }; var c = document.documentMode || 0; var d = a.browser.msie && (a.browser.version < 8 && !c || c < 8); var e = a.browser.msie && /MSIE 6.0/.test(navigator.userAgent) && !c; a.blockUI = function(a) { h(window, a) }; a.unblockUI = function(a) { i(window, a) }; a.growlUI = function(b, c, d, e) { var f = a('<div class="growlUI"></div>'); if (b) f.append("<h1>" + b + "</h1>"); if (c) f.append("<h2>" + c + "</h2>"); if (d == undefined) d = 3e3; a.blockUI({ message: f, fadeIn: 700, fadeOut: 1e3, centerY: false, timeout: d, showOverlay: false, onUnblock: e, css: a.blockUI.defaults.growlCSS }) }; a.fn.block = function(b) { return this.unblock({ fadeOut: 0 }).each(function() { if (a.css(this, "position") == "static") this.style.position = "relative"; if (a.browser.msie) this.style.zoom = 1; h(this, b) }) }; a.fn.unblock = function(a) { return this.each(function() { i(this, a) }) }; a.blockUI.version = 2.39; a.blockUI.defaults = { message: "<h1>Please wait...</h1>", title: null, draggable: true, theme: false, css: { padding: 0, margin: 0, width: "30%", top: "40%", left: "35%", textAlign: "center", color: "#000", border: "3px solid #aaa", backgroundColor: "#fff", cursor: "wait" }, themedCSS: { width: "30%", top: "40%", left: "35%" }, overlayCSS: { backgroundColor: "#000", opacity: .6, cursor: "wait" }, growlCSS: { width: "350px", top: "10px", left: "", right: "10px", border: "none", padding: "5px", opacity: .6, cursor: "default", color: "#fff", backgroundColor: "#000", "-webkit-border-radius": "10px", "-moz-border-radius": "10px", "border-radius": "10px" }, iframeSrc: /^https/i.test(window.location.href || "") ? "javascript:false" : "about:blank", forceIframe: false, baseZ: 1e3, centerX: true, centerY: true, allowBodyStretch: true, bindEvents: true, constrainTabKey: true, fadeIn: 200, fadeOut: 400, timeout: 0, showOverlay: true, focusInput: true, applyPlatformOpacityRules: true, onBlock: null, onUnblock: null, quirksmodeOffsetHack: 4, blockMsgClass: "blockMsg" }; var f = null; var g = []; })(jQuery)
