jQuery Updater - Version 1.6.1

Version Description

  • Updated jQuery to 1.6.1
Download this release

Release Info

Developer Ramoonus
Plugin Icon wp plugin jQuery Updater
Version 1.6.1
Comparing to
See all releases

Code changes from version 1.6.0.1 to 1.6.1

jquery-updater.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: jQuery updater
4
  Plugin URI: http://www.ramoonus.nl/wordpress/jquery-updater/
5
  Description: This plugin updates jQuery to the latest (stable) version.
6
- Version: 1.6.0.1
7
  Author: Ramoonus
8
  Author URI: http://www.ramoonus.nl
9
  License: GPL2
@@ -15,7 +15,7 @@ function rw_jquery_update() {
15
  if (!is_admin()) { // when not in admin screen
16
  wp_deregister_script('jquery'); // deregister
17
  // wp_register_script( $handle, $src, $deps, $ver, $in_footer );
18
- wp_register_script('jquery', plugins_url('/js/jquery-1.6.1rc1.js', __FILE__), false, '1.6');
19
  wp_enqueue_script('jquery'); // load
20
  }
21
  }
3
  Plugin Name: jQuery updater
4
  Plugin URI: http://www.ramoonus.nl/wordpress/jquery-updater/
5
  Description: This plugin updates jQuery to the latest (stable) version.
6
+ Version: 1.6.1
7
  Author: Ramoonus
8
  Author URI: http://www.ramoonus.nl
9
  License: GPL2
15
  if (!is_admin()) { // when not in admin screen
16
  wp_deregister_script('jquery'); // deregister
17
  // wp_register_script( $handle, $src, $deps, $ver, $in_footer );
18
+ wp_register_script('jquery', plugins_url('/js/jquery-1.6.1.min.js', __FILE__), false, '1.6.1');
19
  wp_enqueue_script('jquery'); // load
20
  }
21
  }
js/jquery-1.6.1.min.js ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*!
2
+ * jQuery JavaScript Library v1.6.1
3
+ * http://jquery.com/
4
+ *
5
+ * Copyright 2011, John Resig
6
+ * Dual licensed under the MIT or GPL Version 2 licenses.
7
+ * http://jquery.org/license
8
+ *
9
+ * Includes Sizzle.js
10
+ * http://sizzlejs.com/
11
+ * Copyright 2011, The Dojo Foundation
12
+ * Released under the MIT, BSD, and GPL Licenses.
13
+ *
14
+ * Date: Thu May 12 15:04:36 2011 -0400
15
+ */
16
+ (function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cv(a){if(!cj[a]){var b=f("<"+a+">").appendTo("body"),d=b.css("display");b.remove();if(d==="none"||d===""){ck||(ck=c.createElement("iframe"),ck.frameBorder=ck.width=ck.height=0),c.body.appendChild(ck);if(!cl||!ck.createElement)cl=(ck.contentWindow||ck.contentDocument).document,cl.write("<!doctype><html><body></body></html>");b=cl.createElement(a),cl.body.appendChild(b),d=f.css(b,"display"),c.body.removeChild(ck)}cj[a]=d}return cj[a]}function cu(a,b){var c={};f.each(cp.concat.apply([],cp.slice(0,b)),function(){c[this]=a});return c}function ct(){cq=b}function cs(){setTimeout(ct,0);return cq=f.now()}function ci(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ch(){try{return new a.XMLHttpRequest}catch(b){}}function cb(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g<i;g++){if(g===1)for(h in a.converters)typeof h=="string"&&(e[h.toLowerCase()]=a.converters[h]);l=k,k=d[g];if(k==="*")k=l;else if(l!=="*"&&l!==k){m=l+" "+k,n=e[m]||e["* "+k];if(!n){p=b;for(o in e){j=o.split(" ");if(j[0]===l||j[0]==="*"){p=e[j[1]+" "+k];if(p){o=e[o],o===!0?n=p:p===!0&&(n=o);break}}}}!n&&!p&&f.error("No conversion from "+m.replace(" "," to ")),n!==!0&&(c=n?n(c):p(o(c)))}}return c}function ca(a,c,d){var e=a.contents,f=a.dataTypes,g=a.responseFields,h,i,j,k;for(i in g)i in d&&(c[g[i]]=d[i]);while(f[0]==="*")f.shift(),h===b&&(h=a.mimeType||c.getResponseHeader("content-type"));if(h)for(i in e)if(e[i]&&e[i].test(h)){f.unshift(i);break}if(f[0]in d)j=f[0];else{for(i in d){if(!f[0]||a.converters[i+" "+f[0]]){j=i;break}k||(k=i)}j=j||k}if(j){j!==f[0]&&f.unshift(j);return d[j]}}function b_(a,b,c,d){if(f.isArray(b))f.each(b,function(b,e){c||bF.test(a)?d(a,e):b_(a+"["+(typeof e=="object"||f.isArray(e)?b:"")+"]",e,c,d)});else if(!c&&b!=null&&typeof b=="object")for(var e in b)b_(a+"["+e+"]",b[e],c,d);else d(a,b)}function b$(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h=a[f],i=0,j=h?h.length:0,k=a===bU,l;for(;i<j&&(k||!l);i++)l=h[i](c,d,e),typeof l=="string"&&(!k||g[l]?l=b:(c.dataTypes.unshift(l),l=b$(a,c,d,e,l,g)));(k||!l)&&!g["*"]&&(l=b$(a,c,d,e,"*",g));return l}function bZ(a){return function(b,c){typeof b!="string"&&(c=b,b="*");if(f.isFunction(c)){var d=b.toLowerCase().split(bQ),e=0,g=d.length,h,i,j;for(;e<g;e++)h=d[e],j=/^\+/.test(h),j&&(h=h.substr(1)||"*"),i=a[h]=a[h]||[],i[j?"unshift":"push"](c)}}}function bD(a,b,c){var d=b==="width"?bx:by,e=b==="width"?a.offsetWidth:a.offsetHeight;if(c==="border")return e;f.each(d,function(){c||(e-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?e+=parseFloat(f.css(a,"margin"+this))||0:e-=parseFloat(f.css(a,"border"+this+"Width"))||0});return e}function bn(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(bf,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bm(a){f.nodeName(a,"input")?bl(a):a.getElementsByTagName&&f.grep(a.getElementsByTagName("input"),bl)}function bl(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bk(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bj(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bi(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i<j;i++)f.event.add(b,h+(g[h][i].namespace?".":"")+g[h][i].namespace,g[h][i],g[h][i].data)}}}}function bh(a,b){return f.nodeName(a,"table")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function X(a,b,c){b=b||0;if(f.isFunction(b))return f.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return f.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=f.grep(a,function(a){return a.nodeType===1});if(S.test(b))return f.filter(b,d,!c);b=f.filter(b,d)}return f.grep(a,function(a,d){return f.inArray(a,b)>=0===c})}function W(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function O(a,b){return(a&&a!=="*"?a+".":"")+b.replace(A,"`").replace(B,"&")}function N(a){var b,c,d,e,g,h,i,j,k,l,m,n,o,p=[],q=[],r=f._data(this,"events");if(!(a.liveFired===this||!r||!r.live||a.target.disabled||a.button&&a.type==="click")){a.namespace&&(n=new RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")),a.liveFired=this;var s=r.live.slice(0);for(i=0;i<s.length;i++)g=s[i],g.origType.replace(y,"")===a.type?q.push(g.selector):s.splice(i--,1);e=f(a.target).closest(q,a.currentTarget);for(j=0,k=e.length;j<k;j++){m=e[j];for(i=0;i<s.length;i++){g=s[i];if(m.selector===g.selector&&(!n||n.test(g.namespace))&&!m.elem.disabled){h=m.elem,d=null;if(g.preType==="mouseenter"||g.preType==="mouseleave")a.type=g.preType,d=f(a.relatedTarget).closest(g.selector)[0],d&&f.contains(h,d)&&(d=h);(!d||d!==h)&&p.push({elem:h,handleObj:g,level:m.level})}}}for(j=0,k=p.length;j<k;j++){e=p[j];if(c&&e.level>c)break;a.currentTarget=e.elem,a.data=e.handleObj.data,a.handleObj=e.handleObj,o=e.handleObj.origHandler.apply(e.elem,arguments);if(o===!1||a.isPropagationStopped()){c=e.level,o===!1&&(b=!1);if(a.isImmediatePropagationStopped())break}}return b}}function L(a,c,d){var e=f.extend({},d[0]);e.type=a,e.originalEvent={},e.liveFired=b,f.event.handle.call(c,e),e.isDefaultPrevented()&&d[0].preventDefault()}function F(){return!0}function E(){return!1}function m(a,c,d){var e=c+"defer",g=c+"queue",h=c+"mark",i=f.data(a,e,b,!0);i&&(d==="queue"||!f.data(a,g,b,!0))&&(d==="mark"||!f.data(a,h,b,!0))&&setTimeout(function(){!f.data(a,g,b,!0)&&!f.data(a,h,b,!0)&&(f.removeData(a,e,!0),i.resolve())},0)}function l(a){for(var b in a)if(b!=="toJSON")return!1;return!0}function k(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(j,"$1-$2").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNaN(d)?i.test(d)?f.parseJSON(d):d:parseFloat(d)}catch(g){}f.data(a,c,d)}else d=b}return d}var c=a.document,d=a.navigator,e=a.location,f=function(){function H(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(H,1);return}e.ready()}}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/\d/,n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,o=/^[\],:{}\s]*$/,p=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,q=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,r=/(?:^|:|,)(?:\s*\[)+/g,s=/(webkit)[ \/]([\w.]+)/,t=/(opera)(?:.*version)?[ \/]([\w.]+)/,u=/(msie) ([\w.]+)/,v=/(mozilla)(?:.*? rv:([\w.]+))?/,w=d.userAgent,x,y,z,A=Object.prototype.toString,B=Object.prototype.hasOwnProperty,C=Array.prototype.push,D=Array.prototype.slice,E=String.prototype.trim,F=Array.prototype.indexOf,G={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)!=="<"||a.charAt(a.length-1)!==">"||a.length<3?g=i.exec(a):g=[null,a,null];if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=n.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.6.1",length:0,size:function(){return this.length},toArray:function(){return D.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?C.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),y.done(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(D.apply(this,arguments),"slice",D.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:C,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j<k;j++)if((a=arguments[j])!=null)for(c in a){d=i[c],f=a[c];if(i===f)continue;l&&f&&(e.isPlainObject(f)||(g=e.isArray(f)))?(g?(g=!1,h=d&&e.isArray(d)?d:[]):h=d&&e.isPlainObject(d)?d:{},i[c]=e.extend(l,h,f)):f!==b&&(i[c]=f)}return i},e.extend({noConflict:function(b){a.$===e&&(a.$=g),b&&a.jQuery===e&&(a.jQuery=f);return e},isReady:!1,readyWait:1,holdReady:function(a){a?e.readyWait++:e.ready(!0)},ready:function(a){if(a===!0&&!--e.readyWait||a!==!0&&!e.isReady){if(!c.body)return setTimeout(e.ready,1);e.isReady=!0;if(a!==!0&&--e.readyWait>0)return;y.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!y){y=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",z,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",z),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&H()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNaN:function(a){return a==null||!m.test(a)||isNaN(a)},type:function(a){return a==null?String(a):G[A.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;if(a.constructor&&!B.call(a,"constructor")&&!B.call(a.constructor.prototype,"isPrototypeOf"))return!1;var c;for(c in a);return c===b||B.call(a,c)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw a},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(o.test(b.replace(p,"@").replace(q,"]").replace(r,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(b,c,d){a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b)),d=c.documentElement,(!d||!d.nodeName||d.nodeName==="parsererror")&&e.error("Invalid XML: "+b);return c},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g<h;)if(c.apply(a[g++],d)===!1)break}else if(i){for(f in a)if(c.call(a[f],f,a[f])===!1)break}else for(;g<h;)if(c.call(a[g],g,a[g++])===!1)break;return a},trim:E?function(a){return a==null?"":E.call(a)}:function(a){return a==null?"":(a+"").replace(k,"").replace(l,"")},makeArray:function(a,b){var c=b||[];if(a!=null){var d=e.type(a);a.length==null||d==="string"||d==="function"||d==="regexp"||e.isWindow(a)?C.call(c,a):e.merge(c,a)}return c},inArray:function(a,b){if(F)return F.call(b,a);for(var c=0,d=b.length;c<d;c++)if(b[c]===a)return c;return-1},merge:function(a,c){var d=a.length,e=0;if(typeof c.length=="number")for(var f=c.length;e<f;e++)a[d++]=c[e];else while(c[e]!==b)a[d++]=c[e++];a.length=d;return a},grep:function(a,b,c){var d=[],e;c=!!c;for(var f=0,g=a.length;f<g;f++)e=!!b(a[f],f),c!==e&&d.push(a[f]);return d},map:function(a,c,d){var f,g,h=[],i=0,j=a.length,k=a instanceof e||j!==b&&typeof j=="number"&&(j>0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i<j;i++)f=c(a[i],i,d),f!=null&&(h[h.length]=f);else for(g in a)f=c(a[g],g,d),f!=null&&(h[h.length]=f);return h.concat.apply([],h)},guid:1,proxy:function(a,c){if(typeof c=="string"){var d=a[c];c=a,a=d}if(!e.isFunction(a))return b;var f=D.call(arguments,2),g=function(){return a.apply(c,f.concat(D.call(arguments)))};g.guid=a.guid=a.guid||g.guid||e.guid++;return g},access:function(a,c,d,f,g,h){var i=a.length;if(typeof c=="object"){for(var j in c)e.access(a,j,c[j],f,g,d);return a}if(d!==b){f=!h&&f&&e.isFunction(d);for(var k=0;k<i;k++)g(a[k],c,f?d.call(a[k],k,g(a[k],c)):d,h);return a}return i?g(a[0],c):b},now:function(){return(new Date).getTime()},uaMatch:function(a){a=a.toLowerCase();var b=s.exec(a)||t.exec(a)||u.exec(a)||a.indexOf("compatible")<0&&v.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},sub:function(){function a(b,c){return new a.fn.init(b,c)}e.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(d,f){f&&f instanceof e&&!(f instanceof a)&&(f=a(f));return e.fn.init.call(this,d,f,b)},a.fn.init.prototype=a.fn;var b=a(c);return a},browser:{}}),e.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){G["[object "+b+"]"]=b.toLowerCase()}),x=e.uaMatch(w),x.browser&&(e.browser[x.browser]=!0,e.browser.version=x.version),e.browser.webkit&&(e.browser.safari=!0),j.test(" ")&&(k=/^[\s\xA0]+/,l=/[\s\xA0]+$/),h=e(c),c.addEventListener?z=function(){c.removeEventListener("DOMContentLoaded",z,!1),e.ready()}:c.attachEvent&&(z=function(){c.readyState==="complete"&&(c.detachEvent("onreadystatechange",z),e.ready())});return e}(),g="done fail isResolved isRejected promise then always pipe".split(" "),h=[].slice;f.extend({_Deferred:function(){var a=[],b,c,d,e={done:function(){if(!d){var c=arguments,g,h,i,j,k;b&&(k=b,b=0);for(g=0,h=c.length;g<h;g++)i=c[g],j=f.type(i),j==="array"?e.done.apply(e,i):j==="function"&&a.push(i);k&&e.resolveWith(k[0],k[1])}return this},resolveWith:function(e,f){if(!d&&!b&&!c){f=f||[],c=1;try{while(a[0])a.shift().apply(e,f)}finally{b=[e,f],c=0}}return this},resolve:function(){e.resolveWith(this,arguments);return this},isResolved:function(){return!!c||!!b},cancel:function(){d=1,a=[];return this}};return e},Deferred:function(a){var b=f._Deferred(),c=f._Deferred(),d;f.extend(b,{then:function(a,c){b.done(a).fail(c);return this},always:function(){return b.done.apply(b,arguments).fail.apply(this,arguments)},fail:c.done,rejectWith:c.resolveWith,reject:c.resolve,isRejected:c.isResolved,pipe:function(a,c){return f.Deferred(function(d){f.each({done:[a,"resolve"],fail:[c,"reject"]},function(a,c){var e=c[0],g=c[1],h;f.isFunction(e)?b[a](function(){h=e.apply(this,arguments),h&&f.isFunction(h.promise)?h.promise().then(d.resolve,d.reject):d[g](h)}):b[a](d[g])})}).promise()},promise:function(a){if(a==null){if(d)return d;d=a={}}var c=g.length;while(c--)a[g[c]]=b[g[c]];return a}}),b.done(c.cancel).fail(b.cancel),delete b.cancel,a&&a.call(b,b);return b},when:function(a){function i(a){return function(c){b[a]=arguments.length>1?h.call(arguments,0):c,--e||g.resolveWith(g,h.call(b,0))}}var b=arguments,c=0,d=b.length,e=d,g=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred();if(d>1){for(;c<d;c++)b[c]&&f.isFunction(b[c].promise)?b[c].promise().then(i(c),g.reject):--e;e||g.resolveWith(g,b)}else g!==a&&g.resolveWith(g,d?[a]:[]);return g.promise()}}),f.support=function(){var a=c.createElement("div"),b=c.documentElement,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r;a.setAttribute("className","t"),a.innerHTML=" <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};f=c.createElement("select"),g=f.appendChild(c.createElement("option")),h=a.getElementsByTagName("input")[0],j={leadingWhitespace:a.firstChild.nodeType===3,tbody:!a.getElementsByTagName("tbody").length,htmlSerialize:!!a.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55$/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:h.value==="on",optSelected:g.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},h.checked=!0,j.noCloneChecked=h.cloneNode(!0).checked,f.disabled=!0,j.optDisabled=!g.disabled;try{delete a.test}catch(s){j.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function b(){j.noCloneEvent=!1,a.detachEvent("onclick",b)}),a.cloneNode(!0).fireEvent("onclick")),h=c.createElement("input"),h.value="t",h.setAttribute("type","radio"),j.radioValue=h.value==="t",h.setAttribute("checked","checked"),a.appendChild(h),k=c.createDocumentFragment(),k.appendChild(a.firstChild),j.checkClone=k.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",l=c.createElement("body"),m={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"};for(q in m)l.style[q]=m[q];l.appendChild(a),b.insertBefore(l,b.firstChild),j.appendChecked=h.checked,j.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,j.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="<div style='width:4px;'></div>",j.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>",n=a.getElementsByTagName("td"),r=n[0].offsetHeight===0,n[0].style.display="",n[1].style.display="none",j.reliableHiddenOffsets=r&&n[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(i=c.createElement("div"),i.style.width="0",i.style.marginRight="0",a.appendChild(i),j.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(i,null)||{marginRight:0}).marginRight,10)||0)===0),l.innerHTML="",b.removeChild(l);if(a.attachEvent)for(q in{submit:1,change:1,focusin:1})p="on"+q,r=p in a,r||(a.setAttribute(p,"return;"),r=typeof a[p]=="function"),j[q+"Bubbles"]=r;return j}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([a-z])([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!l(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g=f.expando,h=typeof c=="string",i,j=a.nodeType,k=j?f.cache:a,l=j?a[f.expando]:a[f.expando]&&f.expando;if((!l||e&&l&&!k[l][g])&&h&&d===b)return;l||(j?a[f.expando]=l=++f.uuid:l=f.expando),k[l]||(k[l]={},j||(k[l].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?k[l][g]=f.extend(k[l][g],c):k[l]=f.extend(k[l],c);i=k[l],e&&(i[g]||(i[g]={}),i=i[g]),d!==b&&(i[f.camelCase(c)]=d);if(c==="events"&&!i[c])return i[g]&&i[g].events;return h?i[f.camelCase(c)]:i}},removeData:function(b,c,d){if(!!f.acceptData(b)){var e=f.expando,g=b.nodeType,h=g?f.cache:b,i=g?b[f.expando]:f.expando;if(!h[i])return;if(c){var j=d?h[i][e]:h[i];if(j){delete j[c];if(!l(j))return}}if(d){delete h[i][e];if(!l(h[i]))return}var k=h[i][e];f.support.deleteExpando||h!=a?delete h[i]:h[i]=null,k?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=k):g&&(f.support.deleteExpando?delete b[f.expando]:b.removeAttribute?b.removeAttribute(f.expando):b[f.expando]=null)}},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d=null;if(typeof a=="undefined"){if(this.length){d=f.data(this[0]);if(this[0].nodeType===1){var e=this[0].attributes,g;for(var h=0,i=e.length;h<i;h++)g=e[h].name,g.indexOf("data-")===0&&(g=f.camelCase(g.substring(5)),k(this[0],g,d[g]))}}return d}if(typeof a=="object")return this.each(function(){f.data(this,a)});var j=a.split(".");j[1]=j[1]?"."+j[1]:"";if(c===b){d=this.triggerHandler("getData"+j[1]+"!",[j[0]]),d===b&&this.length&&(d=f.data(this[0],a),d=k(this[0],a,d));return d===b&&j[1]?this.data(j[0]):d}return this.each(function(){var b=f(this),d=[j[0],c];b.triggerHandler("setData"+j[1]+"!",d),f.data(this,a,c),b.triggerHandler("changeData"+j[1]+"!",d)})},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,c){a&&(c=(c||"fx")+"mark",f.data(a,c,(f.data(a,c,b,!0)||0)+1,!0))},_unmark:function(a,c,d){a!==!0&&(d=c,c=a,a=!1);if(c){d=d||"fx";var e=d+"mark",g=a?0:(f.data(c,e,b,!0)||1)-1;g?f.data(c,e,g,!0):(f.removeData(c,e,!0),m(c,d,"mark"))}},queue:function(a,c,d){if(a){c=(c||"fx")+"queue";var e=f.data(a,c,b,!0);d&&(!e||f.isArray(d)?e=f.data(a,c,f.makeArray(d),!0):e.push(d));return e||[]}},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e;d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),d.call(a,function(){f.dequeue(a,b)})),c.length||(f.removeData(a,b+"queue",!0),m(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){typeof a!="string"&&(c=a,a="fx");if(c===b)return f.queue(this[0],a);return this.each(function(){var b=f.queue(this,a,c);a==="fx"&&b[0]!=="inprogress"&&f.dequeue(this,a)})},dequeue:function(a){return this.each(function(){f.dequeue(this,a)})},delay:function(a,b){a=f.fx?f.fx.speeds[a]||a:a,b=b||"fx";return this.queue(b,function(){var c=this;setTimeout(function(){f.dequeue(c,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){function m(){--h||d.resolveWith(e,[e])}typeof a!="string"&&(c=a,a=b),a=a||"fx";var d=f.Deferred(),e=this,g=e.length,h=1,i=a+"defer",j=a+"queue",k=a+"mark",l;while(g--)if(l=f.data(e[g],i,b,!0)||(f.data(e[g],j,b,!0)||f.data(e[g],k,b,!0))&&f.data(e[g],i,f._Deferred(),!0))h++,l.done(m);m();return d.promise()}});var n=/[\n\t\r]/g,o=/\s+/,p=/\r/g,q=/^(?:button|input)$/i,r=/^(?:button|input|object|select|textarea)$/i,s=/^a(?:rea)?$/i,t=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,u=/\:/,v,w;f.fn.extend({attr:function(a,b){return f.access(this,a,b,!0,f.attr)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,a,b,!0,f.prop)},removeProp:function(a){a=f.propFix[a]||a;return this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.addClass(a.call(this,b,c.attr("class")||""))});if(a&&typeof a=="string"){var b=(a||"").split(o);for(var c=0,d=this.length;c<d;c++){var e=this[c];if(e.nodeType===1)if(!e.className)e.className=a;else{var g=" "+e.className+" ",h=e.className;for(var i=0,j=b.length;i<j;i++)g.indexOf(" "+b[i]+" ")<0&&(h+=" "+b[i]);e.className=f.trim(h)}}}return this},removeClass:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.removeClass(a.call(this,b,c.attr("class")))});if(a&&typeof a=="string"||a===b){var c=(a||"").split(o);for(var d=0,e=this.length;d<e;d++){var g=this[d];if(g.nodeType===1&&g.className)if(a){var h=(" "+g.className+" ").replace(n," ");for(var i=0,j=c.length;i<j;i++)h=h.replace(" "+c[i]+" "," ");g.className=f.trim(h)}else g.className=""}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";if(f.isFunction(a))return this.each(function(c){var d=f(this);d.toggleClass(a.call(this,c,d.attr("class"),b),b)});return this.each(function(){if(c==="string"){var e,g=0,h=f(this),i=b,j=a.split(o);while(e=j[g++])i=d?i:!h.hasClass(e),h[i?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&f._data(this,"__className__",this.className),this.className=this.className||a===!1?"":f._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ";for(var c=0,d=this.length;c<d;c++)if((" "+this[c].className+" ").replace(n," ").indexOf(b)>-1)return!0;return!1},val:function(a){var c,d,e=this[0];if(!arguments.length){if(e){c=f.valHooks[e.nodeName.toLowerCase()]||f.valHooks[e.type];if(c&&"get"in c&&(d=c.get(e,"value"))!==b)return d;return(e.value||"").replace(p,"")}return b}var g=f.isFunction(a);return this.each(function(d){var e=f(this),h;if(this.nodeType===1){g?h=a.call(this,d,e.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c=a.selectedIndex,d=[],e=a.options,g=a.type==="select-one";if(c<0)return null;for(var h=g?c:0,i=g?c+1:e.length;h<i;h++){var j=e[h];if(j.selected&&(f.support.optDisabled?!j.disabled:j.getAttribute("disabled")===null)&&(!j.parentNode.disabled||!f.nodeName(j.parentNode,"optgroup"))){b=f(j).val();if(g)return b;d.push(b)}}if(g&&!d.length&&e.length)return f(e[c]).val();return d},set:function(a,b){var c=f.makeArray(b);f(a).find("option").each(function(){this.selected=f.inArray(f(this).val(),c)>=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attrFix:{tabindex:"tabIndex"},attr:function(a,c,d,e){var g=a.nodeType;if(!a||g===3||g===8||g===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);var h,i,j=g!==1||!f.isXMLDoc(a);c=j&&f.attrFix[c]||c,i=f.attrHooks[c],i||(!t.test(c)||typeof d!="boolean"&&d!==b&&d.toLowerCase()!==c.toLowerCase()?v&&(f.nodeName(a,"form")||u.test(c))&&(i=v):i=w);if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(i&&"set"in i&&j&&(h=i.set(a,d,c))!==b)return h;a.setAttribute(c,""+d);return d}if(i&&"get"in i&&j)return i.get(a,c);h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.support.getSetAttribute?a.removeAttribute(b):(f.attr(a,b,""),a.removeAttributeNode(a.getAttributeNode(b))),t.test(b)&&(c=f.propFix[b]||b)in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(q.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;a.setAttribute("type",b),c&&(a.value=c);return b}}},tabIndex:{get:function(a){var c=a.getAttributeNode("tabIndex");return c&&c.specified?parseInt(c.value,10):r.test(a.nodeName)||s.test(a.nodeName)&&a.href?0:b}}},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(a,c,d){var e=a.nodeType;if(!a||e===3||e===8||e===2)return b;var g,h,i=e!==1||!f.isXMLDoc(a);c=i&&f.propFix[c]||c,h=f.propHooks[c];return d!==b?h&&"set"in h&&(g=h.set(a,d,c))!==b?g:a[c]=d:h&&"get"in h&&(g=h.get(a,c))!==b?g:a[c]},propHooks:{}}),w={get:function(a,c){return a[f.propFix[c]||c]?c.toLowerCase():b},set:function(a,b,c){var d;b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=b),a.setAttribute(c,c.toLowerCase()));return c}},f.attrHooks.value={get:function(a,b){if(v&&f.nodeName(a,"button"))return v.get(a,b);return a.value},set:function(a,b,c){if(v&&f.nodeName(a,"button"))return v.set(a,b,c);a.value=b}},f.support.getSetAttribute||(f.attrFix=f.propFix,v=f.attrHooks.name=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,c){var d=a.getAttributeNode(c);if(d){d.nodeValue=b;return b}}},f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c===""){a.setAttribute(b,"auto");return c}}})})),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}})),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var x=Object.prototype.hasOwnProperty,y=/\.(.*)$/,z=/^(?:textarea|input|select)$/i,A=/\./g,B=/ /g,C=/[^\w\s.|`]/g,D=function(a){return a.replace(C,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=E;else if(!d)return;var g,h;d.handler&&(g=d,d=g.handler),d.guid||(d.guid=f.guid++);var i=f._data(a);if(!i)return;var j=i.events,k=i.handle;j||(i.events=j={}),k||(i.handle=k=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.handle.apply(k.elem,arguments):b}),k.elem=a,c=c.split(" ");var l,m=0,n;while(l=c[m++]){h=g?f.extend({},g):{handler:d,data:e},l.indexOf(".")>-1?(n=l.split("."),l=n.shift(),h.namespace=n.slice(0).sort().join(".")):(n=[],h.namespace=""),h.type=l,h.guid||(h.guid=d.guid);var o=j[l],p=f.event.special[l]||{};if(!o){o=j[l]=[];if(!p.setup||p.setup.call(a,e,n,k)===!1)a.addEventListener?a.addEventListener(l,k,!1):a.attachEvent&&a.attachEvent("on"+l,k)}p.add&&(p.add.call(a,h),h.handler.guid||(h.handler.guid=d.guid)),o.push(h),f.event.global[l]=!0}a=null}},global:{},remove:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){d===!1&&(d=E);var g,h,i,j,k=0,l,m,n,o,p,q,r,s=f.hasData(a)&&f._data(a),t=s&&s.events;if(!s||!t)return;c&&c.type&&(d=c.handler,c=c.type);if(!c||typeof c=="string"&&c.charAt(0)==="."){c=c||"";for(h in t)f.event.remove(a,h+c);return}c=c.split(" ");while(h=c[k++]){r=h,q=null,l=h.indexOf(".")<0,m=[],l||(m=h.split("."),h=m.shift(),n=new RegExp("(^|\\.)"+f.map(m.slice(0).sort(),D).join("\\.(?:.*\\.)?")+"(\\.|$)")),p=t[h];if(!p)continue;if(!d){for(j=0;j<p.length;j++){q=p[j];if(l||n.test(q.namespace))f.event.remove(a,r,q.handler,j),p.splice(j--,1)}continue}o=f.event.special[h]||{};for(j=e||0;j<p.length;j++){q=p[j];if(d.guid===q.guid){if(l||n.test(q.namespace))e==null&&p.splice(j--,1),o.remove&&o.remove.call(a,q);if(e!=null)break}}if(p.length===0||e!=null&&p.length===1)(!o.teardown||o.teardown.call(a,m)===!1)&&f.removeEvent(a,h,s.handle),g=null,delete t[h]}if(f.isEmptyObject(t)){var u=s.handle;u&&(u.elem=null),delete s.events,delete s.handle,f.isEmptyObject(s)&&f.removeData(a,b,!0)}}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,g){var h=c.type||c,i=[],j;h.indexOf("!")>=0&&(h=h.slice(0,-1),j=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if(!!e&&!f.event.customEvent[h]||!!f.event.global[h]){c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.exclusive=j,c.namespace=i.join("."),c.namespace_re=new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)");if(g||!e)c.preventDefault(),c.stopPropagation();if(!e){f.each(f.cache,function(){var a=f.expando,b=this[a];b&&b.events&&b.events[h]&&f.event.trigger(c,d,b.handle.elem
17
+ )});return}if(e.nodeType===3||e.nodeType===8)return;c.result=b,c.target=e,d=d?f.makeArray(d):[],d.unshift(c);var k=e,l=h.indexOf(":")<0?"on"+h:"";do{var m=f._data(k,"handle");c.currentTarget=k,m&&m.apply(k,d),l&&f.acceptData(k)&&k[l]&&k[l].apply(k,d)===!1&&(c.result=!1,c.preventDefault()),k=k.parentNode||k.ownerDocument||k===c.target.ownerDocument&&a}while(k&&!c.isPropagationStopped());if(!c.isDefaultPrevented()){var n,o=f.event.special[h]||{};if((!o._default||o._default.call(e.ownerDocument,c)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)){try{l&&e[h]&&(n=e[l],n&&(e[l]=null),f.event.triggered=h,e[h]())}catch(p){}n&&(e[l]=n),f.event.triggered=b}}return c.result}},handle:function(c){c=f.event.fix(c||a.event);var d=((f._data(this,"events")||{})[c.type]||[]).slice(0),e=!c.exclusive&&!c.namespace,g=Array.prototype.slice.call(arguments,0);g[0]=c,c.currentTarget=this;for(var h=0,i=d.length;h<i;h++){var j=d[h];if(e||c.namespace_re.test(j.namespace)){c.handler=j.handler,c.data=j.data,c.handleObj=j;var k=j.handler.apply(this,g);k!==b&&(c.result=k,k===!1&&(c.preventDefault(),c.stopPropagation()));if(c.isImmediatePropagationStopped())break}}return c.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(a){if(a[f.expando])return a;var d=a;a=f.Event(d);for(var e=this.props.length,g;e;)g=this.props[--e],a[g]=d[g];a.target||(a.target=a.srcElement||c),a.target.nodeType===3&&(a.target=a.target.parentNode),!a.relatedTarget&&a.fromElement&&(a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement);if(a.pageX==null&&a.clientX!=null){var h=a.target.ownerDocument||c,i=h.documentElement,j=h.body;a.pageX=a.clientX+(i&&i.scrollLeft||j&&j.scrollLeft||0)-(i&&i.clientLeft||j&&j.clientLeft||0),a.pageY=a.clientY+(i&&i.scrollTop||j&&j.scrollTop||0)-(i&&i.clientTop||j&&j.clientTop||0)}a.which==null&&(a.charCode!=null||a.keyCode!=null)&&(a.which=a.charCode!=null?a.charCode:a.keyCode),!a.metaKey&&a.ctrlKey&&(a.metaKey=a.ctrlKey),!a.which&&a.button!==b&&(a.which=a.button&1?1:a.button&2?3:a.button&4?2:0);return a},guid:1e8,proxy:f.proxy,special:{ready:{setup:f.bindReady,teardown:f.noop},live:{add:function(a){f.event.add(this,O(a.origType,a.selector),f.extend({},a,{handler:N,guid:a.handler.guid}))},remove:function(a){f.event.remove(this,O(a.origType,a.selector),a)}},beforeunload:{setup:function(a,b,c){f.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}}},f.removeEvent=c.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){a.detachEvent&&a.detachEvent("on"+b,c)},f.Event=function(a,b){if(!this.preventDefault)return new f.Event(a,b);a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?F:E):this.type=a,b&&f.extend(this,b),this.timeStamp=f.now(),this[f.expando]=!0},f.Event.prototype={preventDefault:function(){this.isDefaultPrevented=F;var a=this.originalEvent;!a||(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=F;var a=this.originalEvent;!a||(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=F,this.stopPropagation()},isDefaultPrevented:E,isPropagationStopped:E,isImmediatePropagationStopped:E};var G=function(a){var b=a.relatedTarget;a.type=a.data;try{if(b&&b!==c&&!b.parentNode)return;while(b&&b!==this)b=b.parentNode;b!==this&&f.event.handle.apply(this,arguments)}catch(d){}},H=function(a){a.type=a.data,f.event.handle.apply(this,arguments)};f.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){f.event.special[a]={setup:function(c){f.event.add(this,b,c&&c.selector?H:G,a)},teardown:function(a){f.event.remove(this,b,a&&a.selector?H:G)}}}),f.support.submitBubbles||(f.event.special.submit={setup:function(a,b){if(!f.nodeName(this,"form"))f.event.add(this,"click.specialSubmit",function(a){var b=a.target,c=b.type;(c==="submit"||c==="image")&&f(b).closest("form").length&&L("submit",this,arguments)}),f.event.add(this,"keypress.specialSubmit",function(a){var b=a.target,c=b.type;(c==="text"||c==="password")&&f(b).closest("form").length&&a.keyCode===13&&L("submit",this,arguments)});else return!1},teardown:function(a){f.event.remove(this,".specialSubmit")}});if(!f.support.changeBubbles){var I,J=function(a){var b=a.type,c=a.value;b==="radio"||b==="checkbox"?c=a.checked:b==="select-multiple"?c=a.selectedIndex>-1?f.map(a.options,function(a){return a.selected}).join("-"):"":f.nodeName(a,"select")&&(c=a.selectedIndex);return c},K=function(c){var d=c.target,e,g;if(!!z.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=J(d),(c.type!=="focusout"||d.type!=="radio")&&f._data(d,"_change_data",g);if(e===b||g===e)return;if(e!=null||g)c.type="change",c.liveFired=b,f.event.trigger(c,arguments[1],d)}};f.event.special.change={filters:{focusout:K,beforedeactivate:K,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&K.call(this,a)},keydown:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(a.keyCode===13&&!f.nodeName(b,"textarea")||a.keyCode===32&&(c==="checkbox"||c==="radio")||c==="select-multiple")&&K.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",J(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in I)f.event.add(this,c+".specialChange",I[c]);return z.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return z.test(this.nodeName)}},I=f.event.special.change.filters,I.focus=I.beforeactivate}f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){function e(a){var c=f.event.fix(a);c.type=b,c.originalEvent={},f.event.trigger(c,null,c.target),c.isDefaultPrevented()&&a.preventDefault()}var d=0;f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.each(["bind","one"],function(a,c){f.fn[c]=function(a,d,e){var g;if(typeof a=="object"){for(var h in a)this[c](h,d,a[h],e);return this}if(arguments.length===2||d===!1)e=d,d=b;c==="one"?(g=function(a){f(this).unbind(a,g);return e.apply(this,arguments)},g.guid=e.guid||f.guid++):g=e;if(a==="unload"&&c!=="one")this.one(a,d,e);else for(var i=0,j=this.length;i<j;i++)f.event.add(this[i],a,g,d);return this}}),f.fn.extend({unbind:function(a,b){if(typeof a=="object"&&!a.preventDefault)for(var c in a)this.unbind(c,a[c]);else for(var d=0,e=this.length;d<e;d++)f.event.remove(this[d],a,b);return this},delegate:function(a,b,c,d){return this.live(b,c,d,a)},undelegate:function(a,b,c){return arguments.length===0?this.unbind("live"):this.die(b,null,c,a)},trigger:function(a,b){return this.each(function(){f.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return f.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||f.guid++,d=0,e=function(c){var e=(f.data(this,"lastToggle"+a.guid)||0)%d;f.data(this,"lastToggle"+a.guid,e+1),c.preventDefault();return b[e].apply(this,arguments)||!1};e.guid=c;while(d<b.length)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var M={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};f.each(["live","die"],function(a,c){f.fn[c]=function(a,d,e,g){var h,i=0,j,k,l,m=g||this.selector,n=g?this:f(this.context);if(typeof a=="object"&&!a.preventDefault){for(var o in a)n[c](o,d,a[o],m);return this}if(c==="die"&&!a&&g&&g.charAt(0)==="."){n.unbind(g);return this}if(d===!1||f.isFunction(d))e=d||E,d=b;a=(a||"").split(" ");while((h=a[i++])!=null){j=y.exec(h),k="",j&&(k=j[0],h=h.replace(y,""));if(h==="hover"){a.push("mouseenter"+k,"mouseleave"+k);continue}l=h,M[h]?(a.push(M[h]+k),h=h+k):h=(M[h]||h)+k;if(c==="live")for(var p=0,q=n.length;p<q;p++)f.event.add(n[p],"live."+O(h,m),{data:d,selector:m,handler:e,origType:h,origHandler:e,preType:l});else n.unbind("live."+O(h,m),e)}return this}}),f.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".split(" "),function(a,b){f.fn[b]=function(a,c){c==null&&(c=a,a=null);return arguments.length>0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0)}),function(){function u(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}if(i.nodeType===1){f||(i.sizcache=c,i.sizset=g);if(typeof b!="string"){if(i===b){j=!0;break}}else if(k.filter(b,[i]).length>0){j=i;break}}i=i[a]}d[g]=j}}}function t(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}i.nodeType===1&&!f&&(i.sizcache=c,i.sizset=g);if(i.nodeName.toLowerCase()===b){j=i;break}i=i[a]}d[g]=j}}}var a=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d=0,e=Object.prototype.toString,g=!1,h=!0,i=/\\/g,j=/\W/;[0,0].sort(function(){h=!1;return 0});var k=function(b,d,f,g){f=f||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return f;var i,j,n,o,q,r,s,t,u=!0,w=k.isXML(d),x=[],y=b;do{a.exec(""),i=a.exec(y);if(i){y=i[3],x.push(i[1]);if(i[2]){o=i[3];break}}}while(i);if(x.length>1&&m.exec(b))if(x.length===2&&l.relative[x[0]])j=v(x[0]+x[1],d);else{j=l.relative[x[0]]?[d]:k(x.shift(),d);while(x.length)b=x.shift(),l.relative[b]&&(b+=x.shift()),j=v(b,j)}else{!g&&x.length>1&&d.nodeType===9&&!w&&l.match.ID.test(x[0])&&!l.match.ID.test(x[x.length-1])&&(q=k.find(x.shift(),d,w),d=q.expr?k.filter(q.expr,q.set)[0]:q.set[0]);if(d){q=g?{expr:x.pop(),set:p(g)}:k.find(x.pop(),x.length===1&&(x[0]==="~"||x[0]==="+")&&d.parentNode?d.parentNode:d,w),j=q.expr?k.filter(q.expr,q.set):q.set,x.length>0?n=p(j):u=!1;while(x.length)r=x.pop(),s=r,l.relative[r]?s=x.pop():r="",s==null&&(s=d),l.relative[r](n,s,w)}else n=x=[]}n||(n=j),n||k.error(r||b);if(e.call(n)==="[object Array]")if(!u)f.push.apply(f,n);else if(d&&d.nodeType===1)for(t=0;n[t]!=null;t++)n[t]&&(n[t]===!0||n[t].nodeType===1&&k.contains(d,n[t]))&&f.push(j[t]);else for(t=0;n[t]!=null;t++)n[t]&&n[t].nodeType===1&&f.push(j[t]);else p(n,f);o&&(k(o,h,f,g),k.uniqueSort(f));return f};k.uniqueSort=function(a){if(r){g=h,a.sort(r);if(g)for(var b=1;b<a.length;b++)a[b]===a[b-1]&&a.splice(b--,1)}return a},k.matches=function(a,b){return k(a,null,null,b)},k.matchesSelector=function(a,b){return k(b,null,null,[a]).length>0},k.find=function(a,b,c){var d;if(!a)return[];for(var e=0,f=l.order.length;e<f;e++){var g,h=l.order[e];if(g=l.leftMatch[h].exec(a)){var j=g[1];g.splice(1,1);if(j.substr(j.length-1)!=="\\"){g[1]=(g[1]||"").replace(i,""),d=l.find[h](g,b,c);if(d!=null){a=a.replace(l.match[h],"");break}}}}d||(d=typeof b.getElementsByTagName!="undefined"?b.getElementsByTagName("*"):[]);return{set:d,expr:a}},k.filter=function(a,c,d,e){var f,g,h=a,i=[],j=c,m=c&&c[0]&&k.isXML(c[0]);while(a&&c.length){for(var n in l.filter)if((f=l.leftMatch[n].exec(a))!=null&&f[2]){var o,p,q=l.filter[n],r=f[1];g=!1,f.splice(1,1);if(r.substr(r.length-1)==="\\")continue;j===i&&(i=[]);if(l.preFilter[n]){f=l.preFilter[n](f,j,d,i,e,m);if(!f)g=o=!0;else if(f===!0)continue}if(f)for(var s=0;(p=j[s])!=null;s++)if(p){o=q(p,f,s,j);var t=e^!!o;d&&o!=null?t?g=!0:j[s]=!1:t&&(i.push(p),g=!0)}if(o!==b){d||(j=i),a=a.replace(l.match[n],"");if(!g)return[];break}}if(a===h)if(g==null)k.error(a);else break;h=a}return j},k.error=function(a){throw"Syntax error, unrecognized expression: "+a};var l=k.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(a){return a.getAttribute("href")},type:function(a){return a.getAttribute("type")}},relative:{"+":function(a,b){var c=typeof b=="string",d=c&&!j.test(b),e=c&&!d;d&&(b=b.toLowerCase());for(var f=0,g=a.length,h;f<g;f++)if(h=a[f]){while((h=h.previousSibling)&&h.nodeType!==1);a[f]=e||h&&h.nodeName.toLowerCase()===b?h||!1:h===b}e&&k.filter(b,a,!0)},">":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!j.test(b)){b=b.toLowerCase();for(;e<f;e++){c=a[e];if(c){var g=c.parentNode;a[e]=g.nodeName.toLowerCase()===b?g:!1}}}else{for(;e<f;e++)c=a[e],c&&(a[e]=d?c.parentNode:c.parentNode===b);d&&k.filter(b,a,!0)}},"":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("parentNode",b,f,a,e,c)},"~":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("previousSibling",b,f,a,e,c)}},find:{ID:function(a,b,c){if(typeof b.getElementById!="undefined"&&!c){var d=b.getElementById(a[1]);return d&&d.parentNode?[d]:[]}},NAME:function(a,b){if(typeof b.getElementsByName!="undefined"){var c=[],d=b.getElementsByName(a[1]);for(var e=0,f=d.length;e<f;e++)d[e].getAttribute("name")===a[1]&&c.push(d[e]);return c.length===0?null:c}},TAG:function(a,b){if(typeof b.getElementsByTagName!="undefined")return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,c,d,e,f){a=" "+a[1].replace(i,"")+" ";if(f)return a;for(var g=0,h;(h=b[g])!=null;g++)h&&(e^(h.className&&(" "+h.className+" ").replace(/[\t\n\r]/g," ").indexOf(a)>=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(i,"")},TAG:function(a,b){return a[1].replace(i,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||k.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&k.error(a[0]);a[0]=d++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(i,"");!f&&l.attrMap[g]&&(a[1]=l.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(i,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=k(b[3],null,null,c);else{var g=k.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(l.match.POS.test(b[0])||l.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!k(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return b<c[3]-0},gt:function(a,b,c){return b>c[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=l.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||k.getText([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h<i;h++)if(g[h]===a)return!1;return!0}k.error(e)},CHILD:function(a,b){var c=b[1],d=a;switch(c){case"only":case"first":while(d=d.previousSibling)if(d.nodeType===1)return!1;if(c==="first")return!0;d=a;case"last":while(d=d.nextSibling)if(d.nodeType===1)return!1;return!0;case"nth":var e=b[2],f=b[3];if(e===1&&f===0)return!0;var g=b[0],h=a.parentNode;if(h&&(h.sizcache!==g||!a.nodeIndex)){var i=0;for(d=h.firstChild;d;d=d.nextSibling)d.nodeType===1&&(d.nodeIndex=++i);h.sizcache=g}var j=a.nodeIndex-f;return e===0?j===0:j%e===0&&j/e>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=l.attrHandle[c]?l.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=l.setFilters[e];if(f)return f(a,c,b,d)}}},m=l.match.POS,n=function(a,b){return"\\"+(b-0+1)};for(var o in l.match)l.match[o]=new RegExp(l.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),l.leftMatch[o]=new RegExp(/(^(?:.|\r|\n)*?)/.source+l.match[o].source.replace(/\\(\d+)/g,n));var p=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(q){p=function(a,b){var c=0,d=b||[];if(e.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var f=a.length;c<f;c++)d.push(a[c]);else for(;a[c];c++)d.push(a[c]);return d}}var r,s;c.documentElement.compareDocumentPosition?r=function(a,b){if(a===b){g=!0;return 0}if(!a.compareDocumentPosition||!b.compareDocumentPosition)return a.compareDocumentPosition?-1:1;return a.compareDocumentPosition(b)&4?-1:1}:(r=function(a,b){if(a===b){g=!0;return 0}if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],h=a.parentNode,i=b.parentNode,j=h;if(h===i)return s(a,b);if(!h)return-1;if(!i)return 1;while(j)e.unshift(j),j=j.parentNode;j=i;while(j)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return s(e[k],f[k]);return k===c?s(a,f[k],-1):s(e[k],b,1)},s=function(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}),k.getText=function(a){var b="",c;for(var d=0;a[d];d++)c=a[d],c.nodeType===3||c.nodeType===4?b+=c.nodeValue:c.nodeType!==8&&(b+=k.getText(c.childNodes));return b},function(){var a=c.createElement("div"),d="script"+(new Date).getTime(),e=c.documentElement;a.innerHTML="<a name='"+d+"'/>",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(l.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},l.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(l.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(l.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=k,b=c.createElement("div"),d="__sizzle__";b.innerHTML="<p class='TEST'></p>";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){k=function(b,e,f,g){e=e||c;if(!g&&!k.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return p(e.getElementsByTagName(b),f);if(h[2]&&l.find.CLASS&&e.getElementsByClassName)return p(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return p([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return p([],f);if(i.id===h[3])return p([i],f)}try{return p(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var m=e,n=e.getAttribute("id"),o=n||d,q=e.parentNode,r=/^\s*[+~]/.test(b);n?o=o.replace(/'/g,"\\$&"):e.setAttribute("id",o),r&&q&&(e=e.parentNode);try{if(!r||q)return p(e.querySelectorAll("[id='"+o+"'] "+b),f)}catch(s){}finally{n||m.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)k[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}k.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!k.isXML(a))try{if(e||!l.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return k(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;l.order.splice(1,0,"CLASS"),l.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?k.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?k.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:k.contains=function(){return!1},k.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var v=function(a,b){var c,d=[],e="",f=b.nodeType?[b]:b;while(c=l.match.PSEUDO.exec(a))e+=c[0],a=a.replace(l.match.PSEUDO,"");a=l.relative[a]?a+"*":a;for(var g=0,h=f.length;g<h;g++)k(a,f[g],d);return k.filter(e,d)};f.find=k,f.expr=k.selectors,f.expr[":"]=f.expr.filters,f.unique=k.uniqueSort,f.text=k.getText,f.isXMLDoc=k.isXML,f.contains=k.contains}();var P=/Until$/,Q=/^(?:parents|prevUntil|prevAll)/,R=/,/,S=/^.[^:#\[\.,]*$/,T=Array.prototype.slice,U=f.expr.match.POS,V={children:!0,contents:!0,next:!0,prev:!0};f.fn.extend({find:function(a){var b=this,c,d;if(typeof a!="string")return f(a).filter(function(){for(c=0,d=b.length;c<d;c++)if(f.contains(b[c],this))return!0});var e=this.pushStack("","find",a),g,h,i;for(c=0,d=this.length;c<d;c++){g=e.length,f.find(a,this[c],e);if(c>0)for(h=g;h<e.length;h++)for(i=0;i<g;i++)if(e[i]===e[h]){e.splice(h--,1);break}}return e},has:function(a){var b=f(a);return this.filter(function(){for(var a=0,c=b.length;a<c;a++)if(f.contains(this,b[a]))return!0})},not:function(a){return this.pushStack(X(this,a,!1),"not",a)},filter:function(a){return this.pushStack(X(this,a,!0),"filter",a)},is:function(a){return!!a&&(typeof a=="string"?f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h,i,j={},k=1;if(g&&a.length){for(d=0,e=a.length;d<e;d++)i=a[d],j[i]||(j[i]=U.test(i)?f(i,b||this.context):i);while(g&&g.ownerDocument&&g!==b){for(i in j)h=j[i],(h.jquery?h.index(g)>-1:f(g).is(h))&&c.push({selector:i,elem:g,level:k});g=g.parentNode,k++}}return c}var l=U.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d<e;d++){g=this[d];while(g){if(l?l.index(g)>-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a||typeof a=="string")return f.inArray(this[0],a?f(a):this.parent().children());return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(W(c[0])||W(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c),g=T.call(arguments);P.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!V[a]?f.unique(e):e,(this.length>1||R.test(d))&&Q.test(a)&&(e=e.reverse());return this.pushStack(e,a,g.join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var Y=/ jQuery\d+="(?:\d+|null)"/g,Z=/^\s+/,$=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,_=/<([\w:]+)/,ba=/<tbody/i,bb=/<|&#?\w+;/,bc=/<(?:script|object|embed|option|style)/i,bd=/checked\s*(?:[^=]|=\s*.checked.)/i,be=/\/(java|ecma)script/i,bf=/^\s*<!(?:\[CDATA\[|\-\-)/,bg={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,"",""]};bg.optgroup=bg.option,bg.tbody=bg.tfoot=bg.colgroup=bg.caption=bg.thead,bg.th=bg.td,f.support.htmlSerialize||(bg._default=[1,"div<div>","</div>"]),f.fn.extend({text:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.text(a.call(this,b,c.text()))});if(typeof a!="object"&&a!==b)return this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a));return f.text(this)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapInner(a.call(this,b))});return this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){f(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,f(arguments[0]).toArray());return a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this,a,b)})},html:function(a){if(a===b)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(Y,""):null;if(typeof a=="string"&&!bc.test(a)&&(f.support.leadingWhitespace||!Z.test(a))&&!bg[(_.exec(a)||["",""])[1].toLowerCase()]){a=a.replace($,"<$1></$2>");try{for(var c=0,d=this.length;c<d;c++)this[c].nodeType===1&&(f.cleanData(this[c].getElementsByTagName("*")),this[c].innerHTML=a)}catch(e){this.empty().append(a)}}else f.isFunction(a)?this.each(function(b){var c=f(this);c.html(a.call(this,b,c.html()))}):this.empty().append(a);return this},replaceWith:function(a){if(this[0]&&this[0].parentNode){if(f.isFunction(a))return this.each(function(b){var c=f(this),d=c.html();c.replaceWith(a.call(this,b,d))});typeof a!="string"&&(a=f(a).detach());return this.each(function(){var b=this.nextSibling,c=this.parentNode;f(this).remove(),b?f(b).before(a):f(c).append(a)})}return this.length?this.pushStack(f(f.isFunction(a)?a():a),"replaceWith",a):this},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){var e,g,h,i,j=a[0],k=[];if(!f.support.checkClone&&arguments.length===3&&typeof j=="string"&&bd.test(j))return this.each(function(){f(this).domManip(a,c,d,!0)});if(f.isFunction(j))return this.each(function(e){var g=f(this);a[0]=j.call(this,e,c?g.html():b),g.domManip(a,c,d)});if(this[0]){i=j&&j.parentNode,f.support.parentNode&&i&&i.nodeType===11&&i.childNodes.length===this.length?e={fragment:i}:e=f.buildFragment(a,this,k),h=e.fragment,h.childNodes.length===1?g=h=h.firstChild:g=h.firstChild;if(g){c=c&&f.nodeName(g,"tr");for(var l=0,m=this.length,n=m-1;l<m;l++)d.call(c?bh(this[l],g):this[l],e.cacheable||m>1&&l<n?f.clone(h,!0,!0):h)}k.length&&f.each(k,bn)}return this}}),f.buildFragment=function(a,b,d){var e,g,h,i=b&&b[0]?b[0].ownerDocument||b[0]:c;a.length===1&&typeof a[0]=="string"&&a[0].length<512&&i===c&&a[0].charAt(0)==="<"&&!bc.test(a[0])&&(f.support.checkClone||!bd.test(a[0]))&&(g=!0,h=f.fragments[a[0]],h&&h!==1&&(e=h)),e||(e=i.createDocumentFragment(),f.clean(a,i,e,d)),g&&(f.fragments[a[0]]=h?e:1);return{fragment:e,cacheable:g}},f.fragments={},f.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){f.fn[a]=function(c){var d=[],e=f(c),g=this.length===1&&this[0].parentNode;if(g&&g.nodeType===11&&g.childNodes.length===1&&e.length===1){e[b](this[0]);return this}for(var h=0,i=e.length;h<i;h++){var j=(h>0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d=a.cloneNode(!0),e,g,h;if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bj(a,d),e=bk(a),g=bk(d);for(h=0;e[h];++h)bj(e[h],g[h])}if(b){bi(a,d);if(c){e=bk(a),g=bk(d);for(h=0;e[h];++h)bi(e[h],g[h])}}return d},clean:function(a,b,d,e){var g;b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||
18
+ b[0]&&b[0].ownerDocument||c);var h=[],i;for(var j=0,k;(k=a[j])!=null;j++){typeof k=="number"&&(k+="");if(!k)continue;if(typeof k=="string")if(!bb.test(k))k=b.createTextNode(k);else{k=k.replace($,"<$1></$2>");var l=(_.exec(k)||["",""])[1].toLowerCase(),m=bg[l]||bg._default,n=m[0],o=b.createElement("div");o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=ba.test(k),q=l==="table"&&!p?o.firstChild&&o.firstChild.childNodes:m[1]==="<table>"&&!p?o.childNodes:[];for(i=q.length-1;i>=0;--i)f.nodeName(q[i],"tbody")&&!q[i].childNodes.length&&q[i].parentNode.removeChild(q[i])}!f.support.leadingWhitespace&&Z.test(k)&&o.insertBefore(b.createTextNode(Z.exec(k)[0]),o.firstChild),k=o.childNodes}var r;if(!f.support.appendChecked)if(k[0]&&typeof (r=k.length)=="number")for(i=0;i<r;i++)bm(k[i]);else bm(k);k.nodeType?h.push(k):h=f.merge(h,k)}if(d){g=function(a){return!a.type||be.test(a.type)};for(j=0;h[j];j++)if(e&&f.nodeName(h[j],"script")&&(!h[j].type||h[j].type.toLowerCase()==="text/javascript"))e.push(h[j].parentNode?h[j].parentNode.removeChild(h[j]):h[j]);else{if(h[j].nodeType===1){var s=f.grep(h[j].getElementsByTagName("script"),g);h.splice.apply(h,[j+1,0].concat(s))}d.appendChild(h[j])}}return h},cleanData:function(a){var b,c,d=f.cache,e=f.expando,g=f.event.special,h=f.support.deleteExpando;for(var i=0,j;(j=a[i])!=null;i++){if(j.nodeName&&f.noData[j.nodeName.toLowerCase()])continue;c=j[f.expando];if(c){b=d[c]&&d[c][e];if(b&&b.events){for(var k in b.events)g[k]?f.event.remove(j,k):f.removeEvent(j,k,b.handle);b.handle&&(b.handle.elem=null)}h?delete j[f.expando]:j.removeAttribute&&j.removeAttribute(f.expando),delete d[c]}}}});var bo=/alpha\([^)]*\)/i,bp=/opacity=([^)]*)/,bq=/-([a-z])/ig,br=/([A-Z]|^ms)/g,bs=/^-?\d+(?:px)?$/i,bt=/^-?\d/,bu=/^[+\-]=/,bv=/[^+\-\.\de]+/g,bw={position:"absolute",visibility:"hidden",display:"block"},bx=["Left","Right"],by=["Top","Bottom"],bz,bA,bB,bC=function(a,b){return b.toUpperCase()};f.fn.css=function(a,c){if(arguments.length===2&&c===b)return this;return f.access(this,a,c,!0,function(a,c,d){return d!==b?f.style(a,c,d):f.css(a,c)})},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=bz(a,"opacity","opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{zIndex:!0,fontWeight:!0,opacity:!0,zoom:!0,lineHeight:!0,widows:!0,orphans:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!!a&&a.nodeType!==3&&a.nodeType!==8&&!!a.style){var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b){if(k&&"get"in k&&(g=k.get(a,!1,e))!==b)return g;return j[c]}h=typeof d;if(h==="number"&&isNaN(d)||d==null)return;h==="string"&&bu.test(d)&&(d=+d.replace(bv,"")+parseFloat(f.css(a,c))),h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(bz)return bz(a,c)},swap:function(a,b,c){var d={};for(var e in b)d[e]=a.style[e],a.style[e]=b[e];c.call(a);for(e in b)a.style[e]=d[e]},camelCase:function(a){return a.replace(bq,bC)}}),f.curCSS=f.css,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){var e;if(c){a.offsetWidth!==0?e=bD(a,b,d):f.swap(a,bw,function(){e=bD(a,b,d)});if(e<=0){e=bz(a,b,b),e==="0px"&&bB&&(e=bB(a,b,b));if(e!=null)return e===""||e==="auto"?"0px":e}if(e<0||e==null){e=a.style[b];return e===""||e==="auto"?"0px":e}return typeof e=="string"?e:e+"px"}},set:function(a,b){if(!bs.test(b))return b;b=parseFloat(b);if(b>=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bp.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle;c.zoom=1;var e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.filter=bo.test(g)?g.replace(bo,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){var c;f.swap(a,{display:"inline-block"},function(){b?c=bz(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bA=function(a,c){var d,e,g;c=c.replace(br,"-$1").toLowerCase();if(!(e=a.ownerDocument.defaultView))return b;if(g=e.getComputedStyle(a,null))d=g.getPropertyValue(c),d===""&&!f.contains(a.ownerDocument.documentElement,a)&&(d=f.style(a,c));return d}),c.documentElement.currentStyle&&(bB=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bs.test(d)&&bt.test(d)&&(c=f.left,e&&(a.runtimeStyle.left=a.currentStyle.left),f.left=b==="fontSize"?"1em":d||0,d=f.pixelLeft+"px",f.left=c,e&&(a.runtimeStyle.left=e));return d===""?"auto":d}),bz=bA||bB,f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bE=/%20/g,bF=/\[\]$/,bG=/\r?\n/g,bH=/#.*$/,bI=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bJ=/^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bK=/^(?:about|app|app\-storage|.+\-extension|file|widget):$/,bL=/^(?:GET|HEAD)$/,bM=/^\/\//,bN=/\?/,bO=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,bP=/^(?:select|textarea)/i,bQ=/\s+/,bR=/([?&])_=[^&]*/,bS=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bT=f.fn.load,bU={},bV={},bW,bX;try{bW=e.href}catch(bY){bW=c.createElement("a"),bW.href="",bW=bW.href}bX=bS.exec(bW.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bT)return bT.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("<div>").append(c.replace(bO,"")).find(g):c)),d&&i.each(d,[c,b,a])}});return this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||bP.test(this.nodeName)||bJ.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(bG,"\r\n")}}):{name:b.name,value:c.replace(bG,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.bind(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){f.isFunction(d)&&(g=g||e,e=d,d=b);return f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){b?f.extend(!0,a,f.ajaxSettings,b):(b=a,a=f.extend(!0,f.ajaxSettings,b));for(var c in{context:1,url:1})c in b?a[c]=b[c]:c in f.ajaxSettings&&(a[c]=f.ajaxSettings[c]);return a},ajaxSettings:{url:bW,isLocal:bK.test(bX[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","*":"*/*"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML}},ajaxPrefilter:bZ(bU),ajaxTransport:bZ(bV),ajax:function(a,c){function w(a,c,l,m){if(s!==2){s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a?4:0;var o,r,u,w=l?ca(d,v,l):b,x,y;if(a>=200&&a<300||a===304){if(d.ifModified){if(x=v.getResponseHeader("Last-Modified"))f.lastModified[k]=x;if(y=v.getResponseHeader("Etag"))f.etag[k]=y}if(a===304)c="notmodified",o=!0;else try{r=cb(d,w),c="success",o=!0}catch(z){c="parsererror",u=z}}else{u=c;if(!c||a)c="error",a<0&&(a=0)}v.status=a,v.statusText=c,o?h.resolveWith(e,[r,c,v]):h.rejectWith(e,[v,c,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,c]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f._Deferred(),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=bI.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){s||(d.mimeType=a);return this},abort:function(a){a=a||"abort",p&&p.abort(a),w(0,a);return this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.done,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(bH,"").replace(bM,bX[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bQ),d.crossDomain==null&&(r=bS.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bX[1]&&r[2]==bX[2]&&(r[3]||(r[1]==="http:"?80:443))==(bX[3]||(bX[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),b$(bU,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bL.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bN.test(d.url)?"&":"?")+d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bR,"$1_="+x);d.url=y+(y===d.url?(bN.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", */*; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(d.beforeSend&&(d.beforeSend.call(e,v,d)===!1||s===2)){v.abort();return!1}for(u in{success:1,error:1,complete:1})v[u](d[u]);p=b$(bV,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){status<2?w(-1,z):f.error(z)}}return v},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)b_(g,a[g],c,e);return d.join("&").replace(bE,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cc=f.now(),cd=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cc++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=b.contentType==="application/x-www-form-urlencoded"&&typeof b.data=="string";if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(cd.test(b.url)||e&&cd.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";b.jsonp!==!1&&(j=j.replace(cd,l),b.url===j&&(e&&(k=k.replace(cd,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){g||f.error(h+" was not called");return g[0]},b.dataTypes[0]="json";return"script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){f.globalEval(a);return a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var ce=a.ActiveXObject?function(){for(var a in cg)cg[a](0,1)}:!1,cf=0,cg;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ch()||ci()}:ch,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,ce&&delete cg[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n),m.text=h.responseText;try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++cf,ce&&(cg||(cg={},f(a).unload(ce)),cg[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cj={},ck,cl,cm=/^(?:toggle|show|hide)$/,cn=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,co,cp=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cq,cr=a.webkitRequestAnimationFrame||a.mozRequestAnimationFrame||a.oRequestAnimationFrame;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cu("show",3),a,b,c);for(var g=0,h=this.length;g<h;g++)d=this[g],d.style&&(e=d.style.display,!f._data(d,"olddisplay")&&e==="none"&&(e=d.style.display=""),e===""&&f.css(d,"display")==="none"&&f._data(d,"olddisplay",cv(d.nodeName)));for(g=0;g<h;g++){d=this[g];if(d.style){e=d.style.display;if(e===""||e==="none")d.style.display=f._data(d,"olddisplay")||""}}return this},hide:function(a,b,c){if(a||a===0)return this.animate(cu("hide",3),a,b,c);for(var d=0,e=this.length;d<e;d++)if(this[d].style){var g=f.css(this[d],"display");g!=="none"&&!f._data(this[d],"olddisplay")&&f._data(this[d],"olddisplay",g)}for(d=0;d<e;d++)this[d].style&&(this[d].style.display="none");return this},_toggle:f.fn.toggle,toggle:function(a,b,c){var d=typeof a=="boolean";f.isFunction(a)&&f.isFunction(b)?this._toggle.apply(this,arguments):a==null||d?this.each(function(){var b=d?a:f(this).is(":hidden");f(this)[b?"show":"hide"]()}):this.animate(cu("toggle",3),a,b,c);return this},fadeTo:function(a,b,c,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=f.speed(b,c,d);if(f.isEmptyObject(a))return this.each(e.complete,[!1]);a=f.extend({},a);return this[e.queue===!1?"each":"queue"](function(){e.queue===!1&&f._mark(this);var b=f.extend({},e),c=this.nodeType===1,d=c&&f(this).is(":hidden"),g,h,i,j,k,l,m,n,o;b.animatedProperties={};for(i in a){g=f.camelCase(i),i!==g&&(a[g]=a[i],delete a[i]),h=a[g],f.isArray(h)?(b.animatedProperties[g]=h[1],h=a[g]=h[0]):b.animatedProperties[g]=b.specialEasing&&b.specialEasing[g]||b.easing||"swing";if(h==="hide"&&d||h==="show"&&!d)return b.complete.call(this);c&&(g==="height"||g==="width")&&(b.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY],f.css(this,"display")==="inline"&&f.css(this,"float")==="none"&&(f.support.inlineBlockNeedsLayout?(j=cv(this.nodeName),j==="inline"?this.style.display="inline-block":(this.style.display="inline",this.style.zoom=1)):this.style.display="inline-block"))}b.overflow!=null&&(this.style.overflow="hidden");for(i in a)k=new f.fx(this,b,i),h=a[i],cm.test(h)?k[h==="toggle"?d?"show":"hide":h]():(l=cn.exec(h),m=k.cur(),l?(n=parseFloat(l[2]),o=l[3]||(f.cssNumber[i]?"":"px"),o!=="px"&&(f.style(this,i,(n||1)+o),m=(n||1)/k.cur()*m,f.style(this,i,m+o)),l[1]&&(n=(l[1]==="-="?-1:1)*n+m),k.custom(m,n,o)):k.custom(m,h,""));return!0})},stop:function(a,b){a&&this.queue([]),this.each(function(){var a=f.timers,c=a.length;b||f._unmark(!0,this);while(c--)a[c].elem===this&&(b&&a[c](!0),a.splice(c,1))}),b||this.dequeue();return this}}),f.each({slideDown:cu("show",1),slideUp:cu("hide",1),slideToggle:cu("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){f.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),f.extend({speed:function(a,b,c){var d=a&&typeof a=="object"?f.extend({},a):{complete:c||!c&&b||f.isFunction(a)&&a,duration:a,easing:c&&b||b&&!f.isFunction(b)&&b};d.duration=f.fx.off?0:typeof d.duration=="number"?d.duration:d.duration in f.fx.speeds?f.fx.speeds[d.duration]:f.fx.speeds._default,d.old=d.complete,d.complete=function(a){d.queue!==!1?f.dequeue(this):a!==!1&&f._unmark(this),f.isFunction(d.old)&&d.old.call(this)};return d},easing:{linear:function(a,b,c,d){return c+d*a},swing:function(a,b,c,d){return(-Math.cos(a*Math.PI)/2+.5)*d+c}},timers:[],fx:function(a,b,c){this.options=b,this.elem=a,this.prop=c,b.orig=b.orig||{}}}),f.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this),(f.fx.step[this.prop]||f.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 a,b=f.css(this.elem,this.prop);return isNaN(a=parseFloat(b))?!b||b==="auto"?0:b:a},custom:function(a,b,c){function h(a){return d.step(a)}var d=this,e=f.fx,g;this.startTime=cq||cs(),this.start=a,this.end=b,this.unit=c||this.unit||(f.cssNumber[this.prop]?"":"px"),this.now=this.start,this.pos=this.state=0,h.elem=this.elem,h()&&f.timers.push(h)&&!co&&(cr?(co=1,g=function(){co&&(cr(g),e.tick())},cr(g)):co=setInterval(e.tick,e.interval))},show:function(){this.options.orig[this.prop]=f.style(this.elem,this.prop),this.options.show=!0,this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur()),f(this.elem).show()},hide:function(){this.options.orig[this.prop]=f.style(this.elem,this.prop),this.options.hide=!0,this.custom(this.cur(),0)},step:function(a){var b=cq||cs(),c=!0,d=this.elem,e=this.options,g,h;if(a||b>=e.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),e.animatedProperties[this.prop]=!0;for(g in e.animatedProperties)e.animatedProperties[g]!==!0&&(c=!1);if(c){e.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){d.style["overflow"+b]=e.overflow[a]}),e.hide&&f(d).hide();if(e.hide||e.show)for(var i in e.animatedProperties)f.style(d,i,e.orig[i]);e.complete.call(d)}return!1}e.duration==Infinity?this.now=b:(h=b-this.startTime,this.state=h/e.duration,this.pos=f.easing[e.animatedProperties[this.prop]](this.state,h,0,1,e.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){for(var a=f.timers,b=0;b<a.length;++b)a[b]()||a.splice(b--,1);a.length||f.fx.stop()},interval:13,stop:function(){clearInterval(co),co=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){f.style(a.elem,"opacity",a.now)},_default:function(a){a.elem.style&&a.elem.style[a.prop]!=null?a.elem.style[a.prop]=(a.prop==="width"||a.prop==="height"?Math.max(0,a.now):a.now)+a.unit:a.elem[a.prop]=a.now}}}),f.expr&&f.expr.filters&&(f.expr.filters.animated=function(a){return f.grep(f.timers,function(b){return a===b.elem}).length});var cw=/^t(?:able|d|h)$/i,cx=/^(?:body|html)$/i;"getBoundingClientRect"in c.documentElement?f.fn.offset=function(a){var b=this[0],c;if(a)return this.each(function(b){f.offset.setOffset(this,a,b)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return f.offset.bodyOffset(b);try{c=b.getBoundingClientRect()}catch(d){}var e=b.ownerDocument,g=e.documentElement;if(!c||!f.contains(g,b))return c?{top:c.top,left:c.left}:{top:0,left:0};var h=e.body,i=cy(e),j=g.clientTop||h.clientTop||0,k=g.clientLeft||h.clientLeft||0,l=i.pageYOffset||f.support.boxModel&&g.scrollTop||h.scrollTop,m=i.pageXOffset||f.support.boxModel&&g.scrollLeft||h.scrollLeft,n=c.top+l-j,o=c.left+m-k;return{top:n,left:o}}:f.fn.offset=function(a){var b=this[0];if(a)return this.each(function(b){f.offset.setOffset(this,a,b)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return f.offset.bodyOffset(b);f.offset.initialize();var c,d=b.offsetParent,e=b,g=b.ownerDocument,h=g.documentElement,i=g.body,j=g.defaultView,k=j?j.getComputedStyle(b,null):b.currentStyle,l=b.offsetTop,m=b.offsetLeft;while((b=b.parentNode)&&b!==i&&b!==h){if(f.offset.supportsFixedPosition&&k.position==="fixed")break;c=j?j.getComputedStyle(b,null):b.currentStyle,l-=b.scrollTop,m-=b.scrollLeft,b===d&&(l+=b.offsetTop,m+=b.offsetLeft,f.offset.doesNotAddBorder&&(!f.offset.doesAddBorderForTableAndCells||!cw.test(b.nodeName))&&(l+=parseFloat(c.borderTopWidth)||0,m+=parseFloat(c.borderLeftWidth)||0),e=d,d=b.offsetParent),f.offset.subtractsBorderForOverflowNotVisible&&c.overflow!=="visible"&&(l+=parseFloat(c.borderTopWidth)||0,m+=parseFloat(c.borderLeftWidth)||0),k=c}if(k.position==="relative"||k.position==="static")l+=i.offsetTop,m+=i.offsetLeft;f.offset.supportsFixedPosition&&k.position==="fixed"&&(l+=Math.max(h.scrollTop,i.scrollTop),m+=Math.max(h.scrollLeft,i.scrollLeft));return{top:l,left:m}},f.offset={initialize:function(){var a=c.body,b=c.createElement("div"),d,e,g,h,i=parseFloat(f.css(a,"marginTop"))||0,j="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";f.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"}),b.innerHTML=j,a.insertBefore(b,a.firstChild),d=b.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,this.doesNotAddBorder=e.offsetTop!==5,this.doesAddBorderForTableAndCells=h.offsetTop===5,e.style.position="fixed",e.style.top="20px",this.supportsFixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",this.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==i,a.removeChild(b),f.offset.initialize=f.noop},bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;f.offset.initialize(),f.offset.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0);return{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=cx.test(b[0].nodeName)?{top:0,left:0}:b.offset();c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0;return{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!cx.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each(["Left","Top"],function(a,c){var d="scroll"+c;f.fn[d]=function(c){var e,g;if(c===b){e=this[0];if(!e)return null;g=cy(e);return g?"pageXOffset"in g?g[a?"pageYOffset":"pageXOffset"]:f.support.boxModel&&g.document.documentElement[d]||g.document.body[d]:e[d]}return this.each(function(){g=cy(this),g?g.scrollTo(a?f(g).scrollLeft():c,a?c:f(g).scrollTop()):this[d]=c})}}),f.each(["Height","Width"],function(a,c){var d=c.toLowerCase();f.fn["inner"+c]=function(){return this[0]?parseFloat(f.css(this[0],d,"padding")):null},f.fn["outer"+c]=function(a){return this[0]?parseFloat(f.css(this[0],d,a?"margin":"border")):null},f.fn[d]=function(a){var e=this[0];if(!e)return a==null?null:this;if(f.isFunction(a))return this.each(function(b){var c=f(this);c[d](a.call(this,b,c[d]()))});if(f.isWindow(e)){var g=e.document.documentElement["client"+c];return e.document.compatMode==="CSS1Compat"&&g||e.document.body["client"+c]||g}if(e.nodeType===9)return Math.max(e.documentElement["client"+c],e.body["scroll"+c],e.documentElement["scroll"+c],e.body["offset"+c],e.documentElement["offset"+c]);if(a===b){var h=f.css(e,d),i=parseFloat(h);return f.isNaN(i)?h:i}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window);
js/jquery-1.6.1rc1.js DELETED
@@ -1,8935 +0,0 @@
1
- /*!
2
- * jQuery JavaScript Library v1.6.1rc1
3
- * http://jquery.com/
4
- *
5
- * Copyright 2011, John Resig
6
- * Dual licensed under the MIT or GPL Version 2 licenses.
7
- * http://jquery.org/license
8
- *
9
- * Includes Sizzle.js
10
- * http://sizzlejs.com/
11
- * Copyright 2011, The Dojo Foundation
12
- * Released under the MIT, BSD, and GPL Licenses.
13
- *
14
- * Date: Tue May 10 13:50:35 2011 -0400
15
- */
16
- (function( window, undefined ) {
17
-
18
- // Use the correct document accordingly with window argument (sandbox)
19
- var document = window.document,
20
- navigator = window.navigator,
21
- location = window.location;
22
- var jQuery = (function() {
23
-
24
- // Define a local copy of jQuery
25
- var jQuery = function( selector, context ) {
26
- // The jQuery object is actually just the init constructor 'enhanced'
27
- return new jQuery.fn.init( selector, context, rootjQuery );
28
- },
29
-
30
- // Map over jQuery in case of overwrite
31
- _jQuery = window.jQuery,
32
-
33
- // Map over the $ in case of overwrite
34
- _$ = window.$,
35
-
36
- // A central reference to the root jQuery(document)
37
- rootjQuery,
38
-
39
- // A simple way to check for HTML strings or ID strings
40
- // (both of which we optimize for)
41
- quickExpr = /^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,
42
-
43
- // Check if a string has a non-whitespace character in it
44
- rnotwhite = /\S/,
45
-
46
- // Used for trimming whitespace
47
- trimLeft = /^\s+/,
48
- trimRight = /\s+$/,
49
-
50
- // Check for digits
51
- rdigit = /\d/,
52
-
53
- // Match a standalone tag
54
- rsingleTag = /^<(\w+)\s*\/?>(?:<\/\1>)?$/,
55
-
56
- // JSON RegExp
57
- rvalidchars = /^[\],:{}\s]*$/,
58
- rvalidescape = /\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,
59
- rvalidtokens = /"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,
60
- rvalidbraces = /(?:^|:|,)(?:\s*\[)+/g,
61
-
62
- // Useragent RegExp
63
- rwebkit = /(webkit)[ \/]([\w.]+)/,
64
- ropera = /(opera)(?:.*version)?[ \/]([\w.]+)/,
65
- rmsie = /(msie) ([\w.]+)/,
66
- rmozilla = /(mozilla)(?:.*? rv:([\w.]+))?/,
67
-
68
- // Keep a UserAgent string for use with jQuery.browser
69
- userAgent = navigator.userAgent,
70
-
71
- // For matching the engine and version of the browser
72
- browserMatch,
73
-
74
- // The deferred used on DOM ready
75
- readyList,
76
-
77
- // The ready event handler
78
- DOMContentLoaded,
79
-
80
- // Save a reference to some core methods
81
- toString = Object.prototype.toString,
82
- hasOwn = Object.prototype.hasOwnProperty,
83
- push = Array.prototype.push,
84
- slice = Array.prototype.slice,
85
- trim = String.prototype.trim,
86
- indexOf = Array.prototype.indexOf,
87
-
88
- // [[Class]] -> type pairs
89
- class2type = {};
90
-
91
- jQuery.fn = jQuery.prototype = {
92
- constructor: jQuery,
93
- init: function( selector, context, rootjQuery ) {
94
- var match, elem, ret, doc;
95
-
96
- // Handle $(""), $(null), or $(undefined)
97
- if ( !selector ) {
98
- return this;
99
- }
100
-
101
- // Handle $(DOMElement)
102
- if ( selector.nodeType ) {
103
- this.context = this[0] = selector;
104
- this.length = 1;
105
- return this;
106
- }
107
-
108
- // The body element only exists once, optimize finding it
109
- if ( selector === "body" && !context && document.body ) {
110
- this.context = document;
111
- this[0] = document.body;
112
- this.selector = selector;
113
- this.length = 1;
114
- return this;
115
- }
116
-
117
- // Handle HTML strings
118
- if ( typeof selector === "string" ) {
119
- // Are we dealing with HTML string or an ID?
120
- if ( selector.charAt(0) === "<" && selector.charAt( selector.length - 1 ) === ">" && selector.length >= 3 ) {
121
- // Assume that strings that start and end with <> are HTML and skip the regex check
122
- match = [ null, selector, null ];
123
-
124
- } else {
125
- match = quickExpr.exec( selector );
126
- }
127
-
128
- // Verify a match, and that no context was specified for #id
129
- if ( match && (match[1] || !context) ) {
130
-
131
- // HANDLE: $(html) -> $(array)
132
- if ( match[1] ) {
133
- context = context instanceof jQuery ? context[0] : context;
134
- doc = (context ? context.ownerDocument || context : document);
135
-
136
- // If a single string is passed in and it's a single tag
137
- // just do a createElement and skip the rest
138
- ret = rsingleTag.exec( selector );
139
-
140
- if ( ret ) {
141
- if ( jQuery.isPlainObject( context ) ) {
142
- selector = [ document.createElement( ret[1] ) ];
143
- jQuery.fn.attr.call( selector, context, true );
144
-
145
- } else {
146
- selector = [ doc.createElement( ret[1] ) ];
147
- }
148
-
149
- } else {
150
- ret = jQuery.buildFragment( [ match[1] ], [ doc ] );
151
- selector = (ret.cacheable ? jQuery.clone(ret.fragment) : ret.fragment).childNodes;
152
- }
153
-
154
- return jQuery.merge( this, selector );
155
-
156
- // HANDLE: $("#id")
157
- } else {
158
- elem = document.getElementById( match[2] );
159
-
160
- // Check parentNode to catch when Blackberry 4.6 returns
161
- // nodes that are no longer in the document #6963
162
- if ( elem && elem.parentNode ) {
163
- // Handle the case where IE and Opera return items
164
- // by name instead of ID
165
- if ( elem.id !== match[2] ) {
166
- return rootjQuery.find( selector );
167
- }
168
-
169
- // Otherwise, we inject the element directly into the jQuery object
170
- this.length = 1;
171
- this[0] = elem;
172
- }
173
-
174
- this.context = document;
175
- this.selector = selector;
176
- return this;
177
- }
178
-
179
- // HANDLE: $(expr, $(...))
180
- } else if ( !context || context.jquery ) {
181
- return (context || rootjQuery).find( selector );
182
-
183
- // HANDLE: $(expr, context)
184
- // (which is just equivalent to: $(context).find(expr)
185
- } else {
186
- return this.constructor( context ).find( selector );
187
- }
188
-
189
- // HANDLE: $(function)
190
- // Shortcut for document ready
191
- } else if ( jQuery.isFunction( selector ) ) {
192
- return rootjQuery.ready( selector );
193
- }
194
-
195
- if (selector.selector !== undefined) {
196
- this.selector = selector.selector;
197
- this.context = selector.context;
198
- }
199
-
200
- return jQuery.makeArray( selector, this );
201
- },
202
-
203
- // Start with an empty selector
204
- selector: "",
205
-
206
- // The current version of jQuery being used
207
- jquery: "1.6.1rc1",
208
-
209
- // The default length of a jQuery object is 0
210
- length: 0,
211
-
212
- // The number of elements contained in the matched element set
213
- size: function() {
214
- return this.length;
215
- },
216
-
217
- toArray: function() {
218
- return slice.call( this, 0 );
219
- },
220
-
221
- // Get the Nth element in the matched element set OR
222
- // Get the whole matched element set as a clean array
223
- get: function( num ) {
224
- return num == null ?
225
-
226
- // Return a 'clean' array
227
- this.toArray() :
228
-
229
- // Return just the object
230
- ( num < 0 ? this[ this.length + num ] : this[ num ] );
231
- },
232
-
233
- // Take an array of elements and push it onto the stack
234
- // (returning the new matched element set)
235
- pushStack: function( elems, name, selector ) {
236
- // Build a new jQuery matched element set
237
- var ret = this.constructor();
238
-
239
- if ( jQuery.isArray( elems ) ) {
240
- push.apply( ret, elems );
241
-
242
- } else {
243
- jQuery.merge( ret, elems );
244
- }
245
-
246
- // Add the old object onto the stack (as a reference)
247
- ret.prevObject = this;
248
-
249
- ret.context = this.context;
250
-
251
- if ( name === "find" ) {
252
- ret.selector = this.selector + (this.selector ? " " : "") + selector;
253
- } else if ( name ) {
254
- ret.selector = this.selector + "." + name + "(" + selector + ")";
255
- }
256
-
257
- // Return the newly-formed element set
258
- return ret;
259
- },
260
-
261
- // Execute a callback for every element in the matched set.
262
- // (You can seed the arguments with an array of args, but this is
263
- // only used internally.)
264
- each: function( callback, args ) {
265
- return jQuery.each( this, callback, args );
266
- },
267
-
268
- ready: function( fn ) {
269
- // Attach the listeners
270
- jQuery.bindReady();
271
-
272
- // Add the callback
273
- readyList.done( fn );
274
-
275
- return this;
276
- },
277
-
278
- eq: function( i ) {
279
- return i === -1 ?
280
- this.slice( i ) :
281
- this.slice( i, +i + 1 );
282
- },
283
-
284
- first: function() {
285
- return this.eq( 0 );
286
- },
287
-
288
- last: function() {
289
- return this.eq( -1 );
290
- },
291
-
292
- slice: function() {
293
- return this.pushStack( slice.apply( this, arguments ),
294
- "slice", slice.call(arguments).join(",") );
295
- },
296
-
297
- map: function( callback ) {
298
- return this.pushStack( jQuery.map(this, function( elem, i ) {
299
- return callback.call( elem, i, elem );
300
- }));
301
- },
302
-
303
- end: function() {
304
- return this.prevObject || this.constructor(null);
305
- },
306
-
307
- // For internal use only.
308
- // Behaves like an Array's method, not like a jQuery method.
309
- push: push,
310
- sort: [].sort,
311
- splice: [].splice
312
- };
313
-
314
- // Give the init function the jQuery prototype for later instantiation
315
- jQuery.fn.init.prototype = jQuery.fn;
316
-
317
- jQuery.extend = jQuery.fn.extend = function() {
318
- var options, name, src, copy, copyIsArray, clone,
319
- target = arguments[0] || {},
320
- i = 1,
321
- length = arguments.length,
322
- deep = false;
323
-
324
- // Handle a deep copy situation
325
- if ( typeof target === "boolean" ) {
326
- deep = target;
327
- target = arguments[1] || {};
328
- // skip the boolean and the target
329
- i = 2;
330
- }
331
-
332
- // Handle case when target is a string or something (possible in deep copy)
333
- if ( typeof target !== "object" && !jQuery.isFunction(target) ) {
334
- target = {};
335
- }
336
-
337
- // extend jQuery itself if only one argument is passed
338
- if ( length === i ) {
339
- target = this;
340
- --i;
341
- }
342
-
343
- for ( ; i < length; i++ ) {
344
- // Only deal with non-null/undefined values
345
- if ( (options = arguments[ i ]) != null ) {
346
- // Extend the base object
347
- for ( name in options ) {
348
- src = target[ name ];
349
- copy = options[ name ];
350
-
351
- // Prevent never-ending loop
352
- if ( target === copy ) {
353
- continue;
354
- }
355
-
356
- // Recurse if we're merging plain objects or arrays
357
- if ( deep && copy && ( jQuery.isPlainObject(copy) || (copyIsArray = jQuery.isArray(copy)) ) ) {
358
- if ( copyIsArray ) {
359
- copyIsArray = false;
360
- clone = src && jQuery.isArray(src) ? src : [];
361
-
362
- } else {
363
- clone = src && jQuery.isPlainObject(src) ? src : {};
364
- }
365
-
366
- // Never move original objects, clone them
367
- target[ name ] = jQuery.extend( deep, clone, copy );
368
-
369
- // Don't bring in undefined values
370
- } else if ( copy !== undefined ) {
371
- target[ name ] = copy;
372
- }
373
- }
374
- }
375
- }
376
-
377
- // Return the modified object
378
- return target;
379
- };
380
-
381
- jQuery.extend({
382
- noConflict: function( deep ) {
383
- if ( window.$ === jQuery ) {
384
- window.$ = _$;
385
- }
386
-
387
- if ( deep && window.jQuery === jQuery ) {
388
- window.jQuery = _jQuery;
389
- }
390
-
391
- return jQuery;
392
- },
393
-
394
- // Is the DOM ready to be used? Set to true once it occurs.
395
- isReady: false,
396
-
397
- // A counter to track how many items to wait for before
398
- // the ready event fires. See #6781
399
- readyWait: 1,
400
-
401
- // Hold (or release) the ready event
402
- holdReady: function( hold ) {
403
- if ( hold ) {
404
- jQuery.readyWait++;
405
- } else {
406
- jQuery.ready( true );
407
- }
408
- },
409
-
410
- // Handle when the DOM is ready
411
- ready: function( wait ) {
412
- // Either a released hold or an DOMready/load event and not yet ready
413
- if ( (wait === true && !--jQuery.readyWait) || (wait !== true && !jQuery.isReady) ) {
414
- // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443).
415
- if ( !document.body ) {
416
- return setTimeout( jQuery.ready, 1 );
417
- }
418
-
419
- // Remember that the DOM is ready
420
- jQuery.isReady = true;
421
-
422
- // If a normal DOM Ready event fired, decrement, and wait if need be
423
- if ( wait !== true && --jQuery.readyWait > 0 ) {
424
- return;
425
- }
426
-
427
- // If there are functions bound, to execute
428
- readyList.resolveWith( document, [ jQuery ] );
429
-
430
- // Trigger any bound ready events
431
- if ( jQuery.fn.trigger ) {
432
- jQuery( document ).trigger( "ready" ).unbind( "ready" );
433
- }
434
- }
435
- },
436
-
437
- bindReady: function() {
438
- if ( readyList ) {
439
- return;
440
- }
441
-
442
- readyList = jQuery._Deferred();
443
-
444
- // Catch cases where $(document).ready() is called after the
445
- // browser event has already occurred.
446
- if ( document.readyState === "complete" ) {
447
- // Handle it asynchronously to allow scripts the opportunity to delay ready
448
- return setTimeout( jQuery.ready, 1 );
449
- }
450
-
451
- // Mozilla, Opera and webkit nightlies currently support this event
452
- if ( document.addEventListener ) {
453
- // Use the handy event callback
454
- document.addEventListener( "DOMContentLoaded", DOMContentLoaded, false );
455
-
456
- // A fallback to window.onload, that will always work
457
- window.addEventListener( "load", jQuery.ready, false );
458
-
459
- // If IE event model is used
460
- } else if ( document.attachEvent ) {
461
- // ensure firing before onload,
462
- // maybe late but safe also for iframes
463
- document.attachEvent( "onreadystatechange", DOMContentLoaded );
464
-
465
- // A fallback to window.onload, that will always work
466
- window.attachEvent( "onload", jQuery.ready );
467
-
468
- // If IE and not a frame
469
- // continually check to see if the document is ready
470
- var toplevel = false;
471
-
472
- try {
473
- toplevel = window.frameElement == null;
474
- } catch(e) {}
475
-
476
- if ( document.documentElement.doScroll && toplevel ) {
477
- doScrollCheck();
478
- }
479
- }
480
- },
481
-
482
- // See test/unit/core.js for details concerning isFunction.
483
- // Since version 1.3, DOM methods and functions like alert
484
- // aren't supported. They return false on IE (#2968).
485
- isFunction: function( obj ) {
486
- return jQuery.type(obj) === "function";
487
- },
488
-
489
- isArray: Array.isArray || function( obj ) {
490
- return jQuery.type(obj) === "array";
491
- },
492
-
493
- // A crude way of determining if an object is a window
494
- isWindow: function( obj ) {
495
- return obj && typeof obj === "object" && "setInterval" in obj;
496
- },
497
-
498
- isNaN: function( obj ) {
499
- return obj == null || !rdigit.test( obj ) || isNaN( obj );
500
- },
501
-
502
- type: function( obj ) {
503
- return obj == null ?
504
- String( obj ) :
505
- class2type[ toString.call(obj) ] || "object";
506
- },
507
-
508
- isPlainObject: function( obj ) {
509
- // Must be an Object.
510
- // Because of IE, we also have to check the presence of the constructor property.
511
- // Make sure that DOM nodes and window objects don't pass through, as well
512
- if ( !obj || jQuery.type(obj) !== "object" || obj.nodeType || jQuery.isWindow( obj ) ) {
513
- return false;
514
- }
515
-
516
- // Not own constructor property must be Object
517
- if ( obj.constructor &&
518
- !hasOwn.call(obj, "constructor") &&
519
- !hasOwn.call(obj.constructor.prototype, "isPrototypeOf") ) {
520
- return false;
521
- }
522
-
523
- // Own properties are enumerated firstly, so to speed up,
524
- // if last one is own, then all properties are own.
525
-
526
- var key;
527
- for ( key in obj ) {}
528
-
529
- return key === undefined || hasOwn.call( obj, key );
530
- },
531
-
532
- isEmptyObject: function( obj ) {
533
- for ( var name in obj ) {
534
- return false;
535
- }
536
- return true;
537
- },
538
-
539
- error: function( msg ) {
540
- throw msg;
541
- },
542
-
543
- parseJSON: function( data ) {
544
- if ( typeof data !== "string" || !data ) {
545
- return null;
546
- }
547
-
548
- // Make sure leading/trailing whitespace is removed (IE can't handle it)
549
- data = jQuery.trim( data );
550
-
551
- // Attempt to parse using the native JSON parser first
552
- if ( window.JSON && window.JSON.parse ) {
553
- return window.JSON.parse( data );
554
- }
555
-
556
- // Make sure the incoming data is actual JSON
557
- // Logic borrowed from http://json.org/json2.js
558
- if ( rvalidchars.test( data.replace( rvalidescape, "@" )
559
- .replace( rvalidtokens, "]" )
560
- .replace( rvalidbraces, "")) ) {
561
-
562
- return (new Function( "return " + data ))();
563
-
564
- }
565
- jQuery.error( "Invalid JSON: " + data );
566
- },
567
-
568
- // Cross-browser xml parsing
569
- // (xml & tmp used internally)
570
- parseXML: function( data , xml , tmp ) {
571
-
572
- if ( window.DOMParser ) { // Standard
573
- tmp = new DOMParser();
574
- xml = tmp.parseFromString( data , "text/xml" );
575
- } else { // IE
576
- xml = new ActiveXObject( "Microsoft.XMLDOM" );
577
- xml.async = "false";
578
- xml.loadXML( data );
579
- }
580
-
581
- tmp = xml.documentElement;
582
-
583
- if ( ! tmp || ! tmp.nodeName || tmp.nodeName === "parsererror" ) {
584
- jQuery.error( "Invalid XML: " + data );
585
- }
586
-
587
- return xml;
588
- },
589
-
590
- noop: function() {},
591
-
592
- // Evaluates a script in a global context
593
- // Workarounds based on findings by Jim Driscoll
594
- // http://weblogs.java.net/blog/driscoll/archive/2009/09/08/eval-javascript-global-context
595
- globalEval: function( data ) {
596
- if ( data && rnotwhite.test( data ) ) {
597
- // We use execScript on Internet Explorer
598
- // We use an anonymous function so that context is window
599
- // rather than jQuery in Firefox
600
- ( window.execScript || function( data ) {
601
- window[ "eval" ].call( window, data );
602
- } )( data );
603
- }
604
- },
605
-
606
- nodeName: function( elem, name ) {
607
- return elem.nodeName && elem.nodeName.toUpperCase() === name.toUpperCase();
608
- },
609
-
610
- // args is for internal usage only
611
- each: function( object, callback, args ) {
612
- var name, i = 0,
613
- length = object.length,
614
- isObj = length === undefined || jQuery.isFunction( object );
615
-
616
- if ( args ) {
617
- if ( isObj ) {
618
- for ( name in object ) {
619
- if ( callback.apply( object[ name ], args ) === false ) {
620
- break;
621
- }
622
- }
623
- } else {
624
- for ( ; i < length; ) {
625
- if ( callback.apply( object[ i++ ], args ) === false ) {
626
- break;
627
- }
628
- }
629
- }
630
-
631
- // A special, fast, case for the most common use of each
632
- } else {
633
- if ( isObj ) {
634
- for ( name in object ) {
635
- if ( callback.call( object[ name ], name, object[ name ] ) === false ) {
636
- break;
637
- }
638
- }
639
- } else {
640
- for ( ; i < length; ) {
641
- if ( callback.call( object[ i ], i, object[ i++ ] ) === false ) {
642
- break;
643
- }
644
- }
645
- }
646
- }
647
-
648
- return object;
649
- },
650
-
651
- // Use native String.trim function wherever possible
652
- trim: trim ?
653
- function( text ) {
654
- return text == null ?
655
- "" :
656
- trim.call( text );
657
- } :
658
-
659
- // Otherwise use our own trimming functionality
660
- function( text ) {
661
- return text == null ?
662
- "" :
663
- text.toString().replace( trimLeft, "" ).replace( trimRight, "" );
664
- },
665
-
666
- // results is for internal usage only
667
- makeArray: function( array, results ) {
668
- var ret = results || [];
669
-
670
- if ( array != null ) {
671
- // The window, strings (and functions) also have 'length'
672
- // The extra typeof function check is to prevent crashes
673
- // in Safari 2 (See: #3039)
674
- // Tweaked logic slightly to handle Blackberry 4.7 RegExp issues #6930
675
- var type = jQuery.type( array );
676
-
677
- if ( array.length == null || type === "string" || type === "function" || type === "regexp" || jQuery.isWindow( array ) ) {
678
- push.call( ret, array );
679
- } else {
680
- jQuery.merge( ret, array );
681
- }
682
- }
683
-
684
- return ret;
685
- },
686
-
687
- inArray: function( elem, array ) {
688
-
689
- if ( indexOf ) {
690
- return indexOf.call( array, elem );
691
- }
692
-
693
- for ( var i = 0, length = array.length; i < length; i++ ) {
694
- if ( array[ i ] === elem ) {
695
- return i;
696
- }
697
- }
698
-
699
- return -1;
700
- },
701
-
702
- merge: function( first, second ) {
703
- var i = first.length,
704
- j = 0;
705
-
706
- if ( typeof second.length === "number" ) {
707
- for ( var l = second.length; j < l; j++ ) {
708
- first[ i++ ] = second[ j ];
709
- }
710
-
711
- } else {
712
- while ( second[j] !== undefined ) {
713
- first[ i++ ] = second[ j++ ];
714
- }
715
- }
716
-
717
- first.length = i;
718
-
719
- return first;
720
- },
721
-
722
- grep: function( elems, callback, inv ) {
723
- var ret = [], retVal;
724
- inv = !!inv;
725
-
726
- // Go through the array, only saving the items
727
- // that pass the validator function
728
- for ( var i = 0, length = elems.length; i < length; i++ ) {
729
- retVal = !!callback( elems[ i ], i );
730
- if ( inv !== retVal ) {
731
- ret.push( elems[ i ] );
732
- }
733
- }
734
-
735
- return ret;
736
- },
737
-
738
- // arg is for internal usage only
739
- map: function( elems, callback, arg ) {
740
- var value, key, ret = [],
741
- i = 0,
742
- length = elems.length,
743
- // jquery objects are treated as arrays
744
- isArray = elems instanceof jQuery || length !== undefined && typeof length === "number" && ( ( length > 0 && elems[ 0 ] && elems[ length -1 ] ) || length === 0 || jQuery.isArray( elems ) ) ;
745
-
746
- // Go through the array, translating each of the items to their
747
- if ( isArray ) {
748
- for ( ; i < length; i++ ) {
749
- value = callback( elems[ i ], i, arg );
750
-
751
- if ( value != null ) {
752
- ret[ ret.length ] = value;
753
- }
754
- }
755
-
756
- // Go through every key on the object,
757
- } else {
758
- for ( key in elems ) {
759
- value = callback( elems[ key ], key, arg );
760
-
761
- if ( value != null ) {
762
- ret[ ret.length ] = value;
763
- }
764
- }
765
- }
766
-
767
- // Flatten any nested arrays
768
- return ret.concat.apply( [], ret );
769
- },
770
-
771
- // A global GUID counter for objects
772
- guid: 1,
773
-
774
- // Bind a function to a context, optionally partially applying any
775
- // arguments.
776
- proxy: function( fn, context ) {
777
- if ( typeof context === "string" ) {
778
- var tmp = fn[ context ];
779
- context = fn;
780
- fn = tmp;
781
- }
782
-
783
- // Quick check to determine if target is callable, in the spec
784
- // this throws a TypeError, but we will just return undefined.
785
- if ( !jQuery.isFunction( fn ) ) {
786
- return undefined;
787
- }
788
-
789
- // Simulated bind
790
- var args = slice.call( arguments, 2 ),
791
- proxy = function() {
792
- return fn.apply( context, args.concat( slice.call( arguments ) ) );
793
- };
794
-
795
- // Set the guid of unique handler to the same of original handler, so it can be removed
796
- proxy.guid = fn.guid = fn.guid || proxy.guid || jQuery.guid++;
797
-
798
- return proxy;
799
- },
800
-
801
- // Mutifunctional method to get and set values to a collection
802
- // The value/s can be optionally by executed if its a function
803
- access: function( elems, key, value, exec, fn, pass ) {
804
- var length = elems.length;
805
-
806
- // Setting many attributes
807
- if ( typeof key === "object" ) {
808
- for ( var k in key ) {
809
- jQuery.access( elems, k, key[k], exec, fn, value );
810
- }
811
- return elems;
812
- }
813
-
814
- // Setting one attribute
815
- if ( value !== undefined ) {
816
- // Optionally, function values get executed if exec is true
817
- exec = !pass && exec && jQuery.isFunction(value);
818
-
819
- for ( var i = 0; i < length; i++ ) {
820
- fn( elems[i], key, exec ? value.call( elems[i], i, fn( elems[i], key ) ) : value, pass );
821
- }
822
-
823
- return elems;
824
- }
825
-
826
- // Getting an attribute
827
- return length ? fn( elems[0], key ) : undefined;
828
- },
829
-
830
- now: function() {
831
- return (new Date()).getTime();
832
- },
833
-
834
- // Use of jQuery.browser is frowned upon.
835
- // More details: http://docs.jquery.com/Utilities/jQuery.browser
836
- uaMatch: function( ua ) {
837
- ua = ua.toLowerCase();
838
-
839
- var match = rwebkit.exec( ua ) ||
840
- ropera.exec( ua ) ||
841
- rmsie.exec( ua ) ||
842
- ua.indexOf("compatible") < 0 && rmozilla.exec( ua ) ||
843
- [];
844
-
845
- return { browser: match[1] || "", version: match[2] || "0" };
846
- },
847
-
848
- sub: function() {
849
- function jQuerySub( selector, context ) {
850
- return new jQuerySub.fn.init( selector, context );
851
- }
852
- jQuery.extend( true, jQuerySub, this );
853
- jQuerySub.superclass = this;
854
- jQuerySub.fn = jQuerySub.prototype = this();
855
- jQuerySub.fn.constructor = jQuerySub;
856
- jQuerySub.sub = this.sub;
857
- jQuerySub.fn.init = function init( selector, context ) {
858
- if ( context && context instanceof jQuery && !(context instanceof jQuerySub) ) {
859
- context = jQuerySub( context );
860
- }
861
-
862
- return jQuery.fn.init.call( this, selector, context, rootjQuerySub );
863
- };
864
- jQuerySub.fn.init.prototype = jQuerySub.fn;
865
- var rootjQuerySub = jQuerySub(document);
866
- return jQuerySub;
867
- },
868
-
869
- browser: {}
870
- });
871
-
872
- // Populate the class2type map
873
- jQuery.each("Boolean Number String Function Array Date RegExp Object".split(" "), function(i, name) {
874
- class2type[ "[object " + name + "]" ] = name.toLowerCase();
875
- });
876
-
877
- browserMatch = jQuery.uaMatch( userAgent );
878
- if ( browserMatch.browser ) {
879
- jQuery.browser[ browserMatch.browser ] = true;
880
- jQuery.browser.version = browserMatch.version;
881
- }
882
-
883
- // Deprecated, use jQuery.browser.webkit instead
884
- if ( jQuery.browser.webkit ) {
885
- jQuery.browser.safari = true;
886
- }
887
-
888
- // IE doesn't match non-breaking spaces with \s
889
- if ( rnotwhite.test( "\xA0" ) ) {
890
- trimLeft = /^[\s\xA0]+/;
891
- trimRight = /[\s\xA0]+$/;
892
- }
893
-
894
- // All jQuery objects should point back to these
895
- rootjQuery = jQuery(document);
896
-
897
- // Cleanup functions for the document ready method
898
- if ( document.addEventListener ) {
899
- DOMContentLoaded = function() {
900
- document.removeEventListener( "DOMContentLoaded", DOMContentLoaded, false );
901
- jQuery.ready();
902
- };
903
-
904
- } else if ( document.attachEvent ) {
905
- DOMContentLoaded = function() {
906
- // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443).
907
- if ( document.readyState === "complete" ) {
908
- document.detachEvent( "onreadystatechange", DOMContentLoaded );
909
- jQuery.ready();
910
- }
911
- };
912
- }
913
-
914
- // The DOM ready check for Internet Explorer
915
- function doScrollCheck() {
916
- if ( jQuery.isReady ) {
917
- return;
918
- }
919
-
920
- try {
921
- // If IE is used, use the trick by Diego Perini
922
- // http://javascript.nwbox.com/IEContentLoaded/
923
- document.documentElement.doScroll("left");
924
- } catch(e) {
925
- setTimeout( doScrollCheck, 1 );
926
- return;
927
- }
928
-
929
- // and execute any waiting functions
930
- jQuery.ready();
931
- }
932
-
933
- // Expose jQuery to the global object
934
- return jQuery;
935
-
936
- })();
937
-
938
-
939
- var // Promise methods
940
- promiseMethods = "done fail isResolved isRejected promise then always pipe".split( " " ),
941
- // Static reference to slice
942
- sliceDeferred = [].slice;
943
-
944
- jQuery.extend({
945
- // Create a simple deferred (one callbacks list)
946
- _Deferred: function() {
947
- var // callbacks list
948
- callbacks = [],
949
- // stored [ context , args ]
950
- fired,
951
- // to avoid firing when already doing so
952
- firing,
953
- // flag to know if the deferred has been cancelled
954
- cancelled,
955
- // the deferred itself
956
- deferred = {
957
-
958
- // done( f1, f2, ...)
959
- done: function() {
960
- if ( !cancelled ) {
961
- var args = arguments,
962
- i,
963
- length,
964
- elem,
965
- type,
966
- _fired;
967
- if ( fired ) {
968
- _fired = fired;
969
- fired = 0;
970
- }
971
- for ( i = 0, length = args.length; i < length; i++ ) {
972
- elem = args[ i ];
973
- type = jQuery.type( elem );
974
- if ( type === "array" ) {
975
- deferred.done.apply( deferred, elem );
976
- } else if ( type === "function" ) {
977
- callbacks.push( elem );
978
- }
979
- }
980
- if ( _fired ) {
981
- deferred.resolveWith( _fired[ 0 ], _fired[ 1 ] );
982
- }
983
- }
984
- return this;
985
- },
986
-
987
- // resolve with given context and args
988
- resolveWith: function( context, args ) {
989
- if ( !cancelled && !fired && !firing ) {
990
- // make sure args are available (#8421)
991
- args = args || [];
992
- firing = 1;
993
- try {
994
- while( callbacks[ 0 ] ) {
995
- callbacks.shift().apply( context, args );
996
- }
997
- }
998
- finally {
999
- fired = [ context, args ];
1000
- firing = 0;
1001
- }
1002
- }
1003
- return this;
1004
- },
1005
-
1006
- // resolve with this as context and given arguments
1007
- resolve: function() {
1008
- deferred.resolveWith( this, arguments );
1009
- return this;
1010
- },
1011
-
1012
- // Has this deferred been resolved?
1013
- isResolved: function() {
1014
- return !!( firing || fired );
1015
- },
1016
-
1017
- // Cancel
1018
- cancel: function() {
1019
- cancelled = 1;
1020
- callbacks = [];
1021
- return this;
1022
- }
1023
- };
1024
-
1025
- return deferred;
1026
- },
1027
-
1028
- // Full fledged deferred (two callbacks list)
1029
- Deferred: function( func ) {
1030
- var deferred = jQuery._Deferred(),
1031
- failDeferred = jQuery._Deferred(),
1032
- promise;
1033
- // Add errorDeferred methods, then and promise
1034
- jQuery.extend( deferred, {
1035
- then: function( doneCallbacks, failCallbacks ) {
1036
- deferred.done( doneCallbacks ).fail( failCallbacks );
1037
- return this;
1038
- },
1039
- always: function() {
1040
- return deferred.done.apply( deferred, arguments ).fail.apply( this, arguments );
1041
- },
1042
- fail: failDeferred.done,
1043
- rejectWith: failDeferred.resolveWith,
1044
- reject: failDeferred.resolve,
1045
- isRejected: failDeferred.isResolved,
1046
- pipe: function( fnDone, fnFail ) {
1047
- return jQuery.Deferred(function( newDefer ) {
1048
- jQuery.each( {
1049
- done: [ fnDone, "resolve" ],
1050
- fail: [ fnFail, "reject" ]
1051
- }, function( handler, data ) {
1052
- var fn = data[ 0 ],
1053
- action = data[ 1 ],
1054
- returned;
1055
- if ( jQuery.isFunction( fn ) ) {
1056
- deferred[ handler ](function() {
1057
- returned = fn.apply( this, arguments );
1058
- if ( returned && jQuery.isFunction( returned.promise ) ) {
1059
- returned.promise().then( newDefer.resolve, newDefer.reject );
1060
- } else {
1061
- newDefer[ action ]( returned );
1062
- }
1063
- });
1064
- } else {
1065
- deferred[ handler ]( newDefer[ action ] );
1066
- }
1067
- });
1068
- }).promise();
1069
- },
1070
- // Get a promise for this deferred
1071
- // If obj is provided, the promise aspect is added to the object
1072
- promise: function( obj ) {
1073
- if ( obj == null ) {
1074
- if ( promise ) {
1075
- return promise;
1076
- }
1077
- promise = obj = {};
1078
- }
1079
- var i = promiseMethods.length;
1080
- while( i-- ) {
1081
- obj[ promiseMethods[i] ] = deferred[ promiseMethods[i] ];
1082
- }
1083
- return obj;
1084
- }
1085
- });
1086
- // Make sure only one callback list will be used
1087
- deferred.done( failDeferred.cancel ).fail( deferred.cancel );
1088
- // Unexpose cancel
1089
- delete deferred.cancel;
1090
- // Call given func if any
1091
- if ( func ) {
1092
- func.call( deferred, deferred );
1093
- }
1094
- return deferred;
1095
- },
1096
-
1097
- // Deferred helper
1098
- when: function( firstParam ) {
1099
- var args = arguments,
1100
- i = 0,
1101
- length = args.length,
1102
- count = length,
1103
- deferred = length <= 1 && firstParam && jQuery.isFunction( firstParam.promise ) ?
1104
- firstParam :
1105
- jQuery.Deferred();
1106
- function resolveFunc( i ) {
1107
- return function( value ) {
1108
- args[ i ] = arguments.length > 1 ? sliceDeferred.call( arguments, 0 ) : value;
1109
- if ( !( --count ) ) {
1110
- // Strange bug in FF4:
1111
- // Values changed onto the arguments object sometimes end up as undefined values
1112
- // outside the $.when method. Cloning the object into a fresh array solves the issue
1113
- deferred.resolveWith( deferred, sliceDeferred.call( args, 0 ) );
1114
- }
1115
- };
1116
- }
1117
- if ( length > 1 ) {
1118
- for( ; i < length; i++ ) {
1119
- if ( args[ i ] && jQuery.isFunction( args[ i ].promise ) ) {
1120
- args[ i ].promise().then( resolveFunc(i), deferred.reject );
1121
- } else {
1122
- --count;
1123
- }
1124
- }
1125
- if ( !count ) {
1126
- deferred.resolveWith( deferred, args );
1127
- }
1128
- } else if ( deferred !== firstParam ) {
1129
- deferred.resolveWith( deferred, length ? [ firstParam ] : [] );
1130
- }
1131
- return deferred.promise();
1132
- }
1133
- });
1134
-
1135
-
1136
-
1137
- jQuery.support = (function() {
1138
-
1139
- var div = document.createElement( "div" ),
1140
- documentElement = document.documentElement,
1141
- all,
1142
- a,
1143
- select,
1144
- opt,
1145
- input,
1146
- marginDiv,
1147
- support,
1148
- fragment,
1149
- body,
1150
- bodyStyle,
1151
- tds,
1152
- events,
1153
- eventName,
1154
- i,
1155
- isSupported;
1156
-
1157
- // Preliminary tests
1158
- div.setAttribute("className", "t");
1159
- div.innerHTML = " <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>";
1160
-
1161
- all = div.getElementsByTagName( "*" );
1162
- a = div.getElementsByTagName( "a" )[ 0 ];
1163
-
1164
- // Can't get basic test support
1165
- if ( !all || !all.length || !a ) {
1166
- return {};
1167
- }
1168
-
1169
- // First batch of supports tests
1170
- select = document.createElement( "select" );
1171
- opt = select.appendChild( document.createElement("option") );
1172
- input = div.getElementsByTagName( "input" )[ 0 ];
1173
-
1174
- support = {
1175
- // IE strips leading whitespace when .innerHTML is used
1176
- leadingWhitespace: ( div.firstChild.nodeType === 3 ),
1177
-
1178
- // Make sure that tbody elements aren't automatically inserted
1179
- // IE will insert them into empty tables
1180
- tbody: !div.getElementsByTagName( "tbody" ).length,
1181
-
1182
- // Make sure that link elements get serialized correctly by innerHTML
1183
- // This requires a wrapper element in IE
1184
- htmlSerialize: !!div.getElementsByTagName( "link" ).length,
1185
-
1186
- // Get the style information from getAttribute
1187
- // (IE uses .cssText instead)
1188
- style: /top/.test( a.getAttribute("style") ),
1189
-
1190
- // Make sure that URLs aren't manipulated
1191
- // (IE normalizes it by default)
1192
- hrefNormalized: ( a.getAttribute( "href" ) === "/a" ),
1193
-
1194
- // Make sure that element opacity exists
1195
- // (IE uses filter instead)
1196
- // Use a regex to work around a WebKit issue. See #5145
1197
- opacity: /^0.55$/.test( a.style.opacity ),
1198
-
1199
- // Verify style float existence
1200
- // (IE uses styleFloat instead of cssFloat)
1201
- cssFloat: !!a.style.cssFloat,
1202
-
1203
- // Make sure that if no value is specified for a checkbox
1204
- // that it defaults to "on".
1205
- // (WebKit defaults to "" instead)
1206
- checkOn: ( input.value === "on" ),
1207
-
1208
- // Make sure that a selected-by-default option has a working selected property.
1209
- // (WebKit defaults to false instead of true, IE too, if it's in an optgroup)
1210
- optSelected: opt.selected,
1211
-
1212
- // Test setAttribute on camelCase class. If it works, we need attrFixes when doing get/setAttribute (ie6/7)
1213
- getSetAttribute: div.className !== "t",
1214
-
1215
- // Will be defined later
1216
- submitBubbles: true,
1217
- changeBubbles: true,
1218
- focusinBubbles: false,
1219
- deleteExpando: true,
1220
- noCloneEvent: true,
1221
- inlineBlockNeedsLayout: false,
1222
- shrinkWrapBlocks: false,
1223
- reliableMarginRight: true
1224
- };
1225
-
1226
- // Make sure checked status is properly cloned
1227
- input.checked = true;
1228
- support.noCloneChecked = input.cloneNode( true ).checked;
1229
-
1230
- // Make sure that the options inside disabled selects aren't marked as disabled
1231
- // (WebKit marks them as disabled)
1232
- select.disabled = true;
1233
- support.optDisabled = !opt.disabled;
1234
-
1235
- // Test to see if it's possible to delete an expando from an element
1236
- // Fails in Internet Explorer
1237
- try {
1238
- delete div.test;
1239
- } catch( e ) {
1240
- support.deleteExpando = false;
1241
- }
1242
-
1243
- if ( !div.addEventListener && div.attachEvent && div.fireEvent ) {
1244
- div.attachEvent( "onclick", function click() {
1245
- // Cloning a node shouldn't copy over any
1246
- // bound event handlers (IE does this)
1247
- support.noCloneEvent = false;
1248
- div.detachEvent( "onclick", click );
1249
- });
1250
- div.cloneNode( true ).fireEvent( "onclick" );
1251
- }
1252
-
1253
- // Check if a radio maintains it's value
1254
- // after being appended to the DOM
1255
- input = document.createElement("input");
1256
- input.value = "t";
1257
- input.setAttribute("type", "radio");
1258
- support.radioValue = input.value === "t";
1259
-
1260
- input.setAttribute("checked", "checked");
1261
- div.appendChild( input );
1262
- fragment = document.createDocumentFragment();
1263
- fragment.appendChild( div.firstChild );
1264
-
1265
- // WebKit doesn't clone checked state correctly in fragments
1266
- support.checkClone = fragment.cloneNode( true ).cloneNode( true ).lastChild.checked;
1267
-
1268
- div.innerHTML = "";
1269
-
1270
- // Figure out if the W3C box model works as expected
1271
- div.style.width = div.style.paddingLeft = "1px";
1272
-
1273
- // We use our own, invisible, body
1274
- body = document.createElement( "body" );
1275
- bodyStyle = {
1276
- visibility: "hidden",
1277
- width: 0,
1278
- height: 0,
1279
- border: 0,
1280
- margin: 0,
1281
- // Set background to avoid IE crashes when removing (#9028)
1282
- background: "none"
1283
- };
1284
- for ( i in bodyStyle ) {
1285
- body.style[ i ] = bodyStyle[ i ];
1286
- }
1287
- body.appendChild( div );
1288
- documentElement.insertBefore( body, documentElement.firstChild );
1289
-
1290
- // Check if a disconnected checkbox will retain its checked
1291
- // value of true after appended to the DOM (IE6/7)
1292
- support.appendChecked = input.checked;
1293
-
1294
- support.boxModel = div.offsetWidth === 2;
1295
-
1296
- if ( "zoom" in div.style ) {
1297
- // Check if natively block-level elements act like inline-block
1298
- // elements when setting their display to 'inline' and giving
1299
- // them layout
1300
- // (IE < 8 does this)
1301
- div.style.display = "inline";
1302
- div.style.zoom = 1;
1303
- support.inlineBlockNeedsLayout = ( div.offsetWidth === 2 );
1304
-
1305
- // Check if elements with layout shrink-wrap their children
1306
- // (IE 6 does this)
1307
- div.style.display = "";
1308
- div.innerHTML = "<div style='width:4px;'></div>";
1309
- support.shrinkWrapBlocks = ( div.offsetWidth !== 2 );
1310
- }
1311
-
1312
- div.innerHTML = "<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>";
1313
- tds = div.getElementsByTagName( "td" );
1314
-
1315
- // Check if table cells still have offsetWidth/Height when they are set
1316
- // to display:none and there are still other visible table cells in a
1317
- // table row; if so, offsetWidth/Height are not reliable for use when
1318
- // determining if an element has been hidden directly using
1319
- // display:none (it is still safe to use offsets if a parent element is
1320
- // hidden; don safety goggles and see bug #4512 for more information).
1321
- // (only IE 8 fails this test)
1322
- isSupported = ( tds[ 0 ].offsetHeight === 0 );
1323
-
1324
- tds[ 0 ].style.display = "";
1325
- tds[ 1 ].style.display = "none";
1326
-
1327
- // Check if empty table cells still have offsetWidth/Height
1328
- // (IE < 8 fail this test)
1329
- support.reliableHiddenOffsets = isSupported && ( tds[ 0 ].offsetHeight === 0 );
1330
- div.innerHTML = "";
1331
-
1332
- // Check if div with explicit width and no margin-right incorrectly
1333
- // gets computed margin-right based on width of container. For more
1334
- // info see bug #3333
1335
- // Fails in WebKit before Feb 2011 nightlies
1336
- // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right
1337
- if ( document.defaultView && document.defaultView.getComputedStyle ) {
1338
- marginDiv = document.createElement( "div" );
1339
- marginDiv.style.width = "0";
1340
- marginDiv.style.marginRight = "0";
1341
- div.appendChild( marginDiv );
1342
- support.reliableMarginRight =
1343
- ( parseInt( ( document.defaultView.getComputedStyle( marginDiv, null ) || { marginRight: 0 } ).marginRight, 10 ) || 0 ) === 0;
1344
- }
1345
-
1346
- // Remove the body element we added
1347
- body.innerHTML = "";
1348
- documentElement.removeChild( body );
1349
-
1350
- // Technique from Juriy Zaytsev
1351
- // http://thinkweb2.com/projects/prototype/detecting-event-support-without-browser-sniffing/
1352
- // We only care about the case where non-standard event systems
1353
- // are used, namely in IE. Short-circuiting here helps us to
1354
- // avoid an eval call (in setAttribute) which can cause CSP
1355
- // to go haywire. See: https://developer.mozilla.org/en/Security/CSP
1356
- if ( div.attachEvent ) {
1357
- for( i in {
1358
- submit: 1,
1359
- change: 1,
1360
- focusin: 1
1361
- } ) {
1362
- eventName = "on" + i;
1363
- isSupported = ( eventName in div );
1364
- if ( !isSupported ) {
1365
- div.setAttribute( eventName, "return;" );
1366
- isSupported = ( typeof div[ eventName ] === "function" );
1367
- }
1368
- support[ i + "Bubbles" ] = isSupported;
1369
- }
1370
- }
1371
-
1372
- return support;
1373
- })();
1374
-
1375
- // Keep track of boxModel
1376
- jQuery.boxModel = jQuery.support.boxModel;
1377
-
1378
-
1379
-
1380
-
1381
- var rbrace = /^(?:\{.*\}|\[.*\])$/,
1382
- rmultiDash = /([a-z])([A-Z])/g;
1383
-
1384
- jQuery.extend({
1385
- cache: {},
1386
-
1387
- // Please use with caution
1388
- uuid: 0,
1389
-
1390
- // Unique for each copy of jQuery on the page
1391
- // Non-digits removed to match rinlinejQuery
1392
- expando: "jQuery" + ( jQuery.fn.jquery + Math.random() ).replace( /\D/g, "" ),
1393
-
1394
- // The following elements throw uncatchable exceptions if you
1395
- // attempt to add expando properties to them.
1396
- noData: {
1397
- "embed": true,
1398
- // Ban all objects except for Flash (which handle expandos)
1399
- "object": "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",
1400
- "applet": true
1401
- },
1402
-
1403
- hasData: function( elem ) {
1404
- elem = elem.nodeType ? jQuery.cache[ elem[jQuery.expando] ] : elem[ jQuery.expando ];
1405
-
1406
- return !!elem && !isEmptyDataObject( elem );
1407
- },
1408
-
1409
- data: function( elem, name, data, pvt /* Internal Use Only */ ) {
1410
- if ( !jQuery.acceptData( elem ) ) {
1411
- return;
1412
- }
1413
-
1414
- var internalKey = jQuery.expando, getByName = typeof name === "string", thisCache,
1415
-
1416
- // We have to handle DOM nodes and JS objects differently because IE6-7
1417
- // can't GC object references properly across the DOM-JS boundary
1418
- isNode = elem.nodeType,
1419
-
1420
- // Only DOM nodes need the global jQuery cache; JS object data is
1421
- // attached directly to the object so GC can occur automatically
1422
- cache = isNode ? jQuery.cache : elem,
1423
-
1424
- // Only defining an ID for JS objects if its cache already exists allows
1425
- // the code to shortcut on the same path as a DOM node with no cache
1426
- id = isNode ? elem[ jQuery.expando ] : elem[ jQuery.expando ] && jQuery.expando;
1427
-
1428
- // Avoid doing any more work than we need to when trying to get data on an
1429
- // object that has no data at all
1430
- if ( (!id || (pvt && id && !cache[ id ][ internalKey ])) && getByName && data === undefined ) {
1431
- return;
1432
- }
1433
-
1434
- if ( !id ) {
1435
- // Only DOM nodes need a new unique ID for each element since their data
1436
- // ends up in the global cache
1437
- if ( isNode ) {
1438
- elem[ jQuery.expando ] = id = ++jQuery.uuid;
1439
- } else {
1440
- id = jQuery.expando;
1441
- }
1442
- }
1443
-
1444
- if ( !cache[ id ] ) {
1445
- cache[ id ] = {};
1446
-
1447
- // TODO: This is a hack for 1.5 ONLY. Avoids exposing jQuery
1448
- // metadata on plain JS objects when the object is serialized using
1449
- // JSON.stringify
1450
- if ( !isNode ) {
1451
- cache[ id ].toJSON = jQuery.noop;
1452
- }
1453
- }
1454
-
1455
- // An object can be passed to jQuery.data instead of a key/value pair; this gets
1456
- // shallow copied over onto the existing cache
1457
- if ( typeof name === "object" || typeof name === "function" ) {
1458
- if ( pvt ) {
1459
- cache[ id ][ internalKey ] = jQuery.extend(cache[ id ][ internalKey ], name);
1460
- } else {
1461
- cache[ id ] = jQuery.extend(cache[ id ], name);
1462
- }
1463
- }
1464
-
1465
- thisCache = cache[ id ];
1466
-
1467
- // Internal jQuery data is stored in a separate object inside the object's data
1468
- // cache in order to avoid key collisions between internal data and user-defined
1469
- // data
1470
- if ( pvt ) {
1471
- if ( !thisCache[ internalKey ] ) {
1472
- thisCache[ internalKey ] = {};
1473
- }
1474
-
1475
- thisCache = thisCache[ internalKey ];
1476
- }
1477
-
1478
- if ( data !== undefined ) {
1479
- thisCache[ jQuery.camelCase( name ) ] = data;
1480
- }
1481
-
1482
- // TODO: This is a hack for 1.5 ONLY. It will be removed in 1.6. Users should
1483
- // not attempt to inspect the internal events object using jQuery.data, as this
1484
- // internal data object is undocumented and subject to change.
1485
- if ( name === "events" && !thisCache[name] ) {
1486
- return thisCache[ internalKey ] && thisCache[ internalKey ].events;
1487
- }
1488
-
1489
- return getByName ? thisCache[ jQuery.camelCase( name ) ] : thisCache;
1490
- },
1491
-
1492
- removeData: function( elem, name, pvt /* Internal Use Only */ ) {
1493
- if ( !jQuery.acceptData( elem ) ) {
1494
- return;
1495
- }
1496
-
1497
- var internalKey = jQuery.expando, isNode = elem.nodeType,
1498
-
1499
- // See jQuery.data for more information
1500
- cache = isNode ? jQuery.cache : elem,
1501
-
1502
- // See jQuery.data for more information
1503
- id = isNode ? elem[ jQuery.expando ] : jQuery.expando;
1504
-
1505
- // If there is already no cache entry for this object, there is no
1506
- // purpose in continuing
1507
- if ( !cache[ id ] ) {
1508
- return;
1509
- }
1510
-
1511
- if ( name ) {
1512
- var thisCache = pvt ? cache[ id ][ internalKey ] : cache[ id ];
1513
-
1514
- if ( thisCache ) {
1515
- delete thisCache[ name ];
1516
-
1517
- // If there is no data left in the cache, we want to continue
1518
- // and let the cache object itself get destroyed
1519
- if ( !isEmptyDataObject(thisCache) ) {
1520
- return;
1521
- }
1522
- }
1523
- }
1524
-
1525
- // See jQuery.data for more information
1526
- if ( pvt ) {
1527
- delete cache[ id ][ internalKey ];
1528
-
1529
- // Don't destroy the parent cache unless the internal data object
1530
- // had been the only thing left in it
1531
- if ( !isEmptyDataObject(cache[ id ]) ) {
1532
- return;
1533
- }
1534
- }
1535
-
1536
- var internalCache = cache[ id ][ internalKey ];
1537
-
1538
- // Browsers that fail expando deletion also refuse to delete expandos on
1539
- // the window, but it will allow it on all other JS objects; other browsers
1540
- // don't care
1541
- if ( jQuery.support.deleteExpando || cache != window ) {
1542
- delete cache[ id ];
1543
- } else {
1544
- cache[ id ] = null;
1545
- }
1546
-
1547
- // We destroyed the entire user cache at once because it's faster than
1548
- // iterating through each key, but we need to continue to persist internal
1549
- // data if it existed
1550
- if ( internalCache ) {
1551
- cache[ id ] = {};
1552
- // TODO: This is a hack for 1.5 ONLY. Avoids exposing jQuery
1553
- // metadata on plain JS objects when the object is serialized using
1554
- // JSON.stringify
1555
- if ( !isNode ) {
1556
- cache[ id ].toJSON = jQuery.noop;
1557
- }
1558
-
1559
- cache[ id ][ internalKey ] = internalCache;
1560
-
1561
- // Otherwise, we need to eliminate the expando on the node to avoid
1562
- // false lookups in the cache for entries that no longer exist
1563
- } else if ( isNode ) {
1564
- // IE does not allow us to delete expando properties from nodes,
1565
- // nor does it have a removeAttribute function on Document nodes;
1566
- // we must handle all of these cases
1567
- if ( jQuery.support.deleteExpando ) {
1568
- delete elem[ jQuery.expando ];
1569
- } else if ( elem.removeAttribute ) {
1570
- elem.removeAttribute( jQuery.expando );
1571
- } else {
1572
- elem[ jQuery.expando ] = null;
1573
- }
1574
- }
1575
- },
1576
-
1577
- // For internal use only.
1578
- _data: function( elem, name, data ) {
1579
- return jQuery.data( elem, name, data, true );
1580
- },
1581
-
1582
- // A method for determining if a DOM node can handle the data expando
1583
- acceptData: function( elem ) {
1584
- if ( elem.nodeName ) {
1585
- var match = jQuery.noData[ elem.nodeName.toLowerCase() ];
1586
-
1587
- if ( match ) {
1588
- return !(match === true || elem.getAttribute("classid") !== match);
1589
- }
1590
- }
1591
-
1592
- return true;
1593
- }
1594
- });
1595
-
1596
- jQuery.fn.extend({
1597
- data: function( key, value ) {
1598
- var data = null;
1599
-
1600
- if ( typeof key === "undefined" ) {
1601
- if ( this.length ) {
1602
- data = jQuery.data( this[0] );
1603
-
1604
- if ( this[0].nodeType === 1 ) {
1605
- var attr = this[0].attributes, name;
1606
- for ( var i = 0, l = attr.length; i < l; i++ ) {
1607
- name = attr[i].name;
1608
-
1609
- if ( name.indexOf( "data-" ) === 0 ) {
1610
- name = jQuery.camelCase( name.substring(5) );
1611
-
1612
- dataAttr( this[0], name, data[ name ] );
1613
- }
1614
- }
1615
- }
1616
- }
1617
-
1618
- return data;
1619
-
1620
- } else if ( typeof key === "object" ) {
1621
- return this.each(function() {
1622
- jQuery.data( this, key );
1623
- });
1624
- }
1625
-
1626
- var parts = key.split(".");
1627
- parts[1] = parts[1] ? "." + parts[1] : "";
1628
-
1629
- if ( value === undefined ) {
1630
- data = this.triggerHandler("getData" + parts[1] + "!", [parts[0]]);
1631
-
1632
- // Try to fetch any internally stored data first
1633
- if ( data === undefined && this.length ) {
1634
- data = jQuery.data( this[0], key );
1635
- data = dataAttr( this[0], key, data );
1636
- }
1637
-
1638
- return data === undefined && parts[1] ?
1639
- this.data( parts[0] ) :
1640
- data;
1641
-
1642
- } else {
1643
- return this.each(function() {
1644
- var $this = jQuery( this ),
1645
- args = [ parts[0], value ];
1646
-
1647
- $this.triggerHandler( "setData" + parts[1] + "!", args );
1648
- jQuery.data( this, key, value );
1649
- $this.triggerHandler( "changeData" + parts[1] + "!", args );
1650
- });
1651
- }
1652
- },
1653
-
1654
- removeData: function( key ) {
1655
- return this.each(function() {
1656
- jQuery.removeData( this, key );
1657
- });
1658
- }
1659
- });
1660
-
1661
- function dataAttr( elem, key, data ) {
1662
- // If nothing was found internally, try to fetch any
1663
- // data from the HTML5 data-* attribute
1664
- if ( data === undefined && elem.nodeType === 1 ) {
1665
- var name = "data-" + key.replace( rmultiDash, "$1-$2" ).toLowerCase();
1666
-
1667
- data = elem.getAttribute( name );
1668
-
1669
- if ( typeof data === "string" ) {
1670
- try {
1671
- data = data === "true" ? true :
1672
- data === "false" ? false :
1673
- data === "null" ? null :
1674
- !jQuery.isNaN( data ) ? parseFloat( data ) :
1675
- rbrace.test( data ) ? jQuery.parseJSON( data ) :
1676
- data;
1677
- } catch( e ) {}
1678
-
1679
- // Make sure we set the data so it isn't changed later
1680
- jQuery.data( elem, key, data );
1681
-
1682
- } else {
1683
- data = undefined;
1684
- }
1685
- }
1686
-
1687
- return data;
1688
- }
1689
-
1690
- // TODO: This is a hack for 1.5 ONLY to allow objects with a single toJSON
1691
- // property to be considered empty objects; this property always exists in
1692
- // order to make sure JSON.stringify does not expose internal metadata
1693
- function isEmptyDataObject( obj ) {
1694
- for ( var name in obj ) {
1695
- if ( name !== "toJSON" ) {
1696
- return false;
1697
- }
1698
- }
1699
-
1700
- return true;
1701
- }
1702
-
1703
-
1704
-
1705
-
1706
- function handleQueueMarkDefer( elem, type, src ) {
1707
- var deferDataKey = type + "defer",
1708
- queueDataKey = type + "queue",
1709
- markDataKey = type + "mark",
1710
- defer = jQuery.data( elem, deferDataKey, undefined, true );
1711
- if ( defer &&
1712
- ( src === "queue" || !jQuery.data( elem, queueDataKey, undefined, true ) ) &&
1713
- ( src === "mark" || !jQuery.data( elem, markDataKey, undefined, true ) ) ) {
1714
- // Give room for hard-coded callbacks to fire first
1715
- // and eventually mark/queue something else on the element
1716
- setTimeout( function() {
1717
- if ( !jQuery.data( elem, queueDataKey, undefined, true ) &&
1718
- !jQuery.data( elem, markDataKey, undefined, true ) ) {
1719
- jQuery.removeData( elem, deferDataKey, true );
1720
- defer.resolve();
1721
- }
1722
- }, 0 );
1723
- }
1724
- }
1725
-
1726
- jQuery.extend({
1727
-
1728
- _mark: function( elem, type ) {
1729
- if ( elem ) {
1730
- type = (type || "fx") + "mark";
1731
- jQuery.data( elem, type, (jQuery.data(elem,type,undefined,true) || 0) + 1, true );
1732
- }
1733
- },
1734
-
1735
- _unmark: function( force, elem, type ) {
1736
- if ( force !== true ) {
1737
- type = elem;
1738
- elem = force;
1739
- force = false;
1740
- }
1741
- if ( elem ) {
1742
- type = type || "fx";
1743
- var key = type + "mark",
1744
- count = force ? 0 : ( (jQuery.data( elem, key, undefined, true) || 1 ) - 1 );
1745
- if ( count ) {
1746
- jQuery.data( elem, key, count, true );
1747
- } else {
1748
- jQuery.removeData( elem, key, true );
1749
- handleQueueMarkDefer( elem, type, "mark" );
1750
- }
1751
- }
1752
- },
1753
-
1754
- queue: function( elem, type, data ) {
1755
- if ( elem ) {
1756
- type = (type || "fx") + "queue";
1757
- var q = jQuery.data( elem, type, undefined, true );
1758
- // Speed up dequeue by getting out quickly if this is just a lookup
1759
- if ( data ) {
1760
- if ( !q || jQuery.isArray(data) ) {
1761
- q = jQuery.data( elem, type, jQuery.makeArray(data), true );
1762
- } else {
1763
- q.push( data );
1764
- }
1765
- }
1766
- return q || [];
1767
- }
1768
- },
1769
-
1770
- dequeue: function( elem, type ) {
1771
- type = type || "fx";
1772
-
1773
- var queue = jQuery.queue( elem, type ),
1774
- fn = queue.shift(),
1775
- defer;
1776
-
1777
- // If the fx queue is dequeued, always remove the progress sentinel
1778
- if ( fn === "inprogress" ) {
1779
- fn = queue.shift();
1780
- }
1781
-
1782
- if ( fn ) {
1783
- // Add a progress sentinel to prevent the fx queue from being
1784
- // automatically dequeued
1785
- if ( type === "fx" ) {
1786
- queue.unshift("inprogress");
1787
- }
1788
-
1789
- fn.call(elem, function() {
1790
- jQuery.dequeue(elem, type);
1791
- });
1792
- }
1793
-
1794
- if ( !queue.length ) {
1795
- jQuery.removeData( elem, type + "queue", true );
1796
- handleQueueMarkDefer( elem, type, "queue" );
1797
- }
1798
- }
1799
- });
1800
-
1801
- jQuery.fn.extend({
1802
- queue: function( type, data ) {
1803
- if ( typeof type !== "string" ) {
1804
- data = type;
1805
- type = "fx";
1806
- }
1807
-
1808
- if ( data === undefined ) {
1809
- return jQuery.queue( this[0], type );
1810
- }
1811
- return this.each(function() {
1812
- var queue = jQuery.queue( this, type, data );
1813
-
1814
- if ( type === "fx" && queue[0] !== "inprogress" ) {
1815
- jQuery.dequeue( this, type );
1816
- }
1817
- });
1818
- },
1819
- dequeue: function( type ) {
1820
- return this.each(function() {
1821
- jQuery.dequeue( this, type );
1822
- });
1823
- },
1824
- // Based off of the plugin by Clint Helfers, with permission.
1825
- // http://blindsignals.com/index.php/2009/07/jquery-delay/
1826
- delay: function( time, type ) {
1827
- time = jQuery.fx ? jQuery.fx.speeds[time] || time : time;
1828
- type = type || "fx";
1829
-
1830
- return this.queue( type, function() {
1831
- var elem = this;
1832
- setTimeout(function() {
1833
- jQuery.dequeue( elem, type );
1834
- }, time );
1835
- });
1836
- },
1837
- clearQueue: function( type ) {
1838
- return this.queue( type || "fx", [] );
1839
- },
1840
- // Get a promise resolved when queues of a certain type
1841
- // are emptied (fx is the type by default)
1842
- promise: function( type, object ) {
1843
- if ( typeof type !== "string" ) {
1844
- object = type;
1845
- type = undefined;
1846
- }
1847
- type = type || "fx";
1848
- var defer = jQuery.Deferred(),
1849
- elements = this,
1850
- i = elements.length,
1851
- count = 1,
1852
- deferDataKey = type + "defer",
1853
- queueDataKey = type + "queue",
1854
- markDataKey = type + "mark",
1855
- tmp;
1856
- function resolve() {
1857
- if ( !( --count ) ) {
1858
- defer.resolveWith( elements, [ elements ] );
1859
- }
1860
- }
1861
- while( i-- ) {
1862
- if (( tmp = jQuery.data( elements[ i ], deferDataKey, undefined, true ) ||
1863
- ( jQuery.data( elements[ i ], queueDataKey, undefined, true ) ||
1864
- jQuery.data( elements[ i ], markDataKey, undefined, true ) ) &&
1865
- jQuery.data( elements[ i ], deferDataKey, jQuery._Deferred(), true ) )) {
1866
- count++;
1867
- tmp.done( resolve );
1868
- }
1869
- }
1870
- resolve();
1871
- return defer.promise();
1872
- }
1873
- });
1874
-
1875
-
1876
-
1877
-
1878
- var rclass = /[\n\t\r]/g,
1879
- rspace = /\s+/,
1880
- rreturn = /\r/g,
1881
- rtype = /^(?:button|input)$/i,
1882
- rfocusable = /^(?:button|input|object|select|textarea)$/i,
1883
- rclickable = /^a(?:rea)?$/i,
1884
- rboolean = /^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,
1885
- rinvalidChar = /\:/,
1886
- formHook, boolHook;
1887
-
1888
- jQuery.fn.extend({
1889
- attr: function( name, value ) {
1890
- return jQuery.access( this, name, value, true, jQuery.attr );
1891
- },
1892
-
1893
- removeAttr: function( name ) {
1894
- return this.each(function() {
1895
- jQuery.removeAttr( this, name );
1896
- });
1897
- },
1898
-
1899
- prop: function( name, value ) {
1900
- return jQuery.access( this, name, value, true, jQuery.prop );
1901
- },
1902
-
1903
- removeProp: function( name ) {
1904
- name = jQuery.propFix[ name ] || name;
1905
- return this.each(function() {
1906
- // try/catch handles cases where IE balks (such as removing a property on window)
1907
- try {
1908
- this[ name ] = undefined;
1909
- delete this[ name ];
1910
- } catch( e ) {}
1911
- });
1912
- },
1913
-
1914
- addClass: function( value ) {
1915
- if ( jQuery.isFunction( value ) ) {
1916
- return this.each(function(i) {
1917
- var self = jQuery(this);
1918
- self.addClass( value.call(this, i, self.attr("class") || "") );
1919
- });
1920
- }
1921
-
1922
- if ( value && typeof value === "string" ) {
1923
- var classNames = (value || "").split( rspace );
1924
-
1925
- for ( var i = 0, l = this.length; i < l; i++ ) {
1926
- var elem = this[i];
1927
-
1928
- if ( elem.nodeType === 1 ) {
1929
- if ( !elem.className ) {
1930
- elem.className = value;
1931
-
1932
- } else {
1933
- var className = " " + elem.className + " ",
1934
- setClass = elem.className;
1935
-
1936
- for ( var c = 0, cl = classNames.length; c < cl; c++ ) {
1937
- if ( className.indexOf( " " + classNames[c] + " " ) < 0 ) {
1938
- setClass += " " + classNames[c];
1939
- }
1940
- }
1941
- elem.className = jQuery.trim( setClass );
1942
- }
1943
- }
1944
- }
1945
- }
1946
-
1947
- return this;
1948
- },
1949
-
1950
- removeClass: function( value ) {
1951
- if ( jQuery.isFunction(value) ) {
1952
- return this.each(function(i) {
1953
- var self = jQuery(this);
1954
- self.removeClass( value.call(this, i, self.attr("class")) );
1955
- });
1956
- }
1957
-
1958
- if ( (value && typeof value === "string") || value === undefined ) {
1959
- var classNames = (value || "").split( rspace );
1960
-
1961
- for ( var i = 0, l = this.length; i < l; i++ ) {
1962
- var elem = this[i];
1963
-
1964
- if ( elem.nodeType === 1 && elem.className ) {
1965
- if ( value ) {
1966
- var className = (" " + elem.className + " ").replace(rclass, " ");
1967
- for ( var c = 0, cl = classNames.length; c < cl; c++ ) {
1968
- className = className.replace(" " + classNames[c] + " ", " ");
1969
- }
1970
- elem.className = jQuery.trim( className );
1971
-
1972
- } else {
1973
- elem.className = "";
1974
- }
1975
- }
1976
- }
1977
- }
1978
-
1979
- return this;
1980
- },
1981
-
1982
- toggleClass: function( value, stateVal ) {
1983
- var type = typeof value,
1984
- isBool = typeof stateVal === "boolean";
1985
-
1986
- if ( jQuery.isFunction( value ) ) {
1987
- return this.each(function(i) {
1988
- var self = jQuery(this);
1989
- self.toggleClass( value.call(this, i, self.attr("class"), stateVal), stateVal );
1990
- });
1991
- }
1992
-
1993
- return this.each(function() {
1994
- if ( type === "string" ) {
1995
- // toggle individual class names
1996
- var className,
1997
- i = 0,
1998
- self = jQuery( this ),
1999
- state = stateVal,
2000
- classNames = value.split( rspace );
2001
-
2002
- while ( (className = classNames[ i++ ]) ) {
2003
- // check each className given, space seperated list
2004
- state = isBool ? state : !self.hasClass( className );
2005
- self[ state ? "addClass" : "removeClass" ]( className );
2006
- }
2007
-
2008
- } else if ( type === "undefined" || type === "boolean" ) {
2009
- if ( this.className ) {
2010
- // store className if set
2011
- jQuery._data( this, "__className__", this.className );
2012
- }
2013
-
2014
- // toggle whole className
2015
- this.className = this.className || value === false ? "" : jQuery._data( this, "__className__" ) || "";
2016
- }
2017
- });
2018
- },
2019
-
2020
- hasClass: function( selector ) {
2021
- var className = " " + selector + " ";
2022
- for ( var i = 0, l = this.length; i < l; i++ ) {
2023
- if ( (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) > -1 ) {
2024
- return true;
2025
- }
2026
- }
2027
-
2028
- return false;
2029
- },
2030
-
2031
- val: function( value ) {
2032
- var hooks, ret,
2033
- elem = this[0];
2034
-
2035
- if ( !arguments.length ) {
2036
- if ( elem ) {
2037
- hooks = jQuery.valHooks[ elem.nodeName.toLowerCase() ] || jQuery.valHooks[ elem.type ];
2038
-
2039
- if ( hooks && "get" in hooks && (ret = hooks.get( elem, "value" )) !== undefined ) {
2040
- return ret;
2041
- }
2042
-
2043
- return (elem.value || "").replace(rreturn, "");
2044
- }
2045
-
2046
- return undefined;
2047
- }
2048
-
2049
- var isFunction = jQuery.isFunction( value );
2050
-
2051
- return this.each(function( i ) {
2052
- var self = jQuery(this), val;
2053
-
2054
- if ( this.nodeType !== 1 ) {
2055
- return;
2056
- }
2057
-
2058
- if ( isFunction ) {
2059
- val = value.call( this, i, self.val() );
2060
- } else {
2061
- val = value;
2062
- }
2063
-
2064
- // Treat null/undefined as ""; convert numbers to string
2065
- if ( val == null ) {
2066
- val = "";
2067
- } else if ( typeof val === "number" ) {
2068
- val += "";
2069
- } else if ( jQuery.isArray( val ) ) {
2070
- val = jQuery.map(val, function ( value ) {
2071
- return value == null ? "" : value + "";
2072
- });
2073
- }
2074
-
2075
- hooks = jQuery.valHooks[ this.nodeName.toLowerCase() ] || jQuery.valHooks[ this.type ];
2076
-
2077
- // If set returns undefined, fall back to normal setting
2078
- if ( !hooks || !("set" in hooks) || hooks.set( this, val, "value" ) === undefined ) {
2079
- this.value = val;
2080
- }
2081
- });
2082
- }
2083
- });
2084
-
2085
- jQuery.extend({
2086
- valHooks: {
2087
- option: {
2088
- get: function( elem ) {
2089
- // attributes.value is undefined in Blackberry 4.7 but
2090
- // uses .value. See #6932
2091
- var val = elem.attributes.value;
2092
- return !val || val.specified ? elem.value : elem.text;
2093
- }
2094
- },
2095
- select: {
2096
- get: function( elem ) {
2097
- var value,
2098
- index = elem.selectedIndex,
2099
- values = [],
2100
- options = elem.options,
2101
- one = elem.type === "select-one";
2102
-
2103
- // Nothing was selected
2104
- if ( index < 0 ) {
2105
- return null;
2106
- }
2107
-
2108
- // Loop through all the selected options
2109
- for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) {
2110
- var option = options[ i ];
2111
-
2112
- // Don't return options that are disabled or in a disabled optgroup
2113
- if ( option.selected && (jQuery.support.optDisabled ? !option.disabled : option.getAttribute("disabled") === null) &&
2114
- (!option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" )) ) {
2115
-
2116
- // Get the specific value for the option
2117
- value = jQuery( option ).val();
2118
-
2119
- // We don't need an array for one selects
2120
- if ( one ) {
2121
- return value;
2122
- }
2123
-
2124
- // Multi-Selects return an array
2125
- values.push( value );
2126
- }
2127
- }
2128
-
2129
- // Fixes Bug #2551 -- select.val() broken in IE after form.reset()
2130
- if ( one && !values.length && options.length ) {
2131
- return jQuery( options[ index ] ).val();
2132
- }
2133
-
2134
- return values;
2135
- },
2136
-
2137
- set: function( elem, value ) {
2138
- var values = jQuery.makeArray( value );
2139
-
2140
- jQuery(elem).find("option").each(function() {
2141
- this.selected = jQuery.inArray( jQuery(this).val(), values ) >= 0;
2142
- });
2143
-
2144
- if ( !values.length ) {
2145
- elem.selectedIndex = -1;
2146
- }
2147
- return values;
2148
- }
2149
- }
2150
- },
2151
-
2152
- attrFn: {
2153
- val: true,
2154
- css: true,
2155
- html: true,
2156
- text: true,
2157
- data: true,
2158
- width: true,
2159
- height: true,
2160
- offset: true
2161
- },
2162
-
2163
- attrFix: {
2164
- // Always normalize to ensure hook usage
2165
- tabindex: "tabIndex"
2166
- },
2167
-
2168
- attr: function( elem, name, value, pass ) {
2169
- var nType = elem.nodeType;
2170
-
2171
- // don't get/set attributes on text, comment and attribute nodes
2172
- if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {
2173
- return undefined;
2174
- }
2175
-
2176
- if ( pass && name in jQuery.attrFn ) {
2177
- return jQuery( elem )[ name ]( value );
2178
- }
2179
-
2180
- // Fallback to prop when attributes are not supported
2181
- if ( !("getAttribute" in elem) ) {
2182
- return jQuery.prop( elem, name, value );
2183
- }
2184
-
2185
- var ret, hooks,
2186
- notxml = nType !== 1 || !jQuery.isXMLDoc( elem );
2187
-
2188
- // Normalize the name if needed
2189
- name = notxml && jQuery.attrFix[ name ] || name;
2190
-
2191
- hooks = jQuery.attrHooks[ name ];
2192
-
2193
- if ( !hooks ) {
2194
- // Use boolHook for boolean attributes
2195
- if ( rboolean.test( name ) &&
2196
- (typeof value === "boolean" || value === undefined || value.toLowerCase() === name.toLowerCase()) ) {
2197
-
2198
- hooks = boolHook;
2199
-
2200
- // Use formHook for forms and if the name contains certain characters
2201
- } else if ( formHook && (jQuery.nodeName( elem, "form" ) || rinvalidChar.test( name )) ) {
2202
- hooks = formHook;
2203
- }
2204
- }
2205
-
2206
- if ( value !== undefined ) {
2207
-
2208
- if ( value === null ) {
2209
- jQuery.removeAttr( elem, name );
2210
- return undefined;
2211
-
2212
- } else if ( hooks && "set" in hooks && notxml && (ret = hooks.set( elem, value, name )) !== undefined ) {
2213
- return ret;
2214
-
2215
- } else {
2216
- elem.setAttribute( name, "" + value );
2217
- return value;
2218
- }
2219
-
2220
- } else if ( hooks && "get" in hooks && notxml ) {
2221
- return hooks.get( elem, name );
2222
-
2223
- } else {
2224
-
2225
- ret = elem.getAttribute( name );
2226
-
2227
- // Non-existent attributes return null, we normalize to undefined
2228
- return ret === null ?
2229
- undefined :
2230
- ret;
2231
- }
2232
- },
2233
-
2234
- removeAttr: function( elem, name ) {
2235
- var propName;
2236
- if ( elem.nodeType === 1 ) {
2237
- name = jQuery.attrFix[ name ] || name;
2238
-
2239
- if ( jQuery.support.getSetAttribute ) {
2240
- // Use removeAttribute in browsers that support it
2241
- elem.removeAttribute( name );
2242
- } else {
2243
- jQuery.attr( elem, name, "" );
2244
- elem.removeAttributeNode( elem.getAttributeNode( name ) );
2245
- }
2246
-
2247
- // Set corresponding property to false for boolean attributes
2248
- if ( rboolean.test( name ) && (propName = jQuery.propFix[ name ] || name) in elem ) {
2249
- elem[ propName ] = false;
2250
- }
2251
- }
2252
- },
2253
-
2254
- attrHooks: {
2255
- type: {
2256
- set: function( elem, value ) {
2257
- // We can't allow the type property to be changed (since it causes problems in IE)
2258
- if ( rtype.test( elem.nodeName ) && elem.parentNode ) {
2259
- jQuery.error( "type property can't be changed" );
2260
- } else if ( !jQuery.support.radioValue && value === "radio" && jQuery.nodeName(elem, "input") ) {
2261
- // Setting the type on a radio button after the value resets the value in IE6-9
2262
- // Reset value to it's default in case type is set after value
2263
- // This is for element creation
2264
- var val = elem.value;
2265
- elem.setAttribute( "type", value );
2266
- if ( val ) {
2267
- elem.value = val;
2268
- }
2269
- return value;
2270
- }
2271
- }
2272
- },
2273
- tabIndex: {
2274
- get: function( elem ) {
2275
- // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set
2276
- // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/
2277
- var attributeNode = elem.getAttributeNode("tabIndex");
2278
-
2279
- return attributeNode && attributeNode.specified ?
2280
- parseInt( attributeNode.value, 10 ) :
2281
- rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ?
2282
- 0 :
2283
- undefined;
2284
- }
2285
- }
2286
- },
2287
-
2288
- propFix: {
2289
- tabindex: "tabIndex",
2290
- readonly: "readOnly",
2291
- "for": "htmlFor",
2292
- "class": "className",
2293
- maxlength: "maxLength",
2294
- cellspacing: "cellSpacing",
2295
- cellpadding: "cellPadding",
2296
- rowspan: "rowSpan",
2297
- colspan: "colSpan",
2298
- usemap: "useMap",
2299
- frameborder: "frameBorder",
2300
- contenteditable: "contentEditable"
2301
- },
2302
-
2303
- prop: function( elem, name, value ) {
2304
- var nType = elem.nodeType;
2305
-
2306
- // don't get/set properties on text, comment and attribute nodes
2307
- if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {
2308
- return undefined;
2309
- }
2310
-
2311
- var ret, hooks,
2312
- notxml = nType !== 1 || !jQuery.isXMLDoc( elem );
2313
-
2314
- // Try to normalize/fix the name
2315
- name = notxml && jQuery.propFix[ name ] || name;
2316
-
2317
- hooks = jQuery.propHooks[ name ];
2318
-
2319
- if ( value !== undefined ) {
2320
- if ( hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) {
2321
- return ret;
2322
-
2323
- } else {
2324
- return (elem[ name ] = value);
2325
- }
2326
-
2327
- } else {
2328
- if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== undefined ) {
2329
- return ret;
2330
-
2331
- } else {
2332
- return elem[ name ];
2333
- }
2334
- }
2335
- },
2336
-
2337
- propHooks: {}
2338
- });
2339
-
2340
- // Hook for boolean attributes
2341
- boolHook = {
2342
- get: function( elem, name ) {
2343
- // Align boolean attributes with corresponding properties
2344
- return elem[ jQuery.propFix[ name ] || name ] ?
2345
- name.toLowerCase() :
2346
- undefined;
2347
- },
2348
- set: function( elem, value, name ) {
2349
- var propName;
2350
- if ( value === false ) {
2351
- // Remove boolean attributes when set to false
2352
- jQuery.removeAttr( elem, name );
2353
- } else {
2354
- // value is true since we know at this point it's type boolean and not false
2355
- // Set boolean attributes to the same name and set the DOM property
2356
- propName = jQuery.propFix[ name ] || name;
2357
- if ( propName in elem ) {
2358
- // Only set the IDL specifically if it already exists on the element
2359
- elem[ propName ] = value;
2360
- }
2361
-
2362
- elem.setAttribute( name, name.toLowerCase() );
2363
- }
2364
- return name;
2365
- }
2366
- };
2367
-
2368
- // Use the value property for back compat
2369
- // Use the formHook for button elements in IE6/7 (#1954)
2370
- jQuery.attrHooks.value = {
2371
- get: function( elem, name ) {
2372
- if ( formHook && jQuery.nodeName( elem, "button" ) ) {
2373
- return formHook.get( elem, name );
2374
- }
2375
- return elem.value;
2376
- },
2377
- set: function( elem, value, name ) {
2378
- if ( formHook && jQuery.nodeName( elem, "button" ) ) {
2379
- return formHook.set( elem, value, name );
2380
- }
2381
- // Does not return so that setAttribute is also used
2382
- elem.value = value;
2383
- }
2384
- };
2385
-
2386
- // IE6/7 do not support getting/setting some attributes with get/setAttribute
2387
- if ( !jQuery.support.getSetAttribute ) {
2388
-
2389
- // propFix is more comprehensive and contains all fixes
2390
- jQuery.attrFix = jQuery.propFix;
2391
-
2392
- // Use this for any attribute on a form in IE6/7
2393
- formHook = jQuery.attrHooks.name = jQuery.valHooks.button = {
2394
- get: function( elem, name ) {
2395
- var ret;
2396
- ret = elem.getAttributeNode( name );
2397
- // Return undefined if nodeValue is empty string
2398
- return ret && ret.nodeValue !== "" ?
2399
- ret.nodeValue :
2400
- undefined;
2401
- },
2402
- set: function( elem, value, name ) {
2403
- // Check form objects in IE (multiple bugs related)
2404
- // Only use nodeValue if the attribute node exists on the form
2405
- var ret = elem.getAttributeNode( name );
2406
- if ( ret ) {
2407
- ret.nodeValue = value;
2408
- return value;
2409
- }
2410
- }
2411
- };
2412
-
2413
- // Set width and height to auto instead of 0 on empty string( Bug #8150 )
2414
- // This is for removals
2415
- jQuery.each([ "width", "height" ], function( i, name ) {
2416
- jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], {
2417
- set: function( elem, value ) {
2418
- if ( value === "" ) {
2419
- elem.setAttribute( name, "auto" );
2420
- return value;
2421
- }
2422
- }
2423
- });
2424
- });
2425
- }
2426
-
2427
-
2428
- // Some attributes require a special call on IE
2429
- if ( !jQuery.support.hrefNormalized ) {
2430
- jQuery.each([ "href", "src", "width", "height" ], function( i, name ) {
2431
- jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], {
2432
- get: function( elem ) {
2433
- var ret = elem.getAttribute( name, 2 );
2434
- return ret === null ? undefined : ret;
2435
- }
2436
- });
2437
- });
2438
- }
2439
-
2440
- if ( !jQuery.support.style ) {
2441
- jQuery.attrHooks.style = {
2442
- get: function( elem ) {
2443
- // Return undefined in the case of empty string
2444
- // Normalize to lowercase since IE uppercases css property names
2445
- return elem.style.cssText.toLowerCase() || undefined;
2446
- },
2447
- set: function( elem, value ) {
2448
- return (elem.style.cssText = "" + value);
2449
- }
2450
- };
2451
- }
2452
-
2453
- // Safari mis-reports the default selected property of an option
2454
- // Accessing the parent's selectedIndex property fixes it
2455
- if ( !jQuery.support.optSelected ) {
2456
- jQuery.propHooks.selected = jQuery.extend( jQuery.propHooks.selected, {
2457
- get: function( elem ) {
2458
- var parent = elem.parentNode;
2459
-
2460
- if ( parent ) {
2461
- parent.selectedIndex;
2462
-
2463
- // Make sure that it also works with optgroups, see #5701
2464
- if ( parent.parentNode ) {
2465
- parent.parentNode.selectedIndex;
2466
- }
2467
- }
2468
- }
2469
- });
2470
- }
2471
-
2472
- // Radios and checkboxes getter/setter
2473
- if ( !jQuery.support.checkOn ) {
2474
- jQuery.each([ "radio", "checkbox" ], function() {
2475
- jQuery.valHooks[ this ] = {
2476
- get: function( elem ) {
2477
- // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified
2478
- return elem.getAttribute("value") === null ? "on" : elem.value;
2479
- }
2480
- };
2481
- });
2482
- }
2483
- jQuery.each([ "radio", "checkbox" ], function() {
2484
- jQuery.valHooks[ this ] = jQuery.extend( jQuery.valHooks[ this ], {
2485
- set: function( elem, value ) {
2486
- if ( jQuery.isArray( value ) ) {
2487
- return (elem.checked = jQuery.inArray( jQuery(elem).val(), value ) >= 0);
2488
- }
2489
- }
2490
- });
2491
- });
2492
-
2493
-
2494
-
2495
-
2496
- var hasOwn = Object.prototype.hasOwnProperty,
2497
- rnamespaces = /\.(.*)$/,
2498
- rformElems = /^(?:textarea|input|select)$/i,
2499
- rperiod = /\./g,
2500
- rspaces = / /g,
2501
- rescape = /[^\w\s.|`]/g,
2502
- fcleanup = function( nm ) {
2503
- return nm.replace(rescape, "\\$&");
2504
- };
2505
-
2506
- /*
2507
- * A number of helper functions used for managing events.
2508
- * Many of the ideas behind this code originated from
2509
- * Dean Edwards' addEvent library.
2510
- */
2511
- jQuery.event = {
2512
-
2513
- // Bind an event to an element
2514
- // Original by Dean Edwards
2515
- add: function( elem, types, handler, data ) {
2516
- if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
2517
- return;
2518
- }
2519
-
2520
- if ( handler === false ) {
2521
- handler = returnFalse;
2522
- } else if ( !handler ) {
2523
- // Fixes bug #7229. Fix recommended by jdalton
2524
- return;
2525
- }
2526
-
2527
- var handleObjIn, handleObj;
2528
-
2529
- if ( handler.handler ) {
2530
- handleObjIn = handler;
2531
- handler = handleObjIn.handler;
2532
- }
2533
-
2534
- // Make sure that the function being executed has a unique ID
2535
- if ( !handler.guid ) {
2536
- handler.guid = jQuery.guid++;
2537
- }
2538
-
2539
- // Init the element's event structure
2540
- var elemData = jQuery._data( elem );
2541
-
2542
- // If no elemData is found then we must be trying to bind to one of the
2543
- // banned noData elements
2544
- if ( !elemData ) {
2545
- return;
2546
- }
2547
-
2548
- var events = elemData.events,
2549
- eventHandle = elemData.handle;
2550
-
2551
- if ( !events ) {
2552
- elemData.events = events = {};
2553
- }
2554
-
2555
- if ( !eventHandle ) {
2556
- elemData.handle = eventHandle = function( e ) {
2557
- // Discard the second event of a jQuery.event.trigger() and
2558
- // when an event is called after a page has unloaded
2559
- return typeof jQuery !== "undefined" && (!e || jQuery.event.triggered !== e.type) ?
2560
- jQuery.event.handle.apply( eventHandle.elem, arguments ) :
2561
- undefined;
2562
- };
2563
- }
2564
-
2565
- // Add elem as a property of the handle function
2566
- // This is to prevent a memory leak with non-native events in IE.
2567
- eventHandle.elem = elem;
2568
-
2569
- // Handle multiple events separated by a space
2570
- // jQuery(...).bind("mouseover mouseout", fn);
2571
- types = types.split(" ");
2572
-
2573
- var type, i = 0, namespaces;
2574
-
2575
- while ( (type = types[ i++ ]) ) {
2576
- handleObj = handleObjIn ?
2577
- jQuery.extend({}, handleObjIn) :
2578
- { handler: handler, data: data };
2579
-
2580
- // Namespaced event handlers
2581
- if ( type.indexOf(".") > -1 ) {
2582
- namespaces = type.split(".");
2583
- type = namespaces.shift();
2584
- handleObj.namespace = namespaces.slice(0).sort().join(".");
2585
-
2586
- } else {
2587
- namespaces = [];
2588
- handleObj.namespace = "";
2589
- }
2590
-
2591
- handleObj.type = type;
2592
- if ( !handleObj.guid ) {
2593
- handleObj.guid = handler.guid;
2594
- }
2595
-
2596
- // Get the current list of functions bound to this event
2597
- var handlers = events[ type ],
2598
- special = jQuery.event.special[ type ] || {};
2599
-
2600
- // Init the event handler queue
2601
- if ( !handlers ) {
2602
- handlers = events[ type ] = [];
2603
-
2604
- // Check for a special event handler
2605
- // Only use addEventListener/attachEvent if the special
2606
- // events handler returns false
2607
- if ( !special.setup || special.setup.call( elem, data, namespaces, eventHandle ) === false ) {
2608
- // Bind the global event handler to the element
2609
- if ( elem.addEventListener ) {
2610
- elem.addEventListener( type, eventHandle, false );
2611
-
2612
- } else if ( elem.attachEvent ) {
2613
- elem.attachEvent( "on" + type, eventHandle );
2614
- }
2615
- }
2616
- }
2617
-
2618
- if ( special.add ) {
2619
- special.add.call( elem, handleObj );
2620
-
2621
- if ( !handleObj.handler.guid ) {
2622
- handleObj.handler.guid = handler.guid;
2623
- }
2624
- }
2625
-
2626
- // Add the function to the element's handler list
2627
- handlers.push( handleObj );
2628
-
2629
- // Keep track of which events have been used, for event optimization
2630
- jQuery.event.global[ type ] = true;
2631
- }
2632
-
2633
- // Nullify elem to prevent memory leaks in IE
2634
- elem = null;
2635
- },
2636
-
2637
- global: {},
2638
-
2639
- // Detach an event or set of events from an element
2640
- remove: function( elem, types, handler, pos ) {
2641
- // don't do events on text and comment nodes
2642
- if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
2643
- return;
2644
- }
2645
-
2646
- if ( handler === false ) {
2647
- handler = returnFalse;
2648
- }
2649
-
2650
- var ret, type, fn, j, i = 0, all, namespaces, namespace, special, eventType, handleObj, origType,
2651
- elemData = jQuery.hasData( elem ) && jQuery._data( elem ),
2652
- events = elemData && elemData.events;
2653
-
2654
- if ( !elemData || !events ) {
2655
- return;
2656
- }
2657
-
2658
- // types is actually an event object here
2659
- if ( types && types.type ) {
2660
- handler = types.handler;
2661
- types = types.type;
2662
- }
2663
-
2664
- // Unbind all events for the element
2665
- if ( !types || typeof types === "string" && types.charAt(0) === "." ) {
2666
- types = types || "";
2667
-
2668
- for ( type in events ) {
2669
- jQuery.event.remove( elem, type + types );
2670
- }
2671
-
2672
- return;
2673
- }
2674
-
2675
- // Handle multiple events separated by a space
2676
- // jQuery(...).unbind("mouseover mouseout", fn);
2677
- types = types.split(" ");
2678
-
2679
- while ( (type = types[ i++ ]) ) {
2680
- origType = type;
2681
- handleObj = null;
2682
- all = type.indexOf(".") < 0;
2683
- namespaces = [];
2684
-
2685
- if ( !all ) {
2686
- // Namespaced event handlers
2687
- namespaces = type.split(".");
2688
- type = namespaces.shift();
2689
-
2690
- namespace = new RegExp("(^|\\.)" +
2691
- jQuery.map( namespaces.slice(0).sort(), fcleanup ).join("\\.(?:.*\\.)?") + "(\\.|$)");
2692
- }
2693
-
2694
- eventType = events[ type ];
2695
-
2696
- if ( !eventType ) {
2697
- continue;
2698
- }
2699
-
2700
- if ( !handler ) {
2701
- for ( j = 0; j < eventType.length; j++ ) {
2702
- handleObj = eventType[ j ];
2703
-
2704
- if ( all || namespace.test( handleObj.namespace ) ) {
2705
- jQuery.event.remove( elem, origType, handleObj.handler, j );
2706
- eventType.splice( j--, 1 );
2707
- }
2708
- }
2709
-
2710
- continue;
2711
- }
2712
-
2713
- special = jQuery.event.special[ type ] || {};
2714
-
2715
- for ( j = pos || 0; j < eventType.length; j++ ) {
2716
- handleObj = eventType[ j ];
2717
-
2718
- if ( handler.guid === handleObj.guid ) {
2719
- // remove the given handler for the given type
2720
- if ( all || namespace.test( handleObj.namespace ) ) {
2721
- if ( pos == null ) {
2722
- eventType.splice( j--, 1 );
2723
- }
2724
-
2725
- if ( special.remove ) {
2726
- special.remove.call( elem, handleObj );
2727
- }
2728
- }
2729
-
2730
- if ( pos != null ) {
2731
- break;
2732
- }
2733
- }
2734
- }
2735
-
2736
- // remove generic event handler if no more handlers exist
2737
- if ( eventType.length === 0 || pos != null && eventType.length === 1 ) {
2738
- if ( !special.teardown || special.teardown.call( elem, namespaces ) === false ) {
2739
- jQuery.removeEvent( elem, type, elemData.handle );
2740
- }
2741
-
2742
- ret = null;
2743
- delete events[ type ];
2744
- }
2745
- }
2746
-
2747
- // Remove the expando if it's no longer used
2748
- if ( jQuery.isEmptyObject( events ) ) {
2749
- var handle = elemData.handle;
2750
- if ( handle ) {
2751
- handle.elem = null;
2752
- }
2753
-
2754
- delete elemData.events;
2755
- delete elemData.handle;
2756
-
2757
- if ( jQuery.isEmptyObject( elemData ) ) {
2758
- jQuery.removeData( elem, undefined, true );
2759
- }
2760
- }
2761
- },
2762
-
2763
- // Events that are safe to short-circuit if no handlers are attached.
2764
- // Native DOM events should not be added, they may have inline handlers.
2765
- customEvent: {
2766
- "getData": true,
2767
- "setData": true,
2768
- "changeData": true
2769
- },
2770
-
2771
- trigger: function( event, data, elem, onlyHandlers ) {
2772
- // Event object or event type
2773
- var type = event.type || event,
2774
- namespaces = [],
2775
- exclusive;
2776
-
2777
- if ( type.indexOf("!") >= 0 ) {
2778
- // Exclusive events trigger only for the exact event (no namespaces)
2779
- type = type.slice(0, -1);
2780
- exclusive = true;
2781
- }
2782
-
2783
- if ( type.indexOf(".") >= 0 ) {
2784
- // Namespaced trigger; create a regexp to match event type in handle()
2785
- namespaces = type.split(".");
2786
- type = namespaces.shift();
2787
- namespaces.sort();
2788
- }
2789
-
2790
- if ( (!elem || jQuery.event.customEvent[ type ]) && !jQuery.event.global[ type ] ) {
2791
- // No jQuery handlers for this event type, and it can't have inline handlers
2792
- return;
2793
- }
2794
-
2795
- // Caller can pass in an Event, Object, or just an event type string
2796
- event = typeof event === "object" ?
2797
- // jQuery.Event object
2798
- event[ jQuery.expando ] ? event :
2799
- // Object literal
2800
- new jQuery.Event( type, event ) :
2801
- // Just the event type (string)
2802
- new jQuery.Event( type );
2803
-
2804
- event.type = type;
2805
- event.exclusive = exclusive;
2806
- event.namespace = namespaces.join(".");
2807
- event.namespace_re = new RegExp("(^|\\.)" + namespaces.join("\\.(?:.*\\.)?") + "(\\.|$)");
2808
-
2809
- // triggerHandler() and global events don't bubble or run the default action
2810
- if ( onlyHandlers || !elem ) {
2811
- event.preventDefault();
2812
- event.stopPropagation();
2813
- }
2814
-
2815
- // Handle a global trigger
2816
- if ( !elem ) {
2817
- // TODO: Stop taunting the data cache; remove global events and always attach to document
2818
- jQuery.each( jQuery.cache, function() {
2819
- // internalKey variable is just used to make it easier to find
2820
- // and potentially change this stuff later; currently it just
2821
- // points to jQuery.expando
2822
- var internalKey = jQuery.expando,
2823
- internalCache = this[ internalKey ];
2824
- if ( internalCache && internalCache.events && internalCache.events[ type ] ) {
2825
- jQuery.event.trigger( event, data, internalCache.handle.elem );
2826
- }
2827
- });
2828
- return;
2829
- }
2830
-
2831
- // Don't do events on text and comment nodes
2832
- if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
2833
- return;
2834
- }
2835
-
2836
- // Clean up the event in case it is being reused
2837
- event.result = undefined;
2838
- event.target = elem;
2839
-
2840
- // Clone any incoming data and prepend the event, creating the handler arg list
2841
- data = data ? jQuery.makeArray( data ) : [];
2842
- data.unshift( event );
2843
-
2844
- var cur = elem,
2845
- // IE doesn't like method names with a colon (#3533, #8272)
2846
- ontype = type.indexOf(":") < 0 ? "on" + type : "";
2847
-
2848
- // Fire event on the current element, then bubble up the DOM tree
2849
- do {
2850
- var handle = jQuery._data( cur, "handle" );
2851
-
2852
- event.currentTarget = cur;
2853
- if ( handle ) {
2854
- handle.apply( cur, data );
2855
- }
2856
-
2857
- // Trigger an inline bound script
2858
- if ( ontype && jQuery.acceptData( cur ) && cur[ ontype ] && cur[ ontype ].apply( cur, data ) === false ) {
2859
- event.result = false;
2860
- event.preventDefault();
2861
- }
2862
-
2863
- // Bubble up to document, then to window
2864
- cur = cur.parentNode || cur.ownerDocument || cur === event.target.ownerDocument && window;
2865
- } while ( cur && !event.isPropagationStopped() );
2866
-
2867
- // If nobody prevented the default action, do it now
2868
- if ( !event.isDefaultPrevented() ) {
2869
- var old,
2870
- special = jQuery.event.special[ type ] || {};
2871
-
2872
- if ( (!special._default || special._default.call( elem.ownerDocument, event ) === false) &&
2873
- !(type === "click" && jQuery.nodeName( elem, "a" )) && jQuery.acceptData( elem ) ) {
2874
-
2875
- // Call a native DOM method on the target with the same name name as the event.
2876
- // Can't use an .isFunction)() check here because IE6/7 fails that test.
2877
- // IE<9 dies on focus to hidden element (#1486), may want to revisit a try/catch.
2878
- try {
2879
- if ( ontype && elem[ type ] ) {
2880
- // Don't re-trigger an onFOO event when we call its FOO() method
2881
- old = elem[ ontype ];
2882
-
2883
- if ( old ) {
2884
- elem[ ontype ] = null;
2885
- }
2886
-
2887
- jQuery.event.triggered = type;
2888
- elem[ type ]();
2889
- }
2890
- } catch ( ieError ) {}
2891
-
2892
- if ( old ) {
2893
- elem[ ontype ] = old;
2894
- }
2895
-
2896
- jQuery.event.triggered = undefined;
2897
- }
2898
- }
2899
-
2900
- return event.result;
2901
- },
2902
-
2903
- handle: function( event ) {
2904
- event = jQuery.event.fix( event || window.event );
2905
- // Snapshot the handlers list since a called handler may add/remove events.
2906
- var handlers = ((jQuery._data( this, "events" ) || {})[ event.type ] || []).slice(0),
2907
- run_all = !event.exclusive && !event.namespace,
2908
- args = Array.prototype.slice.call( arguments, 0 );
2909
-
2910
- // Use the fix-ed Event rather than the (read-only) native event
2911
- args[0] = event;
2912
- event.currentTarget = this;
2913
-
2914
- for ( var j = 0, l = handlers.length; j < l; j++ ) {
2915
- var handleObj = handlers[ j ];
2916
-
2917
- // Triggered event must 1) be non-exclusive and have no namespace, or
2918
- // 2) have namespace(s) a subset or equal to those in the bound event.
2919
- if ( run_all || event.namespace_re.test( handleObj.namespace ) ) {
2920
- // Pass in a reference to the handler function itself
2921
- // So that we can later remove it
2922
- event.handler = handleObj.handler;
2923
- event.data = handleObj.data;
2924
- event.handleObj = handleObj;
2925
-
2926
- var ret = handleObj.handler.apply( this, args );
2927
-
2928
- if ( ret !== undefined ) {
2929
- event.result = ret;
2930
- if ( ret === false ) {
2931
- event.preventDefault();
2932
- event.stopPropagation();
2933
- }
2934
- }
2935
-
2936
- if ( event.isImmediatePropagationStopped() ) {
2937
- break;
2938
- }
2939
- }
2940
- }
2941
- return event.result;
2942
- },
2943
-
2944
- props: "altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),
2945
-
2946
- fix: function( event ) {
2947
- if ( event[ jQuery.expando ] ) {
2948
- return event;
2949
- }
2950
-
2951
- // store a copy of the original event object
2952
- // and "clone" to set read-only properties
2953
- var originalEvent = event;
2954
- event = jQuery.Event( originalEvent );
2955
-
2956
- for ( var i = this.props.length, prop; i; ) {
2957
- prop = this.props[ --i ];
2958
- event[ prop ] = originalEvent[ prop ];
2959
- }
2960
-
2961
- // Fix target property, if necessary
2962
- if ( !event.target ) {
2963
- // Fixes #1925 where srcElement might not be defined either
2964
- event.target = event.srcElement || document;
2965
- }
2966
-
2967
- // check if target is a textnode (safari)
2968
- if ( event.target.nodeType === 3 ) {
2969
- event.target = event.target.parentNode;
2970
- }
2971
-
2972
- // Add relatedTarget, if necessary
2973
- if ( !event.relatedTarget && event.fromElement ) {
2974
- event.relatedTarget = event.fromElement === event.target ? event.toElement : event.fromElement;
2975
- }
2976
-
2977
- // Calculate pageX/Y if missing and clientX/Y available
2978
- if ( event.pageX == null && event.clientX != null ) {
2979
- var eventDocument = event.target.ownerDocument || document,
2980
- doc = eventDocument.documentElement,
2981
- body = eventDocument.body;
2982
-
2983
- event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0);
2984
- event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0);
2985
- }
2986
-
2987
- // Add which for key events
2988
- if ( event.which == null && (event.charCode != null || event.keyCode != null) ) {
2989
- event.which = event.charCode != null ? event.charCode : event.keyCode;
2990
- }
2991
-
2992
- // Add metaKey to non-Mac browsers (use ctrl for PC's and Meta for Macs)
2993
- if ( !event.metaKey && event.ctrlKey ) {
2994
- event.metaKey = event.ctrlKey;
2995
- }
2996
-
2997
- // Add which for click: 1 === left; 2 === middle; 3 === right
2998
- // Note: button is not normalized, so don't use it
2999
- if ( !event.which && event.button !== undefined ) {
3000
- event.which = (event.button & 1 ? 1 : ( event.button & 2 ? 3 : ( event.button & 4 ? 2 : 0 ) ));
3001
- }
3002
-
3003
- return event;
3004
- },
3005
-
3006
- // Deprecated, use jQuery.guid instead
3007
- guid: 1E8,
3008
-
3009
- // Deprecated, use jQuery.proxy instead
3010
- proxy: jQuery.proxy,
3011
-
3012
- special: {
3013
- ready: {
3014
- // Make sure the ready event is setup
3015
- setup: jQuery.bindReady,
3016
- teardown: jQuery.noop
3017
- },
3018
-
3019
- live: {
3020
- add: function( handleObj ) {
3021
- jQuery.event.add( this,
3022
- liveConvert( handleObj.origType, handleObj.selector ),
3023
- jQuery.extend({}, handleObj, {handler: liveHandler, guid: handleObj.handler.guid}) );
3024
- },
3025
-
3026
- remove: function( handleObj ) {
3027
- jQuery.event.remove( this, liveConvert( handleObj.origType, handleObj.selector ), handleObj );
3028
- }
3029
- },
3030
-
3031
- beforeunload: {
3032
- setup: function( data, namespaces, eventHandle ) {
3033
- // We only want to do this special case on windows
3034
- if ( jQuery.isWindow( this ) ) {
3035
- this.onbeforeunload = eventHandle;
3036
- }
3037
- },
3038
-
3039
- teardown: function( namespaces, eventHandle ) {
3040
- if ( this.onbeforeunload === eventHandle ) {
3041
- this.onbeforeunload = null;
3042
- }
3043
- }
3044
- }
3045
- }
3046
- };
3047
-
3048
- jQuery.removeEvent = document.removeEventListener ?
3049
- function( elem, type, handle ) {
3050
- if ( elem.removeEventListener ) {
3051
- elem.removeEventListener( type, handle, false );
3052
- }
3053
- } :
3054
- function( elem, type, handle ) {
3055
- if ( elem.detachEvent ) {
3056
- elem.detachEvent( "on" + type, handle );
3057
- }
3058
- };
3059
-
3060
- jQuery.Event = function( src, props ) {
3061
- // Allow instantiation without the 'new' keyword
3062
- if ( !this.preventDefault ) {
3063
- return new jQuery.Event( src, props );
3064
- }
3065
-
3066
- // Event object
3067
- if ( src && src.type ) {
3068
- this.originalEvent = src;
3069
- this.type = src.type;
3070
-
3071
- // Events bubbling up the document may have been marked as prevented
3072
- // by a handler lower down the tree; reflect the correct value.
3073
- this.isDefaultPrevented = (src.defaultPrevented || src.returnValue === false ||
3074
- src.getPreventDefault && src.getPreventDefault()) ? returnTrue : returnFalse;
3075
-
3076
- // Event type
3077
- } else {
3078
- this.type = src;
3079
- }
3080
-
3081
- // Put explicitly provided properties onto the event object
3082
- if ( props ) {
3083
- jQuery.extend( this, props );
3084
- }
3085
-
3086
- // timeStamp is buggy for some events on Firefox(#3843)
3087
- // So we won't rely on the native value
3088
- this.timeStamp = jQuery.now();
3089
-
3090
- // Mark it as fixed
3091
- this[ jQuery.expando ] = true;
3092
- };
3093
-
3094
- function returnFalse() {
3095
- return false;
3096
- }
3097
- function returnTrue() {
3098
- return true;
3099
- }
3100
-
3101
- // jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding
3102
- // http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html
3103
- jQuery.Event.prototype = {
3104
- preventDefault: function() {
3105
- this.isDefaultPrevented = returnTrue;
3106
-
3107
- var e = this.originalEvent;
3108
- if ( !e ) {
3109
- return;
3110
- }
3111
-
3112
- // if preventDefault exists run it on the original event
3113
- if ( e.preventDefault ) {
3114
- e.preventDefault();
3115
-
3116
- // otherwise set the returnValue property of the original event to false (IE)
3117
- } else {
3118
- e.returnValue = false;
3119
- }
3120
- },
3121
- stopPropagation: function() {
3122
- this.isPropagationStopped = returnTrue;
3123
-
3124
- var e = this.originalEvent;
3125
- if ( !e ) {
3126
- return;
3127
- }
3128
- // if stopPropagation exists run it on the original event
3129
- if ( e.stopPropagation ) {
3130
- e.stopPropagation();
3131
- }
3132
- // otherwise set the cancelBubble property of the original event to true (IE)
3133
- e.cancelBubble = true;
3134
- },
3135
- stopImmediatePropagation: function() {
3136
- this.isImmediatePropagationStopped = returnTrue;
3137
- this.stopPropagation();
3138
- },
3139
- isDefaultPrevented: returnFalse,
3140
- isPropagationStopped: returnFalse,
3141
- isImmediatePropagationStopped: returnFalse
3142
- };
3143
-
3144
- // Checks if an event happened on an element within another element
3145
- // Used in jQuery.event.special.mouseenter and mouseleave handlers
3146
- var withinElement = function( event ) {
3147
- // Check if mouse(over|out) are still within the same parent element
3148
- var parent = event.relatedTarget;
3149
-
3150
- // set the correct event type
3151
- event.type = event.data;
3152
-
3153
- // Firefox sometimes assigns relatedTarget a XUL element
3154
- // which we cannot access the parentNode property of
3155
- try {
3156
-
3157
- // Chrome does something similar, the parentNode property
3158
- // can be accessed but is null.
3159
- if ( parent && parent !== document && !parent.parentNode ) {
3160
- return;
3161
- }
3162
-
3163
- // Traverse up the tree
3164
- while ( parent && parent !== this ) {
3165
- parent = parent.parentNode;
3166
- }
3167
-
3168
- if ( parent !== this ) {
3169
- // handle event if we actually just moused on to a non sub-element
3170
- jQuery.event.handle.apply( this, arguments );
3171
- }
3172
-
3173
- // assuming we've left the element since we most likely mousedover a xul element
3174
- } catch(e) { }
3175
- },
3176
-
3177
- // In case of event delegation, we only need to rename the event.type,
3178
- // liveHandler will take care of the rest.
3179
- delegate = function( event ) {
3180
- event.type = event.data;
3181
- jQuery.event.handle.apply( this, arguments );
3182
- };
3183
-
3184
- // Create mouseenter and mouseleave events
3185
- jQuery.each({
3186
- mouseenter: "mouseover",
3187
- mouseleave: "mouseout"
3188
- }, function( orig, fix ) {
3189
- jQuery.event.special[ orig ] = {
3190
- setup: function( data ) {
3191
- jQuery.event.add( this, fix, data && data.selector ? delegate : withinElement, orig );
3192
- },
3193
- teardown: function( data ) {
3194
- jQuery.event.remove( this, fix, data && data.selector ? delegate : withinElement );
3195
- }
3196
- };
3197
- });
3198
-
3199
- // submit delegation
3200
- if ( !jQuery.support.submitBubbles ) {
3201
-
3202
- jQuery.event.special.submit = {
3203
- setup: function( data, namespaces ) {
3204
- if ( !jQuery.nodeName( this, "form" ) ) {
3205
- jQuery.event.add(this, "click.specialSubmit", function( e ) {
3206
- var elem = e.target,
3207
- type = elem.type;
3208
-
3209
- if ( (type === "submit" || type === "image") && jQuery( elem ).closest("form").length ) {
3210
- trigger( "submit", this, arguments );
3211
- }
3212
- });
3213
-
3214
- jQuery.event.add(this, "keypress.specialSubmit", function( e ) {
3215
- var elem = e.target,
3216
- type = elem.type;
3217
-
3218
- if ( (type === "text" || type === "password") && jQuery( elem ).closest("form").length && e.keyCode === 13 ) {
3219
- trigger( "submit", this, arguments );
3220
- }
3221
- });
3222
-
3223
- } else {
3224
- return false;
3225
- }
3226
- },
3227
-
3228
- teardown: function( namespaces ) {
3229
- jQuery.event.remove( this, ".specialSubmit" );
3230
- }
3231
- };
3232
-
3233
- }
3234
-
3235
- // change delegation, happens here so we have bind.
3236
- if ( !jQuery.support.changeBubbles ) {
3237
-
3238
- var changeFilters,
3239
-
3240
- getVal = function( elem ) {
3241
- var type = elem.type, val = elem.value;
3242
-
3243
- if ( type === "radio" || type === "checkbox" ) {
3244
- val = elem.checked;
3245
-
3246
- } else if ( type === "select-multiple" ) {
3247
- val = elem.selectedIndex > -1 ?
3248
- jQuery.map( elem.options, function( elem ) {
3249
- return elem.selected;
3250
- }).join("-") :
3251
- "";
3252
-
3253
- } else if ( jQuery.nodeName( elem, "select" ) ) {
3254
- val = elem.selectedIndex;
3255
- }
3256
-
3257
- return val;
3258
- },
3259
-
3260
- testChange = function testChange( e ) {
3261
- var elem = e.target, data, val;
3262
-
3263
- if ( !rformElems.test( elem.nodeName ) || elem.readOnly ) {
3264
- return;
3265
- }
3266
-
3267
- data = jQuery._data( elem, "_change_data" );
3268
- val = getVal(elem);
3269
-
3270
- // the current data will be also retrieved by beforeactivate
3271
- if ( e.type !== "focusout" || elem.type !== "radio" ) {
3272
- jQuery._data( elem, "_change_data", val );
3273
- }
3274
-
3275
- if ( data === undefined || val === data ) {
3276
- return;
3277
- }
3278
-
3279
- if ( data != null || val ) {
3280
- e.type = "change";
3281
- e.liveFired = undefined;
3282
- jQuery.event.trigger( e, arguments[1], elem );
3283
- }
3284
- };
3285
-
3286
- jQuery.event.special.change = {
3287
- filters: {
3288
- focusout: testChange,
3289
-
3290
- beforedeactivate: testChange,
3291
-
3292
- click: function( e ) {
3293
- var elem = e.target, type = jQuery.nodeName( elem, "input" ) ? elem.type : "";
3294
-
3295
- if ( type === "radio" || type === "checkbox" || jQuery.nodeName( elem, "select" ) ) {
3296
- testChange.call( this, e );
3297
- }
3298
- },
3299
-
3300
- // Change has to be called before submit
3301
- // Keydown will be called before keypress, which is used in submit-event delegation
3302
- keydown: function( e ) {
3303
- var elem = e.target, type = jQuery.nodeName( elem, "input" ) ? elem.type : "";
3304
-
3305
- if ( (e.keyCode === 13 && !jQuery.nodeName( elem, "textarea" ) ) ||
3306
- (e.keyCode === 32 && (type === "checkbox" || type === "radio")) ||
3307
- type === "select-multiple" ) {
3308
- testChange.call( this, e );
3309
- }
3310
- },
3311
-
3312
- // Beforeactivate happens also before the previous element is blurred
3313
- // with this event you can't trigger a change event, but you can store
3314
- // information
3315
- beforeactivate: function( e ) {
3316
- var elem = e.target;
3317
- jQuery._data( elem, "_change_data", getVal(elem) );
3318
- }
3319
- },
3320
-
3321
- setup: function( data, namespaces ) {
3322
- if ( this.type === "file" ) {
3323
- return false;
3324
- }
3325
-
3326
- for ( var type in changeFilters ) {
3327
- jQuery.event.add( this, type + ".specialChange", changeFilters[type] );
3328
- }
3329
-
3330
- return rformElems.test( this.nodeName );
3331
- },
3332
-
3333
- teardown: function( namespaces ) {
3334
- jQuery.event.remove( this, ".specialChange" );
3335
-
3336
- return rformElems.test( this.nodeName );
3337
- }
3338
- };
3339
-
3340
- changeFilters = jQuery.event.special.change.filters;
3341
-
3342
- // Handle when the input is .focus()'d
3343
- changeFilters.focus = changeFilters.beforeactivate;
3344
- }
3345
-
3346
- function trigger( type, elem, args ) {
3347
- // Piggyback on a donor event to simulate a different one.
3348
- // Fake originalEvent to avoid donor's stopPropagation, but if the
3349
- // simulated event prevents default then we do the same on the donor.
3350
- // Don't pass args or remember liveFired; they apply to the donor event.
3351
- var event = jQuery.extend( {}, args[ 0 ] );
3352
- event.type = type;
3353
- event.originalEvent = {};
3354
- event.liveFired = undefined;
3355
- jQuery.event.handle.call( elem, event );
3356
- if ( event.isDefaultPrevented() ) {
3357
- args[ 0 ].preventDefault();
3358
- }
3359
- }
3360
-
3361
- // Create "bubbling" focus and blur events
3362
- if ( !jQuery.support.focusinBubbles ) {
3363
- jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) {
3364
-
3365
- // Attach a single capturing handler while someone wants focusin/focusout
3366
- var attaches = 0;
3367
-
3368
- jQuery.event.special[ fix ] = {
3369
- setup: function() {
3370
- if ( attaches++ === 0 ) {
3371
- document.addEventListener( orig, handler, true );
3372
- }
3373
- },
3374
- teardown: function() {
3375
- if ( --attaches === 0 ) {
3376
- document.removeEventListener( orig, handler, true );
3377
- }
3378
- }
3379
- };
3380
-
3381
- function handler( donor ) {
3382
- // Donor event is always a native one; fix it and switch its type.
3383
- // Let focusin/out handler cancel the donor focus/blur event.
3384
- var e = jQuery.event.fix( donor );
3385
- e.type = fix;
3386
- e.originalEvent = {};
3387
- jQuery.event.trigger( e, null, e.target );
3388
- if ( e.isDefaultPrevented() ) {
3389
- donor.preventDefault();
3390
- }
3391
- }
3392
- });
3393
- }
3394
-
3395
- jQuery.each(["bind", "one"], function( i, name ) {
3396
- jQuery.fn[ name ] = function( type, data, fn ) {
3397
- var handler;
3398
-
3399
- // Handle object literals
3400
- if ( typeof type === "object" ) {
3401
- for ( var key in type ) {
3402
- this[ name ](key, data, type[key], fn);
3403
- }
3404
- return this;
3405
- }
3406
-
3407
- if ( arguments.length === 2 || data === false ) {
3408
- fn = data;
3409
- data = undefined;
3410
- }
3411
-
3412
- if ( name === "one" ) {
3413
- handler = function( event ) {
3414
- jQuery( this ).unbind( event, handler );
3415
- return fn.apply( this, arguments );
3416
- };
3417
- handler.guid = fn.guid || jQuery.guid++;
3418
- } else {
3419
- handler = fn;
3420
- }
3421
-
3422
- if ( type === "unload" && name !== "one" ) {
3423
- this.one( type, data, fn );
3424
-
3425
- } else {
3426
- for ( var i = 0, l = this.length; i < l; i++ ) {
3427
- jQuery.event.add( this[i], type, handler, data );
3428
- }
3429
- }
3430
-
3431
- return this;
3432
- };
3433
- });
3434
-
3435
- jQuery.fn.extend({
3436
- unbind: function( type, fn ) {
3437
- // Handle object literals
3438
- if ( typeof type === "object" && !type.preventDefault ) {
3439
- for ( var key in type ) {
3440
- this.unbind(key, type[key]);
3441
- }
3442
-
3443
- } else {
3444
- for ( var i = 0, l = this.length; i < l; i++ ) {
3445
- jQuery.event.remove( this[i], type, fn );
3446
- }
3447
- }
3448
-
3449
- return this;
3450
- },
3451
-
3452
- delegate: function( selector, types, data, fn ) {
3453
- return this.live( types, data, fn, selector );
3454
- },
3455
-
3456
- undelegate: function( selector, types, fn ) {
3457
- if ( arguments.length === 0 ) {
3458
- return this.unbind( "live" );
3459
-
3460
- } else {
3461
- return this.die( types, null, fn, selector );
3462
- }
3463
- },
3464
-
3465
- trigger: function( type, data ) {
3466
- return this.each(function() {
3467
- jQuery.event.trigger( type, data, this );
3468
- });
3469
- },
3470
-
3471
- triggerHandler: function( type, data ) {
3472
- if ( this[0] ) {
3473
- return jQuery.event.trigger( type, data, this[0], true );
3474
- }
3475
- },
3476
-
3477
- toggle: function( fn ) {
3478
- // Save reference to arguments for access in closure
3479
- var args = arguments,
3480
- guid = fn.guid || jQuery.guid++,
3481
- i = 0,
3482
- toggler = function( event ) {
3483
- // Figure out which function to execute
3484
- var lastToggle = ( jQuery.data( this, "lastToggle" + fn.guid ) || 0 ) % i;
3485
- jQuery.data( this, "lastToggle" + fn.guid, lastToggle + 1 );
3486
-
3487
- // Make sure that clicks stop
3488
- event.preventDefault();
3489
-
3490
- // and execute the function
3491
- return args[ lastToggle ].apply( this, arguments ) || false;
3492
- };
3493
-
3494
- // link all the functions, so any of them can unbind this click handler
3495
- toggler.guid = guid;
3496
- while ( i < args.length ) {
3497
- args[ i++ ].guid = guid;
3498
- }
3499
-
3500
- return this.click( toggler );
3501
- },
3502
-
3503
- hover: function( fnOver, fnOut ) {
3504
- return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
3505
- }
3506
- });
3507
-
3508
- var liveMap = {
3509
- focus: "focusin",
3510
- blur: "focusout",
3511
- mouseenter: "mouseover",
3512
- mouseleave: "mouseout"
3513
- };
3514
-
3515
- jQuery.each(["live", "die"], function( i, name ) {
3516
- jQuery.fn[ name ] = function( types, data, fn, origSelector /* Internal Use Only */ ) {
3517
- var type, i = 0, match, namespaces, preType,
3518
- selector = origSelector || this.selector,
3519
- context = origSelector ? this : jQuery( this.context );
3520
-
3521
- if ( typeof types === "object" && !types.preventDefault ) {
3522
- for ( var key in types ) {
3523
- context[ name ]( key, data, types[key], selector );
3524
- }
3525
-
3526
- return this;
3527
- }
3528
-
3529
- if ( name === "die" && !types &&
3530
- origSelector && origSelector.charAt(0) === "." ) {
3531
-
3532
- context.unbind( origSelector );
3533
-
3534
- return this;
3535
- }
3536
-
3537
- if ( data === false || jQuery.isFunction( data ) ) {
3538
- fn = data || returnFalse;
3539
- data = undefined;
3540
- }
3541
-
3542
- types = (types || "").split(" ");
3543
-
3544
- while ( (type = types[ i++ ]) != null ) {
3545
- match = rnamespaces.exec( type );
3546
- namespaces = "";
3547
-
3548
- if ( match ) {
3549
- namespaces = match[0];
3550
- type = type.replace( rnamespaces, "" );
3551
- }
3552
-
3553
- if ( type === "hover" ) {
3554
- types.push( "mouseenter" + namespaces, "mouseleave" + namespaces );
3555
- continue;
3556
- }
3557
-
3558
- preType = type;
3559
-
3560
- if ( liveMap[ type ] ) {
3561
- types.push( liveMap[ type ] + namespaces );
3562
- type = type + namespaces;
3563
-
3564
- } else {
3565
- type = (liveMap[ type ] || type) + namespaces;
3566
- }
3567
-
3568
- if ( name === "live" ) {
3569
- // bind live handler
3570
- for ( var j = 0, l = context.length; j < l; j++ ) {
3571
- jQuery.event.add( context[j], "live." + liveConvert( type, selector ),
3572
- { data: data, selector: selector, handler: fn, origType: type, origHandler: fn, preType: preType } );
3573
- }
3574
-
3575
- } else {
3576
- // unbind live handler
3577
- context.unbind( "live." + liveConvert( type, selector ), fn );
3578
- }
3579
- }
3580
-
3581
- return this;
3582
- };
3583
- });
3584
-
3585
- function liveHandler( event ) {
3586
- var stop, maxLevel, related, match, handleObj, elem, j, i, l, data, close, namespace, ret,
3587
- elems = [],
3588
- selectors = [],
3589
- events = jQuery._data( this, "events" );
3590
-
3591
- // Make sure we avoid non-left-click bubbling in Firefox (#3861) and disabled elements in IE (#6911)
3592
- if ( event.liveFired === this || !events || !events.live || event.target.disabled || event.button && event.type === "click" ) {
3593
- return;
3594
- }
3595
-
3596
- if ( event.namespace ) {
3597
- namespace = new RegExp("(^|\\.)" + event.namespace.split(".").join("\\.(?:.*\\.)?") + "(\\.|$)");
3598
- }
3599
-
3600
- event.liveFired = this;
3601
-
3602
- var live = events.live.slice(0);
3603
-
3604
- for ( j = 0; j < live.length; j++ ) {
3605
- handleObj = live[j];
3606
-
3607
- if ( handleObj.origType.replace( rnamespaces, "" ) === event.type ) {
3608
- selectors.push( handleObj.selector );
3609
-
3610
- } else {
3611
- live.splice( j--, 1 );
3612
- }
3613
- }
3614
-
3615
- match = jQuery( event.target ).closest( selectors, event.currentTarget );
3616
-
3617
- for ( i = 0, l = match.length; i < l; i++ ) {
3618
- close = match[i];
3619
-
3620
- for ( j = 0; j < live.length; j++ ) {
3621
- handleObj = live[j];
3622
-
3623
- if ( close.selector === handleObj.selector && (!namespace || namespace.test( handleObj.namespace )) && !close.elem.disabled ) {
3624
- elem = close.elem;
3625
- related = null;
3626
-
3627
- // Those two events require additional checking
3628
- if ( handleObj.preType === "mouseenter" || handleObj.preType === "mouseleave" ) {
3629
- event.type = handleObj.preType;
3630
- related = jQuery( event.relatedTarget ).closest( handleObj.selector )[0];
3631
-
3632
- // Make sure not to accidentally match a child element with the same selector
3633
- if ( related && jQuery.contains( elem, related ) ) {
3634
- related = elem;
3635
- }
3636
- }
3637
-
3638
- if ( !related || related !== elem ) {
3639
- elems.push({ elem: elem, handleObj: handleObj, level: close.level });
3640
- }
3641
- }
3642
- }
3643
- }
3644
-
3645
- for ( i = 0, l = elems.length; i < l; i++ ) {
3646
- match = elems[i];
3647
-
3648
- if ( maxLevel && match.level > maxLevel ) {
3649
- break;
3650
- }
3651
-
3652
- event.currentTarget = match.elem;
3653
- event.data = match.handleObj.data;
3654
- event.handleObj = match.handleObj;
3655
-
3656
- ret = match.handleObj.origHandler.apply( match.elem, arguments );
3657
-
3658
- if ( ret === false || event.isPropagationStopped() ) {
3659
- maxLevel = match.level;
3660
-
3661
- if ( ret === false ) {
3662
- stop = false;
3663
- }
3664
- if ( event.isImmediatePropagationStopped() ) {
3665
- break;
3666
- }
3667
- }
3668
- }
3669
-
3670
- return stop;
3671
- }
3672
-
3673
- function liveConvert( type, selector ) {
3674
- return (type && type !== "*" ? type + "." : "") + selector.replace(rperiod, "`").replace(rspaces, "&");
3675
- }
3676
-
3677
- jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " +
3678
- "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
3679
- "change select submit keydown keypress keyup error").split(" "), function( i, name ) {
3680
-
3681
- // Handle event binding
3682
- jQuery.fn[ name ] = function( data, fn ) {
3683
- if ( fn == null ) {
3684
- fn = data;
3685
- data = null;
3686
- }
3687
-
3688
- return arguments.length > 0 ?
3689
- this.bind( name, data, fn ) :
3690
- this.trigger( name );
3691
- };
3692
-
3693
- if ( jQuery.attrFn ) {
3694
- jQuery.attrFn[ name ] = true;
3695
- }
3696
- });
3697
-
3698
-
3699
-
3700
- /*!
3701
- * Sizzle CSS Selector Engine
3702
- * Copyright 2011, The Dojo Foundation
3703
- * Released under the MIT, BSD, and GPL Licenses.
3704
- * More information: http://sizzlejs.com/
3705
- */
3706
- (function(){
3707
-
3708
- var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,
3709
- done = 0,
3710
- toString = Object.prototype.toString,
3711
- hasDuplicate = false,
3712
- baseHasDuplicate = true,
3713
- rBackslash = /\\/g,
3714
- rNonWord = /\W/;
3715
-
3716
- // Here we check if the JavaScript engine is using some sort of
3717
- // optimization where it does not always call our comparision
3718
- // function. If that is the case, discard the hasDuplicate value.
3719
- // Thus far that includes Google Chrome.
3720
- [0, 0].sort(function() {
3721
- baseHasDuplicate = false;
3722
- return 0;
3723
- });
3724
-
3725
- var Sizzle = function( selector, context, results, seed ) {
3726
- results = results || [];
3727
- context = context || document;
3728
-
3729
- var origContext = context;
3730
-
3731
- if ( context.nodeType !== 1 && context.nodeType !== 9 ) {
3732
- return [];
3733
- }
3734
-
3735
- if ( !selector || typeof selector !== "string" ) {
3736
- return results;
3737
- }
3738
-
3739
- var m, set, checkSet, extra, ret, cur, pop, i,
3740
- prune = true,
3741
- contextXML = Sizzle.isXML( context ),
3742
- parts = [],
3743
- soFar = selector;
3744
-
3745
- // Reset the position of the chunker regexp (start from head)
3746
- do {
3747
- chunker.exec( "" );
3748
- m = chunker.exec( soFar );
3749
-
3750
- if ( m ) {
3751
- soFar = m[3];
3752
-
3753
- parts.push( m[1] );
3754
-
3755
- if ( m[2] ) {
3756
- extra = m[3];
3757
- break;
3758
- }
3759
- }
3760
- } while ( m );
3761
-
3762
- if ( parts.length > 1 && origPOS.exec( selector ) ) {
3763
-
3764
- if ( parts.length === 2 && Expr.relative[ parts[0] ] ) {
3765
- set = posProcess( parts[0] + parts[1], context );
3766
-
3767
- } else {
3768
- set = Expr.relative[ parts[0] ] ?
3769
- [ context ] :
3770
- Sizzle( parts.shift(), context );
3771
-
3772
- while ( parts.length ) {
3773
- selector = parts.shift();
3774
-
3775
- if ( Expr.relative[ selector ] ) {
3776
- selector += parts.shift();
3777
- }
3778
-
3779
- set = posProcess( selector, set );
3780
- }
3781
- }
3782
-
3783
- } else {
3784
- // Take a shortcut and set the context if the root selector is an ID
3785
- // (but not if it'll be faster if the inner selector is an ID)
3786
- if ( !seed && parts.length > 1 && context.nodeType === 9 && !contextXML &&
3787
- Expr.match.ID.test(parts[0]) && !Expr.match.ID.test(parts[parts.length - 1]) ) {
3788
-
3789
- ret = Sizzle.find( parts.shift(), context, contextXML );
3790
- context = ret.expr ?
3791
- Sizzle.filter( ret.expr, ret.set )[0] :
3792
- ret.set[0];
3793
- }
3794
-
3795
- if ( context ) {
3796
- ret = seed ?
3797
- { expr: parts.pop(), set: makeArray(seed) } :
3798
- Sizzle.find( parts.pop(), parts.length === 1 && (parts[0] === "~" || parts[0] === "+") && context.parentNode ? context.parentNode : context, contextXML );
3799
-
3800
- set = ret.expr ?
3801
- Sizzle.filter( ret.expr, ret.set ) :
3802
- ret.set;
3803
-
3804
- if ( parts.length > 0 ) {
3805
- checkSet = makeArray( set );
3806
-
3807
- } else {
3808
- prune = false;
3809
- }
3810
-
3811
- while ( parts.length ) {
3812
- cur = parts.pop();
3813
- pop = cur;
3814
-
3815
- if ( !Expr.relative[ cur ] ) {
3816
- cur = "";
3817
- } else {
3818
- pop = parts.pop();
3819
- }
3820
-
3821
- if ( pop == null ) {
3822
- pop = context;
3823
- }
3824
-
3825
- Expr.relative[ cur ]( checkSet, pop, contextXML );
3826
- }
3827
-
3828
- } else {
3829
- checkSet = parts = [];
3830
- }
3831
- }
3832
-
3833
- if ( !checkSet ) {
3834
- checkSet = set;
3835
- }
3836
-
3837
- if ( !checkSet ) {
3838
- Sizzle.error( cur || selector );
3839
- }
3840
-
3841
- if ( toString.call(checkSet) === "[object Array]" ) {
3842
- if ( !prune ) {
3843
- results.push.apply( results, checkSet );
3844
-
3845
- } else if ( context && context.nodeType === 1 ) {
3846
- for ( i = 0; checkSet[i] != null; i++ ) {
3847
- if ( checkSet[i] && (checkSet[i] === true || checkSet[i].nodeType === 1 && Sizzle.contains(context, checkSet[i])) ) {
3848
- results.push( set[i] );
3849
- }
3850
- }
3851
-
3852
- } else {
3853
- for ( i = 0; checkSet[i] != null; i++ ) {
3854
- if ( checkSet[i] && checkSet[i].nodeType === 1 ) {
3855
- results.push( set[i] );
3856
- }
3857
- }
3858
- }
3859
-
3860
- } else {
3861
- makeArray( checkSet, results );
3862
- }
3863
-
3864
- if ( extra ) {
3865
- Sizzle( extra, origContext, results, seed );
3866
- Sizzle.uniqueSort( results );
3867
- }
3868
-
3869
- return results;
3870
- };
3871
-
3872
- Sizzle.uniqueSort = function( results ) {
3873
- if ( sortOrder ) {
3874
- hasDuplicate = baseHasDuplicate;
3875
- results.sort( sortOrder );
3876
-
3877
- if ( hasDuplicate ) {
3878
- for ( var i = 1; i < results.length; i++ ) {
3879
- if ( results[i] === results[ i - 1 ] ) {
3880
- results.splice( i--, 1 );
3881
- }
3882
- }
3883
- }
3884
- }
3885
-
3886
- return results;
3887
- };
3888
-
3889
- Sizzle.matches = function( expr, set ) {
3890
- return Sizzle( expr, null, null, set );
3891
- };
3892
-
3893
- Sizzle.matchesSelector = function( node, expr ) {
3894
- return Sizzle( expr, null, null, [node] ).length > 0;
3895
- };
3896
-
3897
- Sizzle.find = function( expr, context, isXML ) {
3898
- var set;
3899
-
3900
- if ( !expr ) {
3901
- return [];
3902
- }
3903
-
3904
- for ( var i = 0, l = Expr.order.length; i < l; i++ ) {
3905
- var match,
3906
- type = Expr.order[i];
3907
-
3908
- if ( (match = Expr.leftMatch[ type ].exec( expr )) ) {
3909
- var left = match[1];
3910
- match.splice( 1, 1 );
3911
-
3912
- if ( left.substr( left.length - 1 ) !== "\\" ) {
3913
- match[1] = (match[1] || "").replace( rBackslash, "" );
3914
- set = Expr.find[ type ]( match, context, isXML );
3915
-
3916
- if ( set != null ) {
3917
- expr = expr.replace( Expr.match[ type ], "" );
3918
- break;
3919
- }
3920
- }
3921
- }
3922
- }
3923
-
3924
- if ( !set ) {
3925
- set = typeof context.getElementsByTagName !== "undefined" ?
3926
- context.getElementsByTagName( "*" ) :
3927
- [];
3928
- }
3929
-
3930
- return { set: set, expr: expr };
3931
- };
3932
-
3933
- Sizzle.filter = function( expr, set, inplace, not ) {
3934
- var match, anyFound,
3935
- old = expr,
3936
- result = [],
3937
- curLoop = set,
3938
- isXMLFilter = set && set[0] && Sizzle.isXML( set[0] );
3939
-
3940
- while ( expr && set.length ) {
3941
- for ( var type in Expr.filter ) {
3942
- if ( (match = Expr.leftMatch[ type ].exec( expr )) != null && match[2] ) {
3943
- var found, item,
3944
- filter = Expr.filter[ type ],
3945
- left = match[1];
3946
-
3947
- anyFound = false;
3948
-
3949
- match.splice(1,1);
3950
-
3951
- if ( left.substr( left.length - 1 ) === "\\" ) {
3952
- continue;
3953
- }
3954
-
3955
- if ( curLoop === result ) {
3956
- result = [];
3957
- }
3958
-
3959
- if ( Expr.preFilter[ type ] ) {
3960
- match = Expr.preFilter[ type ]( match, curLoop, inplace, result, not, isXMLFilter );
3961
-
3962
- if ( !match ) {
3963
- anyFound = found = true;
3964
-
3965
- } else if ( match === true ) {
3966
- continue;
3967
- }
3968
- }
3969
-
3970
- if ( match ) {
3971
- for ( var i = 0; (item = curLoop[i]) != null; i++ ) {
3972
- if ( item ) {
3973
- found = filter( item, match, i, curLoop );
3974
- var pass = not ^ !!found;
3975
-
3976
- if ( inplace && found != null ) {
3977
- if ( pass ) {
3978
- anyFound = true;
3979
-
3980
- } else {
3981
- curLoop[i] = false;
3982
- }
3983
-
3984
- } else if ( pass ) {
3985
- result.push( item );
3986
- anyFound = true;
3987
- }
3988
- }
3989
- }
3990
- }
3991
-
3992
- if ( found !== undefined ) {
3993
- if ( !inplace ) {
3994
- curLoop = result;
3995
- }
3996
-
3997
- expr = expr.replace( Expr.match[ type ], "" );
3998
-
3999
- if ( !anyFound ) {
4000
- return [];
4001
- }
4002
-
4003
- break;
4004
- }
4005
- }
4006
- }
4007
-
4008
- // Improper expression
4009
- if ( expr === old ) {
4010
- if ( anyFound == null ) {
4011
- Sizzle.error( expr );
4012
-
4013
- } else {
4014
- break;
4015
- }
4016
- }
4017
-
4018
- old = expr;
4019
- }
4020
-
4021
- return curLoop;
4022
- };
4023
-
4024
- Sizzle.error = function( msg ) {
4025
- throw "Syntax error, unrecognized expression: " + msg;
4026
- };
4027
-
4028
- var Expr = Sizzle.selectors = {
4029
- order: [ "ID", "NAME", "TAG" ],
4030
-
4031
- match: {
4032
- ID: /#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
4033
- CLASS: /\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
4034
- NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,
4035
- ATTR: /\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,
4036
- TAG: /^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,
4037
- CHILD: /:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,
4038
- POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,
4039
- PSEUDO: /:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/
4040
- },
4041
-
4042
- leftMatch: {},
4043
-
4044
- attrMap: {
4045
- "class": "className",
4046
- "for": "htmlFor"
4047
- },
4048
-
4049
- attrHandle: {
4050
- href: function( elem ) {
4051
- return elem.getAttribute( "href" );
4052
- },
4053
- type: function( elem ) {
4054
- return elem.getAttribute( "type" );
4055
- }
4056
- },
4057
-
4058
- relative: {
4059
- "+": function(checkSet, part){
4060
- var isPartStr = typeof part === "string",
4061
- isTag = isPartStr && !rNonWord.test( part ),
4062
- isPartStrNotTag = isPartStr && !isTag;
4063
-
4064
- if ( isTag ) {
4065
- part = part.toLowerCase();
4066
- }
4067
-
4068
- for ( var i = 0, l = checkSet.length, elem; i < l; i++ ) {
4069
- if ( (elem = checkSet[i]) ) {
4070
- while ( (elem = elem.previousSibling) && elem.nodeType !== 1 ) {}
4071
-
4072
- checkSet[i] = isPartStrNotTag || elem && elem.nodeName.toLowerCase() === part ?
4073
- elem || false :
4074
- elem === part;
4075
- }
4076
- }
4077
-
4078
- if ( isPartStrNotTag ) {
4079
- Sizzle.filter( part, checkSet, true );
4080
- }
4081
- },
4082
-
4083
- ">": function( checkSet, part ) {
4084
- var elem,
4085
- isPartStr = typeof part === "string",
4086
- i = 0,
4087
- l = checkSet.length;
4088
-
4089
- if ( isPartStr && !rNonWord.test( part ) ) {
4090
- part = part.toLowerCase();
4091
-
4092
- for ( ; i < l; i++ ) {
4093
- elem = checkSet[i];
4094
-
4095
- if ( elem ) {
4096
- var parent = elem.parentNode;
4097
- checkSet[i] = parent.nodeName.toLowerCase() === part ? parent : false;
4098
- }
4099
- }
4100
-
4101
- } else {
4102
- for ( ; i < l; i++ ) {
4103
- elem = checkSet[i];
4104
-
4105
- if ( elem ) {
4106
- checkSet[i] = isPartStr ?
4107
- elem.parentNode :
4108
- elem.parentNode === part;
4109
- }
4110
- }
4111
-
4112
- if ( isPartStr ) {
4113
- Sizzle.filter( part, checkSet, true );
4114
- }
4115
- }
4116
- },
4117
-
4118
- "": function(checkSet, part, isXML){
4119
- var nodeCheck,
4120
- doneName = done++,
4121
- checkFn = dirCheck;
4122
-
4123
- if ( typeof part === "string" && !rNonWord.test( part ) ) {
4124
- part = part.toLowerCase();
4125
- nodeCheck = part;
4126
- checkFn = dirNodeCheck;
4127
- }
4128
-
4129
- checkFn( "parentNode", part, doneName, checkSet, nodeCheck, isXML );
4130
- },
4131
-
4132
- "~": function( checkSet, part, isXML ) {
4133
- var nodeCheck,
4134
- doneName = done++,
4135
- checkFn = dirCheck;
4136
-
4137
- if ( typeof part === "string" && !rNonWord.test( part ) ) {
4138
- part = part.toLowerCase();
4139
- nodeCheck = part;
4140
- checkFn = dirNodeCheck;
4141
- }
4142
-
4143
- checkFn( "previousSibling", part, doneName, checkSet, nodeCheck, isXML );
4144
- }
4145
- },
4146
-
4147
- find: {
4148
- ID: function( match, context, isXML ) {
4149
- if ( typeof context.getElementById !== "undefined" && !isXML ) {
4150
- var m = context.getElementById(match[1]);
4151
- // Check parentNode to catch when Blackberry 4.6 returns
4152
- // nodes that are no longer in the document #6963
4153
- return m && m.parentNode ? [m] : [];
4154
- }
4155
- },
4156
-
4157
- NAME: function( match, context ) {
4158
- if ( typeof context.getElementsByName !== "undefined" ) {
4159
- var ret = [],
4160
- results = context.getElementsByName( match[1] );
4161
-
4162
- for ( var i = 0, l = results.length; i < l; i++ ) {
4163
- if ( results[i].getAttribute("name") === match[1] ) {
4164
- ret.push( results[i] );
4165
- }
4166
- }
4167
-
4168
- return ret.length === 0 ? null : ret;
4169
- }
4170
- },
4171
-
4172
- TAG: function( match, context ) {
4173
- if ( typeof context.getElementsByTagName !== "undefined" ) {
4174
- return context.getElementsByTagName( match[1] );
4175
- }
4176
- }
4177
- },
4178
- preFilter: {
4179
- CLASS: function( match, curLoop, inplace, result, not, isXML ) {
4180
- match = " " + match[1].replace( rBackslash, "" ) + " ";
4181
-
4182
- if ( isXML ) {
4183
- return match;
4184
- }
4185
-
4186
- for ( var i = 0, elem; (elem = curLoop[i]) != null; i++ ) {
4187
- if ( elem ) {
4188
- if ( not ^ (elem.className && (" " + elem.className + " ").replace(/[\t\n\r]/g, " ").indexOf(match) >= 0) ) {
4189
- if ( !inplace ) {
4190
- result.push( elem );
4191
- }
4192
-
4193
- } else if ( inplace ) {
4194
- curLoop[i] = false;
4195
- }
4196
- }
4197
- }
4198
-
4199
- return false;
4200
- },
4201
-
4202
- ID: function( match ) {
4203
- return match[1].replace( rBackslash, "" );
4204
- },
4205
-
4206
- TAG: function( match, curLoop ) {
4207
- return match[1].replace( rBackslash, "" ).toLowerCase();
4208
- },
4209
-
4210
- CHILD: function( match ) {
4211
- if ( match[1] === "nth" ) {
4212
- if ( !match[2] ) {
4213
- Sizzle.error( match[0] );
4214
- }
4215
-
4216
- match[2] = match[2].replace(/^\+|\s*/g, '');
4217
-
4218
- // parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6'
4219
- var test = /(-?)(\d*)(?:n([+\-]?\d*))?/.exec(
4220
- match[2] === "even" && "2n" || match[2] === "odd" && "2n+1" ||
4221
- !/\D/.test( match[2] ) && "0n+" + match[2] || match[2]);
4222
-
4223
- // calculate the numbers (first)n+(last) including if they are negative
4224
- match[2] = (test[1] + (test[2] || 1)) - 0;
4225
- match[3] = test[3] - 0;
4226
- }
4227
- else if ( match[2] ) {
4228
- Sizzle.error( match[0] );
4229
- }
4230
-
4231
- // TODO: Move to normal caching system
4232
- match[0] = done++;
4233
-
4234
- return match;
4235
- },
4236
-
4237
- ATTR: function( match, curLoop, inplace, result, not, isXML ) {
4238
- var name = match[1] = match[1].replace( rBackslash, "" );
4239
-
4240
- if ( !isXML && Expr.attrMap[name] ) {
4241
- match[1] = Expr.attrMap[name];
4242
- }
4243
-
4244
- // Handle if an un-quoted value was used
4245
- match[4] = ( match[4] || match[5] || "" ).replace( rBackslash, "" );
4246
-
4247
- if ( match[2] === "~=" ) {
4248
- match[4] = " " + match[4] + " ";
4249
- }
4250
-
4251
- return match;
4252
- },
4253
-
4254
- PSEUDO: function( match, curLoop, inplace, result, not ) {
4255
- if ( match[1] === "not" ) {
4256
- // If we're dealing with a complex expression, or a simple one
4257
- if ( ( chunker.exec(match[3]) || "" ).length > 1 || /^\w/.test(match[3]) ) {
4258
- match[3] = Sizzle(match[3], null, null, curLoop);
4259
-
4260
- } else {
4261
- var ret = Sizzle.filter(match[3], curLoop, inplace, true ^ not);
4262
-
4263
- if ( !inplace ) {
4264
- result.push.apply( result, ret );
4265
- }
4266
-
4267
- return false;
4268
- }
4269
-
4270
- } else if ( Expr.match.POS.test( match[0] ) || Expr.match.CHILD.test( match[0] ) ) {
4271
- return true;
4272
- }
4273
-
4274
- return match;
4275
- },
4276
-
4277
- POS: function( match ) {
4278
- match.unshift( true );
4279
-
4280
- return match;
4281
- }
4282
- },
4283
-
4284
- filters: {
4285
- enabled: function( elem ) {
4286
- return elem.disabled === false && elem.type !== "hidden";
4287
- },
4288
-
4289
- disabled: function( elem ) {
4290
- return elem.disabled === true;
4291
- },
4292
-
4293
- checked: function( elem ) {
4294
- return elem.checked === true;
4295
- },
4296
-
4297
- selected: function( elem ) {
4298
- // Accessing this property makes selected-by-default
4299
- // options in Safari work properly
4300
- if ( elem.parentNode ) {
4301
- elem.parentNode.selectedIndex;
4302
- }
4303
-
4304
- return elem.selected === true;
4305
- },
4306
-
4307
- parent: function( elem ) {
4308
- return !!elem.firstChild;
4309
- },
4310
-
4311
- empty: function( elem ) {
4312
- return !elem.firstChild;
4313
- },
4314
-
4315
- has: function( elem, i, match ) {
4316
- return !!Sizzle( match[3], elem ).length;
4317
- },
4318
-
4319
- header: function( elem ) {
4320
- return (/h\d/i).test( elem.nodeName );
4321
- },
4322
-
4323
- text: function( elem ) {
4324
- var attr = elem.getAttribute( "type" ), type = elem.type;
4325
- // IE6 and 7 will map elem.type to 'text' for new HTML5 types (search, etc)
4326
- // use getAttribute instead to test this case
4327
- return elem.nodeName.toLowerCase() === "input" && "text" === type && ( attr === type || attr === null );
4328
- },
4329
-
4330
- radio: function( elem ) {
4331
- return elem.nodeName.toLowerCase() === "input" && "radio" === elem.type;
4332
- },
4333
-
4334
- checkbox: function( elem ) {
4335
- return elem.nodeName.toLowerCase() === "input" && "checkbox" === elem.type;
4336
- },
4337
-
4338
- file: function( elem ) {
4339
- return elem.nodeName.toLowerCase() === "input" && "file" === elem.type;
4340
- },
4341
-
4342
- password: function( elem ) {
4343
- return elem.nodeName.toLowerCase() === "input" && "password" === elem.type;
4344
- },
4345
-
4346
- submit: function( elem ) {
4347
- var name = elem.nodeName.toLowerCase();
4348
- return (name === "input" || name === "button") && "submit" === elem.type;
4349
- },
4350
-
4351
- image: function( elem ) {
4352
- return elem.nodeName.toLowerCase() === "input" && "image" === elem.type;
4353
- },
4354
-
4355
- reset: function( elem ) {
4356
- var name = elem.nodeName.toLowerCase();
4357
- return (name === "input" || name === "button") && "reset" === elem.type;
4358
- },
4359
-
4360
- button: function( elem ) {
4361
- var name = elem.nodeName.toLowerCase();
4362
- return name === "input" && "button" === elem.type || name === "button";
4363
- },
4364
-
4365
- input: function( elem ) {
4366
- return (/input|select|textarea|button/i).test( elem.nodeName );
4367
- },
4368
-
4369
- focus: function( elem ) {
4370
- return elem === elem.ownerDocument.activeElement;
4371
- }
4372
- },
4373
- setFilters: {
4374
- first: function( elem, i ) {
4375
- return i === 0;
4376
- },
4377
-
4378
- last: function( elem, i, match, array ) {
4379
- return i === array.length - 1;
4380
- },
4381
-
4382
- even: function( elem, i ) {
4383
- return i % 2 === 0;
4384
- },
4385
-
4386
- odd: function( elem, i ) {
4387
- return i % 2 === 1;
4388
- },
4389
-
4390
- lt: function( elem, i, match ) {
4391
- return i < match[3] - 0;
4392
- },
4393
-
4394
- gt: function( elem, i, match ) {
4395
- return i > match[3] - 0;
4396
- },
4397
-
4398
- nth: function( elem, i, match ) {
4399
- return match[3] - 0 === i;
4400
- },
4401
-
4402
- eq: function( elem, i, match ) {
4403
- return match[3] - 0 === i;
4404
- }
4405
- },
4406
- filter: {
4407
- PSEUDO: function( elem, match, i, array ) {
4408
- var name = match[1],
4409
- filter = Expr.filters[ name ];
4410
-
4411
- if ( filter ) {
4412
- return filter( elem, i, match, array );
4413
-
4414
- } else if ( name === "contains" ) {
4415
- return (elem.textContent || elem.innerText || Sizzle.getText([ elem ]) || "").indexOf(match[3]) >= 0;
4416
-
4417
- } else if ( name === "not" ) {
4418
- var not = match[3];
4419
-
4420
- for ( var j = 0, l = not.length; j < l; j++ ) {
4421
- if ( not[j] === elem ) {
4422
- return false;
4423
- }
4424
- }
4425
-
4426
- return true;
4427
-
4428
- } else {
4429
- Sizzle.error( name );
4430
- }
4431
- },
4432
-
4433
- CHILD: function( elem, match ) {
4434
- var type = match[1],
4435
- node = elem;
4436
-
4437
- switch ( type ) {
4438
- case "only":
4439
- case "first":
4440
- while ( (node = node.previousSibling) ) {
4441
- if ( node.nodeType === 1 ) {
4442
- return false;
4443
- }
4444
- }
4445
-
4446
- if ( type === "first" ) {
4447
- return true;
4448
- }
4449
-
4450
- node = elem;
4451
-
4452
- case "last":
4453
- while ( (node = node.nextSibling) ) {
4454
- if ( node.nodeType === 1 ) {
4455
- return false;
4456
- }
4457
- }
4458
-
4459
- return true;
4460
-
4461
- case "nth":
4462
- var first = match[2],
4463
- last = match[3];
4464
-
4465
- if ( first === 1 && last === 0 ) {
4466
- return true;
4467
- }
4468
-
4469
- var doneName = match[0],
4470
- parent = elem.parentNode;
4471
-
4472
- if ( parent && (parent.sizcache !== doneName || !elem.nodeIndex) ) {
4473
- var count = 0;
4474
-
4475
- for ( node = parent.firstChild; node; node = node.nextSibling ) {
4476
- if ( node.nodeType === 1 ) {
4477
- node.nodeIndex = ++count;
4478
- }
4479
- }
4480
-
4481
- parent.sizcache = doneName;
4482
- }
4483
-
4484
- var diff = elem.nodeIndex - last;
4485
-
4486
- if ( first === 0 ) {
4487
- return diff === 0;
4488
-
4489
- } else {
4490
- return ( diff % first === 0 && diff / first >= 0 );
4491
- }
4492
- }
4493
- },
4494
-
4495
- ID: function( elem, match ) {
4496
- return elem.nodeType === 1 && elem.getAttribute("id") === match;
4497
- },
4498
-
4499
- TAG: function( elem, match ) {
4500
- return (match === "*" && elem.nodeType === 1) || elem.nodeName.toLowerCase() === match;
4501
- },
4502
-
4503
- CLASS: function( elem, match ) {
4504
- return (" " + (elem.className || elem.getAttribute("class")) + " ")
4505
- .indexOf( match ) > -1;
4506
- },
4507
-
4508
- ATTR: function( elem, match ) {
4509
- var name = match[1],
4510
- result = Expr.attrHandle[ name ] ?
4511
- Expr.attrHandle[ name ]( elem ) :
4512
- elem[ name ] != null ?
4513
- elem[ name ] :
4514
- elem.getAttribute( name ),
4515
- value = result + "",
4516
- type = match[2],
4517
- check = match[4];
4518
-
4519
- return result == null ?
4520
- type === "!=" :
4521
- type === "=" ?
4522
- value === check :
4523
- type === "*=" ?
4524
- value.indexOf(check) >= 0 :
4525
- type === "~=" ?
4526
- (" " + value + " ").indexOf(check) >= 0 :
4527
- !check ?
4528
- value && result !== false :
4529
- type === "!=" ?
4530
- value !== check :
4531
- type === "^=" ?
4532
- value.indexOf(check) === 0 :
4533
- type === "$=" ?
4534
- value.substr(value.length - check.length) === check :
4535
- type === "|=" ?
4536
- value === check || value.substr(0, check.length + 1) === check + "-" :
4537
- false;
4538
- },
4539
-
4540
- POS: function( elem, match, i, array ) {
4541
- var name = match[2],
4542
- filter = Expr.setFilters[ name ];
4543
-
4544
- if ( filter ) {
4545
- return filter( elem, i, match, array );
4546
- }
4547
- }
4548
- }
4549
- };
4550
-
4551
- var origPOS = Expr.match.POS,
4552
- fescape = function(all, num){
4553
- return "\\" + (num - 0 + 1);
4554
- };
4555
-
4556
- for ( var type in Expr.match ) {
4557
- Expr.match[ type ] = new RegExp( Expr.match[ type ].source + (/(?![^\[]*\])(?![^\(]*\))/.source) );
4558
- Expr.leftMatch[ type ] = new RegExp( /(^(?:.|\r|\n)*?)/.source + Expr.match[ type ].source.replace(/\\(\d+)/g, fescape) );
4559
- }
4560
-
4561
- var makeArray = function( array, results ) {
4562
- array = Array.prototype.slice.call( array, 0 );
4563
-
4564
- if ( results ) {
4565
- results.push.apply( results, array );
4566
- return results;
4567
- }
4568
-
4569
- return array;
4570
- };
4571
-
4572
- // Perform a simple check to determine if the browser is capable of
4573
- // converting a NodeList to an array using builtin methods.
4574
- // Also verifies that the returned array holds DOM nodes
4575
- // (which is not the case in the Blackberry browser)
4576
- try {
4577
- Array.prototype.slice.call( document.documentElement.childNodes, 0 )[0].nodeType;
4578
-
4579
- // Provide a fallback method if it does not work
4580
- } catch( e ) {
4581
- makeArray = function( array, results ) {
4582
- var i = 0,
4583
- ret = results || [];
4584
-
4585
- if ( toString.call(array) === "[object Array]" ) {
4586
- Array.prototype.push.apply( ret, array );
4587
-
4588
- } else {
4589
- if ( typeof array.length === "number" ) {
4590
- for ( var l = array.length; i < l; i++ ) {
4591
- ret.push( array[i] );
4592
- }
4593
-
4594
- } else {
4595
- for ( ; array[i]; i++ ) {
4596
- ret.push( array[i] );
4597
- }
4598
- }
4599
- }
4600
-
4601
- return ret;
4602
- };
4603
- }
4604
-
4605
- var sortOrder, siblingCheck;
4606
-
4607
- if ( document.documentElement.compareDocumentPosition ) {
4608
- sortOrder = function( a, b ) {
4609
- if ( a === b ) {
4610
- hasDuplicate = true;
4611
- return 0;
4612
- }
4613
-
4614
- if ( !a.compareDocumentPosition || !b.compareDocumentPosition ) {
4615
- return a.compareDocumentPosition ? -1 : 1;
4616
- }
4617
-
4618
- return a.compareDocumentPosition(b) & 4 ? -1 : 1;
4619
- };
4620
-
4621
- } else {
4622
- sortOrder = function( a, b ) {
4623
- // The nodes are identical, we can exit early
4624
- if ( a === b ) {
4625
- hasDuplicate = true;
4626
- return 0;
4627
-
4628
- // Fallback to using sourceIndex (in IE) if it's available on both nodes
4629
- } else if ( a.sourceIndex && b.sourceIndex ) {
4630
- return a.sourceIndex - b.sourceIndex;
4631
- }
4632
-
4633
- var al, bl,
4634
- ap = [],
4635
- bp = [],
4636
- aup = a.parentNode,
4637
- bup = b.parentNode,
4638
- cur = aup;
4639
-
4640
- // If the nodes are siblings (or identical) we can do a quick check
4641
- if ( aup === bup ) {
4642
- return siblingCheck( a, b );
4643
-
4644
- // If no parents were found then the nodes are disconnected
4645
- } else if ( !aup ) {
4646
- return -1;
4647
-
4648
- } else if ( !bup ) {
4649
- return 1;
4650
- }
4651
-
4652
- // Otherwise they're somewhere else in the tree so we need
4653
- // to build up a full list of the parentNodes for comparison
4654
- while ( cur ) {
4655
- ap.unshift( cur );
4656
- cur = cur.parentNode;
4657
- }
4658
-
4659
- cur = bup;
4660
-
4661
- while ( cur ) {
4662
- bp.unshift( cur );
4663
- cur = cur.parentNode;
4664
- }
4665
-
4666
- al = ap.length;
4667
- bl = bp.length;
4668
-
4669
- // Start walking down the tree looking for a discrepancy
4670
- for ( var i = 0; i < al && i < bl; i++ ) {
4671
- if ( ap[i] !== bp[i] ) {
4672
- return siblingCheck( ap[i], bp[i] );
4673
- }
4674
- }
4675
-
4676
- // We ended someplace up the tree so do a sibling check
4677
- return i === al ?
4678
- siblingCheck( a, bp[i], -1 ) :
4679
- siblingCheck( ap[i], b, 1 );
4680
- };
4681
-
4682
- siblingCheck = function( a, b, ret ) {
4683
- if ( a === b ) {
4684
- return ret;
4685
- }
4686
-
4687
- var cur = a.nextSibling;
4688
-
4689
- while ( cur ) {
4690
- if ( cur === b ) {
4691
- return -1;
4692
- }
4693
-
4694
- cur = cur.nextSibling;
4695
- }
4696
-
4697
- return 1;
4698
- };
4699
- }
4700
-
4701
- // Utility function for retreiving the text value of an array of DOM nodes
4702
- Sizzle.getText = function( elems ) {
4703
- var ret = "", elem;
4704
-
4705
- for ( var i = 0; elems[i]; i++ ) {
4706
- elem = elems[i];
4707
-
4708
- // Get the text from text nodes and CDATA nodes
4709
- if ( elem.nodeType === 3 || elem.nodeType === 4 ) {
4710
- ret += elem.nodeValue;
4711
-
4712
- // Traverse everything else, except comment nodes
4713
- } else if ( elem.nodeType !== 8 ) {
4714
- ret += Sizzle.getText( elem.childNodes );
4715
- }
4716
- }
4717
-
4718
- return ret;
4719
- };
4720
-
4721
- // Check to see if the browser returns elements by name when
4722
- // querying by getElementById (and provide a workaround)
4723
- (function(){
4724
- // We're going to inject a fake input element with a specified name
4725
- var form = document.createElement("div"),
4726
- id = "script" + (new Date()).getTime(),
4727
- root = document.documentElement;
4728
-
4729
- form.innerHTML = "<a name='" + id + "'/>";
4730
-
4731
- // Inject it into the root element, check its status, and remove it quickly
4732
- root.insertBefore( form, root.firstChild );
4733
-
4734
- // The workaround has to do additional checks after a getElementById
4735
- // Which slows things down for other browsers (hence the branching)
4736
- if ( document.getElementById( id ) ) {
4737
- Expr.find.ID = function( match, context, isXML ) {
4738
- if ( typeof context.getElementById !== "undefined" && !isXML ) {
4739
- var m = context.getElementById(match[1]);
4740
-
4741
- return m ?
4742
- m.id === match[1] || typeof m.getAttributeNode !== "undefined" && m.getAttributeNode("id").nodeValue === match[1] ?
4743
- [m] :
4744
- undefined :
4745
- [];
4746
- }
4747
- };
4748
-
4749
- Expr.filter.ID = function( elem, match ) {
4750
- var node = typeof elem.getAttributeNode !== "undefined" && elem.getAttributeNode("id");
4751
-
4752
- return elem.nodeType === 1 && node && node.nodeValue === match;
4753
- };
4754
- }
4755
-
4756
- root.removeChild( form );
4757
-
4758
- // release memory in IE
4759
- root = form = null;
4760
- })();
4761
-
4762
- (function(){
4763
- // Check to see if the browser returns only elements
4764
- // when doing getElementsByTagName("*")
4765
-
4766
- // Create a fake element
4767
- var div = document.createElement("div");
4768
- div.appendChild( document.createComment("") );
4769
-
4770
- // Make sure no comments are found
4771
- if ( div.getElementsByTagName("*").length > 0 ) {
4772
- Expr.find.TAG = function( match, context ) {
4773
- var results = context.getElementsByTagName( match[1] );
4774
-
4775
- // Filter out possible comments
4776
- if ( match[1] === "*" ) {
4777
- var tmp = [];
4778
-
4779
- for ( var i = 0; results[i]; i++ ) {
4780
- if ( results[i].nodeType === 1 ) {
4781
- tmp.push( results[i] );
4782
- }
4783
- }
4784
-
4785
- results = tmp;
4786
- }
4787
-
4788
- return results;
4789
- };
4790
- }
4791
-
4792
- // Check to see if an attribute returns normalized href attributes
4793
- div.innerHTML = "<a href='#'></a>";
4794
-
4795
- if ( div.firstChild && typeof div.firstChild.getAttribute !== "undefined" &&
4796
- div.firstChild.getAttribute("href") !== "#" ) {
4797
-
4798
- Expr.attrHandle.href = function( elem ) {
4799
- return elem.getAttribute( "href", 2 );
4800
- };
4801
- }
4802
-
4803
- // release memory in IE
4804
- div = null;
4805
- })();
4806
-
4807
- if ( document.querySelectorAll ) {
4808
- (function(){
4809
- var oldSizzle = Sizzle,
4810
- div = document.createElement("div"),
4811
- id = "__sizzle__";
4812
-
4813
- div.innerHTML = "<p class='TEST'></p>";
4814
-
4815
- // Safari can't handle uppercase or unicode characters when
4816
- // in quirks mode.
4817
- if ( div.querySelectorAll && div.querySelectorAll(".TEST").length === 0 ) {
4818
- return;
4819
- }
4820
-
4821
- Sizzle = function( query, context, extra, seed ) {
4822
- context = context || document;
4823
-
4824
- // Only use querySelectorAll on non-XML documents
4825
- // (ID selectors don't work in non-HTML documents)
4826
- if ( !seed && !Sizzle.isXML(context) ) {
4827
- // See if we find a selector to speed up
4828
- var match = /^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec( query );
4829
-
4830
- if ( match && (context.nodeType === 1 || context.nodeType === 9) ) {
4831
- // Speed-up: Sizzle("TAG")
4832
- if ( match[1] ) {
4833
- return makeArray( context.getElementsByTagName( query ), extra );
4834
-
4835
- // Speed-up: Sizzle(".CLASS")
4836
- } else if ( match[2] && Expr.find.CLASS && context.getElementsByClassName ) {
4837
- return makeArray( context.getElementsByClassName( match[2] ), extra );
4838
- }
4839
- }
4840
-
4841
- if ( context.nodeType === 9 ) {
4842
- // Speed-up: Sizzle("body")
4843
- // The body element only exists once, optimize finding it
4844
- if ( query === "body" && context.body ) {
4845
- return makeArray( [ context.body ], extra );
4846
-
4847
- // Speed-up: Sizzle("#ID")
4848
- } else if ( match && match[3] ) {
4849
- var elem = context.getElementById( match[3] );
4850
-
4851
- // Check parentNode to catch when Blackberry 4.6 returns
4852
- // nodes that are no longer in the document #6963
4853
- if ( elem && elem.parentNode ) {
4854
- // Handle the case where IE and Opera return items
4855
- // by name instead of ID
4856
- if ( elem.id === match[3] ) {
4857
- return makeArray( [ elem ], extra );
4858
- }
4859
-
4860
- } else {
4861
- return makeArray( [], extra );
4862
- }
4863
- }
4864
-
4865
- try {
4866
- return makeArray( context.querySelectorAll(query), extra );
4867
- } catch(qsaError) {}
4868
-
4869
- // qSA works strangely on Element-rooted queries
4870
- // We can work around this by specifying an extra ID on the root
4871
- // and working up from there (Thanks to Andrew Dupont for the technique)
4872
- // IE 8 doesn't work on object elements
4873
- } else if ( context.nodeType === 1 && context.nodeName.toLowerCase() !== "object" ) {
4874
- var oldContext = context,
4875
- old = context.getAttribute( "id" ),
4876
- nid = old || id,
4877
- hasParent = context.parentNode,
4878
- relativeHierarchySelector = /^\s*[+~]/.test( query );
4879
-
4880
- if ( !old ) {
4881
- context.setAttribute( "id", nid );
4882
- } else {
4883
- nid = nid.replace( /'/g, "\\$&" );
4884
- }
4885
- if ( relativeHierarchySelector && hasParent ) {
4886
- context = context.parentNode;
4887
- }
4888
-
4889
- try {
4890
- if ( !relativeHierarchySelector || hasParent ) {
4891
- return makeArray( context.querySelectorAll( "[id='" + nid + "'] " + query ), extra );
4892
- }
4893
-
4894
- } catch(pseudoError) {
4895
- } finally {
4896
- if ( !old ) {
4897
- oldContext.removeAttribute( "id" );
4898
- }
4899
- }
4900
- }
4901
- }
4902
-
4903
- return oldSizzle(query, context, extra, seed);
4904
- };
4905
-
4906
- for ( var prop in oldSizzle ) {
4907
- Sizzle[ prop ] = oldSizzle[ prop ];
4908
- }
4909
-
4910
- // release memory in IE
4911
- div = null;
4912
- })();
4913
- }
4914
-
4915
- (function(){
4916
- var html = document.documentElement,
4917
- matches = html.matchesSelector || html.mozMatchesSelector || html.webkitMatchesSelector || html.msMatchesSelector;
4918
-
4919
- if ( matches ) {
4920
- // Check to see if it's possible to do matchesSelector
4921
- // on a disconnected node (IE 9 fails this)
4922
- var disconnectedMatch = !matches.call( document.createElement( "div" ), "div" ),
4923
- pseudoWorks = false;
4924
-
4925
- try {
4926
- // This should fail with an exception
4927
- // Gecko does not error, returns false instead
4928
- matches.call( document.documentElement, "[test!='']:sizzle" );
4929
-
4930
- } catch( pseudoError ) {
4931
- pseudoWorks = true;
4932
- }
4933
-
4934
- Sizzle.matchesSelector = function( node, expr ) {
4935
- // Make sure that attribute selectors are quoted
4936
- expr = expr.replace(/\=\s*([^'"\]]*)\s*\]/g, "='$1']");
4937
-
4938
- if ( !Sizzle.isXML( node ) ) {
4939
- try {
4940
- if ( pseudoWorks || !Expr.match.PSEUDO.test( expr ) && !/!=/.test( expr ) ) {
4941
- var ret = matches.call( node, expr );
4942
-
4943
- // IE 9's matchesSelector returns false on disconnected nodes
4944
- if ( ret || !disconnectedMatch ||
4945
- // As well, disconnected nodes are said to be in a document
4946
- // fragment in IE 9, so check for that
4947
- node.document && node.document.nodeType !== 11 ) {
4948
- return ret;
4949
- }
4950
- }
4951
- } catch(e) {}
4952
- }
4953
-
4954
- return Sizzle(expr, null, null, [node]).length > 0;
4955
- };
4956
- }
4957
- })();
4958
-
4959
- (function(){
4960
- var div = document.createElement("div");
4961
-
4962
- div.innerHTML = "<div class='test e'></div><div class='test'></div>";
4963
-
4964
- // Opera can't find a second classname (in 9.6)
4965
- // Also, make sure that getElementsByClassName actually exists
4966
- if ( !div.getElementsByClassName || div.getElementsByClassName("e").length === 0 ) {
4967
- return;
4968
- }
4969
-
4970
- // Safari caches class attributes, doesn't catch changes (in 3.2)
4971
- div.lastChild.className = "e";
4972
-
4973
- if ( div.getElementsByClassName("e").length === 1 ) {
4974
- return;
4975
- }
4976
-
4977
- Expr.order.splice(1, 0, "CLASS");
4978
- Expr.find.CLASS = function( match, context, isXML ) {
4979
- if ( typeof context.getElementsByClassName !== "undefined" && !isXML ) {
4980
- return context.getElementsByClassName(match[1]);
4981
- }
4982
- };
4983
-
4984
- // release memory in IE
4985
- div = null;
4986
- })();
4987
-
4988
- function dirNodeCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
4989
- for ( var i = 0, l = checkSet.length; i < l; i++ ) {
4990
- var elem = checkSet[i];
4991
-
4992
- if ( elem ) {
4993
- var match = false;
4994
-
4995
- elem = elem[dir];
4996
-
4997
- while ( elem ) {
4998
- if ( elem.sizcache === doneName ) {
4999
- match = checkSet[elem.sizset];
5000
- break;
5001
- }
5002
-
5003
- if ( elem.nodeType === 1 && !isXML ){
5004
- elem.sizcache = doneName;
5005
- elem.sizset = i;
5006
- }
5007
-
5008
- if ( elem.nodeName.toLowerCase() === cur ) {
5009
- match = elem;
5010
- break;
5011
- }
5012
-
5013
- elem = elem[dir];
5014
- }
5015
-
5016
- checkSet[i] = match;
5017
- }
5018
- }
5019
- }
5020
-
5021
- function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
5022
- for ( var i = 0, l = checkSet.length; i < l; i++ ) {
5023
- var elem = checkSet[i];
5024
-
5025
- if ( elem ) {
5026
- var match = false;
5027
-
5028
- elem = elem[dir];
5029
-
5030
- while ( elem ) {
5031
- if ( elem.sizcache === doneName ) {
5032
- match = checkSet[elem.sizset];
5033
- break;
5034
- }
5035
-
5036
- if ( elem.nodeType === 1 ) {
5037
- if ( !isXML ) {
5038
- elem.sizcache = doneName;
5039
- elem.sizset = i;
5040
- }
5041
-
5042
- if ( typeof cur !== "string" ) {
5043
- if ( elem === cur ) {
5044
- match = true;
5045
- break;
5046
- }
5047
-
5048
- } else if ( Sizzle.filter( cur, [elem] ).length > 0 ) {
5049
- match = elem;
5050
- break;
5051
- }
5052
- }
5053
-
5054
- elem = elem[dir];
5055
- }
5056
-
5057
- checkSet[i] = match;
5058
- }
5059
- }
5060
- }
5061
-
5062
- if ( document.documentElement.contains ) {
5063
- Sizzle.contains = function( a, b ) {
5064
- return a !== b && (a.contains ? a.contains(b) : true);
5065
- };
5066
-
5067
- } else if ( document.documentElement.compareDocumentPosition ) {
5068
- Sizzle.contains = function( a, b ) {
5069
- return !!(a.compareDocumentPosition(b) & 16);
5070
- };
5071
-
5072
- } else {
5073
- Sizzle.contains = function() {
5074
- return false;
5075
- };
5076
- }
5077
-
5078
- Sizzle.isXML = function( elem ) {
5079
- // documentElement is verified for cases where it doesn't yet exist
5080
- // (such as loading iframes in IE - #4833)
5081
- var documentElement = (elem ? elem.ownerDocument || elem : 0).documentElement;
5082
-
5083
- return documentElement ? documentElement.nodeName !== "HTML" : false;
5084
- };
5085
-
5086
- var posProcess = function( selector, context ) {
5087
- var match,
5088
- tmpSet = [],
5089
- later = "",
5090
- root = context.nodeType ? [context] : context;
5091
-
5092
- // Position selectors must be done after the filter
5093
- // And so must :not(positional) so we move all PSEUDOs to the end
5094
- while ( (match = Expr.match.PSEUDO.exec( selector )) ) {
5095
- later += match[0];
5096
- selector = selector.replace( Expr.match.PSEUDO, "" );
5097
- }
5098
-
5099
- selector = Expr.relative[selector] ? selector + "*" : selector;
5100
-
5101
- for ( var i = 0, l = root.length; i < l; i++ ) {
5102
- Sizzle( selector, root[i], tmpSet );
5103
- }
5104
-
5105
- return Sizzle.filter( later, tmpSet );
5106
- };
5107
-
5108
- // EXPOSE
5109
- jQuery.find = Sizzle;
5110
- jQuery.expr = Sizzle.selectors;
5111
- jQuery.expr[":"] = jQuery.expr.filters;
5112
- jQuery.unique = Sizzle.uniqueSort;
5113
- jQuery.text = Sizzle.getText;
5114
- jQuery.isXMLDoc = Sizzle.isXML;
5115
- jQuery.contains = Sizzle.contains;
5116
-
5117
-
5118
- })();
5119
-
5120
-
5121
- var runtil = /Until$/,
5122
- rparentsprev = /^(?:parents|prevUntil|prevAll)/,
5123
- // Note: This RegExp should be improved, or likely pulled from Sizzle
5124
- rmultiselector = /,/,
5125
- isSimple = /^.[^:#\[\.,]*$/,
5126
- slice = Array.prototype.slice,
5127
- POS = jQuery.expr.match.POS,
5128
- // methods guaranteed to produce a unique set when starting from a unique set
5129
- guaranteedUnique = {
5130
- children: true,
5131
- contents: true,
5132
- next: true,
5133
- prev: true
5134
- };
5135
-
5136
- jQuery.fn.extend({
5137
- find: function( selector ) {
5138
- var self = this,
5139
- i, l;
5140
-
5141
- if ( typeof selector !== "string" ) {
5142
- return jQuery( selector ).filter(function() {
5143
- for ( i = 0, l = self.length; i < l; i++ ) {
5144
- if ( jQuery.contains( self[ i ], this ) ) {
5145
- return true;
5146
- }
5147
- }
5148
- });
5149
- }
5150
-
5151
- var ret = this.pushStack( "", "find", selector ),
5152
- length, n, r;
5153
-
5154
- for ( i = 0, l = this.length; i < l; i++ ) {
5155
- length = ret.length;
5156
- jQuery.find( selector, this[i], ret );
5157
-
5158
- if ( i > 0 ) {
5159
- // Make sure that the results are unique
5160
- for ( n = length; n < ret.length; n++ ) {
5161
- for ( r = 0; r < length; r++ ) {
5162
- if ( ret[r] === ret[n] ) {
5163
- ret.splice(n--, 1);
5164
- break;
5165
- }
5166
- }
5167
- }
5168
- }
5169
- }
5170
-
5171
- return ret;
5172
- },
5173
-
5174
- has: function( target ) {
5175
- var targets = jQuery( target );
5176
- return this.filter(function() {
5177
- for ( var i = 0, l = targets.length; i < l; i++ ) {
5178
- if ( jQuery.contains( this, targets[i] ) ) {
5179
- return true;
5180
- }
5181
- }
5182
- });
5183
- },
5184
-
5185
- not: function( selector ) {
5186
- return this.pushStack( winnow(this, selector, false), "not", selector);
5187
- },
5188
-
5189
- filter: function( selector ) {
5190
- return this.pushStack( winnow(this, selector, true), "filter", selector );
5191
- },
5192
-
5193
- is: function( selector ) {
5194
- return !!selector && ( typeof selector === "string" ?
5195
- jQuery.filter( selector, this ).length > 0 :
5196
- this.filter( selector ).length > 0 );
5197
- },
5198
-
5199
- closest: function( selectors, context ) {
5200
- var ret = [], i, l, cur = this[0];
5201
-
5202
- // Array
5203
- if ( jQuery.isArray( selectors ) ) {
5204
- var match, selector,
5205
- matches = {},
5206
- level = 1;
5207
-
5208
- if ( cur && selectors.length ) {
5209
- for ( i = 0, l = selectors.length; i < l; i++ ) {
5210
- selector = selectors[i];
5211
-
5212
- if ( !matches[ selector ] ) {
5213
- matches[ selector ] = POS.test( selector ) ?
5214
- jQuery( selector, context || this.context ) :
5215
- selector;
5216
- }
5217
- }
5218
-
5219
- while ( cur && cur.ownerDocument && cur !== context ) {
5220
- for ( selector in matches ) {
5221
- match = matches[ selector ];
5222
-
5223
- if ( match.jquery ? match.index( cur ) > -1 : jQuery( cur ).is( match ) ) {
5224
- ret.push({ selector: selector, elem: cur, level: level });
5225
- }
5226
- }
5227
-
5228
- cur = cur.parentNode;
5229
- level++;
5230
- }
5231
- }
5232
-
5233
- return ret;
5234
- }
5235
-
5236
- // String
5237
- var pos = POS.test( selectors ) || typeof selectors !== "string" ?
5238
- jQuery( selectors, context || this.context ) :
5239
- 0;
5240
-
5241
- for ( i = 0, l = this.length; i < l; i++ ) {
5242
- cur = this[i];
5243
-
5244
- while ( cur ) {
5245
- if ( pos ? pos.index(cur) > -1 : jQuery.find.matchesSelector(cur, selectors) ) {
5246
- ret.push( cur );
5247
- break;
5248
-
5249
- } else {
5250
- cur = cur.parentNode;
5251
- if ( !cur || !cur.ownerDocument || cur === context || cur.nodeType === 11 ) {
5252
- break;
5253
- }
5254
- }
5255
- }
5256
- }
5257
-
5258
- ret = ret.length > 1 ? jQuery.unique( ret ) : ret;
5259
-
5260
- return this.pushStack( ret, "closest", selectors );
5261
- },
5262
-
5263
- // Determine the position of an element within
5264
- // the matched set of elements
5265
- index: function( elem ) {
5266
- if ( !elem || typeof elem === "string" ) {
5267
- return jQuery.inArray( this[0],
5268
- // If it receives a string, the selector is used
5269
- // If it receives nothing, the siblings are used
5270
- elem ? jQuery( elem ) : this.parent().children() );
5271
- }
5272
- // Locate the position of the desired element
5273
- return jQuery.inArray(
5274
- // If it receives a jQuery object, the first element is used
5275
- elem.jquery ? elem[0] : elem, this );
5276
- },
5277
-
5278
- add: function( selector, context ) {
5279
- var set = typeof selector === "string" ?
5280
- jQuery( selector, context ) :
5281
- jQuery.makeArray( selector && selector.nodeType ? [ selector ] : selector ),
5282
- all = jQuery.merge( this.get(), set );
5283
-
5284
- return this.pushStack( isDisconnected( set[0] ) || isDisconnected( all[0] ) ?
5285
- all :
5286
- jQuery.unique( all ) );
5287
- },
5288
-
5289
- andSelf: function() {
5290
- return this.add( this.prevObject );
5291
- }
5292
- });
5293
-
5294
- // A painfully simple check to see if an element is disconnected
5295
- // from a document (should be improved, where feasible).
5296
- function isDisconnected( node ) {
5297
- return !node || !node.parentNode || node.parentNode.nodeType === 11;
5298
- }
5299
-
5300
- jQuery.each({
5301
- parent: function( elem ) {
5302
- var parent = elem.parentNode;
5303
- return parent && parent.nodeType !== 11 ? parent : null;
5304
- },
5305
- parents: function( elem ) {
5306
- return jQuery.dir( elem, "parentNode" );
5307
- },
5308
- parentsUntil: function( elem, i, until ) {
5309
- return jQuery.dir( elem, "parentNode", until );
5310
- },
5311
- next: function( elem ) {
5312
- return jQuery.nth( elem, 2, "nextSibling" );
5313
- },
5314
- prev: function( elem ) {
5315
- return jQuery.nth( elem, 2, "previousSibling" );
5316
- },
5317
- nextAll: function( elem ) {
5318
- return jQuery.dir( elem, "nextSibling" );
5319
- },
5320
- prevAll: function( elem ) {
5321
- return jQuery.dir( elem, "previousSibling" );
5322
- },
5323
- nextUntil: function( elem, i, until ) {
5324
- return jQuery.dir( elem, "nextSibling", until );
5325
- },
5326
- prevUntil: function( elem, i, until ) {
5327
- return jQuery.dir( elem, "previousSibling", until );
5328
- },
5329
- siblings: function( elem ) {
5330
- return jQuery.sibling( elem.parentNode.firstChild, elem );
5331
- },
5332
- children: function( elem ) {
5333
- return jQuery.sibling( elem.firstChild );
5334
- },
5335
- contents: function( elem ) {
5336
- return jQuery.nodeName( elem, "iframe" ) ?
5337
- elem.contentDocument || elem.contentWindow.document :
5338
- jQuery.makeArray( elem.childNodes );
5339
- }
5340
- }, function( name, fn ) {
5341
- jQuery.fn[ name ] = function( until, selector ) {
5342
- var ret = jQuery.map( this, fn, until ),
5343
- // The variable 'args' was introduced in
5344
- // https://github.com/jquery/jquery/commit/52a0238
5345
- // to work around a bug in Chrome 10 (Dev) and should be removed when the bug is fixed.
5346
- // http://code.google.com/p/v8/issues/detail?id=1050
5347
- args = slice.call(arguments);
5348
-
5349
- if ( !runtil.test( name ) ) {
5350
- selector = until;
5351
- }
5352
-
5353
- if ( selector && typeof selector === "string" ) {
5354
- ret = jQuery.filter( selector, ret );
5355
- }
5356
-
5357
- ret = this.length > 1 && !guaranteedUnique[ name ] ? jQuery.unique( ret ) : ret;
5358
-
5359
- if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( name ) ) {
5360
- ret = ret.reverse();
5361
- }
5362
-
5363
- return this.pushStack( ret, name, args.join(",") );
5364
- };
5365
- });
5366
-
5367
- jQuery.extend({
5368
- filter: function( expr, elems, not ) {
5369
- if ( not ) {
5370
- expr = ":not(" + expr + ")";
5371
- }
5372
-
5373
- return elems.length === 1 ?
5374
- jQuery.find.matchesSelector(elems[0], expr) ? [ elems[0] ] : [] :
5375
- jQuery.find.matches(expr, elems);
5376
- },
5377
-
5378
- dir: function( elem, dir, until ) {
5379
- var matched = [],
5380
- cur = elem[ dir ];
5381
-
5382
- while ( cur && cur.nodeType !== 9 && (until === undefined || cur.nodeType !== 1 || !jQuery( cur ).is( until )) ) {
5383
- if ( cur.nodeType === 1 ) {
5384
- matched.push( cur );
5385
- }
5386
- cur = cur[dir];
5387
- }
5388
- return matched;
5389
- },
5390
-
5391
- nth: function( cur, result, dir, elem ) {
5392
- result = result || 1;
5393
- var num = 0;
5394
-
5395
- for ( ; cur; cur = cur[dir] ) {
5396
- if ( cur.nodeType === 1 && ++num === result ) {
5397
- break;
5398
- }
5399
- }
5400
-
5401
- return cur;
5402
- },
5403
-
5404
- sibling: function( n, elem ) {
5405
- var r = [];
5406
-
5407
- for ( ; n; n = n.nextSibling ) {
5408
- if ( n.nodeType === 1 && n !== elem ) {
5409
- r.push( n );
5410
- }
5411
- }
5412
-
5413
- return r;
5414
- }
5415
- });
5416
-
5417
- // Implement the identical functionality for filter and not
5418
- function winnow( elements, qualifier, keep ) {
5419
-
5420
- // Can't pass null or undefined to indexOf in Firefox 4
5421
- // Set to 0 to skip string check
5422
- qualifier = qualifier || 0;
5423
-
5424
- if ( jQuery.isFunction( qualifier ) ) {
5425
- return jQuery.grep(elements, function( elem, i ) {
5426
- var retVal = !!qualifier.call( elem, i, elem );
5427
- return retVal === keep;
5428
- });
5429
-
5430
- } else if ( qualifier.nodeType ) {
5431
- return jQuery.grep(elements, function( elem, i ) {
5432
- return (elem === qualifier) === keep;
5433
- });
5434
-
5435
- } else if ( typeof qualifier === "string" ) {
5436
- var filtered = jQuery.grep(elements, function( elem ) {
5437
- return elem.nodeType === 1;
5438
- });
5439
-
5440
- if ( isSimple.test( qualifier ) ) {
5441
- return jQuery.filter(qualifier, filtered, !keep);
5442
- } else {
5443
- qualifier = jQuery.filter( qualifier, filtered );
5444
- }
5445
- }
5446
-
5447
- return jQuery.grep(elements, function( elem, i ) {
5448
- return (jQuery.inArray( elem, qualifier ) >= 0) === keep;
5449
- });
5450
- }
5451
-
5452
-
5453
-
5454
-
5455
- var rinlinejQuery = / jQuery\d+="(?:\d+|null)"/g,
5456
- rleadingWhitespace = /^\s+/,
5457
- rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,
5458
- rtagName = /<([\w:]+)/,
5459
- rtbody = /<tbody/i,
5460
- rhtml = /<|&#?\w+;/,
5461
- rnocache = /<(?:script|object|embed|option|style)/i,
5462
- // checked="checked" or checked
5463
- rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i,
5464
- rscriptType = /\/(java|ecma)script/i,
5465
- wrapMap = {
5466
- option: [ 1, "<select multiple='multiple'>", "</select>" ],
5467
- legend: [ 1, "<fieldset>", "</fieldset>" ],
5468
- thead: [ 1, "<table>", "</table>" ],
5469
- tr: [ 2, "<table><tbody>", "</tbody></table>" ],
5470
- td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],
5471
- col: [ 2, "<table><tbody></tbody><colgroup>", "</colgroup></table>" ],
5472
- area: [ 1, "<map>", "</map>" ],
5473
- _default: [ 0, "", "" ]
5474
- };
5475
-
5476
- wrapMap.optgroup = wrapMap.option;
5477
- wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;
5478
- wrapMap.th = wrapMap.td;
5479
-
5480
- // IE can't serialize <link> and <script> tags normally
5481
- if ( !jQuery.support.htmlSerialize ) {
5482
- wrapMap._default = [ 1, "div<div>", "</div>" ];
5483
- }
5484
-
5485
- jQuery.fn.extend({
5486
- text: function( text ) {
5487
- if ( jQuery.isFunction(text) ) {
5488
- return this.each(function(i) {
5489
- var self = jQuery( this );
5490
-
5491
- self.text( text.call(this, i, self.text()) );
5492
- });
5493
- }
5494
-
5495
- if ( typeof text !== "object" && text !== undefined ) {
5496
- return this.empty().append( (this[0] && this[0].ownerDocument || document).createTextNode( text ) );
5497
- }
5498
-
5499
- return jQuery.text( this );
5500
- },
5501
-
5502
- wrapAll: function( html ) {
5503
- if ( jQuery.isFunction( html ) ) {
5504
- return this.each(function(i) {
5505
- jQuery(this).wrapAll( html.call(this, i) );
5506
- });
5507
- }
5508
-
5509
- if ( this[0] ) {
5510
- // The elements to wrap the target around
5511
- var wrap = jQuery( html, this[0].ownerDocument ).eq(0).clone(true);
5512
-
5513
- if ( this[0].parentNode ) {
5514
- wrap.insertBefore( this[0] );
5515
- }
5516
-
5517
- wrap.map(function() {
5518
- var elem = this;
5519
-
5520
- while ( elem.firstChild && elem.firstChild.nodeType === 1 ) {
5521
- elem = elem.firstChild;
5522
- }
5523
-
5524
- return elem;
5525
- }).append( this );
5526
- }
5527
-
5528
- return this;
5529
- },
5530
-
5531
- wrapInner: function( html ) {
5532
- if ( jQuery.isFunction( html ) ) {
5533
- return this.each(function(i) {
5534
- jQuery(this).wrapInner( html.call(this, i) );
5535
- });
5536
- }
5537
-
5538
- return this.each(function() {
5539
- var self = jQuery( this ),
5540
- contents = self.contents();
5541
-
5542
- if ( contents.length ) {
5543
- contents.wrapAll( html );
5544
-
5545
- } else {
5546
- self.append( html );
5547
- }
5548
- });
5549
- },
5550
-
5551
- wrap: function( html ) {
5552
- return this.each(function() {
5553
- jQuery( this ).wrapAll( html );
5554
- });
5555
- },
5556
-
5557
- unwrap: function() {
5558
- return this.parent().each(function() {
5559
- if ( !jQuery.nodeName( this, "body" ) ) {
5560
- jQuery( this ).replaceWith( this.childNodes );
5561
- }
5562
- }).end();
5563
- },
5564
-
5565
- append: function() {
5566
- return this.domManip(arguments, true, function( elem ) {
5567
- if ( this.nodeType === 1 ) {
5568
- this.appendChild( elem );
5569
- }
5570
- });
5571
- },
5572
-
5573
- prepend: function() {
5574
- return this.domManip(arguments, true, function( elem ) {
5575
- if ( this.nodeType === 1 ) {
5576
- this.insertBefore( elem, this.firstChild );
5577
- }
5578
- });
5579
- },
5580
-
5581
- before: function() {
5582
- if ( this[0] && this[0].parentNode ) {
5583
- return this.domManip(arguments, false, function( elem ) {
5584
- this.parentNode.insertBefore( elem, this );
5585
- });
5586
- } else if ( arguments.length ) {
5587
- var set = jQuery(arguments[0]);
5588
- set.push.apply( set, this.toArray() );
5589
- return this.pushStack( set, "before", arguments );
5590
- }
5591
- },
5592
-
5593
- after: function() {
5594
- if ( this[0] && this[0].parentNode ) {
5595
- return this.domManip(arguments, false, function( elem ) {
5596
- this.parentNode.insertBefore( elem, this.nextSibling );
5597
- });
5598
- } else if ( arguments.length ) {
5599
- var set = this.pushStack( this, "after", arguments );
5600
- set.push.apply( set, jQuery(arguments[0]).toArray() );
5601
- return set;
5602
- }
5603
- },
5604
-
5605
- // keepData is for internal use only--do not document
5606
- remove: function( selector, keepData ) {
5607
- for ( var i = 0, elem; (elem = this[i]) != null; i++ ) {
5608
- if ( !selector || jQuery.filter( selector, [ elem ] ).length ) {
5609
- if ( !keepData && elem.nodeType === 1 ) {
5610
- jQuery.cleanData( elem.getElementsByTagName("*") );
5611
- jQuery.cleanData( [ elem ] );
5612
- }
5613
-
5614
- if ( elem.parentNode ) {
5615
- elem.parentNode.removeChild( elem );
5616
- }
5617
- }
5618
- }
5619
-
5620
- return this;
5621
- },
5622
-
5623
- empty: function() {
5624
- for ( var i = 0, elem; (elem = this[i]) != null; i++ ) {
5625
- // Remove element nodes and prevent memory leaks
5626
- if ( elem.nodeType === 1 ) {
5627
- jQuery.cleanData( elem.getElementsByTagName("*") );
5628
- }
5629
-
5630
- // Remove any remaining nodes
5631
- while ( elem.firstChild ) {
5632
- elem.removeChild( elem.firstChild );
5633
- }
5634
- }
5635
-
5636
- return this;
5637
- },
5638
-
5639
- clone: function( dataAndEvents, deepDataAndEvents ) {
5640
- dataAndEvents = dataAndEvents == null ? false : dataAndEvents;
5641
- deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;
5642
-
5643
- return this.map( function () {
5644
- return jQuery.clone( this, dataAndEvents, deepDataAndEvents );
5645
- });
5646
- },
5647
-
5648
- html: function( value ) {
5649
- if ( value === undefined ) {
5650
- return this[0] && this[0].nodeType === 1 ?
5651
- this[0].innerHTML.replace(rinlinejQuery, "") :
5652
- null;
5653
-
5654
- // See if we can take a shortcut and just use innerHTML
5655
- } else if ( typeof value === "string" && !rnocache.test( value ) &&
5656
- (jQuery.support.leadingWhitespace || !rleadingWhitespace.test( value )) &&
5657
- !wrapMap[ (rtagName.exec( value ) || ["", ""])[1].toLowerCase() ] ) {
5658
-
5659
- value = value.replace(rxhtmlTag, "<$1></$2>");
5660
-
5661
- try {
5662
- for ( var i = 0, l = this.length; i < l; i++ ) {
5663
- // Remove element nodes and prevent memory leaks
5664
- if ( this[i].nodeType === 1 ) {
5665
- jQuery.cleanData( this[i].getElementsByTagName("*") );
5666
- this[i].innerHTML = value;
5667
- }
5668
- }
5669
-
5670
- // If using innerHTML throws an exception, use the fallback method
5671
- } catch(e) {
5672
- this.empty().append( value );
5673
- }
5674
-
5675
- } else if ( jQuery.isFunction( value ) ) {
5676
- this.each(function(i){
5677
- var self = jQuery( this );
5678
-
5679
- self.html( value.call(this, i, self.html()) );
5680
- });
5681
-
5682
- } else {
5683
- this.empty().append( value );
5684
- }
5685
-
5686
- return this;
5687
- },
5688
-
5689
- replaceWith: function( value ) {
5690
- if ( this[0] && this[0].parentNode ) {
5691
- // Make sure that the elements are removed from the DOM before they are inserted
5692
- // this can help fix replacing a parent with child elements
5693
- if ( jQuery.isFunction( value ) ) {
5694
- return this.each(function(i) {
5695
- var self = jQuery(this), old = self.html();
5696
- self.replaceWith( value.call( this, i, old ) );
5697
- });
5698
- }
5699
-
5700
- if ( typeof value !== "string" ) {
5701
- value = jQuery( value ).detach();
5702
- }
5703
-
5704
- return this.each(function() {
5705
- var next = this.nextSibling,
5706
- parent = this.parentNode;
5707
-
5708
- jQuery( this ).remove();
5709
-
5710
- if ( next ) {
5711
- jQuery(next).before( value );
5712
- } else {
5713
- jQuery(parent).append( value );
5714
- }
5715
- });
5716
- } else {
5717
- return this.length ?
5718
- this.pushStack( jQuery(jQuery.isFunction(value) ? value() : value), "replaceWith", value ) :
5719
- this;
5720
- }
5721
- },
5722
-
5723
- detach: function( selector ) {
5724
- return this.remove( selector, true );
5725
- },
5726
-
5727
- domManip: function( args, table, callback ) {
5728
- var results, first, fragment, parent,
5729
- value = args[0],
5730
- scripts = [];
5731
-
5732
- // We can't cloneNode fragments that contain checked, in WebKit
5733
- if ( !jQuery.support.checkClone && arguments.length === 3 && typeof value === "string" && rchecked.test( value ) ) {
5734
- return this.each(function() {
5735
- jQuery(this).domManip( args, table, callback, true );
5736
- });
5737
- }
5738
-
5739
- if ( jQuery.isFunction(value) ) {
5740
- return this.each(function(i) {
5741
- var self = jQuery(this);
5742
- args[0] = value.call(this, i, table ? self.html() : undefined);
5743
- self.domManip( args, table, callback );
5744
- });
5745
- }
5746
-
5747
- if ( this[0] ) {
5748
- parent = value && value.parentNode;
5749
-
5750
- // If we're in a fragment, just use that instead of building a new one
5751
- if ( jQuery.support.parentNode && parent && parent.nodeType === 11 && parent.childNodes.length === this.length ) {
5752
- results = { fragment: parent };
5753
-
5754
- } else {
5755
- results = jQuery.buildFragment( args, this, scripts );
5756
- }
5757
-
5758
- fragment = results.fragment;
5759
-
5760
- if ( fragment.childNodes.length === 1 ) {
5761
- first = fragment = fragment.firstChild;
5762
- } else {
5763
- first = fragment.firstChild;
5764
- }
5765
-
5766
- if ( first ) {
5767
- table = table && jQuery.nodeName( first, "tr" );
5768
-
5769
- for ( var i = 0, l = this.length, lastIndex = l - 1; i < l; i++ ) {
5770
- callback.call(
5771
- table ?
5772
- root(this[i], first) :
5773
- this[i],
5774
- // Make sure that we do not leak memory by inadvertently discarding
5775
- // the original fragment (which might have attached data) instead of
5776
- // using it; in addition, use the original fragment object for the last
5777
- // item instead of first because it can end up being emptied incorrectly
5778
- // in certain situations (Bug #8070).
5779
- // Fragments from the fragment cache must always be cloned and never used
5780
- // in place.
5781
- results.cacheable || (l > 1 && i < lastIndex) ?
5782
- jQuery.clone( fragment, true, true ) :
5783
- fragment
5784
- );
5785
- }
5786
- }
5787
-
5788
- if ( scripts.length ) {
5789
- jQuery.each( scripts, evalScript );
5790
- }
5791
- }
5792
-
5793
- return this;
5794
- }
5795
- });
5796
-
5797
- function root( elem, cur ) {
5798
- return jQuery.nodeName(elem, "table") ?
5799
- (elem.getElementsByTagName("tbody")[0] ||
5800
- elem.appendChild(elem.ownerDocument.createElement("tbody"))) :
5801
- elem;
5802
- }
5803
-
5804
- function cloneCopyEvent( src, dest ) {
5805
-
5806
- if ( dest.nodeType !== 1 || !jQuery.hasData( src ) ) {
5807
- return;
5808
- }
5809
-
5810
- var internalKey = jQuery.expando,
5811
- oldData = jQuery.data( src ),
5812
- curData = jQuery.data( dest, oldData );
5813
-
5814
- // Switch to use the internal data object, if it exists, for the next
5815
- // stage of data copying
5816
- if ( (oldData = oldData[ internalKey ]) ) {
5817
- var events = oldData.events;
5818
- curData = curData[ internalKey ] = jQuery.extend({}, oldData);
5819
-
5820
- if ( events ) {
5821
- delete curData.handle;
5822
- curData.events = {};
5823
-
5824
- for ( var type in events ) {
5825
- for ( var i = 0, l = events[ type ].length; i < l; i++ ) {
5826
- jQuery.event.add( dest, type + ( events[ type ][ i ].namespace ? "." : "" ) + events[ type ][ i ].namespace, events[ type ][ i ], events[ type ][ i ].data );
5827
- }
5828
- }
5829
- }
5830
- }
5831
- }
5832
-
5833
- function cloneFixAttributes( src, dest ) {
5834
- var nodeName;
5835
-
5836
- // We do not need to do anything for non-Elements
5837
- if ( dest.nodeType !== 1 ) {
5838
- return;
5839
- }
5840
-
5841
- // clearAttributes removes the attributes, which we don't want,
5842
- // but also removes the attachEvent events, which we *do* want
5843
- if ( dest.clearAttributes ) {
5844
- dest.clearAttributes();
5845
- }
5846
-
5847
- // mergeAttributes, in contrast, only merges back on the
5848
- // original attributes, not the events
5849
- if ( dest.mergeAttributes ) {
5850
- dest.mergeAttributes( src );
5851
- }
5852
-
5853
- nodeName = dest.nodeName.toLowerCase();
5854
-
5855
- // IE6-8 fail to clone children inside object elements that use
5856
- // the proprietary classid attribute value (rather than the type
5857
- // attribute) to identify the type of content to display
5858
- if ( nodeName === "object" ) {
5859
- dest.outerHTML = src.outerHTML;
5860
-
5861
- } else if ( nodeName === "input" && (src.type === "checkbox" || src.type === "radio") ) {
5862
- // IE6-8 fails to persist the checked state of a cloned checkbox
5863
- // or radio button. Worse, IE6-7 fail to give the cloned element
5864
- // a checked appearance if the defaultChecked value isn't also set
5865
- if ( src.checked ) {
5866
- dest.defaultChecked = dest.checked = src.checked;
5867
- }
5868
-
5869
- // IE6-7 get confused and end up setting the value of a cloned
5870
- // checkbox/radio button to an empty string instead of "on"
5871
- if ( dest.value !== src.value ) {
5872
- dest.value = src.value;
5873
- }
5874
-
5875
- // IE6-8 fails to return the selected option to the default selected
5876
- // state when cloning options
5877
- } else if ( nodeName === "option" ) {
5878
- dest.selected = src.defaultSelected;
5879
-
5880
- // IE6-8 fails to set the defaultValue to the correct value when
5881
- // cloning other types of input fields
5882
- } else if ( nodeName === "input" || nodeName === "textarea" ) {
5883
- dest.defaultValue = src.defaultValue;
5884
- }
5885
-
5886
- // Event data gets referenced instead of copied if the expando
5887
- // gets copied too
5888
- dest.removeAttribute( jQuery.expando );
5889
- }
5890
-
5891
- jQuery.buildFragment = function( args, nodes, scripts ) {
5892
- var fragment, cacheable, cacheresults,
5893
- doc = (nodes && nodes[0] ? nodes[0].ownerDocument || nodes[0] : document);
5894
-
5895
- // Only cache "small" (1/2 KB) HTML strings that are associated with the main document
5896
- // Cloning options loses the selected state, so don't cache them
5897
- // IE 6 doesn't like it when you put <object> or <embed> elements in a fragment
5898
- // Also, WebKit does not clone 'checked' attributes on cloneNode, so don't cache
5899
- if ( args.length === 1 && typeof args[0] === "string" && args[0].length < 512 && doc === document &&
5900
- args[0].charAt(0) === "<" && !rnocache.test( args[0] ) && (jQuery.support.checkClone || !rchecked.test( args[0] )) ) {
5901
-
5902
- cacheable = true;
5903
-
5904
- cacheresults = jQuery.fragments[ args[0] ];
5905
- if ( cacheresults && cacheresults !== 1 ) {
5906
- fragment = cacheresults;
5907
- }
5908
- }
5909
-
5910
- if ( !fragment ) {
5911
- fragment = doc.createDocumentFragment();
5912
- jQuery.clean( args, doc, fragment, scripts );
5913
- }
5914
-
5915
- if ( cacheable ) {
5916
- jQuery.fragments[ args[0] ] = cacheresults ? fragment : 1;
5917
- }
5918
-
5919
- return { fragment: fragment, cacheable: cacheable };
5920
- };
5921
-
5922
- jQuery.fragments = {};
5923
-
5924
- jQuery.each({
5925
- appendTo: "append",
5926
- prependTo: "prepend",
5927
- insertBefore: "before",
5928
- insertAfter: "after",
5929
- replaceAll: "replaceWith"
5930
- }, function( name, original ) {
5931
- jQuery.fn[ name ] = function( selector ) {
5932
- var ret = [],
5933
- insert = jQuery( selector ),
5934
- parent = this.length === 1 && this[0].parentNode;
5935
-
5936
- if ( parent && parent.nodeType === 11 && parent.childNodes.length === 1 && insert.length === 1 ) {
5937
- insert[ original ]( this[0] );
5938
- return this;
5939
-
5940
- } else {
5941
- for ( var i = 0, l = insert.length; i < l; i++ ) {
5942
- var elems = (i > 0 ? this.clone(true) : this).get();
5943
- jQuery( insert[i] )[ original ]( elems );
5944
- ret = ret.concat( elems );
5945
- }
5946
-
5947
- return this.pushStack( ret, name, insert.selector );
5948
- }
5949
- };
5950
- });
5951
-
5952
- function getAll( elem ) {
5953
- if ( "getElementsByTagName" in elem ) {
5954
- return elem.getElementsByTagName( "*" );
5955
-
5956
- } else if ( "querySelectorAll" in elem ) {
5957
- return elem.querySelectorAll( "*" );
5958
-
5959
- } else {
5960
- return [];
5961
- }
5962
- }
5963
-
5964
- // Used in clean, fixes the defaultChecked property
5965
- function fixDefaultChecked( elem ) {
5966
- if ( elem.type === "checkbox" || elem.type === "radio" ) {
5967
- elem.defaultChecked = elem.checked;
5968
- }
5969
- }
5970
- // Finds all inputs and passes them to fixDefaultChecked
5971
- function findInputs( elem ) {
5972
- if ( jQuery.nodeName( elem, "input" ) ) {
5973
- fixDefaultChecked( elem );
5974
- } else if ( elem.getElementsByTagName ) {
5975
- jQuery.grep( elem.getElementsByTagName("input"), fixDefaultChecked );
5976
- }
5977
- }
5978
-
5979
- jQuery.extend({
5980
- clone: function( elem, dataAndEvents, deepDataAndEvents ) {
5981
- var clone = elem.cloneNode(true),
5982
- srcElements,
5983
- destElements,
5984
- i;
5985
-
5986
- if ( (!jQuery.support.noCloneEvent || !jQuery.support.noCloneChecked) &&
5987
- (elem.nodeType === 1 || elem.nodeType === 11) && !jQuery.isXMLDoc(elem) ) {
5988
- // IE copies events bound via attachEvent when using cloneNode.
5989
- // Calling detachEvent on the clone will also remove the events
5990
- // from the original. In order to get around this, we use some
5991
- // proprietary methods to clear the events. Thanks to MooTools
5992
- // guys for this hotness.
5993
-
5994
- cloneFixAttributes( elem, clone );
5995
-
5996
- // Using Sizzle here is crazy slow, so we use getElementsByTagName
5997
- // instead
5998
- srcElements = getAll( elem );
5999
- destElements = getAll( clone );
6000
-
6001
- // Weird iteration because IE will replace the length property
6002
- // with an element if you are cloning the body and one of the
6003
- // elements on the page has a name or id of "length"
6004
- for ( i = 0; srcElements[i]; ++i ) {
6005
- cloneFixAttributes( srcElements[i], destElements[i] );
6006
- }
6007
- }
6008
-
6009
- // Copy the events from the original to the clone
6010
- if ( dataAndEvents ) {
6011
- cloneCopyEvent( elem, clone );
6012
-
6013
- if ( deepDataAndEvents ) {
6014
- srcElements = getAll( elem );
6015
- destElements = getAll( clone );
6016
-
6017
- for ( i = 0; srcElements[i]; ++i ) {
6018
- cloneCopyEvent( srcElements[i], destElements[i] );
6019
- }
6020
- }
6021
- }
6022
-
6023
- // Return the cloned set
6024
- return clone;
6025
- },
6026
-
6027
- clean: function( elems, context, fragment, scripts ) {
6028
- var checkScriptType;
6029
-
6030
- context = context || document;
6031
-
6032
- // !context.createElement fails in IE with an error but returns typeof 'object'
6033
- if ( typeof context.createElement === "undefined" ) {
6034
- context = context.ownerDocument || context[0] && context[0].ownerDocument || document;
6035
- }
6036
-
6037
- var ret = [], j;
6038
-
6039
- for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) {
6040
- if ( typeof elem === "number" ) {
6041
- elem += "";
6042
- }
6043
-
6044
- if ( !elem ) {
6045
- continue;
6046
- }
6047
-
6048
- // Convert html string into DOM nodes
6049
- if ( typeof elem === "string" ) {
6050
- if ( !rhtml.test( elem ) ) {
6051
- elem = context.createTextNode( elem );
6052
- } else {
6053
- // Fix "XHTML"-style tags in all browsers
6054
- elem = elem.replace(rxhtmlTag, "<$1></$2>");
6055
-
6056
- // Trim whitespace, otherwise indexOf won't work as expected
6057
- var tag = (rtagName.exec( elem ) || ["", ""])[1].toLowerCase(),
6058
- wrap = wrapMap[ tag ] || wrapMap._default,
6059
- depth = wrap[0],
6060
- div = context.createElement("div");
6061
-
6062
- // Go to html and back, then peel off extra wrappers
6063
- div.innerHTML = wrap[1] + elem + wrap[2];
6064
-
6065
- // Move to the right depth
6066
- while ( depth-- ) {
6067
- div = div.lastChild;
6068
- }
6069
-
6070
- // Remove IE's autoinserted <tbody> from table fragments
6071
- if ( !jQuery.support.tbody ) {
6072
-
6073
- // String was a <table>, *may* have spurious <tbody>
6074
- var hasBody = rtbody.test(elem),
6075
- tbody = tag === "table" && !hasBody ?
6076
- div.firstChild && div.firstChild.childNodes :
6077
-
6078
- // String was a bare <thead> or <tfoot>
6079
- wrap[1] === "<table>" && !hasBody ?
6080
- div.childNodes :
6081
- [];
6082
-
6083
- for ( j = tbody.length - 1; j >= 0 ; --j ) {
6084
- if ( jQuery.nodeName( tbody[ j ], "tbody" ) && !tbody[ j ].childNodes.length ) {
6085
- tbody[ j ].parentNode.removeChild( tbody[ j ] );
6086
- }
6087
- }
6088
- }
6089
-
6090
- // IE completely kills leading whitespace when innerHTML is used
6091
- if ( !jQuery.support.leadingWhitespace && rleadingWhitespace.test( elem ) ) {
6092
- div.insertBefore( context.createTextNode( rleadingWhitespace.exec(elem)[0] ), div.firstChild );
6093
- }
6094
-
6095
- elem = div.childNodes;
6096
- }
6097
- }
6098
-
6099
- // Resets defaultChecked for any radios and checkboxes
6100
- // about to be appended to the DOM in IE 6/7 (#8060)
6101
- var len;
6102
- if ( !jQuery.support.appendChecked ) {
6103
- if ( elem[0] && typeof (len = elem.length) === "number" ) {
6104
- for ( j = 0; j < len; j++ ) {
6105
- findInputs( elem[j] );
6106
- }
6107
- } else {
6108
- findInputs( elem );
6109
- }
6110
- }
6111
-
6112
- if ( elem.nodeType ) {
6113
- ret.push( elem );
6114
- } else {
6115
- ret = jQuery.merge( ret, elem );
6116
- }
6117
- }
6118
-
6119
- if ( fragment ) {
6120
- checkScriptType = function( elem ) {
6121
- return !elem.type || rscriptType.test( elem.type );
6122
- };
6123
- for ( i = 0; ret[i]; i++ ) {
6124
- if ( scripts && jQuery.nodeName( ret[i], "script" ) && (!ret[i].type || ret[i].type.toLowerCase() === "text/javascript") ) {
6125
- scripts.push( ret[i].parentNode ? ret[i].parentNode.removeChild( ret[i] ) : ret[i] );
6126
-
6127
- } else {
6128
- if ( ret[i].nodeType === 1 ) {
6129
- var jsTags = jQuery.grep( ret[i].getElementsByTagName( "script" ), checkScriptType );
6130
-
6131
- ret.splice.apply( ret, [i + 1, 0].concat( jsTags ) );
6132
- }
6133
- fragment.appendChild( ret[i] );
6134
- }
6135
- }
6136
- }
6137
-
6138
- return ret;
6139
- },
6140
-
6141
- cleanData: function( elems ) {
6142
- var data, id, cache = jQuery.cache, internalKey = jQuery.expando, special = jQuery.event.special,
6143
- deleteExpando = jQuery.support.deleteExpando;
6144
-
6145
- for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) {
6146
- if ( elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()] ) {
6147
- continue;
6148
- }
6149
-
6150
- id = elem[ jQuery.expando ];
6151
-
6152
- if ( id ) {
6153
- data = cache[ id ] && cache[ id ][ internalKey ];
6154
-
6155
- if ( data && data.events ) {
6156
- for ( var type in data.events ) {
6157
- if ( special[ type ] ) {
6158
- jQuery.event.remove( elem, type );
6159
-
6160
- // This is a shortcut to avoid jQuery.event.remove's overhead
6161
- } else {
6162
- jQuery.removeEvent( elem, type, data.handle );
6163
- }
6164
- }
6165
-
6166
- // Null the DOM reference to avoid IE6/7/8 leak (#7054)
6167
- if ( data.handle ) {
6168
- data.handle.elem = null;
6169
- }
6170
- }
6171
-
6172
- if ( deleteExpando ) {
6173
- delete elem[ jQuery.expando ];
6174
-
6175
- } else if ( elem.removeAttribute ) {
6176
- elem.removeAttribute( jQuery.expando );
6177
- }
6178
-
6179
- delete cache[ id ];
6180
- }
6181
- }
6182
- }
6183
- });
6184
-
6185
- function evalScript( i, elem ) {
6186
- if ( elem.src ) {
6187
- jQuery.ajax({
6188
- url: elem.src,
6189
- async: false,
6190
- dataType: "script"
6191
- });
6192
- } else {
6193
- jQuery.globalEval( elem.text || elem.textContent || elem.innerHTML || "" );
6194
- }
6195
-
6196
- if ( elem.parentNode ) {
6197
- elem.parentNode.removeChild( elem );
6198
- }
6199
- }
6200
-
6201
-
6202
-
6203
-
6204
- var ralpha = /alpha\([^)]*\)/i,
6205
- ropacity = /opacity=([^)]*)/,
6206
- rdashAlpha = /-([a-z])/ig,
6207
- // fixed for IE9, see #8346
6208
- rupper = /([A-Z]|^ms)/g,
6209
- rnumpx = /^-?\d+(?:px)?$/i,
6210
- rnum = /^-?\d/,
6211
- rrelNum = /^[+\-]=/,
6212
- rrelNumFilter = /[^+\-\.\de]+/g,
6213
-
6214
- cssShow = { position: "absolute", visibility: "hidden", display: "block" },
6215
- cssWidth = [ "Left", "Right" ],
6216
- cssHeight = [ "Top", "Bottom" ],
6217
- curCSS,
6218
-
6219
- getComputedStyle,
6220
- currentStyle,
6221
-
6222
- fcamelCase = function( all, letter ) {
6223
- return letter.toUpperCase();
6224
- };
6225
-
6226
- jQuery.fn.css = function( name, value ) {
6227
- // Setting 'undefined' is a no-op
6228
- if ( arguments.length === 2 && value === undefined ) {
6229
- return this;
6230
- }
6231
-
6232
- return jQuery.access( this, name, value, true, function( elem, name, value ) {
6233
- return value !== undefined ?
6234
- jQuery.style( elem, name, value ) :
6235
- jQuery.css( elem, name );
6236
- });
6237
- };
6238
-
6239
- jQuery.extend({
6240
- // Add in style property hooks for overriding the default
6241
- // behavior of getting and setting a style property
6242
- cssHooks: {
6243
- opacity: {
6244
- get: function( elem, computed ) {
6245
- if ( computed ) {
6246
- // We should always get a number back from opacity
6247
- var ret = curCSS( elem, "opacity", "opacity" );
6248
- return ret === "" ? "1" : ret;
6249
-
6250
- } else {
6251
- return elem.style.opacity;
6252
- }
6253
- }
6254
- }
6255
- },
6256
-
6257
- // Exclude the following css properties to add px
6258
- cssNumber: {
6259
- "zIndex": true,
6260
- "fontWeight": true,
6261
- "opacity": true,
6262
- "zoom": true,
6263
- "lineHeight": true,
6264
- "widows": true,
6265
- "orphans": true
6266
- },
6267
-
6268
- // Add in properties whose names you wish to fix before
6269
- // setting or getting the value
6270
- cssProps: {
6271
- // normalize float css property
6272
- "float": jQuery.support.cssFloat ? "cssFloat" : "styleFloat"
6273
- },
6274
-
6275
- // Get and set the style property on a DOM Node
6276
- style: function( elem, name, value, extra ) {
6277
- // Don't set styles on text and comment nodes
6278
- if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || !elem.style ) {
6279
- return;
6280
- }
6281
-
6282
- // Make sure that we're working with the right name
6283
- var ret, type, origName = jQuery.camelCase( name ),
6284
- style = elem.style, hooks = jQuery.cssHooks[ origName ];
6285
-
6286
- name = jQuery.cssProps[ origName ] || origName;
6287
-
6288
- // Check if we're setting a value
6289
- if ( value !== undefined ) {
6290
- type = typeof value;
6291
-
6292
- // Make sure that NaN and null values aren't set. See: #7116
6293
- if ( type === "number" && isNaN( value ) || value == null ) {
6294
- return;
6295
- }
6296
-
6297
- // convert relative number strings (+= or -=) to relative numbers. #7345
6298
- if ( type === "string" && rrelNum.test( value ) ) {
6299
- value = +value.replace( rrelNumFilter, "" ) + parseFloat( jQuery.css( elem, name ) );
6300
- }
6301
-
6302
- // If a number was passed in, add 'px' to the (except for certain CSS properties)
6303
- if ( type === "number" && !jQuery.cssNumber[ origName ] ) {
6304
- value += "px";
6305
- }
6306
-
6307
- // If a hook was provided, use that value, otherwise just set the specified value
6308
- if ( !hooks || !("set" in hooks) || (value = hooks.set( elem, value )) !== undefined ) {
6309
- // Wrapped to prevent IE from throwing errors when 'invalid' values are provided
6310
- // Fixes bug #5509
6311
- try {
6312
- style[ name ] = value;
6313
- } catch(e) {}
6314
- }
6315
-
6316
- } else {
6317
- // If a hook was provided get the non-computed value from there
6318
- if ( hooks && "get" in hooks && (ret = hooks.get( elem, false, extra )) !== undefined ) {
6319
- return ret;
6320
- }
6321
-
6322
- // Otherwise just get the value from the style object
6323
- return style[ name ];
6324
- }
6325
- },
6326
-
6327
- css: function( elem, name, extra ) {
6328
- var ret, hooks;
6329
-
6330
- // Make sure that we're working with the right name
6331
- name = jQuery.camelCase( name );
6332
- hooks = jQuery.cssHooks[ name ];
6333
- name = jQuery.cssProps[ name ] || name;
6334
-
6335
- // cssFloat needs a special treatment
6336
- if ( name === "cssFloat" ) {
6337
- name = "float";
6338
- }
6339
-
6340
- // If a hook was provided get the computed value from there
6341
- if ( hooks && "get" in hooks && (ret = hooks.get( elem, true, extra )) !== undefined ) {
6342
- return ret;
6343
-
6344
- // Otherwise, if a way to get the computed value exists, use that
6345
- } else if ( curCSS ) {
6346
- return curCSS( elem, name );
6347
- }
6348
- },
6349
-
6350
- // A method for quickly swapping in/out CSS properties to get correct calculations
6351
- swap: function( elem, options, callback ) {
6352
- var old = {};
6353
-
6354
- // Remember the old values, and insert the new ones
6355
- for ( var name in options ) {
6356
- old[ name ] = elem.style[ name ];
6357
- elem.style[ name ] = options[ name ];
6358
- }
6359
-
6360
- callback.call( elem );
6361
-
6362
- // Revert the old values
6363
- for ( name in options ) {
6364
- elem.style[ name ] = old[ name ];
6365
- }
6366
- },
6367
-
6368
- camelCase: function( string ) {
6369
- return string.replace( rdashAlpha, fcamelCase );
6370
- }
6371
- });
6372
-
6373
- // DEPRECATED, Use jQuery.css() instead
6374
- jQuery.curCSS = jQuery.css;
6375
-
6376
- jQuery.each(["height", "width"], function( i, name ) {
6377
- jQuery.cssHooks[ name ] = {
6378
- get: function( elem, computed, extra ) {
6379
- var val;
6380
-
6381
- if ( computed ) {
6382
- if ( elem.offsetWidth !== 0 ) {
6383
- val = getWH( elem, name, extra );
6384
-
6385
- } else {
6386
- jQuery.swap( elem, cssShow, function() {
6387
- val = getWH( elem, name, extra );
6388
- });
6389
- }
6390
-
6391
- if ( val <= 0 ) {
6392
- val = curCSS( elem, name, name );
6393
-
6394
- if ( val === "0px" && currentStyle ) {
6395
- val = currentStyle( elem, name, name );
6396
- }
6397
-
6398
- if ( val != null ) {
6399
- // Should return "auto" instead of 0, use 0 for
6400
- // temporary backwards-compat
6401
- return val === "" || val === "auto" ? "0px" : val;
6402
- }
6403
- }
6404
-
6405
- if ( val < 0 || val == null ) {
6406
- val = elem.style[ name ];
6407
-
6408
- // Should return "auto" instead of 0, use 0 for
6409
- // temporary backwards-compat
6410
- return val === "" || val === "auto" ? "0px" : val;
6411
- }
6412
-
6413
- return typeof val === "string" ? val : val + "px";
6414
- }
6415
- },
6416
-
6417
- set: function( elem, value ) {
6418
- if ( rnumpx.test( value ) ) {
6419
- // ignore negative width and height values #1599
6420
- value = parseFloat(value);
6421
-
6422
- if ( value >= 0 ) {
6423
- return value + "px";
6424
- }
6425
-
6426
- } else {
6427
- return value;
6428
- }
6429
- }
6430
- };
6431
- });
6432
-
6433
- if ( !jQuery.support.opacity ) {
6434
- jQuery.cssHooks.opacity = {
6435
- get: function( elem, computed ) {
6436
- // IE uses filters for opacity
6437
- return ropacity.test( (computed && elem.currentStyle ? elem.currentStyle.filter : elem.style.filter) || "" ) ?
6438
- ( parseFloat( RegExp.$1 ) / 100 ) + "" :
6439
- computed ? "1" : "";
6440
- },
6441
-
6442
- set: function( elem, value ) {
6443
- var style = elem.style,
6444
- currentStyle = elem.currentStyle;
6445
-
6446
- // IE has trouble with opacity if it does not have layout
6447
- // Force it by setting the zoom level
6448
- style.zoom = 1;
6449
-
6450
- // Set the alpha filter to set the opacity
6451
- var opacity = jQuery.isNaN( value ) ?
6452
- "" :
6453
- "alpha(opacity=" + value * 100 + ")",
6454
- filter = currentStyle && currentStyle.filter || style.filter || "";
6455
-
6456
- style.filter = ralpha.test( filter ) ?
6457
- filter.replace( ralpha, opacity ) :
6458
- filter + " " + opacity;
6459
- }
6460
- };
6461
- }
6462
-
6463
- jQuery(function() {
6464
- // This hook cannot be added until DOM ready because the support test
6465
- // for it is not run until after DOM ready
6466
- if ( !jQuery.support.reliableMarginRight ) {
6467
- jQuery.cssHooks.marginRight = {
6468
- get: function( elem, computed ) {
6469
- // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right
6470
- // Work around by temporarily setting element display to inline-block
6471
- var ret;
6472
- jQuery.swap( elem, { "display": "inline-block" }, function() {
6473
- if ( computed ) {
6474
- ret = curCSS( elem, "margin-right", "marginRight" );
6475
- } else {
6476
- ret = elem.style.marginRight;
6477
- }
6478
- });
6479
- return ret;
6480
- }
6481
- };
6482
- }
6483
- });
6484
-
6485
- if ( document.defaultView && document.defaultView.getComputedStyle ) {
6486
- getComputedStyle = function( elem, name ) {
6487
- var ret, defaultView, computedStyle;
6488
-
6489
- name = name.replace( rupper, "-$1" ).toLowerCase();
6490
-
6491
- if ( !(defaultView = elem.ownerDocument.defaultView) ) {
6492
- return undefined;
6493
- }
6494
-
6495
- if ( (computedStyle = defaultView.getComputedStyle( elem, null )) ) {
6496
- ret = computedStyle.getPropertyValue( name );
6497
- if ( ret === "" && !jQuery.contains( elem.ownerDocument.documentElement, elem ) ) {
6498
- ret = jQuery.style( elem, name );
6499
- }
6500
- }
6501
-
6502
- return ret;
6503
- };
6504
- }
6505
-
6506
- if ( document.documentElement.currentStyle ) {
6507
- currentStyle = function( elem, name ) {
6508
- var left,
6509
- ret = elem.currentStyle && elem.currentStyle[ name ],
6510
- rsLeft = elem.runtimeStyle && elem.runtimeStyle[ name ],
6511
- style = elem.style;
6512
-
6513
- // From the awesome hack by Dean Edwards
6514
- // http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291
6515
-
6516
- // If we're not dealing with a regular pixel number
6517
- // but a number that has a weird ending, we need to convert it to pixels
6518
- if ( !rnumpx.test( ret ) && rnum.test( ret ) ) {
6519
- // Remember the original values
6520
- left = style.left;
6521
-
6522
- // Put in the new values to get a computed value out
6523
- if ( rsLeft ) {
6524
- elem.runtimeStyle.left = elem.currentStyle.left;
6525
- }
6526
- style.left = name === "fontSize" ? "1em" : (ret || 0);
6527
- ret = style.pixelLeft + "px";
6528
-
6529
- // Revert the changed values
6530
- style.left = left;
6531
- if ( rsLeft ) {
6532
- elem.runtimeStyle.left = rsLeft;
6533
- }
6534
- }
6535
-
6536
- return ret === "" ? "auto" : ret;
6537
- };
6538
- }
6539
-
6540
- curCSS = getComputedStyle || currentStyle;
6541
-
6542
- function getWH( elem, name, extra ) {
6543
- var which = name === "width" ? cssWidth : cssHeight,
6544
- val = name === "width" ? elem.offsetWidth : elem.offsetHeight;
6545
-
6546
- if ( extra === "border" ) {
6547
- return val;
6548
- }
6549
-
6550
- jQuery.each( which, function() {
6551
- if ( !extra ) {
6552
- val -= parseFloat(jQuery.css( elem, "padding" + this )) || 0;
6553
- }
6554
-
6555
- if ( extra === "margin" ) {
6556
- val += parseFloat(jQuery.css( elem, "margin" + this )) || 0;
6557
-
6558
- } else {
6559
- val -= parseFloat(jQuery.css( elem, "border" + this + "Width" )) || 0;
6560
- }
6561
- });
6562
-
6563
- return val;
6564
- }
6565
-
6566
- if ( jQuery.expr && jQuery.expr.filters ) {
6567
- jQuery.expr.filters.hidden = function( elem ) {
6568
- var width = elem.offsetWidth,
6569
- height = elem.offsetHeight;
6570
-
6571
- return (width === 0 && height === 0) || (!jQuery.support.reliableHiddenOffsets && (elem.style.display || jQuery.css( elem, "display" )) === "none");
6572
- };
6573
-
6574
- jQuery.expr.filters.visible = function( elem ) {
6575
- return !jQuery.expr.filters.hidden( elem );
6576
- };
6577
- }
6578
-
6579
-
6580
-
6581
-
6582
- var r20 = /%20/g,
6583
- rbracket = /\[\]$/,
6584
- rCRLF = /\r?\n/g,
6585
- rhash = /#.*$/,
6586
- rheaders = /^(.*?):[ \t]*([^\r\n]*)\r?$/mg, // IE leaves an \r character at EOL
6587
- rinput = /^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,
6588
- // #7653, #8125, #8152: local protocol detection
6589
- rlocalProtocol = /^(?:about|app|app\-storage|.+\-extension|file|widget):$/,
6590
- rnoContent = /^(?:GET|HEAD)$/,
6591
- rprotocol = /^\/\//,
6592
- rquery = /\?/,
6593
- rscript = /<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,
6594
- rselectTextarea = /^(?:select|textarea)/i,
6595
- rspacesAjax = /\s+/,
6596
- rts = /([?&])_=[^&]*/,
6597
- rurl = /^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,
6598
-
6599
- // Keep a copy of the old load method
6600
- _load = jQuery.fn.load,
6601
-
6602
- /* Prefilters
6603
- * 1) They are useful to introduce custom dataTypes (see ajax/jsonp.js for an example)
6604
- * 2) These are called:
6605
- * - BEFORE asking for a transport
6606
- * - AFTER param serialization (s.data is a string if s.processData is true)
6607
- * 3) key is the dataType
6608
- * 4) the catchall symbol "*" can be used
6609
- * 5) execution will start with transport dataType and THEN continue down to "*" if needed
6610
- */
6611
- prefilters = {},
6612
-
6613
- /* Transports bindings
6614
- * 1) key is the dataType
6615
- * 2) the catchall symbol "*" can be used
6616
- * 3) selection will start with transport dataType and THEN go to "*" if needed
6617
- */
6618
- transports = {},
6619
-
6620
- // Document location
6621
- ajaxLocation,
6622
-
6623
- // Document location segments
6624
- ajaxLocParts;
6625
-
6626
- // #8138, IE may throw an exception when accessing
6627
- // a field from window.location if document.domain has been set
6628
- try {
6629
- ajaxLocation = location.href;
6630
- } catch( e ) {
6631
- // Use the href attribute of an A element
6632
- // since IE will modify it given document.location
6633
- ajaxLocation = document.createElement( "a" );
6634
- ajaxLocation.href = "";
6635
- ajaxLocation = ajaxLocation.href;
6636
- }
6637
-
6638
- // Segment location into parts
6639
- ajaxLocParts = rurl.exec( ajaxLocation.toLowerCase() ) || [];
6640
-
6641
- // Base "constructor" for jQuery.ajaxPrefilter and jQuery.ajaxTransport
6642
- function addToPrefiltersOrTransports( structure ) {
6643
-
6644
- // dataTypeExpression is optional and defaults to "*"
6645
- return function( dataTypeExpression, func ) {
6646
-
6647
- if ( typeof dataTypeExpression !== "string" ) {
6648
- func = dataTypeExpression;
6649
- dataTypeExpression = "*";
6650
- }
6651
-
6652
- if ( jQuery.isFunction( func ) ) {
6653
- var dataTypes = dataTypeExpression.toLowerCase().split( rspacesAjax ),
6654
- i = 0,
6655
- length = dataTypes.length,
6656
- dataType,
6657
- list,
6658
- placeBefore;
6659
-
6660
- // For each dataType in the dataTypeExpression
6661
- for(; i < length; i++ ) {
6662
- dataType = dataTypes[ i ];
6663
- // We control if we're asked to add before
6664
- // any existing element
6665
- placeBefore = /^\+/.test( dataType );
6666
- if ( placeBefore ) {
6667
- dataType = dataType.substr( 1 ) || "*";
6668
- }
6669
- list = structure[ dataType ] = structure[ dataType ] || [];
6670
- // then we add to the structure accordingly
6671
- list[ placeBefore ? "unshift" : "push" ]( func );
6672
- }
6673
- }
6674
- };
6675
- }
6676
-
6677
- // Base inspection function for prefilters and transports
6678
- function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR,
6679
- dataType /* internal */, inspected /* internal */ ) {
6680
-
6681
- dataType = dataType || options.dataTypes[ 0 ];
6682
- inspected = inspected || {};
6683
-
6684
- inspected[ dataType ] = true;
6685
-
6686
- var list = structure[ dataType ],
6687
- i = 0,
6688
- length = list ? list.length : 0,
6689
- executeOnly = ( structure === prefilters ),
6690
- selection;
6691
-
6692
- for(; i < length && ( executeOnly || !selection ); i++ ) {
6693
- selection = list[ i ]( options, originalOptions, jqXHR );
6694
- // If we got redirected to another dataType
6695
- // we try there if executing only and not done already
6696
- if ( typeof selection === "string" ) {
6697
- if ( !executeOnly || inspected[ selection ] ) {
6698
- selection = undefined;
6699
- } else {
6700
- options.dataTypes.unshift( selection );
6701
- selection = inspectPrefiltersOrTransports(
6702
- structure, options, originalOptions, jqXHR, selection, inspected );
6703
- }
6704
- }
6705
- }
6706
- // If we're only executing or nothing was selected
6707
- // we try the catchall dataType if not done already
6708
- if ( ( executeOnly || !selection ) && !inspected[ "*" ] ) {
6709
- selection = inspectPrefiltersOrTransports(
6710
- structure, options, originalOptions, jqXHR, "*", inspected );
6711
- }
6712
- // unnecessary when only executing (prefilters)
6713
- // but it'll be ignored by the caller in that case
6714
- return selection;
6715
- }
6716
-
6717
- jQuery.fn.extend({
6718
- load: function( url, params, callback ) {
6719
- if ( typeof url !== "string" && _load ) {
6720
- return _load.apply( this, arguments );
6721
-
6722
- // Don't do a request if no elements are being requested
6723
- } else if ( !this.length ) {
6724
- return this;
6725
- }
6726
-
6727
- var off = url.indexOf( " " );
6728
- if ( off >= 0 ) {
6729
- var selector = url.slice( off, url.length );
6730
- url = url.slice( 0, off );
6731
- }
6732
-
6733
- // Default to a GET request
6734
- var type = "GET";
6735
-
6736
- // If the second parameter was provided
6737
- if ( params ) {
6738
- // If it's a function
6739
- if ( jQuery.isFunction( params ) ) {
6740
- // We assume that it's the callback
6741
- callback = params;
6742
- params = undefined;
6743
-
6744
- // Otherwise, build a param string
6745
- } else if ( typeof params === "object" ) {
6746
- params = jQuery.param( params, jQuery.ajaxSettings.traditional );
6747
- type = "POST";
6748
- }
6749
- }
6750
-
6751
- var self = this;
6752
-
6753
- // Request the remote document
6754
- jQuery.ajax({
6755
- url: url,
6756
- type: type,
6757
- dataType: "html",
6758
- data: params,
6759
- // Complete callback (responseText is used internally)
6760
- complete: function( jqXHR, status, responseText ) {
6761
- // Store the response as specified by the jqXHR object
6762
- responseText = jqXHR.responseText;
6763
- // If successful, inject the HTML into all the matched elements
6764
- if ( jqXHR.isResolved() ) {
6765
- // #4825: Get the actual response in case
6766
- // a dataFilter is present in ajaxSettings
6767
- jqXHR.done(function( r ) {
6768
- responseText = r;
6769
- });
6770
- // See if a selector was specified
6771
- self.html( selector ?
6772
- // Create a dummy div to hold the results
6773
- jQuery("<div>")
6774
- // inject the contents of the document in, removing the scripts
6775
- // to avoid any 'Permission Denied' errors in IE
6776
- .append(responseText.replace(rscript, ""))
6777
-
6778
- // Locate the specified elements
6779
- .find(selector) :
6780
-
6781
- // If not, just inject the full result
6782
- responseText );
6783
- }
6784
-
6785
- if ( callback ) {
6786
- self.each( callback, [ responseText, status, jqXHR ] );
6787
- }
6788
- }
6789
- });
6790
-
6791
- return this;
6792
- },
6793
-
6794
- serialize: function() {
6795
- return jQuery.param( this.serializeArray() );
6796
- },
6797
-
6798
- serializeArray: function() {
6799
- return this.map(function(){
6800
- return this.elements ? jQuery.makeArray( this.elements ) : this;
6801
- })
6802
- .filter(function(){
6803
- return this.name && !this.disabled &&
6804
- ( this.checked || rselectTextarea.test( this.nodeName ) ||
6805
- rinput.test( this.type ) );
6806
- })
6807
- .map(function( i, elem ){
6808
- var val = jQuery( this ).val();
6809
-
6810
- return val == null ?
6811
- null :
6812
- jQuery.isArray( val ) ?
6813
- jQuery.map( val, function( val, i ){
6814
- return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
6815
- }) :
6816
- { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };
6817
- }).get();
6818
- }
6819
- });
6820
-
6821
- // Attach a bunch of functions for handling common AJAX events
6822
- jQuery.each( "ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split( " " ), function( i, o ){
6823
- jQuery.fn[ o ] = function( f ){
6824
- return this.bind( o, f );
6825
- };
6826
- });
6827
-
6828
- jQuery.each( [ "get", "post" ], function( i, method ) {
6829
- jQuery[ method ] = function( url, data, callback, type ) {
6830
- // shift arguments if data argument was omitted
6831
- if ( jQuery.isFunction( data ) ) {
6832
- type = type || callback;
6833
- callback = data;
6834
- data = undefined;
6835
- }
6836
-
6837
- return jQuery.ajax({
6838
- type: method,
6839
- url: url,
6840
- data: data,
6841
- success: callback,
6842
- dataType: type
6843
- });
6844
- };
6845
- });
6846
-
6847
- jQuery.extend({
6848
-
6849
- getScript: function( url, callback ) {
6850
- return jQuery.get( url, undefined, callback, "script" );
6851
- },
6852
-
6853
- getJSON: function( url, data, callback ) {
6854
- return jQuery.get( url, data, callback, "json" );
6855
- },
6856
-
6857
- // Creates a full fledged settings object into target
6858
- // with both ajaxSettings and settings fields.
6859
- // If target is omitted, writes into ajaxSettings.
6860
- ajaxSetup: function ( target, settings ) {
6861
- if ( !settings ) {
6862
- // Only one parameter, we extend ajaxSettings
6863
- settings = target;
6864
- target = jQuery.extend( true, jQuery.ajaxSettings, settings );
6865
- } else {
6866
- // target was provided, we extend into it
6867
- jQuery.extend( true, target, jQuery.ajaxSettings, settings );
6868
- }
6869
- // Flatten fields we don't want deep extended
6870
- for( var field in { context: 1, url: 1 } ) {
6871
- if ( field in settings ) {
6872
- target[ field ] = settings[ field ];
6873
- } else if( field in jQuery.ajaxSettings ) {
6874
- target[ field ] = jQuery.ajaxSettings[ field ];
6875
- }
6876
- }
6877
- return target;
6878
- },
6879
-
6880
- ajaxSettings: {
6881
- url: ajaxLocation,
6882
- isLocal: rlocalProtocol.test( ajaxLocParts[ 1 ] ),
6883
- global: true,
6884
- type: "GET",
6885
- contentType: "application/x-www-form-urlencoded",
6886
- processData: true,
6887
- async: true,
6888
- /*
6889
- timeout: 0,
6890
- data: null,
6891
- dataType: null,
6892
- username: null,
6893
- password: null,
6894
- cache: null,
6895
- traditional: false,
6896
- headers: {},
6897
- */
6898
-
6899
- accepts: {
6900
- xml: "application/xml, text/xml",
6901
- html: "text/html",
6902
- text: "text/plain",
6903
- json: "application/json, text/javascript",
6904
- "*": "*/*"
6905
- },
6906
-
6907
- contents: {
6908
- xml: /xml/,
6909
- html: /html/,
6910
- json: /json/
6911
- },
6912
-
6913
- responseFields: {
6914
- xml: "responseXML",
6915
- text: "responseText"
6916
- },
6917
-
6918
- // List of data converters
6919
- // 1) key format is "source_type destination_type" (a single space in-between)
6920
- // 2) the catchall symbol "*" can be used for source_type
6921
- converters: {
6922
-
6923
- // Convert anything to text
6924
- "* text": window.String,
6925
-
6926
- // Text to html (true = no transformation)
6927
- "text html": true,
6928
-
6929
- // Evaluate text as a json expression
6930
- "text json": jQuery.parseJSON,
6931
-
6932
- // Parse text as xml
6933
- "text xml": jQuery.parseXML
6934
- }
6935
- },
6936
-
6937
- ajaxPrefilter: addToPrefiltersOrTransports( prefilters ),
6938
- ajaxTransport: addToPrefiltersOrTransports( transports ),
6939
-
6940
- // Main method
6941
- ajax: function( url, options ) {
6942
-
6943
- // If url is an object, simulate pre-1.5 signature
6944
- if ( typeof url === "object" ) {
6945
- options = url;
6946
- url = undefined;
6947
- }
6948
-
6949
- // Force options to be an object
6950
- options = options || {};
6951
-
6952
- var // Create the final options object
6953
- s = jQuery.ajaxSetup( {}, options ),
6954
- // Callbacks context
6955
- callbackContext = s.context || s,
6956
- // Context for global events
6957
- // It's the callbackContext if one was provided in the options
6958
- // and if it's a DOM node or a jQuery collection
6959
- globalEventContext = callbackContext !== s &&
6960
- ( callbackContext.nodeType || callbackContext instanceof jQuery ) ?
6961
- jQuery( callbackContext ) : jQuery.event,
6962
- // Deferreds
6963
- deferred = jQuery.Deferred(),
6964
- completeDeferred = jQuery._Deferred(),
6965
- // Status-dependent callbacks
6966
- statusCode = s.statusCode || {},
6967
- // ifModified key
6968
- ifModifiedKey,
6969
- // Headers (they are sent all at once)
6970
- requestHeaders = {},
6971
- requestHeadersNames = {},
6972
- // Response headers
6973
- responseHeadersString,
6974
- responseHeaders,
6975
- // transport
6976
- transport,
6977
- // timeout handle
6978
- timeoutTimer,
6979
- // Cross-domain detection vars
6980
- parts,
6981
- // The jqXHR state
6982
- state = 0,
6983
- // To know if global events are to be dispatched
6984
- fireGlobals,
6985
- // Loop variable
6986
- i,
6987
- // Fake xhr
6988
- jqXHR = {
6989
-
6990
- readyState: 0,
6991
-
6992
- // Caches the header
6993
- setRequestHeader: function( name, value ) {
6994
- if ( !state ) {
6995
- var lname = name.toLowerCase();
6996
- name = requestHeadersNames[ lname ] = requestHeadersNames[ lname ] || name;
6997
- requestHeaders[ name ] = value;
6998
- }
6999
- return this;
7000
- },
7001
-
7002
- // Raw string
7003
- getAllResponseHeaders: function() {
7004
- return state === 2 ? responseHeadersString : null;
7005
- },
7006
-
7007
- // Builds headers hashtable if needed
7008
- getResponseHeader: function( key ) {
7009
- var match;
7010
- if ( state === 2 ) {
7011
- if ( !responseHeaders ) {
7012
- responseHeaders = {};
7013
- while( ( match = rheaders.exec( responseHeadersString ) ) ) {
7014
- responseHeaders[ match[1].toLowerCase() ] = match[ 2 ];
7015
- }
7016
- }
7017
- match = responseHeaders[ key.toLowerCase() ];
7018
- }
7019
- return match === undefined ? null : match;
7020
- },
7021
-
7022
- // Overrides response content-type header
7023
- overrideMimeType: function( type ) {
7024
- if ( !state ) {
7025
- s.mimeType = type;
7026
- }
7027
- return this;
7028
- },
7029
-
7030
- // Cancel the request
7031
- abort: function( statusText ) {
7032
- statusText = statusText || "abort";
7033
- if ( transport ) {
7034
- transport.abort( statusText );
7035
- }
7036
- done( 0, statusText );
7037
- return this;
7038
- }
7039
- };
7040
-
7041
- // Callback for when everything is done
7042
- // It is defined here because jslint complains if it is declared
7043
- // at the end of the function (which would be more logical and readable)
7044
- function done( status, statusText, responses, headers ) {
7045
-
7046
- // Called once
7047
- if ( state === 2 ) {
7048
- return;
7049
- }
7050
-
7051
- // State is "done" now
7052
- state = 2;
7053
-
7054
- // Clear timeout if it exists
7055
- if ( timeoutTimer ) {
7056
- clearTimeout( timeoutTimer );
7057
- }
7058
-
7059
- // Dereference transport for early garbage collection
7060
- // (no matter how long the jqXHR object will be used)
7061
- transport = undefined;
7062
-
7063
- // Cache response headers
7064
- responseHeadersString = headers || "";
7065
-
7066
- // Set readyState
7067
- jqXHR.readyState = status ? 4 : 0;
7068
-
7069
- var isSuccess,
7070
- success,
7071
- error,
7072
- response = responses ? ajaxHandleResponses( s, jqXHR, responses ) : undefined,
7073
- lastModified,
7074
- etag;
7075
-
7076
- // If successful, handle type chaining
7077
- if ( status >= 200 && status < 300 || status === 304 ) {
7078
-
7079
- // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.
7080
- if ( s.ifModified ) {
7081
-
7082
- if ( ( lastModified = jqXHR.getResponseHeader( "Last-Modified" ) ) ) {
7083
- jQuery.lastModified[ ifModifiedKey ] = lastModified;
7084
- }
7085
- if ( ( etag = jqXHR.getResponseHeader( "Etag" ) ) ) {
7086
- jQuery.etag[ ifModifiedKey ] = etag;
7087
- }
7088
- }
7089
-
7090
- // If not modified
7091
- if ( status === 304 ) {
7092
-
7093
- statusText = "notmodified";
7094
- isSuccess = true;
7095
-
7096
- // If we have data
7097
- } else {
7098
-
7099
- try {
7100
- success = ajaxConvert( s, response );
7101
- statusText = "success";
7102
- isSuccess = true;
7103
- } catch(e) {
7104
- // We have a parsererror
7105
- statusText = "parsererror";
7106
- error = e;
7107
- }
7108
- }
7109
- } else {
7110
- // We extract error from statusText
7111
- // then normalize statusText and status for non-aborts
7112
- error = statusText;
7113
- if( !statusText || status ) {
7114
- statusText = "error";
7115
- if ( status < 0 ) {
7116
- status = 0;
7117
- }
7118
- }
7119
- }
7120
-
7121
- // Set data for the fake xhr object
7122
- jqXHR.status = status;
7123
- jqXHR.statusText = statusText;
7124
-
7125
- // Success/Error
7126
- if ( isSuccess ) {
7127
- deferred.resolveWith( callbackContext, [ success, statusText, jqXHR ] );
7128
- } else {
7129
- deferred.rejectWith( callbackContext, [ jqXHR, statusText, error ] );
7130
- }
7131
-
7132
- // Status-dependent callbacks
7133
- jqXHR.statusCode( statusCode );
7134
- statusCode = undefined;
7135
-
7136
- if ( fireGlobals ) {
7137
- globalEventContext.trigger( "ajax" + ( isSuccess ? "Success" : "Error" ),
7138
- [ jqXHR, s, isSuccess ? success : error ] );
7139
- }
7140
-
7141
- // Complete
7142
- completeDeferred.resolveWith( callbackContext, [ jqXHR, statusText ] );
7143
-
7144
- if ( fireGlobals ) {
7145
- globalEventContext.trigger( "ajaxComplete", [ jqXHR, s] );
7146
- // Handle the global AJAX counter
7147
- if ( !( --jQuery.active ) ) {
7148
- jQuery.event.trigger( "ajaxStop" );
7149
- }
7150
- }
7151
- }
7152
-
7153
- // Attach deferreds
7154
- deferred.promise( jqXHR );
7155
- jqXHR.success = jqXHR.done;
7156
- jqXHR.error = jqXHR.fail;
7157
- jqXHR.complete = completeDeferred.done;
7158
-
7159
- // Status-dependent callbacks
7160
- jqXHR.statusCode = function( map ) {
7161
- if ( map ) {
7162
- var tmp;
7163
- if ( state < 2 ) {
7164
- for( tmp in map ) {
7165
- statusCode[ tmp ] = [ statusCode[tmp], map[tmp] ];
7166
- }
7167
- } else {
7168
- tmp = map[ jqXHR.status ];
7169
- jqXHR.then( tmp, tmp );
7170
- }
7171
- }
7172
- return this;
7173
- };
7174
-
7175
- // Remove hash character (#7531: and string promotion)
7176
- // Add protocol if not provided (#5866: IE7 issue with protocol-less urls)
7177
- // We also use the url parameter if available
7178
- s.url = ( ( url || s.url ) + "" ).replace( rhash, "" ).replace( rprotocol, ajaxLocParts[ 1 ] + "//" );
7179
-
7180
- // Extract dataTypes list
7181
- s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().split( rspacesAjax );
7182
-
7183
- // Determine if a cross-domain request is in order
7184
- if ( s.crossDomain == null ) {
7185
- parts = rurl.exec( s.url.toLowerCase() );
7186
- s.crossDomain = !!( parts &&
7187
- ( parts[ 1 ] != ajaxLocParts[ 1 ] || parts[ 2 ] != ajaxLocParts[ 2 ] ||
7188
- ( parts[ 3 ] || ( parts[ 1 ] === "http:" ? 80 : 443 ) ) !=
7189
- ( ajaxLocParts[ 3 ] || ( ajaxLocParts[ 1 ] === "http:" ? 80 : 443 ) ) )
7190
- );
7191
- }
7192
-
7193
- // Convert data if not already a string
7194
- if ( s.data && s.processData && typeof s.data !== "string" ) {
7195
- s.data = jQuery.param( s.data, s.traditional );
7196
- }
7197
-
7198
- // Apply prefilters
7199
- inspectPrefiltersOrTransports( prefilters, s, options, jqXHR );
7200
-
7201
- // If request was aborted inside a prefiler, stop there
7202
- if ( state === 2 ) {
7203
- return false;
7204
- }
7205
-
7206
- // We can fire global events as of now if asked to
7207
- fireGlobals = s.global;
7208
-
7209
- // Uppercase the type
7210
- s.type = s.type.toUpperCase();
7211
-
7212
- // Determine if request has content
7213
- s.hasContent = !rnoContent.test( s.type );
7214
-
7215
- // Watch for a new set of requests
7216
- if ( fireGlobals && jQuery.active++ === 0 ) {
7217
- jQuery.event.trigger( "ajaxStart" );
7218
- }
7219
-
7220
- // More options handling for requests with no content
7221
- if ( !s.hasContent ) {
7222
-
7223
- // If data is available, append data to url
7224
- if ( s.data ) {
7225
- s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.data;
7226
- }
7227
-
7228
- // Get ifModifiedKey before adding the anti-cache parameter
7229
- ifModifiedKey = s.url;
7230
-
7231
- // Add anti-cache in url if needed
7232
- if ( s.cache === false ) {
7233
-
7234
- var ts = jQuery.now(),
7235
- // try replacing _= if it is there
7236
- ret = s.url.replace( rts, "$1_=" + ts );
7237
-
7238
- // if nothing was replaced, add timestamp to the end
7239
- s.url = ret + ( (ret === s.url ) ? ( rquery.test( s.url ) ? "&" : "?" ) + "_=" + ts : "" );
7240
- }
7241
- }
7242
-
7243
- // Set the correct header, if data is being sent
7244
- if ( s.data && s.hasContent && s.contentType !== false || options.contentType ) {
7245
- jqXHR.setRequestHeader( "Content-Type", s.contentType );
7246
- }
7247
-
7248
- // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.
7249
- if ( s.ifModified ) {
7250
- ifModifiedKey = ifModifiedKey || s.url;
7251
- if ( jQuery.lastModified[ ifModifiedKey ] ) {
7252
- jqXHR.setRequestHeader( "If-Modified-Since", jQuery.lastModified[ ifModifiedKey ] );
7253
- }
7254
- if ( jQuery.etag[ ifModifiedKey ] ) {
7255
- jqXHR.setRequestHeader( "If-None-Match", jQuery.etag[ ifModifiedKey ] );
7256
- }
7257
- }
7258
-
7259
- // Set the Accepts header for the server, depending on the dataType
7260
- jqXHR.setRequestHeader(
7261
- "Accept",
7262
- s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[0] ] ?
7263
- s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", */*; q=0.01" : "" ) :
7264
- s.accepts[ "*" ]
7265
- );
7266
-
7267
- // Check for headers option
7268
- for ( i in s.headers ) {
7269
- jqXHR.setRequestHeader( i, s.headers[ i ] );
7270
- }
7271
-
7272
- // Allow custom headers/mimetypes and early abort
7273
- if ( s.beforeSend && ( s.beforeSend.call( callbackContext, jqXHR, s ) === false || state === 2 ) ) {
7274
- // Abort if not done already
7275
- jqXHR.abort();
7276
- return false;
7277
-
7278
- }
7279
-
7280
- // Install callbacks on deferreds
7281
- for ( i in { success: 1, error: 1, complete: 1 } ) {
7282
- jqXHR[ i ]( s[ i ] );
7283
- }
7284
-
7285
- // Get transport
7286
- transport = inspectPrefiltersOrTransports( transports, s, options, jqXHR );
7287
-
7288
- // If no transport, we auto-abort
7289
- if ( !transport ) {
7290
- done( -1, "No Transport" );
7291
- } else {
7292
- jqXHR.readyState = 1;
7293
- // Send global event
7294
- if ( fireGlobals ) {
7295
- globalEventContext.trigger( "ajaxSend", [ jqXHR, s ] );
7296
- }
7297
- // Timeout
7298
- if ( s.async && s.timeout > 0 ) {
7299
- timeoutTimer = setTimeout( function(){
7300
- jqXHR.abort( "timeout" );
7301
- }, s.timeout );
7302
- }
7303
-
7304
- try {
7305
- state = 1;
7306
- transport.send( requestHeaders, done );
7307
- } catch (e) {
7308
- // Propagate exception as error if not done
7309
- if ( status < 2 ) {
7310
- done( -1, e );
7311
- // Simply rethrow otherwise
7312
- } else {
7313
- jQuery.error( e );
7314
- }
7315
- }
7316
- }
7317
-
7318
- return jqXHR;
7319
- },
7320
-
7321
- // Serialize an array of form elements or a set of
7322
- // key/values into a query string
7323
- param: function( a, traditional ) {
7324
- var s = [],
7325
- add = function( key, value ) {
7326
- // If value is a function, invoke it and return its value
7327
- value = jQuery.isFunction( value ) ? value() : value;
7328
- s[ s.length ] = encodeURIComponent( key ) + "=" + encodeURIComponent( value );
7329
- };
7330
-
7331
- // Set traditional to true for jQuery <= 1.3.2 behavior.
7332
- if ( traditional === undefined ) {
7333
- traditional = jQuery.ajaxSettings.traditional;
7334
- }
7335
-
7336
- // If an array was passed in, assume that it is an array of form elements.
7337
- if ( jQuery.isArray( a ) || ( a.jquery && !jQuery.isPlainObject( a ) ) ) {
7338
- // Serialize the form elements
7339
- jQuery.each( a, function() {
7340
- add( this.name, this.value );
7341
- });
7342
-
7343
- } else {
7344
- // If traditional, encode the "old" way (the way 1.3.2 or older
7345
- // did it), otherwise encode params recursively.
7346
- for ( var prefix in a ) {
7347
- buildParams( prefix, a[ prefix ], traditional, add );
7348
- }
7349
- }
7350
-
7351
- // Return the resulting serialization
7352
- return s.join( "&" ).replace( r20, "+" );
7353
- }
7354
- });
7355
-
7356
- function buildParams( prefix, obj, traditional, add ) {
7357
- if ( jQuery.isArray( obj ) ) {
7358
- // Serialize array item.
7359
- jQuery.each( obj, function( i, v ) {
7360
- if ( traditional || rbracket.test( prefix ) ) {
7361
- // Treat each array item as a scalar.
7362
- add( prefix, v );
7363
-
7364
- } else {
7365
- // If array item is non-scalar (array or object), encode its
7366
- // numeric index to resolve deserialization ambiguity issues.
7367
- // Note that rack (as of 1.0.0) can't currently deserialize
7368
- // nested arrays properly, and attempting to do so may cause
7369
- // a server error. Possible fixes are to modify rack's
7370
- // deserialization algorithm or to provide an option or flag
7371
- // to force array serialization to be shallow.
7372
- buildParams( prefix + "[" + ( typeof v === "object" || jQuery.isArray(v) ? i : "" ) + "]", v, traditional, add );
7373
- }
7374
- });
7375
-
7376
- } else if ( !traditional && obj != null && typeof obj === "object" ) {
7377
- // Serialize object item.
7378
- for ( var name in obj ) {
7379
- buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add );
7380
- }
7381
-
7382
- } else {
7383
- // Serialize scalar item.
7384
- add( prefix, obj );
7385
- }
7386
- }
7387
-
7388
- // This is still on the jQuery object... for now
7389
- // Want to move this to jQuery.ajax some day
7390
- jQuery.extend({
7391
-
7392
- // Counter for holding the number of active queries
7393
- active: 0,
7394
-
7395
- // Last-Modified header cache for next request
7396
- lastModified: {},
7397
- etag: {}
7398
-
7399
- });
7400
-
7401
- /* Handles responses to an ajax request:
7402
- * - sets all responseXXX fields accordingly
7403
- * - finds the right dataType (mediates between content-type and expected dataType)
7404
- * - returns the corresponding response
7405
- */
7406
- function ajaxHandleResponses( s, jqXHR, responses ) {
7407
-
7408
- var contents = s.contents,
7409
- dataTypes = s.dataTypes,
7410
- responseFields = s.responseFields,
7411
- ct,
7412
- type,
7413
- finalDataType,
7414
- firstDataType;
7415
-
7416
- // Fill responseXXX fields
7417
- for( type in responseFields ) {
7418
- if ( type in responses ) {
7419
- jqXHR[ responseFields[type] ] = responses[ type ];
7420
- }
7421
- }
7422
-
7423
- // Remove auto dataType and get content-type in the process
7424
- while( dataTypes[ 0 ] === "*" ) {
7425
- dataTypes.shift();
7426
- if ( ct === undefined ) {
7427
- ct = s.mimeType || jqXHR.getResponseHeader( "content-type" );
7428
- }
7429
- }
7430
-
7431
- // Check if we're dealing with a known content-type
7432
- if ( ct ) {
7433
- for ( type in contents ) {
7434
- if ( contents[ type ] && contents[ type ].test( ct ) ) {
7435
- dataTypes.unshift( type );
7436
- break;
7437
- }
7438
- }
7439
- }
7440
-
7441
- // Check to see if we have a response for the expected dataType
7442
- if ( dataTypes[ 0 ] in responses ) {
7443
- finalDataType = dataTypes[ 0 ];
7444
- } else {
7445
- // Try convertible dataTypes
7446
- for ( type in responses ) {
7447
- if ( !dataTypes[ 0 ] || s.converters[ type + " " + dataTypes[0] ] ) {
7448
- finalDataType = type;
7449
- break;
7450
- }
7451
- if ( !firstDataType ) {
7452
- firstDataType = type;
7453
- }
7454
- }
7455
- // Or just use first one
7456
- finalDataType = finalDataType || firstDataType;
7457
- }
7458
-
7459
- // If we found a dataType
7460
- // We add the dataType to the list if needed
7461
- // and return the corresponding response
7462
- if ( finalDataType ) {
7463
- if ( finalDataType !== dataTypes[ 0 ] ) {
7464
- dataTypes.unshift( finalDataType );
7465
- }
7466
- return responses[ finalDataType ];
7467
- }
7468
- }
7469
-
7470
- // Chain conversions given the request and the original response
7471
- function ajaxConvert( s, response ) {
7472
-
7473
- // Apply the dataFilter if provided
7474
- if ( s.dataFilter ) {
7475
- response = s.dataFilter( response, s.dataType );
7476
- }
7477
-
7478
- var dataTypes = s.dataTypes,
7479
- converters = {},
7480
- i,
7481
- key,
7482
- length = dataTypes.length,
7483
- tmp,
7484
- // Current and previous dataTypes
7485
- current = dataTypes[ 0 ],
7486
- prev,
7487
- // Conversion expression
7488
- conversion,
7489
- // Conversion function
7490
- conv,
7491
- // Conversion functions (transitive conversion)
7492
- conv1,
7493
- conv2;
7494
-
7495
- // For each dataType in the chain
7496
- for( i = 1; i < length; i++ ) {
7497
-
7498
- // Create converters map
7499
- // with lowercased keys
7500
- if ( i === 1 ) {
7501
- for( key in s.converters ) {
7502
- if( typeof key === "string" ) {
7503
- converters[ key.toLowerCase() ] = s.converters[ key ];
7504
- }
7505
- }
7506
- }
7507
-
7508
- // Get the dataTypes
7509
- prev = current;
7510
- current = dataTypes[ i ];
7511
-
7512
- // If current is auto dataType, update it to prev
7513
- if( current === "*" ) {
7514
- current = prev;
7515
- // If no auto and dataTypes are actually different
7516
- } else if ( prev !== "*" && prev !== current ) {
7517
-
7518
- // Get the converter
7519
- conversion = prev + " " + current;
7520
- conv = converters[ conversion ] || converters[ "* " + current ];
7521
-
7522
- // If there is no direct converter, search transitively
7523
- if ( !conv ) {
7524
- conv2 = undefined;
7525
- for( conv1 in converters ) {
7526
- tmp = conv1.split( " " );
7527
- if ( tmp[ 0 ] === prev || tmp[ 0 ] === "*" ) {
7528
- conv2 = converters[ tmp[1] + " " + current ];
7529
- if ( conv2 ) {
7530
- conv1 = converters[ conv1 ];
7531
- if ( conv1 === true ) {
7532
- conv = conv2;
7533
- } else if ( conv2 === true ) {
7534
- conv = conv1;
7535
- }
7536
- break;
7537
- }
7538
- }
7539
- }
7540
- }
7541
- // If we found no converter, dispatch an error
7542
- if ( !( conv || conv2 ) ) {
7543
- jQuery.error( "No conversion from " + conversion.replace(" "," to ") );
7544
- }
7545
- // If found converter is not an equivalence
7546
- if ( conv !== true ) {
7547
- // Convert with 1 or 2 converters accordingly
7548
- response = conv ? conv( response ) : conv2( conv1(response) );
7549
- }
7550
- }
7551
- }
7552
- return response;
7553
- }
7554
-
7555
-
7556
-
7557
-
7558
- var jsc = jQuery.now(),
7559
- jsre = /(\=)\?(&|$)|\?\?/i;
7560
-
7561
- // Default jsonp settings
7562
- jQuery.ajaxSetup({
7563
- jsonp: "callback",
7564
- jsonpCallback: function() {
7565
- return jQuery.expando + "_" + ( jsc++ );
7566
- }
7567
- });
7568
-
7569
- // Detect, normalize options and install callbacks for jsonp requests
7570
- jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) {
7571
-
7572
- var inspectData = s.contentType === "application/x-www-form-urlencoded" &&
7573
- ( typeof s.data === "string" );
7574
-
7575
- if ( s.dataTypes[ 0 ] === "jsonp" ||
7576
- s.jsonp !== false && ( jsre.test( s.url ) ||
7577
- inspectData && jsre.test( s.data ) ) ) {
7578
-
7579
- var responseContainer,
7580
- jsonpCallback = s.jsonpCallback =
7581
- jQuery.isFunction( s.jsonpCallback ) ? s.jsonpCallback() : s.jsonpCallback,
7582
- previous = window[ jsonpCallback ],
7583
- url = s.url,
7584
- data = s.data,
7585
- replace = "$1" + jsonpCallback + "$2";
7586
-
7587
- if ( s.jsonp !== false ) {
7588
- url = url.replace( jsre, replace );
7589
- if ( s.url === url ) {
7590
- if ( inspectData ) {
7591
- data = data.replace( jsre, replace );
7592
- }
7593
- if ( s.data === data ) {
7594
- // Add callback manually
7595
- url += (/\?/.test( url ) ? "&" : "?") + s.jsonp + "=" + jsonpCallback;
7596
- }
7597
- }
7598
- }
7599
-
7600
- s.url = url;
7601
- s.data = data;
7602
-
7603
- // Install callback
7604
- window[ jsonpCallback ] = function( response ) {
7605
- responseContainer = [ response ];
7606
- };
7607
-
7608
- // Clean-up function
7609
- jqXHR.always(function() {
7610
- // Set callback back to previous value
7611
- window[ jsonpCallback ] = previous;
7612
- // Call if it was a function and we have a response
7613
- if ( responseContainer && jQuery.isFunction( previous ) ) {
7614
- window[ jsonpCallback ]( responseContainer[ 0 ] );
7615
- }
7616
- });
7617
-
7618
- // Use data converter to retrieve json after script execution
7619
- s.converters["script json"] = function() {
7620
- if ( !responseContainer ) {
7621
- jQuery.error( jsonpCallback + " was not called" );
7622
- }
7623
- return responseContainer[ 0 ];
7624
- };
7625
-
7626
- // force json dataType
7627
- s.dataTypes[ 0 ] = "json";
7628
-
7629
- // Delegate to script
7630
- return "script";
7631
- }
7632
- });
7633
-
7634
-
7635
-
7636
-
7637
- // Install script dataType
7638
- jQuery.ajaxSetup({
7639
- accepts: {
7640
- script: "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"
7641
- },
7642
- contents: {
7643
- script: /javascript|ecmascript/
7644
- },
7645
- converters: {
7646
- "text script": function( text ) {
7647
- jQuery.globalEval( text );
7648
- return text;
7649
- }
7650
- }
7651
- });
7652
-
7653
- // Handle cache's special case and global
7654
- jQuery.ajaxPrefilter( "script", function( s ) {
7655
- if ( s.cache === undefined ) {
7656
- s.cache = false;
7657
- }
7658
- if ( s.crossDomain ) {
7659
- s.type = "GET";
7660
- s.global = false;
7661
- }
7662
- });
7663
-
7664
- // Bind script tag hack transport
7665
- jQuery.ajaxTransport( "script", function(s) {
7666
-
7667
- // This transport only deals with cross domain requests
7668
- if ( s.crossDomain ) {
7669
-
7670
- var script,
7671
- head = document.head || document.getElementsByTagName( "head" )[0] || document.documentElement;
7672
-
7673
- return {
7674
-
7675
- send: function( _, callback ) {
7676
-
7677
- script = document.createElement( "script" );
7678
-
7679
- script.async = "async";
7680
-
7681
- if ( s.scriptCharset ) {
7682
- script.charset = s.scriptCharset;
7683
- }
7684
-
7685
- script.src = s.url;
7686
-
7687
- // Attach handlers for all browsers
7688
- script.onload = script.onreadystatechange = function( _, isAbort ) {
7689
-
7690
- if ( isAbort || !script.readyState || /loaded|complete/.test( script.readyState ) ) {
7691
-
7692
- // Handle memory leak in IE
7693
- script.onload = script.onreadystatechange = null;
7694
-
7695
- // Remove the script
7696
- if ( head && script.parentNode ) {
7697
- head.removeChild( script );
7698
- }
7699
-
7700
- // Dereference the script
7701
- script = undefined;
7702
-
7703
- // Callback if not abort
7704
- if ( !isAbort ) {
7705
- callback( 200, "success" );
7706
- }
7707
- }
7708
- };
7709
- // Use insertBefore instead of appendChild to circumvent an IE6 bug.
7710
- // This arises when a base node is used (#2709 and #4378).
7711
- head.insertBefore( script, head.firstChild );
7712
- },
7713
-
7714
- abort: function() {
7715
- if ( script ) {
7716
- script.onload( 0, 1 );
7717
- }
7718
- }
7719
- };
7720
- }
7721
- });
7722
-
7723
-
7724
-
7725
-
7726
- var // #5280: Internet Explorer will keep connections alive if we don't abort on unload
7727
- xhrOnUnloadAbort = window.ActiveXObject ? function() {
7728
- // Abort all pending requests
7729
- for ( var key in xhrCallbacks ) {
7730
- xhrCallbacks[ key ]( 0, 1 );
7731
- }
7732
- } : false,
7733
- xhrId = 0,
7734
- xhrCallbacks;
7735
-
7736
- // Functions to create xhrs
7737
- function createStandardXHR() {
7738
- try {
7739
- return new window.XMLHttpRequest();
7740
- } catch( e ) {}
7741
- }
7742
-
7743
- function createActiveXHR() {
7744
- try {
7745
- return new window.ActiveXObject( "Microsoft.XMLHTTP" );
7746
- } catch( e ) {}
7747
- }
7748
-
7749
- // Create the request object
7750
- // (This is still attached to ajaxSettings for backward compatibility)
7751
- jQuery.ajaxSettings.xhr = window.ActiveXObject ?
7752
- /* Microsoft failed to properly
7753
- * implement the XMLHttpRequest in IE7 (can't request local files),
7754
- * so we use the ActiveXObject when it is available
7755
- * Additionally XMLHttpRequest can be disabled in IE7/IE8 so
7756
- * we need a fallback.
7757
- */
7758
- function() {
7759
- return !this.isLocal && createStandardXHR() || createActiveXHR();
7760
- } :
7761
- // For all other browsers, use the standard XMLHttpRequest object
7762
- createStandardXHR;
7763
-
7764
- // Determine support properties
7765
- (function( xhr ) {
7766
- jQuery.extend( jQuery.support, {
7767
- ajax: !!xhr,
7768
- cors: !!xhr && ( "withCredentials" in xhr )
7769
- });
7770
- })( jQuery.ajaxSettings.xhr() );
7771
-
7772
- // Create transport if the browser can provide an xhr
7773
- if ( jQuery.support.ajax ) {
7774
-
7775
- jQuery.ajaxTransport(function( s ) {
7776
- // Cross domain only allowed if supported through XMLHttpRequest
7777
- if ( !s.crossDomain || jQuery.support.cors ) {
7778
-
7779
- var callback;
7780
-
7781
- return {
7782
- send: function( headers, complete ) {
7783
-
7784
- // Get a new xhr
7785
- var xhr = s.xhr(),
7786
- handle,
7787
- i;
7788
-
7789
- // Open the socket
7790
- // Passing null username, generates a login popup on Opera (#2865)
7791
- if ( s.username ) {
7792
- xhr.open( s.type, s.url, s.async, s.username, s.password );
7793
- } else {
7794
- xhr.open( s.type, s.url, s.async );
7795
- }
7796
-
7797
- // Apply custom fields if provided
7798
- if ( s.xhrFields ) {
7799
- for ( i in s.xhrFields ) {
7800
- xhr[ i ] = s.xhrFields[ i ];
7801
- }
7802
- }
7803
-
7804
- // Override mime type if needed
7805
- if ( s.mimeType && xhr.overrideMimeType ) {
7806
- xhr.overrideMimeType( s.mimeType );
7807
- }
7808
-
7809
- // X-Requested-With header
7810
- // For cross-domain requests, seeing as conditions for a preflight are
7811
- // akin to a jigsaw puzzle, we simply never set it to be sure.
7812
- // (it can always be set on a per-request basis or even using ajaxSetup)
7813
- // For same-domain requests, won't change header if already provided.
7814
- if ( !s.crossDomain && !headers["X-Requested-With"] ) {
7815
- headers[ "X-Requested-With" ] = "XMLHttpRequest";
7816
- }
7817
-
7818
- // Need an extra try/catch for cross domain requests in Firefox 3
7819
- try {
7820
- for ( i in headers ) {
7821
- xhr.setRequestHeader( i, headers[ i ] );
7822
- }
7823
- } catch( _ ) {}
7824
-
7825
- // Do send the request
7826
- // This may raise an exception which is actually
7827
- // handled in jQuery.ajax (so no try/catch here)
7828
- xhr.send( ( s.hasContent && s.data ) || null );
7829
-
7830
- // Listener
7831
- callback = function( _, isAbort ) {
7832
-
7833
- var status,
7834
- statusText,
7835
- responseHeaders,
7836
- responses,
7837
- xml;
7838
-
7839
- // Firefox throws exceptions when accessing properties
7840
- // of an xhr when a network error occured
7841
- // http://helpful.knobs-dials.com/index.php/Component_returned_failure_code:_0x80040111_(NS_ERROR_NOT_AVAILABLE)
7842
- try {
7843
-
7844
- // Was never called and is aborted or complete
7845
- if ( callback && ( isAbort || xhr.readyState === 4 ) ) {
7846
-
7847
- // Only called once
7848
- callback = undefined;
7849
-
7850
- // Do not keep as active anymore
7851
- if ( handle ) {
7852
- xhr.onreadystatechange = jQuery.noop;
7853
- if ( xhrOnUnloadAbort ) {
7854
- delete xhrCallbacks[ handle ];
7855
- }
7856
- }
7857
-
7858
- // If it's an abort
7859
- if ( isAbort ) {
7860
- // Abort it manually if needed
7861
- if ( xhr.readyState !== 4 ) {
7862
- xhr.abort();
7863
- }
7864
- } else {
7865
- status = xhr.status;
7866
- responseHeaders = xhr.getAllResponseHeaders();
7867
- responses = {};
7868
- xml = xhr.responseXML;
7869
-
7870
- // Construct response list
7871
- if ( xml && xml.documentElement /* #4958 */ ) {
7872
- responses.xml = xml;
7873
- }
7874
- responses.text = xhr.responseText;
7875
-
7876
- // Firefox throws an exception when accessing
7877
- // statusText for faulty cross-domain requests
7878
- try {
7879
- statusText = xhr.statusText;
7880
- } catch( e ) {
7881
- // We normalize with Webkit giving an empty statusText
7882
- statusText = "";
7883
- }
7884
-
7885
- // Filter status for non standard behaviors
7886
-
7887
- // If the request is local and we have data: assume a success
7888
- // (success with no data won't get notified, that's the best we
7889
- // can do given current implementations)
7890
- if ( !status && s.isLocal && !s.crossDomain ) {
7891
- status = responses.text ? 200 : 404;
7892
- // IE - #1450: sometimes returns 1223 when it should be 204
7893
- } else if ( status === 1223 ) {
7894
- status = 204;
7895
- }
7896
- }
7897
- }
7898
- } catch( firefoxAccessException ) {
7899
- if ( !isAbort ) {
7900
- complete( -1, firefoxAccessException );
7901
- }
7902
- }
7903
-
7904
- // Call complete if needed
7905
- if ( responses ) {
7906
- complete( status, statusText, responses, responseHeaders );
7907
- }
7908
- };
7909
-
7910
- // if we're in sync mode or it's in cache
7911
- // and has been retrieved directly (IE6 & IE7)
7912
- // we need to manually fire the callback
7913
- if ( !s.async || xhr.readyState === 4 ) {
7914
- callback();
7915
- } else {
7916
- handle = ++xhrId;
7917
- if ( xhrOnUnloadAbort ) {
7918
- // Create the active xhrs callbacks list if needed
7919
- // and attach the unload handler
7920
- if ( !xhrCallbacks ) {
7921
- xhrCallbacks = {};
7922
- jQuery( window ).unload( xhrOnUnloadAbort );
7923
- }
7924
- // Add to list of active xhrs callbacks
7925
- xhrCallbacks[ handle ] = callback;
7926
- }
7927
- xhr.onreadystatechange = callback;
7928
- }
7929
- },
7930
-
7931
- abort: function() {
7932
- if ( callback ) {
7933
- callback(0,1);
7934
- }
7935
- }
7936
- };
7937
- }
7938
- });
7939
- }
7940
-
7941
-
7942
-
7943
-
7944
- var elemdisplay = {},
7945
- iframe, iframeDoc,
7946
- rfxtypes = /^(?:toggle|show|hide)$/,
7947
- rfxnum = /^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,
7948
- timerId,
7949
- fxAttrs = [
7950
- // height animations
7951
- [ "height", "marginTop", "marginBottom", "paddingTop", "paddingBottom" ],
7952
- // width animations
7953
- [ "width", "marginLeft", "marginRight", "paddingLeft", "paddingRight" ],
7954
- // opacity animations
7955
- [ "opacity" ]
7956
- ],
7957
- fxNow,
7958
- requestAnimationFrame = window.webkitRequestAnimationFrame ||
7959
- window.mozRequestAnimationFrame ||
7960
- window.oRequestAnimationFrame;
7961
-
7962
- jQuery.fn.extend({
7963
- show: function( speed, easing, callback ) {
7964
- var elem, display;
7965
-
7966
- if ( speed || speed === 0 ) {
7967
- return this.animate( genFx("show", 3), speed, easing, callback);
7968
-
7969
- } else {
7970
- for ( var i = 0, j = this.length; i < j; i++ ) {
7971
- elem = this[i];
7972
-
7973
- if ( elem.style ) {
7974
- display = elem.style.display;
7975
-
7976
- // Reset the inline display of this element to learn if it is
7977
- // being hidden by cascaded rules or not
7978
- if ( !jQuery._data(elem, "olddisplay") && display === "none" ) {
7979
- display = elem.style.display = "";
7980
- }
7981
-
7982
- // Set elements which have been overridden with display: none
7983
- // in a stylesheet to whatever the default browser style is
7984
- // for such an element
7985
- if ( display === "" && jQuery.css( elem, "display" ) === "none" ) {
7986
- jQuery._data(elem, "olddisplay", defaultDisplay(elem.nodeName));
7987
- }
7988
- }
7989
- }
7990
-
7991
- // Set the display of most of the elements in a second loop
7992
- // to avoid the constant reflow
7993
- for ( i = 0; i < j; i++ ) {
7994
- elem = this[i];
7995
-
7996
- if ( elem.style ) {
7997
- display = elem.style.display;
7998
-
7999
- if ( display === "" || display === "none" ) {
8000
- elem.style.display = jQuery._data(elem, "olddisplay") || "";
8001
- }
8002
- }
8003
- }
8004
-
8005
- return this;
8006
- }
8007
- },
8008
-
8009
- hide: function( speed, easing, callback ) {
8010
- if ( speed || speed === 0 ) {
8011
- return this.animate( genFx("hide", 3), speed, easing, callback);
8012
-
8013
- } else {
8014
- for ( var i = 0, j = this.length; i < j; i++ ) {
8015
- if ( this[i].style ) {
8016
- var display = jQuery.css( this[i], "display" );
8017
-
8018
- if ( display !== "none" && !jQuery._data( this[i], "olddisplay" ) ) {
8019
- jQuery._data( this[i], "olddisplay", display );
8020
- }
8021
- }
8022
- }
8023
-
8024
- // Set the display of the elements in a second loop
8025
- // to avoid the constant reflow
8026
- for ( i = 0; i < j; i++ ) {
8027
- if ( this[i].style ) {
8028
- this[i].style.display = "none";
8029
- }
8030
- }
8031
-
8032
- return this;
8033
- }
8034
- },
8035
-
8036
- // Save the old toggle function
8037
- _toggle: jQuery.fn.toggle,
8038
-
8039
- toggle: function( fn, fn2, callback ) {
8040
- var bool = typeof fn === "boolean";
8041
-
8042
- if ( jQuery.isFunction(fn) && jQuery.isFunction(fn2) ) {
8043
- this._toggle.apply( this, arguments );
8044
-
8045
- } else if ( fn == null || bool ) {
8046
- this.each(function() {
8047
- var state = bool ? fn : jQuery(this).is(":hidden");
8048
- jQuery(this)[ state ? "show" : "hide" ]();
8049
- });
8050
-
8051
- } else {
8052
- this.animate(genFx("toggle", 3), fn, fn2, callback);
8053
- }
8054
-
8055
- return this;
8056
- },
8057
-
8058
- fadeTo: function( speed, to, easing, callback ) {
8059
- return this.filter(":hidden").css("opacity", 0).show().end()
8060
- .animate({opacity: to}, speed, easing, callback);
8061
- },
8062
-
8063
- animate: function( prop, speed, easing, callback ) {
8064
- var optall = jQuery.speed(speed, easing, callback);
8065
-
8066
- if ( jQuery.isEmptyObject( prop ) ) {
8067
- return this.each( optall.complete, [ false ] );
8068
- }
8069
-
8070
- // Do not change referenced properties as per-property easing will be lost
8071
- prop = jQuery.extend( {}, prop );
8072
-
8073
- return this[ optall.queue === false ? "each" : "queue" ](function() {
8074
- // XXX 'this' does not always have a nodeName when running the
8075
- // test suite
8076
-
8077
- if ( optall.queue === false ) {
8078
- jQuery._mark( this );
8079
- }
8080
-
8081
- var opt = jQuery.extend( {}, optall ),
8082
- isElement = this.nodeType === 1,
8083
- hidden = isElement && jQuery(this).is(":hidden"),
8084
- name, val, p,
8085
- display, e,
8086
- parts, start, end, unit;
8087
-
8088
- // will store per property easing and be used to determine when an animation is complete
8089
- opt.animatedProperties = {};
8090
-
8091
- for ( p in prop ) {
8092
-
8093
- // property name normalization
8094
- name = jQuery.camelCase( p );
8095
- if ( p !== name ) {
8096
- prop[ name ] = prop[ p ];
8097
- delete prop[ p ];
8098
- }
8099
-
8100
- val = prop[ name ];
8101
-
8102
- // easing resolution: per property > opt.specialEasing > opt.easing > 'swing' (default)
8103
- if ( jQuery.isArray( val ) ) {
8104
- opt.animatedProperties[ name ] = val[ 1 ];
8105
- val = prop[ name ] = val[ 0 ];
8106
- } else {
8107
- opt.animatedProperties[ name ] = opt.specialEasing && opt.specialEasing[ name ] || opt.easing || 'swing';
8108
- }
8109
-
8110
- if ( val === "hide" && hidden || val === "show" && !hidden ) {
8111
- return opt.complete.call( this );
8112
- }
8113
-
8114
- if ( isElement && ( name === "height" || name === "width" ) ) {
8115
- // Make sure that nothing sneaks out
8116
- // Record all 3 overflow attributes because IE does not
8117
- // change the overflow attribute when overflowX and
8118
- // overflowY are set to the same value
8119
- opt.overflow = [ this.style.overflow, this.style.overflowX, this.style.overflowY ];
8120
-
8121
- // Set display property to inline-block for height/width
8122
- // animations on inline elements that are having width/height
8123
- // animated
8124
- if ( jQuery.css( this, "display" ) === "inline" &&
8125
- jQuery.css( this, "float" ) === "none" ) {
8126
- if ( !jQuery.support.inlineBlockNeedsLayout ) {
8127
- this.style.display = "inline-block";
8128
-
8129
- } else {
8130
- display = defaultDisplay( this.nodeName );
8131
-
8132
- // inline-level elements accept inline-block;
8133
- // block-level elements need to be inline with layout
8134
- if ( display === "inline" ) {
8135
- this.style.display = "inline-block";
8136
-
8137
- } else {
8138
- this.style.display = "inline";
8139
- this.style.zoom = 1;
8140
- }
8141
- }
8142
- }
8143
- }
8144
- }
8145
-
8146
- if ( opt.overflow != null ) {
8147
- this.style.overflow = "hidden";
8148
- }
8149
-
8150
- for ( p in prop ) {
8151
- e = new jQuery.fx( this, opt, p );
8152
- val = prop[ p ];
8153
-
8154
- if ( rfxtypes.test(val) ) {
8155
- e[ val === "toggle" ? hidden ? "show" : "hide" : val ]();
8156
-
8157
- } else {
8158
- parts = rfxnum.exec( val );
8159
- start = e.cur();
8160
-
8161
- if ( parts ) {
8162
- end = parseFloat( parts[2] );
8163
- unit = parts[3] || ( jQuery.cssNumber[ p ] ? "" : "px" );
8164
-
8165
- // We need to compute starting value
8166
- if ( unit !== "px" ) {
8167
- jQuery.style( this, p, (end || 1) + unit);
8168
- start = ((end || 1) / e.cur()) * start;
8169
- jQuery.style( this, p, start + unit);
8170
- }
8171
-
8172
- // If a +=/-= token was provided, we're doing a relative animation
8173
- if ( parts[1] ) {
8174
- end = ( (parts[ 1 ] === "-=" ? -1 : 1) * end ) + start;
8175
- }
8176
-
8177
- e.custom( start, end, unit );
8178
-
8179
- } else {
8180
- e.custom( start, val, "" );
8181
- }
8182
- }
8183
- }
8184
-
8185
- // For JS strict compliance
8186
- return true;
8187
- });
8188
- },
8189
-
8190
- stop: function( clearQueue, gotoEnd ) {
8191
- if ( clearQueue ) {
8192
- this.queue([]);
8193
- }
8194
-
8195
- this.each(function() {
8196
- var timers = jQuery.timers,
8197
- i = timers.length;
8198
- // clear marker counters if we know they won't be
8199
- if ( !gotoEnd ) {
8200
- jQuery._unmark( true, this );
8201
- }
8202
- while ( i-- ) {
8203
- if ( timers[i].elem === this ) {
8204
- if (gotoEnd) {
8205
- // force the next step to be the last
8206
- timers[i](true);
8207
- }
8208
-
8209
- timers.splice(i, 1);
8210
- }
8211
- }
8212
- });
8213
-
8214
- // start the next in the queue if the last step wasn't forced
8215
- if ( !gotoEnd ) {
8216
- this.dequeue();
8217
- }
8218
-
8219
- return this;
8220
- }
8221
-
8222
- });
8223
-
8224
- // Animations created synchronously will run synchronously
8225
- function createFxNow() {
8226
- setTimeout( clearFxNow, 0 );
8227
- return ( fxNow = jQuery.now() );
8228
- }
8229
-
8230
- function clearFxNow() {
8231
- fxNow = undefined;
8232
- }
8233
-
8234
- // Generate parameters to create a standard animation
8235
- function genFx( type, num ) {
8236
- var obj = {};
8237
-
8238
- jQuery.each( fxAttrs.concat.apply([], fxAttrs.slice(0,num)), function() {
8239
- obj[ this ] = type;
8240
- });
8241
-
8242
- return obj;
8243
- }
8244
-
8245
- // Generate shortcuts for custom animations
8246
- jQuery.each({
8247
- slideDown: genFx("show", 1),
8248
- slideUp: genFx("hide", 1),
8249
- slideToggle: genFx("toggle", 1),
8250
- fadeIn: { opacity: "show" },
8251
- fadeOut: { opacity: "hide" },
8252
- fadeToggle: { opacity: "toggle" }
8253
- }, function( name, props ) {
8254
- jQuery.fn[ name ] = function( speed, easing, callback ) {
8255
- return this.animate( props, speed, easing, callback );
8256
- };
8257
- });
8258
-
8259
- jQuery.extend({
8260
- speed: function( speed, easing, fn ) {
8261
- var opt = speed && typeof speed === "object" ? jQuery.extend({}, speed) : {
8262
- complete: fn || !fn && easing ||
8263
- jQuery.isFunction( speed ) && speed,
8264
- duration: speed,
8265
- easing: fn && easing || easing && !jQuery.isFunction(easing) && easing
8266
- };
8267
-
8268
- opt.duration = jQuery.fx.off ? 0 : typeof opt.duration === "number" ? opt.duration :
8269
- opt.duration in jQuery.fx.speeds ? jQuery.fx.speeds[opt.duration] : jQuery.fx.speeds._default;
8270
-
8271
- // Queueing
8272
- opt.old = opt.complete;
8273
- opt.complete = function( noUnmark ) {
8274
- if ( opt.queue !== false ) {
8275
- jQuery.dequeue( this );
8276
- } else if ( noUnmark !== false ) {
8277
- jQuery._unmark( this );
8278
- }
8279
-
8280
- if ( jQuery.isFunction( opt.old ) ) {
8281
- opt.old.call( this );
8282
- }
8283
- };
8284
-
8285
- return opt;
8286
- },
8287
-
8288
- easing: {
8289
- linear: function( p, n, firstNum, diff ) {
8290
- return firstNum + diff * p;
8291
- },
8292
- swing: function( p, n, firstNum, diff ) {
8293
- return ((-Math.cos(p*Math.PI)/2) + 0.5) * diff + firstNum;
8294
- }
8295
- },
8296
-
8297
- timers: [],
8298
-
8299
- fx: function( elem, options, prop ) {
8300
- this.options = options;
8301
- this.elem = elem;
8302
- this.prop = prop;
8303
-
8304
- options.orig = options.orig || {};
8305
- }
8306
-
8307
- });
8308
-
8309
- jQuery.fx.prototype = {
8310
- // Simple function for setting a style value
8311
- update: function() {
8312
- if ( this.options.step ) {
8313
- this.options.step.call( this.elem, this.now, this );
8314
- }
8315
-
8316
- (jQuery.fx.step[this.prop] || jQuery.fx.step._default)( this );
8317
- },
8318
-
8319
- // Get the current size
8320
- cur: function() {
8321
- if ( this.elem[this.prop] != null && (!this.elem.style || this.elem.style[this.prop] == null) ) {
8322
- return this.elem[ this.prop ];
8323
- }
8324
-
8325
- var parsed,
8326
- r = jQuery.css( this.elem, this.prop );
8327
- // Empty strings, null, undefined and "auto" are converted to 0,
8328
- // complex values such as "rotate(1rad)" are returned as is,
8329
- // simple values such as "10px" are parsed to Float.
8330
- return isNaN( parsed = parseFloat( r ) ) ? !r || r === "auto" ? 0 : r : parsed;
8331
- },
8332
-
8333
- // Start an animation from one number to another
8334
- custom: function( from, to, unit ) {
8335
- var self = this,
8336
- fx = jQuery.fx,
8337
- raf;
8338
-
8339
- this.startTime = fxNow || createFxNow();
8340
- this.start = from;
8341
- this.end = to;
8342
- this.unit = unit || this.unit || ( jQuery.cssNumber[ this.prop ] ? "" : "px" );
8343
- this.now = this.start;
8344
- this.pos = this.state = 0;
8345
-
8346
- function t( gotoEnd ) {
8347
- return self.step(gotoEnd);
8348
- }
8349
-
8350
- t.elem = this.elem;
8351
-
8352
- if ( t() && jQuery.timers.push(t) && !timerId ) {
8353
- // Use requestAnimationFrame instead of setInterval if available
8354
- if ( requestAnimationFrame ) {
8355
- timerId = 1;
8356
- raf = function() {
8357
- // When timerId gets set to null at any point, this stops
8358
- if ( timerId ) {
8359
- requestAnimationFrame( raf );
8360
- fx.tick();
8361
- }
8362
- };
8363
- requestAnimationFrame( raf );
8364
- } else {
8365
- timerId = setInterval( fx.tick, fx.interval );
8366
- }
8367
- }
8368
- },
8369
-
8370
- // Simple 'show' function
8371
- show: function() {
8372
- // Remember where we started, so that we can go back to it later
8373
- this.options.orig[this.prop] = jQuery.style( this.elem, this.prop );
8374
- this.options.show = true;
8375
-
8376
- // Begin the animation
8377
- // Make sure that we start at a small width/height to avoid any
8378
- // flash of content
8379
- this.custom(this.prop === "width" || this.prop === "height" ? 1 : 0, this.cur());
8380
-
8381
- // Start by showing the element
8382
- jQuery( this.elem ).show();
8383
- },
8384
-
8385
- // Simple 'hide' function
8386
- hide: function() {
8387
- // Remember where we started, so that we can go back to it later
8388
- this.options.orig[this.prop] = jQuery.style( this.elem, this.prop );
8389
- this.options.hide = true;
8390
-
8391
- // Begin the animation
8392
- this.custom(this.cur(), 0);
8393
- },
8394
-
8395
- // Each step of an animation
8396
- step: function( gotoEnd ) {
8397
- var t = fxNow || createFxNow(),
8398
- done = true,
8399
- elem = this.elem,
8400
- options = this.options,
8401
- i, n;
8402
-
8403
- if ( gotoEnd || t >= options.duration + this.startTime ) {
8404
- this.now = this.end;
8405
- this.pos = this.state = 1;
8406
- this.update();
8407
-
8408
- options.animatedProperties[ this.prop ] = true;
8409
-
8410
- for ( i in options.animatedProperties ) {
8411
- if ( options.animatedProperties[i] !== true ) {
8412
- done = false;
8413
- }
8414
- }
8415
-
8416
- if ( done ) {
8417
- // Reset the overflow
8418
- if ( options.overflow != null && !jQuery.support.shrinkWrapBlocks ) {
8419
-
8420
- jQuery.each( [ "", "X", "Y" ], function (index, value) {
8421
- elem.style[ "overflow" + value ] = options.overflow[index];
8422
- });
8423
- }
8424
-
8425
- // Hide the element if the "hide" operation was done
8426
- if ( options.hide ) {
8427
- jQuery(elem).hide();
8428
- }
8429
-
8430
- // Reset the properties, if the item has been hidden or shown
8431
- if ( options.hide || options.show ) {
8432
- for ( var p in options.animatedProperties ) {
8433
- jQuery.style( elem, p, options.orig[p] );
8434
- }
8435
- }
8436
-
8437
- // Execute the complete function
8438
- options.complete.call( elem );
8439
- }
8440
-
8441
- return false;
8442
-
8443
- } else {
8444
- // classical easing cannot be used with an Infinity duration
8445
- if ( options.duration == Infinity ) {
8446
- this.now = t;
8447
- } else {
8448
- n = t - this.startTime;
8449
- this.state = n / options.duration;
8450
-
8451
- // Perform the easing function, defaults to swing
8452
- this.pos = jQuery.easing[ options.animatedProperties[ this.prop ] ]( this.state, n, 0, 1, options.duration );
8453
- this.now = this.start + ((this.end - this.start) * this.pos);
8454
- }
8455
- // Perform the next step of the animation
8456
- this.update();
8457
- }
8458
-
8459
- return true;
8460
- }
8461
- };
8462
-
8463
- jQuery.extend( jQuery.fx, {
8464
- tick: function() {
8465
- for ( var timers = jQuery.timers, i = 0 ; i < timers.length ; ++i ) {
8466
- if ( !timers[i]() ) {
8467
- timers.splice(i--, 1);
8468
- }
8469
- }
8470
-
8471
- if ( !timers.length ) {
8472
- jQuery.fx.stop();
8473
- }
8474
- },
8475
-
8476
- interval: 13,
8477
-
8478
- stop: function() {
8479
- clearInterval( timerId );
8480
- timerId = null;
8481
- },
8482
-
8483
- speeds: {
8484
- slow: 600,
8485
- fast: 200,
8486
- // Default speed
8487
- _default: 400
8488
- },
8489
-
8490
- step: {
8491
- opacity: function( fx ) {
8492
- jQuery.style( fx.elem, "opacity", fx.now );
8493
- },
8494
-
8495
- _default: function( fx ) {
8496
- if ( fx.elem.style && fx.elem.style[ fx.prop ] != null ) {
8497
- fx.elem.style[ fx.prop ] = (fx.prop === "width" || fx.prop === "height" ? Math.max(0, fx.now) : fx.now) + fx.unit;
8498
- } else {
8499
- fx.elem[ fx.prop ] = fx.now;
8500
- }
8501
- }
8502
- }
8503
- });
8504
-
8505
- if ( jQuery.expr && jQuery.expr.filters ) {
8506
- jQuery.expr.filters.animated = function( elem ) {
8507
- return jQuery.grep(jQuery.timers, function( fn ) {
8508
- return elem === fn.elem;
8509
- }).length;
8510
- };
8511
- }
8512
-
8513
- // Try to restore the default display value of an element
8514
- function defaultDisplay( nodeName ) {
8515
-
8516
- if ( !elemdisplay[ nodeName ] ) {
8517
-
8518
- var elem = jQuery( "<" + nodeName + ">" ).appendTo( "body" ),
8519
- display = elem.css( "display" );
8520
-
8521
- elem.remove();
8522
-
8523
- // If the simple way fails,
8524
- // get element's real default display by attaching it to a temp iframe
8525
- if ( display === "none" || display === "" ) {
8526
- // No iframe to use yet, so create it
8527
- if ( !iframe ) {
8528
- iframe = document.createElement( "iframe" );
8529
- iframe.frameBorder = iframe.width = iframe.height = 0;
8530
- }
8531
-
8532
- document.body.appendChild( iframe );
8533
-
8534
- // Create a cacheable copy of the iframe document on first call.
8535
- // IE and Opera will allow us to reuse the iframeDoc without re-writing the fake html
8536
- // document to it, Webkit & Firefox won't allow reusing the iframe document
8537
- if ( !iframeDoc || !iframe.createElement ) {
8538
- iframeDoc = ( iframe.contentWindow || iframe.contentDocument ).document;
8539
- iframeDoc.write( "<!doctype><html><body></body></html>" );
8540
- }
8541
-
8542
- elem = iframeDoc.createElement( nodeName );
8543
-
8544
- iframeDoc.body.appendChild( elem );
8545
-
8546
- display = jQuery.css( elem, "display" );
8547
-
8548
- document.body.removeChild( iframe );
8549
- }
8550
-
8551
- // Store the correct default display
8552
- elemdisplay[ nodeName ] = display;
8553
- }
8554
-
8555
- return elemdisplay[ nodeName ];
8556
- }
8557
-
8558
-
8559
-
8560
-
8561
- var rtable = /^t(?:able|d|h)$/i,
8562
- rroot = /^(?:body|html)$/i;
8563
-
8564
- if ( "getBoundingClientRect" in document.documentElement ) {
8565
- jQuery.fn.offset = function( options ) {
8566
- var elem = this[0], box;
8567
-
8568
- if ( options ) {
8569
- return this.each(function( i ) {
8570
- jQuery.offset.setOffset( this, options, i );
8571
- });
8572
- }
8573
-
8574
- if ( !elem || !elem.ownerDocument ) {
8575
- return null;
8576
- }
8577
-
8578
- if ( elem === elem.ownerDocument.body ) {
8579
- return jQuery.offset.bodyOffset( elem );
8580
- }
8581
-
8582
- try {
8583
- box = elem.getBoundingClientRect();
8584
- } catch(e) {}
8585
-
8586
- var doc = elem.ownerDocument,
8587
- docElem = doc.documentElement;
8588
-
8589
- // Make sure we're not dealing with a disconnected DOM node
8590
- if ( !box || !jQuery.contains( docElem, elem ) ) {
8591
- return box ? { top: box.top, left: box.left } : { top: 0, left: 0 };
8592
- }
8593
-
8594
- var body = doc.body,
8595
- win = getWindow(doc),
8596
- clientTop = docElem.clientTop || body.clientTop || 0,
8597
- clientLeft = docElem.clientLeft || body.clientLeft || 0,
8598
- scrollTop = win.pageYOffset || jQuery.support.boxModel && docElem.scrollTop || body.scrollTop,
8599
- scrollLeft = win.pageXOffset || jQuery.support.boxModel && docElem.scrollLeft || body.scrollLeft,
8600
- top = box.top + scrollTop - clientTop,
8601
- left = box.left + scrollLeft - clientLeft;
8602
-
8603
- return { top: top, left: left };
8604
- };
8605
-
8606
- } else {
8607
- jQuery.fn.offset = function( options ) {
8608
- var elem = this[0];
8609
-
8610
- if ( options ) {
8611
- return this.each(function( i ) {
8612
- jQuery.offset.setOffset( this, options, i );
8613
- });
8614
- }
8615
-
8616
- if ( !elem || !elem.ownerDocument ) {
8617
- return null;
8618
- }
8619
-
8620
- if ( elem === elem.ownerDocument.body ) {
8621
- return jQuery.offset.bodyOffset( elem );
8622
- }
8623
-
8624
- jQuery.offset.initialize();
8625
-
8626
- var computedStyle,
8627
- offsetParent = elem.offsetParent,
8628
- prevOffsetParent = elem,
8629
- doc = elem.ownerDocument,
8630
- docElem = doc.documentElement,
8631
- body = doc.body,
8632
- defaultView = doc.defaultView,
8633
- prevComputedStyle = defaultView ? defaultView.getComputedStyle( elem, null ) : elem.currentStyle,
8634
- top = elem.offsetTop,
8635
- left = elem.offsetLeft;
8636
-
8637
- while ( (elem = elem.parentNode) && elem !== body && elem !== docElem ) {
8638
- if ( jQuery.offset.supportsFixedPosition && prevComputedStyle.position === "fixed" ) {
8639
- break;
8640
- }
8641
-
8642
- computedStyle = defaultView ? defaultView.getComputedStyle(elem, null) : elem.currentStyle;
8643
- top -= elem.scrollTop;
8644
- left -= elem.scrollLeft;
8645
-
8646
- if ( elem === offsetParent ) {
8647
- top += elem.offsetTop;
8648
- left += elem.offsetLeft;
8649
-
8650
- if ( jQuery.offset.doesNotAddBorder && !(jQuery.offset.doesAddBorderForTableAndCells && rtable.test(elem.nodeName)) ) {
8651
- top += parseFloat( computedStyle.borderTopWidth ) || 0;
8652
- left += parseFloat( computedStyle.borderLeftWidth ) || 0;
8653
- }
8654
-
8655
- prevOffsetParent = offsetParent;
8656
- offsetParent = elem.offsetParent;
8657
- }
8658
-
8659
- if ( jQuery.offset.subtractsBorderForOverflowNotVisible && computedStyle.overflow !== "visible" ) {
8660
- top += parseFloat( computedStyle.borderTopWidth ) || 0;
8661
- left += parseFloat( computedStyle.borderLeftWidth ) || 0;
8662
- }
8663
-
8664
- prevComputedStyle = computedStyle;
8665
- }
8666
-
8667
- if ( prevComputedStyle.position === "relative" || prevComputedStyle.position === "static" ) {
8668
- top += body.offsetTop;
8669
- left += body.offsetLeft;
8670
- }
8671
-
8672
- if ( jQuery.offset.supportsFixedPosition && prevComputedStyle.position === "fixed" ) {
8673
- top += Math.max( docElem.scrollTop, body.scrollTop );
8674
- left += Math.max( docElem.scrollLeft, body.scrollLeft );
8675
- }
8676
-
8677
- return { top: top, left: left };
8678
- };
8679
- }
8680
-
8681
- jQuery.offset = {
8682
- initialize: function() {
8683
- var body = document.body, container = document.createElement("div"), innerDiv, checkDiv, table, td, bodyMarginTop = parseFloat( jQuery.css(body, "marginTop") ) || 0,
8684
- html = "<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";
8685
-
8686
- jQuery.extend( container.style, { position: "absolute", top: 0, left: 0, margin: 0, border: 0, width: "1px", height: "1px", visibility: "hidden" } );
8687
-
8688
- container.innerHTML = html;
8689
- body.insertBefore( container, body.firstChild );
8690
- innerDiv = container.firstChild;
8691
- checkDiv = innerDiv.firstChild;
8692
- td = innerDiv.nextSibling.firstChild.firstChild;
8693
-
8694
- this.doesNotAddBorder = (checkDiv.offsetTop !== 5);
8695
- this.doesAddBorderForTableAndCells = (td.offsetTop === 5);
8696
-
8697
- checkDiv.style.position = "fixed";
8698
- checkDiv.style.top = "20px";
8699
-
8700
- // safari subtracts parent border width here which is 5px
8701
- this.supportsFixedPosition = (checkDiv.offsetTop === 20 || checkDiv.offsetTop === 15);
8702
- checkDiv.style.position = checkDiv.style.top = "";
8703
-
8704
- innerDiv.style.overflow = "hidden";
8705
- innerDiv.style.position = "relative";
8706
-
8707
- this.subtractsBorderForOverflowNotVisible = (checkDiv.offsetTop === -5);
8708
-
8709
- this.doesNotIncludeMarginInBodyOffset = (body.offsetTop !== bodyMarginTop);
8710
-
8711
- body.removeChild( container );
8712
- jQuery.offset.initialize = jQuery.noop;
8713
- },
8714
-
8715
- bodyOffset: function( body ) {
8716
- var top = body.offsetTop,
8717
- left = body.offsetLeft;
8718
-
8719
- jQuery.offset.initialize();
8720
-
8721
- if ( jQuery.offset.doesNotIncludeMarginInBodyOffset ) {
8722
- top += parseFloat( jQuery.css(body, "marginTop") ) || 0;
8723
- left += parseFloat( jQuery.css(body, "marginLeft") ) || 0;
8724
- }
8725
-
8726
- return { top: top, left: left };
8727
- },
8728
-
8729
- setOffset: function( elem, options, i ) {
8730
- var position = jQuery.css( elem, "position" );
8731
-
8732
- // set position first, in-case top/left are set even on static elem
8733
- if ( position === "static" ) {
8734
- elem.style.position = "relative";
8735
- }
8736
-
8737
- var curElem = jQuery( elem ),
8738
- curOffset = curElem.offset(),
8739
- curCSSTop = jQuery.css( elem, "top" ),
8740
- curCSSLeft = jQuery.css( elem, "left" ),
8741
- calculatePosition = (position === "absolute" || position === "fixed") && jQuery.inArray("auto", [curCSSTop, curCSSLeft]) > -1,
8742
- props = {}, curPosition = {}, curTop, curLeft;
8743
-
8744
- // need to be able to calculate position if either top or left is auto and position is either absolute or fixed
8745
- if ( calculatePosition ) {
8746
- curPosition = curElem.position();
8747
- curTop = curPosition.top;
8748
- curLeft = curPosition.left;
8749
- } else {
8750
- curTop = parseFloat( curCSSTop ) || 0;
8751
- curLeft = parseFloat( curCSSLeft ) || 0;
8752
- }
8753
-
8754
- if ( jQuery.isFunction( options ) ) {
8755
- options = options.call( elem, i, curOffset );
8756
- }
8757
-
8758
- if (options.top != null) {
8759
- props.top = (options.top - curOffset.top) + curTop;
8760
- }
8761
- if (options.left != null) {
8762
- props.left = (options.left - curOffset.left) + curLeft;
8763
- }
8764
-
8765
- if ( "using" in options ) {
8766
- options.using.call( elem, props );
8767
- } else {
8768
- curElem.css( props );
8769
- }
8770
- }
8771
- };
8772
-
8773
-
8774
- jQuery.fn.extend({
8775
- position: function() {
8776
- if ( !this[0] ) {
8777
- return null;
8778
- }
8779
-
8780
- var elem = this[0],
8781
-
8782
- // Get *real* offsetParent
8783
- offsetParent = this.offsetParent(),
8784
-
8785
- // Get correct offsets
8786
- offset = this.offset(),
8787
- parentOffset = rroot.test(offsetParent[0].nodeName) ? { top: 0, left: 0 } : offsetParent.offset();
8788
-
8789
- // Subtract element margins
8790
- // note: when an element has margin: auto the offsetLeft and marginLeft
8791
- // are the same in Safari causing offset.left to incorrectly be 0
8792
- offset.top -= parseFloat( jQuery.css(elem, "marginTop") ) || 0;
8793
- offset.left -= parseFloat( jQuery.css(elem, "marginLeft") ) || 0;
8794
-
8795
- // Add offsetParent borders
8796
- parentOffset.top += parseFloat( jQuery.css(offsetParent[0], "borderTopWidth") ) || 0;
8797
- parentOffset.left += parseFloat( jQuery.css(offsetParent[0], "borderLeftWidth") ) || 0;
8798
-
8799
- // Subtract the two offsets
8800
- return {
8801
- top: offset.top - parentOffset.top,
8802
- left: offset.left - parentOffset.left
8803
- };
8804
- },
8805
-
8806
- offsetParent: function() {
8807
- return this.map(function() {
8808
- var offsetParent = this.offsetParent || document.body;
8809
- while ( offsetParent && (!rroot.test(offsetParent.nodeName) && jQuery.css(offsetParent, "position") === "static") ) {
8810
- offsetParent = offsetParent.offsetParent;
8811
- }
8812
- return offsetParent;
8813
- });
8814
- }
8815
- });
8816
-
8817
-
8818
- // Create scrollLeft and scrollTop methods
8819
- jQuery.each( ["Left", "Top"], function( i, name ) {
8820
- var method = "scroll" + name;
8821
-
8822
- jQuery.fn[ method ] = function( val ) {
8823
- var elem, win;
8824
-
8825
- if ( val === undefined ) {
8826
- elem = this[ 0 ];
8827
-
8828
- if ( !elem ) {
8829
- return null;
8830
- }
8831
-
8832
- win = getWindow( elem );
8833
-
8834
- // Return the scroll offset
8835
- return win ? ("pageXOffset" in win) ? win[ i ? "pageYOffset" : "pageXOffset" ] :
8836
- jQuery.support.boxModel && win.document.documentElement[ method ] ||
8837
- win.document.body[ method ] :
8838
- elem[ method ];
8839
- }
8840
-
8841
- // Set the scroll offset
8842
- return this.each(function() {
8843
- win = getWindow( this );
8844
-
8845
- if ( win ) {
8846
- win.scrollTo(
8847
- !i ? val : jQuery( win ).scrollLeft(),
8848
- i ? val : jQuery( win ).scrollTop()
8849
- );
8850
-
8851
- } else {
8852
- this[ method ] = val;
8853
- }
8854
- });
8855
- };
8856
- });
8857
-
8858
- function getWindow( elem ) {
8859
- return jQuery.isWindow( elem ) ?
8860
- elem :
8861
- elem.nodeType === 9 ?
8862
- elem.defaultView || elem.parentWindow :
8863
- false;
8864
- }
8865
-
8866
-
8867
-
8868
-
8869
- // Create innerHeight, innerWidth, outerHeight and outerWidth methods
8870
- jQuery.each([ "Height", "Width" ], function( i, name ) {
8871
-
8872
- var type = name.toLowerCase();
8873
-
8874
- // innerHeight and innerWidth
8875
- jQuery.fn["inner" + name] = function() {
8876
- return this[0] ?
8877
- parseFloat( jQuery.css( this[0], type, "padding" ) ) :
8878
- null;
8879
- };
8880
-
8881
- // outerHeight and outerWidth
8882
- jQuery.fn["outer" + name] = function( margin ) {
8883
- return this[0] ?
8884
- parseFloat( jQuery.css( this[0], type, margin ? "margin" : "border" ) ) :
8885
- null;
8886
- };
8887
-
8888
- jQuery.fn[ type ] = function( size ) {
8889
- // Get window width or height
8890
- var elem = this[0];
8891
- if ( !elem ) {
8892
- return size == null ? null : this;
8893
- }
8894
-
8895
- if ( jQuery.isFunction( size ) ) {
8896
- return this.each(function( i ) {
8897
- var self = jQuery( this );
8898
- self[ type ]( size.call( this, i, self[ type ]() ) );
8899
- });
8900
- }
8901
-
8902
- if ( jQuery.isWindow( elem ) ) {
8903
- // Everyone else use document.documentElement or document.body depending on Quirks vs Standards mode
8904
- // 3rd condition allows Nokia support, as it supports the docElem prop but not CSS1Compat
8905
- var docElemProp = elem.document.documentElement[ "client" + name ];
8906
- return elem.document.compatMode === "CSS1Compat" && docElemProp ||
8907
- elem.document.body[ "client" + name ] || docElemProp;
8908
-
8909
- // Get document width or height
8910
- } else if ( elem.nodeType === 9 ) {
8911
- // Either scroll[Width/Height] or offset[Width/Height], whichever is greater
8912
- return Math.max(
8913
- elem.documentElement["client" + name],
8914
- elem.body["scroll" + name], elem.documentElement["scroll" + name],
8915
- elem.body["offset" + name], elem.documentElement["offset" + name]
8916
- );
8917
-
8918
- // Get or set width or height on the element
8919
- } else if ( size === undefined ) {
8920
- var orig = jQuery.css( elem, type ),
8921
- ret = parseFloat( orig );
8922
-
8923
- return jQuery.isNaN( ret ) ? orig : ret;
8924
-
8925
- // Set the width or height on the element (default to pixels if value is unitless)
8926
- } else {
8927
- return this.css( type, typeof size === "string" ? size : size + "px" );
8928
- }
8929
- };
8930
-
8931
- });
8932
-
8933
-
8934
- window.jQuery = window.$ = jQuery;
8935
- })(window);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
js/jquery-1.6.min.js DELETED
@@ -1,16 +0,0 @@
1
- /*!
2
- * jQuery JavaScript Library v1.6
3
- * http://jquery.com/
4
- *
5
- * Copyright 2011, John Resig
6
- * Dual licensed under the MIT or GPL Version 2 licenses.
7
- * http://jquery.org/license
8
- *
9
- * Includes Sizzle.js
10
- * http://sizzlejs.com/
11
- * Copyright 2011, The Dojo Foundation
12
- * Released under the MIT, BSD, and GPL Licenses.
13
- *
14
- * Date: Mon May 2 13:50:00 2011 -0400
15
- */
16
- (function(a,b){function cw(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function ct(a){if(!ch[a]){var b=f("<"+a+">").appendTo("body"),d=b.css("display");b.remove();if(d==="none"||d===""){ci||(ci=c.createElement("iframe"),ci.frameBorder=ci.width=ci.height=0),c.body.appendChild(ci);if(!cj||!ci.createElement)cj=(ci.contentWindow||ci.contentDocument).document,cj.write("<!doctype><html><body></body></html>");b=cj.createElement(a),cj.body.appendChild(b),d=f.css(b,"display"),c.body.removeChild(ci)}ch[a]=d}return ch[a]}function cs(a,b){var c={};f.each(cn.concat.apply([],cn.slice(0,b)),function(){c[this]=a});return c}function cr(){co=b}function cq(){setTimeout(cr,0);return co=f.now()}function cg(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function cf(){try{return new a.XMLHttpRequest}catch(b){}}function b_(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g<i;g++){if(g===1)for(h in a.converters)typeof h=="string"&&(e[h.toLowerCase()]=a.converters[h]);l=k,k=d[g];if(k==="*")k=l;else if(l!=="*"&&l!==k){m=l+" "+k,n=e[m]||e["* "+k];if(!n){p=b;for(o in e){j=o.split(" ");if(j[0]===l||j[0]==="*"){p=e[j[1]+" "+k];if(p){o=e[o],o===!0?n=p:p===!0&&(n=o);break}}}}!n&&!p&&f.error("No conversion from "+m.replace(" "," to ")),n!==!0&&(c=n?n(c):p(o(c)))}}return c}function b$(a,c,d){var e=a.contents,f=a.dataTypes,g=a.responseFields,h,i,j,k;for(i in g)i in d&&(c[g[i]]=d[i]);while(f[0]==="*")f.shift(),h===b&&(h=a.mimeType||c.getResponseHeader("content-type"));if(h)for(i in e)if(e[i]&&e[i].test(h)){f.unshift(i);break}if(f[0]in d)j=f[0];else{for(i in d){if(!f[0]||a.converters[i+" "+f[0]]){j=i;break}k||(k=i)}j=j||k}if(j){j!==f[0]&&f.unshift(j);return d[j]}}function bZ(a,b,c,d){if(f.isArray(b))f.each(b,function(b,e){c||bD.test(a)?d(a,e):bZ(a+"["+(typeof e=="object"||f.isArray(e)?b:"")+"]",e,c,d)});else if(!c&&b!=null&&typeof b=="object")for(var e in b)bZ(a+"["+e+"]",b[e],c,d);else d(a,b)}function bY(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h=a[f],i=0,j=h?h.length:0,k=a===bS,l;for(;i<j&&(k||!l);i++)l=h[i](c,d,e),typeof l=="string"&&(!k||g[l]?l=b:(c.dataTypes.unshift(l),l=bY(a,c,d,e,l,g)));(k||!l)&&!g["*"]&&(l=bY(a,c,d,e,"*",g));return l}function bX(a){return function(b,c){typeof b!="string"&&(c=b,b="*");if(f.isFunction(c)){var d=b.toLowerCase().split(bO),e=0,g=d.length,h,i,j;for(;e<g;e++)h=d[e],j=/^\+/.test(h),j&&(h=h.substr(1)||"*"),i=a[h]=a[h]||[],i[j?"unshift":"push"](c)}}}function bB(a,b,c){var d=b==="width"?bv:bw,e=b==="width"?a.offsetWidth:a.offsetHeight;if(c==="border")return e;f.each(d,function(){c||(e-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?e+=parseFloat(f.css(a,"margin"+this))||0:e-=parseFloat(f.css(a,"border"+this+"Width"))||0});return e}function bl(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval(b.text||b.textContent||b.innerHTML||""),b.parentNode&&b.parentNode.removeChild(b)}function bk(a){f.nodeName(a,"input")?bj(a):a.getElementsByTagName&&f.grep(a.getElementsByTagName("input"),bj)}function bj(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bi(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bh(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bg(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i<j;i++)f.event.add(b,h+(g[h][i].namespace?".":"")+g[h][i].namespace,g[h][i],g[h][i].data)}}}}function bf(a,b){return f.nodeName(a,"table")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function W(a,b,c){b=b||0;if(f.isFunction(b))return f.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return f.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=f.grep(a,function(a){return a.nodeType===1});if(R.test(b))return f.filter(b,d,!c);b=f.filter(b,d)}return f.grep(a,function(a,d){return f.inArray(a,b)>=0===c})}function V(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function N(a,b){return(a&&a!=="*"?a+".":"")+b.replace(z,"`").replace(A,"&")}function M(a){var b,c,d,e,g,h,i,j,k,l,m,n,o,p=[],q=[],r=f._data(this,"events");if(!(a.liveFired===this||!r||!r.live||a.target.disabled||a.button&&a.type==="click")){a.namespace&&(n=new RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")),a.liveFired=this;var s=r.live.slice(0);for(i=0;i<s.length;i++)g=s[i],g.origType.replace(x,"")===a.type?q.push(g.selector):s.splice(i--,1);e=f(a.target).closest(q,a.currentTarget);for(j=0,k=e.length;j<k;j++){m=e[j];for(i=0;i<s.length;i++){g=s[i];if(m.selector===g.selector&&(!n||n.test(g.namespace))&&!m.elem.disabled){h=m.elem,d=null;if(g.preType==="mouseenter"||g.preType==="mouseleave")a.type=g.preType,d=f(a.relatedTarget).closest(g.selector)[0],d&&f.contains(h,d)&&(d=h);(!d||d!==h)&&p.push({elem:h,handleObj:g,level:m.level})}}}for(j=0,k=p.length;j<k;j++){e=p[j];if(c&&e.level>c)break;a.currentTarget=e.elem,a.data=e.handleObj.data,a.handleObj=e.handleObj,o=e.handleObj.origHandler.apply(e.elem,arguments);if(o===!1||a.isPropagationStopped()){c=e.level,o===!1&&(b=!1);if(a.isImmediatePropagationStopped())break}}return b}}function K(a,c,d){var e=f.extend({},d[0]);e.type=a,e.originalEvent={},e.liveFired=b,f.event.handle.call(c,e),e.isDefaultPrevented()&&d[0].preventDefault()}function E(){return!0}function D(){return!1}function m(a,c,d){var e=c+"defer",g=c+"queue",h=c+"mark",i=f.data(a,e,b,!0);i&&(d==="queue"||!f.data(a,g,b,!0))&&(d==="mark"||!f.data(a,h,b,!0))&&setTimeout(function(){!f.data(a,g,b,!0)&&!f.data(a,h,b,!0)&&(f.removeData(a,e,!0),i.resolve())},0)}function l(a){for(var b in a)if(b!=="toJSON")return!1;return!0}function k(a,c,d){if(d===b&&a.nodeType===1){name="data-"+c.replace(j,"$1-$2").toLowerCase(),d=a.getAttribute(name);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNaN(d)?i.test(d)?f.parseJSON(d):d:parseFloat(d)}catch(e){}f.data(a,c,d)}else d=b}return d}var c=a.document,d=a.navigator,e=a.location,f=function(){function H(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(H,1);return}e.ready()}}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/\d/,n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,o=/^[\],:{}\s]*$/,p=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,q=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,r=/(?:^|:|,)(?:\s*\[)+/g,s=/(webkit)[ \/]([\w.]+)/,t=/(opera)(?:.*version)?[ \/]([\w.]+)/,u=/(msie) ([\w.]+)/,v=/(mozilla)(?:.*? rv:([\w.]+))?/,w=d.userAgent,x,y,z,A=Object.prototype.toString,B=Object.prototype.hasOwnProperty,C=Array.prototype.push,D=Array.prototype.slice,E=String.prototype.trim,F=Array.prototype.indexOf,G={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)==="<"&&a.charAt(a.length-1)===">"&&a.length>=3?g=[null,a,null]:g=i.exec(a);if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=n.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.6",length:0,size:function(){return this.length},toArray:function(){return D.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?C.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),y.done(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(D.apply(this,arguments),"slice",D.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:C,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j<k;j++)if((a=arguments[j])!=null)for(c in a){d=i[c],f=a[c];if(i===f)continue;l&&f&&(e.isPlainObject(f)||(g=e.isArray(f)))?(g?(g=!1,h=d&&e.isArray(d)?d:[]):h=d&&e.isPlainObject(d)?d:{},i[c]=e.extend(l,h,f)):f!==b&&(i[c]=f)}return i},e.extend({noConflict:function(b){a.$===e&&(a.$=g),b&&a.jQuery===e&&(a.jQuery=f);return e},isReady:!1,readyWait:1,holdReady:function(a){a?e.readyWait++:e.ready(!0)},ready:function(a){if(a===!0&&!--e.readyWait||a!==!0&&!e.isReady){if(!c.body)return setTimeout(e.ready,1);e.isReady=!0;if(a!==!0&&--e.readyWait>0)return;y.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!y){y=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",z,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",z),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&H()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNaN:function(a){return a==null||!m.test(a)||isNaN(a)},type:function(a){return a==null?String(a):G[A.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;if(a.constructor&&!B.call(a,"constructor")&&!B.call(a.constructor.prototype,"isPrototypeOf"))return!1;var c;for(c in a);return c===b||B.call(a,c)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw a},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(o.test(b.replace(p,"@").replace(q,"]").replace(r,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(b,c,d){a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b)),d=c.documentElement,(!d||!d.nodeName||d.nodeName==="parsererror")&&e.error("Invalid XML: "+b);return c},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g<h;)if(c.apply(a[g++],d)===!1)break}else if(i){for(f in a)if(c.call(a[f],f,a[f])===!1)break}else for(;g<h;)if(c.call(a[g],g,a[g++])===!1)break;return a},trim:E?function(a){return a==null?"":E.call(a)}:function(a){return a==null?"":(a+"").replace(k,"").replace(l,"")},makeArray:function(a,b){var c=b||[];if(a!=null){var d=e.type(a);a.length==null||d==="string"||d==="function"||d==="regexp"||e.isWindow(a)?C.call(c,a):e.merge(c,a)}return c},inArray:function(a,b){if(F)return F.call(b,a);for(var c=0,d=b.length;c<d;c++)if(b[c]===a)return c;return-1},merge:function(a,c){var d=a.length,e=0;if(typeof c.length=="number")for(var f=c.length;e<f;e++)a[d++]=c[e];else while(c[e]!==b)a[d++]=c[e++];a.length=d;return a},grep:function(a,b,c){var d=[],e;c=!!c;for(var f=0,g=a.length;f<g;f++)e=!!b(a[f],f),c!==e&&d.push(a[f]);return d},map:function(a,c,d){var f,g,h=[],i=0,j=a.length,k=a instanceof e||j!==b&&typeof j=="number"&&(j>0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i<j;i++)f=c(a[i],i,d),f!=null&&(h[h.length]=f);else for(g in a)f=c(a[g],g,d),f!=null&&(h[h.length]=f);return h.concat.apply([],h)},guid:1,proxy:function(a,c){if(typeof c=="string"){var d=a[c];c=a,a=d}if(!e.isFunction(a))return b;var f=D.call(arguments,2),g=function(){return a.apply(c,f.concat(D.call(arguments)))};g.guid=a.guid=a.guid||g.guid||e.guid++;return g},access:function(a,c,d,f,g,h){var i=a.length;if(typeof c=="object"){for(var j in c)e.access(a,j,c[j],f,g,d);return a}if(d!==b){f=!h&&f&&e.isFunction(d);for(var k=0;k<i;k++)g(a[k],c,f?d.call(a[k],k,g(a[k],c)):d,h);return a}return i?g(a[0],c):b},now:function(){return(new Date).getTime()},uaMatch:function(a){a=a.toLowerCase();var b=s.exec(a)||t.exec(a)||u.exec(a)||a.indexOf("compatible")<0&&v.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},sub:function(){function a(b,c){return new a.fn.init(b,c)}e.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(c,d){d&&d instanceof e&&!(d instanceof a)&&(d=a(d));return e.fn.init.call(this,c,d,b)},a.fn.init.prototype=a.fn;var b=a(c);return a},browser:{}}),e.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){G["[object "+b+"]"]=b.toLowerCase()}),x=e.uaMatch(w),x.browser&&(e.browser[x.browser]=!0,e.browser.version=x.version),e.browser.webkit&&(e.browser.safari=!0),j.test(" ")&&(k=/^[\s\xA0]+/,l=/[\s\xA0]+$/),h=e(c),c.addEventListener?z=function(){c.removeEventListener("DOMContentLoaded",z,!1),e.ready()}:c.attachEvent&&(z=function(){c.readyState==="complete"&&(c.detachEvent("onreadystatechange",z),e.ready())});return e}(),g="done fail isResolved isRejected promise then always pipe".split(" "),h=[].slice;f.extend({_Deferred:function(){var a=[],b,c,d,e={done:function(){if(!d){var c=arguments,g,h,i,j,k;b&&(k=b,b=0);for(g=0,h=c.length;g<h;g++)i=c[g],j=f.type(i),j==="array"?e.done.apply(e,i):j==="function"&&a.push(i);k&&e.resolveWith(k[0],k[1])}return this},resolveWith:function(e,f){if(!d&&!b&&!c){f=f||[],c=1;try{while(a[0])a.shift().apply(e,f)}finally{b=[e,f],c=0}}return this},resolve:function(){e.resolveWith(this,arguments);return this},isResolved:function(){return!!c||!!b},cancel:function(){d=1,a=[];return this}};return e},Deferred:function(a){var b=f._Deferred(),c=f._Deferred(),d;f.extend(b,{then:function(a,c){b.done(a).fail(c);return this},always:function(){return b.done.apply(b,arguments).fail.apply(this,arguments)},fail:c.done,rejectWith:c.resolveWith,reject:c.resolve,isRejected:c.isResolved,pipe:function(a,c){return f.Deferred(function(d){f.each({done:[a,"resolve"],fail:[c,"reject"]},function(a,c){var e=c[0],g=c[1],h;f.isFunction(e)?b[a](function(){h=e.apply(this,arguments),f.isFunction(h.promise)?h.promise().then(d.resolve,d.reject):d[g](h)}):b[a](d[g])})}).promise()},promise:function(a){if(a==null){if(d)return d;d=a={}}var c=g.length;while(c--)a[g[c]]=b[g[c]];return a}}),b.done(c.cancel).fail(b.cancel),delete b.cancel,a&&a.call(b,b);return b},when:function(a){function i(a){return function(c){b[a]=arguments.length>1?h.call(arguments,0):c,--e||g.resolveWith(g,h.call(b,0))}}var b=arguments,c=0,d=b.length,e=d,g=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred();if(d>1){for(;c<d;c++)b[c]&&f.isFunction(b[c].promise)?b[c].promise().then(i(c),g.reject):--e;e||g.resolveWith(g,b)}else g!==a&&g.resolveWith(g,d?[a]:[]);return g.promise()}}),f.support=function(){var a=c.createElement("div"),b,d,e,f,g,h,i,j,k,l,m,n,o,p,q;a.setAttribute("className","t"),a.innerHTML=" <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>",b=a.getElementsByTagName("*"),d=a.getElementsByTagName("a")[0];if(!b||!b.length||!d)return{};e=c.createElement("select"),f=e.appendChild(c.createElement("option")),g=a.getElementsByTagName("input")[0],i={leadingWhitespace:a.firstChild.nodeType===3,tbody:!a.getElementsByTagName("tbody").length,htmlSerialize:!!a.getElementsByTagName("link").length,style:/top/.test(d.getAttribute("style")),hrefNormalized:d.getAttribute("href")==="/a",opacity:/^0.55$/.test(d.style.opacity),cssFloat:!!d.style.cssFloat,checkOn:g.value==="on",optSelected:f.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},g.checked=!0,i.noCloneChecked=g.cloneNode(!0).checked,e.disabled=!0,i.optDisabled=!f.disabled;try{delete a.test}catch(r){i.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function click(){i.noCloneEvent=!1,a.detachEvent("onclick",click)}),a.cloneNode(!0).fireEvent("onclick")),g=c.createElement("input"),g.value="t",g.setAttribute("type","radio"),i.radioValue=g.value==="t",g.setAttribute("checked","checked"),a.appendChild(g),j=c.createDocumentFragment(),j.appendChild(a.firstChild),i.checkClone=j.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",k=c.createElement("body"),l={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"};for(p in l)k.style[p]=l[p];k.appendChild(a),c.documentElement.appendChild(k),i.appendChecked=g.checked,i.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,i.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="<div style='width:4px;'></div>",i.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>",m=a.getElementsByTagName("td"),q=m[0].offsetHeight===0,m[0].style.display="",m[1].style.display="none",i.reliableHiddenOffsets=q&&m[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(h=c.createElement("div"),h.style.width="0",h.style.marginRight="0",a.appendChild(h),i.reliableMarginRight=(parseInt(c.defaultView.getComputedStyle(h,null).marginRight,10)||0)===0),k.innerHTML="",c.documentElement.removeChild(k);if(a.attachEvent)for(p in{submit:1,change:1,focusin:1})o="on"+p,q=o in a,q||(a.setAttribute(o,"return;"),q=typeof a[o]=="function"),i[p+"Bubbles"]=q;return i}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([a-z])([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!l(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g=f.expando,h=typeof c=="string",i,j=a.nodeType,k=j?f.cache:a,l=j?a[f.expando]:a[f.expando]&&f.expando;if((!l||e&&l&&!k[l][g])&&h&&d===b)return;l||(j?a[f.expando]=l=++f.uuid:l=f.expando),k[l]||(k[l]={},j||(k[l].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?k[l][g]=f.extend(k[l][g],c):k[l]=f.extend(k[l],c);i=k[l],e&&(i[g]||(i[g]={}),i=i[g]),d!==b&&(i[c]=d);if(c==="events"&&!i[c])return i[g]&&i[g].events;return h?i[c]:i}},removeData:function(b,c,d){if(!!f.acceptData(b)){var e=f.expando,g=b.nodeType,h=g?f.cache:b,i=g?b[f.expando]:f.expando;if(!h[i])return;if(c){var j=d?h[i][e]:h[i];if(j){delete j[c];if(!l(j))return}}if(d){delete h[i][e];if(!l(h[i]))return}var k=h[i][e];f.support.deleteExpando||h!=a?delete h[i]:h[i]=null,k?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=k):g&&(f.support.deleteExpando?delete b[f.expando]:b.removeAttribute?b.removeAttribute(f.expando):b[f.expando]=null)}},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d=null;if(typeof a=="undefined"){if(this.length){d=f.data(this[0]);if(this[0].nodeType===1){var e=this[0].attributes,g;for(var h=0,i=e.length;h<i;h++)g=e[h].name,g.indexOf("data-")===0&&(g=f.camelCase(g.substring(5)),k(this[0],g,d[g]))}}return d}if(typeof a=="object")return this.each(function(){f.data(this,a)});var j=a.split(".");j[1]=j[1]?"."+j[1]:"";if(c===b){d=this.triggerHandler("getData"+j[1]+"!",[j[0]]),d===b&&this.length&&(d=f.data(this[0],a),d=k(this[0],a,d));return d===b&&j[1]?this.data(j[0]):d}return this.each(function(){var b=f(this),d=[j[0],c];b.triggerHandler("setData"+j[1]+"!",d),f.data(this,a,c),b.triggerHandler("changeData"+j[1]+"!",d)})},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,c){a&&(c=(c||"fx")+"mark",f.data(a,c,(f.data(a,c,b,!0)||0)+1,!0))},_unmark:function(a,c,d){a!==!0&&(d=c,c=a,a=!1);if(c){d=d||"fx";var e=d+"mark",g=a?0:(f.data(c,e,b,!0)||1)-1;g?f.data(c,e,g,!0):(f.removeData(c,e,!0),m(c,d,"mark"))}},queue:function(a,c,d){if(a){c=(c||"fx")+"queue";var e=f.data(a,c,b,!0);d&&(!e||f.isArray(d)?e=f.data(a,c,f.makeArray(d),!0):e.push(d));return e||[]}},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e;d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),d.call(a,function(){f.dequeue(a,b)})),c.length||(f.removeData(a,b+"queue",!0),m(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){typeof a!="string"&&(c=a,a="fx");if(c===b)return f.queue(this[0],a);return this.each(function(){var b=f.queue(this,a,c);a==="fx"&&b[0]!=="inprogress"&&f.dequeue(this,a)})},dequeue:function(a){return this.each(function(){f.dequeue(this,a)})},delay:function(a,b){a=f.fx?f.fx.speeds[a]||a:a,b=b||"fx";return this.queue(b,function(){var c=this;setTimeout(function(){f.dequeue(c,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){function l(){--h||d.resolveWith(e,[e])}typeof a!="string"&&(c=a,a=b),a=a||"fx";var d=f.Deferred(),e=this,g=e.length,h=1,i=a+"defer",j=a+"queue",k=a+"mark";while(g--)if(tmp=f.data(e[g],i,b,!0)||(f.data(e[g],j,b,!0)||f.data(e[g],k,b,!0))&&f.data(e[g],i,f._Deferred(),!0))h++,tmp.done(l);l();return d.promise()}});var n=/[\n\t\r]/g,o=/\s+/,p=/\r/g,q=/^(?:button|input)$/i,r=/^(?:button|input|object|select|textarea)$/i,s=/^a(?:rea)?$/i,t=/^(?:data-|aria-)/,u=/\:/,v;f.fn.extend({attr:function(a,b){return f.access(this,a,b,!0,f.attr)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,a,b,!0,f.prop)},removeProp:function(a){return this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.addClass(a.call(this,b,c.attr("class")||""))});if(a&&typeof a=="string"){var b=(a||"").split(o);for(var c=0,d=this.length;c<d;c++){var e=this[c];if(e.nodeType===1)if(!e.className)e.className=a;else{var g=" "+e.className+" ",h=e.className;for(var i=0,j=b.length;i<j;i++)g.indexOf(" "+b[i]+" ")<0&&(h+=" "+b[i]);e.className=f.trim(h)}}}return this},removeClass:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.removeClass(a.call(this,b,c.attr("class")))});if(a&&typeof a=="string"||a===b){var c=(a||"").split(o);for(var d=0,e=this.length;d<e;d++){var g=this[d];if(g.nodeType===1&&g.className)if(a){var h=(" "+g.className+" ").replace(n," ");for(var i=0,j=c.length;i<j;i++)h=h.replace(" "+c[i]+" "," ");g.className=f.trim(h)}else g.className=""}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";if(f.isFunction(a))return this.each(function(c){var d=f(this);d.toggleClass(a.call(this,c,d.attr("class"),b),b)});return this.each(function(){if(c==="string"){var e,g=0,h=f(this),i=b,j=a.split(o);while(e=j[g++])i=d?i:!h.hasClass(e),h[i?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&f._data(this,"__className__",this.className),this.className=this.className||a===!1?"":f._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ";for(var c=0,d=this.length;c<d;c++)if((" "+this[c].className+" ").replace(n," ").indexOf(b)>-1)return!0;return!1},val:function(a){var c,d,e=this[0];if(!arguments.length){if(e){c=f.valHooks[e.nodeName.toLowerCase()]||f.valHooks[e.type];if(c&&"get"in c&&(d=c.get(e,"value"))!==b)return d;return(e.value||"").replace(p,"")}return b}var g=f.isFunction(a);return this.each(function(d){var e=f(this),h;if(this.nodeType===1){g?h=a.call(this,d,e.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||"set"in c&&c.set(this,h,"value")===b)this.value=h}})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b=a.selectedIndex,c=[],d=a.options,e=a.type==="select-one";if(b<0)return null;for(var g=e?b:0,h=e?b+1:d.length;g<h;g++){var i=d[g];if(i.selected&&(f.support.optDisabled?!i.disabled:i.getAttribute("disabled")===null)&&(!i.parentNode.disabled||!f.nodeName(i.parentNode,"optgroup"))){value=f(i).val();if(e)return value;c.push(value)}}if(e&&!c.length&&d.length)return f(d[b]).val();return c},set:function(a,b){var c=f.makeArray(b);f(a).find("option").each(function(){this.selected=f.inArray(f(this).val(),c)>=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attrFix:{tabindex:"tabIndex",readonly:"readOnly"},attr:function(a,c,d,e){var g=a.nodeType;if(!a||g===3||g===8||g===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);var h,i,j=g!==1||!f.isXMLDoc(a);c=j&&f.attrFix[c]||c,i=f.attrHooks[c]||(v&&(f.nodeName(a,"form")||u.test(c))?v:b);if(d!==b){if(d===null||d===!1&&!t.test(c)){f.removeAttr(a,c);return b}if(i&&"set"in i&&j&&(h=i.set(a,d,c))!==b)return h;d===!0&&!t.test(c)&&(d=c),a.setAttribute(c,""+d);return d}if(i&&"get"in i&&j)return i.get(a,c);h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){a.nodeType===1&&(b=f.attrFix[b]||b,f.support.getSetAttribute?a.removeAttribute(b):(f.attr(a,b,""),a.removeAttributeNode(a.getAttributeNode(b))))},attrHooks:{type:{set:function(a,b){if(q.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.getAttribute("value");a.setAttribute("type",b),c&&(a.value=c);return b}}},tabIndex:{get:function(a){var c=a.getAttributeNode("tabIndex");return c&&c.specified?parseInt(c.value,10):r.test(a.nodeName)||s.test(a.nodeName)&&a.href?0:b}}},propFix:{},prop:function(a,c,d){var e=a.nodeType;if(!a||e===3||e===8||e===2)return b;var g,h,i=e!==1||!f.isXMLDoc(a);c=i&&f.propFix[c]||c,h=f.propHooks[c];return d!==b?h&&"set"in h&&(g=h.set(a,d,c))!==b?g:a[c]=d:h&&"get"in h&&(g=h.get(a,c))!==b?g:a[c]},propHooks:{}}),f.support.getSetAttribute||(f.attrFix=f.extend(f.attrFix,{"for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder"}),v=f.attrHooks.name=f.attrHooks.value=f.valHooks.button={get:function(a,c){var d;if(c==="value"&&!f.nodeName(a,"button"))return a.getAttribute(c);d=a.getAttributeNode(c);return d&&d.specified?d.nodeValue:b},set:function(a,b,c){var d=a.getAttributeNode(c);if(d){d.nodeValue=b;return b}}},f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c===""){a.setAttribute(b,"auto");return c}}})})),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}})),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var w=Object.prototype.hasOwnProperty,x=/\.(.*)$/,y=/^(?:textarea|input|select)$/i,z=/\./g,A=/ /g,B=/[^\w\s.|`]/g,C=function(a){return a.replace(B,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=D;else if(!d)return;var g,h;d.handler&&(g=d,d=g.handler),d.guid||(d.guid=f.guid++);var i=f._data(a);if(!i)return;var j=i.events,k=i.handle;j||(i.events=j={}),k||(i.handle=k=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.handle.apply(k.elem,arguments):b}),k.elem=a,c=c.split(" ");var l,m=0,n;while(l=c[m++]){h=g?f.extend({},g):{handler:d,data:e},l.indexOf(".")>-1?(n=l.split("."),l=n.shift(),h.namespace=n.slice(0).sort().join(".")):(n=[],h.namespace=""),h.type=l,h.guid||(h.guid=d.guid);var o=j[l],p=f.event.special[l]||{};if(!o){o=j[l]=[];if(!p.setup||p.setup.call(a,e,n,k)===!1)a.addEventListener?a.addEventListener(l,k,!1):a.attachEvent&&a.attachEvent("on"+l,k)}p.add&&(p.add.call(a,h),h.handler.guid||(h.handler.guid=d.guid)),o.push(h),f.event.global[l]=!0}a=null}},global:{},remove:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){d===!1&&(d=D);var g,h,i,j,k=0,l,m,n,o,p,q,r,s=f.hasData(a)&&f._data(a),t=s&&s.events;if(!s||!t)return;c&&c.type&&(d=c.handler,c=c.type);if(!c||typeof c=="string"&&c.charAt(0)==="."){c=c||"";for(h in t)f.event.remove(a,h+c);return}c=c.split(" ");while(h=c[k++]){r=h,q=null,l=h.indexOf(".")<0,m=[],l||(m=h.split("."),h=m.shift(),n=new RegExp("(^|\\.)"+f.map(m.slice(0).sort(),C).join("\\.(?:.*\\.)?")+"(\\.|$)")),p=t[h];if(!p)continue;if(!d){for(j=0;j<p.length;j++){q=p[j];if(l||n.test(q.namespace))f.event.remove(a,r,q.handler,j),p.splice(j--,1)}continue}o=f.event.special[h]||{};for(j=e||0;j<p.length;j++){q=p[j];if(d.guid===q.guid){if(l||n.test(q.namespace))e==null&&p.splice(j--,1),o.remove&&o.remove.call(a,q);if(e!=null)break}}if(p.length===0||e!=null&&p.length===1)(!o.teardown||o.teardown.call(a,m)===!1)&&f.removeEvent(a,h,s.handle),g=null,delete t[h]}if(f.isEmptyObject(t)){var u=s.handle;u&&(u.elem=null),delete s.events,delete s.handle,f.isEmptyObject(s)&&f.removeData(a,b,!0)}}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,g){var h=c.type||c,i=[],j;h.indexOf("!")>=0&&(h=h.slice(0,-1),j=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if(!!e&&!f.event.customEvent[h]||!!f.event.global[h]){c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.exclusive=j,c.namespace=i.join("."),c.namespace_re=new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)");if(g||!e)c.preventDefault(),c.stopPropagation();if(!e){f.each(f.cache,function(){var a=f.expando,b=this[a];b&&b.events&&b.events[h]&&f.event.trigger(c,d,b.handle.elem)});return}if(e.nodeType===3||e.nodeType===8)return;c.result=b,c.target=e,d=d?f.makeArray(d):[],d.unshift(c);var k=e,l=h.indexOf(":")<0?"on"+h:"";do{var m=f._data(k,"handle");c.currentTarget=k,m&&m.apply(k,d),l&&f.acceptData(k)&&k[l]&&k[l].apply(k,d)===!1&&(c.result=!1,c.preventDefault()),k=k.parentNode||k.ownerDocument||k===c.target.ownerDocument&&a}while(k&&!c.isPropagationStopped());if(!c.isDefaultPrevented()){var n,o=f.event.special[h]||{};if((!o._default||o._default.call(e.ownerDocument,c)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)){try{l&&e[h]&&(n=e[l],n&&(e[l]=null),f.event.triggered=h,e[h]())}catch(p){}n&&(e[l]=n),f.event.triggered=b}}return c.result}},handle:function(c){c=f.event.fix(c||a.event);var d=((f._data(this,"events")||{})[c.type]||[]).slice(0),e=!c.exclusive&&!c.namespace,g=Array.prototype.slice.call(arguments,0);g[0]=c,c.currentTarget=this;for(var h=0,i=d.length;h<i;h++){var j=d[h];if(e||c.namespace_re.test(j.namespace)){c.handler=j.handler,c.data=j.data,c.handleObj=j;var k=j.handler.apply(this,g);k!==b&&(c.result=k,k===!1&&(c.preventDefault(),c.stopPropagation()));if(c.isImmediatePropagationStopped())break}}return c.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(a){if(a[f.expando])return a;var d=a;a=f.Event(d);for(var e=this.props.length,g;e;)g=this.props[--e],a[g]=d[g];a.target||(a.target=a.srcElement||c),a.target.nodeType===3&&(a.target=a.target.parentNode),!a.relatedTarget&&a.fromElement&&(a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement);if(a.pageX==null&&a.clientX!=null){var h=a.target.ownerDocument||c,i=h.documentElement,j=h.body;a.pageX=a.clientX+(i&&i.scrollLeft||j&&j.scrollLeft||0)-(i&&i.clientLeft||j&&j.clientLeft||0),a.pageY=a.clientY+(i&&i.scrollTop||j&&j.scrollTop||0)-(i&&i.clientTop||j&&j.clientTop||0)}a.which==null&&(a.charCode!=null||a.keyCode!=null)&&(a.which=a.charCode!=null?a.charCode:a.keyCode),!a.metaKey&&a.ctrlKey&&(a.metaKey=a.ctrlKey),!a.which&&a.button!==b&&(a.which=a.button&1?1:a.button&2?3:a.button&4?2:0);return a},guid:1e8,proxy:f.proxy,special:{ready:{setup:f.bindReady,teardown:f.noop},live:{add:function(a){f.event.add(this,N(a.origType,a.selector),f.extend({},a,{handler:M,guid:a.handler.guid}))},remove:function(a){f.event.remove(this,N(a.origType,a.selector),a)}},beforeunload:{setup:function(a,b,c){f.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}}},f.removeEvent=c.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){a.detachEvent&&a.detachEvent("on"+b,c)},f.Event=function(a,b){if(!this.preventDefault)return new f.Event(a,b);a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?E:D):this.type=a,b&&f.extend(this,b),this.timeStamp=f.now(),this[f.expando]=!0},f.Event.prototype={preventDefault:function(){this.isDefaultPrevented=E;var a=this.originalEvent;!a||(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=E;var a=this.originalEvent;!a||(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=E,this.stopPropagation()},isDefaultPrevented:D,isPropagationStopped:D,isImmediatePropagationStopped:D};var F=function(a){var b=a.relatedTarget;try{if(b&&b!==c&&!b.parentNode)return;while(b&&b!==this)b=b.parentNode;b!==this&&(a.type=a.data,f.event.handle.apply(this,arguments))}catch(d){}},G=function(a){a.type=a.data,f.event.handle.apply(this,arguments)};f.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){f.event.special[a]={setup:function(c){f.event.add(this,b,c&&c.selector?G:F,a)},teardown:function(a){f.event.remove(this,b,a&&a.selector?G:F)}}}),f.support.submitBubbles||(f.event.special.submit={setup:function(a,b){if(!f.nodeName(this,"form"))f.event.add(this,"click.specialSubmit",function(a){var b=a.target,c=b.type;(c==="submit"||c==="image")&&f(b).closest("form").length&&K("submit",this,arguments)}),f.event.add(this,"keypress.specialSubmit",function(a){var b=a.target,c=b.type;(c==="text"||c==="password")&&f(b).closest("form").length&&a.keyCode===13&&K("submit",this,arguments)});else return!1},teardown:function(a){f.event.remove(this,".specialSubmit")}});if(!f.support.changeBubbles){var H,I=function(a){var b=a.type,c=a.value;b==="radio"||b==="checkbox"?c=a.checked:b==="select-multiple"?c=a.selectedIndex>-1?f.map(a.options,function(a){return a.selected}).join("-"):"":f.nodeName(a,"select")&&(c=a.selectedIndex);return c},J=function J(a){var c=a.target,d,e;if(!!y.test(c.nodeName)&&!c.readOnly){d=f._data(c,"_change_data"),e=I(c),(a.type!=="focusout"||c.type!=="radio")&&f._data(c,"_change_data",e);if(d===b||e===d)return;if(d!=null||e)a.type="change",a.liveFired=b,f.event.trigger(a,arguments[1],c)}};f.event.special.change={filters:{focusout:J,beforedeactivate:J,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&J.call(this,a)},keydown:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(a.keyCode===13&&!f.nodeName(b,"textarea")||a.keyCode===32&&(c==="checkbox"||c==="radio")||c==="select-multiple")&&J.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",I(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in H)f.event.add(this,c+".specialChange",H[c]);return y.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return y.test(this.nodeName)}},H=f.event.special.change.filters,H.focus=H.beforeactivate}f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){function e(a){var c=f.event.fix(a);c.type=b,c.originalEvent={},f.event.trigger(c,null,c.target),c.isDefaultPrevented()&&a.preventDefault()}var d=0;f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.each(["bind","one"],function(a,c){f.fn[c]=function(a,d,e){var g;if(typeof a=="object"){for(var h in a)this[c](h,d,a[h],e);return this}if(arguments.length===2||d===!1)e=d,d=b;c==="one"?(g=function(a){f(this).unbind(a,g);return e.apply(this,arguments)},g.guid=e.guid||f.guid++):g=e;if(a==="unload"&&c!=="one")this.one(a,d,e);else for(var i=0,j=this.length;i<j;i++)f.event.add(this[i],a,g,d);return this}}),f.fn.extend({unbind:function(a,b){if(typeof a=="object"&&!a.preventDefault)for(var c in a)this.unbind(c,a[c]);else for(var d=0,e=this.length;d<e;d++)f.event.remove(this[d],a,b);return this},delegate:function(a,b,c,d){return this.live(b,c,d,a)},undelegate:function(a,b,c){return arguments.length===0?this.unbind("live"):this.die(b,null,c,a)},trigger:function(a,b){return this.each(function(){f.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return f.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||f.guid++,d=0,e=function(c){var e=(f.data(this,"lastToggle"+a.guid)||0)%d;f.data(this,"lastToggle"+a.guid,e+1),c.preventDefault();return b[e].apply(this,arguments)||!1};e.guid=c;while(d<b.length)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var L={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};f.each(["live","die"],function(a,c){f.fn[c]=function(a,d,e,g){var h,i=0,j,k,l,m=g||this.selector,n=g?this:f(this.context);if(typeof a=="object"&&!a.preventDefault){for(var o in a)n[c](o,d,a[o],m);return this}if(c==="die"&&!a&&g&&g.charAt(0)==="."){n.unbind(g);return this}if(d===!1||f.isFunction(d))e=d||D,d=b;a=(a||"").split(" ");while((h=a[i++])!=null){j=x.exec(h),k="",j&&(k=j[0],h=h.replace(x,""));if(h==="hover"){a.push("mouseenter"+k,"mouseleave"+k);continue}l=h,L[h]?(a.push(L[h]+k),h=h+k):h=(L[h]||h)+k;if(c==="live")for(var p=0,q=n.length;p<q;p++)f.event.add(n[p],"live."+N(h,m),{data:d,selector:m,handler:e,origType:h,origHandler:e,preType:l});else n.unbind("live."+N(h,m),e)}return this}}),f.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".split(" "),function(a,b){f.fn[b]=function(a,c){c==null&&(c=a,a=null);return arguments.length>0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0)}),function(){function u(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}if(i.nodeType===1){f||(i.sizcache=c,i.sizset=g);if(typeof b!="string"){if(i===b){j=!0;break}}else if(k.filter(b,[i]).length>0){j=i;break}}i=i[a]}d[g]=j}}}function t(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}i.nodeType===1&&!f&&(i.sizcache=c,i.sizset=g);if(i.nodeName.toLowerCase()===b){j=i;break}i=i[a]}d[g]=j}}}var a=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d=0,e=Object.prototype.toString,g=!1,h=!0,i=/\\/g,j=/\W/;[0,0].sort(function(){h=!1;return 0});var k=function(b,d,f,g){f=f||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return f;var i,j,n,o,q,r,s,t,u=!0,w=k.isXML(d),x=[],y=b;do{a.exec(""),i=a.exec(y);if(i){y=i[3],x.push(i[1]);if(i[2]){o=i[3];break}}}while(i);if(x.length>1&&m.exec(b))if(x.length===2&&l.relative[x[0]])j=v(x[0]+x[1],d);else{j=l.relative[x[0]]?[d]:k(x.shift(),d);while(x.length)b=x.shift(),l.relative[b]&&(b+=x.shift()),j=v(b,j)}else{!g&&x.length>1&&d.nodeType===9&&!w&&l.match.ID.test(x[0])&&!l.match.ID.test(x[x.length-1])&&(q=k.find(x.shift(),d,w),d=q.expr?k.filter(q.expr,q.set)[0]:q.set[0]);if(d){q=g?{expr:x.pop(),set:p(g)}:k.find(x.pop(),x.length===1&&(x[0]==="~"||x[0]==="+")&&d.parentNode?d.parentNode:d,w),j=q.expr?k.filter(q.expr,q.set):q.set,x.length>0?n=p(j):u=!1;while(x.length)r=x.pop(),s=r,l.relative[r]?s=x.pop():r="",s==null&&(s=d),l.relative[r](n,s,w)}else n=x=[]}n||(n=j),n||k.error(r||b);if(e.call(n)==="[object Array]")if(!u)f.push.apply(f,n);else if(d&&d.nodeType===1)for(t=0;n[t]!=null;t++)n[t]&&(n[t]===!0||n[t].nodeType===1&&k.contains(d,n[t]))&&f.push(j[t]);else for(t=0;n[t]!=null;t++)n[t]&&n[t].nodeType===1&&f.push(j[t]);else p(n,f);o&&(k(o,h,f,g),k.uniqueSort(f));return f};k.uniqueSort=function(a){if(r){g=h,a.sort(r);if(g)for(var b=1;b<a.length;b++)a[b]===a[b-1]&&a.splice(b--,1)}return a},k.matches=function(a,b){return k(a,null,null,b)},k.matchesSelector=function(a,b){return k(b,null,null,[a]).length>0},k.find=function(a,b,c){var d;if(!a)return[];for(var e=0,f=l.order.length;e<f;e++){var g,h=l.order[e];if(g=l.leftMatch[h].exec(a)){var j=g[1];g.splice(1,1);if(j.substr(j.length-1)!=="\\"){g[1]=(g[1]||"").replace(i,""),d=l.find[h](g,b,c);if(d!=null){a=a.replace(l.match[h],"");break}}}}d||(d=typeof b.getElementsByTagName!="undefined"?b.getElementsByTagName("*"):[]);return{set:d,expr:a}},k.filter=function(a,c,d,e){var f,g,h=a,i=[],j=c,m=c&&c[0]&&k.isXML(c[0]);while(a&&c.length){for(var n in l.filter)if((f=l.leftMatch[n].exec(a))!=null&&f[2]){var o,p,q=l.filter[n],r=f[1];g=!1,f.splice(1,1);if(r.substr(r.length-1)==="\\")continue;j===i&&(i=[]);if(l.preFilter[n]){f=l.preFilter[n](f,j,d,i,e,m);if(!f)g=o=!0;else if(f===!0)continue}if(f)for(var s=0;(p=j[s])!=null;s++)if(p){o=q(p,f,s,j);var t=e^!!o;d&&o!=null?t?g=!0:j[s]=!1:t&&(i.push(p),g=!0)}if(o!==b){d||(j=i),a=a.replace(l.match[n],"");if(!g)return[];break}}if(a===h)if(g==null)k.error(a);else break;h=a}return j},k.error=function(a){throw"Syntax error, unrecognized expression: "+a};var l=k.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(a){return a.getAttribute("href")},type:function(a){return a.getAttribute("type")}},relative:{"+":function(a,b){var c=typeof b=="string",d=c&&!j.test(b),e=c&&!d;d&&(b=b.toLowerCase());for(var f=0,g=a.length,h;f<g;f++)if(h=a[f]){while((h=h.previousSibling)&&h.nodeType!==1);a[f]=e||h&&h.nodeName.toLowerCase()===b?h||!1:h===b}e&&k.filter(b,a,!0)},">":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!j.test(b)){b=b.toLowerCase();for(;e<f;e++){c=a[e];if(c){var g=c.parentNode;a[e]=g.nodeName.toLowerCase()===b?g:!1}}}else{for(;e<f;e++)c=a[e],c&&(a[e]=d?c.parentNode:c.parentNode===b);d&&k.filter(b,a,!0)}},"":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("parentNode",b,f,a,e,c)},"~":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("previousSibling",b,f,a,e,c)}},find:{ID:function(a,b,c){if(typeof b.getElementById!="undefined"&&!c){var d=b.getElementById(a[1]);return d&&d.parentNode?[d]:[]}},NAME:function(a,b){if(typeof b.getElementsByName!="undefined"){var c=[],d=b.getElementsByName(a[1]);for(var e=0,f=d.length;e<f;e++)d[e].getAttribute("name")===a[1]&&c.push(d[e]);return c.length===0?null:c}},TAG:function(a,b){if(typeof b.getElementsByTagName!="undefined")return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,c,d,e,f){a=" "+a[1].replace(i,"")+" ";if(f)return a;for(var g=0,h;(h=b[g])!=null;g++)h&&(e^(h.className&&(" "+h.className+" ").replace(/[\t\n\r]/g," ").indexOf(a)>=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(i,"")},TAG:function(a,b){return a[1].replace(i,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||k.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&k.error(a[0]);a[0]=d++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(i,"");!f&&l.attrMap[g]&&(a[1]=l.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(i,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=k(b[3],null,null,c);else{var g=k.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(l.match.POS.test(b[0])||l.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!k(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){return a.nodeName.toLowerCase()==="input"&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return b<c[3]-0},gt:function(a,b,c){return b>c[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=l.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||k.getText([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h<i;h++)if(g[h]===a)return!1;return!0}k.error(e)},CHILD:function(a,b){var c=b[1],d=a;switch(c){case"only":case"first":while(d=d.previousSibling)if(d.nodeType===1)return!1;if(c==="first")return!0;d=a;case"last":while(d=d.nextSibling)if(d.nodeType===1)return!1;return!0;case"nth":var e=b[2],f=b[3];if(e===1&&f===0)return!0;var g=b[0],h=a.parentNode;if(h&&(h.sizcache!==g||!a.nodeIndex)){var i=0;for(d=h.firstChild;d;d=d.nextSibling)d.nodeType===1&&(d.nodeIndex=++i);h.sizcache=g}var j=a.nodeIndex-f;return e===0?j===0:j%e===0&&j/e>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=l.attrHandle[c]?l.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=l.setFilters[e];if(f)return f(a,c,b,d)}}},m=l.match.POS,n=function(a,b){return"\\"+(b-0+1)};for(var o in l.match)l.match[o]=new RegExp(l.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),l.leftMatch[o]=new RegExp(/(^(?:.|\r|\n)*?)/.source+l.match[o].source.replace(/\\(\d+)/g,n));var p=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(q){p=function(a,b){var c=0,d=b||[];if(e.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var f=a.length;c<f;c++)d.push(a[c]);else for(;a[c];c++)d.push(a[c]);return d}}var r,s;c.documentElement.compareDocumentPosition?r=function(a,b){if(a===b){g=!0;return 0}if(!a.compareDocumentPosition||!b.compareDocumentPosition)return a.compareDocumentPosition?-1:1;return a.compareDocumentPosition(b)&4?-1:1}:(r=function(a,b){var c,d,e=[],f=[],h=a.parentNode,i=b.parentNode,j=h;if(a===b){g=!0;return 0}if(h===i)return s(a,b);if(!h)return-1;if(!i)return 1;while(j)e.unshift(j),j=j.parentNode;j=i;while(j)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return s(e[k],f[k]);return k===c?s(a,f[k],-1):s(e[k],b,1)},s=function(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}),k.getText=function(a){var b="",c;for(var d=0;a[d];d++)c=a[d],c.nodeType===3||c.nodeType===4?b+=c.nodeValue:c.nodeType!==8&&(b+=k.getText(c.childNodes));return b},function(){var a=c.createElement("div"),d="script"+(new Date).getTime(),e=c.documentElement;a.innerHTML="<a name='"+d+"'/>",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(l.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},l.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(l.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(l.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=k,b=c.createElement("div"),d="__sizzle__";b.innerHTML="<p class='TEST'></p>";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){k=function(b,e,f,g){e=e||c;if(!g&&!k.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return p(e.getElementsByTagName(b),f);if(h[2]&&l.find.CLASS&&e.getElementsByClassName)return p(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return p([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return p([],f);if(i.id===h[3])return p([i],f)}try{return p(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var m=e,n=e.getAttribute("id"),o=n||d,q=e.parentNode,r=/^\s*[+~]/.test(b);n?o=o.replace(/'/g,"\\$&"):e.setAttribute("id",o),r&&q&&(e=e.parentNode);try{if(!r||q)return p(e.querySelectorAll("[id='"+o+"'] "+b),f)}catch(s){}finally{n||m.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)k[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}k.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!k.isXML(a))try{if(e||!l.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return k(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;l.order.splice(1,0,"CLASS"),l.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?k.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?k.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:k.contains=function(){return!1},k.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var v=function(a,b){var c,d=[],e="",f=b.nodeType?[b]:b;while(c=l.match.PSEUDO.exec(a))e+=c[0],a=a.replace(l.match.PSEUDO,"");a=l.relative[a]?a+"*":a;for(var g=0,h=f.length;g<h;g++)k(a,f[g],d);return k.filter(e,d)};f.find=k,f.expr=k.selectors,f.expr[":"]=f.expr.filters,f.unique=k.uniqueSort,f.text=k.getText,f.isXMLDoc=k.isXML,f.contains=k.contains}();var O=/Until$/,P=/^(?:parents|prevUntil|prevAll)/,Q=/,/,R=/^.[^:#\[\.,]*$/,S=Array.prototype.slice,T=f.expr.match.POS,U={children:!0,contents:!0,next:!0,prev:!0};f.fn.extend({find:function(a){var b=this,c,d;if(typeof a!="string")return f(a).filter(function(){for(c=0,d=b.length;c<d;c++)if(f.contains(b[c],this))return!0});var e=this.pushStack("","find",a),g,h,i;for(c=0,d=this.length;c<d;c++){g=e.length,f.find(a,this[c],e);if(c>0)for(h=g;h<e.length;h++)for(i=0;i<g;i++)if(e[i]===e[h]){e.splice(h--,1);break}}return e},has:function(a){var b=f(a);return this.filter(function(){for(var a=0,c=b.length;a<c;a++)if(f.contains(this,b[a]))return!0})},not:function(a){return this.pushStack(W(this,a,!1),"not",a)},filter:function(a){return this.pushStack(W(this,a,!0),"filter",a)},is:function(a){return!!a&&(typeof a=="string"?f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h,i,j={},k=1;if(g&&a.length){for(d=0,e=a.length;d<e;d++)i=a[d],j[i]||(j[i]=T.test(i)?f(i,b||this.context):i);while(g&&g.ownerDocument&&g!==b){for(i in j)h=j[i],(h.jquery?h.index(g)>-1:f(g).is(h))&&c.push({selector:i,elem:g,level:k});g=g.parentNode,k++}}return c}var l=T.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d<e;d++){g=this[d];while(g){if(l?l.index(g)>-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a||typeof a=="string")return f.inArray(this[0],a?f(a):this.parent().children());return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(V(c[0])||V(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c),g=S.call(arguments);O.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!U[a]?f.unique(e):e,(this.length>1||Q.test(d))&&P.test(a)&&(e=e.reverse());return this.pushStack(e,a,g.join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var X=/ jQuery\d+="(?:\d+|null)"/g,Y=/^\s+/,Z=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,$=/<([\w:]+)/,_=/<tbody/i,ba=/<|&#?\w+;/,bb=/<(?:script|object|embed|option|style)/i,bc=/checked\s*(?:[^=]|=\s*.checked.)/i,bd=/\/(java|ecma)script/i,be={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,"",""]};be.optgroup=be.option,be.tbody=be.tfoot=be.colgroup=be.caption=be.thead,be.th=be.td,f.support.htmlSerialize||(be._default=[1,"div<div>","</div>"]),f.fn.extend({text:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.text(a.call(this,b,c.text()))});if(typeof a!="object"&&a!==b)return this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a));return f.text(this)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapInner(a.call(this,b))});return this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){f(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,f(arguments[0]).toArray());return a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this,a,b)})},html:function(a){if(a===b)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(X,""):null;if(typeof a=="string"&&!bb.test(a)&&(f.support.leadingWhitespace||!Y.test(a))&&!be[($.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Z,"<$1></$2>");try{for(var c=0,d=this.length;c<d;c++)this[c].nodeType===1&&(f.cleanData(this[c].getElementsByTagName("*")),this[c].innerHTML=a)}catch(e){this.empty().append(a)}}else f.isFunction(a)?this.each(function(b){var c=f(this);c.html(a.call(this,b,c.html()))}):this.empty().append(a);return this},replaceWith:function(a){if(this[0]&&this[0].parentNode){if(f.isFunction(a))return this.each(function(b){var c=f(this),d=c.html();c.replaceWith(a.call(this,b,d))});typeof a!="string"&&(a=f(a).detach());return this.each(function(){var b=this.nextSibling,c=this.parentNode;f(this).remove(),b?f(b).before(a):f(c).append(a)})}return this.length?this.pushStack(f(f.isFunction(a)?a():a),"replaceWith",a):this},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){var e,g,h,i,j=a[0],k=[];if(!f.support.checkClone&&arguments.length===3&&typeof j=="string"&&bc.test(j))return this.each(function(){f(this).domManip(a,c,d,!0)});if(f.isFunction(j))return this.each(function(e){var g=f(this);a[0]=j.call(this,e,c?g.html():b),g.domManip(a,c,d)});if(this[0]){i=j&&j.parentNode,f.support.parentNode&&i&&i.nodeType===11&&i.childNodes.length===this.length?e={fragment:i}:e=f.buildFragment(a,this,k),h=e.fragment,h.childNodes.length===1?g=h=h.firstChild:g=h.firstChild;if(g){c=c&&f.nodeName(g,"tr");for(var l=0,m=this.length,n=m-1;l<m;l++)d.call(c?bf(this[l],g):this[l],e.cacheable||m>1&&l<n?f.clone(h,!0,!0):h)}k.length&&f.each(k,bl)}return this}}),f.buildFragment=function(a,b,d){var e,g,h,i=b&&b[0]?b[0].ownerDocument||b[0]:c;a.length===1&&typeof a[0]=="string"&&a[0].length<512&&i===c&&a[0].charAt(0)==="<"&&!bb.test(a[0])&&(f.support.checkClone||!bc.test(a[0]))&&(g=!0,h=f.fragments[a[0]],h&&h!==1&&(e=h)),e||(e=i.createDocumentFragment(),f.clean(a,i,e,d)),g&&(f.fragments[a[0]]=h?e:1);return{fragment:e,cacheable:g}},f.fragments={},f.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){f.fn[a]=function(c){var d=[],e=f(c),g=this.length===1&&this[0].parentNode;if(g&&g.nodeType===11&&g.childNodes.length===1&&e.length===1){e[b](this[0]);return this}for(var h=0,i=e.length;h<i;h++){var j=(h>0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d=a.cloneNode(!0),e,g,h;if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bh(a,d),e=bi(a),g=bi(d);for(h=0;e[h];++h)bh(e[h],g[h])}if(b){bg(a,d);if(c){e=bi(a),g=bi(d);for(h=0;e[h];++h)bg(e[h],g[h])}}return d},clean:function(a,b,d,e){var g;b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);var h=[];for(var i=0,j;(j=a[i])!=null;i++){typeof j=="number"&&(j+="");if(!j)continue;if(typeof j=="string")if(!ba.test(j))j=b.createTextNode(j);else{j=j.replace(Z,"<$1></$2>");var k=($.exec(j)||["",""])[1].toLowerCase(),l=be[k]||be._default,m=l[0],n=b.createElement("div");n.innerHTML=l[1]+j+l[2];while(m--)n=n.lastChild;if(!f.support.tbody){var o=_.test(j),p=k==="table"&&!o?n.firstChild&&n.firstChild.childNodes:l[1]==="<table>"&&!o?n.childNodes:[];for(var q=p.length-1;q>=0;--q)f.nodeName(p[q],"tbody")&&!p[q].childNodes.length&&p[q].parentNode.removeChild(p[q])}!f.support.leadingWhitespace&&Y.test(j)&&n.insertBefore(b.createTextNode(Y.exec(j)[0]),n.firstChild),j=n.childNodes}var r;if(!f.support.appendChecked)if(j[0]&&typeof (r=j.length)=="number")for(i=0;i<r;i++)bk(j[i]);else bk(j);j.nodeType?h.push(j):h=f.merge(h,j)}if(d){g=function(a){return!a.type||bd.test(a.type)};for(i=0;h[i];i++)if(e&&f.nodeName(h[i],"script")&&(!h[i].type||h[i].type.toLowerCase()==="text/javascript"))e.push(h[i].parentNode?h[i].parentNode.removeChild(h[i]):h[i]);else{if(h[i].nodeType===1){var s=f.grep(h[i].getElementsByTagName("script"),g);h.splice.apply(h,[i+1,0].concat(s))}d.appendChild(h[i])}}return h},cleanData:function(a){var b,c,d=f.cache,e=f.expando,g=f.event.special,h=f.support.deleteExpando;for(var i=0,j;(j=a[i])!=null;i++){if(j.nodeName&&f.noData[j.nodeName.toLowerCase()])continue;c=j[f.expando];if(c){b=d[c]&&d[c][e];if(b&&b.events){for(var k in b.events)g[k]?f.event.remove(j,k):f.removeEvent(j,k,b.handle);b.handle&&(b.handle.elem=null)}h?delete j[f.expando]:j.removeAttribute&&j.removeAttribute(f.expando),delete d[c]}}}});var bm=/alpha\([^)]*\)/i,bn=/opacity=([^)]*)/,bo=/-([a-z])/ig,bp=/([A-Z]|^ms)/g,bq=/^-?\d+(?:px)?$/i,br=/^-?\d/,bs=/^[+\-]=/,bt=/[^+\-\.\de]+/g,bu={position:"absolute",visibility:"hidden",display:"block"},bv=["Left","Right"],bw=["Top","Bottom"],bx,by,bz,bA=function(a,b){return b.toUpperCase()};f.fn.css=function(a,c){if(arguments.length===2&&c===b)return this;return f.access(this,a,c,!0,function(a,c,d){return d!==b?f.style(a,c,d):f.css(a,c)})},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=bx(a,"opacity","opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{zIndex:!0,fontWeight:!0,opacity:!0,zoom:!0,lineHeight:!0,widows:!0,orphans:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!!a&&a.nodeType!==3&&a.nodeType!==8&&!!a.style){var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b){if(k&&"get"in k&&(g=k.get(a,!1,e))!==b)return g;return j[c]}h=typeof d;if(h==="number"&&isNaN(d)||d==null)return;h==="string"&&bs.test(d)&&(d=+d.replace(bt,"")+parseFloat(f.css(a,c))),h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(bx)return bx(a,c)},swap:function(a,b,c){var d={};for(var e in b)d[e]=a.style[e],a.style[e]=b[e];c.call(a);for(e in b)a.style[e]=d[e]},camelCase:function(a){return a.replace(bo,bA)}}),f.curCSS=f.css,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){var e;if(c){a.offsetWidth!==0?e=bB(a,b,d):f.swap(a,bu,function(){e=bB(a,b,d)});if(e<=0){e=bx(a,b,b),e==="0px"&&bz&&(e=bz(a,b,b));if(e!=null)return e===""||e==="auto"?"0px":e}if(e<0||e==null){e=a.style[b];return e===""||e==="auto"?"0px":e}return typeof e=="string"?e:e+"px"}},set:function(a,b){if(!bq.test(b))return b;b=parseFloat(b);if(b>=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bn.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle;c.zoom=1;var e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.filter=bm.test(g)?g.replace(bm,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){var c;f.swap(a,{display:"inline-block"},function(){b?c=bx(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(by=function(a,c){var d,e,g;c=c.replace(bp,"-$1").toLowerCase();if(!(e=a.ownerDocument.defaultView))return b;if(g=e.getComputedStyle(a,null))d=g.getPropertyValue(c),d===""&&!f.contains(a.ownerDocument.documentElement,a)&&(d=f.style(a,c));return d}),c.documentElement.currentStyle&&(bz=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bq.test(d)&&br.test(d)&&(c=f.left,e&&(a.runtimeStyle.left=a.currentStyle.left),f.left=b==="fontSize"?"1em":d||0,d=f.pixelLeft+"px",f.left=c,e&&(a.runtimeStyle.left=e));return d===""?"auto":d}),bx=by||bz,f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bC=/%20/g,bD=/\[\]$/,bE=/\r?\n/g,bF=/#.*$/,bG=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bH=/^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bI=/^(?:about|app|app\-storage|.+\-extension|file|widget):$/,bJ=/^(?:GET|HEAD)$/,bK=/^\/\//,bL=/\?/,bM=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,bN=/^(?:select|textarea)/i,bO=/\s+/,bP=/([?&])_=[^&]*/,bQ=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bR=f.fn.load,bS={},bT={},bU,bV;try{bU=e.href}catch(bW){bU=c.createElement("a"),bU.href="",bU=bU.href}bV=bQ.exec(bU.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bR)return bR.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("<div>").append(c.replace(bM,"")).find(g):c)),d&&i.each(d,[c,b,a])}});return this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||bN.test(this.nodeName)||bH.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(bE,"\r\n")}}):{name:b.name,value:c.replace(bE,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.bind(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){f.isFunction(d)&&(g=g||e,e=d,d=b);return f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){b?f.extend(!0,a,f.ajaxSettings,b):(b=a,a=f.extend(!0,f.ajaxSettings,b));for(var c in{context:1,url:1})c in b?a[c]=b[c]:c in f.ajaxSettings&&(a[c]=f.ajaxSettings[c]);return a},ajaxSettings:{url:bU,isLocal:bI.test(bV[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","*":"*/*"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML}},ajaxPrefilter:bX(bS),ajaxTransport:bX(bT),ajax:function(a,c){function w(a,c,l,m){if(s!==2){s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a?4:0;var o,r,u,w=l?b$(d,v,l):b,x,y;if(a>=200&&a<300||a===304){if(d.ifModified){if(x=v.getResponseHeader("Last-Modified"))f.lastModified[k]=x;if(y=v.getResponseHeader("Etag"))f.etag[k]=y}if(a===304)c="notmodified",o=!0;else try{r=b_(d,w),c="success",o=!0}catch(z){c="parsererror",u=z}}else{u=c;if(!c||a)c="error",a<0&&(a=0)}v.status=a,v.statusText=c,o?h.resolveWith(e,[r,c,v]):h.rejectWith(e,[v,c,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,c]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f._Deferred(),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=bG.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){s||(d.mimeType=a);return this},abort:function(a){a=a||"abort",p&&p.abort(a),w(0,a);return this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.done,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(bF,"").replace(bK,bV[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bO),d.crossDomain==null&&(r=bQ.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bV[1]&&r[2]==bV[2]&&(r[3]||(r[1]==="http:"?80:443))==(bV[3]||(bV[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bY(bS,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bJ.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bL.test(d.url)?"&":"?")+d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bP,"$1_="+x);d.url=y+(y===d.url?(bL.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", */*; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(d.beforeSend&&(d.beforeSend.call(e,v,d)===!1||s===2)){v.abort();return!1}for(u in{success:1,error:1,complete:1})v[u](d[u]);p=bY(bT,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){status<2?w(-1,z):f.error(z)}}return v},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)bZ(g,a[g],c,e);return d.join("&").replace(bC,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var ca=f.now(),cb=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+ca++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=b.contentType==="application/x-www-form-urlencoded"&&typeof b.data=="string";if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(cb.test(b.url)||e&&cb.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";b.jsonp!==!1&&(j=j.replace(cb,l),b.url===j&&(e&&(k=k.replace(cb,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){g||f.error(h+" was not called");return g[0]},b.dataTypes[0]="json";return"script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){f.globalEval(a);return a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var cc=a.ActiveXObject?function(){for(var a in ce)ce[a](0,1)}:!1,cd=0,ce;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&cf()||cg()}:cf,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,cc&&delete ce[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n),m.text=h.responseText;try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++cd,cc&&(ce||(ce={},f(a).unload(cc)),ce[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var ch={},ci,cj,ck=/^(?:toggle|show|hide)$/,cl=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cm,cn=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],co,cp=a.webkitRequestAnimationFrame||a.mozRequestAnimationFrame||a.oRequestAnimationFrame;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cs("show",3),a,b,c);for(var g=0,h=this.length;g<h;g++)d=this[g],d.style&&(e=d.style.display,!f._data(d,"olddisplay")&&e==="none"&&(e=d.style.display=""),e===""&&f.css(d,"display")==="none"&&f._data(d,"olddisplay",ct(d.nodeName)));for(g=0;g<h;g++){d=this[g];if(d.style){e=d.style.display;if(e===""||e==="none")d.style.display=f._data(d,"olddisplay")||""}}return this},hide:function(a,b,c){if(a||a===0)return this.animate(cs("hide",3),a,b,c);for(var d=0,e=this.length;d<e;d++)if(this[d].style){var g=f.css(this[d],"display");g!=="none"&&!f._data(this[d],"olddisplay")&&f._data(this[d],"olddisplay",g)}for(d=0;d<e;d++)this[d].style&&(this[d].style.display="none");return this},_toggle:f.fn.toggle,toggle:function(a,b,c){var d=typeof a=="boolean";f.isFunction(a)&&f.isFunction(b)?this._toggle.apply(this,arguments):a==null||d?this.each(function(){var b=d?a:f(this).is(":hidden");f(this)[b?"show":"hide"]()}):this.animate(cs("toggle",3),a,b,c);return this},fadeTo:function(a,b,c,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=f.speed(b,c,d);if(f.isEmptyObject(a))return this.each(e.complete,[!1]);return this[e.queue===!1?"each":"queue"](function(){e.queue===!1&&f._mark(this);var b=f.extend({},e),c=this.nodeType===1,d=c&&f(this).is(":hidden"),g,h,i,j,k,l,m,n,o;b.animatedProperties={};for(i in a){g=f.camelCase(i),i!==g&&(a[g]=a[i],delete a[i]),h=a[g];if(h==="hide"&&d||h==="show"&&!d)return b.complete.call(this);c&&(g==="height"||g==="width")&&(b.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY],f.css(this,"display")==="inline"&&f.css(this,"float")==="none"&&(f.support.inlineBlockNeedsLayout?(j=ct(this.nodeName),j==="inline"?this.style.display="inline-block":(this.style.display="inline",this.style.zoom=1)):this.style.display="inline-block")),b.animatedProperties[g]=f.isArray(h)?h[1]:b.specialEasing&&b.specialEasing[g]||b.easing||"swing"}b.overflow!=null&&(this.style.overflow="hidden");for(i in a)k=new f.fx(this,b,i),h=a[i],ck.test(h)?k[h==="toggle"?d?"show":"hide":h]():(l=cl.exec(h),m=k.cur(),l?(n=parseFloat(l[2]),o=l[3]||(f.cssNumber[g]?"":"px"),o!=="px"&&(f.style(this,i,(n||1)+o),m=(n||1)/k.cur()*m,f.style(this,i,m+o)),l[1]&&(n=(l[1]==="-="?-1:1)*n+m),k.custom(m,n,o)):k.custom(m,h,""));return!0})},stop:function(a,b){a&&this.queue([]),this.each(function(){var a=f.timers,c=a.length;b||f._unmark(!0,this);while(c--)a[c].elem===this&&(b&&a[c](!0),a.splice(c,1))}),b||this.dequeue();return this}}),f.each({slideDown:cs("show",1),slideUp:cs("hide",1),slideToggle:cs("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){f.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),f.extend({speed:function(a,b,c){var d=a&&typeof a=="object"?f.extend({},a):{complete:c||!c&&b||f.isFunction(a)&&a,duration:a,easing:c&&b||b&&!f.isFunction(b)&&b};d.duration=f.fx.off?0:typeof d.duration=="number"?d.duration:d.duration in f.fx.speeds?f.fx.speeds[d.duration]:f.fx.speeds._default,d.old=d.complete,d.complete=function(a){d.queue!==!1?f.dequeue(this):a!==!1&&f._unmark(this),f.isFunction(d.old)&&d.old.call(this)};return d},easing:{linear:function(a,b,c,d){return c+d*a},swing:function(a,b,c,d){return(-Math.cos(a*Math.PI)/2+.5)*d+c}},timers:[],fx:function(a,b,c){this.options=b,this.elem=a,this.prop=c,b.orig=b.orig||{}}}),f.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this),(f.fx.step[this.prop]||f.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 a,b=f.css(this.elem,this.prop);return isNaN(a=parseFloat(b))?!b||b==="auto"?0:b:a},custom:function(a,b,c){function h(a){return d.step(a)}var d=this,e=f.fx,g;this.startTime=co||cq(),this.start=a,this.end=b,this.unit=c||this.unit||(f.cssNumber[this.prop]?"":"px"),this.now=this.start,this.pos=this.state=0,h.elem=this.elem,h()&&f.timers.push(h)&&!cm&&(cp?(cm=1,g=function(){cm&&(cp(g),e.tick())},cp(g)):cm=setInterval(e.tick,e.interval))},show:function(){this.options.orig[this.prop]=f.style(this.elem,this.prop),this.options.show=!0,this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur()),f(this.elem).show()},hide:function(){this.options.orig[this.prop]=f.style(this.elem,this.prop),this.options.hide=!0,this.custom(this.cur(),0)},step:function(a){var b=co||cq(),c=!0,d=this.elem,e=this.options,g,h;if(a||b>=e.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),e.animatedProperties[this.prop]=!0;for(g in e.animatedProperties)e.animatedProperties[g]!==!0&&(c=!1);if(c){e.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){d.style["overflow"+b]=e.overflow[a]}),e.hide&&f(d).hide();if(e.hide||e.show)for(var i in e.animatedProperties)f.style(d,i,e.orig[i]);e.complete.call(d)}return!1}e.duration==Infinity?this.now=b:(h=b-this.startTime,this.state=h/e.duration,this.pos=f.easing[e.animatedProperties[this.prop]](this.state,h,0,1,e.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a=f.timers,b=a.length;while(b--)a[b]()||a.splice(b,1);a.length||f.fx.stop()},interval:13,stop:function(){clearInterval(cm),cm=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){f.style(a.elem,"opacity",a.now)},_default:function(a){a.elem.style&&a.elem.style[a.prop]!=null?a.elem.style[a.prop]=(a.prop==="width"||a.prop==="height"?Math.max(0,a.now):a.now)+a.unit:a.elem[a.prop]=a.now}}}),f.expr&&f.expr.filters&&(f.expr.filters.animated=function(a){return f.grep(f.timers,function(b){return a===b.elem}).length});var cu=/^t(?:able|d|h)$/i,cv=/^(?:body|html)$/i;"getBoundingClientRect"in c.documentElement?f.fn.offset=function(a){var b=this[0],c;if(a)return this.each(function(b){f.offset.setOffset(this,a,b)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return f.offset.bodyOffset(b);try{c=b.getBoundingClientRect()}catch(d){}var e=b.ownerDocument,g=e.documentElement;if(!c||!f.contains(g,b))return c?{top:c.top,left:c.left}:{top:0,left:0};var h=e.body,i=cw(e),j=g.clientTop||h.clientTop||0,k=g.clientLeft||h.clientLeft||0,l=i.pageYOffset||f.support.boxModel&&g.scrollTop||h.scrollTop,m=i.pageXOffset||f.support.boxModel&&g.scrollLeft||h.scrollLeft,n=c.top+l-j,o=c.left+m-k;return{top:n,left:o}}:f.fn.offset=function(a){var b=this[0];if(a)return this.each(function(b){f.offset.setOffset(this,a,b)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return f.offset.bodyOffset(b);f.offset.initialize();var c,d=b.offsetParent,e=b,g=b.ownerDocument,h=g.documentElement,i=g.body,j=g.defaultView,k=j?j.getComputedStyle(b,null):b.currentStyle,l=b.offsetTop,m=b.offsetLeft;while((b=b.parentNode)&&b!==i&&b!==h){if(f.offset.supportsFixedPosition&&k.position==="fixed")break;c=j?j.getComputedStyle(b,null):b.currentStyle,l-=b.scrollTop,m-=b.scrollLeft,b===d&&(l+=b.offsetTop,m+=b.offsetLeft,f.offset.doesNotAddBorder&&(!f.offset.doesAddBorderForTableAndCells||!cu.test(b.nodeName))&&(l+=parseFloat(c.borderTopWidth)||0,m+=parseFloat(c.borderLeftWidth)||0),e=d,d=b.offsetParent),f.offset.subtractsBorderForOverflowNotVisible&&c.overflow!=="visible"&&(l+=parseFloat(c.borderTopWidth)||0,m+=parseFloat(c.borderLeftWidth)||0),k=c}if(k.position==="relative"||k.position==="static")l+=i.offsetTop,m+=i.offsetLeft;f.offset.supportsFixedPosition&&k.position==="fixed"&&(l+=Math.max(h.scrollTop,i.scrollTop),m+=Math.max(h.scrollLeft,i.scrollLeft));return{top:l,left:m}},f.offset={initialize:function(){var a=c.body,b=c.createElement("div"),d,e,g,h,i=parseFloat(f.css(a,"marginTop"))||0,j="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";f.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"}),b.innerHTML=j,a.insertBefore(b,a.firstChild),d=b.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,this.doesNotAddBorder=e.offsetTop!==5,this.doesAddBorderForTableAndCells=h.offsetTop===5,e.style.position="fixed",e.style.top="20px",this.supportsFixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",this.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==i,a.removeChild(b),f.offset.initialize=f.noop},bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;f.offset.initialize(),f.offset.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0);return{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=cv.test(b[0].nodeName)?{top:0,left:0}:b.offset();c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0;return{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!cv.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each(["Left","Top"],function(a,c){var d="scroll"+c;f.fn[d]=function(c){var e,g;if(c===b){e=this[0];if(!e)return null;g=cw(e);return g?"pageXOffset"in g?g[a?"pageYOffset":"pageXOffset"]:f.support.boxModel&&g.document.documentElement[d]||g.document.body[d]:e[d]}return this.each(function(){g=cw(this),g?g.scrollTo(a?f(g).scrollLeft():c,a?c:f(g).scrollTop()):this[d]=c})}}),f.each(["Height","Width"],function(a,c){var d=c.toLowerCase();f.fn["inner"+c]=function(){return this[0]?parseFloat(f.css(this[0],d,"padding")):null},f.fn["outer"+c]=function(a){return this[0]?parseFloat(f.css(this[0],d,a?"margin":"border")):null},f.fn[d]=function(a){var e=this[0];if(!e)return a==null?null:this;if(f.isFunction(a))return this.each(function(b){var c=f(this);c[d](a.call(this,b,c[d]()))});if(f.isWindow(e)){var g=e.document.documentElement["client"+c];return e.document.compatMode==="CSS1Compat"&&g||e.document.body["client"+c]||g}if(e.nodeType===9)return Math.max(e.documentElement["client"+c],e.body["scroll"+c],e.documentElement["scroll"+c],e.body["offset"+c],e.documentElement["offset"+c]);if(a===b){var h=f.css(e,d),i=parseFloat(h);return f.isNaN(i)?h:i}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.ramoonus.nl
4
  Tags: jquery
5
  Requires at least: 3.0.0
6
  Tested up to: 3.2
7
- Stable tag: 1.6.0
8
 
9
  This plugin should only be used for development purposes, this plugin updates jQuery to the latest (stable) version.
10
 
@@ -12,7 +12,7 @@ This plugin should only be used for development purposes, this plugin updates jQ
12
  This plugin should only be used for development purposes, this plugin updates jQuery to the latest (stable) version.
13
 
14
  == Installation ==
15
- 1. Upload `jquery-updater.php` to the `/wp-content/plugins/` directory
16
  2. Activate the plugin through the 'Plugins' menu in WordPress
17
 
18
  == Frequently Asked Questions ==
@@ -25,6 +25,9 @@ Its recommended to flush the cache after upgrading.
25
  Not relevant.
26
 
27
  == Changelog ==
 
 
 
28
  = 1.6.0.1 =
29
  * jQuery 1.6.1 rc 1 (fixes a known WP bug untill 3.2 is released)
30
 
4
  Tags: jquery
5
  Requires at least: 3.0.0
6
  Tested up to: 3.2
7
+ Stable tag: 1.6.1
8
 
9
  This plugin should only be used for development purposes, this plugin updates jQuery to the latest (stable) version.
10
 
12
  This plugin should only be used for development purposes, this plugin updates jQuery to the latest (stable) version.
13
 
14
  == Installation ==
15
+ 1. Upload `jquery-updater/` to the `/wp-content/plugins/` directory
16
  2. Activate the plugin through the 'Plugins' menu in WordPress
17
 
18
  == Frequently Asked Questions ==
25
  Not relevant.
26
 
27
  == Changelog ==
28
+ = 1.6.1 =
29
+ * Updated jQuery to 1.6.1
30
+
31
  = 1.6.0.1 =
32
  * jQuery 1.6.1 rc 1 (fixes a known WP bug untill 3.2 is released)
33