﻿function Boxy(n, t)
{
this.boxy = jQuery(Boxy.WRAPPER), jQuery.data(this.boxy[0],"boxy",this), this.visible = !1, this.options = jQuery.extend({},Boxy.DEFAULTS,t || {}), this.options.modal && (this.options = jQuery.extend(this.options,{
center: !0,
draggable: !1
})), this.options.actuator && jQuery.data(this.options.actuator,"active.boxy",this), this.setContent(n || "<div></div>"), this._setupTitleBar(), this.boxy.css("display","none").appendTo(document.body), this.toTop(), this.options.fixed && (jQuery.browser.msie && jQuery.browser.version < 7 ? this.options.fixed = !1 : this.boxy.addClass("fixed")), this.options.center && Boxy._u(this.options.x,this.options.y) ? this.center() : this.moveTo(Boxy._u(this.options.x) ? this.options.x : Boxy.DEFAULT_X,Boxy._u(this.options.y) ? this.options.y : Boxy.DEFAULT_Y), this.options.show && this.show()
}
var qq,
JSON,
vkkopts,
vkk,
dictionary,
tables;
/*@cc_on
(function(n, t)
{
function l(n)
{
var t=-1;
while(++t < c)
n.createElement(o[t])
}
if(!window.attachEvent || !t.createStyleSheet || !function()
{
var n=document.createElement("div");
return n.innerHTML = "<elem></elem>", n.childNodes.length !== 1
}())
return;
n.iepp = n.iepp || {};
var i=n.iepp,
e=i.html5elements || "abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|subline|summary|time|video",
o=e.split("|"),
c=o.length,
p=new RegExp("(^|\\s)(" + e + ")","gi"),
v=new RegExp("<(/*)(" + e + ")","gi"),
y=/^\s*[\{\}]\s*$/,
b=new RegExp("(^|[^\\n]*?\\s)(" + e + ")([^\\n]*)({[\\n\\w\\W]*?})","gi"),
h=t.createDocumentFragment(),
w=t.documentElement,
s=t.getElementsByTagName("script")[0].parentNode,
u=t.createElement("body"),
f=t.createElement("style"),
a=/print|all/,
r;
i.getCSS = function(n, t)
{
try
{
if(n + "" === undefined)
return""
}
catch(o)
{
return""
}
var u=-1,
e=n.length,
r,
f=[];
while(++u < e)
{
r = n[u];
if(r.disabled)
continue;
t = r.media || t, a.test(t) && f.push(i.getCSS(r.imports,t),r.cssText), t = "all"
}
return f.join("")
}, i.parseCSS = function(n)
{
var i=[],
t;
while((t = b.exec(n)) != null)
i.push(((y.exec(t[1]) ? "\n" : t[1]) + t[2] + t[3]).replace(p,"$1.iepp-$2") + t[4]);
return i.join("\n")
}, i.writeHTML = function()
{
var f=-1;
r = r || t.body;
while(++f < c)
{
var i=t.getElementsByTagName(o[f]),
e=i.length,
n=-1;
while(++n < e)
i[n].className.indexOf("iepp-") < 0 && (i[n].className += " iepp-" + o[f])
}
h.appendChild(r), w.appendChild(u), u.className = r.className, u.id = r.id, u.innerHTML = r.innerHTML.replace(v,"<$1font")
}, i._beforePrint = function()
{
if(i.disablePP)
return;
f.styleSheet.cssText = i.parseCSS(i.getCSS(t.styleSheets,"all")), i.writeHTML()
}, i.restoreHTML = function()
{
if(i.disablePP)
return;
u.swapNode(r)
}, i._afterPrint = function()
{
i.restoreHTML(), f.styleSheet.cssText = ""
}, l(t), l(h);
if(i.disablePP)
return;
s.insertBefore(f,s.firstChild), f.media = "print", f.className = "iepp-printshim", n.attachEvent("onbeforeprint",i._beforePrint), n.attachEvent("onafterprint",i._afterPrint)
})(this,document)@*/;
/*!
 * jQuery JavaScript Library v1.7.1
 * http://jquery.com/
 *
 * Copyright 2011, John Resig
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://jquery.org/license
 *
 * Includes Sizzle.js
 * http://sizzlejs.com/
 * Copyright 2011, The Dojo Foundation
 * Released under the MIT, BSD, and GPL Licenses.
 *
 * Date: Mon Nov 21 21:11:03 2011 -0500
 */
(function(n, t)
{
function eu(n)
{
var r=hr[n] = {},
t,
i;
for(n = n.split(/\s+/), t = 0, i = n.length; t < i; t++)
r[n[t]] = !0;
return r
}
function vr(n, r, u)
{
if(u === t && n.nodeType === 1)
{
var f="data-" + r.replace(lr,"-$1").toLowerCase();
u = n.getAttribute(f);
if(typeof u == "string")
{
try
{
u = u === "true" ? !0 : u === "false" ? !1 : u === "null" ? null : i.isNumeric(u) ? parseFloat(u) : cr.test(u) ? i.parseJSON(u) : u
}
catch(e){}
i.data(n,r,u)
}
else
u = t
}
return u
}
function st(n)
{
for(var t in n)
{
if(t === "data" && i.isEmptyObject(n[t]))
continue;
if(t !== "toJSON")
return!1
}
return!0
}
function er(n, t, r)
{
var e=t + "defer",
o=t + "queue",
u=t + "mark",
f=i._data(n,e);
!f || r !== "queue" && i._data(n,o) || r !== "mark" && i._data(n,u) || setTimeout(function()
{
i._data(n,o) || i._data(n,u) || (i.removeData(n,e,!0), f.fire())
},0)
}
function h()
{
return!1
}
function b()
{
return!0
}
function nr(n)
{
return!n || !n.parentNode || n.parentNode.nodeType === 11
}
function bi(n, t, r)
{
t = t || 0;
if(i.isFunction(t))
return i.grep(n,function(n, i)
{
var u=!!t.call(n,i,n);
return u === r
});
if(t.nodeType)
return i.grep(n,function(n)
{
return n === t === r
});
if(typeof t == "string")
{
var u=i.grep(n,function(n)
{
return n.nodeType === 1
});
if(kf.test(t))
return i.filter(t,u,!r);
t = i.filter(t,u)
}
return i.grep(n,function(n)
{
return i.inArray(n,t) >= 0 === r
})
}
function wi(n)
{
var i=ki.split("|"),
t=n.createDocumentFragment();
if(t.createElement)
while(i.length)
t.createElement(i.pop());
return t
}
function uf(n)
{
return i.nodeName(n,"table") ? n.getElementsByTagName("tbody")[0] || n.appendChild(n.ownerDocument.createElement("tbody")) : n
}
function dt(n, t)
{
if(t.nodeType !== 1 || !i.hasData(n))
return;
var f,
u,
o,
s=i._data(n),
e=i._data(t,s),
r=s.events;
if(r)
{
delete e.handle, e.events = {};
for(f in r)
for(u = 0, o = r[f].length; u < o; u++)
i.event.add(t,f + (r[f][u].namespace ? "." : "") + r[f][u].namespace,r[f][u],r[f][u].data)
}
e.data && (e.data = i.extend({},e.data))
}
function kt(n, t)
{
var r;
if(t.nodeType !== 1)
return;
t.clearAttributes && t.clearAttributes(), t.mergeAttributes && t.mergeAttributes(n), r = t.nodeName.toLowerCase(), r === "object" ? t.outerHTML = n.outerHTML : r === "input" && (n.type === "checkbox" || n.type === "radio") ? (n.checked && (t.defaultChecked = t.checked = n.checked), t.value !== n.value && (t.value = n.value)) : r === "option" ? t.selected = n.defaultSelected : (r === "input" || r === "textarea") && (t.defaultValue = n.defaultValue), t.removeAttribute(i.expando)
}
function w(n)
{
return typeof n.getElementsByTagName != "undefined" ? n.getElementsByTagName("*") : typeof n.querySelectorAll != "undefined" ? n.querySelectorAll("*") : []
}
function wt(n)
{
(n.type === "checkbox" || n.type === "radio") && (n.defaultChecked = n.checked)
}
function bt(n)
{
var t=(n.nodeName || "").toLowerCase();
t === "input" ? wt(n) : t !== "script" && typeof n.getElementsByTagName != "undefined" && i.grep(n.getElementsByTagName("input"),wt)
}
function sf(n)
{
var t=r.createElement("div");
return at.appendChild(t), t.innerHTML = n.outerHTML, t.firstChild
}
function bu(n, t)
{
t.src ? i.ajax({
url: t.src,
async: !1,
dataType: "script"
}) : i.globalEval((t.text || t.textContent || t.innerHTML || "").replace(ef,"/*$0*/")), t.parentNode && t.parentNode.removeChild(t)
}
function yt(n, t, r)
{
var u=t === "width" ? n.offsetWidth : n.offsetHeight,
e=t === "width" ? gu : lf,
f=0,
o=e.length;
if(u > 0)
{
if(r !== "border")
for(; f < o; f++)
r || (u -= parseFloat(i.css(n,"padding" + e[f])) || 0), r === "margin" ? u += parseFloat(i.css(n,r + e[f])) || 0 : u -= parseFloat(i.css(n,"border" + e[f] + "Width")) || 0;
return u + "px"
}
u = l(n,t,t), (u < 0 || u == null) && (u = n.style[t] || 0), u = parseFloat(u) || 0;
if(r)
for(; f < o; f++)
u += parseFloat(i.css(n,"padding" + e[f])) || 0, r !== "padding" && (u += parseFloat(i.css(n,"border" + e[f] + "Width")) || 0), r === "margin" && (u += parseFloat(i.css(n,r + e[f])) || 0);
return u + "px"
}
function ai(n)
{
return function(t, r)
{
typeof t != "string" && (r = t, t = "*");
if(i.isFunction(r))
for(var s=t.toLowerCase().split(hi), e=0, h=s.length, u, o, f; e < h; e++)
u = s[e], f = /^\+/.test(u), f && (u = u.substr(1) || "*"), o = n[u] = n[u] || [], o[f ? "unshift" : "push"](r)
}
}
function p(n, i, r, u, f, e)
{
f = f || i.dataTypes[0], e = e || {}, e[f] = !0;
for(var h=n[f], c=0, l=h ? h.length : 0, s=n === rt, o; c < l && (s || !o); c++)
o = h[c](i,r,u), typeof o == "string" && (!s || e[o] ? o = t : (i.dataTypes.unshift(o), o = p(n,i,r,u,o,e)));
return!s && o || e["*"] || (o = p(n,i,r,u,"*",e)), o
}
function lt(n, r)
{
var u,
f,
e=i.ajaxSettings.flatOptions || {};
for(u in r)
r[u] !== t && ((e[u] ? n : f || (f = {}))[u] = r[u]);
f && i.extend(!0,n,f)
}
function et(n, t, r, u)
{
if(i.isArray(t))
i.each(t,function(t, f)
{
r || gf.test(n) ? u(n,f) : et(n + "[" + (typeof f == "object" || i.isArray(f) ? t : "") + "]",f,r,u)
});
else if(r || t == null || typeof t != "object")
u(n,t);
else
for(var f in t)
et(n + "[" + f + "]",t[f],r,u)
}
function ru(n, i, r)
{
var h=n.contents,
f=n.dataTypes,
c=n.responseFields,
o,
u,
e,
s;
for(u in c)
u in r && (i[c[u]] = r[u]);
while(f[0] === "*")
f.shift(), o === t && (o = n.mimeType || i.getResponseHeader("content-type"));
if(o)
for(u in h)
if(h[u] && h[u].test(o))
{
f.unshift(u);
break
}
if(f[0] in r)
e = f[0];
else
{
for(u in r)
{
if(!f[0] || n.converters[u + " " + f[0]])
{
e = u;
break
}
s || (s = u)
}
e = e || s
}
if(e)
return e !== f[0] && f.unshift(e), r[e]
}
function iu(n, r)
{
n.dataFilter && (r = n.dataFilter(r,n.dataType));
for(var v=n.dataTypes, s={}, l, p=v.length, a, f=v[0], h, y, u, o, e, c=1; c < p; c++)
{
if(c === 1)
for(l in n.converters)
typeof l == "string" && (s[l.toLowerCase()] = n.converters[l]);
h = f, f = v[c];
if(f === "*")
f = h;
else if(h !== "*" && h !== f)
{
y = h + " " + f, u = s[y] || s["* " + f];
if(!u)
{
e = t;
for(o in s)
{
a = o.split(" ");
if(a[0] === h || a[0] === "*")
{
e = s[a[1] + " " + f];
if(e)
{
o = s[o], o === !0 ? u = e : e === !0 && (u = o);
break
}
}
}
}
u || e || i.error("No conversion from " + y.replace(" "," to ")), u !== !0 && (r = u ? u(r) : e(o(r)))
}
}
return r
}
function ti()
{
try
{
return new n.XMLHttpRequest
}
catch(t){}
}
function cu()
{
try
{
return new n.ActiveXObject("Microsoft.XMLHTTP")
}
catch(t){}
}
function oi()
{
return setTimeout(uu,0), tt = i.now()
}
function uu()
{
tt = t
}
function a(n, t)
{
var r={};
return i.each(ui.concat.apply([],ui.slice(0,t)),function()
{
r[this] = n
}), r
}
function ei(n)
{
if(!ht[n])
{
var e=r.body,
t=i("<" + n + ">").appendTo(e),
u=t.css("display");
t.remove(), (u === "none" || u === "") && (f || (f = r.createElement("iframe"), f.frameBorder = f.width = f.height = 0), e.appendChild(f), c && f.createElement || (c = (f.contentWindow || f.contentDocument).document, c.write((r.compatMode === "CSS1Compat" ? "<!doctype html>" : "") + "<html><body>"), c.close()), t = c.createElement(n), c.body.appendChild(t), u = i.css(t,"display"), e.removeChild(f)), ht[n] = u
}
return ht[n]
}
function it(n)
{
return i.isWindow(n) ? n : n.nodeType === 9 ? n.defaultView || n.parentWindow : !1
}
var r=n.document,
ou=n.navigator,
su=n.location,
i=function()
{
function l()
{
if(i.isReady)
return;
try
{
r.documentElement.doScroll("left")
}
catch(n)
{
setTimeout(l,1);
return
}
i.ready()
}
var i=function(n, t)
{
return new i.fn.init(n,t,p)
},
g=n.jQuery,
it=n.$,
p,
tt=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,
w=/\S/,
y=/^\s+/,
b=/\s+$/,
k=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,
rt=/^[\],:{}\s]*$/,
ft=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,
ot=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,
st=/(?:^|:|,)(?:\s*\[)+/g,
et=/(webkit)[ \/]([\w.]+)/,
ut=/(opera)(?:.*version)?[ \/]([\w.]+)/,
nt=/(msie) ([\w.]+)/,
at=/(mozilla)(?:.*? rv:([\w.]+))?/,
vt=/-([a-z]|[0-9])/ig,
lt=/^-ms-/,
ht=function(n, t)
{
return(t + "").toUpperCase()
},
ct=ou.userAgent,
e,
o,
u,
d=Object.prototype.toString,
s=Object.prototype.hasOwnProperty,
h=Array.prototype.push,
f=Array.prototype.slice,
a=String.prototype.trim,
v=Array.prototype.indexOf,
c={};
return i.fn = i.prototype = {
constructor: i,
init: function(n, u, f)
{
var o,
s,
e,
h;
if(!n)
return this;
if(n.nodeType)
return this.context = this[0] = n, this.length = 1, this;
if(n === "body" && !u && r.body)
return this.context = r, this[0] = r.body, this.selector = n, this.length = 1, this;
if(typeof n == "string")
{
o = n.charAt(0) !== "<" || n.charAt(n.length - 1) !== ">" || n.length < 3 ? tt.exec(n) : [null,n,null];
if(o && (o[1] || !u))
{
if(o[1])
return u = u instanceof i ? u[0] : u, h = u ? u.ownerDocument || u : r, e = k.exec(n), e ? i.isPlainObject(u) ? (n = [r.createElement(e[1])], i.fn.attr.call(n,u,!0)) : n = [h.createElement(e[1])] : (e = i.buildFragment([o[1]],[h]), n = (e.cacheable ? i.clone(e.fragment) : e.fragment).childNodes), i.merge(this,n);
s = r.getElementById(o[2]);
if(s && s.parentNode)
{
if(s.id !== o[2])
return f.find(n);
this.length = 1, this[0] = s
}
return this.context = r, this.selector = n, this
}
return!u || u.jquery ? (u || f).find(n) : this.constructor(u).find(n)
}
return i.isFunction(n) ? f.ready(n) : (n.selector !== t && (this.selector = n.selector, this.context = n.context), i.makeArray(n,this))
},
selector: "",
jquery: "1.7.1",
length: 0,
size: function()
{
return this.length
},
toArray: function()
{
return f.call(this,0)
},
get: function(n)
{
return n == null ? this.toArray() : n < 0 ? this[this.length + n] : this[n]
},
pushStack: function(n, t, r)
{
var u=this.constructor();
return i.isArray(n) ? h.apply(u,n) : i.merge(u,n), u.prevObject = this, u.context = this.context, t === "find" ? u.selector = this.selector + (this.selector ? " " : "") + r : t && (u.selector = this.selector + "." + t + "(" + r + ")"), u
},
each: function(n, t)
{
return i.each(this,n,t)
},
ready: function(n)
{
return i.bindReady(), o.add(n), this
},
eq: function(n)
{
return n = +n, n === -1 ? this.slice(n) : this.slice(n,n + 1)
},
first: function()
{
return this.eq(0)
},
last: function()
{
return this.eq(-1)
},
slice: function()
{
return this.pushStack(f.apply(this,arguments),"slice",f.call(arguments).join(","))
},
map: function(n)
{
return this.pushStack(i.map(this,function(t, i)
{
return n.call(t,i,t)
}))
},
end: function()
{
return this.prevObject || this.constructor(null)
},
push: h,
sort: [].sort,
splice: [].splice
}, i.fn.init.prototype = i.fn, i.extend = i.fn.extend = function()
{
var s,
e,
u,
r,
h,
c,
n=arguments[0] || {},
f=1,
l=arguments.length,
o=!1;
for(typeof n == "boolean" && (o = n, n = arguments[1] || {}, f = 2), typeof n == "object" || i.isFunction(n) || (n = {}), l === f && (n = this, --f); f < l; f++)
if((s = arguments[f]) != null)
for(e in s)
{
u = n[e], r = s[e];
if(n === r)
continue;
o && r && (i.isPlainObject(r) || (h = i.isArray(r))) ? (h ? (h = !1, c = u && i.isArray(u) ? u : []) : c = u && i.isPlainObject(u) ? u : {}, n[e] = i.extend(o,c,r)) : r !== t && (n[e] = r)
}
return n
}, i.extend({
noConflict: function(t)
{
return n.$ === i && (n.$ = it), t && n.jQuery === i && (n.jQuery = g), i
},
isReady: !1,
readyWait: 1,
holdReady: function(n)
{
n ? i.readyWait++ : i.ready(!0)
},
ready: function(n)
{
if(n === !0 && !--i.readyWait || n !== !0 && !i.isReady)
{
if(!r.body)
return setTimeout(i.ready,1);
i.isReady = !0;
if(n !== !0 && --i.readyWait > 0)
return;
o.fireWith(r,[i]), i.fn.trigger && i(r).trigger("ready").off("ready")
}
},
bindReady: function()
{
if(o)
return;
o = i.Callbacks("once memory");
if(r.readyState === "complete")
return setTimeout(i.ready,1);
if(r.addEventListener)
r.addEventListener("DOMContentLoaded",u,!1), n.addEventListener("load",i.ready,!1);
else if(r.attachEvent)
{
r.attachEvent("onreadystatechange",u), n.attachEvent("onload",i.ready);
var t=!1;
try
{
t = n.frameElement == null
}
catch(f){}
r.documentElement.doScroll && t && l()
}
},
isFunction: function(n)
{
return i.type(n) === "function"
},
isArray: Array.isArray || function(n)
{
return i.type(n) === "array"
},
isWindow: function(n)
{
return n && typeof n == "object" && "setInterval" in n
},
isNumeric: function(n)
{
return!isNaN(parseFloat(n)) && isFinite(n)
},
type: function(n)
{
return n == null ? String(n) : c[d.call(n)] || "object"
},
isPlainObject: function(n)
{
if(!n || i.type(n) !== "object" || n.nodeType || i.isWindow(n))
return!1;
try
{
if(n.constructor && !s.call(n,"constructor") && !s.call(n.constructor.prototype,"isPrototypeOf"))
return!1
}
catch(u)
{
return!1
}
var r;
for(r in n);
return r === t || s.call(n,r)
},
isEmptyObject: function(n)
{
for(var t in n)
return!1;
return!0
},
error: function(n)
{
throw new Error(n);
},
parseJSON: function(t)
{
if(typeof t != "string" || !t)
return null;
t = i.trim(t);
if(n.JSON && n.JSON.parse)
return n.JSON.parse(t);
if(rt.test(t.replace(ft,"@").replace(ot,"]").replace(st,"")))
return new Function("return " + t)();
i.error("Invalid JSON: " + t)
},
parseXML: function(r)
{
var u,
f;
try
{
n.DOMParser ? (f = new DOMParser, u = f.parseFromString(r,"text/xml")) : (u = new ActiveXObject("Microsoft.XMLDOM"), u.async = "false", u.loadXML(r))
}
catch(e)
{
u = t
}
return u && u.documentElement && !u.getElementsByTagName("parsererror").length || i.error("Invalid XML: " + r), u
},
noop: function(){},
globalEval: function(t)
{
t && w.test(t) && (n.execScript || function(t)
{
n.eval.call(n,t)
})(t)
},
camelCase: function(n)
{
return n.replace(lt,"ms-").replace(vt,ht)
},
nodeName: function(n, t)
{
return n.nodeName && n.nodeName.toUpperCase() === t.toUpperCase()
},
each: function(n, r, u)
{
var e,
f=0,
o=n.length,
s=o === t || i.isFunction(n);
if(u)
{
if(s)
{
for(e in n)
if(r.apply(n[e],u) === !1)
break
}
else
for(; f < o; )
if(r.apply(n[f++],u) === !1)
break
}
else if(s)
{
for(e in n)
if(r.call(n[e],e,n[e]) === !1)
break
}
else
for(; f < o; )
if(r.call(n[f],f,n[f++]) === !1)
break;
return n
},
trim: a ? function(n)
{
return n == null ? "" : a.call(n)
} : function(n)
{
return n == null ? "" : n.toString().replace(y,"").replace(b,"")
},
makeArray: function(n, t)
{
var u=t || [],
r;
return n != null && (r = i.type(n), n.length == null || r === "string" || r === "function" || r === "regexp" || i.isWindow(n) ? h.call(u,n) : i.merge(u,n)), u
},
inArray: function(n, t, i)
{
var r;
if(t)
{
if(v)
return v.call(t,n,i);
for(r = t.length, i = i ? i < 0 ? Math.max(0,r + i) : i : 0; i < r; i++)
if(i in t && t[i] === n)
return i
}
return-1
},
merge: function(n, i)
{
var u=n.length,
r=0,
f;
if(typeof i.length == "number")
for(f = i.length; r < f; r++)
n[u++] = i[r];
else
while(i[r] !== t)
n[u++] = i[r++];
return n.length = u, n
},
grep: function(n, t, i)
{
var f=[],
e,
r,
u;
for(i = !!i, r = 0, u = n.length; r < u; r++)
e = !!t(n[r],r), i !== e && f.push(n[r]);
return f
},
map: function(n, r, u)
{
var o,
h,
f=[],
s=0,
e=n.length,
c=n instanceof i || e !== t && typeof e == "number" && (e > 0 && n[0] && n[e - 1] || e === 0 || i.isArray(n));
if(c)
for(; s < e; s++)
o = r(n[s],s,u), o != null && (f[f.length] = o);
else
for(h in n)
o = r(n[h],h,u), o != null && (f[f.length] = o);
return f.concat.apply([],f)
},
guid: 1,
proxy: function(n, r)
{
var e,
o,
u;
return typeof r == "string" && (e = n[r], r = n, n = e), i.isFunction(n) ? (o = f.call(arguments,2), u = function()
{
return n.apply(r,o.concat(f.call(arguments)))
}, u.guid = n.guid = n.guid || u.guid || i.guid++, u) : t
},
access: function(n, r, u, f, e, o)
{
var c=n.length,
h,
s;
if(typeof r == "object")
{
for(h in r)
i.access(n,h,r[h],f,e,u);
return n
}
if(u !== t)
{
for(f = !o && f && i.isFunction(u), s = 0; s < c; s++)
e(n[s],r,f ? u.call(n[s],s,e(n[s],r)) : u,o);
return n
}
return c ? e(n[0],r) : t
},
now: function()
{
return+new Date
},
uaMatch: function(n)
{
n = n.toLowerCase();
var t=et.exec(n) || ut.exec(n) || nt.exec(n) || n.indexOf("compatible") < 0 && at.exec(n) || [];
return{
browser: t[1] || "",
version: t[2] || "0"
}
},
sub: function()
{
function n(t, i)
{
return new n.fn.init(t,i)
}
i.extend(!0,n,this), n.superclass = this, n.fn = n.prototype = this(), n.fn.constructor = n, n.sub = this.sub, n.fn.init = function(r, u)
{
return u && u instanceof i && !(u instanceof n) && (u = n(u)), i.fn.init.call(this,r,u,t)
}, n.fn.init.prototype = n.fn;
var t=n(r);
return n
},
browser: {}
}), i.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(n, t)
{
c["[object " + t + "]"] = t.toLowerCase()
}), e = i.uaMatch(ct), e.browser && (i.browser[e.browser] = !0, i.browser.version = e.version), i.browser.webkit && (i.browser.safari = !0), w.test(" ") && (y = /^[\s\xA0]+/, b = /[\s\xA0]+$/), p = i(r), r.addEventListener ? u = function()
{
r.removeEventListener("DOMContentLoaded",u,!1), i.ready()
} : r.attachEvent && (u = function()
{
r.readyState === "complete" && (r.detachEvent("onreadystatechange",u), i.ready())
}), i
}(),
hr={},
k,
cr,
lr,
ri,
y,
d,
ii,
v,
fi,
ot;
i.Callbacks = function(n)
{
n = n ? hr[n] || eu(n) : {};
var r=[],
f=[],
u,
s,
c,
h,
e,
l=function(t)
{
for(var u, e, h, f=0, s=t.length; f < s; f++)
u = t[f], e = i.type(u), e === "array" ? l(u) : e === "function" && (n.unique && o.has(u) || r.push(u))
},
a=function(t, i)
{
for(i = i || [], u = !n.memory || [t,i], s = !0, e = c || 0, c = 0, h = r.length; r && e < h; e++)
if(r[e].apply(t,i) === !1 && n.stopOnFalse)
{
u = !0;
break
}
s = !1, r && (n.once ? u === !0 ? o.disable() : r = [] : f && f.length && (u = f.shift(), o.fireWith(u[0],u[1])))
},
o={
add: function()
{
if(r)
{
var n=r.length;
l(arguments), s ? h = r.length : u && u !== !0 && (c = n, a(u[0],u[1]))
}
return this
},
remove: function()
{
var t;
if(r)
for(var u=arguments, i=0, f=u.length; i < f; i++)
for(t = 0; t < r.length; t++)
if(u[i] === r[t])
{
s && (t > h || (h--, t > e || e--)), r.splice(t--,1);
if(n.unique)
break
}
return this
},
has: function(n)
{
if(r)
for(var t=0, i=r.length; t < i; t++)
if(n === r[t])
return!0;
return!1
},
empty: function()
{
return r = [], this
},
disable: function()
{
return r = f = u = t, this
},
disabled: function()
{
return!r
},
lock: function()
{
return f = t, u && u !== !0 || o.disable(), this
},
locked: function()
{
return!f
},
fireWith: function(t, i)
{
return f && (s ? n.once || f.push([t,i]) : n.once && u || a(t,i)), this
},
fire: function()
{
return o.fireWith(this,arguments), this
},
fired: function()
{
return!!u
}
};
return o
}, k = [].slice, i.extend({
Deferred: function(n)
{
var u=i.Callbacks("once memory"),
o=i.Callbacks("once memory"),
e=i.Callbacks("memory"),
s="pending",
h={
resolve: u,
reject: o,
notify: e
},
f={
done: u.add,
fail: o.add,
progress: e.add,
state: function()
{
return s
},
isResolved: u.fired,
isRejected: o.fired,
then: function(n, i, r)
{
return t.done(n).fail(i).progress(r), this
},
always: function()
{
return t.done.apply(t,arguments).fail.apply(t,arguments), this
},
pipe: function(n, r, u)
{
return i.Deferred(function(f)
{
i.each({
done: [n,"resolve"],
fail: [r,"reject"],
progress: [u,"notify"]
},function(n, r)
{
var e=r[0],
o=r[1],
u;
i.isFunction(e) ? t[n](function()
{
u = e.apply(this,arguments), u && i.isFunction(u.promise) ? u.promise().then(f.resolve,f.reject,f.notify) : f[o + "With"](this === t ? f : this,[u])
}) : t[n](f[o])
})
}).promise()
},
promise: function(n)
{
if(n == null)
n = f;
else
for(var t in f)
n[t] = f[t];
return n
}
},
t=f.promise({}),
r;
for(r in h)
t[r] = h[r].fire, t[r + "With"] = h[r].fireWith;
return t.done(function()
{
s = "resolved"
},o.disable,e.lock).fail(function()
{
s = "rejected"
},u.disable,e.lock), n && n.call(t,t), t
},
when: function(n)
{
function h(n)
{
return function(i)
{
u[n] = arguments.length > 1 ? k.call(arguments,0) : i, --e || t.resolveWith(t,u)
}
}
function c(n)
{
return function(i)
{
o[n] = arguments.length > 1 ? k.call(arguments,0) : i, t.notifyWith(s,o)
}
}
var u=k.call(arguments,0),
r=0,
f=u.length,
o=new Array(f),
e=f,
l=f,
t=f <= 1 && n && i.isFunction(n.promise) ? n : i.Deferred(),
s=t.promise();
if(f > 1)
{
for(; r < f; r++)
u[r] && u[r].promise && i.isFunction(u[r].promise) ? u[r].promise().then(h(r),t.reject,c(r)) : --e;
e || t.resolveWith(t,u)
}
else
t !== n && t.resolveWith(t,f ? [n] : []);
return s
}
}), i.support = function()
{
var u,
y,
o,
v,
a,
f,
h,
e,
c,
k,
l,
p,
s,
t=r.createElement("div"),
b=r.documentElement;
t.setAttribute("className","t"), t.innerHTML = "   <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>", y = t.getElementsByTagName("*"), o = t.getElementsByTagName("a")[0];
if(!y || !y.length || !o)
return{};
v = r.createElement("select"), a = v.appendChild(r.createElement("option")), f = t.getElementsByTagName("input")[0], u = {
leadingWhitespace: t.firstChild.nodeType === 3,
tbody: !t.getElementsByTagName("tbody").length,
htmlSerialize: !!t.getElementsByTagName("link").length,
style: /top/.test(o.getAttribute("style")),
hrefNormalized: o.getAttribute("href") === "/a",
opacity: /^0.55/.test(o.style.opacity),
cssFloat: !!o.style.cssFloat,
checkOn: f.value === "on",
optSelected: a.selected,
getSetAttribute: t.className !== "t",
enctype: !!r.createElement("form").enctype,
html5Clone: r.createElement("nav").cloneNode(!0).outerHTML !== "<:nav></:nav>",
submitBubbles: !0,
changeBubbles: !0,
focusinBubbles: !1,
deleteExpando: !0,
noCloneEvent: !0,
inlineBlockNeedsLayout: !1,
shrinkWrapBlocks: !1,
reliableMarginRight: !0
}, f.checked = !0, u.noCloneChecked = f.cloneNode(!0).checked, v.disabled = !0, u.optDisabled = !a.disabled;
try
{
delete t.test
}
catch(w)
{
u.deleteExpando = !1
}
!t.addEventListener && t.attachEvent && t.fireEvent && (t.attachEvent("onclick",function()
{
u.noCloneEvent = !1
}), t.cloneNode(!0).fireEvent("onclick")), f = r.createElement("input"), f.value = "t", f.setAttribute("type","radio"), u.radioValue = f.value === "t", f.setAttribute("checked","checked"), t.appendChild(f), e = r.createDocumentFragment(), e.appendChild(t.lastChild), u.checkClone = e.cloneNode(!0).cloneNode(!0).lastChild.checked, u.appendChecked = f.checked, e.removeChild(f), e.appendChild(t), t.innerHTML = "", n.getComputedStyle && (h = r.createElement("div"), h.style.width = "0", h.style.marginRight = "0", t.style.width = "2px", t.appendChild(h), u.reliableMarginRight = (parseInt((n.getComputedStyle(h,null) || {marginRight: 0}).marginRight,10) || 0) === 0);
if(t.attachEvent)
for(p in{
submit: 1,
change: 1,
focusin: 1
})
l = "on" + p, s = l in t, s || (t.setAttribute(l,"return;"), s = typeof t[l] == "function"), u[p + "Bubbles"] = s;
return e.removeChild(t), e = v = a = h = t = f = null, i(function()
{
var f,
h,
n,
b,
w,
e,
y,
v,
l,
a,
p,
o=r.getElementsByTagName("body")[0];
if(!o)
return;
y = 1, v = "position:absolute;top:0;left:0;width:1px;height:1px;margin:0;", l = "visibility:hidden;border:0;", a = "style='" + v + "border:5px solid #000;padding:0;'", p = "<div " + a + "><div></div></div><table " + a + " cellpadding='0' cellspacing='0'><tr><td></td></tr></table>", f = r.createElement("div"), f.style.cssText = l + "width:0;height:0;position:static;top:0;margin-top:" + y + "px", o.insertBefore(f,o.firstChild), t = r.createElement("div"), f.appendChild(t), t.innerHTML = "<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>", c = t.getElementsByTagName("td"), s = c[0].offsetHeight === 0, c[0].style.display = "", c[1].style.display = "none", u.reliableHiddenOffsets = s && c[0].offsetHeight === 0, t.innerHTML = "", t.style.width = t.style.paddingLeft = "1px", i.boxModel = u.boxModel = t.offsetWidth === 2, typeof t.style.zoom != "undefined" && (t.style.display = "inline", t.style.zoom = 1, u.inlineBlockNeedsLayout = t.offsetWidth === 2, t.style.display = "", t.innerHTML = "<div style='width:4px;'></div>", u.shrinkWrapBlocks = t.offsetWidth !== 2), t.style.cssText = v + l, t.innerHTML = p, h = t.firstChild, n = h.firstChild, w = h.nextSibling.firstChild.firstChild, e = {
doesNotAddBorder: n.offsetTop !== 5,
doesAddBorderForTableAndCells: w.offsetTop === 5
}, n.style.position = "fixed", n.style.top = "20px", e.fixedPosition = n.offsetTop === 20 || n.offsetTop === 15, n.style.position = n.style.top = "", h.style.overflow = "hidden", h.style.position = "relative", e.subtractsBorderForOverflowNotVisible = n.offsetTop === -5, e.doesNotIncludeMarginInBodyOffset = o.offsetTop !== y, o.removeChild(f), t = f = null, i.extend(u,e)
}), u
}(), cr = /^(?:\{.*\}|\[.*\])$/, lr = /([A-Z])/g, i.extend({
cache: {},
uuid: 0,
expando: "jQuery" + (i.fn.jquery + Math.random()).replace(/\D/g,""),
noData: {
embed: !0,
object: "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",
applet: !0
},
hasData: function(n)
{
return n = n.nodeType ? i.cache[n[i.expando]] : n[i.expando], !!n && !st(n)
},
data: function(n, r, u, f)
{
if(!i.acceptData(n))
return;
var v,
s,
c,
h=i.expando,
y=typeof r == "string",
l=n.nodeType,
o=l ? i.cache : n,
e=l ? n[h] : n[h] && h,
a=r === "events";
if((!e || !o[e] || !a && !f && !o[e].data) && y && u === t)
return;
return e || (l ? n[h] = e = ++i.uuid : e = h), o[e] || (o[e] = {}, l || (o[e].toJSON = i.noop)), (typeof r == "object" || typeof r == "function") && (f ? o[e] = i.extend(o[e],r) : o[e].data = i.extend(o[e].data,r)), v = s = o[e], f || (s.data || (s.data = {}), s = s.data), u !== t && (s[i.camelCase(r)] = u), a && !s[r] ? v.events : (y ? (c = s[r], c == null && (c = s[i.camelCase(r)])) : c = s, c)
},
removeData: function(n, t, r)
{
if(!i.acceptData(n))
return;
var e,
s,
c,
o=i.expando,
h=n.nodeType,
u=h ? i.cache : n,
f=h ? n[o] : o;
if(!u[f])
return;
if(t)
{
e = r ? u[f] : u[f].data;
if(e)
{
for(i.isArray(t) || (t in e ? t = [t] : (t = i.camelCase(t), t = t in e ? [t] : t.split(" "))), s = 0, c = t.length; s < c; s++)
delete e[t[s]];
if(!(r ? st : i.isEmptyObject)(e))
return
}
}
if(!r)
{
delete u[f].data;
if(!st(u[f]))
return
}
i.support.deleteExpando || !u.setInterval ? delete u[f] : u[f] = null, h && (i.support.deleteExpando ? delete n[o] : n.removeAttribute ? n.removeAttribute(o) : n[o] = null)
},
_data: function(n, t, r)
{
return i.data(n,t,r,!0)
},
acceptData: function(n)
{
if(n.nodeName)
{
var t=i.noData[n.nodeName.toLowerCase()];
if(t)
return!(t === !0 || n.getAttribute("classid") !== t)
}
return!0
}
}), i.fn.extend({
data: function(n, r)
{
var u,
s,
e,
f=null,
o,
h;
if(typeof n == "undefined")
{
if(this.length)
{
f = i.data(this[0]);
if(this[0].nodeType === 1 && !i._data(this[0],"parsedAttrs"))
{
for(s = this[0].attributes, o = 0, h = s.length; o < h; o++)
e = s[o].name, e.indexOf("data-") === 0 && (e = i.camelCase(e.substring(5)), vr(this[0],e,f[e]));
i._data(this[0],"parsedAttrs",!0)
}
}
return f
}
return typeof n == "object" ? this.each(function()
{
i.data(this,n)
}) : (u = n.split("."), u[1] = u[1] ? "." + u[1] : "", r === t ? (f = this.triggerHandler("getData" + u[1] + "!",[u[0]]), f === t && this.length && (f = i.data(this[0],n), f = vr(this[0],n,f)), f === t && u[1] ? this.data(u[0]) : f) : this.each(function()
{
var f=i(this),
t=[u[0],r];
f.triggerHandler("setData" + u[1] + "!",t), i.data(this,n,r), f.triggerHandler("changeData" + u[1] + "!",t)
}))
},
removeData: function(n)
{
return this.each(function()
{
i.removeData(this,n)
})
}
}), i.extend({
_mark: function(n, t)
{
n && (t = (t || "fx") + "mark", i._data(n,t,(i._data(n,t) || 0) + 1))
},
_unmark: function(n, t, r)
{
n !== !0 && (r = t, t = n, n = !1);
if(t)
{
r = r || "fx";
var u=r + "mark",
f=n ? 0 : (i._data(t,u) || 1) - 1;
f ? i._data(t,u,f) : (i.removeData(t,u,!0), er(t,r,"mark"))
}
},
queue: function(n, t, r)
{
var u;
if(n)
return t = (t || "fx") + "queue", u = i._data(n,t), r && (!u || i.isArray(r) ? u = i._data(n,t,i.makeArray(r)) : u.push(r)), u || []
},
dequeue: function(n, t)
{
t = t || "fx";
var u=i.queue(n,t),
r=u.shift(),
f={};
r === "inprogress" && (r = u.shift()), r && (t === "fx" && u.unshift("inprogress"), i._data(n,t + ".run",f), r.call(n,function()
{
i.dequeue(n,t)
},f)), u.length || (i.removeData(n,t + "queue " + t + ".run",!0), er(n,t,"queue"))
}
}), i.fn.extend({
queue: function(n, r)
{
return typeof n != "string" && (r = n, n = "fx"), r === t ? i.queue(this[0],n) : this.each(function()
{
var t=i.queue(this,n,r);
n === "fx" && t[0] !== "inprogress" && i.dequeue(this,n)
})
},
dequeue: function(n)
{
return this.each(function()
{
i.dequeue(this,n)
})
},
delay: function(n, t)
{
return n = i.fx ? i.fx.speeds[n] || n : n, t = t || "fx", this.queue(t,function(t, i)
{
var r=setTimeout(t,n);
i.stop = function()
{
clearTimeout(r)
}
})
},
clearQueue: function(n)
{
return this.queue(n || "fx",[])
},
promise: function(n, r)
{
function o()
{
--h || c.resolveWith(u,[u])
}
typeof n != "string" && (r = n, n = t), n = n || "fx";
var c=i.Deferred(),
u=this,
f=u.length,
h=1,
s=n + "defer",
l=n + "queue",
a=n + "mark",
e;
while(f--)
(e = i.data(u[f],s,t,!0) || (i.data(u[f],l,t,!0) || i.data(u[f],a,t,!0)) && i.data(u[f],s,i.Callbacks("once memory"),!0)) && (h++, e.add(o));
return o(), c.promise()
}
});
var di=/[\n\t\r]/g,
nt=/\s+/,
vu=/\r/g,
yu=/^(?:button|input)$/i,
au=/^(?:button|input|object|select|textarea)$/i,
lu=/^a(?:rea)?$/i,
ur=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,
fr=i.support.getSetAttribute,
e,
rr,
ir;
i.fn.extend({
attr: function(n, t)
{
return i.access(this,n,t,!0,i.attr)
},
removeAttr: function(n)
{
return this.each(function()
{
i.removeAttr(this,n)
})
},
prop: function(n, t)
{
return i.access(this,n,t,!0,i.prop)
},
removeProp: function(n)
{
return n = i.propFix[n] || n, this.each(function()
{
try
{
this[n] = t, delete this[n]
}
catch(i){}
})
},
addClass: function(n)
{
var u,
e,
s,
t,
f,
r,
o;
if(i.isFunction(n))
return this.each(function(t)
{
i(this).addClass(n.call(this,t,this.className))
});
if(n && typeof n == "string")
for(u = n.split(nt), e = 0, s = this.length; e < s; e++)
{
t = this[e];
if(t.nodeType === 1)
if(t.className || u.length !== 1)
{
for(f = " " + t.className + " ", r = 0, o = u.length; r < o; r++)
~f.indexOf(" " + u[r] + " ") || (f += u[r] + " ");
t.className = i.trim(f)
}
else
t.className = n
}
return this
},
removeClass: function(n)
{
var o,
e,
h,
r,
u,
f,
s;
if(i.isFunction(n))
return this.each(function(t)
{
i(this).removeClass(n.call(this,t,this.className))
});
if(n && typeof n == "string" || n === t)
for(o = (n || "").split(nt), e = 0, h = this.length; e < h; e++)
{
r = this[e];
if(r.nodeType === 1 && r.className)
if(n)
{
for(u = (" " + r.className + " ").replace(di," "), f = 0, s = o.length; f < s; f++)
u = u.replace(" " + o[f] + " "," ");
r.className = i.trim(u)
}
else
r.className = ""
}
return this
},
toggleClass: function(n, t)
{
var r=typeof n,
u=typeof t == "boolean";
return i.isFunction(n) ? this.each(function(r)
{
i(this).toggleClass(n.call(this,r,this.className,t),t)
}) : this.each(function()
{
if(r === "string")
{
var e,
h=0,
o=i(this),
f=t,
s=n.split(nt);
while(e = s[h++])
f = u ? f : !o.hasClass(e), o[f ? "addClass" : "removeClass"](e)
}
else
(r === "undefined" || r === "boolean") && (this.className && i._data(this,"__className__",this.className), this.className = this.className || n === !1 ? "" : i._data(this,"__className__") || "")
})
},
hasClass: function(n)
{
for(var r=" " + n + " ", t=0, i=this.length; t < i; t++)
if(this[t].nodeType === 1 && (" " + this[t].className + " ").replace(di," ").indexOf(r) > -1)
return!0;
return!1
},
val: function(n)
{
var r,
u,
e,
f=this[0];
return arguments.length ? (e = i.isFunction(n), this.each(function(u)
{
var o=i(this),
f;
if(this.nodeType !== 1)
return;
f = e ? n.call(this,u,o.val()) : n, f == null ? f = "" : typeof f == "number" ? f += "" : i.isArray(f) && (f = i.map(f,function(n)
{
return n == null ? "" : n + ""
})), r = i.valHooks[this.nodeName.toLowerCase()] || i.valHooks[this.type], r && "set" in r && r.set(this,f,"value") !== t || (this.value = f)
})) : f ? (r = i.valHooks[f.nodeName.toLowerCase()] || i.valHooks[f.type], r && "get" in r && (u = r.get(f,"value")) !== t ? u : (u = f.value, typeof u == "string" ? u.replace(vu,"") : u == null ? "" : u)) : void 0
}
}), i.extend({
valHooks: {
option: {get: function(n)
{
var t=n.attributes.value;
return!t || t.specified ? n.value : n.text
}},
select: {
get: function(n)
{
var o,
e,
h,
t,
r=n.selectedIndex,
s=[],
u=n.options,
f=n.type === "select-one";
if(r < 0)
return null;
for(e = f ? r : 0, h = f ? r + 1 : u.length; e < h; e++)
{
t = u[e];
if(t.selected && (i.support.optDisabled ? !t.disabled : t.getAttribute("disabled") === null) && (!t.parentNode.disabled || !i.nodeName(t.parentNode,"optgroup")))
{
o = i(t).val();
if(f)
return o;
s.push(o)
}
}
return f && !s.length && u.length ? i(u[r]).val() : s
},
set: function(n, t)
{
var r=i.makeArray(t);
return i(n).find("option").each(function()
{
this.selected = i.inArray(i(this).val(),r) >= 0
}), r.length || (n.selectedIndex = -1), r
}
}
},
attrFn: {
val: !0,
css: !0,
html: !0,
text: !0,
data: !0,
width: !0,
height: !0,
offset: !0
},
attr: function(n, r, u, f)
{
var s,
o,
c,
h=n.nodeType;
if(!n || h === 3 || h === 8 || h === 2)
return;
if(f && r in i.attrFn)
return i(n)[r](u);
if(typeof n.getAttribute == "undefined")
return i.prop(n,r,u);
c = h !== 1 || !i.isXMLDoc(n), c && (r = r.toLowerCase(), o = i.attrHooks[r] || (ur.test(r) ? rr : e));
if(u !== t)
{
if(u === null)
{
i.removeAttr(n,r);
return
}
return o && "set" in o && c && (s = o.set(n,u,r)) !== t ? s : (n.setAttribute(r,"" + u), u)
}
return o && "get" in o && c && (s = o.get(n,r)) !== null ? s : (s = n.getAttribute(r), s === null ? t : s)
},
removeAttr: function(n, t)
{
var u,
e,
r,
o,
f=0;
if(t && n.nodeType === 1)
for(e = t.toLowerCase().split(nt), o = e.length; f < o; f++)
r = e[f], r && (u = i.propFix[r] || r, i.attr(n,r,""), n.removeAttribute(fr ? r : u), ur.test(r) && u in n && (n[u] = !1))
},
attrHooks: {
type: {set: function(n, t)
{
if(yu.test(n.nodeName) && n.parentNode)
i.error("type property can't be changed");
else if(!i.support.radioValue && t === "radio" && i.nodeName(n,"input"))
{
var r=n.value;
return n.setAttribute("type",t), r && (n.value = r), t
}
}},
value: {
get: function(n, t)
{
return e && i.nodeName(n,"button") ? e.get(n,t) : t in n ? n.value : null
},
set: function(n, t, r)
{
if(e && i.nodeName(n,"button"))
return e.set(n,t,r);
n.value = t
}
}
},
propFix: {
tabindex: "tabIndex",
readonly: "readOnly",
"for": "htmlFor",
"class": "className",
maxlength: "maxLength",
cellspacing: "cellSpacing",
cellpadding: "cellPadding",
rowspan: "rowSpan",
colspan: "colSpan",
usemap: "useMap",
frameborder: "frameBorder",
contenteditable: "contentEditable"
},
prop: function(n, r, u)
{
var o,
f,
s,
e=n.nodeType;
if(n && e !== 3 && e !== 8 && e !== 2)
return s = e !== 1 || !i.isXMLDoc(n), s && (r = i.propFix[r] || r, f = i.propHooks[r]), u !== t ? f && "set" in f && (o = f.set(n,u,r)) !== t ? o : n[r] = u : f && "get" in f && (o = f.get(n,r)) !== null ? o : n[r]
},
propHooks: {tabIndex: {get: function(n)
{
var i=n.getAttributeNode("tabindex");
return i && i.specified ? parseInt(i.value,10) : au.test(n.nodeName) || lu.test(n.nodeName) && n.href ? 0 : t
}}}
}), i.attrHooks.tabindex = i.propHooks.tabIndex, rr = {
get: function(n, r)
{
var f,
u=i.prop(n,r);
return u === !0 || typeof u != "boolean" && (f = n.getAttributeNode(r)) && f.nodeValue !== !1 ? r.toLowerCase() : t
},
set: function(n, t, r)
{
var u;
return t === !1 ? i.removeAttr(n,r) : (u = i.propFix[r] || r, u in n && (n[u] = !0), n.setAttribute(r,r.toLowerCase())), r
}
}, fr || (ir = {
name: !0,
id: !0
}, e = i.valHooks.button = {
get: function(n, i)
{
var r;
return r = n.getAttributeNode(i), r && (ir[i] ? r.nodeValue !== "" : r.specified) ? r.nodeValue : t
},
set: function(n, t, i)
{
var u=n.getAttributeNode(i);
return u || (u = r.createAttribute(i), n.setAttributeNode(u)), u.nodeValue = t + ""
}
}, i.attrHooks.tabindex.set = e.set, i.each(["width","height"],function(n, t)
{
i.attrHooks[t] = i.extend(i.attrHooks[t],{set: function(n, i)
{
if(i === "")
return n.setAttribute(t,"auto"), i
}})
}), i.attrHooks.contenteditable = {
get: e.get,
set: function(n, t, i)
{
t === "" && (t = "false"), e.set(n,t,i)
}
}), i.support.hrefNormalized || i.each(["href","src","width","height"],function(n, r)
{
i.attrHooks[r] = i.extend(i.attrHooks[r],{get: function(n)
{
var i=n.getAttribute(r,2);
return i === null ? t : i
}})
}), i.support.style || (i.attrHooks.style = {
get: function(n)
{
return n.style.cssText.toLowerCase() || t
},
set: function(n, t)
{
return n.style.cssText = "" + t
}
}), i.support.optSelected || (i.propHooks.selected = i.extend(i.propHooks.selected,{get: function(n)
{
var t=n.parentNode;
return t && (t.selectedIndex, t.parentNode && t.parentNode.selectedIndex), null
}})), i.support.enctype || (i.propFix.enctype = "encoding"), i.support.checkOn || i.each(["radio","checkbox"],function()
{
i.valHooks[this] = {get: function(n)
{
return n.getAttribute("value") === null ? "on" : n.value
}}
}), i.each(["radio","checkbox"],function()
{
i.valHooks[this] = i.extend(i.valHooks[this],{set: function(n, t)
{
if(i.isArray(t))
return n.checked = i.inArray(i(n).val(),t) >= 0
}})
});
var ct=/^(?:textarea|input|select)$/i,
gi=/^([^\.]*)?(?:\.(.+))?$/,
nu=/\bhover(\.\S+)?\b/,
kr=/^key/,
dr=/^(?:mouse|contextmenu)|click/,
yr=/^(?:focusinfocus|focusoutblur)$/,
gr=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,
tu=function(n)
{
var t=gr.exec(n);
return t && (t[1] = (t[1] || "").toLowerCase(), t[3] = t[3] && new RegExp("(?:^|\\s)" + t[3] + "(?:\\s|$)")), t
},
wr=function(n, t)
{
var i=n.attributes || {};
return(!t[1] || n.nodeName.toLowerCase() === t[1]) && (!t[2] || (i.id || {}).value === t[2]) && (!t[3] || t[3].test((i["class"] || {}).value))
},
sr=function(n)
{
return i.event.special.hover ? n : n.replace(nu,"mouseenter$1 mouseleave$1")
};
i.event = {
add: function(n, r, u, f, e)
{
var v,
h,
a,
p,
y,
o,
w,
l,
b,
k,
c,
s;
if(n.nodeType === 3 || n.nodeType === 8 || !r || !u || !(v = i._data(n)))
return;
for(u.handler && (b = u, u = b.handler), u.guid || (u.guid = i.guid++), a = v.events, a || (v.events = a = {}), h = v.handle, h || (v.handle = h = function(n)
{
return typeof i != "undefined" && (!n || i.event.triggered !== n.type) ? i.event.dispatch.apply(h.elem,arguments) : t
}, h.elem = n), r = i.trim(sr(r)).split(" "), p = 0; p < r.length; p++)
y = gi.exec(r[p]) || [], o = y[1], w = (y[2] || "").split(".").sort(), s = i.event.special[o] || {}, o = (e ? s.delegateType : s.bindType) || o, s = i.event.special[o] || {}, l = i.extend({
type: o,
origType: y[1],
data: f,
handler: u,
guid: u.guid,
selector: e,
quick: tu(e),
namespace: w.join(".")
},b), c = a[o], c || (c = a[o] = [], c.delegateCount = 0, s.setup && s.setup.call(n,f,w,h) !== !1 || (n.addEventListener ? n.addEventListener(o,h,!1) : n.attachEvent && n.attachEvent("on" + o,h))), s.add && (s.add.call(n,l), l.handler.guid || (l.handler.guid = u.guid)), e ? c.splice(c.delegateCount++,0,l) : c.push(l), i.event.global[o] = !0;
n = null
},
global: {},
remove: function(n, t, r, u, f)
{
var y=i.hasData(n) && i._data(n),
v,
p,
e,
k,
h,
b,
l,
a,
c,
w,
o,
s;
if(!y || !(a = y.events))
return;
for(t = i.trim(sr(t || "")).split(" "), v = 0; v < t.length; v++)
{
p = gi.exec(t[v]) || [], e = k = p[1], h = p[2];
if(!e)
{
for(e in a)
i.event.remove(n,e + t[v],r,u,!0);
continue
}
for(c = i.event.special[e] || {}, e = (u ? c.delegateType : c.bindType) || e, o = a[e] || [], b = o.length, h = h ? new RegExp("(^|\\.)" + h.split(".").sort().join("\\.(?:.*\\.)?") + "(\\.|$)") : null, l = 0; l < o.length; l++)
s = o[l], (f || k === s.origType) && (!r || r.guid === s.guid) && (!h || h.test(s.namespace)) && (!u || u === s.selector || u === "**" && s.selector) && (o.splice(l--,1), s.selector && o.delegateCount--, c.remove && c.remove.call(n,s));
o.length === 0 && b !== o.length && (c.teardown && c.teardown.call(n,h) !== !1 || i.removeEvent(n,e,y.handle), delete a[e])
}
i.isEmptyObject(a) && (w = y.handle, w && (w.elem = null), i.removeData(n,["events","handle"],!0))
},
customEvent: {
getData: !0,
setData: !0,
changeData: !0
},
trigger: function(r, u, f, e)
{
if(f && (f.nodeType === 3 || f.nodeType === 8))
return;
var o=r.type || r,
w=[],
p,
k,
c,
s,
h,
a,
l,
v,
y,
b;
if(yr.test(o + i.event.triggered))
return;
o.indexOf("!") < 0 || (o = o.slice(0,-1), k = !0), o.indexOf(".") < 0 || (w = o.split("."), o = w.shift(), w.sort());
if((!f || i.event.customEvent[o]) && !i.event.global[o])
return;
r = typeof r == "object" ? r[i.expando] ? r : new i.Event(o,r) : new i.Event(o), r.type = o, r.isTrigger = !0, r.exclusive = k, r.namespace = w.join("."), r.namespace_re = r.namespace ? new RegExp("(^|\\.)" + w.join("\\.(?:.*\\.)?") + "(\\.|$)") : null, a = o.indexOf(":") < 0 ? "on" + o : "";
if(!f)
{
p = i.cache;
for(c in p)
p[c].events && p[c].events[o] && i.event.trigger(r,u,p[c].handle.elem,!0);
return
}
r.result = t, r.target || (r.target = f), u = u != null ? i.makeArray(u) : [], u.unshift(r), l = i.event.special[o] || {};
if(l.trigger && l.trigger.apply(f,u) === !1)
return;
y = [[f,l.bindType || o]];
if(!e && !l.noBubble && !i.isWindow(f))
{
for(b = l.delegateType || o, s = yr.test(b + o) ? f : f.parentNode, h = null; s; s = s.parentNode)
y.push([s,b]), h = s;
h && h === f.ownerDocument && y.push([h.defaultView || h.parentWindow || n,b])
}
for(c = 0; c < y.length && !r.isPropagationStopped(); c++)
s = y[c][0], r.type = y[c][1], v = (i._data(s,"events") || {})[r.type] && i._data(s,"handle"), v && v.apply(s,u), v = a && s[a], v && i.acceptData(s) && v.apply(s,u) === !1 && r.preventDefault();
return r.type = o, e || r.isDefaultPrevented() || l._default && l._default.apply(f.ownerDocument,u) !== !1 || o === "click" && i.nodeName(f,"a") || !i.acceptData(f) || a && f[o] && (o !== "focus" && o !== "blur" || r.target.offsetWidth !== 0) && !i.isWindow(f) && (h = f[a], h && (f[a] = null), i.event.triggered = o, f[o](), i.event.triggered = t, h && (f[a] = h)), r.result
},
dispatch: function(r)
{
r = i.event.fix(r || n.event);
var h=(i._data(this,"events") || {})[r.type] || [],
p=h.delegateCount,
b=[].slice.call(arguments,0),
k=!r.exclusive && !r.namespace,
y=[],
f,
w,
e,
a,
v,
c,
s,
l,
u,
o,
d;
b[0] = r, r.delegateTarget = this;
if(p && !r.target.disabled && !(r.button && r.type === "click"))
for(a = i(this), a.context = this.ownerDocument || this, e = r.target; e != this; e = e.parentNode || this)
{
for(c = {}, l = [], a[0] = e, f = 0; f < p; f++)
u = h[f], o = u.selector, c[o] === t && (c[o] = u.quick ? wr(e,u.quick) : a.is(o)), c[o] && l.push(u);
l.length && y.push({
elem: e,
matches: l
})
}
for(h.length > p && y.push({
elem: this,
matches: h.slice(p)
}), f = 0; f < y.length && !r.isPropagationStopped(); f++)
for(s = y[f], r.currentTarget = s.elem, w = 0; w < s.matches.length && !r.isImmediatePropagationStopped(); w++)
u = s.matches[w], (k || !r.namespace && !u.namespace || r.namespace_re && r.namespace_re.test(u.namespace)) && (r.data = u.data, r.handleObj = u, v = ((i.event.special[u.origType] || {}).handle || u.handler).apply(s.elem,b), v !== t && (r.result = v, v === !1 && (r.preventDefault(), r.stopPropagation())));
return r.result
},
props: "attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),
fixHooks: {},
keyHooks: {
props: "char charCode key keyCode".split(" "),
filter: function(n, t)
{
return n.which == null && (n.which = t.charCode != null ? t.charCode : t.keyCode), n
}
},
mouseHooks: {
props: "button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),
filter: function(n, i)
{
var s,
f,
u,
e=i.button,
o=i.fromElement;
return n.pageX == null && i.clientX != null && (s = n.target.ownerDocument || r, f = s.documentElement, u = s.body, n.pageX = i.clientX + (f && f.scrollLeft || u && u.scrollLeft || 0) - (f && f.clientLeft || u && u.clientLeft || 0), n.pageY = i.clientY + (f && f.scrollTop || u && u.scrollTop || 0) - (f && f.clientTop || u && u.clientTop || 0)), !n.relatedTarget && o && (n.relatedTarget = o === n.target ? i.toElement : o), n.which || e === t || (n.which = e & 1 ? 1 : e & 2 ? 3 : e & 4 ? 2 : 0), n
}
},
fix: function(n)
{
if(n[i.expando])
return n;
var e,
o,
u=n,
f=i.event.fixHooks[n.type] || {},
s=f.props ? this.props.concat(f.props) : this.props;
for(n = i.Event(u), e = s.length; e; )
o = s[--e], n[o] = u[o];
return n.target || (n.target = u.srcElement || r), n.target.nodeType === 3 && (n.target = n.target.parentNode), n.metaKey === t && (n.metaKey = n.ctrlKey), f.filter ? f.filter(n,u) : n
},
special: {
ready: {setup: i.bindReady},
load: {noBubble: !0},
focus: {delegateType: "focusin"},
blur: {delegateType: "focusout"},
beforeunload: {
setup: function(n, t, r)
{
i.isWindow(this) && (this.onbeforeunload = r)
},
teardown: function(n, t)
{
this.onbeforeunload === t && (this.onbeforeunload = null)
}
}
},
simulate: function(n, t, r, u)
{
var f=i.extend(new i.Event,r,{
type: n,
isSimulated: !0,
originalEvent: {}
});
u ? i.event.trigger(f,null,t) : i.event.dispatch.call(t,f), f.isDefaultPrevented() && r.preventDefault()
}
}, i.event.handle = i.event.dispatch, i.removeEvent = r.removeEventListener ? function(n, t, i)
{
n.removeEventListener && n.removeEventListener(t,i,!1)
} : function(n, t, i)
{
n.detachEvent && n.detachEvent("on" + t,i)
}, i.Event = function(n, t)
{
if(!(this instanceof i.Event))
return new i.Event(n,t);
n && n.type ? (this.originalEvent = n, this.type = n.type, this.isDefaultPrevented = n.defaultPrevented || n.returnValue === !1 || n.getPreventDefault && n.getPreventDefault() ? b : h) : this.type = n, t && i.extend(this,t), this.timeStamp = n && n.timeStamp || i.now(), this[i.expando] = !0
}, i.Event.prototype = {
preventDefault: function()
{
this.isDefaultPrevented = b;
var n=this.originalEvent;
if(!n)
return;
n.preventDefault ? n.preventDefault() : n.returnValue = !1
},
stopPropagation: function()
{
this.isPropagationStopped = b;
var n=this.originalEvent;
if(!n)
return;
n.stopPropagation && n.stopPropagation(), n.cancelBubble = !0
},
stopImmediatePropagation: function()
{
this.isImmediatePropagationStopped = b, this.stopPropagation()
},
isDefaultPrevented: h,
isPropagationStopped: h,
isImmediatePropagationStopped: h
}, i.each({
mouseenter: "mouseover",
mouseleave: "mouseout"
},function(n, t)
{
i.event.special[n] = {
delegateType: t,
bindType: t,
handle: function(n)
{
var e=this,
u=n.relatedTarget,
r=n.handleObj,
o=r.selector,
f;
return u && (u === e || i.contains(e,u)) || (n.type = r.origType, f = r.handler.apply(this,arguments), n.type = t), f
}
}
}), i.support.submitBubbles || (i.event.special.submit = {
setup: function()
{
if(i.nodeName(this,"form"))
return!1;
i.event.add(this,"click._submit keypress._submit",function(n)
{
var u=n.target,
r=i.nodeName(u,"input") || i.nodeName(u,"button") ? u.form : t;
r && !r._submit_attached && (i.event.add(r,"submit._submit",function(n)
{
this.parentNode && !n.isTrigger && i.event.simulate("submit",this.parentNode,n,!0)
}), r._submit_attached = !0)
})
},
teardown: function()
{
if(i.nodeName(this,"form"))
return!1;
i.event.remove(this,"._submit")
}
}), i.support.changeBubbles || (i.event.special.change = {
setup: function()
{
if(ct.test(this.nodeName))
return(this.type === "checkbox" || this.type === "radio") && (i.event.add(this,"propertychange._change",function(n)
{
n.originalEvent.propertyName === "checked" && (this._just_changed = !0)
}), i.event.add(this,"click._change",function(n)
{
this._just_changed && !n.isTrigger && (this._just_changed = !1, i.event.simulate("change",this,n,!0))
})), !1;
i.event.add(this,"beforeactivate._change",function(n)
{
var t=n.target;
ct.test(t.nodeName) && !t._change_attached && (i.event.add(t,"change._change",function(n)
{
!this.parentNode || n.isSimulated || n.isTrigger || i.event.simulate("change",this.parentNode,n,!0)
}), t._change_attached = !0)
})
},
handle: function(n)
{
var t=n.target;
if(this !== t || n.isSimulated || n.isTrigger || t.type !== "radio" && t.type !== "checkbox")
return n.handleObj.handler.apply(this,arguments)
},
teardown: function()
{
return i.event.remove(this,"._change"), ct.test(this.nodeName)
}
}), i.support.focusinBubbles || i.each({
focus: "focusin",
blur: "focusout"
},function(n, t)
{
var f=0,
u=function(n)
{
i.event.simulate(t,n.target,i.event.fix(n),!0)
};
i.event.special[t] = {
setup: function()
{
f++ == 0 && r.addEventListener(n,u,!0)
},
teardown: function()
{
--f == 0 && r.removeEventListener(n,u,!0)
}
}
}), i.fn.extend({
on: function(n, r, u, f, e)
{
var o,
s;
if(typeof n == "object")
{
typeof r != "string" && (u = r, r = t);
for(s in n)
this.on(s,r,u,n[s],e);
return this
}
u == null && f == null ? (f = r, u = r = t) : f == null && (typeof r == "string" ? (f = u, u = t) : (f = u, u = r, r = t));
if(f === !1)
f = h;
else if(!f)
return this;
return e === 1 && (o = f, f = function(n)
{
return i().off(n), o.apply(this,arguments)
}, f.guid = o.guid || (o.guid = i.guid++)), this.each(function()
{
i.event.add(this,n,f,u,r)
})
},
one: function(n, t, i, r)
{
return this.on.call(this,n,t,i,r,1)
},
off: function(n, r, u)
{
var f,
e;
if(n && n.preventDefault && n.handleObj)
return f = n.handleObj, i(n.delegateTarget).off(f.namespace ? f.type + "." + f.namespace : f.type,f.selector,f.handler), this;
if(typeof n == "object")
{
for(e in n)
this.off(e,r,n[e]);
return this
}
return(r === !1 || typeof r == "function") && (u = r, r = t), u === !1 && (u = h), this.each(function()
{
i.event.remove(this,n,u,r)
})
},
bind: function(n, t, i)
{
return this.on(n,null,t,i)
},
unbind: function(n, t)
{
return this.off(n,null,t)
},
live: function(n, t, r)
{
i(this.context).on(n,this.selector,t,r);
return this
},
die: function(n, t)
{
return i(this.context).off(n,this.selector || "**",t), this
},
delegate: function(n, t, i, r)
{
return this.on(t,n,i,r)
},
undelegate: function(n, t, i)
{
return arguments.length == 1 ? this.off(n,"**") : this.off(t,n,i)
},
trigger: function(n, t)
{
return this.each(function()
{
i.event.trigger(n,t,this)
})
},
triggerHandler: function(n, t)
{
if(this[0])
return i.event.trigger(n,t,this[0],!0)
},
toggle: function(n)
{
var r=arguments,
f=n.guid || i.guid++,
t=0,
u=function(u)
{
var f=(i._data(this,"lastToggle" + n.guid) || 0) % t;
return i._data(this,"lastToggle" + n.guid,f + 1), u.preventDefault(), r[f].apply(this,arguments) || !1
};
u.guid = f;
while(t < r.length)
r[t++].guid = f;
return this.click(u)
},
hover: function(n, t)
{
return this.mouseenter(n).mouseleave(t || n)
}
}), i.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(n, t)
{
i.fn[t] = function(n, i)
{
return i == null && (i = n, n = null), arguments.length > 0 ? this.on(t,null,n,i) : this.trigger(t)
}, i.attrFn && (i.attrFn[t] = !0), kr.test(t) && (i.event.fixHooks[t] = i.event.keyHooks), dr.test(t) && (i.event.fixHooks[t] = i.event.mouseHooks)
});
/*!
 * Sizzle CSS Selector Engine
 *  Copyright 2011, The Dojo Foundation
 *  Released under the MIT, BSD, and GPL Licenses.
 *  More information: http://sizzlejs.com/
 */
(function()
{
function k(n, t, i, r, u, f)
{
for(var o, h, s=0, c=r.length; s < c; s++)
{
o = r[s];
if(o)
{
h = !1, o = o[n];
while(o)
{
if(o[e] === i)
{
h = r[o.sizset];
break
}
o.nodeType !== 1 || f || (o[e] = i, o.sizset = s);
if(o.nodeName.toLowerCase() === t)
{
h = o;
break
}
o = o[n]
}
r[s] = h
}
}
}
function b(t, i, r, u, f, o)
{
for(var s, c, h=0, l=u.length; h < l; h++)
{
s = u[h];
if(s)
{
c = !1, s = s[t];
while(s)
{
if(s[e] === r)
{
c = u[s.sizset];
break
}
if(s.nodeType === 1)
{
o || (s[e] = r, s.sizset = h);
if(typeof i != "string")
{
if(s === i)
{
c = !0;
break
}
}
else if(n.filter(i,[s]).length > 0)
{
c = s;
break
}
}
s = s[t]
}
u[h] = c
}
}
}
var p=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,
e="sizcache" + (Math.random() + "").replace(".",""),
y=0,
d=Object.prototype.toString,
l=!1,
g=!0,
o=/\\/g,
it=/\r\n/g,
c=/\W/,
n,
s,
f,
a,
h,
v;
[0,0].sort(function()
{
return g = !1, 0
}), n = function(t, i, e, o)
{
var it;
e = e || [], i = i || r, it = i;
if(i.nodeType !== 1 && i.nodeType !== 9)
return[];
if(!t || typeof t != "string")
return e;
var y,
a,
h,
g,
l,
w,
b,
c,
rt=!0,
k=n.isXML(i),
s=[],
tt=t;
do
{
p.exec(""), y = p.exec(tt);
if(y)
{
tt = y[3], s.push(y[1]);
if(y[2])
{
g = y[3];
break
}
}
} while(y);
if(s.length > 1 && nt.exec(t))
if(s.length === 2 && u.relative[s[0]])
a = v(s[0] + s[1],i,o);
else
{
a = u.relative[s[0]] ? [i] : n(s.shift(),i);
while(s.length)
t = s.shift(), u.relative[t] && (t += s.shift()), a = v(t,a,o)
}
else
{
o || s.length <= 1 || i.nodeType !== 9 || k || !u.match.ID.test(s[0]) || u.match.ID.test(s[s.length - 1]) || (l = n.find(s.shift(),i,k), i = l.expr ? n.filter(l.expr,l.set)[0] : l.set[0]);
if(i)
{
l = o ? {
expr: s.pop(),
set: f(o)
} : n.find(s.pop(),s.length === 1 && (s[0] === "~" || s[0] === "+") && i.parentNode ? i.parentNode : i,k), a = l.expr ? n.filter(l.expr,l.set) : l.set, s.length > 0 ? h = f(a) : rt = !1;
while(s.length)
w = s.pop(), b = w, u.relative[w] ? b = s.pop() : w = "", b == null && (b = i), u.relative[w](h,b,k)
}
else
h = s = []
}
h || (h = a), h || n.error(w || t);
if(d.call(h) === "[object Array]")
if(rt)
if(i && i.nodeType === 1)
for(c = 0; h[c] != null; c++)
h[c] && (h[c] === !0 || h[c].nodeType === 1 && n.contains(i,h[c])) && e.push(a[c]);
else
for(c = 0; h[c] != null; c++)
h[c] && h[c].nodeType === 1 && e.push(a[c]);
else
e.push.apply(e,h);
else
f(h,e);
return g && (n(g,it,e,o), n.uniqueSort(e)), e
}, n.uniqueSort = function(n)
{
if(a)
{
l = g, n.sort(a);
if(l)
for(var t=1; t < n.length; t++)
n[t] === n[t - 1] && n.splice(t--,1)
}
return n
}, n.matches = function(t, i)
{
return n(t,null,null,i)
}, n.matchesSelector = function(t, i)
{
return n(i,null,null,[t]).length > 0
}, n.find = function(n, t, i)
{
var f,
s,
c,
r,
e,
h;
if(!n)
return[];
for(s = 0, c = u.order.length; s < c; s++)
{
e = u.order[s];
if(r = u.leftMatch[e].exec(n))
{
h = r[1], r.splice(1,1);
if(h.substr(h.length - 1) !== "\\")
{
r[1] = (r[1] || "").replace(o,""), f = u.find[e](r,t,i);
if(f != null)
{
n = n.replace(u.match[e],"");
break
}
}
}
}
return f || (f = typeof t.getElementsByTagName != "undefined" ? t.getElementsByTagName("*") : []), {
set: f,
expr: n
}
}, n.filter = function(i, r, f, e)
{
var o,
c,
h,
v,
y,
b,
p,
l,
w,
k=i,
a=[],
s=r,
d=r && r[0] && n.isXML(r[0]);
while(i && r.length)
{
for(h in u.filter)
if((o = u.leftMatch[h].exec(i)) != null && o[2])
{
b = u.filter[h], p = o[1], c = !1, o.splice(1,1);
if(p.substr(p.length - 1) === "\\")
continue;
s === a && (a = []);
if(u.preFilter[h])
{
o = u.preFilter[h](o,s,f,a,e,d);
if(o)
{
if(o === !0)
continue
}
else
c = v = !0
}
if(o)
for(l = 0; (y = s[l]) != null; l++)
y && (v = b(y,o,l,s), w = e ^ v, f && v != null ? w ? c = !0 : s[l] = !1 : w && (a.push(y), c = !0));
if(v !== t)
{
f || (s = a), i = i.replace(u.match[h],"");
if(!c)
return[];
break
}
}
if(i === k)
if(c == null)
n.error(i);
else
break;
k = i
}
return s
}, n.error = function(n)
{
throw new Error("Syntax error, unrecognized expression: " + n);
};
var w=n.getText = function(n)
{
var r,
u,
t=n.nodeType,
i="";
if(t)
{
if(t === 1 || t === 9)
{
if(typeof n.textContent == "string")
return n.textContent;
if(typeof n.innerText == "string")
return n.innerText.replace(it,"");
for(n = n.firstChild; n; n = n.nextSibling)
i += w(n)
}
else if(t === 3 || t === 4)
return n.nodeValue
}
else
for(r = 0; u = n[r]; r++)
u.nodeType !== 8 && (i += w(u));
return i
},
u=n.selectors = {
order: ["ID","NAME","TAG"],
match: {
ID: /#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
CLASS: /\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,
ATTR: /\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,
TAG: /^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,
CHILD: /:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,
POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,
PSEUDO: /:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/
},
leftMatch: {},
attrMap: {
"class": "className",
"for": "htmlFor"
},
attrHandle: {
href: function(n)
{
return n.getAttribute("href")
},
type: function(n)
{
return n.getAttribute("type")
}
},
relative: {
"+": function(t, i)
{
var s=typeof i == "string",
e=s && !c.test(i),
o=s && !e,
u,
f,
r;
for(e && (i = i.toLowerCase()), u = 0, f = t.length; u < f; u++)
if(r = t[u])
{
while((r = r.previousSibling) && r.nodeType !== 1);
t[u] = o || r && r.nodeName.toLowerCase() === i ? r || !1 : r === i
}
o && n.filter(i,t,!0)
},
">": function(t, i)
{
var u,
e=typeof i == "string",
r=0,
o=t.length,
f;
if(e && !c.test(i))
for(i = i.toLowerCase(); r < o; r++)
u = t[r], u && (f = u.parentNode, t[r] = f.nodeName.toLowerCase() === i ? f : !1);
else
{
for(; r < o; r++)
u = t[r], u && (t[r] = e ? u.parentNode : u.parentNode === i);
e && n.filter(i,t,!0)
}
},
"": function(n, t, i)
{
var u,
f=y++,
r=b;
typeof t != "string" || c.test(t) || (t = t.toLowerCase(), u = t, r = k), r("parentNode",t,f,n,u,i)
},
"~": function(n, t, i)
{
var u,
f=y++,
r=b;
typeof t != "string" || c.test(t) || (t = t.toLowerCase(), u = t, r = k), r("previousSibling",t,f,n,u,i)
}
},
find: {
ID: function(n, t, i)
{
if(typeof t.getElementById != "undefined" && !i)
{
var r=t.getElementById(n[1]);
return r && r.parentNode ? [r] : []
}
},
NAME: function(n, t)
{
var u,
r,
i,
f;
if(typeof t.getElementsByName != "undefined")
{
for(u = [], r = t.getElementsByName(n[1]), i = 0, f = r.length; i < f; i++)
r[i].getAttribute("name") === n[1] && u.push(r[i]);
return u.length === 0 ? null : u
}
},
TAG: function(n, t)
{
if(typeof t.getElementsByTagName != "undefined")
return t.getElementsByTagName(n[1])
}
},
preFilter: {
CLASS: function(n, t, i, r, u, f)
{
n = " " + n[1].replace(o,"") + " ";
if(f)
return n;
for(var s=0, e; (e = t[s]) != null; s++)
e && (u ^ (e.className && (" " + e.className + " ").replace(/[\t\n\r]/g," ").indexOf(n) >= 0) ? i || r.push(e) : i && (t[s] = !1));
return!1
},
ID: function(n)
{
return n[1].replace(o,"")
},
TAG: function(n)
{
return n[1].replace(o,"").toLowerCase()
},
CHILD: function(t)
{
if(t[1] === "nth")
{
t[2] || n.error(t[0]), t[2] = t[2].replace(/^\+|\s*/g,"");
var i=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(t[2] === "even" && "2n" || t[2] === "odd" && "2n+1" || !/\D/.test(t[2]) && "0n+" + t[2] || t[2]);
t[2] = i[1] + (i[2] || 1) - 0, t[3] = i[3] - 0
}
else
t[2] && n.error(t[0]);
return t[0] = y++, t
},
ATTR: function(n, t, i, r, f, e)
{
var s=n[1] = n[1].replace(o,"");
return!e && u.attrMap[s] && (n[1] = u.attrMap[s]), n[4] = (n[4] || n[5] || "").replace(o,""), n[2] === "~=" && (n[4] = " " + n[4] + " "), n
},
PSEUDO: function(t, i, r, f, e)
{
if(t[1] === "not")
if((p.exec(t[3]) || "").length > 1 || /^\w/.test(t[3]))
t[3] = n(t[3],null,null,i);
else
{
var o=n.filter(t[3],i,r,!0 ^ e);
return r || f.push.apply(f,o), !1
}
else if(u.match.POS.test(t[0]) || u.match.CHILD.test(t[0]))
return!0;
return t
},
POS: function(n)
{
return n.unshift(!0), n
}
},
filters: {
enabled: function(n)
{
return n.disabled === !1 && n.type !== "hidden"
},
disabled: function(n)
{
return n.disabled === !0
},
checked: function(n)
{
return n.checked === !0
},
selected: function(n)
{
return n.parentNode && n.parentNode.selectedIndex, n.selected === !0
},
parent: function(n)
{
return!!n.firstChild
},
empty: function(n)
{
return!n.firstChild
},
has: function(t, i, r)
{
return!!n(r[3],t).length
},
header: function(n)
{
return/h\d/i.test(n.nodeName)
},
text: function(n)
{
var i=n.getAttribute("type"),
t=n.type;
return n.nodeName.toLowerCase() === "input" && "text" === t && (i === t || i === null)
},
radio: function(n)
{
return n.nodeName.toLowerCase() === "input" && "radio" === n.type
},
checkbox: function(n)
{
return n.nodeName.toLowerCase() === "input" && "checkbox" === n.type
},
file: function(n)
{
return n.nodeName.toLowerCase() === "input" && "file" === n.type
},
password: function(n)
{
return n.nodeName.toLowerCase() === "input" && "password" === n.type
},
submit: function(n)
{
var t=n.nodeName.toLowerCase();
return(t === "input" || t === "button") && "submit" === n.type
},
image: function(n)
{
return n.nodeName.toLowerCase() === "input" && "image" === n.type
},
reset: function(n)
{
var t=n.nodeName.toLowerCase();
return(t === "input" || t === "button") && "reset" === n.type
},
button: function(n)
{
var t=n.nodeName.toLowerCase();
return t === "input" && "button" === n.type || t === "button"
},
input: function(n)
{
return/input|select|textarea|button/i.test(n.nodeName)
},
focus: function(n)
{
return n === n.ownerDocument.activeElement
}
},
setFilters: {
first: function(n, t)
{
return t === 0
},
last: function(n, t, i, r)
{
return t === r.length - 1
},
even: function(n, t)
{
return t % 2 == 0
},
odd: function(n, t)
{
return t % 2 == 1
},
lt: function(n, t, i)
{
return t < i[3] - 0
},
gt: function(n, t, i)
{
return t > i[3] - 0
},
nth: function(n, t, i)
{
return i[3] - 0 === t
},
eq: function(n, t, i)
{
return i[3] - 0 === t
}
},
filter: {
PSEUDO: function(t, i, r, f)
{
var o=i[1],
c=u.filters[o],
s,
e,
h;
if(c)
return c(t,r,i,f);
if(o === "contains")
return(t.textContent || t.innerText || w([t]) || "").indexOf(i[3]) >= 0;
if(o === "not")
{
for(s = i[3], e = 0, h = s.length; e < h; e++)
if(s[e] === t)
return!1;
return!0
}
n.error(o)
},
CHILD: function(n, t)
{
var r,
o,
s,
u,
l,
c,
f,
h=t[1],
i=n;
switch(h)
{
case"only":
case"first":
while(i = i.previousSibling)
if(i.nodeType === 1)
return!1;
if(h === "first")
return!0;
i = n;
case"last":
while(i = i.nextSibling)
if(i.nodeType === 1)
return!1;
return!0;
case"nth":
r = t[2], o = t[3];
if(r === 1 && o === 0)
return!0;
s = t[0], u = n.parentNode;
if(u && (u[e] !== s || !n.nodeIndex))
{
for(c = 0, i = u.firstChild; i; i = i.nextSibling)
i.nodeType === 1 && (i.nodeIndex = ++c);
u[e] = s
}
return f = n.nodeIndex - o, r === 0 ? f === 0 : f % r == 0 && f / r >= 0
}
},
ID: function(n, t)
{
return n.nodeType === 1 && n.getAttribute("id") === t
},
TAG: function(n, t)
{
return t === "*" && n.nodeType === 1 || !!n.nodeName && n.nodeName.toLowerCase() === t
},
CLASS: function(n, t)
{
return(" " + (n.className || n.getAttribute("class")) + " ").indexOf(t) > -1
},
ATTR: function(t, i)
{
var o=i[1],
s=n.attr ? n.attr(t,o) : u.attrHandle[o] ? u.attrHandle[o](t) : t[o] != null ? t[o] : t.getAttribute(o),
f=s + "",
e=i[2],
r=i[4];
return s == null ? e === "!=" : !e && n.attr ? s != null : e === "=" ? f === r : e === "*=" ? f.indexOf(r) >= 0 : e === "~=" ? (" " + f + " ").indexOf(r) >= 0 : r ? e === "!=" ? f !== r : e === "^=" ? f.indexOf(r) === 0 : e === "$=" ? f.substr(f.length - r.length) === r : e === "|=" ? f === r || f.substr(0,r.length + 1) === r + "-" : !1 : f && s !== !1
},
POS: function(n, t, i, r)
{
var e=t[2],
f=u.setFilters[e];
if(f)
return f(n,i,t,r)
}
}
},
nt=u.match.POS,
tt=function(n, t)
{
return"\\" + (+t + 1)
};
for(s in u.match)
u.match[s] = new RegExp(u.match[s].source + /(?![^\[]*\])(?![^\(]*\))/.source), u.leftMatch[s] = new RegExp(/(^(?:.|\r|\n)*?)/.source + u.match[s].source.replace(/\\(\d+)/g,tt));
f = function(n, t)
{
return n = Array.prototype.slice.call(n,0), t ? (t.push.apply(t,n), t) : n
};
try
{
Array.prototype.slice.call(r.documentElement.childNodes,0)[0].nodeType
}
catch(rt)
{
f = function(n, t)
{
var i=0,
r=t || [],
u;
if(d.call(n) === "[object Array]")
Array.prototype.push.apply(r,n);
else if(typeof n.length == "number")
for(u = n.length; i < u; i++)
r.push(n[i]);
else
for(; n[i]; i++)
r.push(n[i]);
return r
}
}
r.documentElement.compareDocumentPosition ? a = function(n, t)
{
return n === t ? (l = !0, 0) : !n.compareDocumentPosition || !t.compareDocumentPosition ? n.compareDocumentPosition ? -1 : 1 : n.compareDocumentPosition(t) & 4 ? -1 : 1
} : (a = function(n, t)
{
var i;
if(n === t)
return l = !0, 0;
if(n.sourceIndex && t.sourceIndex)
return n.sourceIndex - t.sourceIndex;
var o,
c,
f=[],
u=[],
s=n.parentNode,
e=t.parentNode,
r=s;
if(s === e)
return h(n,t);
if(s)
{
if(!e)
return 1
}
else
return-1;
while(r)
f.unshift(r), r = r.parentNode;
r = e;
while(r)
u.unshift(r), r = r.parentNode;
for(o = f.length, c = u.length, i = 0; i < o && i < c; i++)
if(f[i] !== u[i])
return h(f[i],u[i]);
return i === o ? h(n,u[i],-1) : h(f[i],t,1)
}, h = function(n, t, i)
{
if(n === t)
return i;
var r=n.nextSibling;
while(r)
{
if(r === t)
return-1;
r = r.nextSibling
}
return 1
}), function()
{
var i=r.createElement("div"),
f="script" + +new Date,
n=r.documentElement;
i.innerHTML = "<a name='" + f + "'/>", n.insertBefore(i,n.firstChild), r.getElementById(f) && (u.find.ID = function(n, i, r)
{
if(typeof i.getElementById != "undefined" && !r)
{
var u=i.getElementById(n[1]);
return u ? u.id === n[1] || typeof u.getAttributeNode != "undefined" && u.getAttributeNode("id").nodeValue === n[1] ? [u] : t : []
}
}, u.filter.ID = function(n, t)
{
var i=typeof n.getAttributeNode != "undefined" && n.getAttributeNode("id");
return n.nodeType === 1 && i && i.nodeValue === t
}), n.removeChild(i), n = i = null
}(), function()
{
var n=r.createElement("div");
n.appendChild(r.createComment("")), n.getElementsByTagName("*").length > 0 && (u.find.TAG = function(n, t)
{
var r=t.getElementsByTagName(n[1]),
u,
i;
if(n[1] === "*")
{
for(u = [], i = 0; r[i]; i++)
r[i].nodeType === 1 && u.push(r[i]);
r = u
}
return r
}), n.innerHTML = "<a href='#'></a>", n.firstChild && typeof n.firstChild.getAttribute != "undefined" && n.firstChild.getAttribute("href") !== "#" && (u.attrHandle.href = function(n)
{
return n.getAttribute("href",2)
}), n = null
}(), r.querySelectorAll && function()
{
var e=n,
t=r.createElement("div"),
o="__sizzle__",
i;
t.innerHTML = "<p class='TEST'></p>";
if(t.querySelectorAll && t.querySelectorAll(".TEST").length === 0)
return;
n = function(t, i, s, h)
{
var c,
l;
i = i || r;
if(!h && !n.isXML(i))
{
c = /^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(t);
if(c && (i.nodeType === 1 || i.nodeType === 9))
{
if(c[1])
return f(i.getElementsByTagName(t),s);
if(c[2] && u.find.CLASS && i.getElementsByClassName)
return f(i.getElementsByClassName(c[2]),s)
}
if(i.nodeType === 9)
{
if(t === "body" && i.body)
return f([i.body],s);
if(c && c[3])
{
l = i.getElementById(c[3]);
if(l && l.parentNode)
{
if(l.id === c[3])
return f([l],s)
}
else
return f([],s)
}
try
{
return f(i.querySelectorAll(t),s)
}
catch(k){}
}
else if(i.nodeType === 1 && i.nodeName.toLowerCase() !== "object")
{
var w=i,
v=i.getAttribute("id"),
a=v || o,
y=i.parentNode,
p=/^\s*[+~]/.test(t);
v ? a = a.replace(/'/g,"\\$&") : i.setAttribute("id",a), p && y && (i = i.parentNode);
try
{
if(!p || y)
return f(i.querySelectorAll("[id='" + a + "'] " + t),s)
}
catch(b){}
finally
{
v || w.removeAttribute("id")
}
}
}
return e(t,i,s,h)
};
for(i in e)
n[i] = e[i];
t = null
}(), function()
{
var i=r.documentElement,
t=i.matchesSelector || i.mozMatchesSelector || i.webkitMatchesSelector || i.msMatchesSelector,
e,
f;
if(t)
{
e = !t.call(r.createElement("div"),"div"), f = !1;
try
{
t.call(r.documentElement,"[test!='']:sizzle")
}
catch(o)
{
f = !0
}
n.matchesSelector = function(i, r)
{
r = r.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");
if(!n.isXML(i))
try
{
if(f || !u.match.PSEUDO.test(r) && !/!=/.test(r))
{
var o=t.call(i,r);
if(o || !e || i.document && i.document.nodeType !== 11)
return o
}
}
catch(s){}
return n(r,null,null,[i]).length > 0
}
}
}(), function()
{
var n=r.createElement("div");
n.innerHTML = "<div class='test e'></div><div class='test'></div>";
if(!n.getElementsByClassName || n.getElementsByClassName("e").length === 0)
return;
n.lastChild.className = "e";
if(n.getElementsByClassName("e").length === 1)
return;
u.order.splice(1,0,"CLASS"), u.find.CLASS = function(n, t, i)
{
if(typeof t.getElementsByClassName != "undefined" && !i)
return t.getElementsByClassName(n[1])
}, n = null
}(), n.contains = r.documentElement.contains ? function(n, t)
{
return n !== t && (n.contains ? n.contains(t) : !0)
} : r.documentElement.compareDocumentPosition ? function(n, t)
{
return!!(n.compareDocumentPosition(t) & 16)
} : function()
{
return!1
}, n.isXML = function(n)
{
var t=(n ? n.ownerDocument || n : 0).documentElement;
return t ? t.nodeName !== "HTML" : !1
}, v = function(t, i, r)
{
var s,
h=[],
c="",
e=i.nodeType ? [i] : i,
f,
o;
while(s = u.match.PSEUDO.exec(t))
c += s[0], t = t.replace(u.match.PSEUDO,"");
for(t = u.relative[t] ? t + "*" : t, f = 0, o = e.length; f < o; f++)
n(t,e[f],h,r);
return n.filter(c,h)
}, n.attr = i.attr, n.selectors.attrMap = {}, i.find = n, i.expr = n.selectors, i.expr[":"] = i.expr.filters, i.unique = n.uniqueSort, i.text = n.getText, i.isXMLDoc = n.isXML, i.contains = n.contains
})();
var br=/Until$/,
bf=/^(?:parents|prevUntil|prevAll)/,
wf=/,/,
kf=/^.[^:#\[\.,]*$/,
pf=Array.prototype.slice,
tr=i.expr.match.POS,
te={
children: !0,
contents: !0,
next: !0,
prev: !0
};
i.fn.extend({
find: function(n)
{
var s=this,
t,
e,
r,
o,
u,
f;
if(typeof n != "string")
return i(n).filter(function()
{
for(t = 0, e = s.length; t < e; t++)
if(i.contains(s[t],this))
return!0
});
for(r = this.pushStack("","find",n), t = 0, e = this.length; t < e; t++)
{
o = r.length, i.find(n,this[t],r);
if(t > 0)
for(u = o; u < r.length; u++)
for(f = 0; f < o; f++)
if(r[f] === r[u])
{
r.splice(u--,1);
break
}
}
return r
},
has: function(n)
{
var t=i(n);
return this.filter(function()
{
for(var n=0, r=t.length; n < r; n++)
if(i.contains(this,t[n]))
return!0
})
},
not: function(n)
{
return this.pushStack(bi(this,n,!1),"not",n)
},
filter: function(n)
{
return this.pushStack(bi(this,n,!0),"filter",n)
},
is: function(n)
{
return!!n && (typeof n == "string" ? tr.test(n) ? i(n,this.context).index(this[0]) >= 0 : i.filter(n,this).length > 0 : this.filter(n).length > 0)
},
closest: function(n, t)
{
var f=[],
u,
s,
r=this[0],
e,
o;
if(i.isArray(n))
{
e = 1;
while(r && r.ownerDocument && r !== t)
{
for(u = 0; u < n.length; u++)
i(r).is(n[u]) && f.push({
selector: n[u],
elem: r,
level: e
});
r = r.parentNode, e++
}
return f
}
for(o = tr.test(n) || typeof n != "string" ? i(n,t || this.context) : 0, u = 0, s = this.length; u < s; u++)
{
r = this[u];
while(r)
if(o ? o.index(r) > -1 : i.find.matchesSelector(r,n))
{
f.push(r);
break
}
else
{
r = r.parentNode;
if(!r || !r.ownerDocument || r === t || r.nodeType === 11)
break
}
}
return f = f.length > 1 ? i.unique(f) : f, this.pushStack(f,"closest",n)
},
index: function(n)
{
return n ? typeof n == "string" ? i.inArray(this[0],i(n)) : i.inArray(n.jquery ? n[0] : n,this) : this[0] && this[0].parentNode ? this.prevAll().length : -1
},
add: function(n, t)
{
var u=typeof n == "string" ? i(n,t) : i.makeArray(n && n.nodeType ? [n] : n),
r=i.merge(this.get(),u);
return this.pushStack(nr(u[0]) || nr(r[0]) ? r : i.unique(r))
},
andSelf: function()
{
return this.add(this.prevObject)
}
}), i.each({
parent: function(n)
{
var t=n.parentNode;
return t && t.nodeType !== 11 ? t : null
},
parents: function(n)
{
return i.dir(n,"parentNode")
},
parentsUntil: function(n, t, r)
{
return i.dir(n,"parentNode",r)
},
next: function(n)
{
return i.nth(n,2,"nextSibling")
},
prev: function(n)
{
return i.nth(n,2,"previousSibling")
},
nextAll: function(n)
{
return i.dir(n,"nextSibling")
},
prevAll: function(n)
{
return i.dir(n,"previousSibling")
},
nextUntil: function(n, t, r)
{
return i.dir(n,"nextSibling",r)
},
prevUntil: function(n, t, r)
{
return i.dir(n,"previousSibling",r)
},
siblings: function(n)
{
return i.sibling(n.parentNode.firstChild,n)
},
children: function(n)
{
return i.sibling(n.firstChild)
},
contents: function(n)
{
return i.nodeName(n,"iframe") ? n.contentDocument || n.contentWindow.document : i.makeArray(n.childNodes)
}
},function(n, t)
{
i.fn[n] = function(r, u)
{
var f=i.map(this,t,r);
return br.test(n) || (u = r), u && typeof u == "string" && (f = i.filter(u,f)), f = this.length > 1 && !te[n] ? i.unique(f) : f, (this.length > 1 || wf.test(u)) && bf.test(n) && (f = f.reverse()), this.pushStack(f,n,pf.call(arguments).join(","))
}
}), i.extend({
filter: function(n, t, r)
{
return r && (n = ":not(" + n + ")"), t.length === 1 ? i.find.matchesSelector(t[0],n) ? [t[0]] : [] : i.find.matches(n,t)
},
dir: function(n, r, u)
{
var e=[],
f=n[r];
while(f && f.nodeType !== 9 && (u === t || f.nodeType !== 1 || !i(f).is(u)))
f.nodeType === 1 && e.push(f), f = f[r];
return e
},
nth: function(n, t, i)
{
t = t || 1;
for(var u=0; n; n = n[i])
if(n.nodeType === 1 && ++u === t)
break;
return n
},
sibling: function(n, t)
{
for(var i=[]; n; n = n.nextSibling)
n.nodeType === 1 && n !== t && i.push(n);
return i
}
});
var ki="abbr|article|aside|audio|canvas|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",
ku=/ jQuery\d+="(?:\d+|null)"/g,
ft=/^\s+/,
ar=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,
pr=/<([\w:]+)/,
of=/<tbody/i,
cf=/<|&#?\w+;/,
hf=/<(?:script|style)/i,
rf=/<(?:script|object|embed|option|style)/i,
or=new RegExp("<(?:" + ki + ")","i"),
pi=/checked\s*(?:[^=]|=\s*.checked.)/i,
ff=/\/(java|ecma)script/i,
ef=/^\s*<!(?:\[CDATA\[|\-\-)/,
u={
option: [1,"<select multiple='multiple'>","</select>"],
legend: [1,"<fieldset>","</fieldset>"],
thead: [1,"<table>","</table>"],
tr: [2,"<table><tbody>","</tbody></table>"],
td: [3,"<table><tbody><tr>","</tr></tbody></table>"],
col: [2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],
area: [1,"<map>","</map>"],
_default: [0,"",""]
},
at=wi(r);
u.optgroup = u.option, u.tbody = u.tfoot = u.colgroup = u.caption = u.thead, u.th = u.td, i.support.htmlSerialize || (u._default = [1,"div<div>","</div>"]), i.fn.extend({
text: function(n)
{
return i.isFunction(n) ? this.each(function(t)
{
var r=i(this);
r.text(n.call(this,t,r.text()))
}) : typeof n != "object" && n !== t ? this.empty().append((this[0] && this[0].ownerDocument || r).createTextNode(n)) : i.text(this)
},
wrapAll: function(n)
{
if(i.isFunction(n))
return this.each(function(t)
{
i(this).wrapAll(n.call(this,t))
});
if(this[0])
{
var t=i(n,this[0].ownerDocument).eq(0).clone(!0);
this[0].parentNode && t.insertBefore(this[0]), t.map(function()
{
var n=this;
while(n.firstChild && n.firstChild.nodeType === 1)
n = n.firstChild;
return n
}).append(this)
}
return this
},
wrapInner: function(n)
{
return i.isFunction(n) ? this.each(function(t)
{
i(this).wrapInner(n.call(this,t))
}) : this.each(function()
{
var r=i(this),
t=r.contents();
t.length ? t.wrapAll(n) : r.append(n)
})
},
wrap: function(n)
{
var t=i.isFunction(n);
return this.each(function(r)
{
i(this).wrapAll(t ? n.call(this,r) : n)
})
},
unwrap: function()
{
return this.parent().each(function()
{
i.nodeName(this,"body") || i(this).replaceWith(this.childNodes)
}).end()
},
append: function()
{
return this.domManip(arguments,!0,function(n)
{
this.nodeType === 1 && this.appendChild(n)
})
},
prepend: function()
{
return this.domManip(arguments,!0,function(n)
{
this.nodeType === 1 && this.insertBefore(n,this.firstChild)
})
},
before: function()
{
if(this[0] && this[0].parentNode)
return this.domManip(arguments,!1,function(n)
{
this.parentNode.insertBefore(n,this)
});
if(arguments.length)
{
var n=i.clean(arguments);
return n.push.apply(n,this.toArray()), this.pushStack(n,"before",arguments)
}
},
after: function()
{
if(this[0] && this[0].parentNode)
return this.domManip(arguments,!1,function(n)
{
this.parentNode.insertBefore(n,this.nextSibling)
});
if(arguments.length)
{
var n=this.pushStack(this,"after",arguments);
return n.push.apply(n,i.clean(arguments)), n
}
},
remove: function(n, t)
{
for(var u=0, r; (r = this[u]) != null; u++)
(!n || i.filter(n,[r]).length) && (t || r.nodeType !== 1 || (i.cleanData(r.getElementsByTagName("*")), i.cleanData([r])), r.parentNode && r.parentNode.removeChild(r));
return this
},
empty: function()
{
for(var t=0, n; (n = this[t]) != null; t++)
{
n.nodeType === 1 && i.cleanData(n.getElementsByTagName("*"));
while(n.firstChild)
n.removeChild(n.firstChild)
}
return this
},
clone: function(n, t)
{
return n = n == null ? !1 : n, t = t == null ? n : t, this.map(function()
{
return i.clone(this,n,t)
})
},
html: function(n)
{
if(n === t)
return this[0] && this[0].nodeType === 1 ? this[0].innerHTML.replace(ku,"") : null;
if(typeof n != "string" || hf.test(n) || !i.support.leadingWhitespace && ft.test(n) || u[(pr.exec(n) || ["",""])[1].toLowerCase()])
i.isFunction(n) ? this.each(function(t)
{
var r=i(this);
r.html(n.call(this,t,r.html()))
}) : this.empty().append(n);
else
{
n = n.replace(ar,"<$1></$2>");
try
{
for(var r=0, f=this.length; r < f; r++)
this[r].nodeType === 1 && (i.cleanData(this[r].getElementsByTagName("*")), this[r].innerHTML = n)
}
catch(e)
{
this.empty().append(n)
}
}
return this
},
replaceWith: function(n)
{
return this[0] && this[0].parentNode ? i.isFunction(n) ? this.each(function(t)
{
var r=i(this),
u=r.html();
r.replaceWith(n.call(this,t,u))
}) : (typeof n != "string" && (n = i(n).detach()), this.each(function()
{
var t=this.nextSibling,
r=this.parentNode;
i(this).remove(), t ? i(t).before(n) : i(r).append(n)
})) : this.length ? this.pushStack(i(i.isFunction(n) ? n() : n),"replaceWith",n) : this
},
detach: function(n)
{
return this.remove(n,!0)
},
domManip: function(n, r, u)
{
var c,
o,
f,
h,
e=n[0],
a=[];
if(!i.support.checkClone && arguments.length === 3 && typeof e == "string" && pi.test(e))
return this.each(function()
{
i(this).domManip(n,r,u,!0)
});
if(i.isFunction(e))
return this.each(function(f)
{
var o=i(this);
n[0] = e.call(this,f,r ? o.html() : t), o.domManip(n,r,u)
});
if(this[0])
{
h = e && e.parentNode, c = i.support.parentNode && h && h.nodeType === 11 && h.childNodes.length === this.length ? {fragment: h} : i.buildFragment(n,this,a), f = c.fragment, o = f.childNodes.length === 1 ? f = f.firstChild : f.firstChild;
if(o)
{
r = r && i.nodeName(o,"tr");
for(var s=0, l=this.length, v=l - 1; s < l; s++)
u.call(r ? uf(this[s],o) : this[s],c.cacheable || l > 1 && s < v ? i.clone(f,!0,!0) : f)
}
a.length && i.each(a,bu)
}
return this
}
}), i.buildFragment = function(n, t, u)
{
var o,
h,
s,
e,
f=n[0];
return t && t[0] && (e = t[0].ownerDocument || t[0]), e.createDocumentFragment || (e = r), n.length === 1 && typeof f == "string" && f.length < 512 && e === r && f.charAt(0) === "<" && !rf.test(f) && (i.support.checkClone || !pi.test(f)) && (i.support.html5Clone || !or.test(f)) && (h = !0, s = i.fragments[f], s && s !== 1 && (o = s)), o || (o = e.createDocumentFragment(), i.clean(n,e,o,u)), h && (i.fragments[f] = s ? o : 1), {
fragment: o,
cacheable: h
}
}, i.fragments = {}, i.each({
appendTo: "append",
prependTo: "prepend",
insertBefore: "before",
insertAfter: "after",
replaceAll: "replaceWith"
},function(n, t)
{
i.fn[n] = function(r)
{
var o=[],
u=i(r),
s=this.length === 1 && this[0].parentNode,
f,
h,
e;
if(s && s.nodeType === 11 && s.childNodes.length === 1 && u.length === 1)
return u[t](this[0]), this;
for(f = 0, h = u.length; f < h; f++)
e = (f > 0 ? this.clone(!0) : this).get(), i(u[f])[t](e), o = o.concat(e);
return this.pushStack(o,n,u.selector)
}
}), i.extend({
clone: function(n, t, r)
{
var f,
e,
u,
o=i.support.html5Clone || !or.test("<" + n.nodeName) ? n.cloneNode(!0) : sf(n);
if((!i.support.noCloneEvent || !i.support.noCloneChecked) && (n.nodeType === 1 || n.nodeType === 11) && !i.isXMLDoc(n))
for(kt(n,o), f = w(n), e = w(o), u = 0; f[u]; ++u)
e[u] && kt(f[u],e[u]);
if(t)
{
dt(n,o);
if(r)
for(f = w(n), e = w(o), u = 0; f[u]; ++u)
dt(f[u],e[u])
}
return f = e = null, o
},
clean: function(n, t, f, e)
{
var p,
s,
l,
h,
o,
y,
a,
w,
k;
for(t = t || r, typeof t.createElement == "undefined" && (t = t.ownerDocument || t[0] && t[0].ownerDocument || r), s = [], h = 0; (o = n[h]) != null; h++)
{
typeof o == "number" && (o += "");
if(!o)
continue;
if(typeof o == "string")
if(cf.test(o))
{
o = o.replace(ar,"<$1></$2>");
var b=(pr.exec(o) || ["",""])[1].toLowerCase(),
v=u[b] || u._default,
d=v[0],
c=t.createElement("div");
t === r ? at.appendChild(c) : wi(t).appendChild(c), c.innerHTML = v[1] + o + v[2];
while(d--)
c = c.lastChild;
if(!i.support.tbody)
for(y = of.test(o), a = b === "table" && !y ? c.firstChild && c.firstChild.childNodes : v[1] === "<table>" && !y ? c.childNodes : [], l = a.length - 1; l >= 0; --l)
i.nodeName(a[l],"tbody") && !a[l].childNodes.length && a[l].parentNode.removeChild(a[l]);
!i.support.leadingWhitespace && ft.test(o) && c.insertBefore(t.createTextNode(ft.exec(o)[0]),c.firstChild), o = c.childNodes
}
else
o = t.createTextNode(o);
if(!i.support.appendChecked)
if(o[0] && typeof(w = o.length) == "number")
for(l = 0; l < w; l++)
bt(o[l]);
else
bt(o);
o.nodeType ? s.push(o) : s = i.merge(s,o)
}
if(f)
for(p = function(n)
{
return!n.type || ff.test(n.type)
}, h = 0; s[h]; h++)
e && i.nodeName(s[h],"script") && (!s[h].type || s[h].type.toLowerCase() === "text/javascript") ? e.push(s[h].parentNode ? s[h].parentNode.removeChild(s[h]) : s[h]) : (s[h].nodeType === 1 && (k = i.grep(s[h].getElementsByTagName("script"),p), s.splice.apply(s,[h + 1,0].concat(k))), f.appendChild(s[h]));
return s
},
cleanData: function(n)
{
for(var r, f, o=i.cache, s=i.event.special, h=i.support.deleteExpando, t, u, e=0; (t = n[e]) != null; e++)
{
if(t.nodeName && i.noData[t.nodeName.toLowerCase()])
continue;
f = t[i.expando];
if(f)
{
r = o[f];
if(r && r.events)
{
for(u in r.events)
s[u] ? i.event.remove(t,u) : i.removeEvent(t,u,r.handle);
r.handle && (r.handle.elem = null)
}
h ? delete t[i.expando] : t.removeAttribute && t.removeAttribute(i.expando), delete o[f]
}
}
}
});
var ut=/alpha\([^)]*\)/i,
pu=/opacity=([^)]*)/,
wu=/([A-Z]|^ms)/g,
gt=/^-?\d+(?:px)?$/i,
nf=/^-?\d/,
tf=/^([\-+])=([\-+.\de]+)/,
du={
position: "absolute",
visibility: "hidden",
display: "block"
},
gu=["Left","Right"],
lf=["Top","Bottom"],
l,
pt,
vt;
i.fn.css = function(n, r)
{
return arguments.length === 2 && r === t ? this : i.access(this,n,r,!0,function(n, r, u)
{
return u !== t ? i.style(n,r,u) : i.css(n,r)
})
}, i.extend({
cssHooks: {opacity: {get: function(n, t)
{
if(t)
{
var i=l(n,"opacity","opacity");
return i === "" ? "1" : i
}
return n.style.opacity
}}},
cssNumber: {
fillOpacity: !0,
fontWeight: !0,
lineHeight: !0,
opacity: !0,
orphans: !0,
widows: !0,
zIndex: !0,
zoom: !0
},
cssProps: {float: i.support.cssFloat ? "cssFloat" : "styleFloat"},
style: function(n, r, u, f)
{
if(!n || n.nodeType === 3 || n.nodeType === 8 || !n.style)
return;
var s,
o,
h=i.camelCase(r),
c=n.style,
e=i.cssHooks[h];
r = i.cssProps[h] || h;
if(u !== t)
{
o = typeof u, o === "string" && (s = tf.exec(u)) && (u = +(s[1] + 1) * +s[2] + parseFloat(i.css(n,r)), o = "number");
if(u == null || o === "number" && isNaN(u))
return;
o !== "number" || i.cssNumber[h] || (u += "px");
if(!e || !("set" in e) || (u = e.set(n,u)) !== t)
try
{
c[r] = u
}
catch(l){}
}
else
return e && "get" in e && (s = e.get(n,!1,f)) !== t ? s : c[r]
},
css: function(n, r, u)
{
var e,
f;
return r = i.camelCase(r), f = i.cssHooks[r], r = i.cssProps[r] || r, r === "cssFloat" && (r = "float"), f && "get" in f && (e = f.get(n,!0,u)) !== t ? e : l ? l(n,r) : void 0
},
swap: function(n, t, i)
{
var u={},
r;
for(r in t)
u[r] = n.style[r], n.style[r] = t[r];
i.call(n);
for(r in t)
n.style[r] = u[r]
}
}), i.curCSS = i.css, i.each(["height","width"],function(n, t)
{
i.cssHooks[t] = {
get: function(n, r, u)
{
var f;
if(r)
return n.offsetWidth !== 0 ? yt(n,t,u) : (i.swap(n,du,function()
{
f = yt(n,t,u)
}), f)
},
set: function(n, t)
{
if(gt.test(t))
{
t = parseFloat(t);
if(t >= 0)
return t + "px"
}
else
return t
}
}
}), i.support.opacity || (i.cssHooks.opacity = {
get: function(n, t)
{
return pu.test((t && n.currentStyle ? n.currentStyle.filter : n.style.filter) || "") ? parseFloat(RegExp.$1) / 100 + "" : t ? "1" : ""
},
set: function(n, t)
{
var f=n.style,
u=n.currentStyle,
e=i.isNumeric(t) ? "alpha(opacity=" + t * 100 + ")" : "",
r=u && u.filter || f.filter || "";
f.zoom = 1;
if(t >= 1 && i.trim(r.replace(ut,"")) === "")
{
f.removeAttribute("filter");
if(u && !u.filter)
return
}
f.filter = ut.test(r) ? r.replace(ut,e) : r + " " + e
}
}), i(function()
{
i.support.reliableMarginRight || (i.cssHooks.marginRight = {get: function(n, t)
{
var r;
return i.swap(n,{display: "inline-block"},function()
{
r = t ? l(n,"margin-right","marginRight") : n.style.marginRight
}), r
}})
}), r.defaultView && r.defaultView.getComputedStyle && (pt = function(n, t)
{
var r,
f,
u;
return t = t.replace(wu,"-$1").toLowerCase(), (f = n.ownerDocument.defaultView) && (u = f.getComputedStyle(n,null)) && (r = u.getPropertyValue(t), r !== "" || i.contains(n.ownerDocument.documentElement,n) || (r = i.style(n,t))), r
}), r.documentElement.currentStyle && (vt = function(n, t)
{
var e,
u,
f,
i=n.currentStyle && n.currentStyle[t],
r=n.style;
return i === null && r && (f = r[t]) && (i = f), !gt.test(i) && nf.test(i) && (e = r.left, u = n.runtimeStyle && n.runtimeStyle.left, u && (n.runtimeStyle.left = n.currentStyle.left), r.left = t === "fontSize" ? "1em" : i || 0, i = r.pixelLeft + "px", r.left = e, u && (n.runtimeStyle.left = u)), i === "" ? "auto" : i
}), l = pt || vt, i.expr && i.expr.filters && (i.expr.filters.hidden = function(n)
{
var r=n.offsetWidth,
t=n.offsetHeight;
return r === 0 && t === 0 || !i.support.reliableHiddenOffsets && (n.style && n.style.display || i.css(n,"display")) === "none"
}, i.expr.filters.visible = function(n)
{
return!i.expr.filters.hidden(n)
});
var ie=/%20/g,
gf=/\[\]$/,
ni=/\r?\n/g,
ne=/#.*$/,
fe=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,
ee=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,
re=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,
ue=/^(?:GET|HEAD)$/,
yf=/^\/\//,
ci=/\?/,
af=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,
vf=/^(?:select|textarea)/i,
hi=/\s+/,
df=/([?&])_=[^&]*/,
si=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,
li=i.fn.load,
rt={},
yi={},
o,
s,
vi=["*/"] + ["*"];
try
{
o = su.href
}
catch(oe)
{
o = r.createElement("a"), o.href = "", o = o.href
}
s = si.exec(o.toLowerCase()) || [], i.fn.extend({
load: function(n, r, u)
{
var f,
s,
o,
e;
return typeof n != "string" && li ? li.apply(this,arguments) : this.length ? (f = n.indexOf(" "), f < 0 || (s = n.slice(f,n.length), n = n.slice(0,f)), o = "GET", r && (i.isFunction(r) ? (u = r, r = t) : typeof r == "object" && (r = i.param(r,i.ajaxSettings.traditional), o = "POST")), e = this, i.ajax({
url: n,
type: o,
dataType: "html",
data: r,
complete: function(n, t, r)
{
r = n.responseText, n.isResolved() && (n.done(function(n)
{
r = n
}), e.html(s ? i("<div>").append(r.replace(af,"")).find(s) : r)), u && e.each(u,[r,t,n])
}
}), this) : this
},
serialize: function()
{
return i.param(this.serializeArray())
},
serializeArray: function()
{
return this.map(function()
{
return this.elements ? i.makeArray(this.elements) : this
}).filter(function()
{
return this.name && !this.disabled && (this.checked || vf.test(this.nodeName) || ee.test(this.type))
}).map(function(n, t)
{
var r=i(this).val();
return r == null ? null : i.isArray(r) ? i.map(r,function(n)
{
return{
name: t.name,
value: n.replace(ni,"\r\n")
}
}) : {
name: t.name,
value: r.replace(ni,"\r\n")
}
}).get()
}
}), i.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(n, t)
{
i.fn[t] = function(n)
{
return this.on(t,n)
}
}), i.each(["get","post"],function(n, r)
{
i[r] = function(n, u, f, e)
{
return i.isFunction(u) && (e = e || f, f = u, u = t), i.ajax({
type: r,
url: n,
data: u,
success: f,
dataType: e
})
}
}), i.extend({
getScript: function(n, r)
{
return i.get(n,t,r,"script")
},
getJSON: function(n, t, r)
{
return i.get(n,t,r,"json")
},
ajaxSetup: function(n, t)
{
return t ? lt(n,i.ajaxSettings) : (t = n, n = i.ajaxSettings), lt(n,t), n
},
ajaxSettings: {
url: o,
isLocal: re.test(s[1]),
global: !0,
type: "GET",
contentType: "application/x-www-form-urlencoded",
processData: !0,
async: !0,
accepts: {
xml: "application/xml, text/xml",
html: "text/html",
text: "text/plain",
json: "application/json, text/javascript",
"*": vi
},
contents: {
xml: /xml/,
html: /html/,
json: /json/
},
responseFields: {
xml: "responseXML",
text: "responseText"
},
converters: {
"* text": n.String,
"text html": !0,
"text json": i.parseJSON,
"text xml": i.parseXML
},
flatOptions: {
context: !0,
url: !0
}
},
ajaxPrefilter: ai(rt),
ajaxTransport: ai(yi),
ajax: function(n, r)
{
function b(n, r, s, l)
{
if(e === 2)
return;
e = 2, tt && clearTimeout(tt), c = t, it = l || "", f.readyState = n > 0 ? 4 : 0;
var p,
b,
w,
a=r,
rt=s ? ru(u,f,s) : t,
d,
k;
if(n >= 200 && n < 300 || n === 304)
{
u.ifModified && ((d = f.getResponseHeader("Last-Modified")) && (i.lastModified[o] = d), (k = f.getResponseHeader("Etag")) && (i.etag[o] = k));
if(n === 304)
a = "notmodified", p = !0;
else
try
{
b = iu(u,rt), a = "success", p = !0
}
catch(ft)
{
a = "parsererror", w = ft
}
}
else
w = a, (!a || n) && (a = "error", n < 0 && (n = 0));
f.status = n, f.statusText = "" + (r || a), p ? nt.resolveWith(h,[b,a,f]) : nt.rejectWith(h,[f,a,w]), f.statusCode(y), y = t, v && g.trigger("ajax" + (p ? "Success" : "Error"),[f,u,p ? b : w]), ut.fireWith(h,[f,a]), v && (g.trigger("ajaxComplete",[f,u]), --i.active || i.event.trigger("ajaxStop"))
}
var k,
d;
typeof n == "object" && (r = n, n = t), r = r || {};
var u=i.ajaxSetup({},r),
h=u.context || u,
g=h !== u && (h.nodeType || h instanceof i) ? i(h) : i.event,
nt=i.Deferred(),
ut=i.Callbacks("once memory"),
y=u.statusCode || {},
o,
et={},
ft={},
it,
w,
c,
tt,
a,
e=0,
v,
l,
f={
readyState: 0,
setRequestHeader: function(n, t)
{
if(!e)
{
var i=n.toLowerCase();
n = ft[i] = ft[i] || n, et[n] = t
}
return this
},
getAllResponseHeaders: function()
{
return e === 2 ? it : null
},
getResponseHeader: function(n)
{
var i;
if(e === 2)
{
if(!w)
{
w = {};
while(i = fe.exec(it))
w[i[1].toLowerCase()] = i[2]
}
i = w[n.toLowerCase()]
}
return i === t ? null : i
},
overrideMimeType: function(n)
{
return e || (u.mimeType = n), this
},
abort: function(n)
{
return n = n || "abort", c && c.abort(n), b(0,n), this
}
};
nt.promise(f), f.success = f.done, f.error = f.fail, f.complete = ut.add, f.statusCode = function(n)
{
if(n)
{
var t;
if(e < 2)
for(t in n)
y[t] = [y[t],n[t]];
else
t = n[f.status], f.then(t,t)
}
return this
}, u.url = ((n || u.url) + "").replace(ne,"").replace(yf,s[1] + "//"), u.dataTypes = i.trim(u.dataType || "*").toLowerCase().split(hi), u.crossDomain == null && (a = si.exec(u.url.toLowerCase()), u.crossDomain = !!(a && (a[1] != s[1] || a[2] != s[2] || (a[3] || (a[1] === "http:" ? 80 : 443)) != (s[3] || (s[1] === "http:" ? 80 : 443))))), u.data && u.processData && typeof u.data != "string" && (u.data = i.param(u.data,u.traditional)), p(rt,u,r,f);
if(e === 2)
return!1;
v = u.global, u.type = u.type.toUpperCase(), u.hasContent = !ue.test(u.type), v && i.active++ == 0 && i.event.trigger("ajaxStart"), u.hasContent || (u.data && (u.url += (ci.test(u.url) ? "&" : "?") + u.data, delete u.data), o = u.url, u.cache === !1 && (k = i.now(), d = u.url.replace(df,"$1_=" + k), u.url = d + (d === u.url ? (ci.test(u.url) ? "&" : "?") + "_=" + k : ""))), (u.data && u.hasContent && u.contentType !== !1 || r.contentType) && f.setRequestHeader("Content-Type",u.contentType), u.ifModified && (o = o || u.url, i.lastModified[o] && f.setRequestHeader("If-Modified-Since",i.lastModified[o]), i.etag[o] && f.setRequestHeader("If-None-Match",i.etag[o])), f.setRequestHeader("Accept",u.dataTypes[0] && u.accepts[u.dataTypes[0]] ? u.accepts[u.dataTypes[0]] + (u.dataTypes[0] !== "*" ? ", " + vi + "; q=0.01" : "") : u.accepts["*"]);
for(l in u.headers)
f.setRequestHeader(l,u.headers[l]);
if(u.beforeSend && (u.beforeSend.call(h,f,u) === !1 || e === 2))
return f.abort(), !1;
for(l in{
success: 1,
error: 1,
complete: 1
})
f[l](u[l]);
c = p(yi,u,r,f);
if(c)
{
f.readyState = 1, v && g.trigger("ajaxSend",[f,u]), u.async && u.timeout > 0 && (tt = setTimeout(function()
{
f.abort("timeout")
},u.timeout));
try
{
e = 1, c.send(et,b)
}
catch(ot)
{
if(e < 2)
b(-1,ot);
else
throw ot;
}
}
else
b(-1,"No Transport");
return f
},
param: function(n, r)
{
var f=[],
e=function(n, t)
{
t = i.isFunction(t) ? t() : t, f[f.length] = encodeURIComponent(n) + "=" + encodeURIComponent(t)
},
u;
r === t && (r = i.ajaxSettings.traditional);
if(i.isArray(n) || n.jquery && !i.isPlainObject(n))
i.each(n,function()
{
e(this.name,this.value)
});
else
for(u in n)
et(u,n[u],r,e);
return f.join("&").replace(ie,"+")
}
}), i.extend({
active: 0,
lastModified: {},
etag: {}
}), ri = i.now(), y = /(\=)\?(&|$)|\?\?/i, i.ajaxSetup({
jsonp: "callback",
jsonpCallback: function()
{
return i.expando + "_" + ri++
}
}), i.ajaxPrefilter("json jsonp",function(t, r, u)
{
var l=t.contentType === "application/x-www-form-urlencoded" && typeof t.data == "string";
if(t.dataTypes[0] === "jsonp" || t.jsonp !== !1 && (y.test(t.url) || l && y.test(t.data)))
{
var o,
f=t.jsonpCallback = i.isFunction(t.jsonpCallback) ? t.jsonpCallback() : t.jsonpCallback,
c=n[f],
e=t.url,
s=t.data,
h="$1" + f + "$2";
return t.jsonp !== !1 && (e = e.replace(y,h), t.url === e && (l && (s = s.replace(y,h)), t.data === s && (e += (/\?/.test(e) ? "&" : "?") + t.jsonp + "=" + f))), t.url = e, t.data = s, n[f] = function(n)
{
o = [n]
}, u.always(function()
{
n[f] = c, o && i.isFunction(c) && n[f](o[0])
}), t.converters["script json"] = function()
{
return o || i.error(f + " was not called"), o[0]
}, t.dataTypes[0] = "json", "script"
}
}), i.ajaxSetup({
accepts: {script: "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},
contents: {script: /javascript|ecmascript/},
converters: {"text script": function(n)
{
return i.globalEval(n), n
}}
}), i.ajaxPrefilter("script",function(n)
{
n.cache === t && (n.cache = !1), n.crossDomain && (n.type = "GET", n.global = !1)
}), i.ajaxTransport("script",function(n)
{
if(n.crossDomain)
{
var i,
u=r.head || r.getElementsByTagName("head")[0] || r.documentElement;
return{
send: function(f, e)
{
i = r.createElement("script"), i.async = "async", n.scriptCharset && (i.charset = n.scriptCharset), i.src = n.url, i.onload = i.onreadystatechange = function(n, r)
{
(r || !i.readyState || /loaded|complete/.test(i.readyState)) && (i.onload = i.onreadystatechange = null, u && i.parentNode && u.removeChild(i), i = t, r || e(200,"success"))
}, u.insertBefore(i,u.firstChild)
},
abort: function()
{
if(i)
i.onload(0,1)
}
}
}
}), d = n.ActiveXObject ? function()
{
for(var n in v)
v[n](0,1)
} : !1, ii = 0, i.ajaxSettings.xhr = n.ActiveXObject ? function()
{
return!this.isLocal && ti() || cu()
} : ti, function(n)
{
i.extend(i.support,{
ajax: !!n,
cors: !!n && "withCredentials" in n
})
}(i.ajaxSettings.xhr()), i.support.ajax && i.ajaxTransport(function(r)
{
if(!r.crossDomain || i.support.cors)
{
var u;
return{
send: function(f, e)
{
var o=r.xhr(),
h,
s;
r.username ? o.open(r.type,r.url,r.async,r.username,r.password) : o.open(r.type,r.url,r.async);
if(r.xhrFields)
for(s in r.xhrFields)
o[s] = r.xhrFields[s];
r.mimeType && o.overrideMimeType && o.overrideMimeType(r.mimeType), r.crossDomain || f["X-Requested-With"] || (f["X-Requested-With"] = "XMLHttpRequest");
try
{
for(s in f)
o.setRequestHeader(s,f[s])
}
catch(c){}
o.send(r.hasContent && r.data || null), u = function(n, f)
{
var c,
a,
y,
s,
l;
try
{
if(u && (f || o.readyState === 4))
{
u = t, h && (o.onreadystatechange = i.noop, d && delete v[h]);
if(f)
o.readyState !== 4 && o.abort();
else
{
c = o.status, y = o.getAllResponseHeaders(), s = {}, l = o.responseXML, l && l.documentElement && (s.xml = l), s.text = o.responseText;
try
{
a = o.statusText
}
catch(w)
{
a = ""
}
c || !r.isLocal || r.crossDomain ? c === 1223 && (c = 204) : c = s.text ? 200 : 404
}
}
}
catch(p)
{
f || e(-1,p)
}
s && e(c,a,s,y)
}, r.async && o.readyState !== 4 ? (h = ++ii, d && (v || (v = {}, i(n).unload(d)), v[h] = u), o.onreadystatechange = u) : u()
},
abort: function()
{
u && u(0,1)
}
}
}
});
var ht={},
f,
c,
hu=/^(?:toggle|show|hide)$/,
fu=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,
g,
ui=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],
tt;
i.fn.extend({
show: function(n, t, r)
{
var u,
e,
f,
o;
if(n || n === 0)
return this.animate(a("show",3),n,t,r);
for(f = 0, o = this.length; f < o; f++)
u = this[f], u.style && (e = u.style.display, i._data(u,"olddisplay") || e !== "none" || (e = u.style.display = ""), e === "" && i.css(u,"display") === "none" && i._data(u,"olddisplay",ei(u.nodeName)));
for(f = 0; f < o; f++)
u = this[f], u.style && (e = u.style.display, (e === "" || e === "none") && (u.style.display = i._data(u,"olddisplay") || ""));
return this
},
hide: function(n, t, r)
{
if(n || n === 0)
return this.animate(a("hide",3),n,t,r);
for(var f, e, u=0, o=this.length; u < o; u++)
f = this[u], f.style && (e = i.css(f,"display"), e === "none" || i._data(f,"olddisplay") || i._data(f,"olddisplay",e));
for(u = 0; u < o; u++)
this[u].style && (this[u].style.display = "none");
return this
},
_toggle: i.fn.toggle,
toggle: function(n, t, r)
{
var u=typeof n == "boolean";
return i.isFunction(n) && i.isFunction(t) ? this._toggle.apply(this,arguments) : n == null || u ? this.each(function()
{
var t=u ? n : i(this).is(":hidden");
i(this)[t ? "show" : "hide"]()
}) : this.animate(a("toggle",3),n,t,r), this
},
fadeTo: function(n, t, i, r)
{
return this.filter(":hidden").css("opacity",0).show().end().animate({opacity: t},n,i,r)
},
animate: function(n, t, r, u)
{
function e()
{
f.queue === !1 && i._mark(this);
var u=i.extend({},f),
y=this.nodeType === 1,
v=y && i(this).is(":hidden"),
e,
t,
r,
s,
c,
o,
h,
l,
a;
u.animatedProperties = {};
for(r in n)
{
e = i.camelCase(r), r !== e && (n[e] = n[r], delete n[r]), t = n[e], i.isArray(t) ? (u.animatedProperties[e] = t[1], t = n[e] = t[0]) : u.animatedProperties[e] = u.specialEasing && u.specialEasing[e] || u.easing || "swing";
if(t === "hide" && v || t === "show" && !v)
return u.complete.call(this);
y && (e === "height" || e === "width") && (u.overflow = [this.style.overflow,this.style.overflowX,this.style.overflowY], i.css(this,"display") === "inline" && i.css(this,"float") === "none" && (i.support.inlineBlockNeedsLayout && ei(this.nodeName) !== "inline" ? this.style.zoom = 1 : this.style.display = "inline-block"))
}
u.overflow != null && (this.style.overflow = "hidden");
for(r in n)
s = new i.fx(this,u,r), t = n[r], hu.test(t) ? (a = i._data(this,"toggle" + r) || (t === "toggle" ? v ? "show" : "hide" : 0), a ? (i._data(this,"toggle" + r,a === "show" ? "hide" : "show"), s[a]()) : s[t]()) : (c = fu.exec(t), o = s.cur(), c ? (h = parseFloat(c[2]), l = c[3] || (i.cssNumber[r] ? "" : "px"), l !== "px" && (i.style(this,r,(h || 1) + l), o = (h || 1) / s.cur() * o, i.style(this,r,o + l)), c[1] && (h = (c[1] === "-=" ? -1 : 1) * h + o), s.custom(o,h,l)) : s.custom(o,t,""));
return!0
}
var f=i.speed(t,r,u);
return i.isEmptyObject(n) ? this.each(f.complete,[!1]) : (n = i.extend({},n), f.queue === !1 ? this.each(e) : this.queue(f.queue,e))
},
stop: function(n, r, u)
{
return typeof n != "string" && (u = r, r = n, n = t), r && n !== !1 && this.queue(n || "fx",[]), this.each(function()
{
function e(n, t, r)
{
var f=t[r];
i.removeData(n,r,!0), f.stop(u)
}
var t,
o=!1,
f=i.timers,
r=i._data(this);
u || i._unmark(!0,this);
if(n == null)
for(t in r)
r[t] && r[t].stop && t.indexOf(".run") === t.length - 4 && e(this,r,t);
else
r[t = n + ".run"] && r[t].stop && e(this,r,t);
for(t = f.length; t--; )
f[t].elem === this && (n == null || f[t].queue === n) && (u ? f[t](!0) : f[t].saveState(), o = !0, f.splice(t,1));
u && o || i.dequeue(this,n)
})
}
}), i.each({
slideDown: a("show",1),
slideUp: a("hide",1),
slideToggle: a("toggle",1),
fadeIn: {opacity: "show"},
fadeOut: {opacity: "hide"},
fadeToggle: {opacity: "toggle"}
},function(n, t)
{
i.fn[n] = function(n, i, r)
{
return this.animate(t,n,i,r)
}
}), i.extend({
speed: function(n, t, r)
{
var u=n && typeof n == "object" ? i.extend({},n) : {
complete: r || !r && t || i.isFunction(n) && n,
duration: n,
easing: r && t || t && !i.isFunction(t) && t
};
return u.duration = i.fx.off ? 0 : typeof u.duration == "number" ? u.duration : u.duration in i.fx.speeds ? i.fx.speeds[u.duration] : i.fx.speeds._default, (u.queue == null || u.queue === !0) && (u.queue = "fx"), u.old = u.complete, u.complete = function(n)
{
i.isFunction(u.old) && u.old.call(this), u.queue ? i.dequeue(this,u.queue) : n !== !1 && i._unmark(this)
}, u
},
easing: {
linear: function(n, t, i, r)
{
return i + r * n
},
swing: function(n, t, i, r)
{
return(-Math.cos(n * Math.PI) / 2 + .5) * r + i
}
},
timers: [],
fx: function(n, t, i)
{
this.options = t, this.elem = n, this.prop = i, t.orig = t.orig || {}
}
}), i.fx.prototype = {
update: function()
{
this.options.step && this.options.step.call(this.elem,this.now,this), (i.fx.step[this.prop] || i.fx.step._default)(this)
},
cur: function()
{
if(this.elem[this.prop] != null && (!this.elem.style || this.elem.style[this.prop] == null))
return this.elem[this.prop];
var t,
n=i.css(this.elem,this.prop);
return isNaN(t = parseFloat(n)) ? !n || n === "auto" ? 0 : n : t
},
custom: function(n, r, u)
{
function e(n)
{
return f.step(n)
}
var f=this,
o=i.fx;
this.startTime = tt || oi(), this.end = r, this.now = this.start = n, this.pos = this.state = 0, this.unit = u || this.unit || (i.cssNumber[this.prop] ? "" : "px"), e.queue = this.options.queue, e.elem = this.elem, e.saveState = function()
{
f.options.hide && i._data(f.elem,"fxshow" + f.prop) === t && i._data(f.elem,"fxshow" + f.prop,f.start)
}, e() && i.timers.push(e) && !g && (g = setInterval(o.tick,o.interval))
},
show: function()
{
var n=i._data(this.elem,"fxshow" + this.prop);
this.options.orig[this.prop] = n || i.style(this.elem,this.prop), this.options.show = !0, n !== t ? this.custom(this.cur(),n) : this.custom(this.prop === "width" || this.prop === "height" ? 1 : 0,this.cur()), i(this.elem).show()
},
hide: function()
{
this.options.orig[this.prop] = i._data(this.elem,"fxshow" + this.prop) || i.style(this.elem,this.prop), this.options.hide = !0, this.custom(this.cur(),0)
},
step: function(n)
{
var r,
e,
f,
o=tt || oi(),
s=!0,
u=this.elem,
t=this.options;
if(n || o >= t.duration + this.startTime)
{
this.now = this.end, this.pos = this.state = 1, this.update(), t.animatedProperties[this.prop] = !0;
for(r in t.animatedProperties)
t.animatedProperties[r] !== !0 && (s = !1);
if(s)
{
t.overflow == null || i.support.shrinkWrapBlocks || i.each(["","X","Y"],function(n, i)
{
u.style["overflow" + i] = t.overflow[n]
}), t.hide && i(u).hide();
if(t.hide || t.show)
for(r in t.animatedProperties)
i.style(u,r,t.orig[r]), i.removeData(u,"fxshow" + r,!0), i.removeData(u,"toggle" + r,!0);
f = t.complete, f && (t.complete = !1, f.call(u))
}
return!1
}
return t.duration == Infinity ? this.now = o : (e = o - this.startTime, this.state = e / t.duration, this.pos = i.easing[t.animatedProperties[this.prop]](this.state,e,0,1,t.duration), this.now = this.start + (this.end - this.start) * this.pos), this.update(), !0
}
}, i.extend(i.fx,{
tick: function()
{
for(var r, t=i.timers, n=0; n < t.length; n++)
r = t[n], r() || t[n] !== r || t.splice(n--,1);
t.length || i.fx.stop()
},
interval: 13,
stop: function()
{
clearInterval(g), g = null
},
speeds: {
slow: 600,
fast: 200,
_default: 400
},
step: {
opacity: function(n)
{
i.style(n.elem,"opacity",n.now)
},
_default: function(n)
{
n.elem.style && n.elem.style[n.prop] != null ? n.elem.style[n.prop] = n.now + n.unit : n.elem[n.prop] = n.now
}
}
}), i.each(["width","height"],function(n, t)
{
i.fx.step[t] = function(n)
{
i.style(n.elem,t,Math.max(0,n.now) + n.unit)
}
}), i.expr && i.expr.filters && (i.expr.filters.animated = function(n)
{
return i.grep(i.timers,function(t)
{
return n === t.elem
}).length
}), fi = /^t(?:able|d|h)$/i, ot = /^(?:body|html)$/i, i.fn.offset = "getBoundingClientRect" in r.documentElement ? function(n)
{
var t=this[0],
r,
e,
u;
if(n)
return this.each(function(t)
{
i.offset.setOffset(this,n,t)
});
if(!t || !t.ownerDocument)
return null;
if(t === t.ownerDocument.body)
return i.offset.bodyOffset(t);
try
{
r = t.getBoundingClientRect()
}
catch(y){}
e = t.ownerDocument, u = e.documentElement;
if(!r || !i.contains(u,t))
return r ? {
top: r.top,
left: r.left
} : {
top: 0,
left: 0
};
var f=e.body,
o=it(e),
l=u.clientTop || f.clientTop || 0,
a=u.clientLeft || f.clientLeft || 0,
v=o.pageYOffset || i.support.boxModel && u.scrollTop || f.scrollTop,
s=o.pageXOffset || i.support.boxModel && u.scrollLeft || f.scrollLeft,
h=r.top + v - l,
c=r.left + s - a;
return{
top: h,
left: c
}
} : function(n)
{
var t=this[0];
if(n)
return this.each(function(t)
{
i.offset.setOffset(this,n,t)
});
if(!t || !t.ownerDocument)
return null;
if(t === t.ownerDocument.body)
return i.offset.bodyOffset(t);
var f,
h=t.offsetParent,
a=t,
l=t.ownerDocument,
c=l.documentElement,
o=l.body,
s=l.defaultView,
e=s ? s.getComputedStyle(t,null) : t.currentStyle,
u=t.offsetTop,
r=t.offsetLeft;
while((t = t.parentNode) && t !== o && t !== c)
{
if(i.support.fixedPosition && e.position === "fixed")
break;
f = s ? s.getComputedStyle(t,null) : t.currentStyle, u -= t.scrollTop, r -= t.scrollLeft, t === h && (u += t.offsetTop, r += t.offsetLeft, !i.support.doesNotAddBorder || i.support.doesAddBorderForTableAndCells && fi.test(t.nodeName) || (u += parseFloat(f.borderTopWidth) || 0, r += parseFloat(f.borderLeftWidth) || 0), a = h, h = t.offsetParent), i.support.subtractsBorderForOverflowNotVisible && f.overflow !== "visible" && (u += parseFloat(f.borderTopWidth) || 0, r += parseFloat(f.borderLeftWidth) || 0), e = f
}
return(e.position === "relative" || e.position === "static") && (u += o.offsetTop, r += o.offsetLeft), i.support.fixedPosition && e.position === "fixed" && (u += Math.max(c.scrollTop,o.scrollTop), r += Math.max(c.scrollLeft,o.scrollLeft)), {
top: u,
left: r
}
}, i.offset = {
bodyOffset: function(n)
{
var r=n.offsetTop,
t=n.offsetLeft;
return i.support.doesNotIncludeMarginInBodyOffset && (r += parseFloat(i.css(n,"marginTop")) || 0, t += parseFloat(i.css(n,"marginLeft")) || 0), {
top: r,
left: t
}
},
setOffset: function(n, t, r)
{
var s=i.css(n,"position");
s === "static" && (n.style.position = "relative");
var h=i(n),
c=h.offset(),
l=i.css(n,"top"),
a=i.css(n,"left"),
v=(s === "absolute" || s === "fixed") && i.inArray("auto",[l,a]) > -1,
u={},
e={},
f,
o;
v ? (e = h.position(), f = e.top, o = e.left) : (f = parseFloat(l) || 0, o = parseFloat(a) || 0), i.isFunction(t) && (t = t.call(n,r,c)), t.top != null && (u.top = t.top - c.top + f), t.left != null && (u.left = t.left - c.left + o), "using" in t ? t.using.call(n,u) : h.css(u)
}
}, i.fn.extend({
position: function()
{
if(!this[0])
return null;
var u=this[0],
r=this.offsetParent(),
n=this.offset(),
t=ot.test(r[0].nodeName) ? {
top: 0,
left: 0
} : r.offset();
return n.top -= parseFloat(i.css(u,"marginTop")) || 0, n.left -= parseFloat(i.css(u,"marginLeft")) || 0, t.top += parseFloat(i.css(r[0],"borderTopWidth")) || 0, t.left += parseFloat(i.css(r[0],"borderLeftWidth")) || 0, {
top: n.top - t.top,
left: n.left - t.left
}
},
offsetParent: function()
{
return this.map(function()
{
var n=this.offsetParent || r.body;
while(n && !ot.test(n.nodeName) && i.css(n,"position") === "static")
n = n.offsetParent;
return n
})
}
}), i.each(["Left","Top"],function(n, r)
{
var u="scroll" + r;
i.fn[u] = function(r)
{
var e,
f;
return r === t ? (e = this[0], e ? (f = it(e), f ? "pageXOffset" in f ? f[n ? "pageYOffset" : "pageXOffset"] : i.support.boxModel && f.document.documentElement[u] || f.document.body[u] : e[u]) : null) : this.each(function()
{
f = it(this), f ? f.scrollTo(n ? i(f).scrollLeft() : r,n ? r : i(f).scrollTop()) : this[u] = r
})
}
}), i.each(["Height","Width"],function(n, r)
{
var u=r.toLowerCase();
i.fn["inner" + r] = function()
{
var n=this[0];
return n ? n.style ? parseFloat(i.css(n,u,"padding")) : this[u]() : null
}, i.fn["outer" + r] = function(n)
{
var t=this[0];
return t ? t.style ? parseFloat(i.css(t,u,n ? "margin" : "border")) : this[u]() : null
}, i.fn[u] = function(n)
{
var f=this[0],
s,
h,
e,
o;
return f ? i.isFunction(n) ? this.each(function(t)
{
var r=i(this);
r[u](n.call(this,t,r[u]()))
}) : i.isWindow(f) ? (s = f.document.documentElement["client" + r], h = f.document.body, f.document.compatMode === "CSS1Compat" && s || h && h["client" + r] || s) : f.nodeType === 9 ? Math.max(f.documentElement["client" + r],f.body["scroll" + r],f.documentElement["scroll" + r],f.body["offset" + r],f.documentElement["offset" + r]) : n === t ? (e = i.css(f,u), o = parseFloat(e), i.isNumeric(o) ? o : e) : this.css(u,typeof n == "string" ? n : n + "px") : n == null ? null : this
}
}), n.jQuery = n.$ = i, typeof define == "function" && define.amd && define.amd.jQuery && define("jquery",[],function()
{
return i
})
})(window), function(n)
{
n.extend(n.fn,{
validate: function(t)
{
var i,
r;
if(!this.length)
{
t && t.debug && window.console && console.warn("nothing selected, can't validate, returning nothing");
return
}
return i = n.data(this[0],"validator"), i ? i : (this.attr("novalidate","novalidate"), i = new n.validator(t,this[0]), n.data(this[0],"validator",i), i.settings.onsubmit && (r = this.find("input, button"), r.filter(".cancel").click(function()
{
i.cancelSubmit = !0
}), i.settings.submitHandler && r.filter(":submit").click(function()
{
i.submitButton = this
}), this.submit(function(t)
{
function r()
{
if(i.settings.submitHandler)
{
if(i.submitButton)
var t=n("<input type='hidden'/>").attr("name",i.submitButton.name).val(i.submitButton.value).appendTo(i.currentForm);
return i.settings.submitHandler.call(i,i.currentForm), i.submitButton && t.remove(), !1
}
return!0
}
return i.settings.debug && t.preventDefault(), i.cancelSubmit ? (i.cancelSubmit = !1, r()) : i.form() ? i.pendingRequest ? (i.formSubmitted = !0, !1) : r() : (i.focusInvalid(), !1)
})), i)
},
valid: function()
{
if(n(this[0]).is("form"))
return this.validate().form();
var t=!0,
i=n(this[0].form).validate();
return this.each(function()
{
t &= i.element(this)
}), t
},
removeAttrs: function(t)
{
var r={},
i=this;
return n.each(t.split(/\s/),function(n, t)
{
r[t] = i.attr(t), i.removeAttr(t)
}), r
},
rules: function(t, i)
{
var r=this[0],
e,
u,
s;
if(t)
{
var o=n.data(r.form,"validator").settings,
h=o.rules,
f=n.validator.staticRules(r);
switch(t)
{
case"add":
n.extend(f,n.validator.normalizeRule(i)), h[r.name] = f, i.messages && (o.messages[r.name] = n.extend(o.messages[r.name],i.messages));
break;
case"remove":
return i ? (e = {}, n.each(i.split(/\s/),function(n, t)
{
e[t] = f[t], delete f[t]
}), e) : (delete h[r.name], f)
}
}
return u = n.validator.normalizeRules(n.extend({},n.validator.metadataRules(r),n.validator.classRules(r),n.validator.attributeRules(r),n.validator.staticRules(r)),r), u.required && (s = u.required, delete u.required, u = n.extend({required: s},u)), u
}
}), n.extend(n.expr[":"],{
blank: function(t)
{
return!n.trim("" + t.value)
},
filled: function(t)
{
return!!n.trim("" + t.value)
},
unchecked: function(n)
{
return!n.checked
}
}), n.validator = function(t, i)
{
this.settings = n.extend(!0,{},n.validator.defaults,t), this.currentForm = i, this.init()
}, n.validator.format = function(t, i)
{
return arguments.length == 1 ? function()
{
var i=n.makeArray(arguments);
return i.unshift(t), n.validator.format.apply(this,i)
} : (arguments.length > 2 && i.constructor != Array && (i = n.makeArray(arguments).slice(1)), i.constructor != Array && (i = [i]), n.each(i,function(n, i)
{
t = t.replace(new RegExp("\\{" + n + "\\}","g"),i)
}), t)
}, n.extend(n.validator,{
defaults: {
messages: {},
groups: {},
rules: {},
errorClass: "error",
validClass: "valid",
errorElement: "label",
focusInvalid: !0,
errorContainer: n([]),
errorLabelContainer: n([]),
onsubmit: !0,
ignore: ":hidden",
ignoreTitle: !1,
onfocusin: function(n)
{
this.lastActive = n, this.settings.focusCleanup && !this.blockFocusCleanup && (this.settings.unhighlight && this.settings.unhighlight.call(this,n,this.settings.errorClass,this.settings.validClass), this.addWrapper(this.errorsFor(n)).hide())
},
onfocusout: function(n)
{
!this.checkable(n) && (n.name in this.submitted || !this.optional(n)) && this.element(n)
},
onkeyup: function(n)
{
(n.name in this.submitted || n == this.lastElement) && this.element(n)
},
onclick: function(n)
{
n.name in this.submitted ? this.element(n) : n.parentNode.name in this.submitted && this.element(n.parentNode)
},
highlight: function(t, i, r)
{
t.type === "radio" ? this.findByName(t.name).addClass(i).removeClass(r) : n(t).addClass(i).removeClass(r)
},
unhighlight: function(t, i, r)
{
t.type === "radio" ? this.findByName(t.name).removeClass(i).addClass(r) : n(t).removeClass(i).addClass(r)
}
},
setDefaults: function(t)
{
n.extend(n.validator.defaults,t)
},
messages: {
required: "This field is required.",
remote: "Please fix this field.",
email: "Please enter a valid email address.",
url: "Please enter a valid URL.",
date: "Please enter a valid date.",
dateISO: "Please enter a valid date (ISO).",
number: "Please enter a valid number.",
digits: "Please enter only digits.",
creditcard: "Please enter a valid credit card number.",
equalTo: "Please enter the same value again.",
accept: "Please enter a value with a valid extension.",
maxlength: n.validator.format("Please enter no more than {0} characters."),
minlength: n.validator.format("Please enter at least {0} characters."),
rangelength: n.validator.format("Please enter a value between {0} and {1} characters long."),
range: n.validator.format("Please enter a value between {0} and {1}."),
max: n.validator.format("Please enter a value less than or equal to {0}."),
min: n.validator.format("Please enter a value greater than or equal to {0}.")
},
autoCreateRanges: !1,
prototype: {
init: function()
{
function i(t)
{
var i=n.data(this[0].form,"validator"),
r="on" + t.type.replace(/^validate/,"");
i.settings[r] && i.settings[r].call(i,this[0],t)
}
var r,
t;
this.labelContainer = n(this.settings.errorLabelContainer), this.errorContext = this.labelContainer.length && this.labelContainer || n(this.currentForm), this.containers = n(this.settings.errorContainer).add(this.settings.errorLabelContainer), this.submitted = {}, this.valueCache = {}, this.pendingRequest = 0, this.pending = {}, this.invalid = {}, this.reset(), r = this.groups = {}, n.each(this.settings.groups,function(t, i)
{
n.each(i.split(/\s/),function(n, i)
{
r[i] = t
})
}), t = this.settings.rules, n.each(t,function(i, r)
{
t[i] = n.validator.normalizeRule(r)
}), n(this.currentForm).validateDelegate("[type='text'], [type='password'], [type='file'], select, textarea, [type='number'], [type='search'] ,[type='tel'], [type='url'], [type='email'], [type='datetime'], [type='date'], [type='month'], [type='week'], [type='time'], [type='datetime-local'], [type='range'], [type='color'] ","focusin focusout keyup",i).validateDelegate("[type='radio'], [type='checkbox'], select, option","click",i), this.settings.invalidHandler && n(this.currentForm).bind("invalid-form.validate",this.settings.invalidHandler)
},
form: function()
{
return this.checkForm(), n.extend(this.submitted,this.errorMap), this.invalid = n.extend({},this.errorMap), this.valid() || n(this.currentForm).triggerHandler("invalid-form",[this]), this.showErrors(), this.valid()
},
checkForm: function()
{
this.prepareForm();
for(var n=0, t=this.currentElements = this.elements(); t[n]; n++)
this.check(t[n]);
return this.valid()
},
element: function(t)
{
t = this.validationTargetFor(this.clean(t)), this.lastElement = t, this.prepareElement(t), this.currentElements = n(t);
var i=this.check(t);
return i ? delete this.invalid[t.name] : this.invalid[t.name] = !0, this.numberOfInvalids() || (this.toHide = this.toHide.add(this.containers)), this.showErrors(), i
},
showErrors: function(t)
{
if(t)
{
n.extend(this.errorMap,t), this.errorList = [];
for(var i in t)
this.errorList.push({
message: t[i],
element: this.findByName(i)[0]
});
this.successList = n.grep(this.successList,function(n)
{
return!(n.name in t)
})
}
this.settings.showErrors ? this.settings.showErrors.call(this,this.errorMap,this.errorList) : this.defaultShowErrors()
},
resetForm: function()
{
n.fn.resetForm && n(this.currentForm).resetForm(), this.submitted = {}, this.lastElement = null, this.prepareForm(), this.hideErrors(), this.elements().removeClass(this.settings.errorClass)
},
numberOfInvalids: function()
{
return this.objectLength(this.invalid)
},
objectLength: function(n)
{
var t=0,
i;
for(i in n)
t++;
return t
},
hideErrors: function()
{
this.addWrapper(this.toHide).hide()
},
valid: function()
{
return this.size() == 0
},
size: function()
{
return this.errorList.length
},
focusInvalid: function()
{
if(this.settings.focusInvalid)
try
{
n(this.findLastActive() || this.errorList.length && this.errorList[0].element || []).filter(":visible").focus().trigger("focusin")
}
catch(t){}
},
findLastActive: function()
{
var t=this.lastActive;
return t && n.grep(this.errorList,function(n)
{
return n.element.name == t.name
}).length == 1 && t
},
elements: function()
{
var i=this,
t={};
return n(this.currentForm).find("input, select, textarea").not(":submit, :reset, :image, [disabled]").not(this.settings.ignore).filter(function()
{
return!this.name && i.settings.debug && window.console && console.error("%o has no name assigned",this), this.name in t || !i.objectLength(n(this).rules()) ? !1 : (t[this.name] = !0, !0)
})
},
clean: function(t)
{
return n(t)[0]
},
errors: function()
{
return n(this.settings.errorElement + "." + this.settings.errorClass,this.errorContext)
},
reset: function()
{
this.successList = [], this.errorList = [], this.errorMap = {}, this.toShow = n([]), this.toHide = n([]), this.currentElements = n([])
},
prepareForm: function()
{
this.reset(), this.toHide = this.errors().add(this.containers)
},
prepareElement: function(n)
{
this.reset(), this.toHide = this.errorsFor(n)
},
check: function(t)
{
var f,
e,
u,
i,
r;
t = this.validationTargetFor(this.clean(t)), f = n(t).rules(), e = !1;
for(u in f)
{
i = {
method: u,
parameters: f[u]
};
try
{
r = n.validator.methods[u].call(this,t.value.replace(/\r/g,""),t,i.parameters);
if(r == "dependency-mismatch")
{
e = !0;
continue
}
e = !1;
if(r == "pending")
{
this.toHide = this.toHide.not(this.errorsFor(t));
return
}
if(!r)
return this.formatAndAdd(t,i), !1
}
catch(o)
{
this.settings.debug && window.console && console.log("exception occured when checking element " + t.id + ", check the '" + i.method + "' method",o);
throw o;
}
}
if(!e)
return this.objectLength(f) && this.successList.push(t), !0
},
customMetaMessage: function(t, i)
{
if(!n.metadata)
return;
var r=this.settings.meta ? n(t).metadata()[this.settings.meta] : n(t).metadata();
return r && r.messages && r.messages[i]
},
customMessage: function(n, t)
{
var i=this.settings.messages[n];
return i && (i.constructor == String ? i : i[t])
},
findDefined: function()
{
for(var n=0; n < arguments.length; n++)
if(arguments[n] !== undefined)
return arguments[n];
return undefined
},
defaultMessage: function(t, i)
{
return this.findDefined(this.customMessage(t.name,i),this.customMetaMessage(t,i),!this.settings.ignoreTitle && t.title || undefined,n.validator.messages[i],"<strong>Warning: No message defined for " + t.name + "</strong>")
},
formatAndAdd: function(n, t)
{
var i=this.defaultMessage(n,t.method),
r=/\$?\{(\d+)\}/g;
typeof i == "function" ? i = i.call(this,t.parameters,n) : r.test(i) && (i = jQuery.format(i.replace(r,"{$1}"),t.parameters)), this.errorList.push({
message: i,
element: n
}), this.errorMap[n.name] = i, this.submitted[n.name] = i
},
addWrapper: function(n)
{
return this.settings.wrapper && (n = n.add(n.parent(this.settings.wrapper))), n
},
defaultShowErrors: function()
{
for(var t, i, n=0; this.errorList[n]; n++)
t = this.errorList[n], this.settings.highlight && this.settings.highlight.call(this,t.element,this.settings.errorClass,this.settings.validClass), this.showLabel(t.element,t.message);
this.errorList.length && (this.toShow = this.toShow.add(this.containers));
if(this.settings.success)
for(n = 0; this.successList[n]; n++)
this.showLabel(this.successList[n]);
if(this.settings.unhighlight)
for(n = 0, i = this.validElements(); i[n]; n++)
this.settings.unhighlight.call(this,i[n],this.settings.errorClass,this.settings.validClass);
this.toHide = this.toHide.not(this.toShow), this.hideErrors(), this.addWrapper(this.toShow).show()
},
validElements: function()
{
return this.currentElements.not(this.invalidElements())
},
invalidElements: function()
{
return n(this.errorList).map(function()
{
return this.element
})
},
showLabel: function(t, i)
{
var r=this.errorsFor(t);
r.length ? (r.removeClass(this.settings.validClass).addClass(this.settings.errorClass), r.attr("generated") && r.html(i)) : (r = n("<" + this.settings.errorElement + "/>").attr({
"for": this.idOrName(t),
generated: !0
}).addClass(this.settings.errorClass).html(i || ""), this.settings.wrapper && (r = r.hide().show().wrap("<" + this.settings.wrapper + "/>").parent()), this.labelContainer.append(r).length || (this.settings.errorPlacement ? this.settings.errorPlacement(r,n(t)) : r.insertAfter(t))), !i && this.settings.success && (r.text(""), typeof this.settings.success == "string" ? r.addClass(this.settings.success) : this.settings.success(r)), this.toShow = this.toShow.add(r)
},
errorsFor: function(t)
{
var i=this.idOrName(t);
return this.errors().filter(function()
{
return n(this).attr("for") == i
})
},
idOrName: function(n)
{
return this.groups[n.name] || (this.checkable(n) ? n.name : n.id || n.name)
},
validationTargetFor: function(n)
{
return this.checkable(n) && (n = this.findByName(n.name).not(this.settings.ignore)[0]), n
},
checkable: function(n)
{
return/radio|checkbox/i.test(n.type)
},
findByName: function(t)
{
var i=this.currentForm;
return n(document.getElementsByName(t)).map(function(n, r)
{
return r.form == i && r.name == t && r || null
})
},
getLength: function(t, i)
{
switch(i.nodeName.toLowerCase())
{
case"select":
return n("option:selected",i).length;
case"input":
if(this.checkable(i))
return this.findByName(i.name).filter(":checked").length
}
return t.length
},
depend: function(n, t)
{
return this.dependTypes[typeof n] ? this.dependTypes[typeof n](n,t) : !0
},
dependTypes: {
boolean: function(n)
{
return n
},
string: function(t, i)
{
return!!n(t,i.form).length
},
"function": function(n, t)
{
return n(t)
}
},
optional: function(t)
{
return!n.validator.methods.required.call(this,n.trim(t.value),t) && "dependency-mismatch"
},
startRequest: function(n)
{
this.pending[n.name] || (this.pendingRequest++, this.pending[n.name] = !0)
},
stopRequest: function(t, i)
{
this.pendingRequest--, this.pendingRequest < 0 && (this.pendingRequest = 0), delete this.pending[t.name], i && this.pendingRequest == 0 && this.formSubmitted && this.form() ? (n(this.currentForm).submit(), this.formSubmitted = !1) : !i && this.pendingRequest == 0 && this.formSubmitted && (n(this.currentForm).triggerHandler("invalid-form",[this]), this.formSubmitted = !1)
},
previousValue: function(t)
{
return n.data(t,"previousValue") || n.data(t,"previousValue",{
old: null,
valid: !0,
message: this.defaultMessage(t,"remote")
})
}
},
classRuleSettings: {
required: {required: !0},
email: {email: !0},
url: {url: !0},
date: {date: !0},
dateISO: {dateISO: !0},
dateDE: {dateDE: !0},
number: {number: !0},
numberDE: {numberDE: !0},
digits: {digits: !0},
creditcard: {creditcard: !0}
},
addClassRules: function(t, i)
{
t.constructor == String ? this.classRuleSettings[t] = i : n.extend(this.classRuleSettings,t)
},
classRules: function(t)
{
var r={},
i=n(t).attr("class");
return i && n.each(i.split(" "),function()
{
this in n.validator.classRuleSettings && n.extend(r,n.validator.classRuleSettings[this])
}), r
},
attributeRules: function(t)
{
var r={},
f=n(t),
i,
u;
for(i in n.validator.methods)
u = i === "required" && typeof n.fn.prop == "function" ? f.prop(i) : f.attr(i), u ? r[i] = u : f[0].getAttribute("type") === i && (r[i] = !0);
return r.maxlength && /-1|2147483647|524288/.test(r.maxlength) && delete r.maxlength, r
},
metadataRules: function(t)
{
if(!n.metadata)
return{};
var i=n.data(t.form,"validator").settings.meta;
return i ? n(t).metadata()[i] : n(t).metadata()
},
staticRules: function(t)
{
var r={},
i=n.data(t.form,"validator");
return i.settings.rules && (r = n.validator.normalizeRule(i.settings.rules[t.name]) || {}), r
},
normalizeRules: function(t, i)
{
return n.each(t,function(r, u)
{
if(u === !1)
{
delete t[r];
return
}
if(u.param || u.depends)
{
var f=!0;
switch(typeof u.depends)
{
case"string":
f = !!n(u.depends,i.form).length;
break;
case"function":
f = u.depends.call(i,i)
}
f ? t[r] = u.param !== undefined ? u.param : !0 : delete t[r]
}
}), n.each(t,function(r, u)
{
t[r] = n.isFunction(u) ? u(i) : u
}), n.each(["minlength","maxlength","min","max"],function()
{
t[this] && (t[this] = Number(t[this]))
}), n.each(["rangelength","range"],function()
{
t[this] && (t[this] = [Number(t[this][0]),Number(t[this][1])])
}), n.validator.autoCreateRanges && (t.min && t.max && (t.range = [t.min,t.max], delete t.min, delete t.max), t.minlength && t.maxlength && (t.rangelength = [t.minlength,t.maxlength], delete t.minlength, delete t.maxlength)), t.messages && delete t.messages, t
},
normalizeRule: function(t)
{
if(typeof t == "string")
{
var i={};
n.each(t.split(/\s/),function()
{
i[this] = !0
}), t = i
}
return t
},
addMethod: function(t, i, r)
{
n.validator.methods[t] = i, n.validator.messages[t] = r != undefined ? r : n.validator.messages[t], i.length < 3 && n.validator.addClassRules(t,n.validator.normalizeRule(t))
},
methods: {
required: function(t, i, r)
{
if(!this.depend(r,i))
return"dependency-mismatch";
switch(i.nodeName.toLowerCase())
{
case"select":
var u=n(i).val();
return u && u.length > 0;
case"input":
if(this.checkable(i))
return this.getLength(t,i) > 0;
default:
return n.trim(t).length > 0
}
},
remote: function(t, i, r)
{
var f,
u,
e;
if(this.optional(i))
return"dependency-mismatch";
return f = this.previousValue(i), this.settings.messages[i.name] || (this.settings.messages[i.name] = {}), f.originalMessage = this.settings.messages[i.name].remote, this.settings.messages[i.name].remote = f.message, r = typeof r == "string" && {url: r} || r, this.pending[i.name] ? "pending" : f.old === t ? f.valid : (f.old = t, u = this, this.startRequest(i), e = {}, e[i.name] = t, n.ajax(n.extend(!0,{
url: r,
mode: "abort",
port: "validate" + i.name,
dataType: "json",
data: e,
success: function(r)
{
var o,
h,
s,
e;
u.settings.messages[i.name].remote = f.originalMessage, o = r === !0, o ? (h = u.formSubmitted, u.prepareElement(i), u.formSubmitted = h, u.successList.push(i), u.showErrors()) : (s = {}, e = r || u.defaultMessage(i,"remote"), s[i.name] = f.message = n.isFunction(e) ? e(t) : e, u.showErrors(s)), f.valid = o, u.stopRequest(i,o)
}
},r)), "pending")
},
minlength: function(t, i, r)
{
return this.optional(i) || this.getLength(n.trim(t),i) >= r
},
maxlength: function(t, i, r)
{
return this.optional(i) || this.getLength(n.trim(t),i) <= r
},
rangelength: function(t, i, r)
{
var u=this.getLength(n.trim(t),i);
return this.optional(i) || u >= r[0] && u <= r[1]
},
min: function(n, t, i)
{
return this.optional(t) || n >= i
},
max: function(n, t, i)
{
return this.optional(t) || n <= i
},
range: function(n, t, i)
{
return this.optional(t) || n >= i[0] && n <= i[1]
},
email: function(n, t)
{
return this.optional(t) || /^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i.test(n)
},
url: function(n, t)
{
return this.optional(t) || /^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i.test(n)
},
date: function(n, t)
{
return this.optional(t) || !/Invalid|NaN/.test(new Date(n))
},
dateISO: function(n, t)
{
return this.optional(t) || /^\d{4}[\/-]\d{1,2}[\/-]\d{1,2}$/.test(n)
},
number: function(n, t)
{
return this.optional(t) || /^-?(?:\d+|\d{1,3}(?:,\d{3})+)(?:\.\d+)?$/.test(n)
},
digits: function(n, t)
{
return this.optional(t) || /^\d+$/.test(n)
},
creditcard: function(n, t)
{
var i,
f,
r;
if(this.optional(t))
return"dependency-mismatch";
if(/[^0-9 -]+/.test(n))
return!1;
var e=0,
r=0,
u=!1;
for(n = n.replace(/\D/g,""), i = n.length - 1; i >= 0; i--)
f = n.charAt(i), r = parseInt(f,10), u && (r *= 2) > 9 && (r -= 9), e += r, u = !u;
return e % 10 == 0
},
accept: function(n, t, i)
{
return i = typeof i == "string" ? i.replace(/,/g,"|") : "png|jpe?g|gif", this.optional(t) || n.match(new RegExp(".(" + i + ")$","i"))
},
equalTo: function(t, i, r)
{
var u=n(r).unbind(".validate-equalTo").bind("blur.validate-equalTo",function()
{
n(i).valid()
});
return t == u.val()
}
}
}), n.format = n.validator.format
}(jQuery), function(n)
{
var t={},
i;
n.ajaxPrefilter ? n.ajaxPrefilter(function(n, i, r)
{
var u=n.port;
n.mode == "abort" && (t[u] && t[u].abort(), t[u] = r)
}) : (i = n.ajax, n.ajax = function(r)
{
var f=("mode" in r ? r : n.ajaxSettings).mode,
u=("port" in r ? r : n.ajaxSettings).port;
return f == "abort" ? (t[u] && t[u].abort(), t[u] = i.apply(this,arguments)) : i.apply(this,arguments)
})
}(jQuery), function(n)
{
jQuery.event.special.focusin || jQuery.event.special.focusout || !document.addEventListener || n.each({
focus: "focusin",
blur: "focusout"
},function(t, i)
{
function r(t)
{
return t = n.event.fix(t), t.type = i, n.event.handle.call(this,t)
}
n.event.special[i] = {
setup: function()
{
this.addEventListener(t,r,!0)
},
teardown: function()
{
this.removeEventListener(t,r,!0)
},
handler: function(t)
{
return arguments[0] = n.event.fix(t), arguments[0].type = i, n.event.handle.apply(this,arguments)
}
}
}), n.extend(n.fn,{validateDelegate: function(t, i, r)
{
return this.bind(i,function(i)
{
var u=n(i.target);
if(u.is(t))
return r.apply(u,arguments)
})
}})
}(jQuery), jQuery.extend(jQuery.validator.methods,{number: function(n, t)
{
return this.optional(t) || /^-?(?:\d+(,\d+)?|\d{1,3}(?:,\d{3})+)(?:\.\d+)?$/.test(n)
}}), jQuery.extend(jQuery.validator.messages,{
required: "Detta f&auml;lt &auml;r obligatoriskt.",
maxlength: jQuery.validator.format("Du f&aring;r ange h&ouml;gst {0} tecken."),
minlength: jQuery.validator.format("Du m&aring;ste ange minst {0} tecken."),
rangelength: jQuery.validator.format("Ange minst {0} och max {1} tecken."),
email: "Ange en korrekt e-postadress.",
url: "Ange en korrekt URL.",
date: "Ange ett korrekt datum.",
dateISO: "Ange ett korrekt datum (&ARING;&ARING;&ARING;&ARING;-MM-DD).",
number: "Ange ett korrekt nummer.",
digits: "Ange endast siffror.",
equalTo: "Ange samma v&auml;rde igen.",
range: jQuery.validator.format("Ange ett v&auml;rde mellan {0} och {1}."),
max: jQuery.validator.format("Ange ett v&auml;rde som &auml;r mindre eller lika med {0}."),
min: jQuery.validator.format("Ange ett v&auml;rde som &auml;r st&ouml;rre eller lika med {0}."),
creditcard: "Ange ett korrekt kreditkortsnummer."
}), $(function()
{
function r(n, t)
{
try
{
n && (n.length == 13 || n.length == 11) && t.value != n && (t.value = n)
}
catch(i){}
}
function f(n)
{
var t=0;
return n.length == 12 && (t = 2), n.charAt(2 + t) >= 2 ? "o" : n.charAt(4 + t) >= 6 ? "s" : "p"
}
function t(t, r)
{
function s(n, t)
{
function i(n, t, i)
{
return parseInt(n.substr(t,i),10)
}
var r={
y: i(n,0,t),
m: i(n,t,2),
d: i(n,2 + t,2)
};
return r.d < 60 || (r.d -= 60), r
}
function h(n)
{
var t={
y: e.getFullYear(),
m: e.getMonth() + 1,
d: e.getDate()
},
i=t.y % 100;
return n.y < i || n.y == i && n.m < t.m || n.y == i && n.m == t.m && n.d <= t.d ? 20 : 19
}
var e=new Date,
u,
o,
f;
r == 10 ? (u = s(t,2), o = h(u), u.y += 100 * o, t = "" + o + t, n = t.substr(0,8) + "-" + t.substr(8)) : (u = s(t,4), r == 12 && (n = t.substr(0,8) + "-" + t.substr(8)));
if(t.length != 12 || u.y < 1900 || u.m > 12)
return!1;
return f = new Date(u.y,u.m - 1,u.d), f > e || f.getFullYear() != u.y || f.getMonth() != u.m - 1 || f.getDate() != u.d ? !1 : i(t)
}
function e(t, r)
{
return r == 10 && (t = "16" + t, n = t.substr(2,6) + "-" + t.substr(8)), t.length != 12 || t.substr(0,2) != "16" || t[4] < 2 ? !1 : i(t)
}
function i(n)
{
for(var i, r=0, t=2; t < 11; ++t)
i = parseInt(n.substr(t,1),10), i *= 1 + (1 + t) % 2, r += Math.floor(i / 10) + i % 10;
return(10 - r % 10) % 10 == n.substr(11,1)
}
function u(i, u, o, s, h)
{
n = ("" + i).replace(/\D/g,"");
var l=n.length,
c=!0;
if(l < 10)
return!1;
switch(f(n))
{
case"o":
c = h && e(n,l);
break;
case"p":
c = o && t(n,l);
break;
case"s":
c = s && t(n,l)
}
return c && r(n,u), c
}
var n;
jQuery.validator.addMethod("sweid",function(n, t, i)
{
return this.optional(t) || u(n,t,i.pn,i.sn,i.on)
},"Var vänlig fyll i ett korrekt personnummer"), $.validator.unobtrusive.adapters.add("sweid",["on","pn","sn"],function(n)
{
n.rules.sweid = n.params, n.message && (n.messages.sweid = n.message)
})
});
/*!
** Unobtrusive validation support library for jQuery and jQuery Validate
** Copyright (C) Microsoft Corporation. All rights reserved.
*/
(function(n)
{
function i(n, t, i)
{
n.rules[t] = i, n.message && (n.messages[t] = n.message)
}
function h(n)
{
return n.replace(/^\s+|\s+$/g,"").split(/\s*,\s*/g)
}
function u(n)
{
return n.substr(0,n.lastIndexOf(".") + 1)
}
function f(n, t)
{
return n.indexOf("*.") === 0 && (n = n.replace("*.",t)), n
}
function c(t, i)
{
var r=n(this).find("[data-valmsg-for='" + i[0].name + "']"),
u=n.parseJSON(r.attr("data-valmsg-replace")) !== !1;
r.removeClass("field-validation-valid").addClass("field-validation-error"), t.data("unobtrusiveContainer",r), u ? (r.empty(), t.removeClass("input-validation-error").appendTo(r)) : t.hide()
}
function l(t, i)
{
var u=n(this).find("[data-valmsg-summary=true]"),
r=u.find("ul");
r && r.length && i.errorList.length && (r.empty(), u.addClass("validation-summary-errors").removeClass("validation-summary-valid"), n.each(i.errorList,function()
{
n("<li />").html(this.message).appendTo(r)
}))
}
function s(t)
{
var i=t.data("unobtrusiveContainer"),
r=n.parseJSON(i.attr("data-valmsg-replace"));
i && (i.addClass("field-validation-valid").removeClass("field-validation-error"), t.removeData("unobtrusiveContainer"), r && i.empty())
}
function o(t)
{
var i=n(t),
r=i.data(e);
return r || (r = {
options: {
errorClass: "input-validation-error",
errorElement: "span",
errorPlacement: n.proxy(c,t),
invalidHandler: n.proxy(l,t),
messages: {},
rules: {},
success: n.proxy(s,t)
},
attachValidation: function()
{
i.validate(this.options)
},
validate: function()
{
return i.validate(), i.valid()
}
}, i.data(e,r)), r
}
var r=n.validator,
t,
e="unobtrusiveValidation";
r.unobtrusive = {
adapters: [],
parseElement: function(t, i)
{
var f=n(t),
e=f.parents("form")[0],
r,
u,
s;
if(!e)
return;
r = o(e), r.options.rules[t.name] = u = {}, r.options.messages[t.name] = s = {}, n.each(this.adapters,function()
{
var i="data-val-" + this.name,
o=f.attr(i),
r={};
o !== undefined && (i += "-", n.each(this.params,function()
{
r[this] = f.attr(i + this)
}), this.adapt({
element: t,
form: e,
message: o,
params: r,
rules: u,
messages: s
}))
}), jQuery.extend(u,{__dummy__: !0}), i || r.attachValidation()
},
parse: function(t)
{
n(t).find(":input[data-val=true]").each(function()
{
r.unobtrusive.parseElement(this,!0)
}), n("form").each(function()
{
var n=o(this);
n && n.attachValidation()
})
}
}, t = r.unobtrusive.adapters, t.add = function(n, t, i)
{
return i || (i = t, t = []), this.push({
name: n,
params: t,
adapt: i
}), this
}, t.addBool = function(n, t)
{
return this.add(n,function(r)
{
i(r,t || n,!0)
})
}, t.addMinMax = function(n, t, r, u, f, e)
{
return this.add(n,[f || "min",e || "max"],function(n)
{
var e=n.params.min,
f=n.params.max;
e && f ? i(n,u,[e,f]) : e ? i(n,t,e) : f && i(n,r,f)
})
}, t.addSingleVal = function(n, t, r)
{
return this.add(n,[t || "val"],function(u)
{
i(u,r || n,u.params[t])
})
}, r.addMethod("__dummy__",function()
{
return!0
}), r.addMethod("regex",function(n, t, i)
{
var r;
return this.optional(t) ? !0 : (r = new RegExp(i).exec(n), r && r.index === 0 && r[0].length === n.length)
}), t.addSingleVal("accept","exts").addSingleVal("regex","pattern"), t.addBool("creditcard").addBool("date").addBool("digits").addBool("email").addBool("number").addBool("url"), t.addMinMax("length","minlength","maxlength","rangelength").addMinMax("range","min","max","range"), t.add("equalto",["other"],function(t)
{
var o=u(t.element.name),
s=t.params.other,
r=f(s,o),
e=n(t.form).find(":input[name=" + r + "]")[0];
i(t,"equalTo",e)
}), t.add("required",function(n)
{
(n.element.tagName.toUpperCase() !== "INPUT" || n.element.type.toUpperCase() !== "CHECKBOX") && i(n,"required",!0)
}), t.add("remote",["url","type","additionalfields"],function(t)
{
var r={
url: t.params.url,
type: t.params.type || "GET",
data: {}
},
e=u(t.element.name);
n.each(h(t.params.additionalfields || t.element.name),function(i, u)
{
var o=f(u,e);
r.data[o] = function()
{
return n(t.form).find(":input[name='" + o + "']").val()
}
}), i(t,"remote",r)
}), n(function()
{
r.unobtrusive.parse(document)
})
})(jQuery);
/*!
** Unobtrusive Ajax support library for jQuery
** Copyright (C) Microsoft Corporation. All rights reserved.
*/
(function(n)
{
function i(n, t)
{
var i=window,
r=(n || "").split(".");
while(i && r.length)
i = i[r.shift()];
return typeof i == "function" ? i : (t.push(n), Function.constructor.apply(null,t))
}
function u(n)
{
return n === "GET" || n === "POST"
}
function o(n, t)
{
u(t) || n.setRequestHeader("X-HTTP-Method-Override",t)
}
function s(t, i, r)
{
var u;
if(r.indexOf("application/x-javascript") !== -1)
return;
u = (t.getAttribute("data-ajax-mode") || "").toUpperCase(), n(t.getAttribute("data-ajax-update")).each(function(t, r)
{
var f;
switch(u)
{
case"BEFORE":
f = r.firstChild, n("<div />").html(i).contents().each(function()
{
r.insertBefore(this,f)
});
break;
case"AFTER":
n("<div />").html(i).contents().each(function()
{
r.appendChild(this)
});
break;
default:
n(r).html(i)
}
})
}
function r(t, r)
{
var h,
c,
f,
e;
h = t.getAttribute("data-ajax-confirm");
if(h && !window.confirm(h))
return;
c = n(t.getAttribute("data-ajax-loading")), e = t.getAttribute("data-ajax-loading-duration") || 0, n.extend(r,{
type: t.getAttribute("data-ajax-method") || undefined,
url: t.getAttribute("data-ajax-url") || undefined,
beforeSend: function(n)
{
var r;
return o(n,f), r = i(t.getAttribute("data-ajax-begin"),["xhr"]).apply(this,arguments), r !== !1 && c.show(e), r
},
complete: function()
{
c.hide(e), i(t.getAttribute("data-ajax-complete"),["xhr","status"]).apply(this,arguments)
},
success: function(n, r, u)
{
s(t,n,u.getResponseHeader("Content-Type") || "text/html"), i(t.getAttribute("data-ajax-success"),["data","status","xhr"]).apply(this,arguments)
},
error: i(t.getAttribute("data-ajax-failure"),["xhr","status","error"])
}), r.data.push({
name: "X-Requested-With",
value: "XMLHttpRequest"
}), f = r.type.toUpperCase(), u(f) || (r.type = "POST", r.data.push({
name: "X-HTTP-Method-Override",
value: f
})), n.ajax(r)
}
function e(t)
{
var i=n(t).data(f);
return!i || !i.validate || i.validate()
}
var t="unobtrusiveAjaxClick",
f="unobtrusiveValidation";
n("a[data-ajax=true]").live("click",function(n)
{
n.preventDefault(), r(this,{
url: this.href,
type: "GET",
data: []
})
}), n("form[data-ajax=true] input[type=image]").live("click",function(i)
{
var f=i.target.name,
e=n(i.target),
r=e.parents("form")[0],
u=e.offset();
n(r).data(t,[{
name: f + ".x",
value: Math.round(i.pageX - u.left)
},{
name: f + ".y",
value: Math.round(i.pageY - u.top)
}]), setTimeout(function()
{
n(r).removeData(t)
},0)
}), n("form[data-ajax=true] :submit").live("click",function(i)
{
var u=i.target.name,
r=n(i.target).parents("form")[0];
n(r).data(t,u ? [{
name: u,
value: i.target.value
}] : []), setTimeout(function()
{
n(r).removeData(t)
},0)
}), n("form[data-ajax=true]").live("submit",function(i)
{
var u=n(this).data(t) || [];
i.preventDefault();
if(!e(this))
return;
r(this,{
url: this.action,
type: this.method || "GET",
data: u.concat(n(this).serializeArray())
})
})
})(jQuery);
/*!
 * jQuery blockUI plugin
 * Version 2.39 (23-MAY-2011)
 * @requires jQuery v1.2.3 or later
 *
 * Examples at: http://malsup.com/jquery/block/
 * Copyright (c) 2007-2010 M. Alsup
 * Dual licensed under the MIT and GPL licenses:
 * http://www.opensource.org/licenses/mit-license.php
 * http://www.gnu.org/licenses/gpl.html
 *
 * Thanks to Amir-Hossein Sobhi for some excellent contributions!
 */
(function(n)
{
function h(e, o)
{
var a=e == window,
h=o && o.message !== undefined ? o.message : undefined,
ot,
st,
d,
w,
ht,
lt,
ct,
ut;
o = n.extend({},n.blockUI.defaults,o || {}), o.overlayCSS = n.extend({},n.blockUI.defaults.overlayCSS,o.overlayCSS || {}), ot = n.extend({},n.blockUI.defaults.css,o.css || {}), st = n.extend({},n.blockUI.defaults.themedCSS,o.themedCSS || {}), h = h === undefined ? o.message : h, a && i && u(window,{fadeOut: 0}), h && typeof h != "string" && (h.parentNode || h.jquery) && (d = h.jquery ? h[0] : h, w = {}, n(e).data("blockUI.history",w), w.el = d, w.parent = d.parentNode, w.display = d.style.display, w.position = d.style.position, w.parent && w.parent.removeChild(d)), n(e).data("blockUI.onUnblock",o.onUnblock);
var b=o.baseZ,
nt=n.browser.msie || o.forceIframe ? n('<iframe class="blockUI" style="z-index:' + b++ + ';display:none;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="' + o.iframeSrc + '"></iframe>') : n('<div class="blockUI" style="display:none"></div>'),
k=o.theme ? n('<div class="blockUI blockOverlay ui-widget-overlay" style="z-index:' + b++ + ';display:none"></div>') : n('<div class="blockUI blockOverlay" style="z-index:' + b++ + ';display:none;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>'),
p,
g;
g = o.theme && a ? '<div class="blockUI ' + o.blockMsgClass + ' blockPage ui-dialog ui-widget ui-corner-all" style="z-index:' + (b + 10) + ';display:none;position:fixed"><div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">' + (o.title || "&nbsp;") + '</div><div class="ui-widget-content ui-dialog-content"></div></div>' : o.theme ? '<div class="blockUI ' + o.blockMsgClass + ' blockElement ui-dialog ui-widget ui-corner-all" style="z-index:' + (b + 10) + ';display:none;position:absolute"><div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">' + (o.title || "&nbsp;") + '</div><div class="ui-widget-content ui-dialog-content"></div></div>' : a ? '<div class="blockUI ' + o.blockMsgClass + ' blockPage" style="z-index:' + (b + 10) + ';display:none;position:fixed"></div>' : '<div class="blockUI ' + o.blockMsgClass + ' blockElement" style="z-index:' + (b + 10) + ';display:none;position:absolute"></div>', p = n(g), h && (o.theme ? (p.css(st), p.addClass("ui-widget-content")) : p.css(ot)), o.theme || o.applyPlatformOpacityRules && n.browser.mozilla && /Linux/.test(navigator.platform) || k.css(o.overlayCSS), k.css("position",a ? "fixed" : "absolute"), (n.browser.msie || o.forceIframe) && nt.css("opacity",0), ht = [nt,k,p], lt = a ? n("body") : n(e), n.each(ht,function()
{
this.appendTo(lt)
}), o.theme && o.draggable && n.fn.draggable && p.draggable({
handle: ".ui-dialog-titlebar",
cancel: "li"
}), ct = v && (!n.boxModel || n("object,embed",a ? null : e).length > 0);
if(l || ct)
{
a && o.allowBodyStretch && n.boxModel && n("html,body").css("height","100%");
if((l || !n.boxModel) && !a)
var et=r(e,"borderTopWidth"),
tt=r(e,"borderLeftWidth"),
it=et ? "(0 - " + et + ")" : 0,
rt=tt ? "(0 - " + tt + ")" : 0;
n.each([nt,k,p],function(n, t)
{
var i=t[0].style,
u,
r;
i.position = "absolute", n < 2 ? (a ? i.setExpression("height","Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.boxModel?0:" + o.quirksmodeOffsetHack + ') + "px"') : i.setExpression("height",'this.parentNode.offsetHeight + "px"'), a ? i.setExpression("width",'jQuery.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"') : i.setExpression("width",'this.parentNode.offsetWidth + "px"'), rt && i.setExpression("left",rt), it && i.setExpression("top",it)) : o.centerY ? (a && i.setExpression("top",'(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"'), i.marginTop = 0) : !o.centerY && a && (u = o.css && o.css.top ? parseInt(o.css.top) : 0, r = "((document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + " + u + ') + "px"', i.setExpression("top",r))
})
}
h && (o.theme ? p.find(".ui-widget-content").append(h) : p.append(h), (h.jquery || h.nodeType) && n(h).show()), (n.browser.msie || o.forceIframe) && o.showOverlay && nt.show();
if(o.fadeIn)
{
var ft=o.onBlock ? o.onBlock : f,
at=o.showOverlay && !h ? ft : f,
vt=h ? ft : f;
o.showOverlay && k._fadeIn(o.fadeIn,at), h && p._fadeIn(o.fadeIn,vt)
}
else
o.showOverlay && k.show(), h && p.show(), o.onBlock && o.onBlock();
c(1,e,o), a ? (i = p[0], t = n(":input:enabled:visible",i), o.focusInput && setTimeout(s,20)) : y(p[0],o.centerX,o.centerY), o.timeout && (ut = setTimeout(function()
{
a ? n.unblockUI(o) : n(e).unblock(o)
},o.timeout), n(e).data("blockUI.timeout",ut))
}
function u(r, u)
{
var o=r == window,
e=n(r),
h=e.data("blockUI.history"),
s=e.data("blockUI.timeout"),
f;
s && (clearTimeout(s), e.removeData("blockUI.timeout")), u = n.extend({},n.blockUI.defaults,u || {}), c(0,r,u), u.onUnblock === null && (u.onUnblock = e.data("blockUI.onUnblock"), e.removeData("blockUI.onUnblock")), f = o ? n("body").children().filter(".blockUI").add("body > .blockUI") : n(".blockUI",r), o && (i = t = null), u.fadeOut ? (f.fadeOut(u.fadeOut), setTimeout(function()
{
a(f,h,u,r)
},u.fadeOut)) : a(f,h,u,r)
}
function a(t, i, r, u)
{
t.each(function()
{
this.parentNode && this.parentNode.removeChild(this)
}), i && i.el && (i.el.style.display = i.display, i.el.style.position = i.position, i.parent && i.parent.appendChild(i.el), n(u).removeData("blockUI.history"));
if(typeof r.onUnblock == "function")
r.onUnblock(u,r)
}
function c(t, r, u)
{
var e=r == window,
s=n(r),
f;
if(!t && (e && !i || !e && !s.data("blockUI.isBlocked")))
return;
e || s.data("blockUI.isBlocked",t);
if(!u.bindEvents || t && !u.showOverlay)
return;
f = "mousedown mouseup keydown keypress", t ? n(document).bind(f,u,o) : n(document).unbind(f,o)
}
function o(r)
{
var e;
if(r.keyCode && r.keyCode == 9)
if(i && r.data.constrainTabKey)
{
var u=t,
o=!r.shiftKey && r.target === u[u.length - 1],
f=r.shiftKey && r.target === u[0];
if(o || f)
return setTimeout(function()
{
s(f)
},10), !1
}
return e = r.data, n(r.target).parents("div." + e.blockMsgClass).length > 0 ? !0 : n(r.target).parents().children().filter("div.blockUI").length == 0
}
function s(n)
{
if(!t)
return;
var i=t[n === !0 ? t.length - 1 : 0];
i && i.focus()
}
function y(n, t, i)
{
var u=n.parentNode,
o=n.style,
e=(u.offsetWidth - n.offsetWidth) / 2 - r(u,"borderLeftWidth"),
f=(u.offsetHeight - n.offsetHeight) / 2 - r(u,"borderTopWidth");
t && (o.left = e > 0 ? e + "px" : "0"), i && (o.top = f > 0 ? f + "px" : "0")
}
function r(t, i)
{
return parseInt(n.css(t,i)) || 0
}
var i,
t;
if(/1\.(0|1|2)\.(0|1|2)/.test(n.fn.jquery) || /^1.1/.test(n.fn.jquery))
{
alert("blockUI requires jQuery v1.2.3 or later!  You are using v" + n.fn.jquery);
return
}
n.fn._fadeIn = n.fn.fadeIn;
var f=function(){},
e=document.documentMode || 0,
v=n.browser.msie && (n.browser.version < 8 && !e || e < 8),
l=n.browser.msie && /MSIE 6.0/.test(navigator.userAgent) && !e;
n.blockUI = function(n)
{
h(window,n)
}, n.unblockUI = function(n)
{
u(window,n)
}, n.growlUI = function(t, i, r, u)
{
var f=n('<div class="growlUI"></div>');
t && f.append("<h1>" + t + "</h1>"), i && f.append("<h2>" + i + "</h2>"), r == undefined && (r = 3e3), n.blockUI({
message: f,
fadeIn: 700,
fadeOut: 1e3,
centerY: !1,
timeout: r,
showOverlay: !1,
onUnblock: u,
css: n.blockUI.defaults.growlCSS
})
}, n.fn.block = function(t)
{
return this.unblock({fadeOut: 0}).each(function()
{
n.css(this,"position") == "static" && (this.style.position = "relative"), n.browser.msie && (this.style.zoom = 1), h(this,t)
})
}, n.fn.unblock = function(n)
{
return this.each(function()
{
u(this,n)
})
}, n.blockUI.version = 2.39, n.blockUI.defaults = {
message: "<h1>Please wait...</h1>",
title: null,
draggable: !0,
theme: !1,
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: !1,
baseZ: 1e3,
centerX: !0,
centerY: !0,
allowBodyStretch: !0,
bindEvents: !0,
constrainTabKey: !0,
fadeIn: 200,
fadeOut: 400,
timeout: 0,
showOverlay: !0,
focusInput: !0,
applyPlatformOpacityRules: !0,
onBlock: null,
onUnblock: null,
quirksmodeOffsetHack: 4,
blockMsgClass: "blockMsg"
}, i = null, t = []
})(jQuery), jQuery.cookie = function(n, t, i)
{
var e,
r,
f,
u;
return arguments.length > 1 && String(t) !== "[object Object]" ? (i = jQuery.extend({},i), (t === null || t === undefined) && (i.expires = -1), typeof i.expires == "number" && (e = i.expires, r = i.expires = new Date, r.setDate(r.getDate() + e)), t = String(t), document.cookie = [encodeURIComponent(n),"=",i.raw ? t : encodeURIComponent(t),i.expires ? "; expires=" + i.expires.toUTCString() : "",i.path ? "; path=" + i.path : "",i.domain ? "; domain=" + i.domain : "",i.secure ? "; secure" : ""].join("")) : (i = t || {}, u = i.raw ? function(n)
{
return n
} : decodeURIComponent, (f = new RegExp("(?:^|; )" + encodeURIComponent(n) + "=([^;]*)").exec(document.cookie)) ? u(f[1]) : null)
}, function(n)
{
var t={};
n.publish = function(i, r)
{
t[i] && n.each(t[i],function()
{
this.apply(n,r || [])
})
}, n.subscribe = function(n, i)
{
return t[n] || (t[n] = []), t[n].push(i), [n,i]
}, n.unsubscribe = function(i)
{
var r=i[0];
t[r] && n.each(t[r],function(n)
{
this == i[1] && t[r].splice(n,1)
})
}
}(jQuery), jQuery.fn.boxy = function(n)
{
return n = n || {}, this.each(function()
{
var t=this.nodeName.toLowerCase(),
i=this;
t == "a" ? jQuery(this).click(function()
{
var f=Boxy.linkedTo(this),
r=this.getAttribute("href"),
t=jQuery.extend({
actuator: this,
title: this.title
},n),
i,
u;
return f ? f.show() : r.indexOf("#") < 0 ? (t.cache || (t.unloadOnHide = !0), Boxy.load(this.href,t)) : (i = jQuery(r.substr(r.indexOf("#"))), u = i.clone(!0), i.remove(), t.unloadOnHide = !1, new Boxy(u,t)), !1
}) : t == "form" && jQuery(this).bind("submit.boxy",function()
{
return Boxy.confirm(n.message || "Please confirm:",function()
{
jQuery(i).unbind("submit.boxy").submit()
}), !1
})
})
}, Boxy.EF = function(){}, jQuery.extend(Boxy,{
WRAPPER: "<table cellspacing='0' cellpadding='0' border='0' class='boxy-wrapper'><tr><td class='top-left'></td><td class='top'></td><td class='top-right'></td></tr><tr><td class='left'></td><td class='boxy-inner'></td><td class='right'></td></tr><tr><td class='bottom-left'></td><td class='bottom'></td><td class='bottom-right'></td></tr></table>",
DEFAULTS: {
title: null,
closeable: !0,
draggable: !0,
clone: !1,
actuator: null,
center: !0,
show: !0,
modal: !1,
fixed: !0,
closeText: "[close]",
unloadOnHide: !1,
clickToFront: !1,
behaviours: Boxy.EF,
afterDrop: Boxy.EF,
afterShow: Boxy.EF,
beforeHide: Boxy.EF,
afterHide: Boxy.EF,
beforeUnload: Boxy.EF
},
DEFAULT_X: 50,
DEFAULT_Y: 50,
zIndex: 1337,
dragConfigured: !1,
resizeConfigured: !1,
dragging: null,
load: function(n, t)
{
t = t || {};
var i={
url: n,
type: "GET",
dataType: "html",
cache: !1,
success: function(n)
{
n = jQuery(n), t.filter && (n = jQuery(t.filter,n)), new Boxy(n,t)
}
};
jQuery.each(["type","cache"],function()
{
this in t && (i[this] = t[this], delete t[this])
}), jQuery.ajax(i)
},
get: function(n)
{
var t=jQuery(n).parents(".boxy-wrapper");
return t.length ? jQuery.data(t[0],"boxy") : null
},
linkedTo: function(n)
{
return jQuery.data(n,"active.boxy")
},
alert: function(n, t, i)
{
return Boxy.ask(n,["OK"],t,i)
},
confirm: function(n, t, i)
{
return Boxy.ask(n,["OK","Cancel"],function(n)
{
n == "OK" && t()
},i)
},
ask: function(n, t, i, r)
{
var u,
f,
e;
r = jQuery.extend({
modal: !0,
closeable: !1
},r || {},{
show: !0,
unloadOnHide: !0
});
var h=jQuery("<div></div>").append(jQuery('<div class="question"></div>').html(n)),
o={},
s=[];
if(t instanceof Array)
for(u = 0; u < t.length; u++)
o[t[u]] = t[u], s.push(t[u]);
else
for(f in t)
o[t[f]] = f, s.push(t[f]);
e = jQuery('<form class="answers"></form>'), e.html(jQuery.map(s,function(n)
{
return"<input type='button' value='" + n + "' />"
}).join(" ")), jQuery("input[type=button]",e).click(function()
{
var n=this;
Boxy.get(this).hide(function()
{
i && i(o[n.value])
})
}), h.append(e), new Boxy(h,r)
},
isModalVisible: function()
{
return jQuery(".boxy-modal-blackout").length > 0
},
_u: function()
{
for(var n=0; n < arguments.length; n++)
if(typeof arguments[n] != "undefined")
return!1;
return!0
},
_handleResize: function()
{
var t=jQuery(document);
jQuery(".boxy-modal-blackout").css("display","none").css({
width: t.width(),
height: t.height()
}).css("display","block")
},
_handleDrag: function(n)
{
var t;
(t = Boxy.dragging) && t[0].boxy.css({
left: n.pageX - t[1],
top: n.pageY - t[2]
})
},
_nextZ: function()
{
return Boxy.zIndex++
},
_viewport: function()
{
var n=document.documentElement,
i=document.body,
t=window;
return jQuery.extend(jQuery.browser.msie ? {
left: i.scrollLeft || n.scrollLeft,
top: i.scrollTop || n.scrollTop
} : {
left: t.pageXOffset,
top: t.pageYOffset
},Boxy._u(t.innerWidth) ? !Boxy._u(n) && !Boxy._u(n.clientWidth) && n.clientWidth != 0 ? {
width: n.clientWidth,
height: n.clientHeight
} : {
width: i.clientWidth,
height: i.clientHeight
} : {
width: t.innerWidth,
height: t.innerHeight
})
}
}), Boxy.prototype = {
estimateSize: function()
{
this.boxy.css({
visibility: "hidden",
display: "block"
});
var n=this.getSize();
return this.boxy.css("display","none").css("visibility","visible"), n
},
getSize: function()
{
return[this.boxy.width(),this.boxy.height()]
},
getContentSize: function()
{
var n=this.getContent();
return[n.width(),n.height()]
},
getPosition: function()
{
var n=this.boxy[0];
return[n.offsetLeft,n.offsetTop]
},
getCenter: function()
{
var t=this.getPosition(),
n=this.getSize();
return[Math.floor(t[0] + n[0] / 2),Math.floor(t[1] + n[1] / 2)]
},
getInner: function()
{
return jQuery(".boxy-inner",this.boxy)
},
getContent: function()
{
return jQuery(".boxy-content",this.boxy)
},
setContent: function(n)
{
return n = jQuery(n).css({display: "block"}).addClass("boxy-content"), this.options.clone && (n = n.clone(!0)), this.getContent().remove(), this.getInner().append(n), this._setupDefaultBehaviours(n), this.options.behaviours.call(this,n), this
},
moveTo: function(n, t)
{
return this.moveToX(n).moveToY(t), this
},
moveToX: function(n)
{
return typeof n == "number" ? this.boxy.css({left: n}) : this.centerX(), this
},
moveToY: function(n)
{
return typeof n == "number" ? this.boxy.css({top: n}) : this.centerY(), this
},
centerAt: function(n, t)
{
var i=this[this.visible ? "getSize" : "estimateSize"]();
return typeof n == "number" && this.moveToX(n - i[0] / 2), typeof t == "number" && this.moveToY(t - i[1] / 2), this
},
centerAtX: function(n)
{
return this.centerAt(n,null)
},
centerAtY: function(n)
{
return this.centerAt(null,n)
},
center: function(n)
{
var t=Boxy._viewport(),
i=this.options.fixed ? [0,0] : [t.left,t.top];
return n && n != "x" || this.centerAt(i[0] + t.width / 2,null), n && n != "y" || this.centerAt(null,i[1] + t.height / 2), this
},
centerX: function()
{
return this.center("x")
},
centerY: function()
{
return this.center("y")
},
resize: function(n, t, i)
{
if(!this.visible)
return;
var r=this._getBoundsForResize(n,t);
return isNaN(r[1]) ? this.boxy.css({left: r[0]}) : this.boxy.css({
left: r[0],
top: r[1]
}), this.getContent().css({
width: r[2],
height: r[3]
}), i && i(this), this
},
tween: function(n, t, i)
{
if(!this.visible)
return;
var r=this._getBoundsForResize(n,t),
u=this;
return this.boxy.stop().animate({
left: r[0],
top: r[1]
}), this.getContent().stop().animate({
width: r[2],
height: r[3]
},function()
{
i && i(u)
}), this
},
isVisible: function()
{
return this.visible
},
show: function()
{
if(this.visible)
return;
if(this.options.modal)
{
var n=this;
Boxy.resizeConfigured || (Boxy.resizeConfigured = !0, jQuery(window).resize(function()
{
Boxy._handleResize()
})), this.modalBlackout = jQuery('<div class="boxy-modal-blackout"></div>').css({
zIndex: Boxy._nextZ(),
opacity: .7,
width: jQuery(document).width(),
height: jQuery(document).height()
}).appendTo(document.body), this.toTop(), this.options.closeable && jQuery(document.body).bind("keypress.boxy",function(t)
{
var i=t.which || t.keyCode;
i == 27 && (n.hide(), jQuery(document.body).unbind("keypress.boxy"))
})
}
return this.boxy.stop().css({opacity: 1}).show(), this.visible = !0, this._fire("afterShow"), this
},
hide: function(n)
{
if(!this.visible)
return;
var t=this;
return t._fire("beforeHide"), this.options.modal && (jQuery(document.body).unbind("keypress.boxy"), this.modalBlackout.animate({opacity: 0},function()
{
jQuery(this).remove()
})), this.boxy.stop().animate({opacity: 0},300,function()
{
t.boxy.css({display: "none"}), t.visible = !1, t._fire("afterHide"), n && n(t), t.options.unloadOnHide && t.unload()
}), this
},
toggle: function()
{
return this[this.visible ? "hide" : "show"](), this
},
hideAndUnload: function(n)
{
return this.options.unloadOnHide = !0, this.hide(n), this
},
unload: function()
{
this._fire("beforeUnload"), this.boxy.remove(), this.options.actuator && jQuery.data(this.options.actuator,"active.boxy",!1)
},
toTop: function()
{
return this.boxy.css({zIndex: Boxy._nextZ()}), this
},
getTitle: function()
{
return jQuery("> .title-bar h2",this.getInner()).html()
},
setTitle: function(n)
{
return jQuery("> .title-bar h2",this.getInner()).html(n), this
},
_getBoundsForResize: function(n, t)
{
var u=this.getContentSize(),
r=[n - u[0],t - u[1]],
i=this.getPosition();
return[Math.max(i[0] - r[0] / 2,0),Math.max(i[1] - r[1] / 2,0),n,t]
},
_setupTitleBar: function()
{
if(this.options.title)
{
var t=this,
n=jQuery("<div class='title-bar'></div>").html("<h2>" + this.options.title + "</h2>");
this.options.closeable && n.append(jQuery("<a href='#' class='close'></a>").html(this.options.closeText)), this.options.draggable && (n[0].onselectstart = function()
{
return!1
}, n[0].unselectable = "on", n[0].style.MozUserSelect = "none", Boxy.dragConfigured || (jQuery(document).mousemove(Boxy._handleDrag), Boxy.dragConfigured = !0), n.mousedown(function(n)
{
t.toTop(), Boxy.dragging = [t,n.pageX - t.boxy[0].offsetLeft,n.pageY - t.boxy[0].offsetTop], jQuery(this).addClass("dragging")
}).mouseup(function()
{
jQuery(this).removeClass("dragging"), Boxy.dragging = null, t._fire("afterDrop")
})), this.getInner().prepend(n), this._setupDefaultBehaviours(n)
}
},
_setupDefaultBehaviours: function(n)
{
var t=this;
this.options.clickToFront && n.click(function()
{
t.toTop()
}), jQuery(".close",n).click(function()
{
return t.hide(), !1
}).mousedown(function(n)
{
n.stopPropagation()
})
},
_fire: function(n)
{
this.options[n].call(this)
}
}, function(n)
{
n.extend({metadata: {
defaults: {
type: "class",
name: "metadata",
cre: /({.*})/,
single: "metadata"
},
setType: function(n, t)
{
this.defaults.type = n, this.defaults.name = t
},
get: function(t, i)
{
var u=n.extend({},this.defaults,i),
r,
c,
h,
f,
o,
e,
s;
u.single.length || (u.single = "metadata"), r = n.data(t,u.single);
if(r)
return r;
r = "{}", c = function(n)
{
if(typeof n != "string")
return n;
n.indexOf("{") < 0 && (n = eval("(" + n + ")"))
}, h = function(n)
{
return typeof n != "string" ? n : n = eval("(" + n + ")")
};
if(u.type == "html5")
f = {}, n(t.attributes).each(function()
{
var n=this.nodeName;
if(n.match(/^data-/))
n = n.replace(/^data-/,"");
else
return!0;
f[n] = h(this.nodeValue)
});
else
{
if(u.type == "class")
o = u.cre.exec(t.className), o && (r = o[1]);
else if(u.type == "elem")
{
if(!t.getElementsByTagName)
return;
e = t.getElementsByTagName(u.name), e.length && (r = n.trim(e[0].innerHTML))
}
else
t.getAttribute != undefined && (s = t.getAttribute(u.name), s && (r = s));
f = h(r.indexOf("{") < 0 ? "{" + r + "}" : r)
}
return n.data(t,u.single,f), f
}
}}), n.fn.metadata = function(t)
{
return n.metadata.get(this[0],t)
}
}(jQuery), function(n)
{
n.extend({tablesorter: new function()
{
function i(n, t)
{
u(n + "," + (+new Date - t.getTime()) + "ms")
}
function u(n)
{
typeof console != "undefined" && typeof console.debug != "undefined" ? console.log(n) : alert(n)
}
function a(t, i)
{
var o,
e,
r,
f;
t.config.debug && (o = "");
if(t.tBodies.length == 0)
return;
e = t.tBodies[0].rows;
if(e[0])
{
var s=[],
c=e[0].cells,
h=c.length;
for(r = 0; r < h; r++)
f = !1, n.metadata && n(i[r]).metadata() && n(i[r]).metadata().sorter ? f = v(n(i[r]).metadata().sorter) : t.config.headers[r] && t.config.headers[r].sorter && (f = v(t.config.headers[r].sorter)), f || (f = it(t,e,-1,r)), t.config.debug && (o += "column:" + r + " parser:" + f.id + "\n"), s.push(f)
}
return t.config.debug && u(o), s
}
function it(n, i, r, f)
{
var c=t.length,
s=!1,
o=!1,
h=!0,
e;
while(o == "" && h)
r++, i[r] ? (s = tt(i,r,f), o = nt(n.config,s), n.config.debug && u("Checking if value was empty on row:" + r)) : h = !1;
for(e = 1; e < c; e++)
if(t[e].is(o,n,s))
return t[e];
return t[0]
}
function tt(n, t, i)
{
return n[t].cells[i]
}
function nt(t, i)
{
return n.trim(e(t,i))
}
function v(n)
{
for(var r=t.length, i=0; i < r; i++)
if(t[i].id.toLowerCase() == n.toLowerCase())
return t[i];
return!1
}
function p(t)
{
var h,
s,
f,
o,
u;
t.config.debug && (h = new Date);
var c=t.tBodies[0] && t.tBodies[0].rows.length || 0,
a=t.tBodies[0].rows[0] && t.tBodies[0].rows[0].cells.length || 0,
l=t.config.parsers,
r={
row: [],
normalized: []
};
for(s = 0; s < c; ++s)
{
f = n(t.tBodies[0].rows[s]), o = [];
if(f.hasClass(t.config.cssChildRow))
{
r.row[r.row.length - 1] = r.row[r.row.length - 1].add(f);
continue
}
for(r.row.push(f), u = 0; u < a; ++u)
o.push(l[u].format(e(t.config,f[0].cells[u]),t,f[0].cells[u]));
o.push(r.normalized.length), r.normalized.push(o), o = null
}
return t.config.debug && i("Building cache for " + c + " rows:",h), r
}
function e(t, i)
{
var r="";
return i ? (t.supportsTextContent || (t.supportsTextContent = i.textContent || !1), r = t.textExtraction == "simple" ? t.supportsTextContent ? i.textContent : i.childNodes[0] && i.childNodes[0].hasChildNodes() ? i.childNodes[0].innerHTML : i.innerHTML : typeof t.textExtraction == "function" ? t.textExtraction(i) : n(i).text()) : ""
}
function s(t, r)
{
var a,
f,
e,
l,
u;
t.config.debug && (a = new Date);
var v=r,
h=v.row,
c=v.normalized,
y=c.length,
w=c[0].length - 1,
p=n(t.tBodies[0]),
s=[];
for(f = 0; f < y; f++)
{
e = c[f][w], s.push(h[e]);
if(!t.config.appender)
for(l = h[e].length, u = 0; u < l; u++)
p[0].appendChild(h[e][u])
}
t.config.appender && t.config.appender(t,s), s = null, t.config.debug && i("Rebuilt table:",a), o(t), setTimeout(function()
{
n(t).trigger("sortEnd")
},0)
}
function w(t)
{
var f,
e,
r;
return t.config.debug && (f = new Date), e = n.metadata ? !0 : !1, r = ft(t), $tableHeaders = n(t.config.selectorHeaders,t).each(function(i)
{
this.column = r[this.parentNode.rowIndex + "-" + this.cellIndex], this.order = g(t.config.sortInitialOrder), this.count = this.order, (ut(this) || rt(t,i)) && (this.sortDisabled = !0), h(t,i) && (this.order = this.lockedOrder = h(t,i));
if(!this.sortDisabled)
{
var u=n(this).addClass(t.config.cssHeader);
t.config.onRenderHeader && t.config.onRenderHeader.apply(u)
}
t.config.headerList[i] = this
}), t.config.debug && (i("Built headers:",f), u($tableHeaders)), $tableHeaders
}
function ft(n)
{
for(var r=[], a={}, w=n.getElementsByTagName("THEAD")[0], c=w.getElementsByTagName("TR"), h, o, t, l, f, s=0; s < c.length; s++)
for(h = c[s].cells, o = 0; o < h.length; o++)
{
var u=h[o],
i=u.parentNode.rowIndex,
v=i + "-" + u.cellIndex,
p=u.rowSpan || 1,
y=u.colSpan || 1,
e;
for(typeof r[i] == "undefined" && (r[i] = []), t = 0; t < r[i].length + 1; t++)
if(typeof r[i][t] == "undefined")
{
e = t;
break
}
for(a[v] = e, t = i; t < i + p; t++)
for(typeof r[t] == "undefined" && (r[t] = []), l = r[t], f = e; f < e + y; f++)
l[f] = "x"
}
return a
}
function ut(t)
{
return n.metadata && n(t).metadata().sorter === !1 ? !0 : !1
}
function rt(n, t)
{
return n.config.headers[t] && n.config.headers[t].sorter === !1 ? !0 : !1
}
function h(n, t)
{
return n.config.headers[t] && n.config.headers[t].lockedOrder ? n.config.headers[t].lockedOrder : !1
}
function o(n)
{
for(var i=n.config.widgets, r=i.length, t=0; t < r; t++)
c(i[t]).format(n)
}
function c(n)
{
for(var i=f.length, t=0; t < i; t++)
if(f[t].id.toLowerCase() == n.toLowerCase())
return f[t]
}
function g(n)
{
return typeof n != "Number" ? n.toLowerCase() == "desc" ? 1 : 0 : n == 1 ? 1 : 0
}
function d(n, t)
{
for(var r=t.length, i=0; i < r; i++)
if(t[i][0] == n)
return!0;
return!1
}
function l(t, i, r, u)
{
var e,
o,
f;
for(i.removeClass(u[0]).removeClass(u[1]), e = [], i.each(function()
{
this.sortDisabled || (e[this.column] = n(this))
}), o = r.length, f = 0; f < o; f++)
e[r[f][0]].addClass(u[r[f][1]])
}
function k(t)
{
var u=t.config,
r;
u.widthFixed && (r = n("<colgroup>"), n("tr:first td",t.tBodies[0]).each(function()
{
r.append(n("<col>").css("width",n(this).width()))
}), n(t).prepend(r))
}
function b(n, t)
{
for(var e=n.config, f=t.length, r, u, i=0; i < f; i++)
r = t[i], u = e.headerList[r[0]], u.count = r[1], u.count++
}
function y(n, t, u)
{
var a,
f,
l,
s,
e;
for(n.config.debug && (a = new Date), f = "var sortWrapper = function(a,b) {", l = t.length, e = 0; e < l; e++)
{
var o=t[e][0],
c=t[e][1],
v=n.config.parsers[o].type == "text" ? c == 0 ? r("text","asc",o) : r("text","desc",o) : c == 0 ? r("numeric","asc",o) : r("numeric","desc",o),
h="e" + e;
f += "var " + h + " = " + v, f += "if(" + h + ") { return " + h + "; } ", f += "else { "
}
for(s = u.normalized[0].length - 1, f += "return a[" + s + "]-b[" + s + "];", e = 0; e < l; e++)
f += "}; ";
return f += "return 0; ", f += "}; ", n.config.debug && i("Evaling expression:" + f,new Date), eval(f), u.normalized.sort(sortWrapper), n.config.debug && i("Sorting on " + t.toString() + " and dir " + c + " time:",a), u
}
function r(n, t, i)
{
var u="a[" + i + "]",
r="b[" + i + "]";
return n == "text" && t == "asc" ? "(" + u + " == " + r + " ? 0 : (" + u + " === null ? Number.POSITIVE_INFINITY : (" + r + " === null ? Number.NEGATIVE_INFINITY : (" + u + " < " + r + ") ? -1 : 1 )));" : n == "text" && t == "desc" ? "(" + u + " == " + r + " ? 0 : (" + u + " === null ? Number.POSITIVE_INFINITY : (" + r + " === null ? Number.NEGATIVE_INFINITY : (" + r + " < " + u + ") ? -1 : 1 )));" : n == "numeric" && t == "asc" ? "(" + u + " === null && " + r + " === null) ? 0 :(" + u + " === null ? Number.POSITIVE_INFINITY : (" + r + " === null ? Number.NEGATIVE_INFINITY : " + u + " - " + r + "));" : n == "numeric" && t == "desc" ? "(" + u + " === null && " + r + " === null) ? 0 :(" + u + " === null ? Number.POSITIVE_INFINITY : (" + r + " === null ? Number.NEGATIVE_INFINITY : " + r + " - " + u + "));" : void 0
}
var t=[],
f=[];
this.defaults = {
cssHeader: "header",
cssAsc: "headerSortUp",
cssDesc: "headerSortDown",
cssChildRow: "expand-child",
sortInitialOrder: "asc",
sortMultiSortKey: "shiftKey",
sortForce: null,
sortAppend: null,
sortLocaleCompare: !0,
textExtraction: "simple",
parsers: {},
widgets: [],
widgetZebra: {css: ["even","odd"]},
headers: {},
widthFixed: !1,
cancelSelection: !0,
sortList: [],
headerList: [],
dateFormat: "us",
decimal: "/.|,/g",
onRenderHeader: null,
selectorHeaders: "thead th",
debug: !1
}, this.benchmark = i, this.construct = function(t)
{
return this.each(function()
{
var r,
g,
f,
u,
i,
v,
nt,
h;
if(!this.tHead || !this.tBodies)
return;
v = 0, this.config = {}, i = n.extend(this.config,n.tablesorter.defaults,t), r = n(this), n.data(this,"tablesorter",i), f = w(this), this.config.parsers = a(this,f), u = p(this), h = [i.cssDesc,i.cssAsc], k(this), f.click(function(t)
{
var w=r[0].tBodies[0] && r[0].tBodies[0].rows.length || 0,
p,
o,
v,
e,
c,
a;
if(!this.sortDisabled && w > 0)
{
r.trigger("sortStart"), p = n(this), o = this.column, this.order = this.count++ % 2, this.lockedOrder && (this.order = this.lockedOrder);
if(t[i.sortMultiSortKey])
if(d(o,i.sortList))
for(e = 0; e < i.sortList.length; e++)
c = i.sortList[e], a = i.headerList[c[0]], c[0] == o && (a.count = c[1], a.count++, c[1] = a.count % 2);
else
i.sortList.push([o,this.order]);
else
{
i.sortList = [];
if(i.sortForce != null)
for(v = i.sortForce, e = 0; e < v.length; e++)
v[e][0] != o && i.sortList.push(v[e]);
i.sortList.push([o,this.order])
}
return setTimeout(function()
{
l(r[0],f,i.sortList,h), s(r[0],y(r[0],i.sortList,u))
},1), !1
}
}).mousedown(function()
{
if(i.cancelSelection)
return this.onselectstart = function()
{
return!1
}, !1
}), r.bind("update",function()
{
var n=this;
setTimeout(function()
{
n.config.parsers = a(n,f), u = p(n)
},1)
}).bind("updateCell",function(n, t)
{
var r=this.config,
i=[t.parentNode.rowIndex - 1,t.cellIndex];
u.normalized[i[0]][i[1]] = r.parsers[i[1]].format(e(r,t),t)
}).bind("sorton",function(t, r)
{
n(this).trigger("sortStart"), i.sortList = r;
var e=i.sortList;
b(this,e), l(this,f,e,h), s(this,y(this,e,u))
}).bind("appendCache",function()
{
s(this,u)
}).bind("applyWidgetId",function(n, t)
{
c(t).format(this)
}).bind("applyWidgets",function()
{
o(this)
}), n.metadata && n(this).metadata() && n(this).metadata().sortlist && (i.sortList = n(this).metadata().sortlist), i.sortList.length > 0 && r.trigger("sorton",[i.sortList]), o(this)
})
}, this.addParser = function(n)
{
for(var u=t.length, r=!0, i=0; i < u; i++)
t[i].id.toLowerCase() == n.id.toLowerCase() && (r = !1);
r && t.push(n)
}, this.addWidget = function(n)
{
f.push(n)
}, this.formatFloat = function(n)
{
var t=parseFloat(n);
return isNaN(t) ? 0 : t
}, this.formatInt = function(n)
{
var t=parseInt(n);
return isNaN(t) ? 0 : t
}, this.isDigit = function(t)
{
return/^[-+]?\d*$/.test(n.trim(t.replace(/[,.']/g,"")))
}, this.clearTableBody = function(t)
{
if(n.browser.msie)
{
function i()
{
while(this.firstChild)
this.removeChild(this.firstChild)
}
i.apply(t.tBodies[0])
}
else
t.tBodies[0].innerHTML = ""
}
}}), n.fn.extend({tablesorter: n.tablesorter.construct});
var t=n.tablesorter;
t.addParser({
id: "text",
is: function()
{
return!0
},
format: function(t)
{
return n.trim(t.toLocaleLowerCase())
},
type: "text"
}), t.addParser({
id: "digit",
is: function(t, i)
{
var r=i.config;
return n.tablesorter.isDigit(t,r)
},
format: function(t)
{
return n.tablesorter.formatFloat(t)
},
type: "numeric"
}), t.addParser({
id: "currency",
is: function(n)
{
return/^[£$€?.]/.test(n)
},
format: function(t)
{
return n.tablesorter.formatFloat(t.replace(new RegExp(/[£$€]/g),""))
},
type: "numeric"
}), t.addParser({
id: "ipAddress",
is: function(n)
{
return/^\d{2,3}[\.]\d{2,3}[\.]\d{2,3}[\.]\d{2,3}$/.test(n)
},
format: function(t)
{
for(var f=t.split("."), u="", e=f.length, r, i=0; i < e; i++)
r = f[i], u += r.length == 2 ? "0" + r : r;
return n.tablesorter.formatFloat(u)
},
type: "numeric"
}), t.addParser({
id: "url",
is: function(n)
{
return/^(https?|ftp|file):\/\/$/.test(n)
},
format: function(n)
{
return jQuery.trim(n.replace(new RegExp(/(https?|ftp|file):\/\//),""))
},
type: "text"
}), t.addParser({
id: "isoDate",
is: function(n)
{
return/^\d{4}[\/-]\d{1,2}[\/-]\d{1,2}$/.test(n)
},
format: function(t)
{
return n.tablesorter.formatFloat(t != "" ? +new Date(t.replace(new RegExp(/-/g),"/")) : "0")
},
type: "numeric"
}), t.addParser({
id: "percent",
is: function(t)
{
return/\%$/.test(n.trim(t))
},
format: function(t)
{
return n.tablesorter.formatFloat(t.replace(new RegExp(/%/g),""))
},
type: "numeric"
}), t.addParser({
id: "usLongDate",
is: function(n)
{
return n.match(new RegExp(/^[A-Za-z]{3,10}\.? [0-9]{1,2}, ([0-9]{4}|'?[0-9]{2}) (([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(AM|PM)))$/))
},
format: function(t)
{
return n.tablesorter.formatFloat(+new Date(t))
},
type: "numeric"
}), t.addParser({
id: "shortDate",
is: function(n)
{
return/\d{1,2}[\/\-]\d{1,2}[\/\-]\d{2,4}/.test(n)
},
format: function(t, i)
{
var r=i.config;
return t = t.replace(/\-/g,"/"), r.dateFormat == "us" ? t = t.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/,"$3/$1/$2") : r.dateFormat == "uk" ? t = t.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/,"$3/$2/$1") : (r.dateFormat == "dd/mm/yy" || r.dateFormat == "dd-mm-yy") && (t = t.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{2})/,"$1/$2/$3")), n.tablesorter.formatFloat(+new Date(t))
},
type: "numeric"
}), t.addParser({
id: "time",
is: function(n)
{
return/^(([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(am|pm)))$/.test(n)
},
format: function(t)
{
return n.tablesorter.formatFloat(+new Date("2000/01/01 " + t))
},
type: "numeric"
}), t.addParser({
id: "metadata",
is: function()
{
return!1
},
format: function(t, i, r)
{
var u=i.config,
f=u.parserMetadataName ? u.parserMetadataName : "sortValue";
return n(r).metadata()[f]
},
type: "numeric"
}), t.addWidget({
id: "zebra",
format: function(t)
{
var f,
u,
i,
r;
t.config.debug && (f = new Date), i = -1, n("tr:visible",t.tBodies[0]).each(function()
{
u = n(this), u.hasClass(t.config.cssChildRow) || i++, r = i % 2 == 0, u.removeClass(t.config.widgetZebra.css[r ? 0 : 1]).addClass(t.config.widgetZebra.css[r ? 1 : 0])
}), t.config.debug && n.tablesorter.benchmark("Applying Zebra widget",f)
}
})
}(jQuery), qq = qq || {}, qq.extend = function(n, t)
{
for(var i in t)
n[i] = t[i]
}, qq.indexOf = function(n, t, i)
{
if(n.indexOf)
return n.indexOf(t,i);
i = i || 0;
var r=n.length;
for(i < 0 && (i += r); i < r; i++)
if(i in n && n[i] === t)
return i;
return-1
}, qq.getUniqueId = function()
{
var n=0;
return function()
{
return n++
}
}(), qq.attach = function(n, t, i)
{
n.addEventListener ? n.addEventListener(t,i,!1) : n.attachEvent && n.attachEvent("on" + t,i)
}, qq.detach = function(n, t, i)
{
n.removeEventListener ? n.removeEventListener(t,i,!1) : n.attachEvent && n.detachEvent("on" + t,i)
}, qq.preventDefault = function(n)
{
n.preventDefault ? n.preventDefault() : n.returnValue = !1
}, qq.insertBefore = function(n, t)
{
t.parentNode.insertBefore(n,t)
}, qq.remove = function(n)
{
n.parentNode.removeChild(n)
}, qq.contains = function(n, t)
{
return n == t ? !0 : n.contains ? n.contains(t) : !!(t.compareDocumentPosition(n) & 8)
}, qq.toElement = function()
{
var n=document.createElement("div");
return function(t)
{
n.innerHTML = t;
var i=n.firstChild;
return n.removeChild(i), i
}
}(), qq.css = function(n, t)
{
t.opacity != null && typeof n.style.opacity != "string" && typeof n.filters != "undefined" && (t.filter = "alpha(opacity=" + Math.round(100 * t.opacity) + ")"), qq.extend(n.style,t)
}, qq.hasClass = function(n, t)
{
var i=new RegExp("(^| )" + t + "( |$)");
return i.test(n.className)
}, qq.addClass = function(n, t)
{
qq.hasClass(n,t) || (n.className += " " + t)
}, qq.removeClass = function(n, t)
{
var i=new RegExp("(^| )" + t + "( |$)");
n.className = n.className.replace(i," ").replace(/^\s+|\s+$/g,"")
}, qq.setText = function(n, t)
{
n.innerText = t, n.textContent = t
}, qq.children = function(n)
{
var i=[],
t=n.firstChild;
while(t)
t.nodeType == 1 && i.push(t), t = t.nextSibling;
return i
}, qq.getByClass = function(n, t)
{
var i;
if(n.querySelectorAll)
return n.querySelectorAll("." + t);
var u=[],
r=n.getElementsByTagName("*"),
f=r.length;
for(i = 0; i < f; i++)
qq.hasClass(r[i],t) && u.push(r[i]);
return u
}, qq.obj2url = function(n, t, i)
{
var u=[],
e="&",
o=function(n, i)
{
var r=t ? /\[\]$/.test(t) ? t : t + "[" + i + "]" : i;
r != "undefined" && i != "undefined" && u.push(typeof n == "object" ? qq.obj2url(n,r,!0) : Object.prototype.toString.call(n) === "[object Function]" ? encodeURIComponent(r) + "=" + encodeURIComponent(n()) : encodeURIComponent(r) + "=" + encodeURIComponent(n))
},
f,
r;
if(!i && t)
e = /\?/.test(t) ? /\?$/.test(t) ? "" : "&" : "?", u.push(t), u.push(qq.obj2url(n));
else if(Object.prototype.toString.call(n) === "[object Array]" && typeof n != "undefined")
for(r = 0, f = n.length; r < f; ++r)
o(n[r],r);
else if(typeof n != "undefined" && n !== null && typeof n == "object")
for(r in n)
o(n[r],r);
else
u.push(encodeURIComponent(t) + "=" + encodeURIComponent(n));
return u.join(e).replace(/^&/,"").replace(/%20/g,"+")
}, qq = qq || {}, qq.FileUploaderBasic = function(n)
{
this._options = {
debug: !1,
action: "/server/upload",
params: {},
button: null,
multiple: !0,
maxConnections: 3,
allowedExtensions: [],
sizeLimit: 0,
minSizeLimit: 0,
onSubmit: function(){},
onProgress: function(){},
onComplete: function(){},
onCancel: function(){},
messages: {
typeError: "{file} has invalid extension. Only {extensions} are allowed.",
sizeError: "{file} is too large, maximum file size is {sizeLimit}.",
minSizeError: "{file} is too small, minimum file size is {minSizeLimit}.",
emptyError: "{file} is empty, please select files again without it.",
onLeave: "The files are being uploaded, if you leave now the upload will be cancelled."
},
showMessage: function(n)
{
alert(n)
}
}, qq.extend(this._options,n), this._filesInProgress = 0, this._handler = this._createUploadHandler(), this._options.button && (this._button = this._createUploadButton(this._options.button)), this._preventLeaveInProgress()
}, qq.FileUploaderBasic.prototype = {
setParams: function(n)
{
this._options.params = n
},
getInProgress: function()
{
return this._filesInProgress
},
_createUploadButton: function(n)
{
var t=this;
return new qq.UploadButton({
element: n,
multiple: this._options.multiple && qq.UploadHandlerXhr.isSupported(),
onChange: function(n)
{
t._onInputChange(n)
}
})
},
_createUploadHandler: function()
{
var n=this,
t,
i;
return t = qq.UploadHandlerXhr.isSupported() ? "UploadHandlerXhr" : "UploadHandlerForm", i = new qq[t]({
debug: this._options.debug,
action: this._options.action,
maxConnections: this._options.maxConnections,
onProgress: function(t, i, r, u)
{
n._onProgress(t,i,r,u);
n._options.onProgress(t,i,r,u)
},
onComplete: function(t, i, r)
{
n._onComplete(t,i,r);
n._options.onComplete(t,i,r)
},
onCancel: function(t, i)
{
n._onCancel(t,i);
n._options.onCancel(t,i)
}
})
},
_preventLeaveInProgress: function()
{
var n=this;
qq.attach(window,"beforeunload",function(t)
{
if(!n._filesInProgress)
return;
var t=t || window.event;
return t.returnValue = n._options.messages.onLeave, n._options.messages.onLeave
})
},
_onSubmit: function()
{
this._filesInProgress++
},
_onProgress: function(){},
_onComplete: function(n, t, i)
{
this._filesInProgress--, i.error && this._options.showMessage(i.error)
},
_onCancel: function()
{
this._filesInProgress--
},
_onInputChange: function(n)
{
this._handler instanceof qq.UploadHandlerXhr ? this._uploadFileList(n.files) : this._validateFile(n) && this._uploadFile(n), this._button.reset()
},
_uploadFileList: function(n)
{
for(var t=0; t < n.length; t++)
if(!this._validateFile(n[t]))
return;
for(t = 0; t < n.length; t++)
this._uploadFile(n[t])
},
_uploadFile: function(n)
{
var t=this._handler.add(n),
i=this._handler.getName(t);
this._options.onSubmit(t,i) !== !1 && (this._onSubmit(t,i), this._handler.upload(t,this._options.params))
},
_validateFile: function(n)
{
var t,
i;
n.value ? t = n.value.replace(/.*(\/|\\)/,"") : (t = n.fileName != null ? n.fileName : n.name, i = n.fileSize != null ? n.fileSize : n.size);
if(this._isAllowedExtension(t))
{
if(i === 0)
return this._error("emptyError",t), !1;
if(i && this._options.sizeLimit && i > this._options.sizeLimit)
return this._error("sizeError",t), !1;
if(i && i < this._options.minSizeLimit)
return this._error("minSizeError",t), !1
}
else
return this._error("typeError",t), !1;
return!0
},
_error: function(n, t)
{
function i(n, t)
{
r = r.replace(n,t)
}
var r=this._options.messages[n];
i("{file}",this._formatFileName(t)), i("{extensions}",this._options.allowedExtensions.join(", ")), i("{sizeLimit}",this._formatSize(this._options.sizeLimit)), i("{minSizeLimit}",this._formatSize(this._options.minSizeLimit)), this._options.showMessage(r)
},
_formatFileName: function(n)
{
return n.length > 33 && (n = n.slice(0,19) + "..." + n.slice(-13)), n
},
_isAllowedExtension: function(n)
{
var r=-1 !== n.indexOf(".") ? n.replace(/.*[.]/,"").toLowerCase() : "",
i=this._options.allowedExtensions,
t;
if(!i.length)
return!0;
for(t = 0; t < i.length; t++)
if(i[t].toLowerCase() == r)
return!0;
return!1
},
_formatSize: function(n)
{
var t=-1;
do
n = n / 1024, t++;
while(n > 99);
return Math.max(n,.1).toFixed(1) + ["kB","MB","GB","TB","PB","EB"][t]
}
}, qq.FileUploader = function(n)
{
qq.FileUploaderBasic.apply(this,arguments), qq.extend(this._options,{
element: null,
listElement: null,
template: '<div class="qq-uploader"><div class="qq-upload-drop-area"><span>Drop files here to upload</span></div><div class="qq-upload-button">Upload a file</div><ul class="qq-upload-list"></ul></div>',
fileTemplate: '<li><span class="qq-upload-file"></span><span class="qq-upload-spinner"></span><span class="qq-upload-size"></span><a class="qq-upload-cancel" href="#">Cancel</a><span class="qq-upload-failed-text">Failed</span></li>',
classes: {
button: "qq-upload-button",
drop: "qq-upload-drop-area",
dropActive: "qq-upload-drop-area-active",
list: "qq-upload-list",
file: "qq-upload-file",
spinner: "qq-upload-spinner",
size: "qq-upload-size",
cancel: "qq-upload-cancel",
success: "qq-upload-success",
fail: "qq-upload-fail"
}
}), qq.extend(this._options,n), this._element = this._options.element, this._element.innerHTML = this._options.template, this._listElement = this._options.listElement || this._find(this._element,"list"), this._classes = this._options.classes, this._button = this._createUploadButton(this._find(this._element,"button")), this._bindCancelEvent(), this._setupDragDrop()
}, qq.extend(qq.FileUploader.prototype,qq.FileUploaderBasic.prototype), qq.extend(qq.FileUploader.prototype,{
_find: function(n, t)
{
var i=qq.getByClass(n,this._options.classes[t])[0];
if(!i)
throw new Error("element not found " + t);
return i
},
_setupDragDrop: function()
{
var t=this,
n=this._find(this._element,"drop"),
i=new qq.UploadDropZone({
element: n,
onEnter: function(i)
{
qq.addClass(n,t._classes.dropActive), i.stopPropagation()
},
onLeave: function(n)
{
n.stopPropagation()
},
onLeaveNotDescendants: function()
{
qq.removeClass(n,t._classes.dropActive)
},
onDrop: function(i)
{
n.style.display = "none", qq.removeClass(n,t._classes.dropActive), t._uploadFileList(i.dataTransfer.files)
}
});
n.style.display = "none", qq.attach(document,"dragenter",function(t)
{
if(!i._isValidFileDrag(t))
return;
n.style.display = "block"
}), qq.attach(document,"dragleave",function(t)
{
if(!i._isValidFileDrag(t))
return;
var r=document.elementFromPoint(t.clientX,t.clientY);
r && r.nodeName != "HTML" || (n.style.display = "none")
})
},
_onSubmit: function(n, t)
{
qq.FileUploaderBasic.prototype._onSubmit.apply(this,arguments), this._addToList(n,t)
},
_onProgress: function(n, t, i, r)
{
var e,
f,
u;
qq.FileUploaderBasic.prototype._onProgress.apply(this,arguments), e = this._getItemByFileId(n), f = this._find(e,"size"), f.style.display = "inline", u = i != r ? Math.round(i / r * 100) + "% from " + this._formatSize(r) : this._formatSize(r), qq.setText(f,u)
},
_onComplete: function(n, t, i)
{
qq.FileUploaderBasic.prototype._onComplete.apply(this,arguments);
var r=this._getItemByFileId(n);
qq.remove(this._find(r,"cancel")), qq.remove(this._find(r,"spinner")), i.success ? qq.addClass(r,this._classes.success) : qq.addClass(r,this._classes.fail)
},
_addToList: function(n, t)
{
var i=qq.toElement(this._options.fileTemplate),
r;
i.qqFileId = n, r = this._find(i,"file"), qq.setText(r,this._formatFileName(t)), this._find(i,"size").style.display = "none", this._listElement.appendChild(i)
},
_getItemByFileId: function(n)
{
var t=this._listElement.firstChild;
while(t)
{
if(t.qqFileId == n)
return t;
t = t.nextSibling
}
},
_bindCancelEvent: function()
{
var n=this,
t=this._listElement;
qq.attach(t,"click",function(t)
{
var r,
i;
t = t || window.event, r = t.target || t.srcElement, qq.hasClass(r,n._classes.cancel) && (qq.preventDefault(t), i = r.parentNode, n._handler.cancel(i.qqFileId), qq.remove(i))
})
}
}), qq.UploadDropZone = function(n)
{
this._options = {
element: null,
onEnter: function(){},
onLeave: function(){},
onLeaveNotDescendants: function(){},
onDrop: function(){}
}, qq.extend(this._options,n), this._element = this._options.element, this._disableDropOutside(), this._attachEvents()
}, qq.UploadDropZone.prototype = {
_disableDropOutside: function()
{
qq.UploadDropZone.dropOutsideDisabled || (qq.attach(document,"dragover",function(n)
{
n.dataTransfer && (n.dataTransfer.dropEffect = "none", n.preventDefault())
}), qq.UploadDropZone.dropOutsideDisabled = !0)
},
_attachEvents: function()
{
var n=this;
qq.attach(n._element,"dragover",function(t)
{
if(!n._isValidFileDrag(t))
return;
var i=t.dataTransfer.effectAllowed;
t.dataTransfer.dropEffect = i == "move" || i == "linkMove" ? "move" : "copy", t.stopPropagation(), t.preventDefault()
}), qq.attach(n._element,"dragenter",function(t)
{
if(!n._isValidFileDrag(t))
return;
n._options.onEnter(t)
}), qq.attach(n._element,"dragleave",function(t)
{
if(!n._isValidFileDrag(t))
return;
n._options.onLeave(t);
var i=document.elementFromPoint(t.clientX,t.clientY);
if(qq.contains(this,i))
return;
n._options.onLeaveNotDescendants(t)
}), qq.attach(n._element,"drop",function(t)
{
if(!n._isValidFileDrag(t))
return;
t.preventDefault();
n._options.onDrop(t)
})
},
_isValidFileDrag: function(n)
{
var t=n.dataTransfer,
i=navigator.userAgent.indexOf("AppleWebKit") > -1;
return t && t.effectAllowed != "none" && (t.files || !i && t.types.contains && t.types.contains("Files"))
}
}, qq.UploadButton = function(n)
{
this._options = {
element: null,
multiple: !1,
name: "file",
onChange: function(){},
hoverClass: "qq-upload-button-hover",
focusClass: "qq-upload-button-focus"
}, qq.extend(this._options,n), this._element = this._options.element, qq.css(this._element,{
position: "relative",
overflow: "hidden",
direction: "ltr"
}), this._input = this._createInput()
}, qq.UploadButton.prototype = {
getInput: function()
{
return this._input
},
reset: function()
{
this._input.parentNode && qq.remove(this._input), qq.removeClass(this._element,this._options.focusClass), this._input = this._createInput()
},
_createInput: function()
{
var n=document.createElement("input"),
t;
return this._options.multiple && n.setAttribute("multiple","multiple"), n.setAttribute("type","file"), n.setAttribute("name",this._options.name), qq.css(n,{
position: "absolute",
right: 0,
top: 0,
fontFamily: "Arial",
fontSize: "118px",
margin: 0,
padding: 0,
cursor: "pointer",
opacity: 0
}), this._element.appendChild(n), t = this, qq.attach(n,"change",function()
{
t._options.onChange(n)
}), qq.attach(n,"mouseover",function()
{
qq.addClass(t._element,t._options.hoverClass)
}), qq.attach(n,"mouseout",function()
{
qq.removeClass(t._element,t._options.hoverClass)
}), qq.attach(n,"focus",function()
{
qq.addClass(t._element,t._options.focusClass)
}), qq.attach(n,"blur",function()
{
qq.removeClass(t._element,t._options.focusClass)
}), window.attachEvent && n.setAttribute("tabIndex","-1"), n
}
}, qq.UploadHandlerAbstract = function(n)
{
this._options = {
debug: !1,
action: "/upload.php",
maxConnections: 999,
onProgress: function(){},
onComplete: function(){},
onCancel: function(){}
}, qq.extend(this._options,n), this._queue = [], this._params = []
}, qq.UploadHandlerAbstract.prototype = {
log: function(n)
{
this._options.debug && window.console && console.log("[uploader] " + n)
},
add: function(){},
upload: function(n, t)
{
var r=this._queue.push(n),
i={};
qq.extend(i,t), this._params[n] = i, r > this._options.maxConnections || this._upload(n,this._params[n])
},
cancel: function(n)
{
this._cancel(n), this._dequeue(n)
},
cancelAll: function()
{
for(var n=0; n < this._queue.length; n++)
this._cancel(this._queue[n]);
this._queue = []
},
getName: function(){},
getSize: function(){},
getQueue: function()
{
return this._queue
},
_upload: function(){},
_cancel: function(){},
_dequeue: function(n)
{
var r=qq.indexOf(this._queue,n),
t,
i;
this._queue.splice(r,1), t = this._options.maxConnections, this._queue.length >= t && r < t && (i = this._queue[t - 1], this._upload(i,this._params[i]))
}
}, qq.UploadHandlerForm = function()
{
qq.UploadHandlerAbstract.apply(this,arguments), this._inputs = {}
}, qq.extend(qq.UploadHandlerForm.prototype,qq.UploadHandlerAbstract.prototype), qq.extend(qq.UploadHandlerForm.prototype,{
add: function(n)
{
n.setAttribute("name","qqfile");
var t="qq-upload-handler-iframe" + qq.getUniqueId();
return this._inputs[t] = n, n.parentNode && qq.remove(n), t
},
getName: function(n)
{
return this._inputs[n].value.replace(/.*(\/|\\)/,"")
},
_cancel: function(n)
{
this._options.onCancel(n,this.getName(n));
delete this._inputs[n];
var t=document.getElementById(n);
t && (t.setAttribute("src","javascript:false;"), qq.remove(t))
},
_upload: function(n, t)
{
var f=this._inputs[n],
i;
if(!f)
throw new Error("file with passed id was not added, or already uploaded or cancelled");
var e=this.getName(n),
r=this._createIframe(n),
u=this._createForm(r,t);
return u.appendChild(f), i = this, this._attachLoadEvent(r,function()
{
i.log("iframe loaded");
var t=i._getIframeContentJSON(r);
i._options.onComplete(n,e,t);
i._dequeue(n), delete i._inputs[n], setTimeout(function()
{
qq.remove(r)
},1)
}), u.submit(), qq.remove(u), n
},
_attachLoadEvent: function(n, t)
{
qq.attach(n,"load",function()
{
if(!n.parentNode)
return;
if(n.contentDocument && n.contentDocument.body && n.contentDocument.body.innerHTML == "false")
return;
t()
})
},
_getIframeContentJSON: function(n)
{
var i=n.contentDocument ? n.contentDocument : n.contentWindow.document,
t;
this.log("converting iframe's innerHTML to JSON"), this.log("innerHTML = " + i.body.innerHTML);
try
{
t = eval("(" + i.body.innerHTML + ")")
}
catch(r)
{
t = {}
}
return t
},
_createIframe: function(n)
{
var t=qq.toElement('<iframe src="javascript:false;" name="' + n + '" />');
return t.setAttribute("id",n), t.style.display = "none", document.body.appendChild(t), t
},
_createForm: function(n, t)
{
var i=qq.toElement('<form method="post" enctype="multipart/form-data"></form>'),
r=qq.obj2url(t,this._options.action);
return i.setAttribute("action",r), i.setAttribute("target",n.name), i.style.display = "none", document.body.appendChild(i), i
}
}), qq.UploadHandlerXhr = function()
{
qq.UploadHandlerAbstract.apply(this,arguments), this._files = [], this._xhrs = [], this._loaded = []
}, qq.UploadHandlerXhr.isSupported = function()
{
var n=document.createElement("input");
return n.type = "file", "multiple" in n && typeof File != "undefined" && typeof(new XMLHttpRequest).upload != "undefined"
}, qq.extend(qq.UploadHandlerXhr.prototype,qq.UploadHandlerAbstract.prototype), qq.extend(qq.UploadHandlerXhr.prototype,{
add: function(n)
{
if(!(n instanceof File))
throw new Error("Passed obj in not a File (in qq.UploadHandlerXhr)");
return this._files.push(n) - 1
},
getName: function(n)
{
var t=this._files[n];
return t.fileName != null ? t.fileName : t.name
},
getSize: function(n)
{
var t=this._files[n];
return t.fileSize != null ? t.fileSize : t.size
},
getLoaded: function(n)
{
return this._loaded[n] || 0
},
_upload: function(n, t)
{
var e=this._files[n],
u=this.getName(n),
o=this.getSize(n),
i,
r,
f;
this._loaded[n] = 0, i = this._xhrs[n] = new XMLHttpRequest, r = this, i.upload.onprogress = function(t)
{
if(t.lengthComputable)
{
r._loaded[n] = t.loaded;
r._options.onProgress(n,u,t.loaded,t.total)
}
}, i.onreadystatechange = function()
{
i.readyState == 4 && r._onComplete(n,i)
}, t = t || {}, t.qqfile = u, f = qq.obj2url(t,this._options.action), i.open("POST",f,!0), i.setRequestHeader("X-Requested-With","XMLHttpRequest"), i.setRequestHeader("X-File-Name",encodeURIComponent(u)), i.setRequestHeader("Content-Type","application/octet-stream"), i.send(e)
},
_onComplete: function(n, t)
{
var i,
u,
r;
if(!this._files[n])
return;
i = this.getName(n), u = this.getSize(n);
this._options.onProgress(n,i,u,u);
if(t.status == 200)
{
this.log("xhr - server response received"), this.log("responseText = " + t.responseText);
try
{
r = eval("(" + t.responseText + ")")
}
catch(f)
{
r = {}
}
this._options.onComplete(n,i,r)
}
else
this._options.onComplete(n,i,{});
this._files[n] = null, this._xhrs[n] = null, this._dequeue(n)
},
_cancel: function(n)
{
this._options.onCancel(n,this.getName(n));
this._files[n] = null, this._xhrs[n] && (this._xhrs[n].abort(), this._xhrs[n] = null)
}
});
/*!
 * jQuery Cycle Plugin (with Transition Definitions)
 * Examples and documentation at: http://jquery.malsup.com/cycle/
 * Copyright (c) 2007-2010 M. Alsup
 * Version: 2.9999 (13-NOV-2011)
 * Dual licensed under the MIT and GPL licenses.
 * http://jquery.malsup.com/license.html
 * Requires: jQuery v1.3.2 or later
 */
(function(n, t)
{
function r(t)
{
n.fn.cycle.debug && i(t)
}
function i()
{
window.console && console.log && console.log("[cycle] " + Array.prototype.join.call(arguments," "))
}
function f(t, i, r)
{
var u=n(t).data("cycle.opts"),
f=!!t.cyclePause;
f && u.paused ? u.paused(t,u,i,r) : !f && u.resumed && u.resumed(t,u,i,r)
}
function l(r, e, o)
{
function c(t, r, f)
{
if(!t && r === !0)
{
var e=n(f).data("cycle.opts");
if(!e)
return i("options not found, can not resume"), !1;
f.cycleTimeout && (clearTimeout(f.cycleTimeout), f.cycleTimeout = 0), u(e.elements,e,1,!e.backwards)
}
}
var s,
h;
r.cycleStop == t && (r.cycleStop = 0), (e === t || e === null) && (e = {});
if(e.constructor == String)
{
switch(e)
{
case"destroy":
case"stop":
return s = n(r).data("cycle.opts"), s ? (r.cycleStop++, r.cycleTimeout && clearTimeout(r.cycleTimeout), r.cycleTimeout = 0, s.elements && n(s.elements).stop(), n(r).removeData("cycle.opts"), e == "destroy" && a(s), !1) : !1;
case"toggle":
return r.cyclePause = r.cyclePause === 1 ? 0 : 1, c(r.cyclePause,o,r), f(r), !1;
case"pause":
return r.cyclePause = 1, f(r), !1;
case"resume":
return r.cyclePause = 0, c(!1,o,r), f(r), !1;
case"prev":
case"next":
return s = n(r).data("cycle.opts"), s ? (n.fn.cycle[e](s), !1) : (i('options not found, "prev/next" ignored'), !1);
default:
e = {fx: e}
}
return e
}
return e.constructor == Number ? (h = e, e = n(r).data("cycle.opts"), e ? h < 0 || h >= e.elements.length ? (i("invalid slide index: " + h), !1) : (e.nextSlide = h, r.cycleTimeout && (clearTimeout(r.cycleTimeout), r.cycleTimeout = 0), typeof o == "string" && (e.oneTimeFx = o), u(e.elements,e,1,h >= e.currSlide), !1) : (i("options not found, can not advance slide"), !1)) : e
}
function h(t, i)
{
if(!n.support.opacity && i.cleartype && t.style.filter)
try
{
t.style.removeAttribute("filter")
}
catch(r){}
}
function a(t)
{
t.next && n(t.next).unbind(t.prevNextEvent), t.prev && n(t.prev).unbind(t.prevNextEvent), (t.pager || t.pagerAnchorBuilder) && n.each(t.pagerAnchors || [],function()
{
this.unbind().remove()
}), t.pagerAnchors = null, t.destroy && t.destroy(t)
}
function b(r, o, c, l, a)
{
var at,
p=n.extend({},n.fn.cycle.defaults,l || {},n.metadata ? r.metadata() : n.meta ? r.data() : {}),
yt=n.isFunction(r.data) ? r.data(p.metaAttr) : null,
rt,
ot,
it,
b,
vt,
nt,
g,
st,
lt,
ct,
pt,
ht,
d;
yt && (p = n.extend(p,yt)), p.autostop && (p.countdown = p.autostopCount || c.length), rt = r[0], r.data("cycle.opts",p), p.$cont = r, p.stopCount = rt.cycleStop, p.elements = c, p.before = p.before ? [p.before] : [], p.after = p.after ? [p.after] : [], !n.support.opacity && p.cleartype && p.after.push(function()
{
h(this,p)
}), p.continuous && p.after.push(function()
{
u(c,p,0,!p.backwards)
}), w(p), n.support.opacity || !p.cleartype || p.cleartypeNoBg || s(o), r.css("position") == "static" && r.css("position","relative"), p.width && r.width(p.width), p.height && p.height != "auto" && r.height(p.height), p.startingSlide != t ? (p.startingSlide = parseInt(p.startingSlide,10), p.startingSlide >= c.length || p.startSlide < 0 ? p.startingSlide = 0 : at = !0) : p.startingSlide = p.backwards ? c.length - 1 : 0;
if(p.random)
{
for(p.randomMap = [], ot = 0; ot < c.length; ot++)
p.randomMap.push(ot);
p.randomMap.sort(function()
{
return Math.random() - .5
});
if(at)
for(it = 0; it < c.length; it++)
p.startingSlide == p.randomMap[it] && (p.randomIndex = it);
else
p.randomIndex = 1, p.startingSlide = p.randomMap[1]
}
else
p.startingSlide < c.length || (p.startingSlide = 0);
p.currSlide = p.startingSlide || 0, b = p.startingSlide, o.css({
position: "absolute",
top: 0,
left: 0
}).hide().each(function(t)
{
var i;
i = p.backwards ? b ? t <= b ? c.length + (t - b) : b - t : c.length - t : b ? t >= b ? c.length - (t - b) : b - t : c.length - t, n(this).css("z-index",i)
}), n(c[b]).css("opacity",1).show(), h(c[b],p), p.fit && (p.aspect ? o.each(function()
{
var t=n(this),
i=p.aspect === !0 ? t.width() / t.height() : p.aspect;
p.width && t.width() != p.width && (t.width(p.width), t.height(p.width / i)), p.height && t.height() < p.height && (t.height(p.height), t.width(p.height * i))
}) : (p.width && o.width(p.width), p.height && p.height != "auto" && o.height(p.height))), p.center && (!p.fit || p.aspect) && o.each(function()
{
var t=n(this);
t.css({
"margin-left": p.width ? (p.width - t.width()) / 2 + "px" : 0,
"margin-top": p.height ? (p.height - t.height()) / 2 + "px" : 0
})
}), !p.center || p.fit || p.slideResize || o.each(function()
{
var t=n(this);
t.css({
"margin-left": p.width ? (p.width - t.width()) / 2 + "px" : 0,
"margin-top": p.height ? (p.height - t.height()) / 2 + "px" : 0
})
}), vt = p.containerResize && !r.innerHeight();
if(vt)
{
for(nt = 0, g = 0, st = 0; st < c.length; st++)
{
var tt=n(c[st]),
et=tt[0],
ft=tt.outerWidth(),
ut=tt.outerHeight();
ft || (ft = et.offsetWidth || et.width || tt.attr("width")), ut || (ut = et.offsetHeight || et.height || tt.attr("height")), nt = ft > nt ? ft : nt, g = ut > g ? ut : g
}
nt > 0 && g > 0 && r.css({
width: nt + "px",
height: g + "px"
})
}
lt = !1, p.pause && r.hover(function()
{
lt = !0, this.cyclePause++, f(rt,!0)
},function()
{
lt && this.cyclePause--, f(rt,!0)
});
if(y(p) === !1)
return!1;
ct = !1, l.requeueAttempts = l.requeueAttempts || 0, o.each(function()
{
var t=n(this);
this.cycleH = p.fit && p.height ? p.height : t.height() || this.offsetHeight || this.height || t.attr("height") || 0, this.cycleW = p.fit && p.width ? p.width : t.width() || this.offsetWidth || this.width || t.attr("width") || 0;
if(t.is("img"))
{
var f=n.browser.msie && this.cycleW == 28 && this.cycleH == 30 && !this.complete,
e=n.browser.mozilla && this.cycleW == 34 && this.cycleH == 19 && !this.complete,
r=n.browser.opera && (this.cycleW == 42 && this.cycleH == 19 || this.cycleW == 37 && this.cycleH == 17) && !this.complete,
u=this.cycleH == 0 && this.cycleW == 0 && !this.complete;
if(f || e || r || u)
{
if(a.s && p.requeueOnImageNotLoaded && ++l.requeueAttempts < 100)
return i(l.requeueAttempts," - img slide not loaded, requeuing slideshow: ",this.src,this.cycleW,this.cycleH), setTimeout(function()
{
n(a.s,a.c).cycle(l)
},p.requeueTimeout), ct = !0, !1;
i("could not determine size of image: " + this.src,this.cycleW,this.cycleH)
}
}
return!0
});
if(ct)
return!1;
p.cssBefore = p.cssBefore || {}, p.cssAfter = p.cssAfter || {}, p.cssFirst = p.cssFirst || {}, p.animIn = p.animIn || {}, p.animOut = p.animOut || {}, o.not(":eq(" + b + ")").css(p.cssBefore), n(o[b]).css(p.cssFirst);
if(p.timeout)
{
p.timeout = parseInt(p.timeout,10), p.speed.constructor == String && (p.speed = n.fx.speeds[p.speed] || parseInt(p.speed,10)), p.sync || (p.speed = p.speed / 2), pt = p.fx == "none" ? 0 : p.fx == "shuffle" ? 500 : 250;
while(p.timeout - p.speed < pt)
p.timeout += p.speed
}
p.easing && (p.easeIn = p.easeOut = p.easing), p.speedIn || (p.speedIn = p.speed), p.speedOut || (p.speedOut = p.speed), p.slideCount = c.length, p.currSlide = p.lastSlide = b, p.random ? (++p.randomIndex == c.length && (p.randomIndex = 0), p.nextSlide = p.randomMap[p.randomIndex]) : p.nextSlide = p.backwards ? p.startingSlide == 0 ? c.length - 1 : p.startingSlide - 1 : p.startingSlide >= c.length - 1 ? 0 : p.startingSlide + 1;
if(!p.multiFx)
{
ht = n.fn.cycle.transitions[p.fx];
if(n.isFunction(ht))
ht(r,o,p);
else if(p.fx != "custom" && !p.multiFx)
return i("unknown transition: " + p.fx,"; slideshow terminating"), !1
}
return d = o[b], p.skipInitializationCallbacks || (p.before.length && p.before[0].apply(d,[d,d,p,!0]), p.after.length && p.after[0].apply(d,[d,d,p,!0])), p.next && n(p.next).bind(p.prevNextEvent,function()
{
return e(p,1)
}), p.prev && n(p.prev).bind(p.prevNextEvent,function()
{
return e(p,0)
}), (p.pager || p.pagerAnchorBuilder) && v(c,p), k(p,c), p
}
function w(t)
{
t.original = {
before: [],
after: []
}, t.original.cssBefore = n.extend({},t.cssBefore), t.original.cssAfter = n.extend({},t.cssAfter), t.original.animIn = n.extend({},t.animIn), t.original.animOut = n.extend({},t.animOut), n.each(t.before,function()
{
t.original.before.push(this)
}), n.each(t.after,function()
{
t.original.after.push(this)
})
}
function y(t)
{
var u,
e,
f=n.fn.cycle.transitions,
o,
h,
s;
if(t.fx.indexOf(",") > 0)
{
for(t.multiFx = !0, t.fxs = t.fx.replace(/\s*/g,"").split(","), u = 0; u < t.fxs.length; u++)
o = t.fxs[u], e = f[o], e && f.hasOwnProperty(o) && n.isFunction(e) || (i("discarding unknown transition: ",o), t.fxs.splice(u,1), u--);
if(!t.fxs.length)
return i("No valid transitions named; slideshow terminating."), !1
}
else if(t.fx == "all")
{
t.multiFx = !0, t.fxs = [];
for(p in f)
e = f[p], f.hasOwnProperty(p) && n.isFunction(e) && t.fxs.push(p)
}
if(t.multiFx && t.randomizeEffects)
{
for(h = Math.floor(Math.random() * 20) + 30, u = 0; u < h; u++)
s = Math.floor(Math.random() * t.fxs.length), t.fxs.push(t.fxs.splice(s,1)[0]);
r("randomized fx sequence: ",t.fxs)
}
return!0
}
function k(t, i)
{
t.addSlide = function(r, u)
{
var f=n(r),
e=f[0];
t.autostopCount || t.countdown++, i[u ? "unshift" : "push"](e), t.els && t.els[u ? "unshift" : "push"](e), t.slideCount = i.length, t.random && (t.randomMap.push(t.slideCount - 1), t.randomMap.sort(function()
{
return Math.random() - .5
})), f.css("position","absolute"), f[u ? "prependTo" : "appendTo"](t.$cont), u && (t.currSlide++, t.nextSlide++), n.support.opacity || !t.cleartype || t.cleartypeNoBg || s(f), t.fit && t.width && f.width(t.width), t.fit && t.height && t.height != "auto" && f.height(t.height), e.cycleH = t.fit && t.height ? t.height : f.height(), e.cycleW = t.fit && t.width ? t.width : f.width(), f.css(t.cssBefore), (t.pager || t.pagerAnchorBuilder) && n.fn.cycle.createPagerAnchor(i.length - 1,e,n(t.pager),i,t);
if(n.isFunction(t.onAddSlide))
t.onAddSlide(f);
else
f.hide()
}
}
function u(i, f, e, s)
{
function w()
{
var n=0,
t=f.timeout;
f.timeout && !f.continuous ? (n = o(i[f.currSlide],i[f.nextSlide],f,s), f.fx == "shuffle" && (n -= f.speedOut)) : f.continuous && l.cyclePause && (n = 10), n > 0 && (l.cycleTimeout = setTimeout(function()
{
u(i,f,0,!f.backwards)
},n))
}
var y,
v,
p,
a;
e && f.busy && f.manualTrump && (r("manualTrump in go(), stopping active transition"), n(i).stop(!0,!0), f.busy = 0);
if(f.busy)
{
r("transition active, ignoring new tx request");
return
}
var l=f.$cont[0],
c=i[f.currSlide],
h=i[f.nextSlide];
if(l.cycleStop != f.stopCount || l.cycleTimeout === 0 && !e)
return;
if(!e && !l.cyclePause && !f.bounce && (f.autostop && --f.countdown <= 0 || f.nowrap && !f.random && f.nextSlide < f.currSlide))
{
f.end && f.end(f);
return
}
y = !1, (e || !l.cyclePause) && f.nextSlide != f.currSlide ? (y = !0, v = f.fx, c.cycleH = c.cycleH || n(c).height(), c.cycleW = c.cycleW || n(c).width(), h.cycleH = h.cycleH || n(h).height(), h.cycleW = h.cycleW || n(h).width(), f.multiFx && (s && (f.lastFx == t || ++f.lastFx >= f.fxs.length) ? f.lastFx = 0 : !s && (f.lastFx == t || --f.lastFx < 0) && (f.lastFx = f.fxs.length - 1), v = f.fxs[f.lastFx]), f.oneTimeFx && (v = f.oneTimeFx, f.oneTimeFx = null), n.fn.cycle.resetState(f,v), f.before.length && n.each(f.before,function(n, t)
{
if(l.cycleStop != f.stopCount)
return;
t.apply(h,[c,h,f,s])
}), p = function()
{
f.busy = 0, n.each(f.after,function(n, t)
{
if(l.cycleStop != f.stopCount)
return;
t.apply(h,[c,h,f,s])
}), l.cycleStop || w()
}, r("tx firing(" + v + "); currSlide: " + f.currSlide + "; nextSlide: " + f.nextSlide), f.busy = 1, f.fxFn ? f.fxFn(c,h,f,p,s,e && f.fastOnEvent) : n.isFunction(n.fn.cycle[f.fx]) ? n.fn.cycle[f.fx](c,h,f,p,s,e && f.fastOnEvent) : n.fn.cycle.custom(c,h,f,p,s,e && f.fastOnEvent)) : w(), (y || f.nextSlide == f.currSlide) && (f.lastSlide = f.currSlide, f.random ? (f.currSlide = f.nextSlide, ++f.randomIndex == i.length && (f.randomIndex = 0, f.randomMap.sort(function()
{
return Math.random() - .5
})), f.nextSlide = f.randomMap[f.randomIndex], f.nextSlide == f.currSlide && (f.nextSlide = f.currSlide == f.slideCount - 1 ? 0 : f.currSlide + 1)) : f.backwards ? (a = f.nextSlide - 1 < 0, a && f.bounce ? (f.backwards = !f.backwards, f.nextSlide = 1, f.currSlide = 0) : (f.nextSlide = a ? i.length - 1 : f.nextSlide - 1, f.currSlide = a ? 0 : f.nextSlide + 1)) : (a = f.nextSlide + 1 == i.length, a && f.bounce ? (f.backwards = !f.backwards, f.nextSlide = i.length - 2, f.currSlide = i.length - 1) : (f.nextSlide = a ? 0 : f.nextSlide + 1, f.currSlide = a ? i.length - 1 : f.nextSlide - 1))), y && f.pager && f.updateActivePagerLink(f.pager,f.currSlide,f.activePagerClass)
}
function o(n, t, i, u)
{
if(i.timeoutFn)
{
var f=i.timeoutFn.call(n,n,t,i,u);
while(i.fx != "none" && f - i.speed < 250)
f += i.speed;
r("calculated timeout: " + f + "; speed: " + i.speed);
if(f !== !1)
return f
}
return i.timeout
}
function e(t, i)
{
var e=i ? 1 : -1,
r=t.elements,
o=t.$cont[0],
s=o.cycleTimeout,
f;
s && (clearTimeout(s), o.cycleTimeout = 0);
if(t.random && e < 0)
t.randomIndex--, --t.randomIndex == -2 ? t.randomIndex = r.length - 2 : t.randomIndex == -1 && (t.randomIndex = r.length - 1), t.nextSlide = t.randomMap[t.randomIndex];
else if(t.random)
t.nextSlide = t.randomMap[t.randomIndex];
else
{
t.nextSlide = t.currSlide + e;
if(t.nextSlide < 0)
{
if(t.nowrap)
return!1;
t.nextSlide = r.length - 1
}
else if(t.nextSlide >= r.length)
{
if(t.nowrap)
return!1;
t.nextSlide = 0
}
}
return f = t.onPrevNextEvent || t.prevNextClick, n.isFunction(f) && f(e > 0,t.nextSlide,r[t.nextSlide]), u(r,t,1,i), !1
}
function v(t, i)
{
var r=n(i.pager);
n.each(t,function(u, f)
{
n.fn.cycle.createPagerAnchor(u,f,r,t,i)
}), i.updateActivePagerLink(i.pager,i.startingSlide,i.activePagerClass)
}
function s(t)
{
function i(n)
{
return n = parseInt(n,10).toString(16), n.length < 2 ? "0" + n : n
}
function u(t)
{
for(var r, u; t && t.nodeName.toLowerCase() != "html"; t = t.parentNode)
{
r = n.css(t,"background-color");
if(r && r.indexOf("rgb") >= 0)
return u = r.match(/\d+/g), "#" + i(u[0]) + i(u[1]) + i(u[2]);
if(r && r != "transparent")
return r
}
return"#ffffff"
}
r("applying clearType background-color hack"), t.each(function()
{
n(this).css("background-color",u(this))
})
}
var c="2.9999";
n.support == t && (n.support = {opacity: !n.browser.msie}), n.expr[":"].paused = function(n)
{
return n.cyclePause
}, n.fn.cycle = function(t, f)
{
var e={
s: this.selector,
c: this.context
};
return this.length === 0 && t != "stop" ? !n.isReady && e.s ? (i("DOM not ready, queuing slideshow"), n(function()
{
n(e.s,e.c).cycle(t,f)
}), this) : (i("terminating; zero elements found by selector" + (n.isReady ? "" : " (DOM not ready)")), this) : this.each(function()
{
var c=l(this,t,f),
h;
if(c === !1)
return;
c.updateActivePagerLink = c.updateActivePagerLink || n.fn.cycle.updateActivePagerLink, this.cycleTimeout && clearTimeout(this.cycleTimeout), this.cycleTimeout = this.cyclePause = 0;
var y=n(this),
v=c.slideExpr ? n(c.slideExpr,this) : y.children(),
a=v.get(),
s=b(y,v,a,c,e);
if(s === !1)
return;
if(a.length < 2)
{
i("terminating; too few slides: " + a.length);
return
}
h = s.continuous ? 10 : o(a[s.currSlide],a[s.nextSlide],s,!s.backwards), h && (h += s.delay || 0, h < 10 && (h = 10), r("first timeout: " + h), this.cycleTimeout = setTimeout(function()
{
u(a,s,0,!c.backwards)
},h))
})
}, n.fn.cycle.resetState = function(t, i)
{
i = i || t.fx, t.before = [], t.after = [], t.cssBefore = n.extend({},t.original.cssBefore), t.cssAfter = n.extend({},t.original.cssAfter), t.animIn = n.extend({},t.original.animIn), t.animOut = n.extend({},t.original.animOut), t.fxFn = null, n.each(t.original.before,function()
{
t.before.push(this)
}), n.each(t.original.after,function()
{
t.after.push(this)
});
var r=n.fn.cycle.transitions[i];
n.isFunction(r) && r(t.$cont,n(t.elements),t)
}, n.fn.cycle.updateActivePagerLink = function(t, i, r)
{
n(t).each(function()
{
n(this).children().removeClass(r).eq(i).addClass(r)
})
}, n.fn.cycle.next = function(n)
{
e(n,1)
}, n.fn.cycle.prev = function(n)
{
e(n,0)
}, n.fn.cycle.createPagerAnchor = function(t, i, e, o, s)
{
var l,
h,
v,
y,
c,
a;
n.isFunction(s.pagerAnchorBuilder) ? (l = s.pagerAnchorBuilder(t,i), r("pagerAnchorBuilder(" + t + ", el) returned: " + l)) : l = '<a href="#">' + (t + 1) + "</a>";
if(!l)
return;
h = n(l), h.parents("body").length === 0 && (v = [], e.length > 1 ? (e.each(function()
{
var t=h.clone(!0);
n(this).append(t), v.push(t[0])
}), h = n(v)) : h.appendTo(e)), s.pagerAnchors = s.pagerAnchors || [], s.pagerAnchors.push(h), y = function(i)
{
var e,
f,
r;
i.preventDefault(), s.nextSlide = t, e = s.$cont[0], f = e.cycleTimeout, f && (clearTimeout(f), e.cycleTimeout = 0), r = s.onPagerEvent || s.pagerClick, n.isFunction(r) && r(s.nextSlide,o[s.nextSlide]), u(o,s,1,s.currSlide < t)
}, /mouseenter|mouseover/i.test(s.pagerEvent) ? h.hover(y,function(){}) : h.bind(s.pagerEvent,y), /^click/.test(s.pagerEvent) || s.allowPagerClickBubble || h.bind("click.cycle",function()
{
return!1
}), c = s.$cont[0], a = !1, s.pauseOnPagerHover && h.hover(function()
{
a = !0, c.cyclePause++, f(c,!0,!0)
},function()
{
a && c.cyclePause--, f(c,!0,!0)
})
}, n.fn.cycle.hopsFromLast = function(n, t)
{
var u,
i=n.lastSlide,
r=n.currSlide;
return u = t ? r > i ? r - i : n.slideCount - i : r < i ? i - r : i + n.slideCount - r
}, n.fn.cycle.commonReset = function(t, i, r, u, f, e)
{
n(r.elements).not(t).hide(), typeof r.cssBefore.opacity == "undefined" && (r.cssBefore.opacity = 1), r.cssBefore.display = "block", r.slideResize && u !== !1 && i.cycleW > 0 && (r.cssBefore.width = i.cycleW), r.slideResize && f !== !1 && i.cycleH > 0 && (r.cssBefore.height = i.cycleH), r.cssAfter = r.cssAfter || {}, r.cssAfter.display = "none", n(t).css("zIndex",r.slideCount + (e === !0 ? 1 : 0)), n(i).css("zIndex",r.slideCount + (e === !0 ? 0 : 1))
}, n.fn.cycle.custom = function(t, i, r, u, f, e)
{
var l=n(t),
a=n(i),
o=r.speedIn,
s=r.speedOut,
v=r.easeIn,
c=r.easeOut,
h;
a.css(r.cssBefore), e && (o = typeof e == "number" ? s = e : s = 1, v = c = null), h = function()
{
a.animate(r.animIn,o,v,function()
{
u()
})
}, l.animate(r.animOut,s,c,function()
{
l.css(r.cssAfter), r.sync || h()
}), r.sync && h()
}, n.fn.cycle.transitions = {fade: function(t, i, r)
{
i.not(":eq(" + r.currSlide + ")").css("opacity",0), r.before.push(function(t, i, r)
{
n.fn.cycle.commonReset(t,i,r), r.cssBefore.opacity = 0
}), r.animIn = {opacity: 1}, r.animOut = {opacity: 0}, r.cssBefore = {
top: 0,
left: 0
}
}}, n.fn.cycle.ver = function()
{
return c
}, n.fn.cycle.defaults = {
activePagerClass: "activeSlide",
after: null,
allowPagerClickBubble: !1,
animIn: null,
animOut: null,
aspect: !1,
autostop: 0,
autostopCount: 0,
backwards: !1,
before: null,
center: null,
cleartype: !n.support.opacity,
cleartypeNoBg: !1,
containerResize: 1,
continuous: 0,
cssAfter: null,
cssBefore: null,
delay: 0,
easeIn: null,
easeOut: null,
easing: null,
end: null,
fastOnEvent: 0,
fit: 0,
fx: "fade",
fxFn: null,
height: "auto",
manualTrump: !0,
metaAttr: "cycle",
next: null,
nowrap: 0,
onPagerEvent: null,
onPrevNextEvent: null,
pager: null,
pagerAnchorBuilder: null,
pagerEvent: "click.cycle",
pause: 0,
pauseOnPagerHover: 0,
prev: null,
prevNextEvent: "click.cycle",
random: 0,
randomizeEffects: 1,
requeueOnImageNotLoaded: !0,
requeueTimeout: 250,
rev: 0,
shuffle: null,
skipInitializationCallbacks: !1,
slideExpr: null,
slideResize: 1,
speed: 1e3,
speedIn: null,
speedOut: null,
startingSlide: t,
sync: 1,
timeout: 4e3,
timeoutFn: null,
updateActivePagerLink: null,
width: null
}
})(jQuery), function(n, t, i)
{
"use strict";
function p()
{
p.history = p.history || [], p.history.push(arguments);
if("object" == typeof console)
{
var t=console[console.warn ? "warn" : "log"],
n=Array.prototype.slice.call(arguments),
i;
typeof arguments[0] == "string" && (n[0] = "qTip2: " + n[0]), i = t.apply ? t.apply(console,n) : t(n)
}
}
function k(t)
{
var i;
return!t || "object" != typeof t ? r : ((t.metadata === e || "object" != typeof t.metadata) && (t.metadata = {type: t.metadata}), "content" in t && ((t.content === e || "object" != typeof t.content || t.content.jquery) && (t.content = {text: t.content}), i = t.content.text || r, n.isFunction(i) || (i || i.attr) && i.length >= 1 && ("object" != typeof i || i.jquery) || (t.content.text = r), "title" in t.content && ((t.content.title === e || "object" != typeof t.content.title) && (t.content.title = {text: t.content.title}), i = t.content.title.text || r, n.isFunction(i) || (i || i.attr) && i.length >= 1 && ("object" != typeof i || i.jquery) || (t.content.title.text = r))), "position" in t && (t.position === e || "object" != typeof t.position) && (t.position = {
my: t.position,
at: t.position
}), "show" in t && (t.show === e || "object" != typeof t.show) && (t.show = t.show.jquery ? {target: t.show} : {event: t.show}), "hide" in t && (t.hide === e || "object" != typeof t.hide) && (t.hide = t.hide.jquery ? {target: t.hide} : {event: t.hide}), "style" in t && (t.style === e || "object" != typeof t.style) && (t.style = {classes: t.style}), n.each(f,function()
{
this.sanitize && this.sanitize(t)
}), t)
}
function st(p, b, tt, it)
{
function kt(n)
{
var u=0,
r,
t=b,
i=n.split(".");
while(t = t[i[u++]])
u < i.length && (r = t);
return[r || b,i.pop()]
}
function gt()
{
var n=b.style.widget;
ut.toggleClass(g,n).toggleClass(nt,b.style["default"] && !n), et.content.toggleClass(g + "-content",n), et.titlebar && et.titlebar.toggleClass(g + "-header",n), et.button && et.button.toggleClass(s + "-icon",!n)
}
function at(n)
{
et.title && (et.titlebar.remove(), et.titlebar = et.title = et.button = e, n !== r && rt.reposition())
}
function dt()
{
var t=b.content.title.button,
u=typeof t == "string",
i=u ? t : "Close tooltip";
et.button && et.button.remove(), et.button = t.jquery ? t : n("<a />",{
"class": "ui-state-default ui-tooltip-close " + (b.style.widget ? "" : s + "-icon"),
title: i,
"aria-label": i
}).prepend(n("<span />",{
"class": "ui-icon ui-icon-close",
html: "&times;"
})), et.button.appendTo(et.titlebar).attr("role","button").click(function(n)
{
return ut.hasClass(h) || rt.hide(n), r
}), rt.redraw()
}
function yt()
{
var t=lt + "-title";
et.titlebar && at(), et.titlebar = n("<div />",{"class": s + "-titlebar " + (b.style.widget ? "ui-widget-header" : "")}).append(et.title = n("<div />",{
id: t,
"class": s + "-title",
"aria-atomic": u
})).insertBefore(et.content).delegate(".ui-tooltip-close","mousedown keydown mouseup keyup mouseout",function(t)
{
n(this).toggleClass("ui-state-active ui-state-focus",t.type.substr(-4) === "down")
}).delegate(".ui-tooltip-close","mouseover mouseout",function(t)
{
n(this).toggleClass("ui-state-hover",t.type === "mouseover")
}), b.content.title.button ? dt() : rt.rendered && rt.redraw()
}
function ti(n)
{
var i=et.button,
t=et.title;
if(!rt.rendered)
return r;
n ? (t || yt(), dt()) : i.remove()
}
function vt(t, i)
{
var u=et.title;
if(!rt.rendered || !t)
return r;
n.isFunction(t) && (t = t.call(p,ot.event,rt));
if(t === r)
return at(r);
t.jquery && t.length > 0 ? u.empty().append(t.css({display: "block"})) : u.html(t), rt.redraw(), i !== r && rt.rendered && ut.is(":visible") && rt.reposition(ot.event)
}
function pt(t, u)
{
function e(t)
{
function o(i)
{
i && (delete e[i.src], clearTimeout(rt.timers.img[i.src]), n(i).unbind(st)), n.isEmptyObject(e) && (rt.redraw(), u !== r && rt.reposition(ot.event), t())
}
var s,
e={};
if((s = f.find("img:not([height]):not([width])")).length === 0)
return o();
s.each(function(t, r)
{
if(e[r.src] !== i)
return;
var u=0,
s=3;
(function f()
{
if(r.height || r.width || u > s)
return o(r);
u += 1, rt.timers.img[r.src] = setTimeout(f,700)
})(), n(r).bind("error" + st + " load" + st,function()
{
o(this)
}), e[r.src] = r
})
}
var f=et.content;
return!rt.rendered || !t ? r : (n.isFunction(t) && (t = t.call(p,ot.event,rt) || ""), t.jquery && t.length > 0 ? f.empty().append(t.css({display: "block"})) : f.html(t), rt.rendered < 0 ? ut.queue("fx",e) : (ht = 0, e(n.noop)), rt)
}
function bt()
{
function y(n)
{
if(ut.hasClass(h))
return r;
clearTimeout(rt.timers.show), clearTimeout(rt.timers.hide);
var t=function()
{
rt.toggle(u,n)
};
b.show.delay > 0 ? rt.timers.show = setTimeout(t,b.show.delay) : t()
}
function s(t)
{
if(ut.hasClass(h) || ct || ht)
return r;
var e=n(t.relatedTarget || t.target),
u=e.closest(l)[0] === ut[0],
o=e[0] === i.show[0];
clearTimeout(rt.timers.show), clearTimeout(rt.timers.hide);
if(f.target === "mouse" && u || b.hide.fixed && /mouse(out|leave|move)/.test(t.type) && (u || o))
{
try
{
t.preventDefault(), t.stopImmediatePropagation()
}
catch(s){}
return
}
b.hide.delay > 0 ? rt.timers.hide = setTimeout(function()
{
rt.hide(t)
},b.hide.delay) : rt.hide(t)
}
function a(n)
{
if(ut.hasClass(h))
return r;
clearTimeout(rt.timers.inactive), rt.timers.inactive = setTimeout(function()
{
rt.hide(n)
},b.hide.inactive)
}
function v(n)
{
ut.is(":visible") && rt.reposition(n)
}
var f=b.position,
i={
show: b.show.target,
hide: b.hide.target,
viewport: n(f.viewport),
document: n(document),
body: n(document.body),
window: n(t)
},
e={
show: n.trim("" + b.show.event).split(" "),
hide: n.trim("" + b.hide.event).split(" ")
},
w=n.browser.msie && parseInt(n.browser.version,10) === 6;
ut.bind("mouseenter" + st + " mouseleave" + st,function(n)
{
var t=n.type === "mouseenter";
t && rt.focus(n), ut.toggleClass(ft,t)
}), b.hide.fixed && (i.hide = i.hide.add(ut), ut.bind("mouseover" + st,function()
{
ut.hasClass(h) || clearTimeout(rt.timers.hide)
})), /mouse(out|leave)/i.test(b.hide.event) ? b.hide.leave === "window" && i.window.bind("mouseout" + st + " blur" + st,function(n)
{
/select|option/.test(n.target) && !n.relatedTarget && rt.hide(n)
}) : /mouse(over|enter)/i.test(b.show.event) && i.hide.bind("mouseleave" + st,function()
{
clearTimeout(rt.timers.show)
}), ("" + b.hide.event).indexOf("unfocus") > -1 && i.body.bind("mousedown" + st,function(t)
{
var i=n(t.target),
r=!ut.hasClass(h) && ut.is(":visible");
i[0] !== ut[0] && i.parents(l).length === 0 && i.add(p).length > 1 && !i.attr("disabled") && rt.hide(t)
}), "number" == typeof b.hide.inactive && (i.show.bind("qtip-" + tt + "-inactive",a), n.each(o.inactiveEvents,function(n, t)
{
i.hide.add(et.tooltip).bind(t + st + "-inactive",a)
})), n.each(e.hide,function(t, r)
{
var f=n.inArray(r,e.show),
u=n(i.hide);
f > -1 && u.add(i.show).length === u.length || r === "unfocus" ? (i.show.bind(r + st,function(n)
{
ut.is(":visible") ? s(n) : y(n)
}), delete e.show[f]) : i.hide.bind(r + st,s)
}), n.each(e.show,function(n, t)
{
i.show.bind(t + st,y)
}), "number" == typeof b.hide.distance && i.show.add(ut).bind("mousemove" + st,function(n)
{
var r=ot.origin || {},
i=b.hide.distance,
t=Math.abs;
t(n.pageX - r.pageX) < i && t(n.pageY - r.pageY) < i || rt.hide(n)
}), f.target === "mouse" && (i.show.bind("mousemove" + st,function(n)
{
c = {
pageX: n.pageX,
pageY: n.pageY,
type: "mousemove"
}
}), f.adjust.mouse && (b.hide.event && ut.bind("mouseleave" + st,function(n)
{
(n.relatedTarget || n.target) !== i.show[0] && rt.hide(n)
}), i.document.bind("mousemove" + st,function(n)
{
!ut.hasClass(h) && ut.is(":visible") && rt.reposition(n || c)
}))), (f.adjust.resize || i.viewport.length) && (n.event.special.resize ? i.viewport : i.window).bind("resize" + st,v), (i.viewport.length || w && ut.css("position") === "fixed") && i.viewport.bind("scroll" + st,v)
}
function wt()
{
var i=[b.show.target[0],b.hide.target[0],rt.rendered && et.tooltip[0],b.position.container[0],b.position.viewport[0],t,document];
rt.rendered ? n([]).pushStack(n.grep(i,function(n)
{
return typeof n == "object"
})).unbind(st) : b.show.target.unbind(st + "-create")
}
var rt=this,
ni=document.body,
lt=s + "-" + tt,
ct=0,
ht=0,
ut=n(),
st=".qtip-" + tt,
et,
ot;
rt.id = tt, rt.rendered = r, rt.elements = et = {target: p}, rt.timers = {img: {}}, rt.options = b, rt.checks = {}, rt.plugins = {}, rt.cache = ot = {
event: {},
target: n(),
disabled: r,
attr: it
}, rt.checks.builtin = {
"^id$": function(t, i, f)
{
var h=f === u ? o.nextid : f,
e=s + "-" + h;
h !== r && h.length > 0 && !n("#" + e).length && (ut[0].id = e, et.content[0].id = e + "-content", et.title[0].id = e + "-title")
},
"^content.text$": function(n, t, i)
{
pt(i)
},
"^content.title.text$": function(n, t, i)
{
if(!i)
return at();
!et.title && i && yt(), vt(i)
},
"^content.title.button$": function(n, t, i)
{
ti(i)
},
"^position.(my|at)$": function(n, t, i)
{
"string" == typeof i && (n[t] = new f.Corner(i))
},
"^position.container$": function(n, t, i)
{
rt.rendered && ut.appendTo(i)
},
"^show.ready$": function()
{
rt.rendered ? rt.toggle(u) : rt.render(1)
},
"^style.classes$": function(n, t, i)
{
ut.attr("class",s + " qtip ui-helper-reset " + i)
},
"^style.widget|content.title": gt,
"^events.(render|show|move|hide|focus|blur)$": function(t, i, r)
{
ut[(n.isFunction(r) ? "" : "un") + "bind"]("tooltip" + i,r)
},
"^(show|hide|position).(event|target|fixed|inactive|leave|distance|viewport|adjust)": function()
{
var n=b.position;
ut.attr("tracking",n.target === "mouse" && n.adjust.mouse), wt(), bt()
}
}, n.extend(rt,{
render: function(t)
{
if(rt.rendered)
return rt;
var c=b.content.text,
i=b.content.title.text,
o=b.position,
e=n.Event("tooltiprender");
return n.attr(p[0],"aria-describedby",lt), ut = et.tooltip = n("<div/>",{
id: lt,
"class": s + " qtip ui-helper-reset " + nt + " " + b.style.classes + " " + s + "-pos-" + b.position.my.abbrev(),
width: b.style.width || "",
height: b.style.height || "",
tracking: o.target === "mouse" && o.adjust.mouse,
role: "alert",
"aria-live": "polite",
"aria-atomic": r,
"aria-describedby": lt + "-content",
"aria-hidden": u
}).toggleClass(h,ot.disabled).data("qtip",rt).appendTo(b.position.container).append(et.content = n("<div />",{
"class": s + "-content",
id: lt + "-content",
"aria-atomic": u
})), rt.rendered = -1, ht = 1, ct = 1, i && (yt(), n.isFunction(i) || vt(i,r)), n.isFunction(c) || pt(c,r), rt.rendered = u, gt(), n.each(b.events,function(t, i)
{
n.isFunction(i) && ut.bind(t === "toggle" ? "tooltipshow tooltiphide" : "tooltip" + t,i)
}), n.each(f,function()
{
this.initialize === "render" && this(rt)
}), bt(), ut.queue("fx",function(n)
{
e.originalEvent = ot.event, ut.trigger(e,[rt]), ht = 0, ct = 0, rt.redraw(), (b.show.ready || t) && rt.toggle(u,ot.event,r), n()
}), rt
},
get: function(n)
{
var t,
i;
switch(n.toLowerCase())
{
case"dimensions":
t = {
height: ut.outerHeight(),
width: ut.outerWidth()
};
break;
case"offset":
t = f.offset(ut,b.position.container);
break;
default:
i = kt(n.toLowerCase()), t = i[0][i[1]], t = t.precedance ? t.string() : t
}
return t
},
set: function(t, i)
{
function c(n, t)
{
var r,
i,
u;
for(r in o)
for(i in o[r])
(u = new RegExp(i,"i").exec(n)) && (t.push(u), o[r][i].apply(rt,t))
}
var a=/^position\.(my|at|adjust|target|container)|style|content|show\.ready/i,
l=/^content\.(title|attr)|style/i,
s=r,
f=r,
o=rt.checks,
h;
return"string" == typeof t ? (h = t, t = {}, t[h] = i) : t = n.extend(u,{},t), n.each(t,function(i, r)
{
var u=kt(i.toLowerCase()),
e;
e = u[0][u[1]], u[0][u[1]] = "object" == typeof r && r.nodeType ? n(r) : r, t[i] = [u[0],u[1],r,e], s = a.test(i) || s, f = l.test(i) || f
}), k(b), ct = ht = 1, n.each(t,c), ct = ht = 0, ut.is(":visible") && rt.rendered && (s && rt.reposition(b.position.target === "mouse" ? e : ot.event), f && rt.redraw()), rt
},
toggle: function(t, i)
{
function a()
{
t ? (n.browser.msie && ut[0].style.removeAttribute("filter"), ut.css("overflow",""), "string" == typeof f.autofocus && n(f.autofocus,ut).focus(), o = n.Event("tooltipvisible"), o.originalEvent = i ? ot.event : e, ut.trigger(o,[rt]), f.target.trigger("qtip-" + tt + "-inactive")) : ut.css({
display: "",
visibility: "",
opacity: "",
left: "",
top: ""
})
}
if(!rt.rendered)
return t ? rt.render(1) : rt;
var h=t ? "show" : "hide",
f=b[h],
v=ut.is(":visible"),
y=!i || b[h].target.length < 2 || ot.target[0] === i.target,
p=b.position,
s=b.content,
k,
o;
(typeof t).search("boolean|number") && (t = !v);
if(!ut.is(":animated") && v === t && y)
return rt;
if(i)
{
if(/over|enter/.test(i.type) && /out|leave/.test(ot.event.type) && i.target === b.show.target[0] && ut.has(i.relatedTarget).length)
return rt;
ot.event = n.extend({},i)
}
return o = n.Event("tooltip" + h), o.originalEvent = i ? ot.event : e, ut.trigger(o,[rt,90]), o.isDefaultPrevented() ? rt : (n.attr(ut[0],"aria-hidden",!!!t), t ? (ot.origin = n.extend({},c), rt.focus(i), n.isFunction(s.text) && pt(s.text,r), n.isFunction(s.title.text) && vt(s.title.text,r), !w && p.target === "mouse" && p.adjust.mouse && (n(document).bind("mousemove.qtip",function(n)
{
c = {
pageX: n.pageX,
pageY: n.pageY,
type: "mousemove"
}
}), w = u), rt.reposition(i,arguments[2]), (o.solo = !!f.solo) && n(l,f.solo).not(ut).qtip("hide",o)) : (clearTimeout(rt.timers.show), delete ot.origin, w && !n(l + '[tracking="true"]:visible',f.solo).not(ut).length && (n(document).unbind("mousemove.qtip"), w = r), rt.blur(i)), y && ut.stop(0,1), f.effect === r ? (ut[h](), a.call(ut)) : n.isFunction(f.effect) ? (f.effect.call(ut,rt), ut.queue("fx",function(n)
{
a(), n()
})) : ut.fadeTo(90,t ? 1 : 0,a), t && f.target.trigger("qtip-" + tt + "-inactive"), rt)
},
show: function(n)
{
return rt.toggle(u,n)
},
hide: function(n)
{
return rt.toggle(r,n)
},
focus: function(t)
{
if(!rt.rendered)
return rt;
var r=n(l),
f=parseInt(ut[0].style.zIndex,10),
u=o.zindex + r.length,
e=n.extend({},t),
s,
i;
return ut.hasClass(v) || (i = n.Event("tooltipfocus"), i.originalEvent = e, ut.trigger(i,[rt,u]), i.isDefaultPrevented() || (f !== u && (r.each(function()
{
this.style.zIndex > f && (this.style.zIndex = this.style.zIndex - 1)
}), r.filter("." + v).qtip("blur",e)), ut.addClass(v)[0].style.zIndex = u)), rt
},
blur: function(t)
{
var r=n.extend({},t),
i;
return ut.removeClass(v), i = n.Event("tooltipblur"), i.originalEvent = r, ut.trigger(i,[rt]), rt
},
reposition: function(i, u)
{
if(!rt.rendered || ct)
return rt;
ct = 1;
var o=b.position.target,
d=b.position,
l=d.my,
y=d.at,
k=d.adjust,
et=k.method.split(" "),
nt=ut.outerWidth(),
tt=ut.outerHeight(),
g=0,
p=0,
ht=n.Event("tooltipmove"),
it=ut.css("position") === "fixed",
h=d.viewport,
e={
left: 0,
top: 0
},
v=d.container,
ft=r,
a=rt.plugins.tip,
w={
horizontal: et[0],
vertical: et[1] = et[1] || et[0],
enabled: h.jquery && o[0] !== t && o[0] !== ni && k.method !== "none",
left: function(n)
{
var c=w.horizontal === "shift",
f=-v.offset.left + h.offset.left + h.scrollLeft,
s=l.x === "left" ? nt : l.x === "right" ? -nt : -nt / 2,
b=y.x === "left" ? g : y.x === "right" ? -g : -g / 2,
p=a && a.size ? a.size.width || 0 : 0,
i=a && a.corner && a.corner.precedance === "x" && !c ? p : 0,
u=f - n + i,
r=n + nt - h.width - f + i,
t=s - (l.precedance === "x" || l.x === l.y ? b : 0),
o=l.x === "center";
return c ? (i = a && a.corner && a.corner.precedance === "y" ? p : 0, t = (l.x === "left" ? 1 : -1) * s - i, e.left += u > 0 ? u : r > 0 ? -r : 0, e.left = Math.max(-v.offset.left + h.offset.left + (i && a.corner.x === "center" ? a.offset : 0),n - t,Math.min(Math.max(-v.offset.left + h.offset.left + h.width,n + t),e.left))) : (u > 0 && (l.x !== "left" || r > 0) ? e.left -= t : r > 0 && (l.x !== "right" || u > 0) && (e.left -= o ? -t : t), e.left !== n && o && (e.left -= k.x), e.left < f && -e.left > r && (e.left = n)), e.left - n
},
top: function(n)
{
var s=w.vertical === "shift",
o=-v.offset.top + h.offset.top + h.scrollTop,
c=l.y === "top" ? tt : l.y === "bottom" ? -tt : -tt / 2,
d=y.y === "top" ? p : y.y === "bottom" ? -p : -p / 2,
b=a && a.size ? a.size.height || 0 : 0,
i=a && a.corner && a.corner.precedance === "y" && !s ? b : 0,
u=o - n + i,
r=n + tt - h.height - o + i,
t=c - (l.precedance === "y" || l.x === l.y ? d : 0),
f=l.y === "center";
return s ? (i = a && a.corner && a.corner.precedance === "x" ? b : 0, t = (l.y === "top" ? 1 : -1) * c - i, e.top += u > 0 ? u : r > 0 ? -r : 0, e.top = Math.max(-v.offset.top + h.offset.top + (i && a.corner.x === "center" ? a.offset : 0),n - t,Math.min(Math.max(-v.offset.top + h.offset.top + h.height,n + t),e.top))) : (u > 0 && (l.y !== "top" || r > 0) ? e.top -= t : r > 0 && (l.y !== "bottom" || u > 0) && (e.top -= f ? -t : t), e.top !== n && f && (e.top -= k.y), e.top < 0 && -e.top > r && (e.top = n)), e.top - n
}
},
st;
if(n.isArray(o) && o.length === 2)
y = {
x: "left",
y: "top"
}, e = {
left: o[0],
top: o[1]
};
else if(o === "mouse" && (i && i.pageX || ot.event.pageX))
y = {
x: "left",
y: "top"
}, i = (i && (i.type === "resize" || i.type === "scroll") ? ot.event : i && i.pageX && i.type === "mousemove" ? i : c && c.pageX && (k.mouse || !i || !i.pageX) ? {
pageX: c.pageX,
pageY: c.pageY
} : !k.mouse && ot.origin && ot.origin.pageX ? ot.origin : i) || i || ot.event || c || {}, e = {
top: i.pageY,
left: i.pageX
};
else
{
o === "event" ? o = i && i.target && i.type !== "scroll" && i.type !== "resize" ? ot.target = n(i.target) : ot.target : ot.target = n(o), o = n(o).eq(0);
if(o.length === 0)
return rt;
o[0] === document || o[0] === t ? (g = f.iOS ? t.innerWidth : o.width(), p = f.iOS ? t.innerHeight : o.height(), o[0] === t && (e = {
top: it || f.iOS ? (h || o).scrollTop() : 0,
left: it || f.iOS ? (h || o).scrollLeft() : 0
})) : o.is("area") && f.imagemap ? e = f.imagemap(o,y,w.enabled ? et : r) : o[0].namespaceURI === "http://www.w3.org/2000/svg" && f.svg ? e = f.svg(o,y) : (g = o.outerWidth(), p = o.outerHeight(), e = f.offset(o,v)), e.offset && (g = e.width, p = e.height, ft = e.flipoffset, e = e.offset), (f.iOS < 4.1 && f.iOS > 3.1 || f.iOS == 4.3 || !f.iOS && it) && (st = n(t), e.left -= st.scrollLeft(), e.top -= st.scrollTop()), e.left += y.x === "right" ? g : y.x === "center" ? g / 2 : 0, e.top += y.y === "bottom" ? p : y.y === "center" ? p / 2 : 0
}
return e.left += k.x + (l.x === "right" ? -nt : l.x === "center" ? -nt / 2 : 0), e.top += k.y + (l.y === "bottom" ? -tt : l.y === "center" ? -tt / 2 : 0), w.enabled ? (h = {
elem: h,
height: h[(h[0] === t ? "h" : "outerH") + "eight"](),
width: h[(h[0] === t ? "w" : "outerW") + "idth"](),
scrollLeft: it ? 0 : h.scrollLeft(),
scrollTop: it ? 0 : h.scrollTop(),
offset: h.offset() || {
left: 0,
top: 0
}
}, v = {
elem: v,
scrollLeft: v.scrollLeft(),
scrollTop: v.scrollTop(),
offset: v.offset() || {
left: 0,
top: 0
}
}, e.adjusted = {
left: w.horizontal !== "none" ? w.left(e.left) : 0,
top: w.vertical !== "none" ? w.top(e.top) : 0
}, e.adjusted.left + e.adjusted.top && ut.attr("class",ut[0].className.replace(/ui-tooltip-pos-\w+/i,s + "-pos-" + l.abbrev())), ft && e.adjusted.left && (e.left += ft.left), ft && e.adjusted.top && (e.top += ft.top)) : e.adjusted = {
left: 0,
top: 0
}, ht.originalEvent = n.extend({},i), ut.trigger(ht,[rt,e,h.elem || h]), ht.isDefaultPrevented() ? rt : (delete e.adjusted, u === r || isNaN(e.left) || isNaN(e.top) || o === "mouse" || !n.isFunction(d.effect) ? ut.css(e) : n.isFunction(d.effect) && (d.effect.call(ut,rt,n.extend({},e)), ut.queue(function(t)
{
n(this).css({
opacity: "",
height: ""
}), n.browser.msie && this.style.removeAttribute("filter"), t()
})), ct = 0, rt)
},
redraw: function()
{
if(rt.rendered < 1 || ht)
return rt;
var u=b.position.container,
r,
i,
n,
t;
return ht = 1, b.style.height && ut.css("height",b.style.height), b.style.width ? ut.css("width",b.style.width) : (ut.css("width","").addClass(y), i = ut.width() + 1, n = ut.css("max-width") || "", t = ut.css("min-width") || "", r = (n + t).indexOf("%") > -1 ? u.width() / 100 : 0, n = (n.indexOf("%") > -1 ? r : 1) * parseInt(n,10) || i, t = (t.indexOf("%") > -1 ? r : 1) * parseInt(t,10) || 0, i = n + t ? Math.min(Math.max(i,t),n) : i, ut.css("width",Math.round(i)).removeClass(y)), ht = 0, rt
},
disable: function(t)
{
return"boolean" != typeof t && (t = !(ut.hasClass(h) || ot.disabled)), rt.rendered ? (ut.toggleClass(h,t), n.attr(ut[0],"aria-disabled",t)) : ot.disabled = !!t, rt
},
enable: function()
{
return rt.disable(r)
},
destroy: function()
{
var t=p[0],
r=n.attr(t,a),
i=p.data("qtip");
return rt.rendered && (ut.remove(), n.each(rt.plugins,function()
{
this.destroy && this.destroy()
})), clearTimeout(rt.timers.show), clearTimeout(rt.timers.hide), wt(), i && rt !== i || (n.removeData(t,"qtip"), b.suppress && r && (n.attr(t,"title",r), p.removeAttr(a)), p.removeAttr("aria-describedby")), p.unbind(".qtip-" + tt), delete d[rt.id], p
}
})
}
function ot(t, i)
{
var y,
h,
v,
s,
g,
c=n(this),
d=n(document.body),
b=this === document ? d : c,
w=c.metadata ? c.metadata(i.metadata) : e,
nt=i.metadata.type === "html5" && w ? w[i.metadata.name] : e,
l=c.data(i.metadata.name || "qtipopts");
try
{
l = typeof l == "string" ? new Function("return " + l)() : l
}
catch(tt)
{
p("Unable to parse HTML5 attribute data: " + l)
}
s = n.extend(u,{},o.defaults,i,typeof l == "object" ? k(l) : e,k(nt || w)), h = s.position, s.id = t;
if("boolean" == typeof s.content.text)
{
v = c.attr(s.content.attr);
if(s.content.attr !== r && v)
s.content.text = v;
else
return p("Unable to locate content for tooltip! Aborting render of tooltip on element: ",c), r
}
h.container.length || (h.container = d), h.target === r && (h.target = b), s.show.target === r && (s.show.target = b), s.show.solo === u && (s.show.solo = d), s.hide.target === r && (s.hide.target = b), s.position.viewport === u && (s.position.viewport = h.container), h.at = new f.Corner(h.at), h.my = new f.Corner(h.my);
if(n.data(this,"qtip"))
if(s.overwrite)
c.qtip("destroy");
else if(s.overwrite === r)
return r;
return s.suppress && (g = n.attr(this,"title")) && n(this).removeAttr("title").attr(a,g), y = new st(c,s,t,!!v), n.data(this,"qtip",y), c.bind("remove.qtip-" + t,function()
{
y.destroy()
}), y
}
function et(t)
{
var f=this,
o=t.elements.tooltip,
i=t.options.content.ajax,
e=".qtip-ajax",
s=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,
h=u;
t.checks.ajax = {"^content.ajax": function(n, t, r)
{
t === "ajax" && (i = r), t === "once" ? f.init() : i && i.url ? f.load() : o.unbind(e)
}}, n.extend(f,{
init: function()
{
return i && i.url && o.unbind(e)[i.once ? "one" : "bind"]("tooltipshow" + e,f.load), f
},
load: function(u, e)
{
function y()
{
l && (t.show(u.originalEvent), e = r), n.isFunction(i.complete) && i.complete.apply(this,arguments)
}
function v(i)
{
h && (i = n("<div/>").append(i.replace(s,"")).find(h)), t.set("content.text",i)
}
function a(n, i, r)
{
if(n.status === 0)
return;
t.set("content.text",i + ": " + r)
}
var c=i.url.indexOf(" "),
o=i.url,
h,
l=i.once && !i.loading && e;
if(l)
try
{
u.preventDefault()
}
catch(p){}
else if(u && u.isDefaultPrevented())
return f;
c > -1 && (h = o.substr(c), o = o.substr(0,c)), n.ajax(n.extend({
success: v,
error: a,
context: t
},i,{
url: o,
complete: y
}))
}
}), f.init()
}
function tt(t)
{
var u=this,
i=t.elements,
r=i.tooltip,
f=".bgiframe-" + t.id;
n.extend(u,{
init: function()
{
i.bgiframe = n('<iframe class="ui-tooltip-bgiframe" frameborder="0" tabindex="-1" src="javascript:\'\';"  style="display:block; position:absolute; z-index:-1; filter:alpha(opacity=0); -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";"></iframe>'), i.bgiframe.appendTo(r), r.bind("tooltipmove" + f,u.adjust)
},
adjust: function()
{
var o=t.get("dimensions"),
e=t.plugins.tip,
f=i.tip,
u,
n;
n = parseInt(r.css("border-left-width"),10) || 0, n = {
left: -n,
top: -n
}, e && f && (u = e.corner.precedance === "x" ? ["width","left"] : ["height","top"], n[u[1]] -= f[u[0]]()), i.bgiframe.css(n).css(o)
},
destroy: function()
{
i.bgiframe.remove(), r.unbind(f)
}
}), u.init()
}
function ut(i)
{
var o=this,
p=i.options.show.modal,
a=i.elements,
s=a.tooltip,
b="#qtip-overlay",
h=".qtipmodal",
c=h + i.id,
y="is-modal-qtip",
w=n(document.body),
e;
i.checks.modal = {"^show.modal.(on|blur)$": function()
{
o.init(), a.overlay.toggle(s.is(":visible"))
}}, n.extend(o,{
init: function()
{
return p.on ? (e = o.create(), s.attr(y,u).css("z-index",f.modal.zindex + n(l + "[" + y + "]").length).unbind(h).unbind(c).bind("tooltipshow" + h + " tooltiphide" + h,function(t, i, r)
{
var u=t.originalEvent;
if(u && t.type === "tooltiphide" && /mouse(leave|enter)/.test(u.type) && n(u.relatedTarget).closest(e[0]).length)
try
{
t.preventDefault()
}
catch(f){}
else
u && (!u || u.solo) || o[t.type.replace("tooltip","")](t,r)
}).bind("tooltipfocus" + h,function(t)
{
if(t.isDefaultPrevented())
return;
var i=n(l).filter("[" + y + "]"),
r=f.modal.zindex + i.length,
u=parseInt(s[0].style.zIndex,10);
e[0].style.zIndex = r - 1, i.each(function()
{
this.style.zIndex > u && (this.style.zIndex -= 1)
}), i.end().filter("." + v).qtip("blur",t.originalEvent), s.addClass(v)[0].style.zIndex = r;
try
{
t.preventDefault()
}
catch(o){}
}).bind("tooltiphide" + h,function(t)
{
n("[" + y + "]").filter(":visible").not(s).last().qtip("focus",t)
}), p.escape && n(t).unbind(c).bind("keydown" + c,function(n)
{
n.keyCode === 27 && s.hasClass(v) && i.hide(n)
}), p.blur && a.overlay.unbind(c).bind("click" + c,function(n)
{
s.hasClass(v) && i.hide(n)
}), o) : o
},
create: function()
{
var i=n(b);
return i.length ? a.overlay = i.insertAfter(n(l).last()) : (e = a.overlay = n("<div />",{
id: b.substr(1),
html: "<div></div>",
mousedown: function()
{
return r
}
}).insertAfter(n(l).last()), n(t).unbind(h).bind("resize" + h,function()
{
e.css({
height: n(t).height(),
width: n(t).width()
})
}).triggerHandler("resize"), e)
},
toggle: function(t, i, f)
{
if(t && t.isDefaultPrevented())
return o;
var h=p.effect,
b=i ? "show" : "hide",
v=e.is(":visible"),
a=n("[" + y + "]").filter(":visible").not(s),
k;
return e || (e = o.create()), e.is(":animated") && v === i || !i && a.length ? o : (i ? (e.css({
left: 0,
top: 0
}), e.toggleClass("blurs",p.blur), w.bind("focusin" + c,function(t)
{
var f=n(t.target),
i=f.closest(".qtip"),
u=i.length < 1 ? r : parseInt(i[0].style.zIndex,10) > parseInt(s[0].style.zIndex,10);
u || n(t.target).closest(l)[0] === s[0] || s.find("input:visible").filter(":first").focus()
})) : w.undelegate("*","focusin" + c), e.stop(u,r), n.isFunction(h) ? h.call(e,i) : h === r ? e[b]() : e.fadeTo(parseInt(f,10) || 90,i ? 1 : 0,function()
{
i || n(this).hide()
}), i || e.queue(function(n)
{
e.css({
left: "",
top: ""
}), n()
}), o)
},
show: function(n, t)
{
return o.toggle(n,u,t)
},
hide: function(n, t)
{
return o.toggle(n,r,t)
},
destroy: function()
{
var r=e;
return r && (r = n("[" + y + "]").not(s).length < 1, r ? (a.overlay.remove(), n(t).unbind(h)) : a.overlay.unbind(h + i.id), w.undelegate("*","focusin" + c)), s.removeAttr(y).unbind(h)
}
}), o.init()
}
function rt(n, t, i)
{
var u=Math.ceil(t / 2),
f=Math.ceil(i / 2),
r={
bottomright: [[0,0],[t,i],[t,0]],
bottomleft: [[0,0],[t,0],[0,i]],
topright: [[0,i],[t,0],[t,i]],
topleft: [[0,0],[0,i],[t,i]],
topcenter: [[0,i],[u,0],[t,i]],
bottomcenter: [[0,0],[t,0],[u,i]],
rightcenter: [[0,0],[t,f],[0,i]],
leftcenter: [[t,0],[t,i],[0,f]]
};
return r.lefttop = r.bottomright, r.righttop = r.bottomleft, r.leftbottom = r.topright, r.rightbottom = r.topleft, r[n.string()]
}
function it(t)
{
function nt(n, f, e)
{
if(!h.tip)
return;
var l=s.corner.clone(),
v=e.adjusted,
g=t.options.position.adjust.method.split(" "),
d=g[0],
k=g[1] || g[0],
y={
left: r,
top: r,
x: 0,
y: 0
},
c,
b={},
p;
s.corner.fixed !== u && (d === "shift" && l.precedance === "x" && v.left && l.y !== "center" ? l.precedance = l.precedance === "x" ? "y" : "x" : d === "flip" && v.left && (l.x = l.x === "center" ? v.left > 0 ? "left" : "right" : l.x === "left" ? "right" : "left"), k === "shift" && l.precedance === "y" && v.top && l.x !== "center" ? l.precedance = l.precedance === "y" ? "x" : "y" : k === "flip" && v.top && (l.y = l.y === "center" ? v.top > 0 ? "top" : "bottom" : l.y === "top" ? "bottom" : "top"), l.string() !== w.corner.string() && (w.top !== v.top || w.left !== v.left) && s.update(l,r)), c = s.position(l,v), c.right !== i && (c.left = -c.right), c.bottom !== i && (c.top = -c.bottom), c.user = Math.max(0,a.offset), (y.left = d === "shift" && !!v.left) && (l.x === "center" ? b["margin-left"] = y.x = c["margin-left"] - v.left : (p = c.right !== i ? [v.left,-c.left] : [-v.left,c.left], (y.x = Math.max(p[0],p[1])) > p[0] && (e.left -= v.left, y.left = r), b[c.right !== i ? "right" : "left"] = y.x)), (y.top = k === "shift" && !!v.top) && (l.y === "center" ? b["margin-top"] = y.y = c["margin-top"] - v.top : (p = c.bottom !== i ? [v.top,-c.top] : [-v.top,c.top], (y.y = Math.max(p[0],p[1])) > p[0] && (e.top -= v.top, y.top = r), b[c.bottom !== i ? "bottom" : "top"] = y.y)), h.tip.css(b).toggle(!(y.x && y.y || l.x === "center" && y.y || l.y === "center" && y.x)), e.left -= c.left.charAt ? c.user : d !== "shift" || y.top || !y.left && !y.top ? c.left : 0, e.top -= c.top.charAt ? c.user : k !== "shift" || y.left || !y.left && !y.top ? c.top : 0, w.left = v.left, w.top = v.top, w.corner = l.clone()
}
function b(n, t, i)
{
t = t ? t : n[n.precedance];
var f=v.hasClass(y),
e=h.titlebar && n.y === "top",
o=e ? h.titlebar : h.content,
u="border-" + t + "-width",
r;
return v.addClass(y), r = parseInt(o.css(u),10), r = (i ? r || parseInt(v.css(u),10) : r) || 0, v.toggleClass(y,f), r
}
function tt(t)
{
var e=h.titlebar && t.y === "top",
f=e ? h.titlebar : h.content,
i=n.browser.mozilla,
o=i ? "-moz-" : n.browser.webkit ? "-webkit-" : "",
r=t.y + (i ? "" : "-") + t.x,
u=o + (i ? "border-radius-" + r : "border-" + r + "-radius");
return parseInt(f.css(u),10) || parseInt(v.css(u),10) || 0
}
function g(n)
{
var u=n.precedance === "y",
s=p[u ? "width" : "height"],
o=p[u ? "height" : "width"],
l=n.string().indexOf("center") > -1,
h=s * (l ? .5 : 1),
i=Math.pow,
v=Math.round,
a,
e,
f,
r=Math.sqrt(i(h,2) + i(o,2)),
t=[c / h * r,c / o * r];
return t[2] = Math.sqrt(i(t[0],2) - i(c,2)), t[3] = Math.sqrt(i(t[1],2) - i(c,2)), a = r + t[2] + t[3] + (l ? 0 : t[0]), e = a / r, f = [v(e * o),v(e * s)], {
height: f[u ? 0 : 1],
width: f[u ? 1 : 0]
}
}
var s=this,
a=t.options.style.tip,
h=t.elements,
v=h.tooltip,
w={
top: 0,
left: 0
},
p={
width: a.width,
height: a.height
},
l={},
c=a.border || 0,
d=".qtip-tip",
k=!!(n("<canvas />")[0] || {}).getContext;
s.corner = e, s.mimic = e, s.border = c, s.offset = a.offset, s.size = p, t.checks.tip = {
"^position.my|style.tip.(corner|mimic|border)$": function()
{
s.init() || s.destroy(), t.reposition()
},
"^style.tip.(height|width)$": function()
{
p = {
width: a.width,
height: a.height
}, s.create(), s.update(), t.reposition()
},
"^content.title.text|style.(classes|widget)$": function()
{
h.tip && s.update()
}
}, n.extend(s,{
init: function()
{
var t=s.detectCorner() && (k || n.browser.msie);
return t && (s.create(), s.update(), v.unbind(d).bind("tooltipmove" + d,nt)), t
},
detectCorner: function()
{
var i=a.corner,
n=t.options.position,
o=n.at,
e=n.my.string ? n.my.string() : n.my;
return i === r || e === r && o === r ? r : (i === u ? s.corner = new f.Corner(e) : i.string || (s.corner = new f.Corner(i), s.corner.fixed = u), s.corner.string() !== "centercenter")
},
detectColours: function(i)
{
var rt,
c,
u,
r=h.tip.css("cssText",""),
o=i || s.corner,
b=o[o.precedance],
k="border-" + b + "-color",
tt="border" + b.charAt(0) + b.substr(1) + "Color",
f=/rgba?\(0, 0, 0(, 0)?\)|transparent|#123456/i,
e="background-color",
w="transparent",
d=" !important",
it=n(document.body).css("color"),
ut=t.elements.content.css("color"),
nt=h.titlebar && (o.y === "top" || o.y === "center" && r.position().top + p.height / 2 + a.offset < h.titlebar.outerHeight(1)),
g=nt ? h.titlebar : h.content;
v.addClass(y), l.fill = c = r.css(e), l.border = u = r[0].style[tt] || r.css(k) || v.css(k), (!c || f.test(c)) && (l.fill = g.css(e) || w, f.test(l.fill) && (l.fill = v.css(e) || c)), (!u || f.test(u) || u === it) && (l.border = g.css(k) || w, f.test(l.border) && (l.border = u)), n("*",r).add(r).css("cssText",e + ":" + w + d + ";border:0" + d + ";"), v.removeClass(y)
},
create: function()
{
var i=p.width,
r=p.height,
t;
h.tip && h.tip.remove(), h.tip = n("<div />",{"class": "ui-tooltip-tip"}).css({
width: i,
height: r
}).prependTo(v), k ? n("<canvas />").appendTo(h.tip)[0].getContext("2d").save() : (t = '<vml:shape coordorigin="0,0" style="display:inline-block; position:absolute; behavior:url(#default#VML);"></vml:shape>', h.tip.html(t + t), n("*",h.tip).bind("click mousedown",function(n)
{
n.stopPropagation()
}))
},
update: function(t, i)
{
var ot=h.tip,
et=ot.children(),
it=p.width,
tt=p.height,
ht="px solid ",
st="px dashed transparent",
o=a.mimic,
ut=Math.round,
ft,
v,
y,
nt,
d;
t || (t = w.corner || s.corner), o === r ? o = t : (o = new f.Corner(o), o.precedance = t.precedance, o.x === "inherit" ? o.x = t.x : o.y === "inherit" ? o.y = t.y : o.x === o.y && (o[t.precedance] = t[t.precedance])), ft = o.precedance, s.detectColours(t), l.border !== "transparent" && l.border !== "#123456" ? (c = b(t,e,u), a.border === 0 && c > 0 && (l.fill = l.border), s.border = c = a.border !== u ? a.border : c) : s.border = c = 0, y = rt(o,it,tt), s.size = d = g(t), ot.css(d), nt = t.precedance === "y" ? [ut(o.x === "left" ? c : o.x === "right" ? d.width - it - c : (d.width - it) / 2),ut(o.y === "top" ? d.height - tt : 0)] : [ut(o.x === "left" ? d.width - it : 0),ut(o.y === "top" ? c : o.y === "bottom" ? d.height - tt - c : (d.height - tt) / 2)], k ? (et.attr(d), v = et[0].getContext("2d"), v.restore(), v.save(), v.clearRect(0,0,3e3,3e3), v.translate(nt[0],nt[1]), v.beginPath(), v.moveTo(y[0][0],y[0][1]), v.lineTo(y[1][0],y[1][1]), v.lineTo(y[2][0],y[2][1]), v.closePath(), v.fillStyle = l.fill, v.strokeStyle = l.border, v.lineWidth = c * 2, v.lineJoin = "miter", v.miterLimit = 100, c && v.stroke(), v.fill()) : (y = "m" + y[0][0] + "," + y[0][1] + " l" + y[1][0] + "," + y[1][1] + " " + y[2][0] + "," + y[2][1] + " xe", nt[2] = c && /^(r|b)/i.test(t.string()) ? parseFloat(n.browser.version,10) === 8 ? 2 : 1 : 0, et.css({
antialias: "" + (o.string().indexOf("center") > -1),
left: nt[0] - nt[2] * Number(ft === "x"),
top: nt[1] - nt[2] * Number(ft === "y"),
width: it + c,
height: tt + c
}).each(function(t)
{
var i=n(this);
i[i.prop ? "prop" : "attr"]({
coordsize: it + c + " " + (tt + c),
path: y,
fillcolor: l.fill,
filled: !!t,
stroked: !!!t
}).css({display: c || t ? "block" : "none"}), t || i.html() !== "" || i.html('<vml:stroke weight="' + c * 2 + 'px" color="' + l.border + '" miterlimit="1000" joinstyle="miter"  style="behavior:url(#default#VML); display:inline-block;" />')
})), i !== r && s.position(t)
},
position: function(t)
{
var v=h.tip,
i={},
l=Math.max(0,a.offset),
f,
e,
o;
return a.corner === r || !v ? r : (t = t || s.corner, f = t.precedance, e = g(t), o = [t.x,t.y], f === "x" && o.reverse(), n.each(o,function(n, r)
{
var o,
s;
r === "center" ? (o = f === "y" ? "left" : "top", i[o] = "50%", i["margin-" + o] = -Math.round(e[f === "y" ? "width" : "height"] / 2) + l) : (o = b(t,r,u), s = tt(t), i[r] = n ? c ? b(t,r) : 0 : l + (s > o ? s : 0))
}), i[t[f]] -= e[f === "x" ? "width" : "height"], v.css({
top: "",
bottom: "",
left: "",
right: "",
margin: ""
}).css(i), i)
},
destroy: function()
{
h.tip && h.tip.remove(), v.unbind(d)
}
}), w.corner = new f.Corner(s.init())
}
var u=!0,
r=!1,
e=null,
o,
f,
c,
d={},
s="ui-tooltip",
g="ui-widget",
h="ui-state-disabled",
l="div.qtip." + s,
nt=s + "-default",
v=s + "-focus",
ft=s + "-hover",
y=s + "-fluid",
ht="-31000px",
b="_replacedByqTip",
a="oldtitle",
w;
o = n.fn.qtip = function(t, f, s)
{
var h=("" + t).toLowerCase(),
a=e,
v=n.makeArray(arguments).slice(1),
c=v[v.length - 1],
l=this[0] ? n.data(this[0],"qtip") : e;
return!arguments.length && l || h === "api" ? l : "string" == typeof t ? (this.each(function()
{
var t=n.data(this,"qtip");
if(!t)
return u;
c && c.timeStamp && (t.cache.event = c);
if((h === "option" || h === "options") && f)
if(n.isPlainObject(f) || s !== i)
t.set(f,s);
else
return a = t.get(f), r;
else
t[h] && t[h].apply(t[h],v)
}), a !== e ? a : this) : "object" == typeof t || !arguments.length ? (l = k(n.extend(u,{},t)), o.bind.call(this,l,c)) : void 0
}, o.bind = function(t, e)
{
return this.each(function(s)
{
function w(t)
{
function u()
{
h.render(typeof t == "object" || l.show.ready), p.show.add(p.hide).unbind(v)
}
if(h.cache.disabled)
return r;
h.cache.event = n.extend({},t), h.cache.target = t ? n(t.target) : [i], l.show.delay > 0 ? (clearTimeout(h.timers.show), h.timers.show = setTimeout(u,l.show.delay), y.show !== y.hide && p.hide.bind(y.hide,function()
{
clearTimeout(h.timers.show)
})) : u()
}
var l,
p,
y,
v,
h,
a;
a = n.isArray(t.id) ? t.id[s] : t.id, a = !a || a === r || a.length < 1 || d[a] ? o.nextid++ : d[a] = a, v = ".qtip-" + a + "-create", h = ot.call(this,a,t);
if(h === r)
return u;
l = h.options, n.each(f,function()
{
this.initialize === "initialize" && this(h)
}), p = {
show: l.show.target,
hide: l.hide.target
}, y = {
show: n.trim("" + l.show.event).replace(/ /g,v + " ") + v,
hide: n.trim("" + l.hide.event).replace(/ /g,v + " ") + v
}, /mouse(over|enter)/i.test(y.show) && !/mouse(out|leave)/i.test(y.hide) && (y.hide += " mouseleave" + v), p.show.bind("mousemove" + v,function(n)
{
c = {
pageX: n.pageX,
pageY: n.pageY,
type: "mousemove"
}
}), p.show.bind(y.show,w), (l.show.ready || l.prerender) && w(e)
})
}, f = o.plugins = {
Corner: function(n)
{
n = ("" + n).replace(/([A-Z])/," $1").replace(/middle/gi,"center").toLowerCase(), this.x = (n.match(/left|right/i) || n.match(/center/) || ["inherit"])[0].toLowerCase(), this.y = (n.match(/top|bottom|center/i) || ["inherit"])[0].toLowerCase();
var t=n.charAt(0);
this.precedance = t === "t" || t === "b" ? "y" : "x", this.string = function()
{
return this.precedance === "y" ? this.y + this.x : this.x + this.y
}, this.abbrev = function()
{
var n=this.x.substr(0,1),
t=this.y.substr(0,1);
return n === t ? n : n === "c" || n !== "c" && t !== "c" ? t + n : n + t
}, this.clone = function()
{
return{
x: this.x,
y: this.y,
precedance: this.precedance,
string: this.string,
abbrev: this.abbrev,
clone: this.clone
}
}
},
offset: function(n, t)
{
function s(n, t)
{
r.left += t * n.scrollLeft(), r.top += t * n.scrollTop()
}
var r=n.offset(),
i=t,
o=0,
f=document.body,
u,
e;
if(i)
{
do
{
i.css("position") !== "static" && (u = i[0] === f ? {
left: parseInt(i.css("left"),10) || 0,
top: parseInt(i.css("top"),10) || 0
} : i.position(), r.left -= u.left + (parseInt(i.css("borderLeftWidth"),10) || 0) + (parseInt(i.css("marginLeft"),10) || 0), r.top -= u.top + (parseInt(i.css("borderTopWidth"),10) || 0), e = i.css("overflow"), (e === "scroll" || e === "auto") && o++);
if(i[0] === f)
break
} while(i = i.offsetParent());
t[0] !== f && o && s(t,1)
}
return r
},
iOS: parseFloat(("" + (/CPU.*OS ([0-9_]{1,3})|(CPU like).*AppleWebKit.*Mobile/i.exec(navigator.userAgent) || [0,""])[1]).replace("undefined","3_2").replace("_",".")) || r,
fn: {
attr: function(t, i)
{
if(this.length)
{
var u=this[0],
f="title",
r=n.data(u,"qtip");
if(t === f && r && "object" == typeof r && r.options.suppress)
return arguments.length < 2 ? n.attr(u,a) : (r && r.options.content.attr === f && r.cache.attr && r.set("content.text",i), this.attr(a,i))
}
return n.fn["attr" + b].apply(this,arguments)
},
clone: function(t)
{
var r=n([]),
u="title",
i=n.fn["clone" + b].apply(this,arguments);
return t || i.filter("[" + a + "]").attr("title",function()
{
return n.attr(this,a)
}).removeAttr(a), i
},
remove: n.ui ? e : function(t, i)
{
if(n.ui)
return;
n(this).each(function()
{
i || (!t || n.filter(t,[this]).length) && n("*",this).add(this).each(function()
{
n(this).triggerHandler("remove")
})
})
}
}
}, n.each(f.fn,function(t, i)
{
if(!i || n.fn[t + b])
return u;
var r=n.fn[t + b] = n.fn[t];
n.fn[t] = function()
{
return i.apply(this,arguments) || r.apply(this,arguments)
}
}), o.version = "2.0.0pre", o.nextid = 0, o.inactiveEvents = "click dblclick mousedown mouseup mousemove mouseleave mouseenter".split(" "), o.zindex = 15e3, o.defaults = {
prerender: r,
id: r,
overwrite: u,
suppress: u,
content: {
text: u,
attr: "title",
title: {
text: r,
button: r
}
},
position: {
my: "top left",
at: "bottom right",
target: r,
container: r,
viewport: r,
adjust: {
x: 0,
y: 0,
mouse: u,
resize: u,
method: "flip flip"
},
effect: function(t, i)
{
n(this).animate(i,{
duration: 200,
queue: r
})
}
},
show: {
target: r,
event: "mouseenter",
effect: u,
delay: 90,
solo: r,
ready: r,
autofocus: r
},
hide: {
target: r,
event: "mouseleave",
effect: u,
delay: 0,
fixed: r,
inactive: r,
leave: "window",
distance: r
},
style: {
classes: "",
widget: r,
width: r,
height: r,
"default": u
},
events: {
render: e,
move: e,
show: e,
hide: e,
toggle: e,
visible: e,
focus: e,
blur: e
}
}, f.ajax = function(n)
{
var t=n.plugins.ajax;
return"object" == typeof t ? t : n.plugins.ajax = new et(n)
}, f.ajax.initialize = "render", f.ajax.sanitize = function(n)
{
var i=n.content,
t;
i && "ajax" in i && (t = i.ajax, typeof t != "object" && (t = n.content.ajax = {url: t}), "boolean" != typeof t.once && t.once && (t.once = !!t.once))
}, n.extend(u,o.defaults,{content: {ajax: {
loading: u,
once: u
}}}), f.bgiframe = function(t)
{
var u=n.browser,
i=t.plugins.bgiframe;
return n("select, object").length < 1 || !(u.msie && ("" + u.version).charAt(0) === "6") ? r : "object" == typeof i ? i : t.plugins.bgiframe = new tt(t)
}, f.bgiframe.initialize = "render", f.imagemap = function(t, i, r)
{
function l(n, t, i)
{
var o=0,
u=1,
r=1,
s=0,
h=0,
f=n.width,
e=n.height;
while(f > 0 && e > 0 && u > 0 && r > 0)
{
f = Math.floor(f / 2), e = Math.floor(e / 2), i.x === "left" ? u = f : i.x === "right" ? u = n.width - f : u += Math.floor(f / 2), i.y === "top" ? r = e : i.y === "bottom" ? r = n.height - e : r += Math.floor(e / 2), o = t.length;
while(o--)
{
if(t.length < 2)
break;
s = t[o][0] - n.offset.left, h = t[o][1] - n.offset.top, (i.x === "left" && s >= u || i.x === "right" && s <= u || i.x === "center" && (s < u || s > n.width - u) || i.y === "top" && h >= r || i.y === "bottom" && h <= r || i.y === "center" && (h < r || h > n.height - r)) && t.splice(o,1)
}
}
return{
left: t[0][0],
top: t[0][1]
}
}
t.jquery || (t = n(t));
var a=(t[0].shape || t.attr("shape")).toLowerCase(),
h=(t[0].coords || t.attr("coords")).split(","),
f=[],
o=n('img[usemap="#' + t.parent("map").attr("name") + '"]'),
c=o.offset(),
u={
width: 0,
height: 0,
offset: {
top: 1e10,
right: 0,
bottom: 0,
left: 1e10
}
},
s=0,
e=0,
v;
c.left += Math.ceil((o.outerWidth() - o.width()) / 2), c.top += Math.ceil((o.outerHeight() - o.height()) / 2);
if(a === "poly")
{
s = h.length;
while(s--)
e = [parseInt(h[--s],10),parseInt(h[s + 1],10)], e[0] > u.offset.right && (u.offset.right = e[0]), e[0] < u.offset.left && (u.offset.left = e[0]), e[1] > u.offset.bottom && (u.offset.bottom = e[1]), e[1] < u.offset.top && (u.offset.top = e[1]), f.push(e)
}
else
f = n.map(h,function(n)
{
return parseInt(n,10)
});
switch(a)
{
case"rect":
u = {
width: Math.abs(f[2] - f[0]),
height: Math.abs(f[3] - f[1]),
offset: {
left: Math.min(f[0],f[2]),
top: Math.min(f[1],f[3])
}
};
break;
case"circle":
u = {
width: f[2] + 2,
height: f[2] + 2,
offset: {
left: f[0],
top: f[1]
}
};
break;
case"poly":
n.extend(u,{
width: Math.abs(u.offset.right - u.offset.left),
height: Math.abs(u.offset.bottom - u.offset.top)
}), i.string() === "centercenter" ? u.offset = {
left: u.offset.left + u.width / 2,
top: u.offset.top + u.height / 2
} : (u.offset = l(u,f.slice(),i), r && (r[0] === "flip" || r[1] === "flip") && (u.flipoffset = l(u,f.slice(),{
x: i.x === "left" ? "right" : i.x === "right" ? "left" : "center",
y: i.y === "top" ? "bottom" : i.y === "bottom" ? "top" : "center"
}), u.flipoffset.left -= u.offset.left, u.flipoffset.top -= u.offset.top)), u.width = u.height = 0
}
return u.offset.left += c.left, u.offset.top += c.top, u
}, f.modal = function(n)
{
var t=n.plugins.modal;
return"object" == typeof t ? t : n.plugins.modal = new ut(n)
}, f.modal.initialize = "render", f.modal.sanitize = function(n)
{
n.show && (typeof n.show.modal != "object" ? n.show.modal = {on: !!n.show.modal} : typeof n.show.modal.on == "undefined" && (n.show.modal.on = u))
}, f.modal.zindex = o.zindex + 1e3, n.extend(u,o.defaults,{show: {modal: {
on: r,
effect: u,
blur: u,
escape: u
}}}), f.svg = function(t)
{
var c=n(document),
e=t[0],
r={
width: 0,
height: 0,
offset: {
top: 1e10,
left: 1e10
}
},
o,
s,
h,
u,
f;
if(e.getBBox && e.parentNode)
{
o = e.getBBox(), s = e.getScreenCTM(), h = e.farthestViewportElement || e;
if(!h.createSVGPoint)
return r;
u = h.createSVGPoint(), u.x = o.x, u.y = o.y, f = u.matrixTransform(s), r.offset.left = f.x, r.offset.top = f.y, u.x += o.width, u.y += o.height, f = u.matrixTransform(s), r.width = f.x - r.offset.left, r.height = f.y - r.offset.top, r.offset.left += c.scrollLeft(), r.offset.top += c.scrollTop()
}
return r
}, f.tip = function(n)
{
var t=n.plugins.tip;
return"object" == typeof t ? t : n.plugins.tip = new it(n)
}, f.tip.initialize = "render", f.tip.sanitize = function(n)
{
var i=n.style,
t;
i && "tip" in i && (t = n.style.tip, typeof t != "object" && (n.style.tip = {corner: t}), /string|boolean/i.test(typeof t.corner) || (t.corner = u), typeof t.width != "number" && delete t.width, typeof t.height != "number" && delete t.height, typeof t.border != "number" && t.border !== u && delete t.border, typeof t.offset != "number" && delete t.offset)
}, n.extend(u,o.defaults,{style: {tip: {
corner: u,
mimic: r,
width: 6,
height: 6,
border: u,
offset: 0
}}})
}(jQuery,window), function()
{
function t(n, t)
{
if(t)
for(var i in t)
t.hasOwnProperty(i) && (n[i] = t[i]);
return n
}
function h(n, t)
{
var r=[],
i;
for(i in n)
n.hasOwnProperty(i) && (r[i] = t(n[i]));
return r
}
function e(r, e, o)
{
if(n.isSupported(e.version))
r.innerHTML = n.getHTML(e,o);
else if(e.expressInstall && n.isSupported([6,65]))
r.innerHTML = n.getHTML(t(e,{src: e.expressInstall}),{
MMredirectURL: location.href,
MMplayerType: "PlugIn",
MMdoctitle: document.title
});
else
{
r.innerHTML.replace(/\s/g,"") || (r.innerHTML = "<h2>Flash version " + e.version + " or greater is required</h2><h3>" + (i[0] > 0 ? "Your version is " + i : "You have no flash plugin installed") + "</h3>" + (r.tagName == "A" ? "<p>Click here to download latest version</p>" : "<p>Download latest version from <a href='" + f + "'>here</a></p>"), r.tagName == "A" && (r.onclick = function()
{
location.href = f
}));
if(e.onFail)
{
var s=e.onFail.call(this);
typeof s == "string" && (r.innerHTML = s)
}
}
u && (window[e.id] = document.getElementById(e.id)), t(this,{
getRoot: function()
{
return r
},
getOptions: function()
{
return e
},
getConf: function()
{
return o
},
getApi: function()
{
return r.firstChild
}
})
}
var u=document.all,
f="http://www.adobe.com/go/getflashplayer",
s=typeof jQuery == "function",
o=/(\d+)[^\d]+(\d+)[^\d]*(\d*)/,
r={
width: "100%",
height: "100%",
id: "_" + ("" + Math.random()).slice(9),
allowfullscreen: !0,
allowscriptaccess: "always",
quality: "high",
version: [3,0],
onFail: null,
expressInstall: null,
w3c: !1,
cachebusting: !1
},
n,
i;
window.attachEvent && window.attachEvent("onbeforeunload",function()
{
__flash_unloadHandler = function(){}, __flash_savedUnloadHandler = function(){}
}), window.flashembed = function(n, i, u)
{
return typeof n == "string" && (n = document.getElementById(n.replace("#",""))), n ? (typeof i == "string" && (i = {src: i}), new e(n,t(t({},r),i),u)) : void 0
}, n = t(window.flashembed,{
conf: r,
getVersion: function()
{
var t,
n;
try
{
n = navigator.plugins["Shockwave Flash"].description.slice(16)
}
catch(u)
{
try
{
t = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"), n = t && t.GetVariable("$version")
}
catch(r)
{
try
{
t = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"), n = t && t.GetVariable("$version")
}
catch(i){}
}
}
return n = o.exec(n), n ? [n[1],n[3]] : [0,0]
},
asString: function(t)
{
var r,
u,
i;
if(t === null || t === undefined)
return null;
r = typeof t, r == "object" && t.push && (r = "array");
switch(r)
{
case"string":
return t = t.replace(new RegExp('(["\\\\])',"g"),"\\$1"), t = t.replace(/^\s?(\d+\.?\d+)%/,"$1pct"), '"' + t + '"';
case"array":
return"[" + h(t,function(t)
{
return n.asString(t)
}).join(",") + "]";
case"function":
return'"function()"';
case"object":
u = [];
for(i in t)
t.hasOwnProperty(i) && u.push('"' + i + '":' + n.asString(t[i]));
return"{" + u.join(",") + "}"
}
return String(t).replace(/\s/g," ").replace(/\'/g,'"')
},
getHTML: function(i, r)
{
var f,
h,
e,
s,
o;
i = t({},i), f = '<object width="' + i.width + '" height="' + i.height + '" id="' + i.id + '" name="' + i.id + '"', i.cachebusting && (i.src += (i.src.indexOf("?") != -1 ? "&" : "?") + Math.random()), f += i.w3c || !u ? ' data="' + i.src + '" type="application/x-shockwave-flash"' : ' classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"', f += ">", (i.w3c || u) && (f += '<param name="movie" value="' + i.src + '" />'), i.width = i.height = i.id = i.w3c = i.src = null, i.onFail = i.version = i.expressInstall = null;
for(h in i)
i[h] && (f += '<param name="' + h + '" value="' + i[h] + '" />');
e = "";
if(r)
{
for(s in r)
r[s] && (o = r[s], e += s + "=" + (/function|object/.test(typeof o) ? n.asString(o) : o) + "&");
e = e.slice(0,-1), f += '<param name="flashvars" value=\'' + e + "' />"
}
return f += "</object>"
},
isSupported: function(n)
{
return i[0] > n[0] || i[0] == n[0] && i[1] >= n[1]
}
}), i = n.getVersion(), s && (jQuery.tools = jQuery.tools || {version: "1.2.5"}, jQuery.tools.flashembed = {conf: r}, jQuery.fn.flashembed = function(n, t)
{
return this.each(function()
{
$(this).data("flashembed",flashembed(this,n,t))
})
})
}(), function(n)
{
function t(t, i)
{
function c(n)
{
var r=n.siblings(".content"),
f;
s || r.is(":visible") || (s = !0, u = r, o = t.find("div > .content:visible"), f = {opacity: "show"}, f[i.vertical ? "height" : "width"] = "show", r.animate(f,{
step: function(n, t)
{
o.css(t.prop,t.end - n + t.unit)
},
complete: function()
{
o.css({
display: "",
width: "",
opacity: ""
}), s = !1
},
duration: 600
}), r.closest(".set").nextAll(".set").addClass("invert").end().prevAll(".set").andSelf().removeClass("invert"))
}
function l()
{
var n=i.reverse ? u.closest(".set").prev(".set") : u.closest(".set").next(".set");
n.length == 0 && (n = i.reverse ? r.last() : r.first()), c(n.children(".title"))
}
function h()
{
e(), f = window.setInterval(l,i.autoDelay * 1e3)
}
function e()
{
f && (window.clearInterval(f), f = 0)
}
var r=t.children(".set"),
f=0,
s=!1,
u,
o;
t.addClass("accordionWrapper").css({
overflow: "hidden",
width: "100%"
}).find("div > .title").bind(i.openEvent,function(t)
{
return e(), c(n(t.target)), !1
}), r.children(".content").css("overflow","hidden").children(".wrapper").each(function()
{
var t=n(this);
t.width(t.parent().width())
}), i.vertical && r.css({
display: "block",
float: "none",
clear: "both"
}).children(".title").css({
display: "block",
float: "none",
clear: "both"
}).end().children(".content").css({clear: "both"}), u = r.find(".content").eq(i.startIndex).show(), i.autoDelay > 0 && (r.mouseenter(e).mouseleave(h), h())
}
n.fn.vkkAccordion = function(i)
{
var r=n.extend({
vertical: !1,
startIndex: 0,
autoDelay: 0,
openEvent: "click",
reverse: !1
},i);
return this.each(function()
{
t(n(this),r)
})
}
}(jQuery), JSON || (JSON = {}), function()
{
"use strict";
function i(n)
{
return n < 10 ? "0" + n : n
}
function f(n)
{
return o.lastIndex = 0, o.test(n) ? '"' + n.replace(o,function(n)
{
var t=s[n];
return typeof t == "string" ? t : "\\u" + ("0000" + n.charCodeAt(0).toString(16)).slice(-4)
}) + '"' : '"' + n + '"'
}
function r(i, e)
{
var h,
l,
c,
a,
v=n,
s,
o=e[i];
o && typeof o == "object" && typeof o.toJSON == "function" && (o = o.toJSON(i)), typeof t == "function" && (o = t.call(e,i,o));
switch(typeof o)
{
case"string":
return f(o);
case"number":
return isFinite(o) ? String(o) : "null";
case"boolean":
case"null":
return String(o);
case"object":
if(!o)
return"null";
n += u, s = [];
if(Object.prototype.toString.apply(o) === "[object Array]")
{
for(a = o.length, h = 0; h < a; h += 1)
s[h] = r(h,o) || "null";
return c = s.length === 0 ? "[]" : n ? "[\n" + n + s.join(",\n" + n) + "\n" + v + "]" : "[" + s.join(",") + "]", n = v, c
}
if(t && typeof t == "object")
for(a = t.length, h = 0; h < a; h += 1)
typeof t[h] == "string" && (l = t[h], c = r(l,o), c && s.push(f(l) + (n ? ": " : ":") + c));
else
for(l in o)
Object.prototype.hasOwnProperty.call(o,l) && (c = r(l,o), c && s.push(f(l) + (n ? ": " : ":") + c));
return c = s.length === 0 ? "{}" : n ? "{\n" + n + s.join(",\n" + n) + "\n" + v + "}" : "{" + s.join(",") + "}", n = v, c
}
}
typeof Date.prototype.toJSON != "function" && (Date.prototype.toJSON = function()
{
return isFinite(this.valueOf()) ? this.getUTCFullYear() + "-" + i(this.getUTCMonth() + 1) + "-" + i(this.getUTCDate()) + "T" + i(this.getUTCHours()) + ":" + i(this.getUTCMinutes()) + ":" + i(this.getUTCSeconds()) + "Z" : null
}, String.prototype.toJSON = Number.prototype.toJSON = Boolean.prototype.toJSON = function()
{
return this.valueOf()
});
var e=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,
o=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,
n,
u,
s={
"\b": "\\b",
"\t": "\\t",
"\n": "\\n",
"\f": "\\f",
"\r": "\\r",
'"': '\\"',
"\\": "\\\\"
},
t;
typeof JSON.stringify != "function" && (JSON.stringify = function(i, f, e)
{
var o;
n = "", u = "";
if(typeof e == "number")
for(o = 0; o < e; o += 1)
u += " ";
else
typeof e == "string" && (u = e);
t = f;
if(f && typeof f != "function" && (typeof f != "object" || typeof f.length != "number"))
throw new Error("JSON.stringify");
return r("",{"": i})
}), typeof JSON.parse != "function" && (JSON.parse = function(n, t)
{
function r(n, i)
{
var f,
e,
u=n[i];
if(u && typeof u == "object")
for(f in u)
Object.prototype.hasOwnProperty.call(u,f) && (e = r(u,f), e !== undefined ? u[f] = e : delete u[f]);
return t.call(n,i,u)
}
var i;
n = String(n), e.lastIndex = 0, e.test(n) && (n = n.replace(e,function(n)
{
return"\\u" + ("0000" + n.charCodeAt(0).toString(16)).slice(-4)
}));
if(/^[\],:{}\s]*$/.test(n.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))
return i = eval("(" + n + ")"), typeof t == "function" ? r({"": i},"") : i;
throw new SyntaxError("JSON.parse");
})
}(), function(n, t, i)
{
function nt(n)
{
return!n || n == "loaded" || n == "complete"
}
function r()
{
var t=1,
n=-1;
while(e.length - ++n)
if(e[n].s && !(t = e[n].r))
break;
t && d()
}
function lt(n)
{
var i=t.createElement("script"),
e;
i.src = n.s, i.onreadystatechange = i.onload = function()
{
!e && nt(i.readyState) && (e = 1, r(), i.onload = i.onreadystatechange = null)
}, f(function()
{
e || (e = 1, r())
},u.errorTimeout), n.e ? i.onload() : o.parentNode.insertBefore(i,o)
}
function st(n)
{
var e=t.createElement("link"),
i,
s;
e.href = n.s, e.rel = "stylesheet", e.type = "text/css", !n.e && (k || c) ? (s = function(n)
{
f(function()
{
if(!i)
try
{
n.sheet.cssRules.length ? (i = 1, r()) : s(n)
}
catch(t)
{
t.code == 1e3 || t.message == "security" || t.message == "denied" ? (i = 1, f(function()
{
r()
},0)) : s(n)
}
},0)
}, s(e)) : (e.onload = function()
{
i || (i = 1, f(function()
{
r()
},0))
}, n.e && e.onload()), f(function()
{
i || (i = 1, r())
},u.errorTimeout), !n.e && o.parentNode.insertBefore(e,o)
}
function d()
{
var n=e.shift();
l = 1, n ? n.t ? f(function()
{
n.t == "c" ? st(n) : lt(n)
},0) : (n(), r()) : l = 0
}
function et(n, i, s, h, c, v)
{
function k()
{
!b && nt(y.readyState) && (p.r = b = 1, !l && r(), y.onload = y.onreadystatechange = null, f(function()
{
w.removeChild(y)
},0))
}
var y=t.createElement(n),
b=0,
p={
t: s,
s: i,
e: v
};
y.src = y.data = i, !a && (y.style.display = "none"), y.width = y.height = "0", n != "object" && (y.type = s), y.onload = y.onreadystatechange = k, n == "img" ? y.onerror = k : n == "script" && (y.onerror = function()
{
p.e = p.r = 1, d()
}), e.splice(h,0,p), w.insertBefore(y,a ? null : o), f(function()
{
b || (w.removeChild(y), p.r = p.e = b = 1, r())
},u.errorTimeout)
}
function ot(n, t, i)
{
var r=t == "c" ? ht : rt;
return l = 0, t = t || "j", s(n) ? et(r,n,t,this.i++,h,i) : (e.splice(this.i++,0,n), e.length == 1 && d()), this
}
function g()
{
var n=u;
return n.loader = {
load: ot,
i: 0
}, n
}
var h=t.documentElement,
f=n.setTimeout,
o=t.getElementsByTagName("script")[0],
p={}.toString,
e=[],
l=0,
c="MozAppearance" in h.style,
a=c && !!t.createRange().compareNode,
at=c && !a,
w=a ? h : o.parentNode,
ft=n.opera && p.call(n.opera) == "[object Opera]",
k="webkitAppearance" in h.style,
ct=k && "async" in t.createElement("script"),
rt=c ? "object" : ft || ct ? "img" : "script",
ht=k ? "img" : rt,
ut=Array.isArray || function(n)
{
return p.call(n) == "[object Array]"
},
v=function(n)
{
return Object(n) === n
},
s=function(n)
{
return typeof n == "string"
},
y=function(n)
{
return p.call(n) == "[object Function]"
},
b=[],
it={},
tt,
u;
u = function(n)
{
function h(n)
{
for(var r=n.split("!"), e=b.length, f=r.pop(), o=r.length, i={
url: f,
origUrl: f,
prefixes: r
}, u, t=0; t < o; t++)
u = it[r[t]], u && (i = u(i));
for(t = 0; t < e; t++)
i = b[t](i);
return i
}
function r(n, t, r, u, f)
{
var e=h(n),
o=e.autoCallback;
if(e.bypass)
return;
t && (t = y(t) ? t : t[n] || t[u] || t[n.split("/").pop().split("?")[0]]);
if(e.instead)
return e.instead(n,t,r,u,f);
r.load(e.url,e.forceCSS || !e.forceJS && /css$/.test(e.url) ? "c" : i,e.noexec), (y(t) || y(o)) && r.load(function()
{
g(), t && t(e.origUrl,f,u), o && o(e.origUrl,f,u)
})
}
function o(n, t)
{
function e(n)
{
if(s(n))
r(n,f,t,0,u);
else if(v(n))
for(i in n)
n.hasOwnProperty(i) && r(n[i],f,t,i,u)
}
var u=!!n.test,
o=u ? n.yep : n.nope,
h=n.load || n.both,
f=n.callback,
i;
e(o), e(h), n.complete && t.load(n.complete)
}
var e,
t,
f=this.yepnope.loader;
if(s(n))
r(n,0,f,0);
else if(ut(n))
for(e = 0; e < n.length; e++)
t = n[e], s(t) ? r(t,0,f,0) : ut(t) ? u(t) : v(t) && o(t,f);
else
v(n) && o(n,f)
}, u.addPrefix = function(n, t)
{
it[n] = t
}, u.addFilter = function(n)
{
b.push(n)
}, u.errorTimeout = 1e4, t.readyState == null && t.addEventListener && (t.readyState = "loading", t.addEventListener("DOMContentLoaded",tt = function()
{
t.removeEventListener("DOMContentLoaded",tt,0), t.readyState = "complete"
},0)), n.yepnope = g()
}(this,this.document), vkkopts = vkkopts || {}, vkk = {
lastSubmittedForm: [],
ajaxUpdateTarget: [],
bodyJS: function()
{
try
{
$("body").removeClass("noscript")
}
catch(n)
{
typeof $ == "function" && $(vkk.bodyJS)
}
},
ready: function(n)
{
window.parent == window ? setTimeout(n,0) : $(window).load(function()
{
setTimeout(n,0)
})
},
bindControls: function(n)
{
$.publish("bindControls",[n]), vkk.reverseList($(".inline-tab-navigation ul.menu",n)), vkk.bindTabs(n), vkk.bindPopups(n), vkk.bindEventTracking(n), $.validator.unobtrusive.parse(n)
},
setupSearch: function(n)
{
function t()
{
window.location.href = n + "?query=" + encodeURIComponent($("#amf-search-input").val())
}
$(function()
{
$("#amf-search-input").keypress(function(n)
{
n.which == 13 && t()
}), $("#amf-search-btn").click(function()
{
return t(), !1
})
})
},
getCookieKey: function()
{
var n=window.location.href;
return n = n.substr(n.lastIndexOf("/")), n.indexOf("#") != -1 && (n = n.substr(0,n.indexOf("#"))), "state" + n
},
clearStateCookies: function()
{
var n=document.cookie + ";";
$.each(n.split(";"),function(n, t)
{
t = $.trim(t);
if(t.indexOf("state") > -1)
{
var i=decodeURIComponent(t.substr(0,t.indexOf("=")));
$.cookie(i,null,{path: "/"})
}
})
},
setPageCookie: function(n, t)
{
var f=vkk.getCookieKey(),
u=$.cookie(f),
i,
r;
u || (u = "{}"), i = $.parseJSON(u), i[n] = t, t ? i[n] = t : delete i[n], r = JSON.stringify(i), r == "{}" && (r = null), $.cookie(f,r)
},
getPageCookie: function(n)
{
var i=vkk.getCookieKey(),
r=$.cookie(i),
t=$.parseJSON(r);
return t ? t[n] : null
},
selectTab: function(n, t, i)
{
var u=$(n).closest("li"),
s=u.data("pageid"),
o=$(u).closest("ul"),
f=$(".tab-content",o.closest(t)),
r,
e;
return typeof s != undefined ? (r = ".page-" + u.data("pageid"), u.addClass("active").siblings().removeClass("active"), e = f.filter(r).show(), f.not(r).hide(), e.data().active != 1 && ($.publish("activateTab",[f.filter(r)]), e.data().active = 1), i && o.closest(t).scrollTo(350), !1) : !0
},
bindTabs: function(n)
{
function t(t)
{
$(t + " .menu",n).not(".custom").each(function()
{
var n=$(this),
u=$(".tab-content",n.closest(t)),
f,
r,
s,
o,
e;
$("li.active",n).length == 0 && ($("li:first",n).addClass("active"), u.hide().first().show()), u.css("min-height",u.first().height() + "px"), f = n.hasClass("saveState"), r = i(n), $("li a",n).click(function()
{
var n=$(this).closest("li").attr("data-pageId");
return f && vkk.setPageCookie(r,n), vkk.selectTab(this,t,!0), !1
}), s = vkk.getPageCookie(r), f && s != null && (o = $('[data-pageId="' + vkk.getPageCookie(r) + '"]'), e = $("a",o), vkk.selectTab(e,t))
})
}
function i(n)
{
var t="";
return $("li",n).each(function()
{
t += $(this).data("pageid")
}), t
}
t(".inline-tab-navigation"), t(".object-inline-tab-navigation-large")
},
ajaxSubmit: function()
{
var t=$(this);
if(t.data().validator.errorList.length > 0)
return;
vkk.lastSubmittedForm = t, vkk.ajaxUpdateTarget = $(t.data("ajax-update")), typeof $.fn.block != "undefined" && (vkk.ajaxUpdateTarget.data("block",1), setTimeout(function()
{
vkk.ajaxUpdateTarget.data("block") == 1 && (vkk.ajaxUpdateTarget.data("block",0), vkk.ajaxUpdateTarget.block({
message: '<img src="/Content/Images/Shared/ajax-loader.gif" />',
css: {
"margin-top": "-5%",
border: "0",
backgroundColor: "transparent"
},
overlayCSS: {backgroundColor: "#ffffff"}
}), $("input").blur())
},100))
},
ajaxBeforeSend: function(){},
ajaxComplete: function()
{
vkk.ajaxUpdateTarget.parent(".object.inline-tab-navigation").size() > 0 ? vkk.reverseList($("ul.menu",vkk.ajaxUpdateTarget)) : vkk.reverseList($(".inline-tab-navigation ul.menu",vkk.ajaxUpdateTarget)), vkk.bindControls(vkk.ajaxUpdateTarget), setTimeout(function()
{
$(".input-validation-error",vkk.ajaxUpdateTarget).first().focus()
},10), typeof $.fn.unblock != "undefined" && (vkk.ajaxUpdateTarget.data("block",0), vkk.ajaxUpdateTarget.unblock()), vkk.ajaxUpdateTarget.data().updateCount = typeof vkk.ajaxUpdateTarget.data().updateCount == "undefined" ? 1 : vkk.ajaxUpdateTarget.data().updateCount + 1
},
ajaxError: function()
{
var r=$("div[class*=validation-summary]",vkk.lastSubmittedForm),
u=$('<div class="validation-summary-errors ajax-error"><span>Tekniskt fel</span><ul><li>Någonting gick fel, var god försök senare.</li></ul></div>');
$(".ajax-error",r.parent()).remove(), r.parent().prepend(u), typeof $.fn.unblock != "undefined" && (vkk.ajaxUpdateTarget.data("block",0), vkk.ajaxUpdateTarget.unblock())
},
postJsonWithVerificationToken: function(n)
{
var i=$('input[name=""__RequestVerificationToken""]').val(),
t={};
t.__RequestVerificationToken = i, $.ajax({
cache: !1,
dataType: "json",
type: "POST",
headers: t,
data: n.jsonData,
contentType: "application/json; charset=utf-8",
url: n.url,
success: n.onSuccess,
error: n.onError
})
},
formKeyDown: function(n)
{
n.keyCode != 13 || typeof $.browser.msie != "undefined" && $.browser.version.split(".")[0] < 9 || $(this).submit()
},
reverseList: function(n)
{
var i=n.children("li"),
t=i.size();
$.each(i,function(n, i)
{
$item = $(i), $item.css("z-index",$item.hasClass("active") ? t + 1 : t - n), $item.css("position","relative")
})
},
infoPopup: function(n, t)
{
new Boxy(n,{
closeable: !0,
closeText: "Stäng",
draggable: !0,
fixed: !1,
modal: !1,
title: t
}).resize(700).show()
},
bindPopups: function(n)
{
$("a.popup",n).each(function()
{
var i=$(this).data("content"),
t=$(i,n);
$(this).removeClass("popup").click(function()
{
return vkk.infoPopup(t,t.attr("title")), !1
})
})
},
windowPopup: function(n, t, i)
{
var u=645,
f=i > 0 ? i : screen.height,
r=window.open(n,t,"width=" + u + ", height=" + f + ",resizable=yes,scrollbars=yes,menubar=no,toolbar=no,directories=no,location=no,status=no");
return r.focus(), r
},
modalWindow: function(n)
{
var i={
closeable: !0,
closeText: "Stäng",
draggable: !1,
fixed: !1,
modal: !0,
title: " ",
unloadOnHide: !0,
afterShow: function()
{
var t=this,
i=!1;
n.width && n.width > 0 && (t.boxy.width(n.width), i = !0), n.resize && (t.resize(n.resize[0],n.resize[1]), i = !0), i && t.center(), n.timer = setInterval(function()
{
var n=$(window).scrollTop() + $(window).height() / 2 - t.boxy.height() / 2;
t.boxy.css("top") != n + "px" && t.boxy.clearQueue().stop().animate({top: Math.max(n,0)},200)
},200)
},
beforeHide: function()
{
clearInterval(n.timer)
}
},
t;
n.iframe ? (t = '<iframe src="' + n.url + '" frameborder="0" style="border:none;margin:0;padding:inherit 0;width:100%;" scrolling="auto"></iframe>', n.boxy = new Boxy(t,i)) : n.boxy = Boxy.load(n.url,i)
},
isModalVisible: function()
{
return Boxy.isModalVisible()
},
nki: function()
{
function r(n)
{
$.cookie(e,n,{
expires: 30,
path: "/",
domain: document.location.host
})
}
function u()
{
if(vkk.isModalVisible())
return;
r(0), vkk.modalWindow({
url: "https://www.surveymonkey.com/s/RLJX9JC",
iframe: !0,
resize: [500,Math.min(Math.max($(window).height() - 100,500),600)]
})
}
if(document.location.host.indexOf("www") < 0)
return;
var i=60,
f=+new Date,
e="VkkNKI",
o=$.cookie(e),
n,
t;
if(!o)
{
r(f), setTimeout(u,i * 1e3);
return
}
n = parseInt(o,10);
if(!n || document.location.protocol != "http:")
return;
t = Math.floor((f - n) / 1e3), setTimeout(u,t >= i ? 100 : (i - t) * 1e3)
},
setEqualObjectHeight: function(n)
{
var i=$(n).select(function(n)
{
if($(n).hasClass("slideshow"))
{
var t=$(n).find(".slide .object").select(function(n)
{
return $(n).outerHeight()
});
return Math.max.apply(Math,t)
}
return $(n).outerHeight()
}),
t=Math.max.apply(Math,i);
$(n).each(function()
{
var n=t - ($(this).outerHeight(!0) - $(this).height());
$(this).css("min-height",n), $(this).hasClass("slideshow") && $(this).find(".slide .object").each(function()
{
var n=t - ($(this).outerHeight(!0) - $(this).height());
$(this).css("height",n)
})
})
},
startSlideshow: function(n, t, i, r)
{
typeof t == "undefined" && (t = 3e3), typeof i == "undefined" && (i = 1e3), $(n).each(function()
{
var u=$(this).find(".slide .object"),
f=u.select(function(n)
{
return $(n).outerHeight()
}),
n=Math.max.apply(Math,f);
u.each(function()
{
$(this).css("min-height",n - ($(this).outerHeight(!1) - $(this).height()))
}), $(this).cycle({
fit: 1,
fx: "fade",
speed: i,
timeout: t,
pager: $(".nav-content",$(this).parent()),
pagerEvent: "mouseover",
pause: 1,
pauseOnPagerHover: 1,
pagerAnchorBuilder: function(n)
{
return'<a href="#" class="page' + (n + 1) + '">' + (n + 1) + "</a>"
},
slideExpr: $(".slide",$(this).parent()),
width: r
}), $(this).css("min-height",n - ($(this).outerHeight(!1) - $(this).height()))
})
},
googleAnalytics: function(n)
{
var u=window.location.pathname.replace(/RequestId=[\w\d]+/g,"").replace(/\?&+/,"?").replace(/\?$/,""),
r,
t,
i;
window._gaq = window._gaq || [], window._gaq.push(["_setAccount",n]), window._gaq.push(["_trackPageview",u]), window.addthis_config = window.addthis_config || {}, window.addthis_config.data_ga_property = n, typeof $.address != "undefined" && (r = "/", $.address.tracker(null).change(function(n)
{
if(n.value != r)
{
for(var t=0; t < window._gaq.length; t++)
window._gaq[t][0] == "_trackPageview" && window._gaq.splice(t,1);
window._gaq.push(["_trackPageview",u + "#" + n.value]), r = n.value
}
})), t = document.createElement("script"), t.type = "text/javascript", t.async = !0, t.src = ("https:" == document.location.protocol ? "https://ssl" : "http://www") + ".google-analytics.com/ga.js", i = document.getElementsByTagName("script")[0], i.parentNode.insertBefore(t,i)
},
bindEventTracking: function(n)
{
var t=function(n, t)
{
var r=n.attr("target"),
i=n.attr("href");
r != "_blank" && i.indexOf("#") != 0 && i.indexOf("java") != 0 && (t.preventDefault(), setTimeout(function()
{
document.location = i
},200))
},
r=function(n)
{
var i=n.attr("target"),
t=n.attr("href").replace(/^https?:\/\//,"/exit/").replace(new RegExp("^/exit/" + document.location.hostname),"");
window._gaq = window._gaq || [], _gaq.push(["_trackPageview",t])
},
i=function(n)
{
var t=n.metadata();
typeof t.cat != "undefined" && typeof t.act != "undefined" && vkk.trackEvent(t.cat,t.act,t.lbl,t.val)
};
$("a.track-url",n).mouseup(function()
{
r($(this))
}).click(function(n)
{
t($(this),n)
}), $("a.track-event",n).mouseup(function()
{
i($(this))
}).click(function(n)
{
t($(this),n)
})
},
trackEvent: function(n, t, i, r)
{
typeof i == "undefined" && (i = window.location.pathname), window._gaq = window._gaq || [], _gaq.push(["_trackEvent",n,t,i,r])
},
disqusCommentCount: function()
{
if(typeof disqus_shortname != "undefined")
{
var n=document.createElement("script");
n.type = "text/javascript", n.async = !0, n.src = "http://" + disqus_shortname + ".disqus.com/count.js", (document.getElementsByTagName("head")[0] || document.getElementsByTagName("body")[0]).appendChild(n)
}
},
disqusComments: function()
{
if(typeof disqus_shortname != "undefined")
{
var n=document.createElement("script");
n.type = "text/javascript", n.async = !0, n.src = "http://" + disqus_shortname + ".disqus.com/embed.js", (document.getElementsByTagName("head")[0] || document.getElementsByTagName("body")[0]).appendChild(n), $("#disqus_thread").css("min-height","400px"), $("#disqus-comments").show().scrollTo(350)
}
}
}, $.fn.select = function(n)
{
var t=[];
return $(this).each(function()
{
t.push(n(this))
}), t
}, $.fn.arrAttr = function(n)
{
return $(this).select(function(t)
{
return $(t).attr(n)
})
}, $.fn.scrollTo = function(n)
{
var r=$(this).height(),
t=$(this).offset().top,
i;
r > $(window).height() ? t > $(window).scrollTop() && $("html, body").animate({scrollTop: t},n) : (i = t + r / 2 - $(window).height() / 2, t + r > $(window).scrollTop() + $(window).height() ? $("html, body").animate({scrollTop: i},n) : t < $(window).scrollTop() && $("html, body").animate({scrollTop: i},n))
}, dictionary = {
enabled: !0,
setup: function()
{
$.cookie("dictionary") != null ? dictionary.toggle($.cookie("dictionary") == 1 ? !0 : !1) : dictionary.toggle(dictionary.enabled), $(".dictionary-toggle").hide()
},
toggle: function(n)
{
dictionary.enabled = typeof n == "undefined" ? !dictionary.enabled : n, $("body").toggleClass("dictionary-enabled",dictionary.enabled), $.cookie("dictionary",dictionary.enabled ? 1 : 0,{path: "/"})
},
bindWords: function(n)
{
$("a.dictionary-word",n).each(function()
{
var i=$(this).attr("href"),
t=$(this).text(),
n=$('<span class="dictionary-word"></span>').text(t).attr("rel",i);
$(this).replaceWith(n)
});
var t=$("span.dictionary-word",n);
t.size() > 0 && ($(".dictionary-toggle").show(), t.each(function()
{
var n=$(this).attr("rel"),
t=$(this).text();
$(this).qtip({
content: {
text: "<p>Laddar..</p>",
ajax: {
url: n,
type: "GET",
data: {},
success: function(n)
{
this.set("content.text",n)
}
}
},
hide: {
when: "mouseout",
delay: 120,
fixed: !0
},
events: {show: function()
{
return dictionary.enabled
}},
position: {
my: "top left",
at: "bottom center"
}
})
}))
}
}, $(function()
{
dictionary.setup()
}), $.subscribe("bindControls",function(n)
{
dictionary.bindWords(n)
}), $.fn.hintLabels = function()
{
return $(this).each(function()
{
function r(n)
{
var i=n.closest("form"),
t=$("input#" + n.attr("for"),i);
t.each(function()
{
t.val() == n.text() && t.val(""), setTimeout(function()
{
i.data().validator.errorList.length > 0 && t.val() == "" && t.val(n.text())
},10)
})
}
var t=$(this),
i=t.closest("form"),
n=$("input#" + t.attr("for"),i);
t.hide(), n.each(function()
{
n.val() == "" && n.val(t.text()), n.focus(function()
{
n.addClass("focus"), n.val() == t.text() && n.val("")
}), n.blur(function()
{
n.removeClass("focus"), setTimeout(function()
{
n.val() == "" && n.val(t.text())
},1)
})
}), i.submit(function()
{
r(t)
}), n.keydown(function(n)
{
n.keyCode == 13 && $("label",i).each(function()
{
r($(this))
})
})
})
}, $.fn.supressHintedLabels = function()
{
return $(this).each(function()
{
var t=$(this),
i=t.parentsUntil("form").parent().eq(0),
n=$("input#" + t.attr("for"),i);
n.val() == t.text() && n.val(""), setTimeout(function()
{
n.hasClass("focus") == !1 && n.val() == "" && n.val(t.text())
},1)
})
}, tables = {
bindTableSorter: function(n)
{
if(typeof $.fn.tablesorter == "undefined")
return;
$("table.sortable",n).tablesorter({
cssAsc: "asc",
cssDesc: "desc",
cssHeader: "",
textExtraction: function(n)
{
var i=$("input[type=hidden]",$(n)),
t;
return i.size() > 0 ? (t = parseFloat(i.val().replace(",",".")), t != NaN ? (i.hasClass("reverse") && (t = -t), "" + t) : i.val()) : $.trim($(n).text())
}
})
},
bindTableSorterDropDowns: function(n, t)
{
$("table.sortable th select",n).click(function(n)
{
n.stopPropagation()
}).mousedown(function(n)
{
n.stopPropagation()
}), setTimeout(function()
{
$("table.sortable .return",n).hide(), $("table.sortable .return." + t,n).show()
},1), $("table.sortable .return select",n).change(function()
{
var i=$(this).val(),
t=$("table.sortable .return." + i,n);
$("table.sortable .return",n).hide(), t.show(), $("select",t).val(i)
})
}
}, $.subscribe("bindControls",function(n)
{
tables.bindTableSorter(n)
}), $.subscribe("bindControls",function(n)
{
$(".list-collapsable.readmore",n).each(function()
{
var t=$(this),
n=$(this).prev().find(".expandable");
n.hide(), $("li a",t).click(function()
{
return n.show(), t.hide(), !1
})
})
}), vkk.blankettbestallning = {
aktiverad: !1,
varukorg: [],
boxyInstance: null,
activate: function()
{
vkk.blankettbestallning.aktiverad = !0, $.cookie("blankettvarukorg",JSON.stringify(vkk.blankettbestallning.varukorg),{path: "/"}), vkk.blankettbestallning.updateView()
},
clear: function()
{
vkk.blankettbestallning.aktiverad = !1, vkk.blankettbestallning.varukorg = [], $.cookie("blankettvarukorg",null,{path: "/"}), vkk.blankettbestallning.updateView()
},
add: function(n)
{
if(vkk.blankettbestallning.contains(n))
return;
vkk.blankettbestallning.varukorg.push({
id: n,
count: 1
}), $.cookie("blankettvarukorg",JSON.stringify(vkk.blankettbestallning.varukorg),{path: "/"}), vkk.blankettbestallning.updateView(n)
},
remove: function(n)
{
for(var t in vkk.blankettbestallning.varukorg)
vkk.blankettbestallning.varukorg[t].id == n && vkk.blankettbestallning.varukorg.splice(t,1);
$.cookie("blankettvarukorg",JSON.stringify(vkk.blankettbestallning.varukorg),{path: "/"}), vkk.blankettbestallning.updateView(n)
},
contains: function(n)
{
for(var t in vkk.blankettbestallning.varukorg)
if(vkk.blankettbestallning.varukorg[t].id == n)
return!0;
return!1
},
showOrderForm: function(n)
{
if(vkk.blankettbestallning.varukorg.length == 0)
return;
Boxy.load(n,{
closeable: !0,
closeText: "Stäng",
draggable: !0,
fixed: !1,
modal: !0,
afterShow: function()
{
$.validator.unobtrusive.parse(this.boxy), vkk.blankettbestallning.boxyInstance = this;
var n=function()
{
vkk.blankettbestallning.boxyInstance != null && vkk.blankettbestallning.boxyInstance.moveTo(null,135)
};
$(window).resize(n), n()
},
afterHide: function()
{
boxyInstance = null
}
})
},
removeOrderFormRow: function(n, t)
{
return vkk.blankettbestallning.remove(n), t.find("input.delete-flag").val("true"), t.find("input.count").val("1"), t.hide(), vkk.blankettbestallning.varukorg.length == 0 && vkk.blankettbestallning.boxyInstance != null && vkk.blankettbestallning.boxyInstance.hide(), !1
},
updateView: function(n)
{
vkk.blankettbestallning.updatePuff(), typeof n != "undefined" ? vkk.blankettbestallning.updateDocument(n) : vkk.blankettbestallning.updateAllDocuments()
},
updatePuff: function()
{
var n=$(".object.form-order-basket.blankettbestallning");
$(".varukorg-document-count",n).text(vkk.blankettbestallning.varukorg.length), vkk.blankettbestallning.aktiverad ? ($(".object.list-collapsable.forms").addClass("active"), $(".form-inactive",n).hide(), $(".form-active",n).show(), vkk.blankettbestallning.varukorg.length == 0 ? $(".button.show-order",n).addClass("inactive") : $(".button.show-order",n).removeClass("inactive")) : ($(".object.list-collapsable.forms").removeClass("active"), $(".form-inactive",n).show(), $(".form-active",n).hide())
},
updateDocument: function(n)
{
var t=$('.object.list-collapsable.forms > ul > li > ul > li[data-document-id="' + n + '"]');
vkk.blankettbestallning.contains(n) ? (t.addClass("selected"), $(".button.standard.add",t).hide(), $(".button.standard.remove",t).show()) : (t.removeClass("selected"), $(".button.standard.add",t).css("display",""), $(".button.standard.remove",t).hide())
},
updateAllDocuments: function()
{
var t=$(".object.list-collapsable.forms > ul > li > ul > li"),
i,
r,
n;
t.removeClass("selected"), $(".button.standard.add",t).css("display",""), $(".button.standard.remove",t).hide(), i = $(".object.list-collapsable.forms > ul > li > ul");
for(r in vkk.blankettbestallning.varukorg)
n = i.find('li[data-document-id="' + vkk.blankettbestallning.varukorg[r].id + '"]'), n.addClass("selected"), $(".button.standard.add",n).hide(), $(".button.standard.remove",n).show()
}
}, $(function()
{
$.cookie("blankettvarukorg") != null && (vkk.blankettbestallning.aktiverad = !0, vkk.blankettbestallning.varukorg = JSON.parse($.cookie("blankettvarukorg"))), vkk.blankettbestallning.updateView(), $(".object.list-collapsable.forms > ul > li > ul > li.selected").parent().parent().addClass("visible")
}), $(function()
{
$(".no-js-hide,.no-js-show-block,.no-js-show-inline").removeClass("no-js-hide no-js-show-block no-js-show-inline"), vkk.reverseList($("#tab-navigation-header ul:first-child")), $.browser.msie && $("select.iedropdownfix").live("focus mouseover",function()
{
$(this).addClass("iewide").removeClass("clicked")
}).live("focus",function()
{
$(this).addClass("focus")
}).live("click",function()
{
$(this).toggleClass("clicked")
}).live("mouseout",function()
{
$(this).hasClass("focus") || $(this).hasClass("clicked") || $(this).removeClass("iewide")
}).live("blur",function()
{
$(this).removeClass("clicked iewide focus")
}), vkk.setupSearch(vkkopts.searchPage), vkk.bindControls($("body")), $("form[data-ajax=true]").live("submit",vkk.ajaxSubmit), $("form[data-ajax=true] input").live("keydown",vkk.formKeyDown), $("form[data-ajax=true] select").live("keydown",vkk.formKeyDown), vkk.ready(function()
{
$(".object.slideshow .slide").show(), vkk.setEqualObjectHeight(".column.front.row1 > .object"), vkk.setEqualObjectHeight(".column.front.row2 > .object"), vkk.startSlideshow(".object.slideshow.bildspel",6e3,"fast",null), vkk.startSlideshow(".object.slideshow.cision",1e4,1e3,220), vkk.disqusCommentCount(), vkk.nki()
})
})
