// ./jquery-1.7.1.min.js /*! jQuery v1.7.1 jquery.com | jquery.org/license */ (function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cv(a){if(!ck[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){cl||(cl=c.createElement("iframe"),cl.frameBorder=cl.width=cl.height=0),b.appendChild(cl);if(!cm||!cl.createElement)cm=(cl.contentWindow||cl.contentDocument).document,cm.write((c.compatMode==="CSS1Compat"?"":"")+""),cm.close();d=cm.createElement(a),cm.body.appendChild(d),e=f.css(d,"display"),b.removeChild(cl)}ck[a]=e}return ck[a]}function cu(a,b){var c={};f.each(cq.concat.apply([],cq.slice(0,b)),function(){c[this]=a});return c}function ct(){cr=b}function cs(){setTimeout(ct,0);return cr=f.now()}function cj(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ci(){try{return new a.XMLHttpRequest}catch(b){}}function cc(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;g0){if(c!=="border")for(;g=0===c})}function S(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function K(){return!0}function J(){return!1}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?parseFloat(d):j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,n=/^[\],:{}\s]*$/,o=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,p=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,q=/(?:^|:|,)(?:\s*\[)+/g,r=/(webkit)[ \/]([\w.]+)/,s=/(opera)(?:.*version)?[ \/]([\w.]+)/,t=/(msie) ([\w.]+)/,u=/(mozilla)(?:.*? rv:([\w.]+))?/,v=/-([a-z]|[0-9])/ig,w=/^-ms-/,x=function(a,b){return(b+"").toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};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=m.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.7.1",length:0,size:function(){return this.length},toArray:function(){return F.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)?E.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(),A.add(a);return this},eq:function(a){a=+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(F.apply(this,arguments),"slice",F.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:E,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(;j0)return;A.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").off("ready")}},bindReady:function(){if(!A){A=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}}},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},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||D.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw new Error(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(n.test(b.replace(o,"@").replace(p,"]").replace(q,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,"ms-").replace(v,x)},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(;g0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i1?i.call(arguments,0):b,j.notifyWith(k,e)}}function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}var b=i.call(arguments,0),c=0,d=b.length,e=Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c
a",d=q.getElementsByTagName("*"),e=q.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=q.getElementsByTagName("input")[0],b={leadingWhitespace:q.firstChild.nodeType===3,tbody:!q.getElementsByTagName("tbody").length,htmlSerialize:!!q.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:i.value==="on",optSelected:h.selected,getSetAttribute:q.className!=="t",enctype:!!c.createElement("form").enctype,html5Clone:c.createElement("nav").cloneNode(!0).outerHTML!=="<:nav>",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,b.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,b.optDisabled=!h.disabled;try{delete q.test}catch(s){b.deleteExpando=!1}!q.addEventListener&&q.attachEvent&&q.fireEvent&&(q.attachEvent("onclick",function(){b.noCloneEvent=!1}),q.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),b.radioValue=i.value==="t",i.setAttribute("checked","checked"),q.appendChild(i),k=c.createDocumentFragment(),k.appendChild(q.lastChild),b.checkClone=k.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=i.checked,k.removeChild(i),k.appendChild(q),q.innerHTML="",a.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",q.style.width="2px",q.appendChild(j),b.reliableMarginRight=(parseInt((a.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0);if(q.attachEvent)for(o in{submit:1,change:1,focusin:1})n="on"+o,p=n in q,p||(q.setAttribute(n,"return;"),p=typeof q[n]=="function"),b[o+"Bubbles"]=p;k.removeChild(q),k=g=h=j=q=i=null,f(function(){var a,d,e,g,h,i,j,k,m,n,o,r=c.getElementsByTagName("body")[0];!r||(j=1,k="position:absolute;top:0;left:0;width:1px;height:1px;margin:0;",m="visibility:hidden;border:0;",n="style='"+k+"border:5px solid #000;padding:0;'",o="
"+""+"
",a=c.createElement("div"),a.style.cssText=m+"width:0;height:0;position:static;top:0;margin-top:"+j+"px",r.insertBefore(a,r.firstChild),q=c.createElement("div"),a.appendChild(q),q.innerHTML="
t
",l=q.getElementsByTagName("td"),p=l[0].offsetHeight===0,l[0].style.display="",l[1].style.display="none",b.reliableHiddenOffsets=p&&l[0].offsetHeight===0,q.innerHTML="",q.style.width=q.style.paddingLeft="1px",f.boxModel=b.boxModel=q.offsetWidth===2,typeof q.style.zoom!="undefined"&&(q.style.display="inline",q.style.zoom=1,b.inlineBlockNeedsLayout=q.offsetWidth===2,q.style.display="",q.innerHTML="
",b.shrinkWrapBlocks=q.offsetWidth!==2),q.style.cssText=k+m,q.innerHTML=o,d=q.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,i={doesNotAddBorder:e.offsetTop!==5,doesAddBorderForTableAndCells:h.offsetTop===5},e.style.position="fixed",e.style.top="20px",i.fixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",i.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,i.doesNotIncludeMarginInBodyOffset=r.offsetTop!==j,r.removeChild(a),q=a=null,f.extend(b,i))});return b}();var j=/^(?:\{.*\}|\[.*\])$/,k=/([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&&!m(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[j]:a[j]&&j,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[j]=n=++f.uuid:n=j),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d);if(o&&!h[c])return g.events;k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h;return i}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[h]:h;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)||(b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,g=b.length;e-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];{if(!!arguments.length){e=f.isFunction(a);return this.each(function(d){var g=f(this),h;if(this.nodeType===1){e?h=a.call(this,d,g.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}})}if(g){c=f.valHooks[g.nodeName.toLowerCase()]||f.valHooks[g.type];if(c&&"get"in c&&(d=c.get(g,"value"))!==b)return d;d=g.value;return typeof d=="string"?d.replace(q,""):d==null?"":d}}}}),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,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;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},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!!a&&j!==3&&j!==8&&j!==2){if(e&&c in f.attrFn)return f(a)[c](d);if(typeof a.getAttribute=="undefined")return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return}if(h&&"set"in h&&i&&(g=h.set(a,d,c))!==b)return g;a.setAttribute(c,""+d);return d}if(h&&"get"in h&&i&&(g=h.get(a,c))!==null)return g;g=a.getAttribute(c);return g===null?b:g}},removeAttr:function(a,b){var c,d,e,g,h=0;if(b&&a.nodeType===1){d=b.toLowerCase().split(p),g=d.length;for(;h=0}})});var z=/^(?:textarea|input|select)$/i,A=/^([^\.]*)?(?:\.(.+))?$/,B=/\bhover(\.\S+)?\b/,C=/^key/,D=/^(?:mouse|contextmenu)|click/,E=/^(?:focusinfocus|focusoutblur)$/,F=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,G=function(a){var b=F.exec(a);b&&(b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)"));return b},H=function(a,b){var c=a.attributes||{};return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||(c.id||{}).value===b[2])&&(!b[3]||b[3].test((c["class"]||{}).value))},I=function(a){return f.event.special.hover?a:a.replace(B,"mouseenter$1 mouseleave$1")}; f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.dispatch.apply(i.elem,arguments):b},i.elem=a),c=f.trim(I(c)).split(" ");for(k=0;k=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"";if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,m=E.test(s+h)?e:e.parentNode,n=null;for(;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;le&&i.push({elem:this,matches:d.slice(e)});for(j=0;j0?this.on(b,null,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),C.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),D.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function x(a,b,c,e,f,g){for(var h=0,i=e.length;h0){k=j;break}}j=j[a]}e[h]=k}}}function w(a,b,c,e,f,g){for(var h=0,i=e.length;h+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){i=!1;return 0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length===1&&(w[0]==="~"||w[0]==="+")&&d.parentNode?d.parentNode:d,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);l&&(m(l,h,e,f),m.uniqueSort(e));return e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.test(b)){b=b.toLowerCase();for(;e=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.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]&&m.error(a[0]);a[0]=e++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),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]=m(b[3],null,null,c);else{var g=m.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(o.match.POS.test(b[0])||o.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!!m(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 bc[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=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||!!a.nodeName&&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=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null: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=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));var s=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(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.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:[]}},o.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&&(o.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.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[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}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.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 m(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="
";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h0)for(h=g;h=0: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=1;while(g&&g.ownerDocument&&g!==b){for(d=0;d-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)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));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(S(c[0])||S(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);L.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!R[a]?f.unique(e):e,(this.length>1||N.test(d))&&M.test(a)&&(e=e.reverse());return this.pushStack(e,a,P.call(arguments).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 V="abbr|article|aside|audio|canvas|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/",""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]},bh=U(c);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
","
"]),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){var b=f.isFunction(a);return this.each(function(c){f(this).wrapAll(b?a.call(this,c):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.clean(arguments);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.clean(arguments));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(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!bg[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1>");try{for(var c=0,d=this.length;c1&&l0?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,e,g,h=f.support.html5Clone||!bc.test("<"+a.nodeName)?a.cloneNode(!0):bo(a);if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bk(a,h),d=bl(a),e=bl(h);for(g=0;d[g];++g)e[g]&&bk(d[g],e[g])}if(b){bj(a,h);if(c){d=bl(a),e=bl(h);for(g=0;d[g];++g)bj(d[g],e[g])}}d=e=null;return h},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=[],i;for(var j=0,k;(k=a[j])!=null;j++){typeof k=="number"&&(k+="");if(!k)continue;if(typeof k=="string")if(!_.test(k))k=b.createTextNode(k);else{k=k.replace(Y,"<$1>");var l=(Z.exec(k)||["",""])[1].toLowerCase(),m=bg[l]||bg._default,n=m[0],o=b.createElement("div");b===c?bh.appendChild(o):U(b).appendChild(o),o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=$.test(k),q=l==="table"&&!p?o.firstChild&&o.firstChild.childNodes:m[1]===""&&!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&&X.test(k)&&o.insertBefore(b.createTextNode(X.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=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return br.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,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bq,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bq.test(g)?g.replace(bq,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,b){var c,d,e;b=b.replace(bs,"-$1").toLowerCase(),(d=a.ownerDocument.defaultView)&&(e=d.getComputedStyle(a,null))&&(c=e.getPropertyValue(b),c===""&&!f.contains(a.ownerDocument.documentElement,a)&&(c=f.style(a,b)));return c}),c.documentElement.currentStyle&&(bB=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;f===null&&g&&(e=g[b])&&(f=e),!bt.test(f)&&bu.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f||0,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d));return f===""?"auto":f}),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&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bD=/%20/g,bE=/\[\]$/,bF=/\r?\n/g,bG=/#.*$/,bH=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bI=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bJ=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bK=/^(?:GET|HEAD)$/,bL=/^\/\//,bM=/\?/,bN=/)<[^<]*)*<\/script>/gi,bO=/^(?:select|textarea)/i,bP=/\s+/,bQ=/([?&])_=[^&]*/,bR=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bS=f.fn.load,bT={},bU={},bV,bW,bX=["*/"]+["*"];try{bV=e.href}catch(bY){bV=c.createElement("a"),bV.href="",bV=bV.href}bW=bR.exec(bV.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bS)return bS.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("
").append(c.replace(bN,"")).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||bO.test(this.nodeName)||bI.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(bF,"\r\n")}}):{name:b.name,value:c.replace(bF,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.on(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?b_(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),b_(a,b);return a},ajaxSettings:{url:bV,isLocal:bJ.test(bW[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","*":bX},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},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bZ(bT),ajaxTransport:bZ(bU),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>0?4:0;var o,r,u,w=c,x=l?cb(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=cc(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),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.Callbacks("once memory"),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=bH.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.add,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(bG,"").replace(bL,bW[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bP),d.crossDomain==null&&(r=bR.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bW[1]&&r[2]==bW[2]&&(r[3]||(r[1]==="http:"?80:443))==(bW[3]||(bW[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),b$(bT,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bK.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bM.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bQ,"$1_="+x);d.url=y+(y===d.url?(bM.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]!=="*"?", "+bX+"; 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$(bU,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){if(s<2)w(-1,z);else throw 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)ca(g,a[g],c,e);return d.join("&").replace(bD,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cd=f.now(),ce=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cd++}}),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&&(ce.test(b.url)||e&&ce.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(ce,l),b.url===j&&(e&&(k=k.replace(ce,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 cf=a.ActiveXObject?function(){for(var a in ch)ch[a](0,1)}:!1,cg=0,ch;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ci()||cj()}:ci,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,cf&&delete ch[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=++cg,cf&&(ch||(ch={},f(a).unload(cf)),ch[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var ck={},cl,cm,cn=/^(?:toggle|show|hide)$/,co=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cp,cq=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cr;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=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c-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(){var a=this[0];return a?a.style?parseFloat(f.css(a,d,"padding")):this[d]():null},f.fn["outer"+c]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,d,a?"margin":"border")):this[d]():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],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["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 i=f.css(e,d),j=parseFloat(i);return f.isNumeric(j)?j:i}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return f})})(window); // ./jquery.jgrowl_minimized.js /** * jGrowl 1.2.5 * * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses. * * Written by Stan Lemon * Last updated: 2009.12.15 * * jGrowl is a jQuery plugin implementing unobtrusive userland notifications. These * notifications function similarly to the Growl Framework available for * Mac OS X (http://growl.info). * * To Do: * - Move library settings to containers and allow them to be changed per container * * Changes in 1.2.5 * - Changed wrapper jGrowl's options usage to "o" instead of $.jGrowl.defaults * - Added themeState option to control 'highlight' or 'error' for jQuery UI * - Ammended some CSS to provide default positioning for nested usage. * - Changed some CSS to be prefixed with jGrowl- to prevent namespacing issues * - Added two new options - openDuration and closeDuration to allow * better control of notification open and close speeds, respectively * Patch contributed by Jesse Vincet. * - Added afterOpen callback. Patch contributed by Russel Branca. * * Changes in 1.2.4 * - Fixed IE bug with the close-all button * - Fixed IE bug with the filter CSS attribute (special thanks to gotwic) * - Update IE opacity CSS * - Changed font sizes to use "em", and only set the base style * * Changes in 1.2.3 * - The callbacks no longer use the container as context, instead they use the actual notification * - The callbacks now receive the container as a parameter after the options parameter * - beforeOpen and beforeClose now check the return value, if it's false - the notification does * not continue. The open callback will also halt execution if it returns false. * - Fixed bug where containers would get confused * - Expanded the pause functionality to pause an entire container. * * Changes in 1.2.2 * - Notification can now be theme rolled for jQuery UI, special thanks to Jeff Chan! * * Changes in 1.2.1 * - Fixed instance where the interval would fire the close method multiple times. * - Added CSS to hide from print media * - Fixed issue with closer button when div { position: relative } is set * - Fixed leaking issue with multiple containers. Special thanks to Matthew Hanlon! * * Changes in 1.2.0 * - Added message pooling to limit the number of messages appearing at a given time. * - Closing a notification is now bound to the notification object and triggered by the close button. * * Changes in 1.1.2 * - Added iPhone styled example * - Fixed possible IE7 bug when determining if the ie6 class shoudl be applied. * - Added template for the close button, so that it's content could be customized. * * Changes in 1.1.1 * - Fixed CSS styling bug for ie6 caused by a mispelling * - Changes height restriction on default notifications to min-height * - Added skinned examples using a variety of images * - Added the ability to customize the content of the [close all] box * - Added jTweet, an example of using jGrowl + Twitter * * Changes in 1.1.0 * - Multiple container and instances. * - Standard $.jGrowl() now wraps $.fn.jGrowl() by first establishing a generic jGrowl container. * - Instance methods of a jGrowl container can be called by $.fn.jGrowl(methodName) * - Added glue preferenced, which allows notifications to be inserted before or after nodes in the container * - Added new log callback which is called before anything is done for the notification * - Corner's attribute are now applied on an individual notification basis. * * Changes in 1.0.4 * - Various CSS fixes so that jGrowl renders correctly in IE6. * * Changes in 1.0.3 * - Fixed bug with options persisting across notifications * - Fixed theme application bug * - Simplified some selectors and manipulations. * - Added beforeOpen and beforeClose callbacks * - Reorganized some lines of code to be more readable * - Removed unnecessary this.defaults context * - If corners plugin is present, it's now customizable. * - Customizable open animation. * - Customizable close animation. * - Customizable animation easing. * - Added customizable positioning (top-left, top-right, bottom-left, bottom-right, center) * * Changes in 1.0.2 * - All CSS styling is now external. * - Added a theme parameter which specifies a secondary class for styling, such * that notifications can be customized in appearance on a per message basis. * - Notification life span is now customizable on a per message basis. * - Added the ability to disable the global closer, enabled by default. * - Added callbacks for when a notification is opened or closed. * - Added callback for the global closer. * - Customizable animation speed. * - jGrowl now set itself up and tears itself down. * * Changes in 1.0.1: * - Removed dependency on metadata plugin in favor of .data() * - Namespaced all events */ (function($) { /** jGrowl Wrapper - Establish a base jGrowl Container for compatibility with older releases. **/ $.jGrowl = function( m , o ) { // To maintain compatibility with older version that only supported one instance we'll create the base container. if ( $('#jGrowl').size() == 0 ) $('
').addClass( (o && o.position) ? o.position : $.jGrowl.defaults.position ).appendTo('body'); // Create a notification on the container. $('#jGrowl').jGrowl(m,o); }; /** Raise jGrowl Notification on a jGrowl Container **/ $.fn.jGrowl = function( m , o ) { if ( $.isFunction(this.each) ) { var args = arguments; return this.each(function() { var self = this; /** Create a jGrowl Instance on the Container if it does not exist **/ if ( $(this).data('jGrowl.instance') == undefined ) { $(this).data('jGrowl.instance', $.extend( new $.fn.jGrowl(), { notifications: [], element: null, interval: null } )); $(this).data('jGrowl.instance').startup( this ); } /** Optionally call jGrowl instance methods, or just raise a normal notification **/ if ( $.isFunction($(this).data('jGrowl.instance')[m]) ) { $(this).data('jGrowl.instance')[m].apply( $(this).data('jGrowl.instance') , $.makeArray(args).slice(1) ); } else { $(this).data('jGrowl.instance').create( m , o ); } }); }; }; $.extend( $.fn.jGrowl.prototype , { /** Default JGrowl Settings **/ defaults: { pool: 0, header: '', group: '', sticky: false, position: 'top-right', glue: 'after', theme: 'default', themeState: 'highlight', corners: '10px', check: 250, life: 3000, closeDuration: 'normal', openDuration: 'normal', easing: 'swing', closer: true, closeTemplate: '×', closerTemplate: '
[ close all ]
', log: function(e,m,o) {}, beforeOpen: function(e,m,o) {}, afterOpen: function(e,m,o) {}, open: function(e,m,o) {}, beforeClose: function(e,m,o) {}, close: function(e,m,o) {}, animateOpen: { opacity: 'show' }, animateClose: { opacity: 'hide' } }, notifications: [], /** jGrowl Container Node **/ element: null, /** Interval Function **/ interval: null, /** Create a Notification **/ create: function( message , o ) { var o = $.extend({}, this.defaults, o); /* To keep backward compatibility with 1.24 and earlier, honor 'speed' if the user has set it */ if (typeof o.speed !== 'undefined') { o.openDuration = o.speed; o.closeDuration = o.speed; } this.notifications.push({ message: message , options: o }); o.log.apply( this.element , [this.element,message,o] ); }, render: function( notification ) { var self = this; var message = notification.message; var o = notification.options; var notification = $( '
' + '
' + o.closeTemplate + '
' + '
' + o.header + '
' + '
' + message + '
' ).data("jGrowl", o).addClass(o.theme).children('div.jGrowl-close').bind("click.jGrowl", function() { $(this).parent().trigger('jGrowl.close'); }).parent(); /** Notification Actions **/ $(notification).bind("mouseover.jGrowl", function() { $('div.jGrowl-notification', self.element).data("jGrowl.pause", true); }).bind("mouseout.jGrowl", function() { $('div.jGrowl-notification', self.element).data("jGrowl.pause", false); }).bind('jGrowl.beforeOpen', function() { if ( o.beforeOpen.apply( notification , [notification,message,o,self.element] ) != false ) { $(this).trigger('jGrowl.open'); } }).bind('jGrowl.open', function() { if ( o.open.apply( notification , [notification,message,o,self.element] ) != false ) { if ( o.glue == 'after' ) { $('div.jGrowl-notification:last', self.element).after(notification); } else { $('div.jGrowl-notification:first', self.element).before(notification); } $(this).animate(o.animateOpen, o.openDuration, o.easing, function() { // Fixes some anti-aliasing issues with IE filters. if ($.browser.msie && (parseInt($(this).css('opacity'), 10) === 1 || parseInt($(this).css('opacity'), 10) === 0)) this.style.removeAttribute('filter'); $(this).data("jGrowl").created = new Date(); $(this).trigger('jGrowl.afterOpen'); }); } }).bind('jGrowl.afterOpen', function() { o.afterOpen.apply( notification , [notification,message,o,self.element] ); }).bind('jGrowl.beforeClose', function() { if ( o.beforeClose.apply( notification , [notification,message,o,self.element] ) != false ) $(this).trigger('jGrowl.close'); }).bind('jGrowl.close', function() { // Pause the notification, lest during the course of animation another close event gets called. $(this).data('jGrowl.pause', true); $(this).animate(o.animateClose, o.closeDuration, o.easing, function() { $(this).remove(); var close = o.close.apply( notification , [notification,message,o,self.element] ); if ( $.isFunction(close) ) close.apply( notification , [notification,message,o,self.element] ); }); }).trigger('jGrowl.beforeOpen'); /** Optional Corners Plugin **/ if(navigator.appName != 'Microsoft Internet Explorer') { if ( o.corners != '' && $.fn.corner != undefined ) $(notification).corner( o.corners ); } /** Add a Global Closer if more than one notification exists **/ if ( $('div.jGrowl-notification:parent', self.element).size() > 1 && $('div.jGrowl-closer', self.element).size() == 0 && this.defaults.closer != false ) { $(this.defaults.closerTemplate).addClass('jGrowl-closer ui-state-highlight ui-corner-all').addClass(this.defaults.theme) .appendTo(self.element).animate(this.defaults.animateOpen, this.defaults.speed, this.defaults.easing) .bind("click.jGrowl", function() { $(this).siblings().trigger("jGrowl.beforeClose"); if ( $.isFunction( self.defaults.closer ) ) { self.defaults.closer.apply( $(this).parent()[0] , [$(this).parent()[0]] ); } }); }; }, /** Update the jGrowl Container, removing old jGrowl notifications **/ update: function() { $(this.element).find('div.jGrowl-notification:parent').each( function() { if ( $(this).data("jGrowl") != undefined && $(this).data("jGrowl").created != undefined && ($(this).data("jGrowl").created.getTime() + parseInt($(this).data("jGrowl").life)) < (new Date()).getTime() && $(this).data("jGrowl").sticky != true && ($(this).data("jGrowl.pause") == undefined || $(this).data("jGrowl.pause") != true) ) { // Pause the notification, lest during the course of animation another close event gets called. $(this).trigger('jGrowl.beforeClose'); } }); if ( this.notifications.length > 0 && (this.defaults.pool == 0 || $(this.element).find('div.jGrowl-notification:parent').size() < this.defaults.pool) ) this.render( this.notifications.shift() ); if ( $(this.element).find('div.jGrowl-notification:parent').size() < 2 ) { $(this.element).find('div.jGrowl-closer').animate(this.defaults.animateClose, this.defaults.speed, this.defaults.easing, function() { $(this).remove(); }); } }, /** Setup the jGrowl Notification Container **/ startup: function(e) { this.element = $(e).addClass('jGrowl').append('
'); this.interval = setInterval( function() { $(e).data('jGrowl.instance').update(); }, parseInt(this.defaults.check)); if ($.browser.msie && parseInt($.browser.version) < 7 && !window["XMLHttpRequest"]) { $(this.element).addClass('ie6'); } }, /** Shutdown jGrowl, removing it and clearing the interval **/ shutdown: function() { $(this.element).removeClass('jGrowl').find('div.jGrowl-notification').remove(); clearInterval( this.interval ); }, close: function() { $(this.element).find('div.jGrowl-notification').each(function(){ $(this).trigger('jGrowl.beforeClose'); }); } }); /** Reference the Defaults Object for compatibility with older versions of jGrowl **/ $.jGrowl.defaults = $.fn.jGrowl.prototype.defaults; })(jQuery); // ./jquery.tablednd_0_5.js /** * TableDnD plug-in for JQuery, allows you to drag and drop table rows * You can set up various options to control how the system will work * Copyright (c) Denis Howlett * Licensed like jQuery, see http://docs.jquery.com/License. * * Configuration options: * * onDragStyle * This is the style that is assigned to the row during drag. There are limitations to the styles that can be * associated with a row (such as you can't assign a border--well you can, but it won't be * displayed). (So instead consider using onDragClass.) The CSS style to apply is specified as * a map (as used in the jQuery css(...) function). * onDropStyle * This is the style that is assigned to the row when it is dropped. As for onDragStyle, there are limitations * to what you can do. Also this replaces the original style, so again consider using onDragClass which * is simply added and then removed on drop. * onDragClass * This class is added for the duration of the drag and then removed when the row is dropped. It is more * flexible than using onDragStyle since it can be inherited by the row cells and other content. The default * is class is tDnD_whileDrag. So to use the default, simply customise this CSS class in your * stylesheet. * onDrop * Pass a function that will be called when the row is dropped. The function takes 2 parameters: the table * and the row that was dropped. You can work out the new order of the rows by using * table.rows. * onDragStart * Pass a function that will be called when the user starts dragging. The function takes 2 parameters: the * table and the row which the user has started to drag. * onAllowDrop * Pass a function that will be called as a row is over another row. If the function returns true, allow * dropping on that row, otherwise not. The function takes 2 parameters: the dragged row and the row under * the cursor. It returns a boolean: true allows the drop, false doesn't allow it. * scrollAmount * This is the number of pixels to scroll if the user moves the mouse cursor to the top or bottom of the * window. The page should automatically scroll up or down as appropriate (tested in IE6, IE7, Safari, FF2, * FF3 beta * dragHandle * This is the name of a class that you assign to one or more cells in each row that is draggable. If you * specify this class, then you are responsible for setting cursor: move in the CSS and only these cells * will have the drag behaviour. If you do not specify a dragHandle, then you get the old behaviour where * the whole row is draggable. * * Other ways to control behaviour: * * Add class="nodrop" to any rows for which you don't want to allow dropping, and class="nodrag" to any rows * that you don't want to be draggable. * * Inside the onDrop method you can also call $.tableDnD.serialize() this returns a string of the form * []=&[]= so that you can send this back to the server. The table must have * an ID as must all the rows. * * Other methods: * * $("...").tableDnDUpdate() * Will update all the matching tables, that is it will reapply the mousedown method to the rows (or handle cells). * This is useful if you have updated the table rows using Ajax and you want to make the table draggable again. * The table maintains the original configuration (so you don't have to specify it again). * * $("...").tableDnDSerialize() * Will serialize and return the serialized string as above, but for each of the matching tables--so it can be * called from anywhere and isn't dependent on the currentTable being set up correctly before calling * * Known problems: * - Auto-scoll has some problems with IE7 (it scrolls even when it shouldn't), work-around: set scrollAmount to 0 * * Version 0.2: 2008-02-20 First public version * Version 0.3: 2008-02-07 Added onDragStart option * Made the scroll amount configurable (default is 5 as before) * Version 0.4: 2008-03-15 Changed the noDrag/noDrop attributes to nodrag/nodrop classes * Added onAllowDrop to control dropping * Fixed a bug which meant that you couldn't set the scroll amount in both directions * Added serialize method * Version 0.5: 2008-05-16 Changed so that if you specify a dragHandle class it doesn't make the whole row * draggable * Improved the serialize method to use a default (and settable) regular expression. * Added tableDnDupate() and tableDnDSerialize() to be called when you are outside the table */ jQuery.tableDnD = { /** Keep hold of the current table being dragged */ currentTable : null, /** Keep hold of the current drag object if any */ dragObject: null, /** The current mouse offset */ mouseOffset: null, /** Remember the old value of Y so that we don't do too much processing */ oldY: 0, /** Actually build the structure */ build: function(options) { // Set up the defaults if any this.each(function() { // This is bound to each matching table, set up the defaults and override with user options this.tableDnDConfig = jQuery.extend({ onDragStyle: null, onDropStyle: null, // Add in the default class for whileDragging onDragClass: "tDnD_whileDrag", onDrop: null, onDragStart: null, scrollAmount: 5, serializeRegexp: /[^\-]*$/, // The regular expression to use to trim row IDs serializeParamName: null, // If you want to specify another parameter name instead of the table ID dragHandle: null // If you give the name of a class here, then only Cells with this class will be draggable }, options || {}); // Now make the rows draggable jQuery.tableDnD.makeDraggable(this); }); // Now we need to capture the mouse up and mouse move event // We can use bind so that we don't interfere with other event handlers jQuery(document) .bind('mousemove', jQuery.tableDnD.mousemove) .bind('mouseup', jQuery.tableDnD.mouseup); // Don't break the chain return this; }, /** This function makes all the rows on the table draggable apart from those marked as "NoDrag" */ makeDraggable: function(table) { var config = table.tableDnDConfig; if (table.tableDnDConfig.dragHandle) { // We only need to add the event to the specified cells var cells = jQuery("td."+table.tableDnDConfig.dragHandle, table); cells.each(function() { // The cell is bound to "this" jQuery(this).mousedown(function(ev) { jQuery.tableDnD.dragObject = this.parentNode; jQuery.tableDnD.currentTable = table; jQuery.tableDnD.mouseOffset = jQuery.tableDnD.getMouseOffset(this, ev); if (config.onDragStart) { // Call the onDrop method if there is one config.onDragStart(table, this); } return false; }); }) } else { // For backwards compatibility, we add the event to the whole row var rows = jQuery("tr", table); // get all the rows as a wrapped set rows.each(function() { // Iterate through each row, the row is bound to "this" var row = jQuery(this); if (! row.hasClass("nodrag")) { row.mousedown(function(ev) { if (ev.target.tagName == "TD") { jQuery.tableDnD.dragObject = this; jQuery.tableDnD.currentTable = table; jQuery.tableDnD.mouseOffset = jQuery.tableDnD.getMouseOffset(this, ev); if (config.onDragStart) { // Call the onDrop method if there is one config.onDragStart(table, this); } return false; } }).css("cursor", "move"); // Store the tableDnD object } }); } }, updateTables: function() { this.each(function() { // this is now bound to each matching table if (this.tableDnDConfig) { jQuery.tableDnD.makeDraggable(this); } }) }, /** Get the mouse coordinates from the event (allowing for browser differences) */ mouseCoords: function(ev){ if(ev.pageX || ev.pageY){ return {x:ev.pageX, y:ev.pageY}; } return { x:ev.clientX + document.body.scrollLeft - document.body.clientLeft, y:ev.clientY + document.body.scrollTop - document.body.clientTop }; }, /** Given a target element and a mouse event, get the mouse offset from that element. To do this we need the element's position and the mouse position */ getMouseOffset: function(target, ev) { ev = ev || window.event; var docPos = this.getPosition(target); var mousePos = this.mouseCoords(ev); return {x:mousePos.x - docPos.x, y:mousePos.y - docPos.y}; }, /** Get the position of an element by going up the DOM tree and adding up all the offsets */ getPosition: function(e){ var left = 0; var top = 0; /** Safari fix -- thanks to Luis Chato for this! */ if (e.offsetHeight == 0) { /** Safari 2 doesn't correctly grab the offsetTop of a table row this is detailed here: http://jacob.peargrove.com/blog/2006/technical/table-row-offsettop-bug-in-safari/ the solution is likewise noted there, grab the offset of a table cell in the row - the firstChild. note that firefox will return a text node as a first child, so designing a more thorough solution may need to take that into account, for now this seems to work in firefox, safari, ie */ e = e.firstChild; // a table cell } while (e.offsetParent){ left += e.offsetLeft; top += e.offsetTop; e = e.offsetParent; } left += e.offsetLeft; top += e.offsetTop; return {x:left, y:top}; }, mousemove: function(ev) { if (jQuery.tableDnD.dragObject == null) { return; } var dragObj = jQuery(jQuery.tableDnD.dragObject); var config = jQuery.tableDnD.currentTable.tableDnDConfig; var mousePos = jQuery.tableDnD.mouseCoords(ev); var y = mousePos.y - jQuery.tableDnD.mouseOffset.y; //auto scroll the window var yOffset = window.pageYOffset; if (document.all) { // Windows version //yOffset=document.body.scrollTop; if (typeof document.compatMode != 'undefined' && document.compatMode != 'BackCompat') { yOffset = document.documentElement.scrollTop; } else if (typeof document.body != 'undefined') { yOffset=document.body.scrollTop; } } if (mousePos.y-yOffset < config.scrollAmount) { window.scrollBy(0, -config.scrollAmount); } else { var windowHeight = window.innerHeight ? window.innerHeight : document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body.clientHeight; if (windowHeight-(mousePos.y-yOffset) < config.scrollAmount) { window.scrollBy(0, config.scrollAmount); } } if (y != jQuery.tableDnD.oldY) { // work out if we're going up or down... var movingDown = y > jQuery.tableDnD.oldY; // update the old value jQuery.tableDnD.oldY = y; // update the style to show we're dragging if (config.onDragClass) { dragObj.addClass(config.onDragClass); } else { dragObj.css(config.onDragStyle); } // If we're over a row then move the dragged row to there so that the user sees the // effect dynamically var currentRow = jQuery.tableDnD.findDropTargetRow(dragObj, y); if (currentRow) { // TODO worry about what happens when there are multiple TBODIES if (movingDown && jQuery.tableDnD.dragObject != currentRow) { jQuery.tableDnD.dragObject.parentNode.insertBefore(jQuery.tableDnD.dragObject, currentRow.nextSibling); } else if (! movingDown && jQuery.tableDnD.dragObject != currentRow) { jQuery.tableDnD.dragObject.parentNode.insertBefore(jQuery.tableDnD.dragObject, currentRow); } } } return false; }, /** We're only worried about the y position really, because we can only move rows up and down */ findDropTargetRow: function(draggedRow, y) { var rows = jQuery.tableDnD.currentTable.rows; for (var i=0; i rowY - rowHeight) && (y < (rowY + rowHeight))) { // that's the row we're over // If it's the same as the current row, ignore it if (row == draggedRow) {return null;} var config = jQuery.tableDnD.currentTable.tableDnDConfig; if (config.onAllowDrop) { if (config.onAllowDrop(draggedRow, row)) { return row; } else { return null; } } else { // If a row has nodrop class, then don't allow dropping (inspired by John Tarr and Famic) var nodrop = jQuery(row).hasClass("nodrop"); if (! nodrop) { return row; } else { return null; } } return row; } } return null; }, mouseup: function(e) { if (jQuery.tableDnD.currentTable && jQuery.tableDnD.dragObject) { var droppedRow = jQuery.tableDnD.dragObject; var config = jQuery.tableDnD.currentTable.tableDnDConfig; // If we have a dragObject, then we need to release it, // The row will already have been moved to the right place so we just reset stuff if (config.onDragClass) { jQuery(droppedRow).removeClass(config.onDragClass); } else { jQuery(droppedRow).css(config.onDropStyle); } jQuery.tableDnD.dragObject = null; if (config.onDrop) { // Call the onDrop method if there is one config.onDrop(jQuery.tableDnD.currentTable, droppedRow); } jQuery.tableDnD.currentTable = null; // let go of the table too } }, serialize: function() { if (jQuery.tableDnD.currentTable) { return jQuery.tableDnD.serializeTable(jQuery.tableDnD.currentTable); } else { return "Error: No Table id set, you need to set an id on your table and every row"; } }, serializeTable: function(table) { var result = ""; var tableId = table.id; var rows = table.rows; for (var i=0; i 0) result += "&"; var rowId = rows[i].id; if (rowId && rowId && table.tableDnDConfig && table.tableDnDConfig.serializeRegexp) { rowId = rowId.match(table.tableDnDConfig.serializeRegexp)[0]; } result += tableId + '[]=' + rowId; } return result; }, serializeTables: function() { var result = ""; this.each(function() { // this is now bound to each matching table result += jQuery.tableDnD.serializeTable(this); }); return result; } } jQuery.fn.extend( { tableDnD : jQuery.tableDnD.build, tableDnDUpdate : jQuery.tableDnD.updateTables, tableDnDSerialize: jQuery.tableDnD.serializeTables } ); // ./jquery.tabledisplay-0.2.js /* * jQuery Table Display * * Copyright (c) 2008 Gabriel Langhans, Lucas Leite, Maicon Martins * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * $Date: 2008-08-06 14:01:12 +0300 (Wed, 06 Aug 2008) $ */ (function($){ $.fn.toggleRow = function() { if($(this).css('display')=='none') { $(this).showRow(); } else { $(this).hideRow(); } }; $.fn.hideRow = function() { $(this).hide(); }; $.fn.showRow = function() { if($(this).css('display')=='none'){ if ($.browser.msie) { $(this).css('display', 'block'); } else{ $(this).css('display', 'table-row'); } } }; })(jQuery); // ./jquery.tools.min.js /* * jquery.tools 1.0.2 - The missing UI library * * [tools.tooltip-1.0.2] * * Copyright (c) 2009 Tero Piirainen * http://flowplayer.org/tools/ * * Dual licensed under MIT and GPL 2+ licenses * http://www.opensource.org/licenses * * ----- * * Build: Fri Jun 12 12:46:48 GMT+00:00 2009 */ (function(c){c.tools=c.tools||{version:{}};c.tools.version.tooltip="1.0.2";var b={toggle:[function(){this.getTip().show()},function(){this.getTip().hide()}],fade:[function(){this.getTip().fadeIn(this.getConf().fadeInSpeed)},function(){this.getTip().fadeOut(this.getConf().fadeOutSpeed)}]};c.tools.addTipEffect=function(d,f,e){b[d]=[f,e]};c.tools.addTipEffect("slideup",function(){var d=this.getConf();var e=d.slideOffset||10;this.getTip().css({opacity:0}).animate({top:"-="+e,opacity:d.opacity},d.slideInSpeed||200).show()},function(){var d=this.getConf();var e=d.slideOffset||10;this.getTip().animate({top:"-="+e,opacity:0},d.slideOutSpeed||200,function(){c(this).hide().animate({top:"+="+(e*2)},0)})});function a(f,e){var d=this;var h=f.next();if(e.tip){if(e.tip.indexOf("#")!=-1){h=c(e.tip)}else{h=f.nextAll(e.tip).eq(0);if(!h.length){h=f.parent().nextAll(e.tip).eq(0)}}}function j(k,l){c(d).bind(k,function(n,m){if(l&&l.call(this)===false&&m){m.proceed=false}});return d}c.each(e,function(k,l){if(c.isFunction(l)){j(k,l)}});var g=f.is("input, textarea");f.bind(g?"focus":"mouseover",function(k){k.target=this;d.show(k);h.hover(function(){d.show()},function(){d.hide()})});f.bind(g?"blur":"mouseout",function(){d.hide()});h.css("opacity",e.opacity);var i=0;c.extend(d,{show:function(q){if(q){f=c(q.target)}clearTimeout(i);if(h.is(":animated")||h.is(":visible")){return d}var o={proceed:true};c(d).trigger("onBeforeShow",o);if(!o.proceed){return d}var n=f.position().top-h.outerHeight();var k=h.outerHeight()+f.outerHeight();var r=e.position[0];if(r=="center"){n+=k/2}if(r=="bottom"){n+=k}var l=f.outerWidth()+h.outerWidth();var m=f.position().left+f.outerWidth();r=e.position[1];if(r=="center"){m-=l/2}if(r=="left"){m-=l}n+=e.offset[0];m+=e.offset[1];h.css({position:"absolute",top:n,left:m});b[e.effect][0].call(d);c(d).trigger("onShow");return d},hide:function(){clearTimeout(i);i=setTimeout(function(){if(!h.is(":visible")){return d}var k={proceed:true};c(d).trigger("onBeforeHide",k);if(!k.proceed){return d}b[e.effect][1].call(d);c(d).trigger("onHide")},e.delay||1);return d},isShown:function(){return h.is(":visible, :animated")},getConf:function(){return e},getTip:function(){return h},getTrigger:function(){return f},onBeforeShow:function(k){return j("onBeforeShow",k)},onShow:function(k){return j("onShow",k)},onBeforeHide:function(k){return j("onBeforeHide",k)},onHide:function(k){return j("onHide",k)}})}c.prototype.tooltip=function(d){var e=this.eq(typeof d=="number"?d:0).data("tooltip");if(e){return e}var f={tip:null,effect:"slideup",delay:30,opacity:1,position:["top","center"],offset:[0,0],api:false};if(c.isFunction(d)){d={onBeforeShow:d}}c.extend(f,d);this.each(function(){e=new a(c(this),f);c(this).data("tooltip",e)});return f.api?e:this}})(jQuery); // ./jquery.lightbox-0.5.min.js /** * jQuery lightBox plugin * This jQuery plugin was inspired and based on Lightbox 2 by Lokesh Dhakar (http://www.huddletogether.com/projects/lightbox2/) * and adapted to me for use like a plugin from jQuery. * @name jquery-lightbox-0.5.js * @author Leandro Vieira Pinho - http://leandrovieira.com * @version 0.5 * @date April 11, 2008 * @category jQuery plugin * @copyright (c) 2008 Leandro Vieira Pinho (leandrovieira.com) * @license CC Attribution-No Derivative Works 2.5 Brazil - http://creativecommons.org/licenses/by-nd/2.5/br/deed.en_US * @example Visit http://leandrovieira.com/projects/jquery/lightbox/ for more informations about this jQuery plugin */ (function($){$.fn.lightBox=function(settings){settings=jQuery.extend({overlayBgColor:'#000',overlayOpacity:0.8,fixedNavigation:false,imageLoading:'images/lightbox-ico-loading.gif',imageBtnPrev:'images/lightbox-btn-prev.gif',imageBtnNext:'images/lightbox-btn-next.gif',imageBtnClose:'images/lightbox-btn-close.gif',imageBlank:'images/lightbox-blank.gif',containerBorderSize:10,containerResizeSpeed:400,txtImage:'Image',txtOf:'of',keyToClose:'c',keyToPrev:'p',keyToNext:'n',imageArray:[],activeImage:0},settings);var jQueryMatchedObj=this;function _initialize(){_start(this,jQueryMatchedObj);return false;} function _start(objClicked,jQueryMatchedObj){$('embed, object, select').css({'visibility':'hidden'});_set_interface();settings.imageArray.length=0;settings.activeImage=0;if(jQueryMatchedObj.length==1){settings.imageArray.push(new Array(objClicked.getAttribute('href'),objClicked.getAttribute('title')));}else{for(var i=0;i
');var arrPageSizes=___getPageSize();$('#jquery-overlay').css({backgroundColor:settings.overlayBgColor,opacity:settings.overlayOpacity,width:arrPageSizes[0],height:arrPageSizes[1]}).fadeIn();var arrPageScroll=___getPageScroll();$('#jquery-lightbox').css({top:arrPageScroll[1]+(arrPageSizes[3]/10),left:arrPageScroll[0]}).show();$('#jquery-overlay,#jquery-lightbox').click(function(){_finish();});$('#lightbox-loading-link,#lightbox-secNav-btnClose').click(function(){_finish();return false;});$(window).resize(function(){var arrPageSizes=___getPageSize();$('#jquery-overlay').css({width:arrPageSizes[0],height:arrPageSizes[1]});var arrPageScroll=___getPageScroll();$('#jquery-lightbox').css({top:arrPageScroll[1]+(arrPageSizes[3]/10),left:arrPageScroll[0]});});} function _set_image_to_view(){$('#lightbox-loading').show();if(settings.fixedNavigation){$('#lightbox-image,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber').hide();}else{$('#lightbox-image,#lightbox-nav,#lightbox-nav-btnPrev,#lightbox-nav-btnNext,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber').hide();} var objImagePreloader=new Image();objImagePreloader.onload=function(){$('#lightbox-image').attr('src',settings.imageArray[settings.activeImage][0]);_resize_container_image_box(objImagePreloader.width,objImagePreloader.height);objImagePreloader.onload=function(){};};objImagePreloader.src=settings.imageArray[settings.activeImage][0];};function _resize_container_image_box(intImageWidth,intImageHeight){var intCurrentWidth=$('#lightbox-container-image-box').width();var intCurrentHeight=$('#lightbox-container-image-box').height();var intWidth=(intImageWidth+(settings.containerBorderSize*2));var intHeight=(intImageHeight+(settings.containerBorderSize*2));var intDiffW=intCurrentWidth-intWidth;var intDiffH=intCurrentHeight-intHeight;$('#lightbox-container-image-box').animate({width:intWidth,height:intHeight},settings.containerResizeSpeed,function(){_show_image();});if((intDiffW==0)&&(intDiffH==0)){if($.browser.msie){___pause(250);}else{___pause(100);}} $('#lightbox-container-image-data-box').css({width:intImageWidth});$('#lightbox-nav-btnPrev,#lightbox-nav-btnNext').css({height:intImageHeight+(settings.containerBorderSize*2)});};function _show_image(){$('#lightbox-loading').hide();$('#lightbox-image').fadeIn(function(){_show_image_data();_set_navigation();});_preload_neighbor_images();};function _show_image_data(){$('#lightbox-container-image-data-box').slideDown('fast');$('#lightbox-image-details-caption').hide();if(settings.imageArray[settings.activeImage][1]){$('#lightbox-image-details-caption').html(settings.imageArray[settings.activeImage][1]).show();} if(settings.imageArray.length>1){$('#lightbox-image-details-currentNumber').html(settings.txtImage+' '+(settings.activeImage+1)+' '+settings.txtOf+' '+settings.imageArray.length).show();}} function _set_navigation(){$('#lightbox-nav').show();$('#lightbox-nav-btnPrev,#lightbox-nav-btnNext').css({'background':'transparent url('+settings.imageBlank+') no-repeat'});if(settings.activeImage!=0){if(settings.fixedNavigation){$('#lightbox-nav-btnPrev').css({'background':'url('+settings.imageBtnPrev+') left 15% no-repeat'}).unbind().bind('click',function(){settings.activeImage=settings.activeImage-1;_set_image_to_view();return false;});}else{$('#lightbox-nav-btnPrev').unbind().hover(function(){$(this).css({'background':'url('+settings.imageBtnPrev+') left 15% no-repeat'});},function(){$(this).css({'background':'transparent url('+settings.imageBlank+') no-repeat'});}).show().bind('click',function(){settings.activeImage=settings.activeImage-1;_set_image_to_view();return false;});}} if(settings.activeImage!=(settings.imageArray.length-1)){if(settings.fixedNavigation){$('#lightbox-nav-btnNext').css({'background':'url('+settings.imageBtnNext+') right 15% no-repeat'}).unbind().bind('click',function(){settings.activeImage=settings.activeImage+1;_set_image_to_view();return false;});}else{$('#lightbox-nav-btnNext').unbind().hover(function(){$(this).css({'background':'url('+settings.imageBtnNext+') right 15% no-repeat'});},function(){$(this).css({'background':'transparent url('+settings.imageBlank+') no-repeat'});}).show().bind('click',function(){settings.activeImage=settings.activeImage+1;_set_image_to_view();return false;});}} _enable_keyboard_navigation();} function _enable_keyboard_navigation(){$(document).keydown(function(objEvent){_keyboard_action(objEvent);});} function _disable_keyboard_navigation(){$(document).unbind();} function _keyboard_action(objEvent){if(objEvent==null){keycode=event.keyCode;escapeKey=27;}else{keycode=objEvent.keyCode;escapeKey=objEvent.DOM_VK_ESCAPE;} key=String.fromCharCode(keycode).toLowerCase();if((key==settings.keyToClose)||(key=='x')||(keycode==escapeKey)){_finish();} if((key==settings.keyToPrev)||(keycode==37)){if(settings.activeImage!=0){settings.activeImage=settings.activeImage-1;_set_image_to_view();_disable_keyboard_navigation();}} if((key==settings.keyToNext)||(keycode==39)){if(settings.activeImage!=(settings.imageArray.length-1)){settings.activeImage=settings.activeImage+1;_set_image_to_view();_disable_keyboard_navigation();}}} function _preload_neighbor_images(){if((settings.imageArray.length-1)>settings.activeImage){objNext=new Image();objNext.src=settings.imageArray[settings.activeImage+1][0];} if(settings.activeImage>0){objPrev=new Image();objPrev.src=settings.imageArray[settings.activeImage-1][0];}} function _finish(){$('#jquery-lightbox').remove();$('#jquery-overlay').fadeOut(function(){$('#jquery-overlay').remove();});$('embed, object, select').css({'visibility':'visible'});} function ___getPageSize(){var xScroll,yScroll;if(window.innerHeight&&window.scrollMaxY){xScroll=window.innerWidth+window.scrollMaxX;yScroll=window.innerHeight+window.scrollMaxY;}else if(document.body.scrollHeight>document.body.offsetHeight){xScroll=document.body.scrollWidth;yScroll=document.body.scrollHeight;}else{xScroll=document.body.offsetWidth;yScroll=document.body.offsetHeight;} var windowWidth,windowHeight;if(self.innerHeight){if(document.documentElement.clientWidth){windowWidth=document.documentElement.clientWidth;}else{windowWidth=self.innerWidth;} windowHeight=self.innerHeight;}else if(document.documentElement&&document.documentElement.clientHeight){windowWidth=document.documentElement.clientWidth;windowHeight=document.documentElement.clientHeight;}else if(document.body){windowWidth=document.body.clientWidth;windowHeight=document.body.clientHeight;} if(yScroll0){return true}m[j]=1;l=(m[j]>0);m[j]=0;return l},isOverAxis:function(k,j,l){return(k>j)&&(k<(j+l))},isOver:function(o,k,n,m,j,l){return c.ui.isOverAxis(o,n,j)&&c.ui.isOverAxis(k,m,l)},keyCode:{BACKSPACE:8,CAPS_LOCK:20,COMMA:188,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38}};if(d){var f=c.attr,e=c.fn.removeAttr,h="http://www.w3.org/2005/07/aaa",a=/^aria-/,b=/^wairole:/;c.attr=function(k,j,l){var m=l!==undefined;return(j=="role"?(m?f.call(this,k,j,"wairole:"+l):(f.apply(this,arguments)||"").replace(b,"")):(a.test(j)?(m?k.setAttributeNS(h,j.replace(a,"aaa:"),l):f.call(this,k,j.replace(a,"aaa:"))):f.apply(this,arguments)))};c.fn.removeAttr=function(j){return(a.test(j)?this.each(function(){this.removeAttributeNS(h,j.replace(a,""))}):e.call(this,j))}}c.fn.extend({remove:function(j,k){return this.each(function(){if(!k){if(!j||c.filter(j,[this]).length){c("*",this).add(this).each(function(){c(this).triggerHandler("remove")})}}return i.call(c(this),j,k)})},enableSelection:function(){return this.attr("unselectable","off").css("MozUserSelect","").unbind("selectstart.ui")},disableSelection:function(){return this.attr("unselectable","on").css("MozUserSelect","none").bind("selectstart.ui",function(){return false})},scrollParent:function(){var j;if((c.browser.msie&&(/(static|relative)/).test(this.css("position")))||(/absolute/).test(this.css("position"))){j=this.parents().filter(function(){return(/(relative|absolute|fixed)/).test(c.curCSS(this,"position",1))&&(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}else{j=this.parents().filter(function(){return(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}return(/fixed/).test(this.css("position"))||!j.length?c(document):j}});c.extend(c.expr[":"],{data:function(l,k,j){return !!c.data(l,j[3])},focusable:function(k){var l=k.nodeName.toLowerCase(),j=c.attr(k,"tabindex");return(/input|select|textarea|button|object/.test(l)?!k.disabled:"a"==l||"area"==l?k.href||!isNaN(j):!isNaN(j))&&!c(k)["area"==l?"parents":"closest"](":hidden").length},tabbable:function(k){var j=c.attr(k,"tabindex");return(isNaN(j)||j>=0)&&c(k).is(":focusable")}});function g(m,n,o,l){function k(q){var p=c[m][n][q]||[];return(typeof p=="string"?p.split(/,?\s+/):p)}var j=k("getter");if(l.length==1&&typeof l[0]=="string"){j=j.concat(k("getterSetter"))}return(c.inArray(o,j)!=-1)}c.widget=function(k,j){var l=k.split(".")[0];k=k.split(".")[1];c.fn[k]=function(p){var n=(typeof p=="string"),o=Array.prototype.slice.call(arguments,1);if(n&&p.substring(0,1)=="_"){return this}if(n&&g(l,k,p,o)){var m=c.data(this[0],k);return(m?m[p].apply(m,o):undefined)}return this.each(function(){var q=c.data(this,k);(!q&&!n&&c.data(this,k,new c[l][k](this,p))._init());(q&&n&&c.isFunction(q[p])&&q[p].apply(q,o))})};c[l]=c[l]||{};c[l][k]=function(o,n){var m=this;this.namespace=l;this.widgetName=k;this.widgetEventPrefix=c[l][k].eventPrefix||k;this.widgetBaseClass=l+"-"+k;this.options=c.extend({},c.widget.defaults,c[l][k].defaults,c.metadata&&c.metadata.get(o)[k],n);this.element=c(o).bind("setData."+k,function(q,p,r){if(q.target==o){return m._setData(p,r)}}).bind("getData."+k,function(q,p){if(q.target==o){return m._getData(p)}}).bind("remove",function(){return m.destroy()})};c[l][k].prototype=c.extend({},c.widget.prototype,j);c[l][k].getterSetter="option"};c.widget.prototype={_init:function(){},destroy:function(){this.element.removeData(this.widgetName).removeClass(this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").removeAttr("aria-disabled")},option:function(l,m){var k=l,j=this;if(typeof l=="string"){if(m===undefined){return this._getData(l)}k={};k[l]=m}c.each(k,function(n,o){j._setData(n,o)})},_getData:function(j){return this.options[j]},_setData:function(j,k){this.options[j]=k;if(j=="disabled"){this.element[k?"addClass":"removeClass"](this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").attr("aria-disabled",k)}},enable:function(){this._setData("disabled",false)},disable:function(){this._setData("disabled",true)},_trigger:function(l,m,n){var p=this.options[l],j=(l==this.widgetEventPrefix?l:this.widgetEventPrefix+l);m=c.Event(m);m.type=j;if(m.originalEvent){for(var k=c.event.props.length,o;k;){o=c.event.props[--k];m[o]=m.originalEvent[o]}}this.element.trigger(m,n);return !(c.isFunction(p)&&p.call(this.element[0],m,n)===false||m.isDefaultPrevented())}};c.widget.defaults={disabled:false};c.ui.mouse={_mouseInit:function(){var j=this;this.element.bind("mousedown."+this.widgetName,function(k){return j._mouseDown(k)}).bind("click."+this.widgetName,function(k){if(j._preventClickEvent){j._preventClickEvent=false;k.stopImmediatePropagation();return false}});if(c.browser.msie){this._mouseUnselectable=this.element.attr("unselectable");this.element.attr("unselectable","on")}this.started=false},_mouseDestroy:function(){this.element.unbind("."+this.widgetName);(c.browser.msie&&this.element.attr("unselectable",this._mouseUnselectable))},_mouseDown:function(l){l.originalEvent=l.originalEvent||{};if(l.originalEvent.mouseHandled){return}(this._mouseStarted&&this._mouseUp(l));this._mouseDownEvent=l;var k=this,m=(l.which==1),j=(typeof this.options.cancel=="string"?c(l.target).parents().add(l.target).filter(this.options.cancel).length:false);if(!m||j||!this._mouseCapture(l)){return true}this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet){this._mouseDelayTimer=setTimeout(function(){k.mouseDelayMet=true},this.options.delay)}if(this._mouseDistanceMet(l)&&this._mouseDelayMet(l)){this._mouseStarted=(this._mouseStart(l)!==false);if(!this._mouseStarted){l.preventDefault();return true}}this._mouseMoveDelegate=function(n){return k._mouseMove(n)};this._mouseUpDelegate=function(n){return k._mouseUp(n)};c(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate);(c.browser.safari||l.preventDefault());l.originalEvent.mouseHandled=true;return true},_mouseMove:function(j){if(c.browser.msie&&!j.button){return this._mouseUp(j)}if(this._mouseStarted){this._mouseDrag(j);return j.preventDefault()}if(this._mouseDistanceMet(j)&&this._mouseDelayMet(j)){this._mouseStarted=(this._mouseStart(this._mouseDownEvent,j)!==false);(this._mouseStarted?this._mouseDrag(j):this._mouseUp(j))}return !this._mouseStarted},_mouseUp:function(j){c(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=false;this._preventClickEvent=(j.target==this._mouseDownEvent.target);this._mouseStop(j)}return false},_mouseDistanceMet:function(j){return(Math.max(Math.abs(this._mouseDownEvent.pageX-j.pageX),Math.abs(this._mouseDownEvent.pageY-j.pageY))>=this.options.distance)},_mouseDelayMet:function(j){return this.mouseDelayMet},_mouseStart:function(j){},_mouseDrag:function(j){},_mouseStop:function(j){},_mouseCapture:function(j){return true}};c.ui.mouse.defaults={cancel:null,distance:1,delay:0}})(jQuery);;/* * jQuery UI Draggable 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Draggables * * Depends: * ui.core.js */ (function(a){a.widget("ui.draggable",a.extend({},a.ui.mouse,{_init:function(){if(this.options.helper=="original"&&!(/^(?:r|a|f)/).test(this.element.css("position"))){this.element[0].style.position="relative"}(this.options.addClasses&&this.element.addClass("ui-draggable"));(this.options.disabled&&this.element.addClass("ui-draggable-disabled"));this._mouseInit()},destroy:function(){if(!this.element.data("draggable")){return}this.element.removeData("draggable").unbind(".draggable").removeClass("ui-draggable ui-draggable-dragging ui-draggable-disabled");this._mouseDestroy()},_mouseCapture:function(b){var c=this.options;if(this.helper||c.disabled||a(b.target).is(".ui-resizable-handle")){return false}this.handle=this._getHandle(b);if(!this.handle){return false}return true},_mouseStart:function(b){var c=this.options;this.helper=this._createHelper(b);this._cacheHelperProportions();if(a.ui.ddmanager){a.ui.ddmanager.current=this}this._cacheMargins();this.cssPosition=this.helper.css("position");this.scrollParent=this.helper.scrollParent();this.offset=this.element.offset();this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left};a.extend(this.offset,{click:{left:b.pageX-this.offset.left,top:b.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()});this.originalPosition=this._generatePosition(b);this.originalPageX=b.pageX;this.originalPageY=b.pageY;if(c.cursorAt){this._adjustOffsetFromHelper(c.cursorAt)}if(c.containment){this._setContainment()}this._trigger("start",b);this._cacheHelperProportions();if(a.ui.ddmanager&&!c.dropBehaviour){a.ui.ddmanager.prepareOffsets(this,b)}this.helper.addClass("ui-draggable-dragging");this._mouseDrag(b,true);return true},_mouseDrag:function(b,d){this.position=this._generatePosition(b);this.positionAbs=this._convertPositionTo("absolute");if(!d){var c=this._uiHash();this._trigger("drag",b,c);this.position=c.position}if(!this.options.axis||this.options.axis!="y"){this.helper[0].style.left=this.position.left+"px"}if(!this.options.axis||this.options.axis!="x"){this.helper[0].style.top=this.position.top+"px"}if(a.ui.ddmanager){a.ui.ddmanager.drag(this,b)}return false},_mouseStop:function(c){var d=false;if(a.ui.ddmanager&&!this.options.dropBehaviour){d=a.ui.ddmanager.drop(this,c)}if(this.dropped){d=this.dropped;this.dropped=false}if((this.options.revert=="invalid"&&!d)||(this.options.revert=="valid"&&d)||this.options.revert===true||(a.isFunction(this.options.revert)&&this.options.revert.call(this.element,d))){var b=this;a(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){b._trigger("stop",c);b._clear()})}else{this._trigger("stop",c);this._clear()}return false},_getHandle:function(b){var c=!this.options.handle||!a(this.options.handle,this.element).length?true:false;a(this.options.handle,this.element).find("*").andSelf().each(function(){if(this==b.target){c=true}});return c},_createHelper:function(c){var d=this.options;var b=a.isFunction(d.helper)?a(d.helper.apply(this.element[0],[c])):(d.helper=="clone"?this.element.clone():this.element);if(!b.parents("body").length){b.appendTo((d.appendTo=="parent"?this.element[0].parentNode:d.appendTo))}if(b[0]!=this.element[0]&&!(/(fixed|absolute)/).test(b.css("position"))){b.css("position","absolute")}return b},_adjustOffsetFromHelper:function(b){if(b.left!=undefined){this.offset.click.left=b.left+this.margins.left}if(b.right!=undefined){this.offset.click.left=this.helperProportions.width-b.right+this.margins.left}if(b.top!=undefined){this.offset.click.top=b.top+this.margins.top}if(b.bottom!=undefined){this.offset.click.top=this.helperProportions.height-b.bottom+this.margins.top}},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var b=this.offsetParent.offset();if(this.cssPosition=="absolute"&&this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])){b.left+=this.scrollParent.scrollLeft();b.top+=this.scrollParent.scrollTop()}if((this.offsetParent[0]==document.body)||(this.offsetParent[0].tagName&&this.offsetParent[0].tagName.toLowerCase()=="html"&&a.browser.msie)){b={top:0,left:0}}return{top:b.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:b.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if(this.cssPosition=="relative"){var b=this.element.position();return{top:b.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:b.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}else{return{top:0,left:0}}},_cacheMargins:function(){this.margins={left:(parseInt(this.element.css("marginLeft"),10)||0),top:(parseInt(this.element.css("marginTop"),10)||0)}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e=this.options;if(e.containment=="parent"){e.containment=this.helper[0].parentNode}if(e.containment=="document"||e.containment=="window"){this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,a(e.containment=="document"?document:window).width()-this.helperProportions.width-this.margins.left,(a(e.containment=="document"?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]}if(!(/^(document|window|parent)$/).test(e.containment)&&e.containment.constructor!=Array){var c=a(e.containment)[0];if(!c){return}var d=a(e.containment).offset();var b=(a(c).css("overflow")!="hidden");this.containment=[d.left+(parseInt(a(c).css("borderLeftWidth"),10)||0)+(parseInt(a(c).css("paddingLeft"),10)||0)-this.margins.left,d.top+(parseInt(a(c).css("borderTopWidth"),10)||0)+(parseInt(a(c).css("paddingTop"),10)||0)-this.margins.top,d.left+(b?Math.max(c.scrollWidth,c.offsetWidth):c.offsetWidth)-(parseInt(a(c).css("borderLeftWidth"),10)||0)-(parseInt(a(c).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,d.top+(b?Math.max(c.scrollHeight,c.offsetHeight):c.offsetHeight)-(parseInt(a(c).css("borderTopWidth"),10)||0)-(parseInt(a(c).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top]}else{if(e.containment.constructor==Array){this.containment=e.containment}}},_convertPositionTo:function(f,h){if(!h){h=this.position}var c=f=="absolute"?1:-1;var e=this.options,b=this.cssPosition=="absolute"&&!(this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0]))?this.offsetParent:this.scrollParent,g=(/(html|body)/i).test(b[0].tagName);return{top:(h.top+this.offset.relative.top*c+this.offset.parent.top*c-(a.browser.safari&&this.cssPosition=="fixed"?0:(this.cssPosition=="fixed"?-this.scrollParent.scrollTop():(g?0:b.scrollTop()))*c)),left:(h.left+this.offset.relative.left*c+this.offset.parent.left*c-(a.browser.safari&&this.cssPosition=="fixed"?0:(this.cssPosition=="fixed"?-this.scrollParent.scrollLeft():g?0:b.scrollLeft())*c))}},_generatePosition:function(e){var h=this.options,b=this.cssPosition=="absolute"&&!(this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0]))?this.offsetParent:this.scrollParent,i=(/(html|body)/i).test(b[0].tagName);if(this.cssPosition=="relative"&&!(this.scrollParent[0]!=document&&this.scrollParent[0]!=this.offsetParent[0])){this.offset.relative=this._getRelativeOffset()}var d=e.pageX;var c=e.pageY;if(this.originalPosition){if(this.containment){if(e.pageX-this.offset.click.leftthis.containment[2]){d=this.containment[2]+this.offset.click.left}if(e.pageY-this.offset.click.top>this.containment[3]){c=this.containment[3]+this.offset.click.top}}if(h.grid){var g=this.originalPageY+Math.round((c-this.originalPageY)/h.grid[1])*h.grid[1];c=this.containment?(!(g-this.offset.click.topthis.containment[3])?g:(!(g-this.offset.click.topthis.containment[2])?f:(!(f-this.offset.click.left').css({width:this.offsetWidth+"px",height:this.offsetHeight+"px",position:"absolute",opacity:"0.001",zIndex:1000}).css(a(this).offset()).appendTo("body")})},stop:function(b,c){a("div.ui-draggable-iframeFix").each(function(){this.parentNode.removeChild(this)})}});a.ui.plugin.add("draggable","opacity",{start:function(c,d){var b=a(d.helper),e=a(this).data("draggable").options;if(b.css("opacity")){e._opacity=b.css("opacity")}b.css("opacity",e.opacity)},stop:function(b,c){var d=a(this).data("draggable").options;if(d._opacity){a(c.helper).css("opacity",d._opacity)}}});a.ui.plugin.add("draggable","scroll",{start:function(c,d){var b=a(this).data("draggable");if(b.scrollParent[0]!=document&&b.scrollParent[0].tagName!="HTML"){b.overflowOffset=b.scrollParent.offset()}},drag:function(d,e){var c=a(this).data("draggable"),f=c.options,b=false;if(c.scrollParent[0]!=document&&c.scrollParent[0].tagName!="HTML"){if(!f.axis||f.axis!="x"){if((c.overflowOffset.top+c.scrollParent[0].offsetHeight)-d.pageY=0;v--){var s=g.snapElements[v].left,n=s+g.snapElements[v].width,m=g.snapElements[v].top,A=m+g.snapElements[v].height;if(!((s-y=p&&n<=k)||(m>=p&&m<=k)||(nk))&&((e>=g&&e<=c)||(d>=g&&d<=c)||(ec));break;default:return false;break}};a.ui.ddmanager={current:null,droppables:{"default":[]},prepareOffsets:function(e,g){var b=a.ui.ddmanager.droppables[e.options.scope];var f=g?g.type:null;var h=(e.currentItem||e.element).find(":data(droppable)").andSelf();droppablesLoop:for(var d=0;d').css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")}));this.element=this.element.parent().data("resizable",this.element.data("resizable"));this.elementIsWrapper=true;this.element.css({marginLeft:this.originalElement.css("marginLeft"),marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom")});this.originalElement.css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0});this.originalResizeStyle=this.originalElement.css("resize");this.originalElement.css("resize","none");this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"}));this.originalElement.css({margin:this.originalElement.css("margin")});this._proportionallyResize()}this.handles=j.handles||(!c(".ui-resizable-handle",this.element).length?"e,s,se":{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"});if(this.handles.constructor==String){if(this.handles=="all"){this.handles="n,e,s,w,se,sw,ne,nw"}var k=this.handles.split(",");this.handles={};for(var f=0;f');if(/sw|se|ne|nw/.test(h)){g.css({zIndex:++j.zIndex})}if("se"==h){g.addClass("ui-icon ui-icon-gripsmall-diagonal-se")}this.handles[h]=".ui-resizable-"+h;this.element.append(g)}}this._renderAxis=function(p){p=p||this.element;for(var m in this.handles){if(this.handles[m].constructor==String){this.handles[m]=c(this.handles[m],this.element).show()}if(this.elementIsWrapper&&this.originalElement[0].nodeName.match(/textarea|input|select|button/i)){var n=c(this.handles[m],this.element),o=0;o=/sw|ne|nw|se|n|s/.test(m)?n.outerHeight():n.outerWidth();var l=["padding",/ne|nw|n/.test(m)?"Top":/se|sw|s/.test(m)?"Bottom":/^e$/.test(m)?"Right":"Left"].join("");p.css(l,o);this._proportionallyResize()}if(!c(this.handles[m]).length){continue}}};this._renderAxis(this.element);this._handles=c(".ui-resizable-handle",this.element).disableSelection();this._handles.mouseover(function(){if(!e.resizing){if(this.className){var i=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)}e.axis=i&&i[1]?i[1]:"se"}});if(j.autoHide){this._handles.hide();c(this.element).addClass("ui-resizable-autohide").hover(function(){c(this).removeClass("ui-resizable-autohide");e._handles.show()},function(){if(!e.resizing){c(this).addClass("ui-resizable-autohide");e._handles.hide()}})}this._mouseInit()},destroy:function(){this._mouseDestroy();var d=function(f){c(f).removeClass("ui-resizable ui-resizable-disabled ui-resizable-resizing").removeData("resizable").unbind(".resizable").find(".ui-resizable-handle").remove()};if(this.elementIsWrapper){d(this.element);var e=this.element;e.parent().append(this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")})).end().remove()}this.originalElement.css("resize",this.originalResizeStyle);d(this.originalElement)},_mouseCapture:function(e){var f=false;for(var d in this.handles){if(c(this.handles[d])[0]==e.target){f=true}}return this.options.disabled||!!f},_mouseStart:function(f){var i=this.options,e=this.element.position(),d=this.element;this.resizing=true;this.documentScroll={top:c(document).scrollTop(),left:c(document).scrollLeft()};if(d.is(".ui-draggable")||(/absolute/).test(d.css("position"))){d.css({position:"absolute",top:e.top,left:e.left})}if(c.browser.opera&&(/relative/).test(d.css("position"))){d.css({position:"relative",top:"auto",left:"auto"})}this._renderProxy();var j=b(this.helper.css("left")),g=b(this.helper.css("top"));if(i.containment){j+=c(i.containment).scrollLeft()||0;g+=c(i.containment).scrollTop()||0}this.offset=this.helper.offset();this.position={left:j,top:g};this.size=this._helper?{width:d.outerWidth(),height:d.outerHeight()}:{width:d.width(),height:d.height()};this.originalSize=this._helper?{width:d.outerWidth(),height:d.outerHeight()}:{width:d.width(),height:d.height()};this.originalPosition={left:j,top:g};this.sizeDiff={width:d.outerWidth()-d.width(),height:d.outerHeight()-d.height()};this.originalMousePosition={left:f.pageX,top:f.pageY};this.aspectRatio=(typeof i.aspectRatio=="number")?i.aspectRatio:((this.originalSize.width/this.originalSize.height)||1);var h=c(".ui-resizable-"+this.axis).css("cursor");c("body").css("cursor",h=="auto"?this.axis+"-resize":h);d.addClass("ui-resizable-resizing");this._propagate("start",f);return true},_mouseDrag:function(d){var g=this.helper,f=this.options,l={},p=this,i=this.originalMousePosition,m=this.axis;var q=(d.pageX-i.left)||0,n=(d.pageY-i.top)||0;var h=this._change[m];if(!h){return false}var k=h.apply(this,[d,q,n]),j=c.browser.msie&&c.browser.version<7,e=this.sizeDiff;if(this._aspectRatio||d.shiftKey){k=this._updateRatio(k,d)}k=this._respectSize(k,d);this._propagate("resize",d);g.css({top:this.position.top+"px",left:this.position.left+"px",width:this.size.width+"px",height:this.size.height+"px"});if(!this._helper&&this._proportionallyResizeElements.length){this._proportionallyResize()}this._updateCache(k);this._trigger("resize",d,this.ui());return false},_mouseStop:function(g){this.resizing=false;var h=this.options,l=this;if(this._helper){var f=this._proportionallyResizeElements,d=f.length&&(/textarea/i).test(f[0].nodeName),e=d&&c.ui.hasScroll(f[0],"left")?0:l.sizeDiff.height,j=d?0:l.sizeDiff.width;var m={width:(l.size.width-j),height:(l.size.height-e)},i=(parseInt(l.element.css("left"),10)+(l.position.left-l.originalPosition.left))||null,k=(parseInt(l.element.css("top"),10)+(l.position.top-l.originalPosition.top))||null;if(!h.animate){this.element.css(c.extend(m,{top:k,left:i}))}l.helper.height(l.size.height);l.helper.width(l.size.width);if(this._helper&&!h.animate){this._proportionallyResize()}}c("body").css("cursor","auto");this.element.removeClass("ui-resizable-resizing");this._propagate("stop",g);if(this._helper){this.helper.remove()}return false},_updateCache:function(d){var e=this.options;this.offset=this.helper.offset();if(a(d.left)){this.position.left=d.left}if(a(d.top)){this.position.top=d.top}if(a(d.height)){this.size.height=d.height}if(a(d.width)){this.size.width=d.width}},_updateRatio:function(g,f){var h=this.options,i=this.position,e=this.size,d=this.axis;if(g.height){g.width=(e.height*this.aspectRatio)}else{if(g.width){g.height=(e.width/this.aspectRatio)}}if(d=="sw"){g.left=i.left+(e.width-g.width);g.top=null}if(d=="nw"){g.top=i.top+(e.height-g.height);g.left=i.left+(e.width-g.width)}return g},_respectSize:function(k,f){var i=this.helper,h=this.options,q=this._aspectRatio||f.shiftKey,p=this.axis,s=a(k.width)&&h.maxWidth&&(h.maxWidthk.width),r=a(k.height)&&h.minHeight&&(h.minHeight>k.height);if(g){k.width=h.minWidth}if(r){k.height=h.minHeight}if(s){k.width=h.maxWidth}if(l){k.height=h.maxHeight}var e=this.originalPosition.left+this.originalSize.width,n=this.position.top+this.size.height;var j=/sw|nw|w/.test(p),d=/nw|ne|n/.test(p);if(g&&j){k.left=e-h.minWidth}if(s&&j){k.left=e-h.maxWidth}if(r&&d){k.top=n-h.minHeight}if(l&&d){k.top=n-h.maxHeight}var m=!k.width&&!k.height;if(m&&!k.left&&k.top){k.top=null}else{if(m&&!k.top&&k.left){k.left=null}}return k},_proportionallyResize:function(){var j=this.options;if(!this._proportionallyResizeElements.length){return}var f=this.helper||this.element;for(var e=0;e');var d=c.browser.msie&&c.browser.version<7,f=(d?1:0),g=(d?2:-1);this.helper.addClass(this._helper).css({width:this.element.outerWidth()+g,height:this.element.outerHeight()+g,position:"absolute",left:this.elementOffset.left-f+"px",top:this.elementOffset.top-f+"px",zIndex:++h.zIndex});this.helper.appendTo("body").disableSelection()}else{this.helper=this.element}},_change:{e:function(f,e,d){return{width:this.originalSize.width+e}},w:function(g,e,d){var i=this.options,f=this.originalSize,h=this.originalPosition;return{left:h.left+e,width:f.width-e}},n:function(g,e,d){var i=this.options,f=this.originalSize,h=this.originalPosition;return{top:h.top+d,height:f.height-d}},s:function(f,e,d){return{height:this.originalSize.height+d}},se:function(f,e,d){return c.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[f,e,d]))},sw:function(f,e,d){return c.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[f,e,d]))},ne:function(f,e,d){return c.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[f,e,d]))},nw:function(f,e,d){return c.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[f,e,d]))}},_propagate:function(e,d){c.ui.plugin.call(this,e,[d,this.ui()]);(e!="resize"&&this._trigger(e,d,this.ui()))},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}));c.extend(c.ui.resizable,{version:"1.7.3",eventPrefix:"resize",defaults:{alsoResize:false,animate:false,animateDuration:"slow",animateEasing:"swing",aspectRatio:false,autoHide:false,cancel:":input,option",containment:false,delay:0,distance:1,ghost:false,grid:false,handles:"e,s,se",helper:false,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:1000}});c.ui.plugin.add("resizable","alsoResize",{start:function(e,f){var d=c(this).data("resizable"),g=d.options;_store=function(h){c(h).each(function(){c(this).data("resizable-alsoresize",{width:parseInt(c(this).width(),10),height:parseInt(c(this).height(),10),left:parseInt(c(this).css("left"),10),top:parseInt(c(this).css("top"),10)})})};if(typeof(g.alsoResize)=="object"&&!g.alsoResize.parentNode){if(g.alsoResize.length){g.alsoResize=g.alsoResize[0];_store(g.alsoResize)}else{c.each(g.alsoResize,function(h,i){_store(h)})}}else{_store(g.alsoResize)}},resize:function(f,h){var e=c(this).data("resizable"),i=e.options,g=e.originalSize,k=e.originalPosition;var j={height:(e.size.height-g.height)||0,width:(e.size.width-g.width)||0,top:(e.position.top-k.top)||0,left:(e.position.left-k.left)||0},d=function(l,m){c(l).each(function(){var p=c(this),q=c(this).data("resizable-alsoresize"),o={},n=m&&m.length?m:["width","height","top","left"];c.each(n||["width","height","top","left"],function(r,t){var s=(q[t]||0)+(j[t]||0);if(s&&s>=0){o[t]=s||null}});if(/relative/.test(p.css("position"))&&c.browser.opera){e._revertToRelativePosition=true;p.css({position:"absolute",top:"auto",left:"auto"})}p.css(o)})};if(typeof(i.alsoResize)=="object"&&!i.alsoResize.nodeType){c.each(i.alsoResize,function(l,m){d(l,m)})}else{d(i.alsoResize)}},stop:function(e,f){var d=c(this).data("resizable");if(d._revertToRelativePosition&&c.browser.opera){d._revertToRelativePosition=false;el.css({position:"relative"})}c(this).removeData("resizable-alsoresize-start")}});c.ui.plugin.add("resizable","animate",{stop:function(h,m){var n=c(this).data("resizable"),i=n.options;var g=n._proportionallyResizeElements,d=g.length&&(/textarea/i).test(g[0].nodeName),e=d&&c.ui.hasScroll(g[0],"left")?0:n.sizeDiff.height,k=d?0:n.sizeDiff.width;var f={width:(n.size.width-k),height:(n.size.height-e)},j=(parseInt(n.element.css("left"),10)+(n.position.left-n.originalPosition.left))||null,l=(parseInt(n.element.css("top"),10)+(n.position.top-n.originalPosition.top))||null;n.element.animate(c.extend(f,l&&j?{top:l,left:j}:{}),{duration:i.animateDuration,easing:i.animateEasing,step:function(){var o={width:parseInt(n.element.css("width"),10),height:parseInt(n.element.css("height"),10),top:parseInt(n.element.css("top"),10),left:parseInt(n.element.css("left"),10)};if(g&&g.length){c(g[0]).css({width:o.width,height:o.height})}n._updateCache(o);n._propagate("resize",h)}})}});c.ui.plugin.add("resizable","containment",{start:function(e,q){var s=c(this).data("resizable"),i=s.options,k=s.element;var f=i.containment,j=(f instanceof c)?f.get(0):(/parent/.test(f))?k.parent().get(0):f;if(!j){return}s.containerElement=c(j);if(/document/.test(f)||f==document){s.containerOffset={left:0,top:0};s.containerPosition={left:0,top:0};s.parentData={element:c(document),left:0,top:0,width:c(document).width(),height:c(document).height()||document.body.parentNode.scrollHeight}}else{var m=c(j),h=[];c(["Top","Right","Left","Bottom"]).each(function(p,o){h[p]=b(m.css("padding"+o))});s.containerOffset=m.offset();s.containerPosition=m.position();s.containerSize={height:(m.innerHeight()-h[3]),width:(m.innerWidth()-h[1])};var n=s.containerOffset,d=s.containerSize.height,l=s.containerSize.width,g=(c.ui.hasScroll(j,"left")?j.scrollWidth:l),r=(c.ui.hasScroll(j)?j.scrollHeight:d);s.parentData={element:j,left:n.left,top:n.top,width:g,height:r}}},resize:function(f,p){var s=c(this).data("resizable"),h=s.options,e=s.containerSize,n=s.containerOffset,l=s.size,m=s.position,q=s._aspectRatio||f.shiftKey,d={top:0,left:0},g=s.containerElement;if(g[0]!=document&&(/static/).test(g.css("position"))){d=n}if(m.left<(s._helper?n.left:0)){s.size.width=s.size.width+(s._helper?(s.position.left-n.left):(s.position.left-d.left));if(q){s.size.height=s.size.width/h.aspectRatio}s.position.left=h.helper?n.left:0}if(m.top<(s._helper?n.top:0)){s.size.height=s.size.height+(s._helper?(s.position.top-n.top):s.position.top);if(q){s.size.width=s.size.height*h.aspectRatio}s.position.top=s._helper?n.top:0}s.offset.left=s.parentData.left+s.position.left;s.offset.top=s.parentData.top+s.position.top;var k=Math.abs((s._helper?s.offset.left-d.left:(s.offset.left-d.left))+s.sizeDiff.width),r=Math.abs((s._helper?s.offset.top-d.top:(s.offset.top-n.top))+s.sizeDiff.height);var j=s.containerElement.get(0)==s.element.parent().get(0),i=/relative|absolute/.test(s.containerElement.css("position"));if(j&&i){k-=s.parentData.left}if(k+s.size.width>=s.parentData.width){s.size.width=s.parentData.width-k;if(q){s.size.height=s.size.width/s.aspectRatio}}if(r+s.size.height>=s.parentData.height){s.size.height=s.parentData.height-r;if(q){s.size.width=s.size.height*s.aspectRatio}}},stop:function(e,m){var p=c(this).data("resizable"),f=p.options,k=p.position,l=p.containerOffset,d=p.containerPosition,g=p.containerElement;var i=c(p.helper),q=i.offset(),n=i.outerWidth()-p.sizeDiff.width,j=i.outerHeight()-p.sizeDiff.height;if(p._helper&&!f.animate&&(/relative/).test(g.css("position"))){c(this).css({left:q.left-d.left-l.left,width:n,height:j})}if(p._helper&&!f.animate&&(/static/).test(g.css("position"))){c(this).css({left:q.left-d.left-l.left,width:n,height:j})}}});c.ui.plugin.add("resizable","ghost",{start:function(f,g){var d=c(this).data("resizable"),h=d.options,e=d.size;d.ghost=d.originalElement.clone();d.ghost.css({opacity:0.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}).addClass("ui-resizable-ghost").addClass(typeof h.ghost=="string"?h.ghost:"");d.ghost.appendTo(d.helper)},resize:function(e,f){var d=c(this).data("resizable"),g=d.options;if(d.ghost){d.ghost.css({position:"relative",height:d.size.height,width:d.size.width})}},stop:function(e,f){var d=c(this).data("resizable"),g=d.options;if(d.ghost&&d.helper){d.helper.get(0).removeChild(d.ghost.get(0))}}});c.ui.plugin.add("resizable","grid",{resize:function(d,l){var n=c(this).data("resizable"),g=n.options,j=n.size,h=n.originalSize,i=n.originalPosition,m=n.axis,k=g._aspectRatio||d.shiftKey;g.grid=typeof g.grid=="number"?[g.grid,g.grid]:g.grid;var f=Math.round((j.width-h.width)/(g.grid[0]||1))*(g.grid[0]||1),e=Math.round((j.height-h.height)/(g.grid[1]||1))*(g.grid[1]||1);if(/^(se|s|e)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e}else{if(/^(ne)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e;n.position.top=i.top-e}else{if(/^(sw)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e;n.position.left=i.left-f}else{n.size.width=h.width+f;n.size.height=h.height+e;n.position.top=i.top-e;n.position.left=i.left-f}}}}});var b=function(d){return parseInt(d,10)||0};var a=function(d){return !isNaN(parseInt(d,10))}})(jQuery);;/* * jQuery UI Selectable 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Selectables * * Depends: * ui.core.js */ (function(a){a.widget("ui.selectable",a.extend({},a.ui.mouse,{_init:function(){var b=this;this.element.addClass("ui-selectable");this.dragged=false;var c;this.refresh=function(){c=a(b.options.filter,b.element[0]);c.each(function(){var d=a(this);var e=d.offset();a.data(this,"selectable-item",{element:this,$element:d,left:e.left,top:e.top,right:e.left+d.outerWidth(),bottom:e.top+d.outerHeight(),startselected:false,selected:d.hasClass("ui-selected"),selecting:d.hasClass("ui-selecting"),unselecting:d.hasClass("ui-unselecting")})})};this.refresh();this.selectees=c.addClass("ui-selectee");this._mouseInit();this.helper=a(document.createElement("div")).css({border:"1px dotted black"}).addClass("ui-selectable-helper")},destroy:function(){this.element.removeClass("ui-selectable ui-selectable-disabled").removeData("selectable").unbind(".selectable");this._mouseDestroy()},_mouseStart:function(d){var b=this;this.opos=[d.pageX,d.pageY];if(this.options.disabled){return}var c=this.options;this.selectees=a(c.filter,this.element[0]);this._trigger("start",d);a(c.appendTo).append(this.helper);this.helper.css({"z-index":100,position:"absolute",left:d.clientX,top:d.clientY,width:0,height:0});if(c.autoRefresh){this.refresh()}this.selectees.filter(".ui-selected").each(function(){var e=a.data(this,"selectable-item");e.startselected=true;if(!d.metaKey){e.$element.removeClass("ui-selected");e.selected=false;e.$element.addClass("ui-unselecting");e.unselecting=true;b._trigger("unselecting",d,{unselecting:e.element})}});a(d.target).parents().andSelf().each(function(){var e=a.data(this,"selectable-item");if(e){e.$element.removeClass("ui-unselecting").addClass("ui-selecting");e.unselecting=false;e.selecting=true;e.selected=true;b._trigger("selecting",d,{selecting:e.element});return false}})},_mouseDrag:function(i){var c=this;this.dragged=true;if(this.options.disabled){return}var e=this.options;var d=this.opos[0],h=this.opos[1],b=i.pageX,g=i.pageY;if(d>b){var f=b;b=d;d=f}if(h>g){var f=g;g=h;h=f}this.helper.css({left:d,top:h,width:b-d,height:g-h});this.selectees.each(function(){var j=a.data(this,"selectable-item");if(!j||j.element==c.element[0]){return}var k=false;if(e.tolerance=="touch"){k=(!(j.left>b||j.rightg||j.bottomd&&j.righth&&j.bottom=0;b--){this.items[b].item.removeData("sortable-item")}},_mouseCapture:function(e,f){if(this.reverting){return false}if(this.options.disabled||this.options.type=="static"){return false}this._refreshItems(e);var d=null,c=this,b=a(e.target).parents().each(function(){if(a.data(this,"sortable-item")==c){d=a(this);return false}});if(a.data(e.target,"sortable-item")==c){d=a(e.target)}if(!d){return false}if(this.options.handle&&!f){var g=false;a(this.options.handle,d).find("*").andSelf().each(function(){if(this==e.target){g=true}});if(!g){return false}}this.currentItem=d;this._removeCurrentsFromItems();return true},_mouseStart:function(e,f,b){var g=this.options,c=this;this.currentContainer=this;this.refreshPositions();this.helper=this._createHelper(e);this._cacheHelperProportions();this._cacheMargins();this.scrollParent=this.helper.scrollParent();this.offset=this.currentItem.offset();this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left};this.helper.css("position","absolute");this.cssPosition=this.helper.css("position");a.extend(this.offset,{click:{left:e.pageX-this.offset.left,top:e.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()});this.originalPosition=this._generatePosition(e);this.originalPageX=e.pageX;this.originalPageY=e.pageY;if(g.cursorAt){this._adjustOffsetFromHelper(g.cursorAt)}this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]};if(this.helper[0]!=this.currentItem[0]){this.currentItem.hide()}this._createPlaceholder();if(g.containment){this._setContainment()}if(g.cursor){if(a("body").css("cursor")){this._storedCursor=a("body").css("cursor")}a("body").css("cursor",g.cursor)}if(g.opacity){if(this.helper.css("opacity")){this._storedOpacity=this.helper.css("opacity")}this.helper.css("opacity",g.opacity)}if(g.zIndex){if(this.helper.css("zIndex")){this._storedZIndex=this.helper.css("zIndex")}this.helper.css("zIndex",g.zIndex)}if(this.scrollParent[0]!=document&&this.scrollParent[0].tagName!="HTML"){this.overflowOffset=this.scrollParent.offset()}this._trigger("start",e,this._uiHash());if(!this._preserveHelperProportions){this._cacheHelperProportions()}if(!b){for(var d=this.containers.length-1;d>=0;d--){this.containers[d]._trigger("activate",e,c._uiHash(this))}}if(a.ui.ddmanager){a.ui.ddmanager.current=this}if(a.ui.ddmanager&&!g.dropBehaviour){a.ui.ddmanager.prepareOffsets(this,e)}this.dragging=true;this.helper.addClass("ui-sortable-helper");this._mouseDrag(e);return true},_mouseDrag:function(f){this.position=this._generatePosition(f);this.positionAbs=this._convertPositionTo("absolute");if(!this.lastPositionAbs){this.lastPositionAbs=this.positionAbs}if(this.options.scroll){var g=this.options,b=false;if(this.scrollParent[0]!=document&&this.scrollParent[0].tagName!="HTML"){if((this.overflowOffset.top+this.scrollParent[0].offsetHeight)-f.pageY=0;d--){var e=this.items[d],c=e.item[0],h=this._intersectsWithPointer(e);if(!h){continue}if(c!=this.currentItem[0]&&this.placeholder[h==1?"next":"prev"]()[0]!=c&&!a.ui.contains(this.placeholder[0],c)&&(this.options.type=="semi-dynamic"?!a.ui.contains(this.element[0],c):true)){this.direction=h==1?"down":"up";if(this.options.tolerance=="pointer"||this._intersectsWithSides(e)){this._rearrange(f,e)}else{break}this._trigger("change",f,this._uiHash());break}}this._contactContainers(f);if(a.ui.ddmanager){a.ui.ddmanager.drag(this,f)}this._trigger("sort",f,this._uiHash());this.lastPositionAbs=this.positionAbs;return false},_mouseStop:function(c,d){if(!c){return}if(a.ui.ddmanager&&!this.options.dropBehaviour){a.ui.ddmanager.drop(this,c)}if(this.options.revert){var b=this;var e=b.placeholder.offset();b.reverting=true;a(this.helper).animate({left:e.left-this.offset.parent.left-b.margins.left+(this.offsetParent[0]==document.body?0:this.offsetParent[0].scrollLeft),top:e.top-this.offset.parent.top-b.margins.top+(this.offsetParent[0]==document.body?0:this.offsetParent[0].scrollTop)},parseInt(this.options.revert,10)||500,function(){b._clear(c)})}else{this._clear(c,d)}return false},cancel:function(){var b=this;if(this.dragging){this._mouseUp();if(this.options.helper=="original"){this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper")}else{this.currentItem.show()}for(var c=this.containers.length-1;c>=0;c--){this.containers[c]._trigger("deactivate",null,b._uiHash(this));if(this.containers[c].containerCache.over){this.containers[c]._trigger("out",null,b._uiHash(this));this.containers[c].containerCache.over=0}}}if(this.placeholder[0].parentNode){this.placeholder[0].parentNode.removeChild(this.placeholder[0])}if(this.options.helper!="original"&&this.helper&&this.helper[0].parentNode){this.helper.remove()}a.extend(this,{helper:null,dragging:false,reverting:false,_noFinalSort:null});if(this.domPosition.prev){a(this.domPosition.prev).after(this.currentItem)}else{a(this.domPosition.parent).prepend(this.currentItem)}return true},serialize:function(d){var b=this._getItemsAsjQuery(d&&d.connected);var c=[];d=d||{};a(b).each(function(){var e=(a(d.item||this).attr(d.attribute||"id")||"").match(d.expression||(/(.+)[-=_](.+)/));if(e){c.push((d.key||e[1]+"[]")+"="+(d.key&&d.expression?e[1]:e[2]))}});return c.join("&")},toArray:function(d){var b=this._getItemsAsjQuery(d&&d.connected);var c=[];d=d||{};b.each(function(){c.push(a(d.item||this).attr(d.attribute||"id")||"")});return c},_intersectsWith:function(m){var e=this.positionAbs.left,d=e+this.helperProportions.width,k=this.positionAbs.top,j=k+this.helperProportions.height;var f=m.left,c=f+m.width,n=m.top,i=n+m.height;var o=this.offset.click.top,h=this.offset.click.left;var g=(k+o)>n&&(k+o)f&&(e+h)m[this.floating?"width":"height"])){return g}else{return(f0?"down":"up")},_getDragHorizontalDirection:function(){var b=this.positionAbs.left-this.lastPositionAbs.left;return b!=0&&(b>0?"right":"left")},refresh:function(b){this._refreshItems(b);this.refreshPositions()},_connectWith:function(){var b=this.options;return b.connectWith.constructor==String?[b.connectWith]:b.connectWith},_getItemsAsjQuery:function(b){var l=this;var g=[];var e=[];var h=this._connectWith();if(h&&b){for(var d=h.length-1;d>=0;d--){var k=a(h[d]);for(var c=k.length-1;c>=0;c--){var f=a.data(k[c],"sortable");if(f&&f!=this&&!f.options.disabled){e.push([a.isFunction(f.options.items)?f.options.items.call(f.element):a(f.options.items,f.element).not(".ui-sortable-helper"),f])}}}}e.push([a.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):a(this.options.items,this.element).not(".ui-sortable-helper"),this]);for(var d=e.length-1;d>=0;d--){e[d][0].each(function(){g.push(this)})}return a(g)},_removeCurrentsFromItems:function(){var d=this.currentItem.find(":data(sortable-item)");for(var c=0;c=0;e--){var m=a(l[e]);for(var d=m.length-1;d>=0;d--){var g=a.data(m[d],"sortable");if(g&&g!=this&&!g.options.disabled){f.push([a.isFunction(g.options.items)?g.options.items.call(g.element[0],b,{item:this.currentItem}):a(g.options.items,g.element),g]);this.containers.push(g)}}}}for(var e=f.length-1;e>=0;e--){var k=f[e][1];var c=f[e][0];for(var d=0,n=c.length;d=0;d--){var e=this.items[d];if(e.instance!=this.currentContainer&&this.currentContainer&&e.item[0]!=this.currentItem[0]){continue}var c=this.options.toleranceElement?a(this.options.toleranceElement,e.item):e.item;if(!b){e.width=c.outerWidth();e.height=c.outerHeight()}var f=c.offset();e.left=f.left;e.top=f.top}if(this.options.custom&&this.options.custom.refreshContainers){this.options.custom.refreshContainers.call(this)}else{for(var d=this.containers.length-1;d>=0;d--){var f=this.containers[d].element.offset();this.containers[d].containerCache.left=f.left;this.containers[d].containerCache.top=f.top;this.containers[d].containerCache.width=this.containers[d].element.outerWidth();this.containers[d].containerCache.height=this.containers[d].element.outerHeight()}}},_createPlaceholder:function(d){var b=d||this,e=b.options;if(!e.placeholder||e.placeholder.constructor==String){var c=e.placeholder;e.placeholder={element:function(){var f=a(document.createElement(b.currentItem[0].nodeName)).addClass(c||b.currentItem[0].className+" ui-sortable-placeholder").removeClass("ui-sortable-helper")[0];if(!c){f.style.visibility="hidden"}return f},update:function(f,g){if(c&&!e.forcePlaceholderSize){return}if(!g.height()){g.height(b.currentItem.innerHeight()-parseInt(b.currentItem.css("paddingTop")||0,10)-parseInt(b.currentItem.css("paddingBottom")||0,10))}if(!g.width()){g.width(b.currentItem.innerWidth()-parseInt(b.currentItem.css("paddingLeft")||0,10)-parseInt(b.currentItem.css("paddingRight")||0,10))}}}}b.placeholder=a(e.placeholder.element.call(b.element,b.currentItem));b.currentItem.after(b.placeholder);e.placeholder.update(b,b.placeholder)},_contactContainers:function(d){for(var c=this.containers.length-1;c>=0;c--){if(this._intersectsWith(this.containers[c].containerCache)){if(!this.containers[c].containerCache.over){if(this.currentContainer!=this.containers[c]){var h=10000;var g=null;var e=this.positionAbs[this.containers[c].floating?"left":"top"];for(var b=this.items.length-1;b>=0;b--){if(!a.ui.contains(this.containers[c].element[0],this.items[b].item[0])){continue}var f=this.items[b][this.containers[c].floating?"left":"top"];if(Math.abs(f-e)this.containment[2]){d=this.containment[2]+this.offset.click.left}if(e.pageY-this.offset.click.top>this.containment[3]){c=this.containment[3]+this.offset.click.top}}if(h.grid){var g=this.originalPageY+Math.round((c-this.originalPageY)/h.grid[1])*h.grid[1];c=this.containment?(!(g-this.offset.click.topthis.containment[3])?g:(!(g-this.offset.click.topthis.containment[2])?f:(!(f-this.offset.click.left=0;c--){if(a.ui.contains(this.containers[c].element[0],this.currentItem[0])&&!e){f.push((function(g){return function(h){g._trigger("receive",h,this._uiHash(this))}}).call(this,this.containers[c]));f.push((function(g){return function(h){g._trigger("update",h,this._uiHash(this))}}).call(this,this.containers[c]))}}}for(var c=this.containers.length-1;c>=0;c--){if(!e){f.push((function(g){return function(h){g._trigger("deactivate",h,this._uiHash(this))}}).call(this,this.containers[c]))}if(this.containers[c].containerCache.over){f.push((function(g){return function(h){g._trigger("out",h,this._uiHash(this))}}).call(this,this.containers[c]));this.containers[c].containerCache.over=0}}if(this._storedCursor){a("body").css("cursor",this._storedCursor)}if(this._storedOpacity){this.helper.css("opacity",this._storedOpacity)}if(this._storedZIndex){this.helper.css("zIndex",this._storedZIndex=="auto"?"":this._storedZIndex)}this.dragging=false;if(this.cancelHelperRemoval){if(!e){this._trigger("beforeStop",d,this._uiHash());for(var c=0;c *",opacity:false,placeholder:false,revert:false,scroll:true,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1000}})})(jQuery);;/* * jQuery UI Accordion 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Accordion * * Depends: * ui.core.js */ (function(a){a.widget("ui.accordion",{_init:function(){var d=this.options,b=this;this.running=0;if(d.collapsible==a.ui.accordion.defaults.collapsible&&d.alwaysOpen!=a.ui.accordion.defaults.alwaysOpen){d.collapsible=!d.alwaysOpen}if(d.navigation){var c=this.element.find("a").filter(d.navigationFilter);if(c.length){if(c.filter(d.header).length){this.active=c}else{this.active=c.parent().parent().prev();c.addClass("ui-accordion-content-active")}}}this.element.addClass("ui-accordion ui-widget ui-helper-reset");if(this.element[0].nodeName=="UL"){this.element.children("li").addClass("ui-accordion-li-fix")}this.headers=this.element.find(d.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){a(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){a(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){a(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){a(this).removeClass("ui-state-focus")});this.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");this.active=this._findActive(this.active||d.active).toggleClass("ui-state-default").toggleClass("ui-state-active").toggleClass("ui-corner-all").toggleClass("ui-corner-top");this.active.next().addClass("ui-accordion-content-active");a("").addClass("ui-icon "+d.icons.header).prependTo(this.headers);this.active.find(".ui-icon").toggleClass(d.icons.header).toggleClass(d.icons.headerSelected);if(a.browser.msie){this.element.find("a").css("zoom","1")}this.resize();this.element.attr("role","tablist");this.headers.attr("role","tab").bind("keydown",function(e){return b._keydown(e)}).next().attr("role","tabpanel");this.headers.not(this.active||"").attr("aria-expanded","false").attr("tabIndex","-1").next().hide();if(!this.active.length){this.headers.eq(0).attr("tabIndex","0")}else{this.active.attr("aria-expanded","true").attr("tabIndex","0")}if(!a.browser.safari){this.headers.find("a").attr("tabIndex","-1")}if(d.event){this.headers.bind((d.event)+".accordion",function(e){return b._clickHandler.call(b,e,this)})}},destroy:function(){var c=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role").unbind(".accordion").removeData("accordion");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabindex");this.headers.find("a").removeAttr("tabindex");this.headers.children(".ui-icon").remove();var b=this.headers.next().css("display","").removeAttr("role").removeClass("ui-helper-reset ui-widget-content ui-corner-bottom ui-accordion-content ui-accordion-content-active");if(c.autoHeight||c.fillHeight){b.css("height","")}},_setData:function(b,c){if(b=="alwaysOpen"){b="collapsible";c=!c}a.widget.prototype._setData.apply(this,arguments)},_keydown:function(e){var g=this.options,f=a.ui.keyCode;if(g.disabled||e.altKey||e.ctrlKey){return}var d=this.headers.length;var b=this.headers.index(e.target);var c=false;switch(e.keyCode){case f.RIGHT:case f.DOWN:c=this.headers[(b+1)%d];break;case f.LEFT:case f.UP:c=this.headers[(b-1+d)%d];break;case f.SPACE:case f.ENTER:return this._clickHandler({target:e.target},e.target)}if(c){a(e.target).attr("tabIndex","-1");a(c).attr("tabIndex","0");c.focus();return false}return true},resize:function(){var e=this.options,d;if(e.fillSpace){if(a.browser.msie){var b=this.element.parent().css("overflow");this.element.parent().css("overflow","hidden")}d=this.element.parent().height();if(a.browser.msie){this.element.parent().css("overflow",b)}this.headers.each(function(){d-=a(this).outerHeight()});var c=0;this.headers.next().each(function(){c=Math.max(c,a(this).innerHeight()-a(this).height())}).height(Math.max(0,d-c)).css("overflow","auto")}else{if(e.autoHeight){d=0;this.headers.next().each(function(){d=Math.max(d,a(this).outerHeight())}).height(d)}}},activate:function(b){var c=this._findActive(b)[0];this._clickHandler({target:c},c)},_findActive:function(b){return b?typeof b=="number"?this.headers.filter(":eq("+b+")"):this.headers.not(this.headers.not(b)):b===false?a([]):this.headers.filter(":eq(0)")},_clickHandler:function(b,f){var d=this.options;if(d.disabled){return false}if(!b.target&&d.collapsible){this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").find(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);this.active.next().addClass("ui-accordion-content-active");var h=this.active.next(),e={options:d,newHeader:a([]),oldHeader:d.active,newContent:a([]),oldContent:h},c=(this.active=a([]));this._toggle(c,h,e);return false}var g=a(b.currentTarget||f);var i=g[0]==this.active[0];if(this.running||(!d.collapsible&&i)){return false}this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").find(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);this.active.next().addClass("ui-accordion-content-active");if(!i){g.removeClass("ui-state-default ui-corner-all").addClass("ui-state-active ui-corner-top").find(".ui-icon").removeClass(d.icons.header).addClass(d.icons.headerSelected);g.next().addClass("ui-accordion-content-active")}var c=g.next(),h=this.active.next(),e={options:d,newHeader:i&&d.collapsible?a([]):g,oldHeader:this.active,newContent:i&&d.collapsible?a([]):c.find("> *"),oldContent:h.find("> *")},j=this.headers.index(this.active[0])>this.headers.index(g[0]);this.active=i?a([]):g;this._toggle(c,h,e,i,j);return false},_toggle:function(b,i,g,j,k){var d=this.options,m=this;this.toShow=b;this.toHide=i;this.data=g;var c=function(){if(!m){return}return m._completed.apply(m,arguments)};this._trigger("changestart",null,this.data);this.running=i.size()===0?b.size():i.size();if(d.animated){var f={};if(d.collapsible&&j){f={toShow:a([]),toHide:i,complete:c,down:k,autoHeight:d.autoHeight||d.fillSpace}}else{f={toShow:b,toHide:i,complete:c,down:k,autoHeight:d.autoHeight||d.fillSpace}}if(!d.proxied){d.proxied=d.animated}if(!d.proxiedDuration){d.proxiedDuration=d.duration}d.animated=a.isFunction(d.proxied)?d.proxied(f):d.proxied;d.duration=a.isFunction(d.proxiedDuration)?d.proxiedDuration(f):d.proxiedDuration;var l=a.ui.accordion.animations,e=d.duration,h=d.animated;if(!l[h]){l[h]=function(n){this.slide(n,{easing:h,duration:e||700})}}l[h](f)}else{if(d.collapsible&&j){b.toggle()}else{i.hide();b.show()}c(true)}i.prev().attr("aria-expanded","false").attr("tabIndex","-1").blur();b.prev().attr("aria-expanded","true").attr("tabIndex","0").focus()},_completed:function(b){var c=this.options;this.running=b?0:--this.running;if(this.running){return}if(c.clearStyle){this.toShow.add(this.toHide).css({height:"",overflow:""})}this._trigger("change",null,this.data)}});a.extend(a.ui.accordion,{version:"1.7.3",defaults:{active:null,alwaysOpen:true,animated:"slide",autoHeight:true,clearStyle:false,collapsible:false,event:"click",fillSpace:false,header:"> li > :first-child,> :not(li):even",icons:{header:"ui-icon-triangle-1-e",headerSelected:"ui-icon-triangle-1-s"},navigation:false,navigationFilter:function(){return this.href.toLowerCase()==location.href.toLowerCase()}},animations:{slide:function(j,h){j=a.extend({easing:"swing",duration:300},j,h);if(!j.toHide.size()){j.toShow.animate({height:"show"},j);return}if(!j.toShow.size()){j.toHide.animate({height:"hide"},j);return}var c=j.toShow.css("overflow"),g,d={},f={},e=["height","paddingTop","paddingBottom"],b;var i=j.toShow;b=i[0].style.width;i.width(parseInt(i.parent().width(),10)-parseInt(i.css("paddingLeft"),10)-parseInt(i.css("paddingRight"),10)-(parseInt(i.css("borderLeftWidth"),10)||0)-(parseInt(i.css("borderRightWidth"),10)||0));a.each(e,function(k,m){f[m]="hide";var l=(""+a.css(j.toShow[0],m)).match(/^([\d+-.]+)(.*)$/);d[m]={value:l[1],unit:l[2]||"px"}});j.toShow.css({height:0,overflow:"hidden"}).show();j.toHide.filter(":hidden").each(j.complete).end().filter(":visible").animate(f,{step:function(k,l){if(l.prop=="height"){g=(l.now-l.start)/(l.end-l.start)}j.toShow[0].style[l.prop]=(g*d[l.prop].value)+d[l.prop].unit},duration:j.duration,easing:j.easing,complete:function(){if(!j.autoHeight){j.toShow.css("height","")}j.toShow.css("width",b);j.toShow.css({overflow:c});j.complete()}})},bounceslide:function(b){this.slide(b,{easing:b.down?"easeOutBounce":"swing",duration:b.down?1000:200})},easeslide:function(b){this.slide(b,{easing:"easeinout",duration:700})}}})})(jQuery);;/* * jQuery UI Dialog 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Dialog * * Depends: * ui.core.js * ui.draggable.js * ui.resizable.js */ (function(c){var b={dragStart:"start.draggable",drag:"drag.draggable",dragStop:"stop.draggable",maxHeight:"maxHeight.resizable",minHeight:"minHeight.resizable",maxWidth:"maxWidth.resizable",minWidth:"minWidth.resizable",resizeStart:"start.resizable",resize:"drag.resizable",resizeStop:"stop.resizable"},a="ui-dialog ui-widget ui-widget-content ui-corner-all ";c.widget("ui.dialog",{_init:function(){this.originalTitle=this.element.attr("title");var l=this,m=this.options,j=m.title||this.originalTitle||" ",e=c.ui.dialog.getTitleId(this.element),k=(this.uiDialog=c("
")).appendTo(document.body).hide().addClass(a+m.dialogClass).css({position:"absolute",overflow:"hidden",zIndex:m.zIndex}).attr("tabIndex",-1).css("outline",0).keydown(function(n){(m.closeOnEscape&&n.keyCode&&n.keyCode==c.ui.keyCode.ESCAPE&&l.close(n))}).attr({role:"dialog","aria-labelledby":e}).mousedown(function(n){l.moveToTop(false,n)}),g=this.element.show().removeAttr("title").addClass("ui-dialog-content ui-widget-content").appendTo(k),f=(this.uiDialogTitlebar=c("
")).addClass("ui-dialog-titlebar ui-widget-header ui-corner-all ui-helper-clearfix").prependTo(k),i=c('').addClass("ui-dialog-titlebar-close ui-corner-all").attr("role","button").hover(function(){i.addClass("ui-state-hover")},function(){i.removeClass("ui-state-hover")}).focus(function(){i.addClass("ui-state-focus")}).blur(function(){i.removeClass("ui-state-focus")}).mousedown(function(n){n.stopPropagation()}).click(function(n){l.close(n);return false}).appendTo(f),h=(this.uiDialogTitlebarCloseText=c("")).addClass("ui-icon ui-icon-closethick").text(m.closeText).appendTo(i),d=c("").addClass("ui-dialog-title").attr("id",e).html(j).prependTo(f);f.find("*").add(f).disableSelection();(m.draggable&&c.fn.draggable&&this._makeDraggable());(m.resizable&&c.fn.resizable&&this._makeResizable());this._createButtons(m.buttons);this._isOpen=false;(m.bgiframe&&c.fn.bgiframe&&k.bgiframe());(m.autoOpen&&this.open())},destroy:function(){(this.overlay&&this.overlay.destroy());this.uiDialog.hide();this.element.unbind(".dialog").removeData("dialog").removeClass("ui-dialog-content ui-widget-content").hide().appendTo("body");this.uiDialog.remove();(this.originalTitle&&this.element.attr("title",this.originalTitle))},close:function(f){var d=this;if(false===d._trigger("beforeclose",f)){return}(d.overlay&&d.overlay.destroy());d.uiDialog.unbind("keypress.ui-dialog");(d.options.hide?d.uiDialog.hide(d.options.hide,function(){d._trigger("close",f)}):d.uiDialog.hide()&&d._trigger("close",f));c.ui.dialog.overlay.resize();d._isOpen=false;if(d.options.modal){var e=0;c(".ui-dialog").each(function(){if(this!=d.uiDialog[0]){e=Math.max(e,c(this).css("z-index"))}});c.ui.dialog.maxZ=e}},isOpen:function(){return this._isOpen},moveToTop:function(f,e){if((this.options.modal&&!f)||(!this.options.stack&&!this.options.modal)){return this._trigger("focus",e)}if(this.options.zIndex>c.ui.dialog.maxZ){c.ui.dialog.maxZ=this.options.zIndex}(this.overlay&&this.overlay.$el.css("z-index",c.ui.dialog.overlay.maxZ=++c.ui.dialog.maxZ));var d={scrollTop:this.element.attr("scrollTop"),scrollLeft:this.element.attr("scrollLeft")};this.uiDialog.css("z-index",++c.ui.dialog.maxZ);this.element.attr(d);this._trigger("focus",e)},open:function(){if(this._isOpen){return}var e=this.options,d=this.uiDialog;this.overlay=e.modal?new c.ui.dialog.overlay(this):null;(d.next().length&&d.appendTo("body"));this._size();this._position(e.position);d.show(e.show);this.moveToTop(true);(e.modal&&d.bind("keypress.ui-dialog",function(h){if(h.keyCode!=c.ui.keyCode.TAB){return}var g=c(":tabbable",this),i=g.filter(":first")[0],f=g.filter(":last")[0];if(h.target==f&&!h.shiftKey){setTimeout(function(){i.focus()},1)}else{if(h.target==i&&h.shiftKey){setTimeout(function(){f.focus()},1)}}}));c([]).add(d.find(".ui-dialog-content :tabbable:first")).add(d.find(".ui-dialog-buttonpane :tabbable:first")).add(d).filter(":first").focus();this._trigger("open");this._isOpen=true},_createButtons:function(g){var f=this,d=false,e=c("
").addClass("ui-dialog-buttonpane ui-widget-content ui-helper-clearfix");this.uiDialog.find(".ui-dialog-buttonpane").remove();(typeof g=="object"&&g!==null&&c.each(g,function(){return !(d=true)}));if(d){c.each(g,function(h,i){c('').addClass("ui-state-default ui-corner-all").text(h).click(function(){i.apply(f.element[0],arguments)}).hover(function(){c(this).addClass("ui-state-hover")},function(){c(this).removeClass("ui-state-hover")}).focus(function(){c(this).addClass("ui-state-focus")}).blur(function(){c(this).removeClass("ui-state-focus")}).appendTo(e)});e.appendTo(this.uiDialog)}},_makeDraggable:function(){var d=this,f=this.options,e;this.uiDialog.draggable({cancel:".ui-dialog-content",handle:".ui-dialog-titlebar",containment:"document",start:function(){e=f.height;c(this).height(c(this).height()).addClass("ui-dialog-dragging");(f.dragStart&&f.dragStart.apply(d.element[0],arguments))},drag:function(){(f.drag&&f.drag.apply(d.element[0],arguments))},stop:function(){c(this).removeClass("ui-dialog-dragging").height(e);(f.dragStop&&f.dragStop.apply(d.element[0],arguments));c.ui.dialog.overlay.resize()}})},_makeResizable:function(g){g=(g===undefined?this.options.resizable:g);var d=this,f=this.options,e=typeof g=="string"?g:"n,e,s,w,se,sw,ne,nw";this.uiDialog.resizable({cancel:".ui-dialog-content",alsoResize:this.element,maxWidth:f.maxWidth,maxHeight:f.maxHeight,minWidth:f.minWidth,minHeight:f.minHeight,start:function(){c(this).addClass("ui-dialog-resizing");(f.resizeStart&&f.resizeStart.apply(d.element[0],arguments))},resize:function(){(f.resize&&f.resize.apply(d.element[0],arguments))},handles:e,stop:function(){c(this).removeClass("ui-dialog-resizing");f.height=c(this).height();f.width=c(this).width();(f.resizeStop&&f.resizeStop.apply(d.element[0],arguments));c.ui.dialog.overlay.resize()}}).find(".ui-resizable-se").addClass("ui-icon ui-icon-grip-diagonal-se")},_position:function(i){var e=c(window),f=c(document),g=f.scrollTop(),d=f.scrollLeft(),h=g;if(c.inArray(i,["center","top","right","bottom","left"])>=0){i=[i=="right"||i=="left"?i:"center",i=="top"||i=="bottom"?i:"middle"]}if(i.constructor!=Array){i=["center","middle"]}if(i[0].constructor==Number){d+=i[0]}else{switch(i[0]){case"left":d+=0;break;case"right":d+=e.width()-this.uiDialog.outerWidth();break;default:case"center":d+=(e.width()-this.uiDialog.outerWidth())/2}}if(i[1].constructor==Number){g+=i[1]}else{switch(i[1]){case"top":g+=0;break;case"bottom":g+=e.height()-this.uiDialog.outerHeight();break;default:case"middle":g+=(e.height()-this.uiDialog.outerHeight())/2}}g=Math.max(g,h);this.uiDialog.css({top:g,left:d})},_setData:function(e,f){(b[e]&&this.uiDialog.data(b[e],f));switch(e){case"buttons":this._createButtons(f);break;case"closeText":this.uiDialogTitlebarCloseText.text(f);break;case"dialogClass":this.uiDialog.removeClass(this.options.dialogClass).addClass(a+f);break;case"draggable":(f?this._makeDraggable():this.uiDialog.draggable("destroy"));break;case"height":this.uiDialog.height(f);break;case"position":this._position(f);break;case"resizable":var d=this.uiDialog,g=this.uiDialog.is(":data(resizable)");(g&&!f&&d.resizable("destroy"));(g&&typeof f=="string"&&d.resizable("option","handles",f));(g||this._makeResizable(f));break;case"title":c(".ui-dialog-title",this.uiDialogTitlebar).html(f||" ");break;case"width":this.uiDialog.width(f);break}c.widget.prototype._setData.apply(this,arguments)},_size:function(){var e=this.options;this.element.css({height:0,minHeight:0,width:"auto"});var d=this.uiDialog.css({height:"auto",width:e.width}).height();this.element.css({minHeight:Math.max(e.minHeight-d,0),height:e.height=="auto"?"auto":Math.max(e.height-d,0)})}});c.extend(c.ui.dialog,{version:"1.7.3",defaults:{autoOpen:true,bgiframe:false,buttons:{},closeOnEscape:true,closeText:"close",dialogClass:"",draggable:true,hide:null,height:"auto",maxHeight:false,maxWidth:false,minHeight:150,minWidth:150,modal:false,position:"center",resizable:true,show:null,stack:true,title:"",width:300,zIndex:1000},getter:"isOpen",uuid:0,maxZ:0,getTitleId:function(d){return"ui-dialog-title-"+(d.attr("id")||++this.uuid)},overlay:function(d){this.$el=c.ui.dialog.overlay.create(d)}});c.extend(c.ui.dialog.overlay,{instances:[],maxZ:0,events:c.map("focus,mousedown,mouseup,keydown,keypress,click".split(","),function(d){return d+".dialog-overlay"}).join(" "),create:function(e){if(this.instances.length===0){setTimeout(function(){if(c.ui.dialog.overlay.instances.length){c(document).bind(c.ui.dialog.overlay.events,function(f){var g=c(f.target).parents(".ui-dialog").css("zIndex")||0;return(g>c.ui.dialog.overlay.maxZ)})}},1);c(document).bind("keydown.dialog-overlay",function(f){(e.options.closeOnEscape&&f.keyCode&&f.keyCode==c.ui.keyCode.ESCAPE&&e.close(f))});c(window).bind("resize.dialog-overlay",c.ui.dialog.overlay.resize)}var d=c("
").appendTo(document.body).addClass("ui-widget-overlay").css({width:this.width(),height:this.height()});(e.options.bgiframe&&c.fn.bgiframe&&d.bgiframe());this.instances.push(d);return d},destroy:function(d){this.instances.splice(c.inArray(this.instances,d),1);if(this.instances.length===0){c([document,window]).unbind(".dialog-overlay")}d.remove();var e=0;c.each(this.instances,function(){e=Math.max(e,this.css("z-index"))});this.maxZ=e},height:function(){if(c.browser.msie&&c.browser.version<7){var e=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);var d=Math.max(document.documentElement.offsetHeight,document.body.offsetHeight);if(e
");if(!c.values){c.values=[this._valueMin(),this._valueMin()]}if(c.values.length&&c.values.length!=2){c.values=[c.values[0],c.values[0]]}}else{this.range=a("
")}this.range.appendTo(this.element).addClass("ui-slider-range");if(c.range=="min"||c.range=="max"){this.range.addClass("ui-slider-range-"+c.range)}this.range.addClass("ui-widget-header")}if(a(".ui-slider-handle",this.element).length==0){a('
').appendTo(this.element).addClass("ui-slider-handle")}if(c.values&&c.values.length){while(a(".ui-slider-handle",this.element).length').appendTo(this.element).addClass("ui-slider-handle")}}this.handles=a(".ui-slider-handle",this.element).addClass("ui-state-default ui-corner-all");this.handle=this.handles.eq(0);this.handles.add(this.range).filter("a").click(function(d){d.preventDefault()}).hover(function(){if(!c.disabled){a(this).addClass("ui-state-hover")}},function(){a(this).removeClass("ui-state-hover")}).focus(function(){if(!c.disabled){a(".ui-slider .ui-state-focus").removeClass("ui-state-focus");a(this).addClass("ui-state-focus")}else{a(this).blur()}}).blur(function(){a(this).removeClass("ui-state-focus")});this.handles.each(function(d){a(this).data("index.ui-slider-handle",d)});this.handles.keydown(function(i){var f=true;var e=a(this).data("index.ui-slider-handle");if(b.options.disabled){return}switch(i.keyCode){case a.ui.keyCode.HOME:case a.ui.keyCode.END:case a.ui.keyCode.UP:case a.ui.keyCode.RIGHT:case a.ui.keyCode.DOWN:case a.ui.keyCode.LEFT:f=false;if(!b._keySliding){b._keySliding=true;a(this).addClass("ui-state-active");b._start(i,e)}break}var g,d,h=b._step();if(b.options.values&&b.options.values.length){g=d=b.values(e)}else{g=d=b.value()}switch(i.keyCode){case a.ui.keyCode.HOME:d=b._valueMin();break;case a.ui.keyCode.END:d=b._valueMax();break;case a.ui.keyCode.UP:case a.ui.keyCode.RIGHT:if(g==b._valueMax()){return}d=g+h;break;case a.ui.keyCode.DOWN:case a.ui.keyCode.LEFT:if(g==b._valueMin()){return}d=g-h;break}b._slide(i,e,d);return f}).keyup(function(e){var d=a(this).data("index.ui-slider-handle");if(b._keySliding){b._stop(e,d);b._change(e,d);b._keySliding=false;a(this).removeClass("ui-state-active")}});this._refreshValue()},destroy:function(){this.handles.remove();this.range.remove();this.element.removeClass("ui-slider ui-slider-horizontal ui-slider-vertical ui-slider-disabled ui-widget ui-widget-content ui-corner-all").removeData("slider").unbind(".slider");this._mouseDestroy()},_mouseCapture:function(d){var e=this.options;if(e.disabled){return false}this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()};this.elementOffset=this.element.offset();var h={x:d.pageX,y:d.pageY};var j=this._normValueFromMouse(h);var c=this._valueMax()-this._valueMin()+1,f;var k=this,i;this.handles.each(function(l){var m=Math.abs(j-k.values(l));if(c>m){c=m;f=a(this);i=l}});if(e.range==true&&this.values(1)==e.min){f=a(this.handles[++i])}this._start(d,i);k._handleIndex=i;f.addClass("ui-state-active").focus();var g=f.offset();var b=!a(d.target).parents().andSelf().is(".ui-slider-handle");this._clickOffset=b?{left:0,top:0}:{left:d.pageX-g.left-(f.width()/2),top:d.pageY-g.top-(f.height()/2)-(parseInt(f.css("borderTopWidth"),10)||0)-(parseInt(f.css("borderBottomWidth"),10)||0)+(parseInt(f.css("marginTop"),10)||0)};j=this._normValueFromMouse(h);this._slide(d,i,j);return true},_mouseStart:function(b){return true},_mouseDrag:function(d){var b={x:d.pageX,y:d.pageY};var c=this._normValueFromMouse(b);this._slide(d,this._handleIndex,c);return false},_mouseStop:function(b){this.handles.removeClass("ui-state-active");this._stop(b,this._handleIndex);this._change(b,this._handleIndex);this._handleIndex=null;this._clickOffset=null;return false},_detectOrientation:function(){this.orientation=this.options.orientation=="vertical"?"vertical":"horizontal"},_normValueFromMouse:function(d){var c,h;if("horizontal"==this.orientation){c=this.elementSize.width;h=d.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)}else{c=this.elementSize.height;h=d.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)}var f=(h/c);if(f>1){f=1}if(f<0){f=0}if("vertical"==this.orientation){f=1-f}var e=this._valueMax()-this._valueMin(),i=f*e,b=i%this.options.step,g=this._valueMin()+i-b;if(b>(this.options.step/2)){g+=this.options.step}return parseFloat(g.toFixed(5))},_start:function(d,c){var b={handle:this.handles[c],value:this.value()};if(this.options.values&&this.options.values.length){b.value=this.values(c);b.values=this.values()}this._trigger("start",d,b)},_slide:function(f,e,d){var g=this.handles[e];if(this.options.values&&this.options.values.length){var b=this.values(e?0:1);if((this.options.values.length==2&&this.options.range===true)&&((e==0&&d>b)||(e==1&&d1){this.options.values[b]=e;this._refreshValue(c);if(!d){this._change(null,b)}}if(arguments.length){if(this.options.values&&this.options.values.length){return this._values(b)}else{return this.value()}}else{return this._values()}},_setData:function(b,d,c){a.widget.prototype._setData.apply(this,arguments);switch(b){case"disabled":if(d){this.handles.filter(".ui-state-focus").blur();this.handles.removeClass("ui-state-hover");this.handles.attr("disabled","disabled")}else{this.handles.removeAttr("disabled")}case"orientation":this._detectOrientation();this.element.removeClass("ui-slider-horizontal ui-slider-vertical").addClass("ui-slider-"+this.orientation);this._refreshValue(c);break;case"value":this._refreshValue(c);break}},_step:function(){var b=this.options.step;return b},_value:function(){var b=this.options.value;if(bthis._valueMax()){b=this._valueMax()}return b},_values:function(b){if(arguments.length){var c=this.options.values[b];if(cthis._valueMax()){c=this._valueMax()}return c}else{return this.options.values}},_valueMin:function(){var b=this.options.min;return b},_valueMax:function(){var b=this.options.max;return b},_refreshValue:function(c){var f=this.options.range,d=this.options,l=this;if(this.options.values&&this.options.values.length){var i,h;this.handles.each(function(p,n){var o=(l.values(p)-l._valueMin())/(l._valueMax()-l._valueMin())*100;var m={};m[l.orientation=="horizontal"?"left":"bottom"]=o+"%";a(this).stop(1,1)[c?"animate":"css"](m,d.animate);if(l.options.range===true){if(l.orientation=="horizontal"){(p==0)&&l.range.stop(1,1)[c?"animate":"css"]({left:o+"%"},d.animate);(p==1)&&l.range[c?"animate":"css"]({width:(o-lastValPercent)+"%"},{queue:false,duration:d.animate})}else{(p==0)&&l.range.stop(1,1)[c?"animate":"css"]({bottom:(o)+"%"},d.animate);(p==1)&&l.range[c?"animate":"css"]({height:(o-lastValPercent)+"%"},{queue:false,duration:d.animate})}}lastValPercent=o})}else{var j=this.value(),g=this._valueMin(),k=this._valueMax(),e=k!=g?(j-g)/(k-g)*100:0;var b={};b[l.orientation=="horizontal"?"left":"bottom"]=e+"%";this.handle.stop(1,1)[c?"animate":"css"](b,d.animate);(f=="min")&&(this.orientation=="horizontal")&&this.range.stop(1,1)[c?"animate":"css"]({width:e+"%"},d.animate);(f=="max")&&(this.orientation=="horizontal")&&this.range[c?"animate":"css"]({width:(100-e)+"%"},{queue:false,duration:d.animate});(f=="min")&&(this.orientation=="vertical")&&this.range.stop(1,1)[c?"animate":"css"]({height:e+"%"},d.animate);(f=="max")&&(this.orientation=="vertical")&&this.range[c?"animate":"css"]({height:(100-e)+"%"},{queue:false,duration:d.animate})}}}));a.extend(a.ui.slider,{getter:"value values",version:"1.7.3",eventPrefix:"slide",defaults:{animate:false,delay:0,distance:0,max:100,min:0,orientation:"horizontal",range:false,step:1,value:0,values:null}})})(jQuery);;/* * jQuery UI Tabs 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Tabs * * Depends: * ui.core.js */ (function(c){var b=0,a=0;c.widget("ui.tabs",{_init:function(){if(this.options.deselectable!==undefined){this.options.collapsible=this.options.deselectable}this._tabify(true)},_setData:function(d,e){if(d=="selected"){if(this.options.collapsible&&e==this.options.selected){return}this.select(e)}else{this.options[d]=e;if(d=="deselectable"){this.options.collapsible=e}this._tabify()}},_tabId:function(d){return d.title&&d.title.replace(/\s/g,"_").replace(/[^A-Za-z0-9\-_:\.]/g,"")||this.options.idPrefix+(++b)},_sanitizeSelector:function(d){return d.replace(/:/g,"\\:")},_cookie:function(){var d=this.cookie||(this.cookie=this.options.cookie.name||"ui-tabs-"+(++a));return c.cookie.apply(null,[d].concat(c.makeArray(arguments)))},_ui:function(e,d){return{tab:e,panel:d,index:this.anchors.index(e)}},_cleanup:function(){this.lis.filter(".ui-state-processing").removeClass("ui-state-processing").find("span:data(label.tabs)").each(function(){var d=c(this);d.html(d.data("label.tabs")).removeData("label.tabs")})},_tabify:function(q){this.list=this.element.children("ul:first");this.lis=c("li:has(a[href])",this.list);this.anchors=this.lis.map(function(){return c("a",this)[0]});this.panels=c([]);var r=this,f=this.options;var e=/^#.+/;this.anchors.each(function(u,o){var s=c(o).attr("href");var v=s.split("#")[0],w;if(v&&(v===location.toString().split("#")[0]||(w=c("base")[0])&&v===w.href)){s=o.hash;o.href=s}if(e.test(s)){r.panels=r.panels.add(r._sanitizeSelector(s))}else{if(s!="#"){c.data(o,"href.tabs",s);c.data(o,"load.tabs",s.replace(/#.*$/,""));var y=r._tabId(o);o.href="#"+y;var x=c("#"+y);if(!x.length){x=c(f.panelTemplate).attr("id",y).addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").insertAfter(r.panels[u-1]||r.list);x.data("destroy.tabs",true)}r.panels=r.panels.add(x)}else{f.disabled.push(u)}}});if(q){this.element.addClass("ui-tabs ui-widget ui-widget-content ui-corner-all");this.list.addClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all");this.lis.addClass("ui-state-default ui-corner-top");this.panels.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom");if(f.selected===undefined){if(location.hash){this.anchors.each(function(s,o){if(o.hash==location.hash){f.selected=s;return false}})}if(typeof f.selected!="number"&&f.cookie){f.selected=parseInt(r._cookie(),10)}if(typeof f.selected!="number"&&this.lis.filter(".ui-tabs-selected").length){f.selected=this.lis.index(this.lis.filter(".ui-tabs-selected"))}f.selected=f.selected||0}else{if(f.selected===null){f.selected=-1}}f.selected=((f.selected>=0&&this.anchors[f.selected])||f.selected<0)?f.selected:0;f.disabled=c.unique(f.disabled.concat(c.map(this.lis.filter(".ui-state-disabled"),function(s,o){return r.lis.index(s)}))).sort();if(c.inArray(f.selected,f.disabled)!=-1){f.disabled.splice(c.inArray(f.selected,f.disabled),1)}this.panels.addClass("ui-tabs-hide");this.lis.removeClass("ui-tabs-selected ui-state-active");if(f.selected>=0&&this.anchors.length){this.panels.eq(f.selected).removeClass("ui-tabs-hide");this.lis.eq(f.selected).addClass("ui-tabs-selected ui-state-active");r.element.queue("tabs",function(){r._trigger("show",null,r._ui(r.anchors[f.selected],r.panels[f.selected]))});this.load(f.selected)}c(window).bind("unload",function(){r.lis.add(r.anchors).unbind(".tabs");r.lis=r.anchors=r.panels=null})}else{f.selected=this.lis.index(this.lis.filter(".ui-tabs-selected"))}this.element[f.collapsible?"addClass":"removeClass"]("ui-tabs-collapsible");if(f.cookie){this._cookie(f.selected,f.cookie)}for(var j=0,p;(p=this.lis[j]);j++){c(p)[c.inArray(j,f.disabled)!=-1&&!c(p).hasClass("ui-tabs-selected")?"addClass":"removeClass"]("ui-state-disabled")}if(f.cache===false){this.anchors.removeData("cache.tabs")}this.lis.add(this.anchors).unbind(".tabs");if(f.event!="mouseover"){var h=function(o,i){if(i.is(":not(.ui-state-disabled)")){i.addClass("ui-state-"+o)}};var l=function(o,i){i.removeClass("ui-state-"+o)};this.lis.bind("mouseover.tabs",function(){h("hover",c(this))});this.lis.bind("mouseout.tabs",function(){l("hover",c(this))});this.anchors.bind("focus.tabs",function(){h("focus",c(this).closest("li"))});this.anchors.bind("blur.tabs",function(){l("focus",c(this).closest("li"))})}var d,k;if(f.fx){if(c.isArray(f.fx)){d=f.fx[0];k=f.fx[1]}else{d=k=f.fx}}function g(i,o){i.css({display:""});if(c.browser.msie&&o.opacity){i[0].style.removeAttribute("filter")}}var m=k?function(i,o){c(i).closest("li").removeClass("ui-state-default").addClass("ui-tabs-selected ui-state-active");o.hide().removeClass("ui-tabs-hide").animate(k,k.duration||"normal",function(){g(o,k);r._trigger("show",null,r._ui(i,o[0]))})}:function(i,o){c(i).closest("li").removeClass("ui-state-default").addClass("ui-tabs-selected ui-state-active");o.removeClass("ui-tabs-hide");r._trigger("show",null,r._ui(i,o[0]))};var n=d?function(o,i){i.animate(d,d.duration||"normal",function(){r.lis.removeClass("ui-tabs-selected ui-state-active").addClass("ui-state-default");i.addClass("ui-tabs-hide");g(i,d);r.element.dequeue("tabs")})}:function(o,i,s){r.lis.removeClass("ui-tabs-selected ui-state-active").addClass("ui-state-default");i.addClass("ui-tabs-hide");r.element.dequeue("tabs")};this.anchors.bind(f.event+".tabs",function(){var o=this,u=c(this).closest("li"),i=r.panels.filter(":not(.ui-tabs-hide)"),s=c(r._sanitizeSelector(this.hash));if((u.hasClass("ui-tabs-selected")&&!f.collapsible)||u.hasClass("ui-state-disabled")||u.hasClass("ui-state-processing")||r._trigger("select",null,r._ui(this,s[0]))===false){this.blur();return false}f.selected=r.anchors.index(this);r.abort();if(f.collapsible){if(u.hasClass("ui-tabs-selected")){f.selected=-1;if(f.cookie){r._cookie(f.selected,f.cookie)}r.element.queue("tabs",function(){n(o,i)}).dequeue("tabs");this.blur();return false}else{if(!i.length){if(f.cookie){r._cookie(f.selected,f.cookie)}r.element.queue("tabs",function(){m(o,s)});r.load(r.anchors.index(this));this.blur();return false}}}if(f.cookie){r._cookie(f.selected,f.cookie)}if(s.length){if(i.length){r.element.queue("tabs",function(){n(o,i)})}r.element.queue("tabs",function(){m(o,s)});r.load(r.anchors.index(this))}else{throw"jQuery UI Tabs: Mismatching fragment identifier."}if(c.browser.msie){this.blur()}});this.anchors.bind("click.tabs",function(){return false})},destroy:function(){var d=this.options;this.abort();this.element.unbind(".tabs").removeClass("ui-tabs ui-widget ui-widget-content ui-corner-all ui-tabs-collapsible").removeData("tabs");this.list.removeClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all");this.anchors.each(function(){var e=c.data(this,"href.tabs");if(e){this.href=e}var f=c(this).unbind(".tabs");c.each(["href","load","cache"],function(g,h){f.removeData(h+".tabs")})});this.lis.unbind(".tabs").add(this.panels).each(function(){if(c.data(this,"destroy.tabs")){c(this).remove()}else{c(this).removeClass(["ui-state-default","ui-corner-top","ui-tabs-selected","ui-state-active","ui-state-hover","ui-state-focus","ui-state-disabled","ui-tabs-panel","ui-widget-content","ui-corner-bottom","ui-tabs-hide"].join(" "))}});if(d.cookie){this._cookie(null,d.cookie)}},add:function(g,f,e){if(e===undefined){e=this.anchors.length}var d=this,i=this.options,k=c(i.tabTemplate.replace(/#\{href\}/g,g).replace(/#\{label\}/g,f)),j=!g.indexOf("#")?g.replace("#",""):this._tabId(c("a",k)[0]);k.addClass("ui-state-default ui-corner-top").data("destroy.tabs",true);var h=c("#"+j);if(!h.length){h=c(i.panelTemplate).attr("id",j).data("destroy.tabs",true)}h.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom ui-tabs-hide");if(e>=this.lis.length){k.appendTo(this.list);h.appendTo(this.list[0].parentNode)}else{k.insertBefore(this.lis[e]);h.insertBefore(this.panels[e])}i.disabled=c.map(i.disabled,function(m,l){return m>=e?++m:m});this._tabify();if(this.anchors.length==1){k.addClass("ui-tabs-selected ui-state-active");h.removeClass("ui-tabs-hide");this.element.queue("tabs",function(){d._trigger("show",null,d._ui(d.anchors[0],d.panels[0]))});this.load(0)}this._trigger("add",null,this._ui(this.anchors[e],this.panels[e]))},remove:function(d){var f=this.options,g=this.lis.eq(d).remove(),e=this.panels.eq(d).remove();if(g.hasClass("ui-tabs-selected")&&this.anchors.length>1){this.select(d+(d+1=d?--j:j});this._tabify();this._trigger("remove",null,this._ui(g.find("a")[0],e[0]))},enable:function(d){var e=this.options;if(c.inArray(d,e.disabled)==-1){return}this.lis.eq(d).removeClass("ui-state-disabled");e.disabled=c.grep(e.disabled,function(g,f){return g!=d});this._trigger("enable",null,this._ui(this.anchors[d],this.panels[d]))},disable:function(e){var d=this,f=this.options;if(e!=f.selected){this.lis.eq(e).addClass("ui-state-disabled");f.disabled.push(e);f.disabled.sort();this._trigger("disable",null,this._ui(this.anchors[e],this.panels[e]))}},select:function(d){if(typeof d=="string"){d=this.anchors.index(this.anchors.filter("[href$="+d+"]"))}else{if(d===null){d=-1}}if(d==-1&&this.options.collapsible){d=this.options.selected}this.anchors.eq(d).trigger(this.options.event+".tabs")},load:function(g){var e=this,i=this.options,d=this.anchors.eq(g)[0],f=c.data(d,"load.tabs");this.abort();if(!f||this.element.queue("tabs").length!==0&&c.data(d,"cache.tabs")){this.element.dequeue("tabs");return}this.lis.eq(g).addClass("ui-state-processing");if(i.spinner){var h=c("span",d);h.data("label.tabs",h.html()).html(i.spinner)}this.xhr=c.ajax(c.extend({},i.ajaxOptions,{url:f,success:function(k,j){c(e._sanitizeSelector(d.hash)).html(k);e._cleanup();if(i.cache){c.data(d,"cache.tabs",true)}e._trigger("load",null,e._ui(e.anchors[g],e.panels[g]));try{i.ajaxOptions.success(k,j)}catch(l){}e.element.dequeue("tabs")}}))},abort:function(){this.element.queue([]);this.panels.stop(false,true);if(this.xhr){this.xhr.abort();delete this.xhr}this._cleanup()},url:function(e,d){this.anchors.eq(e).removeData("cache.tabs").data("load.tabs",d)},length:function(){return this.anchors.length}});c.extend(c.ui.tabs,{version:"1.7.3",getter:"length",defaults:{ajaxOptions:null,cache:false,cookie:null,collapsible:false,disabled:[],event:"click",fx:null,idPrefix:"ui-tabs-",panelTemplate:"
",spinner:"Loading…",tabTemplate:'
  • #{label}
  • '}});c.extend(c.ui.tabs.prototype,{rotation:null,rotate:function(f,h){var d=this,i=this.options;var e=d._rotate||(d._rotate=function(j){clearTimeout(d.rotation);d.rotation=setTimeout(function(){var k=i.selected;d.select(++k')}$.extend(Datepicker.prototype,{markerClassName:"hasDatepicker",log:function(){if(this.debug){console.log.apply("",arguments)}},setDefaults:function(settings){extendRemove(this._defaults,settings||{});return this},_attachDatepicker:function(target,settings){var inlineSettings=null;for(var attrName in this._defaults){var attrValue=target.getAttribute("date:"+attrName);if(attrValue){inlineSettings=inlineSettings||{};try{inlineSettings[attrName]=eval(attrValue)}catch(err){inlineSettings[attrName]=attrValue}}}var nodeName=target.nodeName.toLowerCase();var inline=(nodeName=="div"||nodeName=="span");if(!target.id){target.id="dp"+(++this.uuid)}var inst=this._newInst($(target),inline);inst.settings=$.extend({},settings||{},inlineSettings||{});if(nodeName=="input"){this._connectDatepicker(target,inst)}else{if(inline){this._inlineDatepicker(target,inst)}}},_newInst:function(target,inline){var id=target[0].id.replace(/([:\[\]\.])/g,"\\\\$1");return{id:id,input:target,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:inline,dpDiv:(!inline?this.dpDiv:$('
    '))}},_connectDatepicker:function(target,inst){var input=$(target);inst.append=$([]);inst.trigger=$([]);if(input.hasClass(this.markerClassName)){return}var appendText=this._get(inst,"appendText");var isRTL=this._get(inst,"isRTL");if(appendText){inst.append=$(''+appendText+"");input[isRTL?"before":"after"](inst.append)}var showOn=this._get(inst,"showOn");if(showOn=="focus"||showOn=="both"){input.focus(this._showDatepicker)}if(showOn=="button"||showOn=="both"){var buttonText=this._get(inst,"buttonText");var buttonImage=this._get(inst,"buttonImage");inst.trigger=$(this._get(inst,"buttonImageOnly")?$("").addClass(this._triggerClass).attr({src:buttonImage,alt:buttonText,title:buttonText}):$('').addClass(this._triggerClass).html(buttonImage==""?buttonText:$("").attr({src:buttonImage,alt:buttonText,title:buttonText})));input[isRTL?"before":"after"](inst.trigger);inst.trigger.click(function(){if($.datepicker._datepickerShowing&&$.datepicker._lastInput==target){$.datepicker._hideDatepicker()}else{$.datepicker._showDatepicker(target)}return false})}input.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).bind("setData.datepicker",function(event,key,value){inst.settings[key]=value}).bind("getData.datepicker",function(event,key){return this._get(inst,key)});$.data(target,PROP_NAME,inst)},_inlineDatepicker:function(target,inst){var divSpan=$(target);if(divSpan.hasClass(this.markerClassName)){return}divSpan.addClass(this.markerClassName).append(inst.dpDiv).bind("setData.datepicker",function(event,key,value){inst.settings[key]=value}).bind("getData.datepicker",function(event,key){return this._get(inst,key)});$.data(target,PROP_NAME,inst);this._setDate(inst,this._getDefaultDate(inst));this._updateDatepicker(inst);this._updateAlternate(inst)},_dialogDatepicker:function(input,dateText,onSelect,settings,pos){var inst=this._dialogInst;if(!inst){var id="dp"+(++this.uuid);this._dialogInput=$('');this._dialogInput.keydown(this._doKeyDown);$("body").append(this._dialogInput);inst=this._dialogInst=this._newInst(this._dialogInput,false);inst.settings={};$.data(this._dialogInput[0],PROP_NAME,inst)}extendRemove(inst.settings,settings||{});this._dialogInput.val(dateText);this._pos=(pos?(pos.length?pos:[pos.pageX,pos.pageY]):null);if(!this._pos){var browserWidth=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;var browserHeight=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;var scrollX=document.documentElement.scrollLeft||document.body.scrollLeft;var scrollY=document.documentElement.scrollTop||document.body.scrollTop;this._pos=[(browserWidth/2)-100+scrollX,(browserHeight/2)-150+scrollY]}this._dialogInput.css("left",this._pos[0]+"px").css("top",this._pos[1]+"px");inst.settings.onSelect=onSelect;this._inDialog=true;this.dpDiv.addClass(this._dialogClass);this._showDatepicker(this._dialogInput[0]);if($.blockUI){$.blockUI(this.dpDiv)}$.data(this._dialogInput[0],PROP_NAME,inst);return this},_destroyDatepicker:function(target){var $target=$(target);var inst=$.data(target,PROP_NAME);if(!$target.hasClass(this.markerClassName)){return}var nodeName=target.nodeName.toLowerCase();$.removeData(target,PROP_NAME);if(nodeName=="input"){inst.append.remove();inst.trigger.remove();$target.removeClass(this.markerClassName).unbind("focus",this._showDatepicker).unbind("keydown",this._doKeyDown).unbind("keypress",this._doKeyPress)}else{if(nodeName=="div"||nodeName=="span"){$target.removeClass(this.markerClassName).empty()}}},_enableDatepicker:function(target){var $target=$(target);var inst=$.data(target,PROP_NAME);if(!$target.hasClass(this.markerClassName)){return}var nodeName=target.nodeName.toLowerCase();if(nodeName=="input"){target.disabled=false;inst.trigger.filter("button").each(function(){this.disabled=false}).end().filter("img").css({opacity:"1.0",cursor:""})}else{if(nodeName=="div"||nodeName=="span"){var inline=$target.children("."+this._inlineClass);inline.children().removeClass("ui-state-disabled")}}this._disabledInputs=$.map(this._disabledInputs,function(value){return(value==target?null:value)})},_disableDatepicker:function(target){var $target=$(target);var inst=$.data(target,PROP_NAME);if(!$target.hasClass(this.markerClassName)){return}var nodeName=target.nodeName.toLowerCase();if(nodeName=="input"){target.disabled=true;inst.trigger.filter("button").each(function(){this.disabled=true}).end().filter("img").css({opacity:"0.5",cursor:"default"})}else{if(nodeName=="div"||nodeName=="span"){var inline=$target.children("."+this._inlineClass);inline.children().addClass("ui-state-disabled")}}this._disabledInputs=$.map(this._disabledInputs,function(value){return(value==target?null:value)});this._disabledInputs[this._disabledInputs.length]=target},_isDisabledDatepicker:function(target){if(!target){return false}for(var i=0;i-1)}},_showDatepicker:function(input){input=input.target||input;if(input.nodeName.toLowerCase()!="input"){input=$("input",input.parentNode)[0]}if($.datepicker._isDisabledDatepicker(input)||$.datepicker._lastInput==input){return}var inst=$.datepicker._getInst(input);var beforeShow=$.datepicker._get(inst,"beforeShow");extendRemove(inst.settings,(beforeShow?beforeShow.apply(input,[input,inst]):{}));$.datepicker._hideDatepicker(null,"");$.datepicker._lastInput=input;$.datepicker._setDateFromField(inst);if($.datepicker._inDialog){input.value=""}if(!$.datepicker._pos){$.datepicker._pos=$.datepicker._findPos(input);$.datepicker._pos[1]+=input.offsetHeight}var isFixed=false;$(input).parents().each(function(){isFixed|=$(this).css("position")=="fixed";return !isFixed});if(isFixed&&$.browser.opera){$.datepicker._pos[0]-=document.documentElement.scrollLeft;$.datepicker._pos[1]-=document.documentElement.scrollTop}var offset={left:$.datepicker._pos[0],top:$.datepicker._pos[1]};$.datepicker._pos=null;inst.rangeStart=null;inst.dpDiv.css({position:"absolute",display:"block",top:"-1000px"});$.datepicker._updateDatepicker(inst);offset=$.datepicker._checkOffset(inst,offset,isFixed);inst.dpDiv.css({position:($.datepicker._inDialog&&$.blockUI?"static":(isFixed?"fixed":"absolute")),display:"none",left:offset.left+"px",top:offset.top+"px"});if(!inst.inline){var showAnim=$.datepicker._get(inst,"showAnim")||"show";var duration=$.datepicker._get(inst,"duration");var postProcess=function(){$.datepicker._datepickerShowing=true;if($.browser.msie&&parseInt($.browser.version,10)<7){$("iframe.ui-datepicker-cover").css({width:inst.dpDiv.width()+4,height:inst.dpDiv.height()+4})}};if($.effects&&$.effects[showAnim]){inst.dpDiv.show(showAnim,$.datepicker._get(inst,"showOptions"),duration,postProcess)}else{inst.dpDiv[showAnim](duration,postProcess)}if(duration==""){postProcess()}if(inst.input[0].type!="hidden"){inst.input[0].focus()}$.datepicker._curInst=inst}},_updateDatepicker:function(inst){var dims={width:inst.dpDiv.width()+4,height:inst.dpDiv.height()+4};var self=this;inst.dpDiv.empty().append(this._generateHTML(inst)).find("iframe.ui-datepicker-cover").css({width:dims.width,height:dims.height}).end().find("button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a").bind("mouseout",function(){$(this).removeClass("ui-state-hover");if(this.className.indexOf("ui-datepicker-prev")!=-1){$(this).removeClass("ui-datepicker-prev-hover")}if(this.className.indexOf("ui-datepicker-next")!=-1){$(this).removeClass("ui-datepicker-next-hover")}}).bind("mouseover",function(){if(!self._isDisabledDatepicker(inst.inline?inst.dpDiv.parent()[0]:inst.input[0])){$(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover");$(this).addClass("ui-state-hover");if(this.className.indexOf("ui-datepicker-prev")!=-1){$(this).addClass("ui-datepicker-prev-hover")}if(this.className.indexOf("ui-datepicker-next")!=-1){$(this).addClass("ui-datepicker-next-hover")}}}).end().find("."+this._dayOverClass+" a").trigger("mouseover").end();var numMonths=this._getNumberOfMonths(inst);var cols=numMonths[1];var width=17;if(cols>1){inst.dpDiv.addClass("ui-datepicker-multi-"+cols).css("width",(width*cols)+"em")}else{inst.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width("")}inst.dpDiv[(numMonths[0]!=1||numMonths[1]!=1?"add":"remove")+"Class"]("ui-datepicker-multi");inst.dpDiv[(this._get(inst,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl");if(inst.input&&inst.input[0].type!="hidden"&&inst==$.datepicker._curInst){$(inst.input[0]).focus()}},_checkOffset:function(inst,offset,isFixed){var dpWidth=inst.dpDiv.outerWidth();var dpHeight=inst.dpDiv.outerHeight();var inputWidth=inst.input?inst.input.outerWidth():0;var inputHeight=inst.input?inst.input.outerHeight():0;var viewWidth=(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)+$(document).scrollLeft();var viewHeight=(window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight)+$(document).scrollTop();offset.left-=(this._get(inst,"isRTL")?(dpWidth-inputWidth):0);offset.left-=(isFixed&&offset.left==inst.input.offset().left)?$(document).scrollLeft():0;offset.top-=(isFixed&&offset.top==(inst.input.offset().top+inputHeight))?$(document).scrollTop():0;offset.left-=(offset.left+dpWidth>viewWidth&&viewWidth>dpWidth)?Math.abs(offset.left+dpWidth-viewWidth):0;offset.top-=(offset.top+dpHeight>viewHeight&&viewHeight>dpHeight)?Math.abs(offset.top+dpHeight+inputHeight*2-viewHeight):0;return offset},_findPos:function(obj){while(obj&&(obj.type=="hidden"||obj.nodeType!=1)){obj=obj.nextSibling}var position=$(obj).offset();return[position.left,position.top]},_hideDatepicker:function(input,duration){var inst=this._curInst;if(!inst||(input&&inst!=$.data(input,PROP_NAME))){return}if(inst.stayOpen){this._selectDate("#"+inst.id,this._formatDate(inst,inst.currentDay,inst.currentMonth,inst.currentYear))}inst.stayOpen=false;if(this._datepickerShowing){duration=(duration!=null?duration:this._get(inst,"duration"));var showAnim=this._get(inst,"showAnim");var postProcess=function(){$.datepicker._tidyDialog(inst)};if(duration!=""&&$.effects&&$.effects[showAnim]){inst.dpDiv.hide(showAnim,$.datepicker._get(inst,"showOptions"),duration,postProcess)}else{inst.dpDiv[(duration==""?"hide":(showAnim=="slideDown"?"slideUp":(showAnim=="fadeIn"?"fadeOut":"hide")))](duration,postProcess)}if(duration==""){this._tidyDialog(inst)}var onClose=this._get(inst,"onClose");if(onClose){onClose.apply((inst.input?inst.input[0]:null),[(inst.input?inst.input.val():""),inst])}this._datepickerShowing=false;this._lastInput=null;if(this._inDialog){this._dialogInput.css({position:"absolute",left:"0",top:"-100px"});if($.blockUI){$.unblockUI();$("body").append(this.dpDiv)}}this._inDialog=false}this._curInst=null},_tidyDialog:function(inst){inst.dpDiv.removeClass(this._dialogClass).unbind(".ui-datepicker-calendar")},_checkExternalClick:function(event){if(!$.datepicker._curInst){return}var $target=$(event.target);if(($target.parents("#"+$.datepicker._mainDivId).length==0)&&!$target.hasClass($.datepicker.markerClassName)&&!$target.hasClass($.datepicker._triggerClass)&&$.datepicker._datepickerShowing&&!($.datepicker._inDialog&&$.blockUI)){$.datepicker._hideDatepicker(null,"")}},_adjustDate:function(id,offset,period){var target=$(id);var inst=this._getInst(target[0]);if(this._isDisabledDatepicker(target[0])){return}this._adjustInstDate(inst,offset+(period=="M"?this._get(inst,"showCurrentAtPos"):0),period);this._updateDatepicker(inst)},_gotoToday:function(id){var target=$(id);var inst=this._getInst(target[0]);if(this._get(inst,"gotoCurrent")&&inst.currentDay){inst.selectedDay=inst.currentDay;inst.drawMonth=inst.selectedMonth=inst.currentMonth;inst.drawYear=inst.selectedYear=inst.currentYear}else{var date=new Date();inst.selectedDay=date.getDate();inst.drawMonth=inst.selectedMonth=date.getMonth();inst.drawYear=inst.selectedYear=date.getFullYear()}this._notifyChange(inst);this._adjustDate(target)},_selectMonthYear:function(id,select,period){var target=$(id);var inst=this._getInst(target[0]);inst._selectingMonthYear=false;inst["selected"+(period=="M"?"Month":"Year")]=inst["draw"+(period=="M"?"Month":"Year")]=parseInt(select.options[select.selectedIndex].value,10);this._notifyChange(inst);this._adjustDate(target)},_clickMonthYear:function(id){var target=$(id);var inst=this._getInst(target[0]);if(inst.input&&inst._selectingMonthYear&&!$.browser.msie){inst.input[0].focus()}inst._selectingMonthYear=!inst._selectingMonthYear},_selectDay:function(id,month,year,td){var target=$(id);if($(td).hasClass(this._unselectableClass)||this._isDisabledDatepicker(target[0])){return}var inst=this._getInst(target[0]);inst.selectedDay=inst.currentDay=$("a",td).html();inst.selectedMonth=inst.currentMonth=month;inst.selectedYear=inst.currentYear=year;if(inst.stayOpen){inst.endDay=inst.endMonth=inst.endYear=null}this._selectDate(id,this._formatDate(inst,inst.currentDay,inst.currentMonth,inst.currentYear));if(inst.stayOpen){inst.rangeStart=this._daylightSavingAdjust(new Date(inst.currentYear,inst.currentMonth,inst.currentDay));this._updateDatepicker(inst)}},_clearDate:function(id){var target=$(id);var inst=this._getInst(target[0]);inst.stayOpen=false;inst.endDay=inst.endMonth=inst.endYear=inst.rangeStart=null;this._selectDate(target,"")},_selectDate:function(id,dateStr){var target=$(id);var inst=this._getInst(target[0]);dateStr=(dateStr!=null?dateStr:this._formatDate(inst));if(inst.input){inst.input.val(dateStr)}this._updateAlternate(inst);var onSelect=this._get(inst,"onSelect");if(onSelect){onSelect.apply((inst.input?inst.input[0]:null),[dateStr,inst])}else{if(inst.input){inst.input.trigger("change")}}if(inst.inline){this._updateDatepicker(inst)}else{if(!inst.stayOpen){this._hideDatepicker(null,this._get(inst,"duration"));this._lastInput=inst.input[0];if(typeof(inst.input[0])!="object"){inst.input[0].focus()}this._lastInput=null}}},_updateAlternate:function(inst){var altField=this._get(inst,"altField");if(altField){var altFormat=this._get(inst,"altFormat")||this._get(inst,"dateFormat");var date=this._getDate(inst);dateStr=this.formatDate(altFormat,date,this._getFormatConfig(inst));$(altField).each(function(){$(this).val(dateStr)})}},noWeekends:function(date){var day=date.getDay();return[(day>0&&day<6),""]},iso8601Week:function(date){var checkDate=new Date(date.getFullYear(),date.getMonth(),date.getDate());var firstMon=new Date(checkDate.getFullYear(),1-1,4);var firstDay=firstMon.getDay()||7;firstMon.setDate(firstMon.getDate()+1-firstDay);if(firstDay<4&&checkDatenew Date(checkDate.getFullYear(),12-1,28)){firstDay=new Date(checkDate.getFullYear()+1,1-1,4).getDay()||7;if(firstDay>4&&(checkDate.getDay()||7)0&&iValue="0"&&value.charAt(iValue)<="9"){num=num*10+parseInt(value.charAt(iValue++),10);size--}if(size==origSize){throw"Missing number at position "+iValue}return num};var getName=function(match,shortNames,longNames){var names=(lookAhead(match)?longNames:shortNames);var size=0;for(var j=0;j0&&iValue-1){month=1;day=doy;do{var dim=this._getDaysInMonth(year,month-1);if(day<=dim){break}month++;day-=dim}while(true)}var date=this._daylightSavingAdjust(new Date(year,month-1,day));if(date.getFullYear()!=year||date.getMonth()+1!=month||date.getDate()!=day){throw"Invalid date"}return date},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TIMESTAMP:"@",W3C:"yy-mm-dd",formatDate:function(format,date,settings){if(!date){return""}var dayNamesShort=(settings?settings.dayNamesShort:null)||this._defaults.dayNamesShort;var dayNames=(settings?settings.dayNames:null)||this._defaults.dayNames;var monthNamesShort=(settings?settings.monthNamesShort:null)||this._defaults.monthNamesShort;var monthNames=(settings?settings.monthNames:null)||this._defaults.monthNames;var lookAhead=function(match){var matches=(iFormat+1=0;m--){doy+=this._getDaysInMonth(date.getFullYear(),m)}output+=formatNumber("o",doy,3);break;case"m":output+=formatNumber("m",date.getMonth()+1,2);break;case"M":output+=formatName("M",date.getMonth(),monthNamesShort,monthNames);break;case"y":output+=(lookAhead("y")?date.getFullYear():(date.getYear()%100<10?"0":"")+date.getYear()%100);break;case"@":output+=date.getTime();break;case"'":if(lookAhead("'")){output+="'"}else{literal=true}break;default:output+=format.charAt(iFormat)}}}}return output},_possibleChars:function(format){var chars="";var literal=false;for(var iFormat=0;iFormatmaxDate?maxDate:date);return date},_determineDate:function(date,defaultDate){var offsetNumeric=function(offset){var date=new Date();date.setDate(date.getDate()+offset);return date};var offsetString=function(offset,getDaysInMonth){var date=new Date();var year=date.getFullYear();var month=date.getMonth();var day=date.getDate();var pattern=/([+-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g;var matches=pattern.exec(offset);while(matches){switch(matches[2]||"d"){case"d":case"D":day+=parseInt(matches[1],10);break;case"w":case"W":day+=parseInt(matches[1],10)*7;break;case"m":case"M":month+=parseInt(matches[1],10);day=Math.min(day,getDaysInMonth(year,month));break;case"y":case"Y":year+=parseInt(matches[1],10);day=Math.min(day,getDaysInMonth(year,month));break}matches=pattern.exec(offset)}return new Date(year,month,day)};date=(date==null?defaultDate:(typeof date=="string"?offsetString(date,this._getDaysInMonth):(typeof date=="number"?(isNaN(date)?defaultDate:offsetNumeric(date)):date)));date=(date&&date.toString()=="Invalid Date"?defaultDate:date);if(date){date.setHours(0);date.setMinutes(0);date.setSeconds(0);date.setMilliseconds(0)}return this._daylightSavingAdjust(date)},_daylightSavingAdjust:function(date){if(!date){return null}date.setHours(date.getHours()>12?date.getHours()+2:0);return date},_setDate:function(inst,date,endDate){var clear=!(date);var origMonth=inst.selectedMonth;var origYear=inst.selectedYear;date=this._determineDate(date,new Date());inst.selectedDay=inst.currentDay=date.getDate();inst.drawMonth=inst.selectedMonth=inst.currentMonth=date.getMonth();inst.drawYear=inst.selectedYear=inst.currentYear=date.getFullYear();if(origMonth!=inst.selectedMonth||origYear!=inst.selectedYear){this._notifyChange(inst)}this._adjustInstDate(inst);if(inst.input){inst.input.val(clear?"":this._formatDate(inst))}},_getDate:function(inst){var startDate=(!inst.currentYear||(inst.input&&inst.input.val()=="")?null:this._daylightSavingAdjust(new Date(inst.currentYear,inst.currentMonth,inst.currentDay)));return startDate},_generateHTML:function(inst){var today=new Date();today=this._daylightSavingAdjust(new Date(today.getFullYear(),today.getMonth(),today.getDate()));var isRTL=this._get(inst,"isRTL");var showButtonPanel=this._get(inst,"showButtonPanel");var hideIfNoPrevNext=this._get(inst,"hideIfNoPrevNext");var navigationAsDateFormat=this._get(inst,"navigationAsDateFormat");var numMonths=this._getNumberOfMonths(inst);var showCurrentAtPos=this._get(inst,"showCurrentAtPos");var stepMonths=this._get(inst,"stepMonths");var stepBigMonths=this._get(inst,"stepBigMonths");var isMultiMonth=(numMonths[0]!=1||numMonths[1]!=1);var currentDate=this._daylightSavingAdjust((!inst.currentDay?new Date(9999,9,9):new Date(inst.currentYear,inst.currentMonth,inst.currentDay)));var minDate=this._getMinMaxDate(inst,"min",true);var maxDate=this._getMinMaxDate(inst,"max");var drawMonth=inst.drawMonth-showCurrentAtPos;var drawYear=inst.drawYear;if(drawMonth<0){drawMonth+=12;drawYear--}if(maxDate){var maxDraw=this._daylightSavingAdjust(new Date(maxDate.getFullYear(),maxDate.getMonth()-numMonths[1]+1,maxDate.getDate()));maxDraw=(minDate&&maxDrawmaxDraw){drawMonth--;if(drawMonth<0){drawMonth=11;drawYear--}}}inst.drawMonth=drawMonth;inst.drawYear=drawYear;var prevText=this._get(inst,"prevText");prevText=(!navigationAsDateFormat?prevText:this.formatDate(prevText,this._daylightSavingAdjust(new Date(drawYear,drawMonth-stepMonths,1)),this._getFormatConfig(inst)));var prev=(this._canAdjustMonth(inst,-1,drawYear,drawMonth)?''+prevText+"":(hideIfNoPrevNext?"":''+prevText+""));var nextText=this._get(inst,"nextText");nextText=(!navigationAsDateFormat?nextText:this.formatDate(nextText,this._daylightSavingAdjust(new Date(drawYear,drawMonth+stepMonths,1)),this._getFormatConfig(inst)));var next=(this._canAdjustMonth(inst,+1,drawYear,drawMonth)?''+nextText+"":(hideIfNoPrevNext?"":''+nextText+""));var currentText=this._get(inst,"currentText");var gotoDate=(this._get(inst,"gotoCurrent")&&inst.currentDay?currentDate:today);currentText=(!navigationAsDateFormat?currentText:this.formatDate(currentText,gotoDate,this._getFormatConfig(inst)));var controls=(!inst.inline?'":"");var buttonPanel=(showButtonPanel)?'
    '+(isRTL?controls:"")+(this._isInRange(inst,gotoDate)?'":"")+(isRTL?"":controls)+"
    ":"";var firstDay=parseInt(this._get(inst,"firstDay"),10);firstDay=(isNaN(firstDay)?0:firstDay);var dayNames=this._get(inst,"dayNames");var dayNamesShort=this._get(inst,"dayNamesShort");var dayNamesMin=this._get(inst,"dayNamesMin");var monthNames=this._get(inst,"monthNames");var monthNamesShort=this._get(inst,"monthNamesShort");var beforeShowDay=this._get(inst,"beforeShowDay");var showOtherMonths=this._get(inst,"showOtherMonths");var calculateWeek=this._get(inst,"calculateWeek")||this.iso8601Week;var endDate=inst.endDay?this._daylightSavingAdjust(new Date(inst.endYear,inst.endMonth,inst.endDay)):currentDate;var defaultDate=this._getDefaultDate(inst);var html="";for(var row=0;row'+(/all|left/.test(cornerClass)&&row==0?(isRTL?next:prev):"")+(/all|right/.test(cornerClass)&&row==0?(isRTL?prev:next):"")+this._generateMonthYearHeader(inst,drawMonth,drawYear,minDate,maxDate,selectedDate,row>0||col>0,monthNames,monthNamesShort)+'
    ';var thead="";for(var dow=0;dow<7;dow++){var day=(dow+firstDay)%7;thead+="=5?' class="ui-datepicker-week-end"':"")+'>'+dayNamesMin[day]+""}calender+=thead+"";var daysInMonth=this._getDaysInMonth(drawYear,drawMonth);if(drawYear==inst.selectedYear&&drawMonth==inst.selectedMonth){inst.selectedDay=Math.min(inst.selectedDay,daysInMonth)}var leadDays=(this._getFirstDayOfMonth(drawYear,drawMonth)-firstDay+7)%7;var numRows=(isMultiMonth?6:Math.ceil((leadDays+daysInMonth)/7));var printDate=this._daylightSavingAdjust(new Date(drawYear,drawMonth,1-leadDays));for(var dRow=0;dRow";var tbody="";for(var dow=0;dow<7;dow++){var daySettings=(beforeShowDay?beforeShowDay.apply((inst.input?inst.input[0]:null),[printDate]):[true,""]);var otherMonth=(printDate.getMonth()!=drawMonth);var unselectable=otherMonth||!daySettings[0]||(minDate&&printDatemaxDate);tbody+='";printDate.setDate(printDate.getDate()+1);printDate=this._daylightSavingAdjust(printDate)}calender+=tbody+""}drawMonth++;if(drawMonth>11){drawMonth=0;drawYear++}calender+="
    =currentDate.getTime()&&printDate.getTime()<=endDate.getTime()?" "+this._currentClass:"")+(printDate.getTime()==today.getTime()?" ui-datepicker-today":""))+'"'+((!otherMonth||showOtherMonths)&&daySettings[2]?' title="'+daySettings[2]+'"':"")+(unselectable?"":" onclick=\"DP_jQuery.datepicker._selectDay('#"+inst.id+"',"+drawMonth+","+drawYear+', this);return false;"')+">"+(otherMonth?(showOtherMonths?printDate.getDate():" "):(unselectable?''+printDate.getDate()+"":'=currentDate.getTime()&&printDate.getTime()<=endDate.getTime()?" ui-state-active":"")+'" href="#">'+printDate.getDate()+""))+"
    "+(isMultiMonth?""+((numMonths[0]>0&&col==numMonths[1]-1)?'
    ':""):"");group+=calender}html+=group}html+=buttonPanel+($.browser.msie&&parseInt($.browser.version,10)<7&&!inst.inline?'':"");inst._keyEvent=false;return html},_generateMonthYearHeader:function(inst,drawMonth,drawYear,minDate,maxDate,selectedDate,secondary,monthNames,monthNamesShort){minDate=(inst.rangeStart&&minDate&&selectedDate "}else{var inMinYear=(minDate&&minDate.getFullYear()==drawYear);var inMaxYear=(maxDate&&maxDate.getFullYear()==drawYear);monthHtml+='"}if(!showMonthAfterYear){html+=monthHtml+((secondary||changeMonth||changeYear)&&(!(changeMonth&&changeYear))?" ":"")}if(secondary||!changeYear){html+=''+drawYear+""}else{var years=this._get(inst,"yearRange").split(":");var year=0;var endYear=0;if(years.length!=2){year=drawYear-10;endYear=drawYear+10}else{if(years[0].charAt(0)=="+"||years[0].charAt(0)=="-"){year=drawYear+parseInt(years[0],10);endYear=drawYear+parseInt(years[1],10)}else{year=parseInt(years[0],10);endYear=parseInt(years[1],10)}}year=(minDate?Math.max(year,minDate.getFullYear()):year);endYear=(maxDate?Math.min(endYear,maxDate.getFullYear()):endYear);html+='"}if(showMonthAfterYear){html+=(secondary||changeMonth||changeYear?" ":"")+monthHtml}html+="";return html},_adjustInstDate:function(inst,offset,period){var year=inst.drawYear+(period=="Y"?offset:0);var month=inst.drawMonth+(period=="M"?offset:0);var day=Math.min(inst.selectedDay,this._getDaysInMonth(year,month))+(period=="D"?offset:0);var date=this._daylightSavingAdjust(new Date(year,month,day));var minDate=this._getMinMaxDate(inst,"min",true);var maxDate=this._getMinMaxDate(inst,"max");date=(minDate&&datemaxDate?maxDate:date);inst.selectedDay=date.getDate();inst.drawMonth=inst.selectedMonth=date.getMonth();inst.drawYear=inst.selectedYear=date.getFullYear();if(period=="M"||period=="Y"){this._notifyChange(inst)}},_notifyChange:function(inst){var onChange=this._get(inst,"onChangeMonthYear");if(onChange){onChange.apply((inst.input?inst.input[0]:null),[inst.selectedYear,inst.selectedMonth+1,inst])}},_getNumberOfMonths:function(inst){var numMonths=this._get(inst,"numberOfMonths");return(numMonths==null?[1,1]:(typeof numMonths=="number"?[1,numMonths]:numMonths))},_getMinMaxDate:function(inst,minMax,checkRange){var date=this._determineDate(this._get(inst,minMax+"Date"),null);return(!checkRange||!inst.rangeStart?date:(!date||inst.rangeStart>date?inst.rangeStart:date))},_getDaysInMonth:function(year,month){return 32-new Date(year,month,32).getDate()},_getFirstDayOfMonth:function(year,month){return new Date(year,month,1).getDay()},_canAdjustMonth:function(inst,offset,curYear,curMonth){var numMonths=this._getNumberOfMonths(inst);var date=this._daylightSavingAdjust(new Date(curYear,curMonth+(offset<0?offset:numMonths[1]),1));if(offset<0){date.setDate(this._getDaysInMonth(date.getFullYear(),date.getMonth()))}return this._isInRange(inst,date)},_isInRange:function(inst,date){var newMinDate=(!inst.rangeStart?null:this._daylightSavingAdjust(new Date(inst.selectedYear,inst.selectedMonth,inst.selectedDay)));newMinDate=(newMinDate&&inst.rangeStart=minDate)&&(!maxDate||date<=maxDate))},_getFormatConfig:function(inst){var shortYearCutoff=this._get(inst,"shortYearCutoff");shortYearCutoff=(typeof shortYearCutoff!="string"?shortYearCutoff:new Date().getFullYear()%100+parseInt(shortYearCutoff,10));return{shortYearCutoff:shortYearCutoff,dayNamesShort:this._get(inst,"dayNamesShort"),dayNames:this._get(inst,"dayNames"),monthNamesShort:this._get(inst,"monthNamesShort"),monthNames:this._get(inst,"monthNames")}},_formatDate:function(inst,day,month,year){if(!day){inst.currentDay=inst.selectedDay;inst.currentMonth=inst.selectedMonth;inst.currentYear=inst.selectedYear}var date=(day?(typeof day=="object"?day:this._daylightSavingAdjust(new Date(year,month,day))):this._daylightSavingAdjust(new Date(inst.currentYear,inst.currentMonth,inst.currentDay)));return this.formatDate(this._get(inst,"dateFormat"),date,this._getFormatConfig(inst))}});function extendRemove(target,props){$.extend(target,props);for(var name in props){if(props[name]==null||props[name]==undefined){target[name]=props[name]}}return target}function isArray(a){return(a&&(($.browser.safari&&typeof a=="object"&&a.length)||(a.constructor&&a.constructor.toString().match(/\Array\(\)/))))}$.fn.datepicker=function(options){if(!$.datepicker.initialized){$(document).mousedown($.datepicker._checkExternalClick).find("body").append($.datepicker.dpDiv);$.datepicker.initialized=true}var otherArgs=Array.prototype.slice.call(arguments,1);if(typeof options=="string"&&(options=="isDisabled"||options=="getDate")){return $.datepicker["_"+options+"Datepicker"].apply($.datepicker,[this[0]].concat(otherArgs))}if(options=="option"&&arguments.length==2&&typeof arguments[1]=="string"){return $.datepicker["_"+options+"Datepicker"].apply($.datepicker,[this[0]].concat(otherArgs))}return this.each(function(){typeof options=="string"?$.datepicker["_"+options+"Datepicker"].apply($.datepicker,[this].concat(otherArgs)):$.datepicker._attachDatepicker(this,options)})};$.datepicker=new Datepicker();$.datepicker.initialized=false;$.datepicker.uuid=new Date().getTime();$.datepicker.version="1.7.3";window.DP_jQuery=$})(jQuery);;/* * jQuery UI Progressbar 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Progressbar * * Depends: * ui.core.js */ (function(a){a.widget("ui.progressbar",{_init:function(){this.element.addClass("ui-progressbar ui-widget ui-widget-content ui-corner-all").attr({role:"progressbar","aria-valuemin":this._valueMin(),"aria-valuemax":this._valueMax(),"aria-valuenow":this._value()});this.valueDiv=a('
    ').appendTo(this.element);this._refreshValue()},destroy:function(){this.element.removeClass("ui-progressbar ui-widget ui-widget-content ui-corner-all").removeAttr("role").removeAttr("aria-valuemin").removeAttr("aria-valuemax").removeAttr("aria-valuenow").removeData("progressbar").unbind(".progressbar");this.valueDiv.remove();a.widget.prototype.destroy.apply(this,arguments)},value:function(b){if(b===undefined){return this._value()}this._setData("value",b);return this},_setData:function(b,c){switch(b){case"value":this.options.value=c;this._refreshValue();this._trigger("change",null,{});break}a.widget.prototype._setData.apply(this,arguments)},_value:function(){var b=this.options.value;if(bthis._valueMax()){b=this._valueMax()}return b},_valueMin:function(){var b=0;return b},_valueMax:function(){var b=100;return b},_refreshValue:function(){var b=this.value();this.valueDiv[b==this._valueMax()?"addClass":"removeClass"]("ui-corner-right");this.valueDiv.width(b+"%");this.element.attr("aria-valuenow",b)}});a.extend(a.ui.progressbar,{version:"1.7.3",defaults:{value:0}})})(jQuery);;/* * jQuery UI Effects 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Effects/ */ jQuery.effects||(function(d){d.effects={version:"1.7.3",save:function(g,h){for(var f=0;f');var j=f.parent();if(f.css("position")=="static"){j.css({position:"relative"});f.css({position:"relative"})}else{var i=f.css("top");if(isNaN(parseInt(i,10))){i="auto"}var h=f.css("left");if(isNaN(parseInt(h,10))){h="auto"}j.css({position:f.css("position"),top:i,left:h,zIndex:f.css("z-index")}).show();f.css({position:"relative",top:0,left:0})}j.css(g);return j},removeWrapper:function(f){if(f.parent().is(".ui-effects-wrapper")){return f.parent().replaceWith(f)}return f},setTransition:function(g,i,f,h){h=h||{};d.each(i,function(k,j){unit=g.cssUnit(j);if(unit[0]>0){h[j]=unit[0]*f+unit[1]}});return h},animateClass:function(h,i,k,j){var f=(typeof k=="function"?k:(j?j:null));var g=(typeof k=="string"?k:null);return this.each(function(){var q={};var o=d(this);var p=o.attr("style")||"";if(typeof p=="object"){p=p.cssText}if(h.toggle){o.hasClass(h.toggle)?h.remove=h.toggle:h.add=h.toggle}var l=d.extend({},(document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle));if(h.add){o.addClass(h.add)}if(h.remove){o.removeClass(h.remove)}var m=d.extend({},(document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle));if(h.add){o.removeClass(h.add)}if(h.remove){o.addClass(h.remove)}for(var r in m){if(typeof m[r]!="function"&&m[r]&&r.indexOf("Moz")==-1&&r.indexOf("length")==-1&&m[r]!=l[r]&&(r.match(/color/i)||(!r.match(/color/i)&&!isNaN(parseInt(m[r],10))))&&(l.position!="static"||(l.position=="static"&&!r.match(/left|top|bottom|right/)))){q[r]=m[r]}}o.animate(q,i,g,function(){if(typeof d(this).attr("style")=="object"){d(this).attr("style")["cssText"]="";d(this).attr("style")["cssText"]=p}else{d(this).attr("style",p)}if(h.add){d(this).addClass(h.add)}if(h.remove){d(this).removeClass(h.remove)}if(f){f.apply(this,arguments)}})})}};function c(g,f){var i=g[1]&&g[1].constructor==Object?g[1]:{};if(f){i.mode=f}var h=g[1]&&g[1].constructor!=Object?g[1]:(i.duration?i.duration:g[2]);h=d.fx.off?0:typeof h==="number"?h:d.fx.speeds[h]||d.fx.speeds._default;var j=i.callback||(d.isFunction(g[1])&&g[1])||(d.isFunction(g[2])&&g[2])||(d.isFunction(g[3])&&g[3]);return[g[0],i,h,j]}d.fn.extend({_show:d.fn.show,_hide:d.fn.hide,__toggle:d.fn.toggle,_addClass:d.fn.addClass,_removeClass:d.fn.removeClass,_toggleClass:d.fn.toggleClass,effect:function(g,f,h,i){return d.effects[g]?d.effects[g].call(this,{method:g,options:f||{},duration:h,callback:i}):null},show:function(){if(!arguments[0]||(arguments[0].constructor==Number||(/(slow|normal|fast)/).test(arguments[0]))){return this._show.apply(this,arguments)}else{return this.effect.apply(this,c(arguments,"show"))}},hide:function(){if(!arguments[0]||(arguments[0].constructor==Number||(/(slow|normal|fast)/).test(arguments[0]))){return this._hide.apply(this,arguments)}else{return this.effect.apply(this,c(arguments,"hide"))}},toggle:function(){if(!arguments[0]||(arguments[0].constructor==Number||(/(slow|normal|fast)/).test(arguments[0]))||(d.isFunction(arguments[0])||typeof arguments[0]=="boolean")){return this.__toggle.apply(this,arguments)}else{return this.effect.apply(this,c(arguments,"toggle"))}},addClass:function(g,f,i,h){return f?d.effects.animateClass.apply(this,[{add:g},f,i,h]):this._addClass(g)},removeClass:function(g,f,i,h){return f?d.effects.animateClass.apply(this,[{remove:g},f,i,h]):this._removeClass(g)},toggleClass:function(g,f,i,h){return((typeof f!=="boolean")&&f)?d.effects.animateClass.apply(this,[{toggle:g},f,i,h]):this._toggleClass(g,f)},morph:function(f,h,g,j,i){return d.effects.animateClass.apply(this,[{add:h,remove:f},g,j,i])},switchClass:function(){return this.morph.apply(this,arguments)},cssUnit:function(f){var g=this.css(f),h=[];d.each(["em","px","%","pt"],function(j,k){if(g.indexOf(k)>0){h=[parseFloat(g),k]}});return h}});d.each(["backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","color","outlineColor"],function(g,f){d.fx.step[f]=function(h){if(h.state==0){h.start=e(h.elem,f);h.end=b(h.end)}h.elem.style[f]="rgb("+[Math.max(Math.min(parseInt((h.pos*(h.end[0]-h.start[0]))+h.start[0],10),255),0),Math.max(Math.min(parseInt((h.pos*(h.end[1]-h.start[1]))+h.start[1],10),255),0),Math.max(Math.min(parseInt((h.pos*(h.end[2]-h.start[2]))+h.start[2],10),255),0)].join(",")+")"}});function b(g){var f;if(g&&g.constructor==Array&&g.length==3){return g}if(f=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(g)){return[parseInt(f[1],10),parseInt(f[2],10),parseInt(f[3],10)]}if(f=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(g)){return[parseFloat(f[1])*2.55,parseFloat(f[2])*2.55,parseFloat(f[3])*2.55]}if(f=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(g)){return[parseInt(f[1],16),parseInt(f[2],16),parseInt(f[3],16)]}if(f=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(g)){return[parseInt(f[1]+f[1],16),parseInt(f[2]+f[2],16),parseInt(f[3]+f[3],16)]}if(f=/rgba\(0, 0, 0, 0\)/.exec(g)){return a.transparent}return a[d.trim(g).toLowerCase()]}function e(h,f){var g;do{g=d.curCSS(h,f);if(g!=""&&g!="transparent"||d.nodeName(h,"body")){break}f="backgroundColor"}while(h=h.parentNode);return b(g)}var a={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0],transparent:[255,255,255]};d.easing.jswing=d.easing.swing;d.extend(d.easing,{def:"easeOutQuad",swing:function(g,h,f,j,i){return d.easing[d.easing.def](g,h,f,j,i)},easeInQuad:function(g,h,f,j,i){return j*(h/=i)*h+f},easeOutQuad:function(g,h,f,j,i){return -j*(h/=i)*(h-2)+f},easeInOutQuad:function(g,h,f,j,i){if((h/=i/2)<1){return j/2*h*h+f}return -j/2*((--h)*(h-2)-1)+f},easeInCubic:function(g,h,f,j,i){return j*(h/=i)*h*h+f},easeOutCubic:function(g,h,f,j,i){return j*((h=h/i-1)*h*h+1)+f},easeInOutCubic:function(g,h,f,j,i){if((h/=i/2)<1){return j/2*h*h*h+f}return j/2*((h-=2)*h*h+2)+f},easeInQuart:function(g,h,f,j,i){return j*(h/=i)*h*h*h+f},easeOutQuart:function(g,h,f,j,i){return -j*((h=h/i-1)*h*h*h-1)+f},easeInOutQuart:function(g,h,f,j,i){if((h/=i/2)<1){return j/2*h*h*h*h+f}return -j/2*((h-=2)*h*h*h-2)+f},easeInQuint:function(g,h,f,j,i){return j*(h/=i)*h*h*h*h+f},easeOutQuint:function(g,h,f,j,i){return j*((h=h/i-1)*h*h*h*h+1)+f},easeInOutQuint:function(g,h,f,j,i){if((h/=i/2)<1){return j/2*h*h*h*h*h+f}return j/2*((h-=2)*h*h*h*h+2)+f},easeInSine:function(g,h,f,j,i){return -j*Math.cos(h/i*(Math.PI/2))+j+f},easeOutSine:function(g,h,f,j,i){return j*Math.sin(h/i*(Math.PI/2))+f},easeInOutSine:function(g,h,f,j,i){return -j/2*(Math.cos(Math.PI*h/i)-1)+f},easeInExpo:function(g,h,f,j,i){return(h==0)?f:j*Math.pow(2,10*(h/i-1))+f},easeOutExpo:function(g,h,f,j,i){return(h==i)?f+j:j*(-Math.pow(2,-10*h/i)+1)+f},easeInOutExpo:function(g,h,f,j,i){if(h==0){return f}if(h==i){return f+j}if((h/=i/2)<1){return j/2*Math.pow(2,10*(h-1))+f}return j/2*(-Math.pow(2,-10*--h)+2)+f},easeInCirc:function(g,h,f,j,i){return -j*(Math.sqrt(1-(h/=i)*h)-1)+f},easeOutCirc:function(g,h,f,j,i){return j*Math.sqrt(1-(h=h/i-1)*h)+f},easeInOutCirc:function(g,h,f,j,i){if((h/=i/2)<1){return -j/2*(Math.sqrt(1-h*h)-1)+f}return j/2*(Math.sqrt(1-(h-=2)*h)+1)+f},easeInElastic:function(g,i,f,m,l){var j=1.70158;var k=0;var h=m;if(i==0){return f}if((i/=l)==1){return f+m}if(!k){k=l*0.3}if(h").css({position:"absolute",visibility:"visible",left:-d*(g/e),top:-f*(c/k)}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:g/e,height:c/k,left:l.left+d*(g/e)+(b.options.mode=="show"?(d-Math.floor(e/2))*(g/e):0),top:l.top+f*(c/k)+(b.options.mode=="show"?(f-Math.floor(k/2))*(c/k):0),opacity:b.options.mode=="show"?0:1}).animate({left:l.left+d*(g/e)+(b.options.mode=="show"?0:(d-Math.floor(e/2))*(g/e)),top:l.top+f*(c/k)+(b.options.mode=="show"?0:(f-Math.floor(k/2))*(c/k)),opacity:b.options.mode=="show"?1:0},b.duration||500)}}setTimeout(function(){b.options.mode=="show"?h.css({visibility:"visible"}):h.css({visibility:"visible"}).hide();if(b.callback){b.callback.apply(h[0])}h.dequeue();a("div.ui-effects-explode").remove()},b.duration||500)})}})(jQuery);;/* * jQuery UI Effects Fold 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Effects/Fold * * Depends: * effects.core.js */ (function(a){a.effects.fold=function(b){return this.queue(function(){var e=a(this),k=["position","top","left"];var h=a.effects.setMode(e,b.options.mode||"hide");var o=b.options.size||15;var n=!(!b.options.horizFirst);var g=b.duration?b.duration/2:a.fx.speeds._default/2;a.effects.save(e,k);e.show();var d=a.effects.createWrapper(e).css({overflow:"hidden"});var i=((h=="show")!=n);var f=i?["width","height"]:["height","width"];var c=i?[d.width(),d.height()]:[d.height(),d.width()];var j=/([0-9]+)%/.exec(o);if(j){o=parseInt(j[1],10)/100*c[h=="hide"?0:1]}if(h=="show"){d.css(n?{height:0,width:o}:{height:o,width:0})}var m={},l={};m[f[0]]=h=="show"?c[0]:o;l[f[1]]=h=="show"?c[1]:0;d.animate(m,g,b.options.easing).animate(l,g,b.options.easing,function(){if(h=="hide"){e.hide()}a.effects.restore(e,k);a.effects.removeWrapper(e);if(b.callback){b.callback.apply(e[0],arguments)}e.dequeue()})})}})(jQuery);;/* * jQuery UI Effects Highlight 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Effects/Highlight * * Depends: * effects.core.js */ (function(a){a.effects.highlight=function(b){return this.queue(function(){var e=a(this),d=["backgroundImage","backgroundColor","opacity"];var h=a.effects.setMode(e,b.options.mode||"show");var c=b.options.color||"#ffff99";var g=e.css("backgroundColor");a.effects.save(e,d);e.show();e.css({backgroundImage:"none",backgroundColor:c});var f={backgroundColor:g};if(h=="hide"){f.opacity=0}e.animate(f,{queue:false,duration:b.duration,easing:b.options.easing,complete:function(){if(h=="hide"){e.hide()}a.effects.restore(e,d);if(h=="show"&&a.browser.msie){this.style.removeAttribute("filter")}if(b.callback){b.callback.apply(this,arguments)}e.dequeue()}})})}})(jQuery);;/* * jQuery UI Effects Pulsate 1.7.3 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Effects/Pulsate * * Depends: * effects.core.js */ (function(a){a.effects.pulsate=function(b){return this.queue(function(){var d=a(this);var g=a.effects.setMode(d,b.options.mode||"show");var f=b.options.times||5;var e=b.duration?b.duration/2:a.fx.speeds._default/2;if(g=="hide"){f--}if(d.is(":hidden")){d.css("opacity",0);d.show();d.animate({opacity:1},e,b.options.easing);f=f-2}for(var c=0;c').appendTo(document.body).addClass(b.options.className).css({top:d.top,left:d.left,height:f.innerHeight(),width:f.innerWidth(),position:"absolute"}).animate(g,b.duration,b.options.easing,function(){c.remove();(b.callback&&b.callback.apply(f[0],arguments));f.dequeue()})})}})(jQuery);; // ./jquery.sly.js /*! * https://github.com/darsain/sly/blob/master/docs/Options.md * sly 1.2.5 - 28th Aug 2014 * https://github.com/darsain/sly * * Licensed under the MIT license. * http://opensource.org/licenses/MIT */ ;(function ($, w, undefined) { 'use strict'; var pluginName = 'sly'; var className = 'Sly'; var namespace = pluginName; // Local WindowAnimationTiming interface var cAF = w.cancelAnimationFrame || w.cancelRequestAnimationFrame; var rAF = w.requestAnimationFrame; // Support indicators var transform, gpuAcceleration; // Other global values var $doc = $(document); var dragInitEvents = 'touchstart.' + namespace + ' mousedown.' + namespace; var dragMouseEvents = 'mousemove.' + namespace + ' mouseup.' + namespace; var dragTouchEvents = 'touchmove.' + namespace + ' touchend.' + namespace; var wheelEvent = (document.implementation.hasFeature('Event.wheel', '3.0') ? 'wheel.' : 'mousewheel.') + namespace; var clickEvent = 'click.' + namespace; var mouseDownEvent = 'mousedown.' + namespace; var interactiveElements = ['INPUT', 'SELECT', 'BUTTON', 'TEXTAREA']; var tmpArray = []; var time; // Math shorthands var abs = Math.abs; var sqrt = Math.sqrt; var pow = Math.pow; var round = Math.round; var max = Math.max; var min = Math.min; // Keep track of last fired global wheel event var lastWheel = 0; $doc.on(wheelEvent, function () { lastWheel = +new Date(); }); /** * Sly. * * @class * * @param {Element} frame DOM element of sly container. * @param {Object} options Object with options. * @param {Object} callbackMap Callbacks map. */ function Sly(frame, options, callbackMap) { // Extend options var o = $.extend({}, Sly.defaults, options); // Private variables var self = this; var parallax = isNumber(frame); // Frame var $frame = $(frame); var $slidee = $frame.children().eq(0); var frameSize = 0; var slideeSize = 0; var pos = { start: 0, center: 0, end: 0, cur: 0, dest: 0 }; // Scrollbar var $sb = $(o.scrollBar).eq(0); var $handle = $sb.children().eq(0); var sbSize = 0; var handleSize = 0; var hPos = { start: 0, end: 0, cur: 0 }; // Pagesbar var $pb = $(o.pagesBar); var $pages = 0; var pages = []; // Items var $items = 0; var items = []; var rel = { firstItem: 0, lastItem: 0, centerItem: 0, activeItem: -1, activePage: 0 }; // Navigation type booleans var basicNav = o.itemNav === 'basic'; var forceCenteredNav = o.itemNav === 'forceCentered'; var centeredNav = o.itemNav === 'centered' || forceCenteredNav; var itemNav = !parallax && (basicNav || centeredNav || forceCenteredNav); // Miscellaneous var $scrollSource = o.scrollSource ? $(o.scrollSource) : $frame; var $dragSource = o.dragSource ? $(o.dragSource) : $frame; var $forwardButton = $(o.forward); var $backwardButton = $(o.backward); var $prevButton = $(o.prev); var $nextButton = $(o.next); var $prevPageButton = $(o.prevPage); var $nextPageButton = $(o.nextPage); var callbacks = {}; var last = {}; var animation = {}; var move = {}; var dragging = { released: 1 }; var scrolling = { last: 0, delta: 0, resetTime: 200 }; var renderID = 0; var historyID = 0; var cycleID = 0; var continuousID = 0; var i, l; // Normalizing frame if (!parallax) { frame = $frame[0]; } // Expose properties self.initialized = 0; self.frame = frame; self.slidee = $slidee[0]; self.pos = pos; self.rel = rel; self.items = items; self.pages = pages; self.isPaused = 0; self.options = o; self.dragging = dragging; /** * (Re)Loading function. * * Populate arrays, set sizes, bind events, ... * * @return {Void} */ function load() { // Local variables var lastItemsCount = 0; var lastPagesCount = pages.length; // Save old position pos.old = $.extend({}, pos); // Reset global variables frameSize = parallax ? 0 : $frame[o.horizontal ? 'width' : 'height'](); sbSize = $sb[o.horizontal ? 'width' : 'height'](); slideeSize = parallax ? frame : $slidee[o.horizontal ? 'outerWidth' : 'outerHeight'](); pages.length = 0; // Set position limits & relatives pos.start = 0; pos.end = max(slideeSize - frameSize, 0); // Sizes & offsets for item based navigations if (itemNav) { // Save the number of current items lastItemsCount = items.length; // Reset itemNav related variables $items = $slidee.children(o.itemSelector); items.length = 0; // Needed variables var paddingStart = getPx($slidee, o.horizontal ? 'paddingLeft' : 'paddingTop'); var paddingEnd = getPx($slidee, o.horizontal ? 'paddingRight' : 'paddingBottom'); var borderBox = $($items).css('boxSizing') === 'border-box'; var areFloated = $items.css('float') !== 'none'; var ignoredMargin = 0; var lastItemIndex = $items.length - 1; var lastItem; // Reset slideeSize slideeSize = 0; // Iterate through items $items.each(function (i, element) { // Item var $item = $(element); var itemSize = $item[o.horizontal ? 'outerWidth' : 'outerHeight'](); var itemMarginStart = getPx($item, o.horizontal ? 'marginLeft' : 'marginTop'); var itemMarginEnd = getPx($item, o.horizontal ? 'marginRight' : 'marginBottom'); var itemSizeFull = itemSize + itemMarginStart + itemMarginEnd; var singleSpaced = !itemMarginStart || !itemMarginEnd; var item = {}; item.el = element; item.size = singleSpaced ? itemSize : itemSizeFull; item.half = item.size / 2; item.start = slideeSize + (singleSpaced ? itemMarginStart : 0); item.center = item.start - round(frameSize / 2 - item.size / 2); item.end = item.start - frameSize + item.size; // Account for slidee padding if (!i) { slideeSize += paddingStart; } // Increment slidee size for size of the active element slideeSize += itemSizeFull; // Try to account for vertical margin collapsing in vertical mode // It's not bulletproof, but should work in 99% of cases if (!o.horizontal && !areFloated) { // Subtract smaller margin, but only when top margin is not 0, and this is not the first element if (itemMarginEnd && itemMarginStart && i > 0) { slideeSize -= min(itemMarginStart, itemMarginEnd); } } // Things to be done on last item if (i === lastItemIndex) { item.end += paddingEnd; slideeSize += paddingEnd; ignoredMargin = singleSpaced ? itemMarginEnd : 0; } // Add item object to items array items.push(item); lastItem = item; }); // Resize SLIDEE to fit all items $slidee[0].style[o.horizontal ? 'width' : 'height'] = (borderBox ? slideeSize: slideeSize - paddingStart - paddingEnd) + 'px'; // Adjust internal SLIDEE size for last margin slideeSize -= ignoredMargin; // Set limits if (items.length) { pos.start = items[0][forceCenteredNav ? 'center' : 'start']; pos.end = forceCenteredNav ? lastItem.center : frameSize < slideeSize ? lastItem.end : pos.start; } else { pos.start = pos.end = 0; } } // Calculate SLIDEE center position pos.center = round(pos.end / 2 + pos.start / 2); // Update relative positions updateRelatives(); // Scrollbar if ($handle.length && sbSize > 0) { // Stretch scrollbar handle to represent the visible area if (o.dynamicHandle) { handleSize = pos.start === pos.end ? sbSize : round(sbSize * frameSize / slideeSize); handleSize = within(handleSize, o.minHandleSize, sbSize); $handle[0].style[o.horizontal ? 'width' : 'height'] = handleSize + 'px'; } else { handleSize = $handle[o.horizontal ? 'outerWidth' : 'outerHeight'](); } hPos.end = sbSize - handleSize; if (!renderID) { syncScrollbar(); } } // Pages if (!parallax && frameSize > 0) { var tempPagePos = pos.start; var pagesHtml = ''; // Populate pages array if (itemNav) { $.each(items, function (i, item) { if (forceCenteredNav) { pages.push(item.center); } else if (item.start + item.size > tempPagePos && tempPagePos <= pos.end) { tempPagePos = item.start; pages.push(tempPagePos); tempPagePos += frameSize; if (tempPagePos > pos.end && tempPagePos < pos.end + frameSize) { pages.push(pos.end); } } }); } else { while (tempPagePos - frameSize < pos.end) { pages.push(tempPagePos); tempPagePos += frameSize; } } // Pages bar if ($pb[0] && lastPagesCount !== pages.length) { for (var i = 0; i < pages.length; i++) { pagesHtml += o.pageBuilder.call(self, i); } $pages = $pb.html(pagesHtml).children(); $pages.eq(rel.activePage).addClass(o.activeClass); } } // Extend relative variables object with some useful info rel.slideeSize = slideeSize; rel.frameSize = frameSize; rel.sbSize = sbSize; rel.handleSize = handleSize; // Activate requested position if (itemNav) { if (!self.initialized) { activate(o.startAt); self[centeredNav ? 'toCenter' : 'toStart'](o.startAt); } else if (rel.activeItem >= items.length || lastItemsCount === 0 && items.length > 0) { // Activate last item if previous active has been removed, or first item // when there were no items before, and new got appended. activate(rel.activeItem >= items.length ? items.length - 1 : 0, !lastItemsCount); } // Fix possible overflowing var activeItem = items[rel.activeItem]; slideTo(centeredNav && activeItem ? activeItem.center : within(pos.dest, pos.start, pos.end)); } else { if (!self.initialized) { slideTo(o.startAt, 1); } else { // Fix possible overflowing slideTo(within(pos.dest, pos.start, pos.end)); } } // Trigger load event trigger('load'); } self.reload = load; /** * Animate to a position. * * @param {Int} newPos New position. * @param {Bool} immediate Reposition immediately without an animation. * @param {Bool} dontAlign Do not align items, use the raw position passed in first argument. * * @return {Void} */ function slideTo(newPos, immediate, dontAlign) { // Align items if (itemNav && dragging.released && !dontAlign) { var tempRel = getRelatives(newPos); var isNotBordering = newPos > pos.start && newPos < pos.end; if (centeredNav) { if (isNotBordering) { newPos = items[tempRel.centerItem].center; } if (forceCenteredNav && o.activateMiddle) { activate(tempRel.centerItem); } } else if (isNotBordering) { newPos = items[tempRel.firstItem].start; } } // Handle overflowing position limits if (dragging.init && dragging.slidee && o.elasticBounds) { if (newPos > pos.end) { newPos = pos.end + (newPos - pos.end) / 6; } else if (newPos < pos.start) { newPos = pos.start + (newPos - pos.start) / 6; } } else { newPos = within(newPos, pos.start, pos.end); } // Update the animation object animation.start = +new Date(); animation.time = 0; animation.from = pos.cur; animation.to = newPos; animation.delta = newPos - pos.cur; animation.tweesing = dragging.tweese || dragging.init && !dragging.slidee; animation.immediate = !animation.tweesing && (immediate || dragging.init && dragging.slidee || !o.speed); // Reset dragging tweesing request dragging.tweese = 0; // Start animation rendering if (newPos !== pos.dest) { pos.dest = newPos; trigger('change'); if (!renderID) { render(); } } // Reset next cycle timeout resetCycle(); // Synchronize states updateRelatives(); updateButtonsState(); syncPagesbar(); } /** * Render animation frame. * * @return {Void} */ function render() { // If first render call, wait for next animationFrame if (!renderID) { renderID = rAF(render); if (dragging.released) { trigger('moveStart'); } return; } // If immediate repositioning is requested, don't animate. if (animation.immediate) { pos.cur = animation.to; } // Use tweesing for animations without known end point else if (animation.tweesing) { animation.tweeseDelta = animation.to - pos.cur; // Fuck Zeno's paradox if (abs(animation.tweeseDelta) < 0.1) { pos.cur = animation.to; } else { pos.cur += animation.tweeseDelta * (dragging.released ? o.swingSpeed : o.syncSpeed); } } // Use tweening for basic animations with known end point else { animation.time = min(+new Date() - animation.start, o.speed); pos.cur = animation.from + animation.delta * jQuery.easing[o.easing](animation.time/o.speed, animation.time, 0, 1, o.speed); } // If there is nothing more to render break the rendering loop, otherwise request new animation frame. if (animation.to === pos.cur) { pos.cur = animation.to; dragging.tweese = renderID = 0; } else { renderID = rAF(render); } trigger('move'); // Update SLIDEE position if (!parallax) { if (transform) { $slidee[0].style[transform] = gpuAcceleration + (o.horizontal ? 'translateX' : 'translateY') + '(' + (-pos.cur) + 'px)'; } else { $slidee[0].style[o.horizontal ? 'left' : 'top'] = -round(pos.cur) + 'px'; } } // When animation reached the end, and dragging is not active, trigger moveEnd if (!renderID && dragging.released) { trigger('moveEnd'); } syncScrollbar(); } /** * Synchronizes scrollbar with the SLIDEE. * * @return {Void} */ function syncScrollbar() { if ($handle.length) { hPos.cur = pos.start === pos.end ? 0 : (((dragging.init && !dragging.slidee) ? pos.dest : pos.cur) - pos.start) / (pos.end - pos.start) * hPos.end; hPos.cur = within(round(hPos.cur), hPos.start, hPos.end); if (last.hPos !== hPos.cur) { last.hPos = hPos.cur; if (transform) { $handle[0].style[transform] = gpuAcceleration + (o.horizontal ? 'translateX' : 'translateY') + '(' + hPos.cur + 'px)'; } else { $handle[0].style[o.horizontal ? 'left' : 'top'] = hPos.cur + 'px'; } } } } /** * Synchronizes pagesbar with SLIDEE. * * @return {Void} */ function syncPagesbar() { if ($pages[0] && last.page !== rel.activePage) { last.page = rel.activePage; $pages.removeClass(o.activeClass).eq(rel.activePage).addClass(o.activeClass); trigger('activePage', last.page); } } /** * Returns the position object. * * @param {Mixed} item * * @return {Object} */ self.getPos = function (item) { if (itemNav) { var index = getIndex(item); return index !== -1 ? items[index] : false; } else { var $item = $slidee.find(item).eq(0); if ($item[0]) { var offset = o.horizontal ? $item.offset().left - $slidee.offset().left : $item.offset().top - $slidee.offset().top; var size = $item[o.horizontal ? 'outerWidth' : 'outerHeight'](); return { start: offset, center: offset - frameSize / 2 + size / 2, end: offset - frameSize + size, size: size }; } else { return false; } } }; /** * Continuous move in a specified direction. * * @param {Bool} forward True for forward movement, otherwise it'll go backwards. * @param {Int} speed Movement speed in pixels per frame. Overrides options.moveBy value. * * @return {Void} */ self.moveBy = function (speed) { move.speed = speed; // If already initiated, or there is nowhere to move, abort if (dragging.init || !move.speed || pos.cur === (move.speed > 0 ? pos.end : pos.start)) { return; } // Initiate move object move.lastTime = +new Date(); move.startPos = pos.cur; // Set dragging as initiated continuousInit('button'); dragging.init = 1; // Start movement trigger('moveStart'); cAF(continuousID); moveLoop(); }; /** * Continuous movement loop. * * @return {Void} */ function moveLoop() { // If there is nowhere to move anymore, stop if (!move.speed || pos.cur === (move.speed > 0 ? pos.end : pos.start)) { self.stop(); } // Request new move loop if it hasn't been stopped continuousID = dragging.init ? rAF(moveLoop) : 0; // Update move object move.now = +new Date(); move.pos = pos.cur + (move.now - move.lastTime) / 1000 * move.speed; // Slide slideTo(dragging.init ? move.pos : round(move.pos)); // Normally, this is triggered in render(), but if there // is nothing to render, we have to do it manually here. if (!dragging.init && pos.cur === pos.dest) { trigger('moveEnd'); } // Update times for future iteration move.lastTime = move.now; } /** * Stops continuous movement. * * @return {Void} */ self.stop = function () { if (dragging.source === 'button') { dragging.init = 0; dragging.released = 1; } }; /** * Activate previous item. * * @return {Void} */ self.prev = function () { self.activate(rel.activeItem - 1); }; /** * Activate next item. * * @return {Void} */ self.next = function () { self.activate(rel.activeItem + 1); }; /** * Activate previous page. * * @return {Void} */ self.prevPage = function () { self.activatePage(rel.activePage - 1); }; /** * Activate next page. * * @return {Void} */ self.nextPage = function () { self.activatePage(rel.activePage + 1); }; /** * Slide SLIDEE by amount of pixels. * * @param {Int} delta Pixels/Items. Positive means forward, negative means backward. * @param {Bool} immediate Reposition immediately without an animation. * * @return {Void} */ self.slideBy = function (delta, immediate) { if (!delta) { return; } if (itemNav) { self[centeredNav ? 'toCenter' : 'toStart']( within((centeredNav ? rel.centerItem : rel.firstItem) + o.scrollBy * delta, 0, items.length) ); } else { slideTo(pos.dest + delta, immediate); } }; /** * Animate SLIDEE to a specific position. * * @param {Int} pos New position. * @param {Bool} immediate Reposition immediately without an animation. * * @return {Void} */ self.slideTo = function (pos, immediate) { slideTo(pos, immediate); }; /** * Core method for handling `toLocation` methods. * * @param {String} location * @param {Mixed} item * @param {Bool} immediate * * @return {Void} */ function to(location, item, immediate) { // Optional arguments logic if (type(item) === 'boolean') { immediate = item; item = undefined; } if (item === undefined) { slideTo(pos[location], immediate); } else { // You can't align items to sides of the frame // when centered navigation type is enabled if (centeredNav && location !== 'center') { return; } var itemPos = self.getPos(item); if (itemPos) { slideTo(itemPos[location], immediate, !centeredNav); } } } /** * Animate element or the whole SLIDEE to the start of the frame. * * @param {Mixed} item Item DOM element, or index starting at 0. Omitting will animate SLIDEE. * @param {Bool} immediate Reposition immediately without an animation. * * @return {Void} */ self.toStart = function (item, immediate) { to('start', item, immediate); }; /** * Animate element or the whole SLIDEE to the end of the frame. * * @param {Mixed} item Item DOM element, or index starting at 0. Omitting will animate SLIDEE. * @param {Bool} immediate Reposition immediately without an animation. * * @return {Void} */ self.toEnd = function (item, immediate) { to('end', item, immediate); }; /** * Animate element or the whole SLIDEE to the center of the frame. * * @param {Mixed} item Item DOM element, or index starting at 0. Omitting will animate SLIDEE. * @param {Bool} immediate Reposition immediately without an animation. * * @return {Void} */ self.toCenter = function (item, immediate) { to('center', item, immediate); }; /** * Get the index of an item in SLIDEE. * * @param {Mixed} item Item DOM element. * * @return {Int} Item index, or -1 if not found. */ function getIndex(item) { return item != null ? isNumber(item) ? item >= 0 && item < items.length ? item : -1 : $items.index(item) : -1; } // Expose getIndex without lowering the compressibility of it, // as it is used quite often throughout Sly. self.getIndex = getIndex; /** * Get index of an item in SLIDEE based on a variety of input types. * * @param {Mixed} item DOM element, positive or negative integer. * * @return {Int} Item index, or -1 if not found. */ function getRelativeIndex(item) { return getIndex(isNumber(item) && item < 0 ? item + items.length : item); } /** * Activates an item. * * @param {Mixed} item Item DOM element, or index starting at 0. * * @return {Mixed} Activated item index or false on fail. */ function activate(item, force) { var index = getIndex(item); if (!itemNav || index < 0) { return false; } // Update classes, last active index, and trigger active event only when there // has been a change. Otherwise just return the current active index. if (last.active !== index || force) { // Update classes $items.eq(rel.activeItem).removeClass(o.activeClass); $items.eq(index).addClass(o.activeClass); last.active = rel.activeItem = index; updateButtonsState(); trigger('active', index); } return index; } /** * Activates an item and helps with further navigation when o.smart is enabled. * * @param {Mixed} item Item DOM element, or index starting at 0. * @param {Bool} immediate Whether to reposition immediately in smart navigation. * * @return {Void} */ self.activate = function (item, immediate) { var index = activate(item); // Smart navigation if (o.smart && index !== false) { // When centeredNav is enabled, center the element. // Otherwise, determine where to position the element based on its current position. // If the element is currently on the far end side of the frame, assume that user is // moving forward and animate it to the start of the visible frame, and vice versa. if (centeredNav) { self.toCenter(index, immediate); } else if (index >= rel.lastItem) { self.toStart(index, immediate); } else if (index <= rel.firstItem) { self.toEnd(index, immediate); } else { resetCycle(); } } }; /** * Activates a page. * * @param {Int} index Page index, starting from 0. * @param {Bool} immediate Whether to reposition immediately without animation. * * @return {Void} */ self.activatePage = function (index, immediate) { if (isNumber(index)) { slideTo(pages[within(index, 0, pages.length - 1)], immediate); } }; /** * Return relative positions of items based on their visibility within FRAME. * * @param {Int} slideePos Position of SLIDEE. * * @return {Void} */ function getRelatives(slideePos) { slideePos = within(isNumber(slideePos) ? slideePos : pos.dest, pos.start, pos.end); var relatives = {}; var centerOffset = forceCenteredNav ? 0 : frameSize / 2; // Determine active page if (!parallax) { for (var p = 0, pl = pages.length; p < pl; p++) { if (slideePos >= pos.end || p === pages.length - 1) { relatives.activePage = pages.length - 1; break; } if (slideePos <= pages[p] + centerOffset) { relatives.activePage = p; break; } } } // Relative item indexes if (itemNav) { var first = false; var last = false; var center = false; // From start for (var i = 0, il = items.length; i < il; i++) { // First item if (first === false && slideePos <= items[i].start + items[i].half) { first = i; } // Center item if (center === false && slideePos <= items[i].center + items[i].half) { center = i; } // Last item if (i === il - 1 || slideePos <= items[i].end + items[i].half) { last = i; break; } } // Safe assignment, just to be sure the false won't be returned relatives.firstItem = isNumber(first) ? first : 0; relatives.centerItem = isNumber(center) ? center : relatives.firstItem; relatives.lastItem = isNumber(last) ? last : relatives.centerItem; } return relatives; } /** * Update object with relative positions. * * @param {Int} newPos * * @return {Void} */ function updateRelatives(newPos) { $.extend(rel, getRelatives(newPos)); } /** * Disable navigation buttons when needed. * * Adds disabledClass, and when the button is ').click(function(){h.click.apply(b.element[0],arguments)}).appendTo(g);c.each(h,function(j,k){if(j!=="click")j in o?i[j](k):i.attr(j,k)});c.fn.button&&i.button()});e.appendTo(b.uiDialog)}},_makeDraggable:function(){function a(f){return{position:f.position,offset:f.offset}}var b=this,d=b.options,e=c(document),g;b.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close", handle:".ui-dialog-titlebar",containment:"document",start:function(f,h){g=d.height==="auto"?"auto":c(this).height();c(this).height(c(this).height()).addClass("ui-dialog-dragging");b._trigger("dragStart",f,a(h))},drag:function(f,h){b._trigger("drag",f,a(h))},stop:function(f,h){d.position=[h.position.left-e.scrollLeft(),h.position.top-e.scrollTop()];c(this).removeClass("ui-dialog-dragging").height(g);b._trigger("dragStop",f,a(h));c.ui.dialog.overlay.resize()}})},_makeResizable:function(a){function b(f){return{originalPosition:f.originalPosition, originalSize:f.originalSize,position:f.position,size:f.size}}a=a===l?this.options.resizable:a;var d=this,e=d.options,g=d.uiDialog.css("position");a=typeof a==="string"?a:"n,e,s,w,se,sw,ne,nw";d.uiDialog.resizable({cancel:".ui-dialog-content",containment:"document",alsoResize:d.element,maxWidth:e.maxWidth,maxHeight:e.maxHeight,minWidth:e.minWidth,minHeight:d._minHeight(),handles:a,start:function(f,h){c(this).addClass("ui-dialog-resizing");d._trigger("resizeStart",f,b(h))},resize:function(f,h){d._trigger("resize", f,b(h))},stop:function(f,h){c(this).removeClass("ui-dialog-resizing");e.height=c(this).height();e.width=c(this).width();d._trigger("resizeStop",f,b(h));c.ui.dialog.overlay.resize()}}).css("position",g).find(".ui-resizable-se").addClass("ui-icon ui-icon-grip-diagonal-se")},_minHeight:function(){var a=this.options;return a.height==="auto"?a.minHeight:Math.min(a.minHeight,a.height)},_position:function(a){var b=[],d=[0,0],e;if(a){if(typeof a==="string"||typeof a==="object"&&"0"in a){b=a.split?a.split(" "): [a[0],a[1]];if(b.length===1)b[1]=b[0];c.each(["left","top"],function(g,f){if(+b[g]===b[g]){d[g]=b[g];b[g]=f}});a={my:b.join(" "),at:b.join(" "),offset:d.join(" ")}}a=c.extend({},c.ui.dialog.prototype.options.position,a)}else a=c.ui.dialog.prototype.options.position;(e=this.uiDialog.is(":visible"))||this.uiDialog.show();this.uiDialog.css({top:0,left:0}).position(c.extend({of:window},a));e||this.uiDialog.hide()},_setOptions:function(a){var b=this,d={},e=false;c.each(a,function(g,f){b._setOption(g,f); if(g in m)e=true;if(g in n)d[g]=f});e&&this._size();this.uiDialog.is(":data(resizable)")&&this.uiDialog.resizable("option",d)},_setOption:function(a,b){var d=this,e=d.uiDialog;switch(a){case "beforeclose":a="beforeClose";break;case "buttons":d._createButtons(b);break;case "closeText":d.uiDialogTitlebarCloseText.text(""+b);break;case "dialogClass":e.removeClass(d.options.dialogClass).addClass("ui-dialog ui-widget ui-widget-content ui-corner-all "+b);break;case "disabled":b?e.addClass("ui-dialog-disabled"): e.removeClass("ui-dialog-disabled");break;case "draggable":var g=e.is(":data(draggable)");g&&!b&&e.draggable("destroy");!g&&b&&d._makeDraggable();break;case "position":d._position(b);break;case "resizable":(g=e.is(":data(resizable)"))&&!b&&e.resizable("destroy");g&&typeof b==="string"&&e.resizable("option","handles",b);!g&&b!==false&&d._makeResizable(b);break;case "title":c(".ui-dialog-title",d.uiDialogTitlebar).html(""+(b||" "));break}c.Widget.prototype._setOption.apply(d,arguments)},_size:function(){var a= this.options,b,d,e=this.uiDialog.is(":visible");this.element.show().css({width:"auto",minHeight:0,height:0});if(a.minWidth>a.width)a.width=a.minWidth;b=this.uiDialog.css({height:"auto",width:a.width}).height();d=Math.max(0,a.minHeight-b);if(a.height==="auto")if(c.support.minHeight)this.element.css({minHeight:d,height:"auto"});else{this.uiDialog.show();a=this.element.css("height","auto").height();e||this.uiDialog.hide();this.element.height(Math.max(a,d))}else this.element.height(Math.max(a.height- b,0));this.uiDialog.is(":data(resizable)")&&this.uiDialog.resizable("option","minHeight",this._minHeight())}});c.extend(c.ui.dialog,{version:"1.8.16",uuid:0,maxZ:0,getTitleId:function(a){a=a.attr("id");if(!a){this.uuid+=1;a=this.uuid}return"ui-dialog-title-"+a},overlay:function(a){this.$el=c.ui.dialog.overlay.create(a)}});c.extend(c.ui.dialog.overlay,{instances:[],oldInstances:[],maxZ:0,events:c.map("focus,mousedown,mouseup,keydown,keypress,click".split(","),function(a){return a+".dialog-overlay"}).join(" "), create:function(a){if(this.instances.length===0){setTimeout(function(){c.ui.dialog.overlay.instances.length&&c(document).bind(c.ui.dialog.overlay.events,function(d){if(c(d.target).zIndex()").addClass("ui-widget-overlay")).appendTo(document.body).css({width:this.width(),height:this.height()});c.fn.bgiframe&&b.bgiframe();this.instances.push(b);return b},destroy:function(a){var b=c.inArray(a,this.instances);b!=-1&&this.oldInstances.push(this.instances.splice(b,1)[0]);this.instances.length===0&&c([document,window]).unbind(".dialog-overlay");a.remove();var d=0;c.each(this.instances,function(){d=Math.max(d,this.css("z-index"))});this.maxZ=d},height:function(){var a,b;if(c.browser.msie&& c.browser.version<7){a=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);b=Math.max(document.documentElement.offsetHeight,document.body.offsetHeight);return a").addClass("ui-slider-handle").appendTo(self.element); if (this.id) handle.attr("id", this.id); return handle[0]; }); } var handleclass = function(el) { this.element = $(el); this.element.data("mouse", this); this.options = self.options; this.element.bind("mousedown", function() { if(self.currentHandle) this.blur(self.currentHandle); self.focus(this,1); }); this.mouseInit(); }; $.extend(handleclass.prototype, $.ui.mouse, { mouseStart: function(e) { return self.start.call(self, e, this.element[0]); }, mouseStop: function(e) { return self.stop.call(self, e, this.element[0]); }, mouseDrag: function(e) { return self.drag.call(self, e, this.element[0]); }, trigger: function(e) { this.mouseDown(e); } }); $(this.handle) .each(function() { new handleclass(this); }) .wrap('') .parent() .bind('focus', function(e) { self.focus(this.firstChild); }) .bind('blur', function(e) { self.blur(this.firstChild); }) .bind('keydown', function(e) { if(!self.options.noKeyboard) self.keydown(e.keyCode, this.firstChild); }) ; // Bind the click to the slider itself this.element.bind('mousedown.slider', function(e) { self.click.apply(self, [e]); self.currentHandle.data("mouse").trigger(e); self.firstValue = self.firstValue + 1; //This is for always triggering the change event }); // Move the first handle to the startValue $.each(this.options.handles || [], function(index, handle) { self.moveTo(handle.start, index, true); }); if (!isNaN(this.options.startValue)) this.moveTo(this.options.startValue, 0, true); this.previousHandle = $(this.handle[0]); //set the previous handle to the first to allow clicking before selecting the handle if(this.handle.length == 2 && this.options.range) this.createRange(); }, initBoundaries: function() { var element = this.element[0], o = this.options; this.actualSize = { width: this.element.outerWidth() , height: this.element.outerHeight() }; $.extend(o, { axis: o.axis || (element.offsetWidth < element.offsetHeight ? 'vertical' : 'horizontal'), max: !isNaN(parseInt(o.max,10)) ? { x: parseInt(o.max, 10), y: parseInt(o.max, 10) } : ({ x: o.max && o.max.x || 100, y: o.max && o.max.y || 100 }), min: !isNaN(parseInt(o.min,10)) ? { x: parseInt(o.min, 10), y: parseInt(o.min, 10) } : ({ x: o.min && o.min.x || 0, y: o.min && o.min.y || 0 }) }); //Prepare the real maxValue o.realMax = { x: o.max.x - o.min.x, y: o.max.y - o.min.y }; //Calculate stepping based on steps o.stepping = { x: o.stepping && o.stepping.x || parseInt(o.stepping, 10) || (o.steps ? o.realMax.x/(o.steps.x || parseInt(o.steps, 10) || o.realMax.x) : 0), y: o.stepping && o.stepping.y || parseInt(o.stepping, 10) || (o.steps ? o.realMax.y/(o.steps.y || parseInt(o.steps, 10) || o.realMax.y) : 0) }; }, keydown: function(keyCode, handle) { if(/(37|38|39|40)/.test(keyCode)) { this.moveTo({ x: /(37|39)/.test(keyCode) ? (keyCode == 37 ? '-' : '+') + '=' + this.oneStep("x") : 0, y: /(38|40)/.test(keyCode) ? (keyCode == 38 ? '-' : '+') + '=' + this.oneStep("y") : 0 }, handle); } }, focus: function(handle,hard) { this.currentHandle = $(handle).addClass('ui-slider-handle-active'); if (hard) this.currentHandle.parent()[0].focus(); }, blur: function(handle) { $(handle).removeClass('ui-slider-handle-active'); if(this.currentHandle && this.currentHandle[0] == handle) { this.previousHandle = this.currentHandle; this.currentHandle = null; }; }, click: function(e) { // This method is only used if: // - The user didn't click a handle // - The Slider is not disabled // - There is a current, or previous selected handle (otherwise we wouldn't know which one to move) var pointer = [e.pageX,e.pageY]; var clickedHandle = false; this.handle.each(function() { if(this == e.target) clickedHandle = true; }); if (clickedHandle || this.disabled || !(this.currentHandle || this.previousHandle)) return; // If a previous handle was focussed, focus it again if (!this.currentHandle && this.previousHandle) this.focus(this.previousHandle, true); // propagate only for distance > 0, otherwise propagation is done my drag this.offset = this.element.offset(); this.moveTo({ y: this.convertValue(e.pageY - this.offset.top - this.currentHandle[0].offsetHeight/2, "y"), x: this.convertValue(e.pageX - this.offset.left - this.currentHandle[0].offsetWidth/2, "x") }, null, !this.options.distance); }, createRange: function() { this.rangeElement = $('
    ') .addClass('ui-slider-range') .css({ position: 'absolute' }) .appendTo(this.element); this.updateRange(); }, updateRange: function() { var prop = this.options.axis == "vertical" ? "top" : "left"; var size = this.options.axis == "vertical" ? "height" : "width"; this.rangeElement.css(prop, parseInt($(this.handle[0]).css(prop),10) + this.handleSize(0, this.options.axis == "vertical" ? "y" : "x")/2); this.rangeElement.css(size, parseInt($(this.handle[1]).css(prop),10) - parseInt($(this.handle[0]).css(prop),10)); }, getRange: function() { return this.rangeElement ? this.convertValue(parseInt(this.rangeElement.css(this.options.axis == "vertical" ? "height" : "width"),10), this.options.axis == "vertical" ? "y" : "x") : null; }, handleIndex: function() { return this.handle.index(this.currentHandle[0]); }, value: function(handle, axis) { if(this.handle.length == 1) this.currentHandle = this.handle; if(!axis) axis = this.options.axis == "vertical" ? "y" : "x"; var curHandle = $(handle != undefined && handle !== null ? this.handle[handle] || handle : this.currentHandle); if(curHandle.data("mouse").sliderValue) { return parseInt(curHandle.data("mouse").sliderValue[axis],10); } else { return parseInt(((parseInt(curHandle.css(axis == "x" ? "left" : "top"),10) / (this.actualSize[axis == "x" ? "width" : "height"] - this.handleSize(handle,axis))) * this.options.realMax[axis]) + this.options.min[axis],10); } }, convertValue: function(value,axis) { return this.options.min[axis] + (value / (this.actualSize[axis == "x" ? "width" : "height"] - this.handleSize(null,axis))) * this.options.realMax[axis]; }, translateValue: function(value,axis) { return ((value - this.options.min[axis]) / this.options.realMax[axis]) * (this.actualSize[axis == "x" ? "width" : "height"] - this.handleSize(null,axis)); }, translateRange: function(value,axis) { if (this.rangeElement) { if (this.currentHandle[0] == this.handle[0] && value >= this.translateValue(this.value(1),axis)) value = this.translateValue(this.value(1,axis) - this.oneStep(axis), axis); if (this.currentHandle[0] == this.handle[1] && value <= this.translateValue(this.value(0),axis)) value = this.translateValue(this.value(0,axis) + this.oneStep(axis), axis); } if (this.options.handles) { var handle = this.options.handles[this.handleIndex()]; if (value < this.translateValue(handle.min,axis)) { value = this.translateValue(handle.min,axis); } else if (value > this.translateValue(handle.max,axis)) { value = this.translateValue(handle.max,axis); } } return value; }, translateLimits: function(value,axis) { if (value >= this.actualSize[axis == "x" ? "width" : "height"] - this.handleSize(null,axis)) value = this.actualSize[axis == "x" ? "width" : "height"] - this.handleSize(null,axis); if (value <= 0) value = 0; return value; }, handleSize: function(handle,axis) { return $(handle != undefined && handle !== null ? this.handle[handle] : this.currentHandle)[0]["offset"+(axis == "x" ? "Width" : "Height")]; }, oneStep: function(axis) { return this.options.stepping[axis] || 1; }, start: function(e, handle) { var o = this.options; if(this.disabled) return false; // Prepare the outer size this.actualSize = { width: this.element.outerWidth() , height: this.element.outerHeight() }; // This is a especially ugly fix for strange blur events happening on mousemove events if (!this.currentHandle) this.focus(this.previousHandle, true); this.offset = this.element.offset(); this.handleOffset = this.currentHandle.offset(); this.clickOffset = { top: e.pageY - this.handleOffset.top, left: e.pageX - this.handleOffset.left }; this.firstValue = this.value(); this.propagate('start', e); return true; }, stop: function(e) { this.propagate('stop', e); if (this.firstValue != this.value()) this.propagate('change', e); // This is a especially ugly fix for strange blur events happening on mousemove events this.focus(this.currentHandle, true); return false; }, drag: function(e, handle) { var o = this.options; var position = { top: e.pageY - this.offset.top - this.clickOffset.top, left: e.pageX - this.offset.left - this.clickOffset.left}; if(!this.currentHandle) this.focus(this.previousHandle, true); //This is a especially ugly fix for strange blur events happening on mousemove events position.left = this.translateLimits(position.left, "x"); position.top = this.translateLimits(position.top, "y"); if (o.stepping.x) { var value = this.convertValue(position.left, "x"); value = Math.round(value / o.stepping.x) * o.stepping.x; position.left = this.translateValue(value, "x"); } if (o.stepping.y) { var value = this.convertValue(position.top, "y"); value = Math.round(value / o.stepping.y) * o.stepping.y; position.top = this.translateValue(value, "y"); } position.left = this.translateRange(position.left, "x"); position.top = this.translateRange(position.top, "y"); if(o.axis != "vertical") this.currentHandle.css({ left: position.left }); if(o.axis != "horizontal") this.currentHandle.css({ top: position.top }); //Store the slider's value this.currentHandle.data("mouse").sliderValue = { x: Math.round(this.convertValue(position.left, "x")) || 0, y: Math.round(this.convertValue(position.top, "y")) || 0 }; if (this.rangeElement) this.updateRange(); this.propagate('slide', e); return false; }, moveTo: function(value, handle, noPropagation) { var o = this.options; // Prepare the outer size this.actualSize = { width: this.element.outerWidth() , height: this.element.outerHeight() }; //If no handle has been passed, no current handle is available and we have multiple handles, return false if (handle == undefined && !this.currentHandle && this.handle.length != 1) return false; //If only one handle is available, use it if (handle == undefined && !this.currentHandle) handle = 0; if (handle != undefined) this.currentHandle = this.previousHandle = $(this.handle[handle] || handle); if(value.x !== undefined && value.y !== undefined) { var x = value.x, y = value.y; } else { var x = value, y = value; } if(x !== undefined && x.constructor != Number) { var me = /^\-\=/.test(x), pe = /^\+\=/.test(x); if(me || pe) { x = this.value(null, "x") + parseInt(x.replace(me ? '=' : '+=', ''), 10); } else { x = isNaN(parseInt(x, 10)) ? undefined : parseInt(x, 10); } } if(y !== undefined && y.constructor != Number) { var me = /^\-\=/.test(y), pe = /^\+\=/.test(y); if(me || pe) { y = this.value(null, "y") + parseInt(y.replace(me ? '=' : '+=', ''), 10); } else { y = isNaN(parseInt(y, 10)) ? undefined : parseInt(y, 10); } } if(o.axis != "vertical" && x !== undefined) { if(o.stepping.x) x = Math.round(x / o.stepping.x) * o.stepping.x; x = this.translateValue(x, "x"); x = this.translateLimits(x, "x"); x = this.translateRange(x, "x"); this.currentHandle.css({ left: x }); } if(o.axis != "horizontal" && y !== undefined) { if(o.stepping.y) y = Math.round(y / o.stepping.y) * o.stepping.y; y = this.translateValue(y, "y"); y = this.translateLimits(y, "y"); y = this.translateRange(y, "y"); this.currentHandle.css({ top: y }); } if (this.rangeElement) this.updateRange(); //Store the slider's value this.currentHandle.data("mouse").sliderValue = { x: Math.round(this.convertValue(x, "x")) || 0, y: Math.round(this.convertValue(y, "y")) || 0 }; if (!noPropagation) { this.propagate('start', null); this.propagate('stop', null); this.propagate('change', null); this.propagate("slide", null); } } }); $.ui.slider.getter = "value"; $.ui.slider.defaults = { handle: ".ui-slider-handle", distance: 1 }; })(jQuery); // ./ui.tabs.js /* * jQuery UI Tabs 1.7.2 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Tabs * * Depends: * ui.core.js */ (function($) { $.widget("ui.tabs", { _init: function() { if (this.options.deselectable !== undefined) { this.options.collapsible = this.options.deselectable; } this._tabify(true); }, _setData: function(key, value) { if (key == 'selected') { if (this.options.collapsible && value == this.options.selected) { return; } this.select(value); } else { this.options[key] = value; if (key == 'deselectable') { this.options.collapsible = value; } this._tabify(); } }, _tabId: function(a) { return a.title && a.title.replace(/\s/g, '_').replace(/[^A-Za-z0-9\-_:\.]/g, '') || this.options.idPrefix + $.data(a); }, _sanitizeSelector: function(hash) { return hash.replace(/:/g, '\\:'); // we need this because an id may contain a ":" }, _cookie: function() { var cookie = this.cookie || (this.cookie = this.options.cookie.name || 'ui-tabs-' + $.data(this.list[0])); return $.cookie.apply(null, [cookie].concat($.makeArray(arguments))); }, _ui: function(tab, panel) { return { tab: tab, panel: panel, index: this.anchors.index(tab) }; }, _cleanup: function() { // restore all former loading tabs labels this.lis.filter('.ui-state-processing').removeClass('ui-state-processing') .find('span:data(label.tabs)') .each(function() { var el = $(this); el.html(el.data('label.tabs')).removeData('label.tabs'); }); }, _tabify: function(init) { this.list = this.element.children('ul:first'); this.lis = $('li:has(a[href])', this.list); this.anchors = this.lis.map(function() { return $('a', this)[0]; }); this.panels = $([]); var self = this, o = this.options; var fragmentId = /^#.+/; // Safari 2 reports '#' for an empty hash this.anchors.each(function(i, a) { var href = $(a).attr('href'); // For dynamically created HTML that contains a hash as href IE < 8 expands // such href to the full page url with hash and then misinterprets tab as ajax. // Same consideration applies for an added tab with a fragment identifier // since a[href=#fragment-identifier] does unexpectedly not match. // Thus normalize href attribute... var hrefBase = href.split('#')[0], baseEl; if (hrefBase && (hrefBase === location.toString().split('#')[0] || (baseEl = $('base')[0]) && hrefBase === baseEl.href)) { href = a.hash; a.href = href; } // inline tab if (fragmentId.test(href)) { self.panels = self.panels.add(self._sanitizeSelector(href)); } // remote tab else if (href != '#') { // prevent loading the page itself if href is just "#" $.data(a, 'href.tabs', href); // required for restore on destroy // TODO until #3808 is fixed strip fragment identifier from url // (IE fails to load from such url) $.data(a, 'load.tabs', href.replace(/#.*$/, '')); // mutable data var id = self._tabId(a); a.href = '#' + id; var $panel = $('#' + id); if (!$panel.length) { $panel = $(o.panelTemplate).attr('id', id).addClass('ui-tabs-panel ui-widget-content ui-corner-bottom') .insertAfter(self.panels[i - 1] || self.list); $panel.data('destroy.tabs', true); } self.panels = self.panels.add($panel); } // invalid tab href else { o.disabled.push(i); } }); // initialization from scratch if (init) { // attach necessary classes for styling this.element.addClass('ui-tabs ui-widget ui-widget-content ui-corner-all'); this.list.addClass('ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all'); this.lis.addClass('ui-state-default ui-corner-top'); this.panels.addClass('ui-tabs-panel ui-widget-content ui-corner-bottom'); // Selected tab // use "selected" option or try to retrieve: // 1. from fragment identifier in url // 2. from cookie // 3. from selected class attribute on
  • if (o.selected === undefined) { if (location.hash) { this.anchors.each(function(i, a) { if (a.hash == location.hash) { o.selected = i; return false; // break } }); } if (typeof o.selected != 'number' && o.cookie) { o.selected = parseInt(self._cookie(), 10); } if (typeof o.selected != 'number' && this.lis.filter('.ui-tabs-selected').length) { o.selected = this.lis.index(this.lis.filter('.ui-tabs-selected')); } o.selected = o.selected || 0; } else if (o.selected === null) { // usage of null is deprecated, TODO remove in next release o.selected = -1; } // sanity check - default to first tab... o.selected = ((o.selected >= 0 && this.anchors[o.selected]) || o.selected < 0) ? o.selected : 0; // Take disabling tabs via class attribute from HTML // into account and update option properly. // A selected tab cannot become disabled. o.disabled = $.unique(o.disabled.concat( $.map(this.lis.filter('.ui-state-disabled'), function(n, i) { return self.lis.index(n); } ) )).sort(); if ($.inArray(o.selected, o.disabled) != -1) { o.disabled.splice($.inArray(o.selected, o.disabled), 1); } // highlight selected tab this.panels.addClass('ui-tabs-hide'); this.lis.removeClass('ui-tabs-selected ui-state-active'); if (o.selected >= 0 && this.anchors.length) { // check for length avoids error when initializing empty list this.panels.eq(o.selected).removeClass('ui-tabs-hide'); this.lis.eq(o.selected).addClass('ui-tabs-selected ui-state-active'); // seems to be expected behavior that the show callback is fired self.element.queue("tabs", function() { self._trigger('show', null, self._ui(self.anchors[o.selected], self.panels[o.selected])); }); this.load(o.selected); } // clean up to avoid memory leaks in certain versions of IE 6 $(window).bind('unload', function() { self.lis.add(self.anchors).unbind('.tabs'); self.lis = self.anchors = self.panels = null; }); } // update selected after add/remove else { o.selected = this.lis.index(this.lis.filter('.ui-tabs-selected')); } // update collapsible this.element[o.collapsible ? 'addClass' : 'removeClass']('ui-tabs-collapsible'); // set or update cookie after init and add/remove respectively if (o.cookie) { this._cookie(o.selected, o.cookie); } // disable tabs for (var i = 0, li; (li = this.lis[i]); i++) { $(li)[$.inArray(i, o.disabled) != -1 && !$(li).hasClass('ui-tabs-selected') ? 'addClass' : 'removeClass']('ui-state-disabled'); } // reset cache if switching from cached to not cached if (o.cache === false) { this.anchors.removeData('cache.tabs'); } // remove all handlers before, tabify may run on existing tabs after add or option change this.lis.add(this.anchors).unbind('.tabs'); if (o.event != 'mouseover') { var addState = function(state, el) { if (el.is(':not(.ui-state-disabled)')) { el.addClass('ui-state-' + state); } }; var removeState = function(state, el) { el.removeClass('ui-state-' + state); }; this.lis.bind('mouseover.tabs', function() { addState('hover', $(this)); }); this.lis.bind('mouseout.tabs', function() { removeState('hover', $(this)); }); this.anchors.bind('focus.tabs', function() { addState('focus', $(this).closest('li')); }); this.anchors.bind('blur.tabs', function() { removeState('focus', $(this).closest('li')); }); } // set up animations var hideFx, showFx; if (o.fx) { if ($.isArray(o.fx)) { hideFx = o.fx[0]; showFx = o.fx[1]; } else { hideFx = showFx = o.fx; } } // Reset certain styles left over from animation // and prevent IE's ClearType bug... function resetStyle($el, fx) { $el.css({ display: '' }); if ($.browser.msie && fx.opacity) { $el[0].style.removeAttribute('filter'); } } // Show a tab... var showTab = showFx ? function(clicked, $show) { $(clicked).closest('li').removeClass('ui-state-default').addClass('ui-tabs-selected ui-state-active'); $show.hide().removeClass('ui-tabs-hide') // avoid flicker that way .animate(showFx, showFx.duration || 'normal', function() { resetStyle($show, showFx); self._trigger('show', null, self._ui(clicked, $show[0])); }); } : function(clicked, $show) { $(clicked).closest('li').removeClass('ui-state-default').addClass('ui-tabs-selected ui-state-active'); $show.removeClass('ui-tabs-hide'); self._trigger('show', null, self._ui(clicked, $show[0])); }; // Hide a tab, $show is optional... var hideTab = hideFx ? function(clicked, $hide) { $hide.animate(hideFx, hideFx.duration || 'normal', function() { self.lis.removeClass('ui-tabs-selected ui-state-active').addClass('ui-state-default'); $hide.addClass('ui-tabs-hide'); resetStyle($hide, hideFx); self.element.dequeue("tabs"); }); } : function(clicked, $hide, $show) { self.lis.removeClass('ui-tabs-selected ui-state-active').addClass('ui-state-default'); $hide.addClass('ui-tabs-hide'); self.element.dequeue("tabs"); }; // attach tab event handler, unbind to avoid duplicates from former tabifying... this.anchors.bind(o.event + '.tabs', function() { var el = this, $li = $(this).closest('li'), $hide = self.panels.filter(':not(.ui-tabs-hide)'), $show = $(self._sanitizeSelector(this.hash)); // If tab is already selected and not collapsible or tab disabled or // or is already loading or click callback returns false stop here. // Check if click handler returns false last so that it is not executed // for a disabled or loading tab! if (($li.hasClass('ui-tabs-selected') && !o.collapsible) || $li.hasClass('ui-state-disabled') || $li.hasClass('ui-state-processing') || self._trigger('select', null, self._ui(this, $show[0])) === false) { this.blur(); return false; } o.selected = self.anchors.index(this); self.abort(); // if tab may be closed if (o.collapsible) { if ($li.hasClass('ui-tabs-selected')) { o.selected = -1; if (o.cookie) { self._cookie(o.selected, o.cookie); } self.element.queue("tabs", function() { hideTab(el, $hide); }).dequeue("tabs"); this.blur(); return false; } else if (!$hide.length) { if (o.cookie) { self._cookie(o.selected, o.cookie); } self.element.queue("tabs", function() { showTab(el, $show); }); self.load(self.anchors.index(this)); // TODO make passing in node possible, see also http://dev.jqueryui.com/ticket/3171 this.blur(); return false; } } if (o.cookie) { self._cookie(o.selected, o.cookie); } // show new tab if ($show.length) { if ($hide.length) { self.element.queue("tabs", function() { hideTab(el, $hide); }); } self.element.queue("tabs", function() { showTab(el, $show); }); self.load(self.anchors.index(this)); } else { throw 'jQuery UI Tabs: Mismatching fragment identifier.'; } // Prevent IE from keeping other link focussed when using the back button // and remove dotted border from clicked link. This is controlled via CSS // in modern browsers; blur() removes focus from address bar in Firefox // which can become a usability and annoying problem with tabs('rotate'). if ($.browser.msie) { this.blur(); } }); // disable click in any case this.anchors.bind('click.tabs', function(){return false;}); }, destroy: function() { var o = this.options; this.abort(); this.element.unbind('.tabs') .removeClass('ui-tabs ui-widget ui-widget-content ui-corner-all ui-tabs-collapsible') .removeData('tabs'); this.list.removeClass('ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all'); this.anchors.each(function() { var href = $.data(this, 'href.tabs'); if (href) { this.href = href; } var $this = $(this).unbind('.tabs'); $.each(['href', 'load', 'cache'], function(i, prefix) { $this.removeData(prefix + '.tabs'); }); }); this.lis.unbind('.tabs').add(this.panels).each(function() { if ($.data(this, 'destroy.tabs')) { $(this).remove(); } else { $(this).removeClass([ 'ui-state-default', 'ui-corner-top', 'ui-tabs-selected', 'ui-state-active', 'ui-state-hover', 'ui-state-focus', 'ui-state-disabled', 'ui-tabs-panel', 'ui-widget-content', 'ui-corner-bottom', 'ui-tabs-hide' ].join(' ')); } }); if (o.cookie) { this._cookie(null, o.cookie); } }, add: function(url, label, index) { if (index === undefined) { index = this.anchors.length; // append by default } var self = this, o = this.options, $li = $(o.tabTemplate.replace(/#\{href\}/g, url).replace(/#\{label\}/g, label)), id = !url.indexOf('#') ? url.replace('#', '') : this._tabId($('a', $li)[0]); $li.addClass('ui-state-default ui-corner-top').data('destroy.tabs', true); // try to find an existing element before creating a new one var $panel = $('#' + id); if (!$panel.length) { $panel = $(o.panelTemplate).attr('id', id).data('destroy.tabs', true); } $panel.addClass('ui-tabs-panel ui-widget-content ui-corner-bottom ui-tabs-hide'); if (index >= this.lis.length) { $li.appendTo(this.list); $panel.appendTo(this.list[0].parentNode); } else { $li.insertBefore(this.lis[index]); $panel.insertBefore(this.panels[index]); } o.disabled = $.map(o.disabled, function(n, i) { return n >= index ? ++n : n; }); this._tabify(); if (this.anchors.length == 1) { // after tabify $li.addClass('ui-tabs-selected ui-state-active'); $panel.removeClass('ui-tabs-hide'); this.element.queue("tabs", function() { self._trigger('show', null, self._ui(self.anchors[0], self.panels[0])); }); this.load(0); } // callback this._trigger('add', null, this._ui(this.anchors[index], this.panels[index])); }, remove: function(index) { var o = this.options, $li = this.lis.eq(index).remove(), $panel = this.panels.eq(index).remove(); // If selected tab was removed focus tab to the right or // in case the last tab was removed the tab to the left. if ($li.hasClass('ui-tabs-selected') && this.anchors.length > 1) { this.select(index + (index + 1 < this.anchors.length ? 1 : -1)); } o.disabled = $.map($.grep(o.disabled, function(n, i) { return n != index; }), function(n, i) { return n >= index ? --n : n; }); this._tabify(); // callback this._trigger('remove', null, this._ui($li.find('a')[0], $panel[0])); }, enable: function(index) { var o = this.options; if ($.inArray(index, o.disabled) == -1) { return; } this.lis.eq(index).removeClass('ui-state-disabled'); o.disabled = $.grep(o.disabled, function(n, i) { return n != index; }); // callback this._trigger('enable', null, this._ui(this.anchors[index], this.panels[index])); }, disable: function(index) { var self = this, o = this.options; if (index != o.selected) { // cannot disable already selected tab this.lis.eq(index).addClass('ui-state-disabled'); o.disabled.push(index); o.disabled.sort(); // callback this._trigger('disable', null, this._ui(this.anchors[index], this.panels[index])); } }, select: function(index) { if (typeof index == 'string') { index = this.anchors.index(this.anchors.filter('[href$=' + index + ']')); } else if (index === null) { // usage of null is deprecated, TODO remove in next release index = -1; } if (index == -1 && this.options.collapsible) { index = this.options.selected; } this.anchors.eq(index).trigger(this.options.event + '.tabs'); }, load: function(index) { var self = this, o = this.options, a = this.anchors.eq(index)[0], url = $.data(a, 'load.tabs'); this.abort(); // not remote or from cache if (!url || this.element.queue("tabs").length !== 0 && $.data(a, 'cache.tabs')) { this.element.dequeue("tabs"); return; } // load remote from here on this.lis.eq(index).addClass('ui-state-processing'); if (o.spinner) { var span = $('span', a); span.data('label.tabs', span.html()).html(o.spinner); } this.xhr = $.ajax($.extend({}, o.ajaxOptions, { url: url, success: function(r, s) { $(self._sanitizeSelector(a.hash)).html(r); // take care of tab labels self._cleanup(); if (o.cache) { $.data(a, 'cache.tabs', true); // if loaded once do not load them again } // callbacks self._trigger('load', null, self._ui(self.anchors[index], self.panels[index])); try { o.ajaxOptions.success(r, s); } catch (e) {} // last, so that load event is fired before show... self.element.dequeue("tabs"); } })); }, abort: function() { // stop possibly running animations this.element.queue([]); this.panels.stop(false, true); // terminate pending requests from other tabs if (this.xhr) { this.xhr.abort(); delete this.xhr; } // take care of tab labels this._cleanup(); }, url: function(index, url) { this.anchors.eq(index).removeData('cache.tabs').data('load.tabs', url); }, length: function() { return this.anchors.length; } }); $.extend($.ui.tabs, { version: '1.7.2', getter: 'length', defaults: { ajaxOptions: null, cache: false, cookie: null, // e.g. { expires: 7, path: '/', domain: 'jquery.com', secure: true } collapsible: false, disabled: [], event: 'click', fx: null, // e.g. { height: 'toggle', opacity: 'toggle', duration: 200 } idPrefix: 'ui-tabs-', panelTemplate: '
    ', spinner: 'Loading…', tabTemplate: '
  • #{label}
  • ' } }); /* * Tabs Extensions */ /* * Rotate */ $.extend($.ui.tabs.prototype, { rotation: null, rotate: function(ms, continuing) { var self = this, o = this.options; var rotate = self._rotate || (self._rotate = function(e) { clearTimeout(self.rotation); self.rotation = setTimeout(function() { var t = o.selected; self.select( ++t < self.anchors.length ? t : 0 ); }, ms); if (e) { e.stopPropagation(); } }); var stop = self._unrotate || (self._unrotate = !continuing ? function(e) { if (e.clientX) { // in case of a true click self.rotate(null); } } : function(e) { t = o.selected; rotate(); }); // start rotation if (ms) { this.element.bind('tabsshow', rotate); this.anchors.bind(o.event + '.tabs', stop); rotate(); } // stop rotation else { clearTimeout(self.rotation); this.element.unbind('tabsshow', rotate); this.anchors.unbind(o.event + '.tabs', stop); delete this._rotate; delete this._unrotate; } } }); })(jQuery); // ./jquery.jfontsizer.js /* * * jFontSizer Plugin * Written by fluidByte - http://www.fluidbyte.net * * */ jQuery.fn.jfontsizer = function(o) { // Cookie functions function setCookie(c_name,value,expiredays){ var exdate=new Date(); exdate.setDate(exdate.getDate()+expiredays); document.cookie=c_name+ "=" +escape(value)+ ((expiredays==null) ? "" : ";expires="+exdate.toGMTString()); } function getCookie(c_name){ if (document.cookie.length>0){ c_start=document.cookie.indexOf(c_name + "="); if (c_start!=-1){ c_start=c_start + c_name.length+1; c_end=document.cookie.indexOf(";",c_start); if (c_end==-1) c_end=document.cookie.length; return unescape(document.cookie.substring(c_start,c_end)); } } return ""; } // Defaults var o = jQuery.extend( { applyTo: 'body', changesmall: '2', changelarge: '2', expire: 30 },o); var s = ''; var m = ''; var l = ''; // Current var c = 'fs_med'; // Check cookie if (getCookie('fsizer') != "") { var c = getCookie('fsizer'); switch (c) { case 'fs_sml': s = 'fsactive'; $(o.applyTo).css('font-size','.'+(10-o.changesmall)+'em'); break; case 'fs_med': m = 'fsactive'; $(o.applyTo).css('font-size','1em'); break; case 'fs_lrg': l = 'fsactive'; $(o.applyTo).css('font-size','1.'+o.changelarge+'em'); break; } } else { m = "fsactive"; } // Create font-chooser box $(this).html(''); $('.fsizer a').click(function(){ var t = $(this).attr('id'); setCookie('fsizer',t,o.expire); $('.fsizer a').removeClass('fsactive'); $(this).addClass('fsactive'); var f = $(o.applyTo).css('font-size'); switch(t){ case 'fs_sml': $(o.applyTo).css('font-size','.'+(10-o.changesmall)+'em'); break; case 'fs_med': $(o.applyTo).css('font-size','1em'); break; case 'fs_lrg': $(o.applyTo).css('font-size','1.'+o.changelarge+'em'); break; } }); }; // ./jquery.scrollTo-min.js /** * jQuery.ScrollTo - Easy element scrolling using jQuery. * Copyright (c) 2007-2009 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com * Dual licensed under MIT and GPL. * Date: 5/25/2009 * @author Ariel Flesler * @version 1.4.2 * * http://flesler.blogspot.com/2007/10/jqueryscrollto.html */ ;(function(d){var k=d.scrollTo=function(a,i,e){d(window).scrollTo(a,i,e)};k.defaults={axis:'xy',duration:parseFloat(d.fn.jquery)>=1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery); // ./adminDropdownMenu.js function mkDropdownBinder() { $(".zeigeWelcomIcons > div > a > img").unbind('click').bind('click', function(e) { /**$(".zeigeWelcomIcons > div > a > img").unbind('mouseover').bind('mouseover', function(e) {**/ if($("#adminDropdownMenu").length == 0) { var relativeX = e.pageX +1; var relativeY = e.pageY; var MODUL = $(this).attr('class'); var element = this; $.ajax({ url: '/admin/includesOpen/ajax_adminDrowdownMenu.php', type: 'POST', data: {key: 'demoding', modulname: MODUL}, success: function(data) { $(element).css('position', 'relative').css('zIndex', '1001'); $("body").append(data); $("#adminDropdownMenu").css('top', relativeY + 'px').css('left', relativeX + 'px'); $("#blackPopuptrans").clone(true).prependTo("body").css('backgroundColor', '#fff').attr('class', 'blackPopupClone').show().bind('mouseover', function() { $(".blackPopupClone").remove(); $("#adminDropdownMenu").remove(); $(element).css('position', 'static'); }); if(!data) { window.location = $(element).parent().attr('href'); } } }) }else{ $("#blackPopuptrans").remove(); $("#adminDropdownMenu").remove(); $(element).css('position', 'static'); } return false; }).bind('dblclick', function() { window.location = $(this).parent().attr('href'); }) } $(document).ready(function() { mkDropdownBinder(); }); // ./jquery.jcorners.js /** * jCorners - Cross-Browser Corners with JQuery * http://jcorners.culturezoo.com/ * * Copyright (c) 2008 Levi Nunnink, Culturezoo, LLC (http://culturezoo.com) * Licensed under the GPL * * Built on top of the jQuery library * http://jquery.com * * Inspired by the "Corners Experiment" by Jonathan Snook * http://snook.ca/archives/html_and_css/rounded_corners_experiment_ie/ */ var defaults = { radius: 5 }; jQuery.fn.jcorners = function(o) { return this.each(function() { new $jc(this, o); }); }; jQuery.jcorners = function(e, o) { this.options = $.extend({}, defaults, o || {}); if(this.browser.msie){ this("body").prepend(""); if($(e).css("background-color") != undefined){ var bg = $(e).css("background-color"); }else{ var bg = "white"; } var guid = this.guid(); var padding = this.intval(this(e).css("padding")); var arc = (this.options.radius / this(e).height()); this(e).wrap(""); this("#wrapper-"+guid+"").css("behavior","url(#default#VML)"); this("#wrapper-"+guid+"").css("background-color","transparent"); this("#wrapper-"+guid+"").css("padding",this.options.radius+"px"); this("#wrapper-"+guid+"").css("height","100%"); this("#wrapper-"+guid+"").css("width",this(e).width()+(padding*2)+"px"); this("#wrapper-"+guid+"").css("border-color:",bg); this("#wrapper-"+guid+"").css("display","inline-block"); }else if(this.browser.mozilla){ this(e).css("-moz-border-radius",this.options.radius+"px"); }else if(this.browser.safari){ this(e).css("-webkit-border-radius",this.options.radius+"px"); }else{ this(e).css("border-radius",this.options.radius+"px"); } return this; } jQuery.extend({ intval: function(v) { v = parseInt(v); return isNaN(v) ? 0 : v; }, guid: function(){ var result, i, j; result = ''; for(j=0; j<32; j++) { if( j == 8 || j == 12|| j == 16|| j == 20) result = result + '-'; i = Math.floor(Math.random()*16).toString(16).toUpperCase(); result = result + i; } return result } }); // ./jquery.curvycorners_source.js /**************************************************************** * * * JQuery Curvy Corners by Mike Jolley * * http://blue-anvil.com * * http://code.google.com/p/jquerycurvycorners/ * * ========================================================== * * * * Version 2.1.1 (Based on CC 2.1 beta) * * * * Original by: Terry Riegel, Cameron Cooke and Tim Hutchison * * Website: http://www.curvycorners.net * * * * This library is free software; you can redistribute * * it and/or modify it under the terms of the GNU * * Lesser General Public License as published by the * * Free Software Foundation; either version 2.1 of the * * License, or (at your option) any later version. * * * * This library is distributed in the hope that it will * * be useful, but WITHOUT ANY WARRANTY; without even the * * implied warranty of MERCHANTABILITY or FITNESS FOR A * * PARTICULAR PURPOSE. See the GNU Lesser General Public * * License for more details. * * * * You should have received a copy of the GNU Lesser * * General Public License along with this library; * * Inc., 59 Temple Place, Suite 330, Boston, * * MA 02111-1307 USA * * * ****************************************************************/ /* Usage: To use this plugin just apply borders via CSS Rules and include this plugin - it will automatically detect styles and apply corners. Opera and Chrome support rounded corners via border-radius Safari and Mozilla support rounded borders via -webkit-border-radius and -moz-border-radius IE (any version) does not support border-radius - this is all we need to support. So to make curvycorners work with any major browser simply add the following CSS declarations: .round { border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; } ---- If you don't want to use the above method, you can still use the direct syntax if you want: $('.myBox').corner(); The script will still use border-radius for those which support it. */ (function($) { // object that parses border-radius properties for a box function curvyCnrSpec(selText) { this.selectorText = selText; this.tlR = this.trR = this.blR = this.brR = 0; this.tlu = this.tru = this.blu = this.bru = ""; this.antiAlias = true; // default true }; curvyCnrSpec.prototype.setcorner = function(tb, lr, radius, unit) { if (!tb) { // no corner specified this.tlR = this.trR = this.blR = this.brR = parseInt(radius); this.tlu = this.tru = this.blu = this.bru = unit; } else { // corner specified propname = tb.charAt(0) + lr.charAt(0); this[propname + 'R'] = parseInt(radius); this[propname + 'u'] = unit; } }; curvyCnrSpec.prototype.get = function(prop) { if (/^(t|b)(l|r)(R|u)$/.test(prop)) return this[prop]; if (/^(t|b)(l|r)Ru$/.test(prop)) { var pname = prop.charAt(0) + prop.charAt(1); return this[pname + 'R'] + this[pname + 'u']; } if (/^(t|b)Ru?$/.test(prop)) { var tb = prop.charAt(0); tb += this[tb + 'lR'] > this[tb + 'rR'] ? 'l' : 'r'; var retval = this[tb + 'R']; if (prop.length === 3 && prop.charAt(2) === 'u') retval += this[tb = 'u']; return retval; } throw new Error('Don\'t recognize property ' + prop); }; curvyCnrSpec.prototype.radiusdiff = function(tb) { if (tb !== 't' && tb !== 'b') throw new Error("Param must be 't' or 'b'"); return Math.abs(this[tb + 'lR'] - this[tb + 'rR']); }; curvyCnrSpec.prototype.setfrom = function(obj) { this.tlu = this.tru = this.blu = this.bru = 'px'; // default to px if ('tl' in obj) this.tlR = obj.tl.radius; if ('tr' in obj) this.trR = obj.tr.radius; if ('bl' in obj) this.blR = obj.bl.radius; if ('br' in obj) this.brR = obj.br.radius; if ('antiAlias' in obj) this.antiAlias = obj.antiAlias; }; curvyCnrSpec.prototype.cloneOn = function(box) { // not needed by IE var props = ['tl', 'tr', 'bl', 'br']; var converted = 0; var i, propu; for (i in props) if (!isNaN(i)) { propu = this[props[i] + 'u']; if (propu !== '' && propu !== 'px') { converted = new curvyCnrSpec; break; } } if (!converted) converted = this; // no need to clone else { var propi, propR, save = curvyBrowser.get_style(box, 'left'); for (i in props) if (!isNaN(i)) { propi = props[i]; propu = this[propi + 'u']; propR = this[propi + 'R']; if (propu !== 'px') { var save = box.style.left; box.style.left = propR + propu; propR = box.style.pixelLeft; box.style.left = save; } converted[propi + 'R'] = propR; converted[propi + 'u'] = 'px'; } box.style.left = save; } return converted; }; curvyCnrSpec.prototype.radiusSum = function(tb) { if (tb !== 't' && tb !== 'b') throw new Error("Param must be 't' or 'b'"); return this[tb + 'lR'] + this[tb + 'rR']; }; curvyCnrSpec.prototype.radiusCount = function(tb) { var count = 0; if (this[tb + 'lR']) ++count; if (this[tb + 'rR']) ++count; return count; }; curvyCnrSpec.prototype.cornerNames = function() { var ret = []; if (this.tlR) ret.push('tl'); if (this.trR) ret.push('tr'); if (this.blR) ret.push('bl'); if (this.brR) ret.push('br'); return ret; }; if (typeof redrawList === 'undefined') redrawList = new Array; $.fn.corner = function(options) { // Check for Native Round Corners var nativeCornersSupported = false; var checkWebkit, checkMozilla, checkStandard; try { checkWebkit = (document.body.style.WebkitBorderRadius !== undefined); } catch(err) {} try { checkMozilla = (document.body.style.MozBorderRadius !== undefined); } catch(err) {} try { checkStandard = (document.body.style.BorderRadius !== undefined); } catch(err) {} try { checkStandard = (document.body.style.borderRadius !== undefined); } catch(err) {} if (checkWebkit || checkMozilla || checkStandard) nativeCornersSupported = true; if (options instanceof curvyCnrSpec) { settings = options; } else { var options = jQuery.extend({ tl: { radius: 8 }, tr: { radius: 8 }, bl: { radius: 8 }, br: { radius: 8 }, antiAlias: true }, options); var settings = new curvyCnrSpec(this); settings.setfrom(options); } // Apply the corners to the passed object! function curvyObject() { // Setup Globals this.box = arguments[1]; this.settings = arguments[0]; var $$ = $(this.box); var boxDisp; this.masterCorners = new Array(); //this.contentDIV = null; this.topContainer = this.bottomContainer = this.shell = boxDisp = null; // Get CSS of box and define vars var boxWidth = $$.innerWidth(); // Does not include border width if ($$.is('table')) throw new Error("You cannot apply corners to " + this.box.tagName + " elements.", "Error"); // try to handle attempts to style inline elements if ($$.css('display') === 'inline') { $$.css('display', 'inline-block'); } // all attempts have failed if (!boxWidth) { this.applyCorners = function() {}; // make the error harmless return; } if (arguments[0] instanceof curvyCnrSpec) { this.spec = arguments[0].cloneOn(this.box); // convert non-pixel units } else { this.spec = new curvyCnrSpec(''); this.spec.setfrom(this.settings); // no need for unit conversion, use settings param. directly } // Get box formatting details var borderWidth = $$.css("borderTopWidth") ? $$.css("borderTopWidth") : 0; var borderWidthB = $$.css("borderBottomWidth") ? $$.css("borderBottomWidth") : 0; var borderWidthL = $$.css("borderLeftWidth") ? $$.css("borderLeftWidth") : 0; var borderWidthR = $$.css("borderRightWidth") ? $$.css("borderRightWidth") : 0; var borderColour = $$.css("borderTopColor"); var borderColourB = $$.css("borderBottomColor"); var borderColourL = $$.css("borderLeftColor"); var borderColourR = $$.css("borderRightColor"); var borderStyle = $$.css("borderTopStyle"); var borderStyleB = $$.css("borderBottomStyle"); var borderStyleL = $$.css("borderLeftStyle"); var borderStyleR = $$.css("borderRightStyle"); var boxColour = $$.css("backgroundColor"); var backgroundImage = $$.css("backgroundImage"); var backgroundRepeat= $$.css("backgroundRepeat"); var backgroundPosX, backgroundPosY; backgroundPosX = $$.css("backgroundPositionX") ? $$.css("backgroundPositionX") : 0; backgroundPosY = $$.css("backgroundPositionY") ? $$.css("backgroundPositionY") : 0; var boxPosition = $$.css("position"); var topPadding = $$.css("paddingTop"); var bottomPadding = $$.css("paddingBottom"); var leftPadding = $$.css("paddingLeft"); var rightPadding = $$.css("paddingRight"); var border = $$.css("border"); var filter = jQuery.browser.version > 7 && $.browser.msie ? $$.css("filter") : null; // IE8 bug fix var topMaxRadius = this.spec.get('tR'); var botMaxRadius = this.spec.get('bR'); var styleToNPx = function(val) { if (typeof val === 'number') return val; if (typeof val !== 'string') throw new Error('unexpected styleToNPx type ' + typeof val); var matches = /^[-\d.]([a-z]+)$/.exec(val); if (matches && matches[1] != 'px') throw new Error('Unexpected unit ' + matches[1]); if (isNaN(val = parseInt(val))) val = 0; return val; }; var min0Px = function(val) { return val <= 0 ? "0" : val + "px"; }; // Set formatting properties try { this.borderWidth = styleToNPx(borderWidth); this.borderWidthB = styleToNPx(borderWidthB); this.borderWidthL = styleToNPx(borderWidthL); this.borderWidthR = styleToNPx(borderWidthR); this.boxColour = curvyObject.format_colour(boxColour); this.topPadding = styleToNPx(topPadding); this.bottomPadding = styleToNPx(bottomPadding); this.leftPadding = styleToNPx(leftPadding); this.rightPadding = styleToNPx(rightPadding); this.boxWidth = boxWidth; this.boxHeight = $$.innerHeight(); // No border this.borderColour = curvyObject.format_colour(borderColour); this.borderColourB = curvyObject.format_colour(borderColourB); this.borderColourL = curvyObject.format_colour(borderColourL); this.borderColourR = curvyObject.format_colour(borderColourR); this.borderString = this.borderWidth + "px" + " " + borderStyle + " " + this.borderColour; this.borderStringB = this.borderWidthB + "px" + " " + borderStyleB + " " + this.borderColourB; this.borderStringL = this.borderWidthL + "px" + " " + borderStyleL + " " + this.borderColourL; this.borderStringR = this.borderWidthR + "px" + " " + borderStyleR + " " + this.borderColourR; this.backgroundImage = (backgroundImage != "none" && backgroundImage!="initial") ? backgroundImage : ""; this.backgroundRepeat= backgroundRepeat; } catch(e) {} var clientHeight = this.boxHeight; var clientWidth = boxWidth; // save it as it gets trampled on later if ($.browser.opera) { backgroundPosX = styleToNPx(backgroundPosX); backgroundPosY = styleToNPx(backgroundPosY); if (backgroundPosX) { var t = clientWidth + this.borderWidthL + this.borderWidthR; if (backgroundPosX > t) backgroundPosX = t; backgroundPosX = (t / backgroundPosX * 100) + '%'; // convert to percentage } if (backgroundPosY) { var t = clientHeight + this.borderWidth + this.borderWidthB; if (backgroundPosY > t) backgroundPosY = t; backgroundPosY = (t / backgroundPosY * 100) + '%'; // convert to percentage } } // Create content container this.contentContainer = document.createElement("div"); if (filter) this.contentContainer.style.filter = filter; // IE8 bug fix while (this.box.firstChild) this.contentContainer.appendChild(this.box.removeChild(this.box.firstChild)); if (boxPosition != "absolute") $$.css("position", "relative"); this.box.style.padding = '0'; this.box.style.border = this.box.style.backgroundImage = 'none'; this.box.style.backgroundColor = 'transparent'; this.box.style.width = (clientWidth + this.borderWidthL + this.borderWidthR) + 'px'; this.box.style.height = (clientHeight + this.borderWidth + this.borderWidthB) + 'px'; // Ok we add an inner div to actually put things into this will allow us to keep the height var newMainContainer = document.createElement("div"); $(newMainContainer).css({ width: clientWidth + 'px', 'padding': "0", position: "absolute", height: min0Px(clientHeight + this.borderWidth + this.borderWidthB - topMaxRadius - botMaxRadius), top: topMaxRadius + "px", left: "0", 'backgroundColor': boxColour, 'backgroundImage': this.backgroundImage, 'backgroundRepeat': this.backgroundRepeat, 'direction': 'ltr' }); if (filter) $(newMainContainer).css('filter', 'filter'); // IE8 bug fix if (this.borderWidthL) $(newMainContainer).css('borderLeft', this.borderStringL); if (this.borderWidth && !topMaxRadius) $(newMainContainer).css('borderTop', this.borderString); if (this.borderWidthR) $(newMainContainer).css('borderRight', this.borderStringR); if (this.borderWidthB && !botMaxRadius) $(newMainContainer).css('borderBottom', this.borderStringB); this.shell = this.box.appendChild(newMainContainer); boxWidth = $(this.shell).css("width"); if (boxWidth === "" || boxWidth === "auto" || boxWidth.indexOf("%") !== -1) throw Error('Shell width is ' + boxWidth); this.boxWidth = (boxWidth != "" && boxWidth != "auto" && boxWidth.indexOf("%") == -1) ? parseInt(boxWidth) : $(this.shell).width(); this.applyCorners = function() { /* Set up background offsets. This may need to be delayed until the background image is loaded. */ this.backgroundPosX = this.backgroundPosY = 0; if (this.backgroundObject) { var bgOffset = function(style, imglen, boxlen) { if (style === 0) return 0; var retval; if (style === 'right' || style === 'bottom') return boxlen - imglen; if (style === 'center') return (boxlen - imglen) / 2; if (style.indexOf('%') > 0) return (boxlen - imglen) / (100 / parseInt(style)); return styleToNPx(style); }; this.backgroundPosX = bgOffset(backgroundPosX, this.backgroundObject.width, clientWidth); this.backgroundPosY = bgOffset(backgroundPosY, this.backgroundObject.height, clientHeight); } else if (this.backgroundImage) { this.backgroundPosX = styleToNPx(backgroundPosX); this.backgroundPosY = styleToNPx(backgroundPosY); } /* Create top and bottom containers. These will be used as a parent for the corners and bars. */ // Build top bar only if a top corner is to be drawn if (topMaxRadius) { newMainContainer = document.createElement("div"); $(newMainContainer).css({ width: this.boxWidth + "px", 'fontSize': "1px", overflow: "hidden", position: "absolute", 'paddingLeft': this.borderWidth + "px", 'paddingRight': this.borderWidth + "px", height: topMaxRadius + "px", top: -topMaxRadius + "px", left: -this.borderWidthL + "px" }); this.topContainer = this.shell.appendChild(newMainContainer); } // Build bottom bar only if a bottom corner is to be drawn if (botMaxRadius) { var newMainContainer = document.createElement("div"); $(newMainContainer).css({ width: this.boxWidth + "px", 'fontSize': "1px", overflow: "hidden", position: "absolute", 'paddingLeft': this.borderWidthB + "px", 'paddingRight': this.borderWidthB + "px", height: botMaxRadius + "px", bottom: -botMaxRadius + "px", left: -this.borderWidthL + "px" }); this.bottomContainer = this.shell.appendChild(newMainContainer); } var corners = this.spec.cornerNames(); // array of available corners /* Loop for each corner */ for (var i in corners) if (!isNaN(i)) { // Get current corner type from array var cc = corners[i]; var specRadius = this.spec[cc + 'R']; // Has the user requested the currentCorner be round? // Code to apply correct color to top or bottom var bwidth, bcolor, borderRadius, borderWidthTB; if (cc == "tr" || cc == "tl") { bwidth = this.borderWidth; bcolor = this.borderColour; borderWidthTB = this.borderWidth; } else { bwidth = this.borderWidthB; bcolor = this.borderColourB; borderWidthTB = this.borderWidthB; } borderRadius = specRadius - borderWidthTB; var newCorner = document.createElement("div"); $(newCorner).css({ position:"absolute", "font-size":"1px", overflow:"hidden" }).height(this.spec.get(cc + 'Ru')).width(this.spec.get(cc + 'Ru')); // THE FOLLOWING BLOCK OF CODE CREATES A ROUNDED CORNER // ---------------------------------------------------- TOP var intx, inty, outsideColour; var trans = filter ? parseInt(/alpha\(opacity.(\d+)\)/.exec(filter)[1]) : 100; // IE8 bug fix // Cycle the x-axis for (intx = 0; intx < specRadius; ++intx) { // Calculate the value of y1 which identifies the pixels inside the border var y1 = (intx + 1 >= borderRadius) ? -1 : Math.floor(Math.sqrt(Math.pow(borderRadius, 2) - Math.pow(intx + 1, 2))) - 1; // Calculate y2 and y3 only if there is a border defined if (borderRadius != specRadius) { var y2 = (intx >= borderRadius) ? -1 : Math.ceil(Math.sqrt(Math.pow(borderRadius, 2) - Math.pow(intx, 2))); var y3 = (intx + 1 >= specRadius) ? -1 : Math.floor(Math.sqrt(Math.pow(specRadius, 2) - Math.pow((intx+1), 2))) - 1; } // Calculate y4 var y4 = (intx >= specRadius) ? -1 : Math.ceil(Math.sqrt(Math.pow(specRadius, 2) - Math.pow(intx, 2))); // Draw bar on inside of the border with foreground colour if (y1 > -1) this.drawPixel(intx, 0, this.boxColour, trans, (y1 + 1), newCorner, true, specRadius); // Draw border/foreground antialiased pixels and border only if there is a border defined if (borderRadius != specRadius) { // Cycle the y-axis if (this.spec.antiAlias) { for (inty = y1 + 1; inty < y2; ++inty) { // For each of the pixels that need anti aliasing between the foreground and border colour draw single pixel divs if (this.backgroundImage != "") { var borderFract = curvyObject.pixelFraction(intx, inty, borderRadius) * 100; this.drawPixel(intx, inty, bcolor, trans, 1, newCorner, borderFract >= 30, specRadius); } else if (this.boxColour !== 'transparent') { var pixelcolour = curvyObject.BlendColour(this.boxColour, bcolor, curvyObject.pixelFraction(intx, inty, borderRadius)); this.drawPixel(intx, inty, pixelcolour, trans, 1, newCorner, false, specRadius); } else this.drawPixel(intx, inty, bcolor, trans >> 1, 1, newCorner, false, specRadius); } // Draw bar for the border if (y3 >= y2) { if (y2 == -1) y2 = 0; this.drawPixel(intx, y2, bcolor, trans, (y3 - y2 + 1), newCorner, false, 0); } outsideColour = bcolor; // Set the colour for the outside AA curve inty = y3; // start_pos - 1 for y-axis AA pixels } else { // no antiAlias if (y3 > y1) { // NB condition was >=, changed to avoid zero-height divs this.drawPixel(intx, (y1 + 1), bcolor, trans, (y3 - y1), newCorner, false, 0); } } } else { outsideColour = this.boxColour; // Set the colour for the outside curve inty = y1; // start_pos - 1 for y-axis AA pixels } // Draw aa pixels? if (this.spec.antiAlias && this.boxColour !== 'transparent') { // Cycle the y-axis and draw the anti aliased pixels on the outside of the curve while (++inty < y4) { // For each of the pixels that need anti aliasing between the foreground/border colour & background draw single pixel divs this.drawPixel(intx, inty, outsideColour, (curvyObject.pixelFraction(intx, inty , specRadius) * trans), 1, newCorner, borderWidthTB <= 0, specRadius); } } } // END OF CORNER CREATION // ---------------------------------------------------- END /* Now we have a new corner we need to reposition all the pixels unless the current corner is the bottom right. */ // Loop through all children (pixel bars) for (var t = 0, k = newCorner.childNodes.length; t < k; ++t) { // Get current pixel bar var pixelBar = newCorner.childNodes[t]; // Get current top and left properties var pixelBarTop = parseInt($(pixelBar).css('top')); var pixelBarLeft = parseInt($(pixelBar).css('left')); var pixelBarHeight = parseInt($(pixelBar).css('height')); // Reposition pixels if (cc == "tl" || cc == "bl") { $(pixelBar).css('left', (specRadius - pixelBarLeft - 1) + "px"); // Left } if (cc == "tr" || cc == "tl"){ $(pixelBar).css('top', (specRadius - pixelBarHeight - pixelBarTop) + "px"); // Top } $(pixelBar).css('backgroundRepeat', this.backgroundRepeat); if (this.backgroundImage) switch(cc) { case "tr": $(pixelBar).css('backgroundPosition',(this.backgroundPosX - this.borderWidthL + specRadius - clientWidth - pixelBarLeft) + "px " + (this.backgroundPosY + pixelBarHeight + pixelBarTop + this.borderWidth - specRadius) + "px"); break; case "tl": $(pixelBar).css('backgroundPosition',(this.backgroundPosX - specRadius + pixelBarLeft + 1 + this.borderWidthL) + "px " + (this.backgroundPosY - specRadius + pixelBarHeight + pixelBarTop + this.borderWidth) + "px"); break; case "bl": $(pixelBar).css('backgroundPosition',(this.backgroundPosX - specRadius + pixelBarLeft + 1 + this.borderWidthL) + "px " + (this.backgroundPosY - clientHeight - this.borderWidth + (!jQuery.support.boxModel ? pixelBarTop : -pixelBarTop) + specRadius) + "px"); break; case "br": // Quirks mode on? if (!jQuery.support.boxModel) { $(pixelBar).css('backgroundPosition',(this.backgroundPosX - this.borderWidthL - clientWidth + specRadius - pixelBarLeft) + "px " + (this.backgroundPosY - clientHeight - this.borderWidth + pixelBarTop + specRadius) + "px"); } else { $(pixelBar).css('backgroundPosition',(this.backgroundPosX - this.borderWidthL - clientWidth + specRadius - pixelBarLeft) + "px " + (this.backgroundPosY - clientHeight - this.borderWidth + specRadius - pixelBarTop) + "px"); } //break; } } // Position the container switch (cc) { case "tl": $(newCorner).css('top', newCorner.style.left = "0"); this.topContainer.appendChild(newCorner); break; case "tr": $(newCorner).css('top', newCorner.style.right = "0"); this.topContainer.appendChild(newCorner); break; case "bl": $(newCorner).css('bottom', newCorner.style.left = "0"); this.bottomContainer.appendChild(newCorner); break; case "br": $(newCorner).css('bottom', newCorner.style.right = "0"); this.bottomContainer.appendChild(newCorner); //break; } } /* The last thing to do is draw the rest of the filler DIVs. */ // Find out which corner has the bigger radius and get the difference amount var radiusDiff = { t : this.spec.radiusdiff('t'), b : this.spec.radiusdiff('b') }; for (z in radiusDiff) { if (typeof z === 'function') continue; // for prototype, mootools frameworks if (!this.spec.get(z + 'R')) continue; // no need if no corners if (radiusDiff[z]) { // Get the type of corner that is the smaller one var smallerCornerType = (this.spec[z + "lR"] < this.spec[z + "rR"]) ? z + "l" : z + "r"; // First we need to create a DIV for the space under the smaller corner var newFiller = document.createElement("div"); $(newFiller).css({ 'height': radiusDiff[z] + "px", 'width': this.spec.get(smallerCornerType + 'Ru'), 'position': "absolute", 'fontSize': "1px", 'overflow': "hidden", 'backgroundColor': this.boxColour, 'backgroundImage': this.backgroundImage, 'backgroundRepeat': this.backgroundRepeat }); if (filter) $(newFiller).css('filter', 'filter'); // IE8 bug fix // Position filler switch (smallerCornerType) { case "tl": $(newFiller).css({ 'bottom': '', 'left': '0', 'borderLeft': this.borderStringL, 'backgroundPosition': this.backgroundPosX + "px " + (this.borderWidth + this.backgroundPosY - this.spec.tlR) + "px" }); this.topContainer.appendChild(newFiller); break; case "tr": $(newFiller).css({ 'bottom': '', 'right': '0', 'borderRight': this.borderStringR, 'backgroundPosition': (this.backgroundPosX - this.boxWidth + this.spec.trR) + "px " + (this.borderWidth + this.backgroundPosY - this.spec.trR) + "px" }); this.topContainer.appendChild(newFiller); break; case "bl": $(newFiller).css({ 'top': '', 'left': '0', 'borderLeft': this.borderStringL, 'backgroundPosition': this.backgroundPosX + "px " + (this.backgroundPosY - this.borderWidth - this.boxHeight + radiusDiff[z] + this.spec.blR) + "px" }); this.bottomContainer.appendChild(newFiller); break; case "br": $(newFiller).css({ 'top': '', 'right': '0', 'borderRight': this.borderStringR, 'backgroundPosition': (this.borderWidthL + this.backgroundPosX - this.boxWidth + this.spec.brR) + "px " + (this.backgroundPosY - this.borderWidth - this.boxHeight + radiusDiff[z] + this.spec.brR) + "px" }); this.bottomContainer.appendChild(newFiller); //break; } } // Create the bar to fill the gap between each corner horizontally var newFillerBar = document.createElement("div"); if (filter) $(newFillerBar).css('filter', 'filter'); // IE8 bug fix $(newFillerBar).css({ 'position': "relative", 'fontSize': "1px", 'overflow': "hidden", 'width': this.fillerWidth(z), 'backgroundColor': this.boxColour, 'backgroundImage': this.backgroundImage, 'backgroundRepeat': this.backgroundRepeat }); switch (z) { case "t": // Top Bar if (this.topContainer) { if (!jQuery.support.boxModel) { $(newFillerBar).css('height', 100 + topMaxRadius + "px"); } else { $(newFillerBar).css('height', 100 + topMaxRadius - this.borderWidth + "px"); } $(newFillerBar).css('marginLeft', this.spec.tlR ? (this.spec.tlR - this.borderWidthL) + "px" : "0"); $(newFillerBar).css('borderTop', this.borderString); if (this.backgroundImage) { var x_offset = this.spec.tlR ? (this.borderWidthL + this.backgroundPosX - this.spec.tlR) + "px " : this.backgroundPosX + "px "; $(newFillerBar).css('backgroundPosition', x_offset + this.backgroundPosY + "px"); // Reposition the box's background image $(this.shell).css('backgroundPosition', this.backgroundPosX + "px " + (this.backgroundPosY - topMaxRadius + this.borderWidthL) + "px"); } this.topContainer.appendChild(newFillerBar); } break; case "b": if (this.bottomContainer) { // Bottom Bar if (!jQuery.support.boxModel) { $(newFillerBar).css('height', botMaxRadius + "px"); } else { $(newFillerBar).css('height', botMaxRadius - this.borderWidthB + "px"); } $(newFillerBar).css('marginLeft', this.spec.blR ? (this.spec.blR - this.borderWidthL) + "px" : "0"); $(newFillerBar).css('borderBottom', this.borderStringB); if (this.backgroundImage) { var x_offset = this.spec.blR ? (this.backgroundPosX + this.borderWidthL - this.spec.blR) + "px " : this.backgroundPosX + "px "; $(newFillerBar).css('backgroundPosition', x_offset + (this.backgroundPosY - clientHeight - this.borderWidth + botMaxRadius) + "px"); } this.bottomContainer.appendChild(newFillerBar); } //break; } } // style content container z = clientWidth; if (jQuery.support.boxModel) z -= this.leftPadding + this.rightPadding; $(this.contentContainer).css({ 'position': 'absolute', 'left': this.borderWidthL + "px", 'paddingTop': this.topPadding + "px", 'top': this.borderWidth + "px", 'paddingLeft': this.leftPadding + "px", 'paddingRight': this.rightPadding + "px", 'width': z + "px", 'textAlign': $$.css('textAlign') }).addClass('autoPadDiv'); $$.css('textAlign', 'left').addClass('hasCorners'); this.box.appendChild(this.contentContainer); if (boxDisp) $(boxDisp).css('display', boxDispSave); }; if (this.backgroundImage) { backgroundPosX = this.backgroundCheck(backgroundPosX); backgroundPosY = this.backgroundCheck(backgroundPosY); if (this.backgroundObject) { this.backgroundObject.holdingElement = this; this.dispatch = this.applyCorners; this.applyCorners = function() { if (this.backgroundObject.complete) this.dispatch(); else this.backgroundObject.onload = new Function('$(this.holdingElement).dispatch();'); }; } } }; curvyObject.prototype.backgroundCheck = function(style) { if (style === 'top' || style === 'left' || parseInt(style) === 0) return 0; if (!(/^[-\d.]+px$/.test(style)) && !this.backgroundObject) { this.backgroundObject = new Image; var imgName = function(str) { var matches = /url\("?([^'"]+)"?\)/.exec(str); return (matches ? matches[1] : str); }; this.backgroundObject.src = imgName(this.backgroundImage); } return style; }; /*curvyObject.dispatch = function(obj) { if ('dispatch' in obj) obj.dispatch(); else throw Error('No dispatch function'); };*/ /* This function draws the pixels */ curvyObject.prototype.drawPixel = function( intx, inty, colour, transAmount, height, newCorner, image, cornerRadius ) { //var $$ = $(box); var pixel = document.createElement("div"); $(pixel).css({ "height" : height + "px", "width" : "1px", "position" : "absolute", "font-size" : "1px", "overflow" : "hidden", "top" : inty + "px", "left" : intx + "px", "background-color" :colour }); var topMaxRadius = this.spec.get('tR'); // Dont apply background image to border pixels if(image && this.backgroundImage != "") { $(pixel).css({ "background-position":"-" + (this.boxWidth - (cornerRadius - intx) + this.borderWidth) + "px -" + ((this.boxHeight + topMaxRadius + inty) - this.borderWidth) + "px", "background-image":this.backgroundImage }); } if (transAmount != 100) $(pixel).css({opacity: (transAmount/100) }); newCorner.appendChild(pixel); }; curvyObject.prototype.fillerWidth = function(tb) { var b_width, f_width; b_width = !jQuery.support.boxModel ? 0 : this.spec.radiusCount(tb) * this.borderWidthL; if ((f_width = this.boxWidth - this.spec.radiusSum(tb) + b_width) < 0) throw Error("Radius exceeds box width"); return f_width + 'px'; }; // Gets the computed colour. curvyObject.getComputedColour = function(colour) { var d = document.createElement('DIV'); d.style.backgroundColor = colour; document.body.appendChild(d); if (window.getComputedStyle) { // Mozilla, Opera, Chrome, Safari var rtn = document.defaultView.getComputedStyle(d, null).getPropertyValue('background-color'); d.parentNode.removeChild(d); if (rtn.substr(0, 3) === "rgb") rtn = curvyObject.rgb2Hex(rtn); return rtn; } else { // IE var rng = document.body.createTextRange(); rng.moveToElementText(d); rng.execCommand('ForeColor', false, colour); var iClr = rng.queryCommandValue('ForeColor'); var rgb = "rgb("+(iClr & 0xFF)+", "+((iClr & 0xFF00)>>8)+", "+((iClr & 0xFF0000)>>16)+")"; d.parentNode.removeChild(d); rng = null; return curvyObject.rgb2Hex(rgb); } }; curvyObject.BlendColour = function(Col1, Col2, Col1Fraction) { if (Col1 === 'transparent' || Col2 === 'transparent') throw Error('Cannot blend with transparent'); if (Col1.charAt(0) !== '#') { Col1 = curvyObject.format_colour(Col1); } if (Col2.charAt(0) !== '#') { Col2 = curvyObject.format_colour(Col2); } var red1 = parseInt(Col1.substr(1, 2), 16); var green1 = parseInt(Col1.substr(3, 2), 16); var blue1 = parseInt(Col1.substr(5, 2), 16); var red2 = parseInt(Col2.substr(1, 2), 16); var green2 = parseInt(Col2.substr(3, 2), 16); var blue2 = parseInt(Col2.substr(5, 2), 16); if (Col1Fraction > 1 || Col1Fraction < 0) Col1Fraction = 1; var endRed = Math.round((red1 * Col1Fraction) + (red2 * (1 - Col1Fraction))); if (endRed > 255) endRed = 255; if (endRed < 0) endRed = 0; var endGreen = Math.round((green1 * Col1Fraction) + (green2 * (1 - Col1Fraction))); if (endGreen > 255) endGreen = 255; if (endGreen < 0) endGreen = 0; var endBlue = Math.round((blue1 * Col1Fraction) + (blue2 * (1 - Col1Fraction))); if (endBlue > 255) endBlue = 255; if (endBlue < 0) endBlue = 0; return "#" + curvyObject.IntToHex(endRed) + curvyObject.IntToHex(endGreen)+ curvyObject.IntToHex(endBlue); }; curvyObject.IntToHex = function(strNum) { var hexdig = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' ]; return hexdig[strNum >>> 4] + '' + hexdig[strNum & 15]; }; /* For a pixel cut by the line determines the fraction of the pixel on the 'inside' of the line. Returns a number between 0 and 1 */ curvyObject.pixelFraction = function(x, y, r) { var fraction; var rsquared = r * r; /* determine the co-ordinates of the two points on the perimeter of the pixel that the circle crosses */ var xvalues = new Array(2); var yvalues = new Array(2); var point = 0; var whatsides = ""; // x + 0 = Left var intersect = Math.sqrt(rsquared - Math.pow(x, 2)); if (intersect >= y && intersect < (y + 1)) { whatsides = "Left"; xvalues[point] = 0; yvalues[point] = intersect - y; ++point; } // y + 1 = Top intersect = Math.sqrt(rsquared - Math.pow(y + 1, 2)); if (intersect >= x && intersect < (x + 1)) { whatsides += "Top"; xvalues[point] = intersect - x; yvalues[point] = 1; ++point; } // x + 1 = Right intersect = Math.sqrt(rsquared - Math.pow(x + 1, 2)); if (intersect >= y && intersect < (y + 1)) { whatsides += "Right"; xvalues[point] = 1; yvalues[point] = intersect - y; ++point; } // y + 0 = Bottom intersect = Math.sqrt(rsquared - Math.pow(y, 2)); if (intersect >= x && intersect < (x + 1)) { whatsides += "Bottom"; xvalues[point] = intersect - x; yvalues[point] = 0; } /* depending on which sides of the perimeter of the pixel the circle crosses calculate the fraction of the pixel inside the circle */ switch (whatsides) { case "LeftRight": fraction = Math.min(yvalues[0], yvalues[1]) + ((Math.max(yvalues[0], yvalues[1]) - Math.min(yvalues[0], yvalues[1])) / 2); break; case "TopRight": fraction = 1 - (((1 - xvalues[0]) * (1 - yvalues[1])) / 2); break; case "TopBottom": fraction = Math.min(xvalues[0], xvalues[1]) + ((Math.max(xvalues[0], xvalues[1]) - Math.min(xvalues[0], xvalues[1])) / 2); break; case "LeftBottom": fraction = yvalues[0] * xvalues[1] / 2; break; default: fraction = 1; } return fraction; }; // This function converts CSS rgb(x, x, x) to hexadecimal curvyObject.rgb2Hex = function(rgbColour) { try{ // Get array of RGB values var rgbArray = curvyObject.rgb2Array(rgbColour); // Get RGB values var red = parseInt(rgbArray[0]); var green = parseInt(rgbArray[1]); var blue = parseInt(rgbArray[2]); // Build hex colour code var hexColour = "#" + curvyObject.IntToHex(red) + curvyObject.IntToHex(green) + curvyObject.IntToHex(blue); } catch(e){ alert("There was an error converting the RGB value to Hexadecimal in function rgb2Hex"); } return hexColour; }; // Returns an array of rbg values curvyObject.rgb2Array = function(rgbColour) { // Remove rgb() var rgbValues = rgbColour.substring(4, rgbColour.indexOf(")")); // Split RGB into array return rgbValues.split(", "); }; // Formats colours curvyObject.format_colour = function(colour) { // Make sure colour is set and not transparent if (colour != "" && colour != "transparent") { // RGB Value? if (colour.substr(0, 3) === "rgb") { // Get HEX aquiv. colour = curvyObject.rgb2Hex(colour); } else if (colour.charAt(0) !== '#') { // Convert colour name to hex value colour = getComputedColour(colour); } else if (colour.length === 4) { // 3 chr colour code add remainder colour = "#" + colour.charAt(1) + colour.charAt(1) + colour.charAt(2) + colour.charAt(2) + colour.charAt(3) + colour.charAt(3); } } return colour; }; return this.each(function() { if (!$(this).is('.hasCorners')) { if (nativeCornersSupported) { if (settings.get('tlR')) { $(this).css({ 'border-top-left-radius' : settings.get('tlR') + 'px', '-moz-border-radius-topleft' : settings.get('tlR') + 'px', '-webkit-border-top-left-radius' : settings.get('tlR') + 'px' }); } if (settings.get('trR')) { $(this).css({ 'border-top-right-radius' : settings.get('trR') + 'px', '-moz-border-radius-topright' : settings.get('trR') + 'px', '-webkit-border-top-right-radius' : settings.get('trR') + 'px' }); } if (settings.get('blR')) { $(this).css({ 'border-bottom-left-radius' : settings.get('blR') + 'px', '-moz-border-radius-bottomleft' : settings.get('blR') + 'px', '-webkit-border-bottom-left-radius' : settings.get('blR') + 'px' }); } if (settings.get('brR')) { $(this).css({ 'border-bottom-right-radius' : settings.get('brR') + 'px', '-moz-border-radius-bottomright' : settings.get('brR') + 'px', '-webkit-border-bottom-right-radius' : settings.get('brR') + 'px' }); } } else { if (!$(this).is('.drawn')) { $(this).addClass('drawn'); thestyles = $(this).attr('style'); if (thestyles == 'undefined') { thestyles = ''; } redrawList.push({ node : this, spec : settings, style : thestyles, copy : $(this).clone(true) }); } var obj = new curvyObject(settings, this); obj.applyCorners(); } } }); }; $.fn.removeCorners = function() { return this.each(function(i, e) { thisdiv = e; $.each( redrawList, function( intIndex, list ){ if (list.node==thisdiv && $('.autoPadDiv', thisdiv).size()>0) { //$('div:not(.autoPadDiv)', thisdiv).remove(); //$('.autoPadDiv', thisdiv).replaceWith( $('.autoPadDiv', thisdiv).contents() ); $(thisdiv).html($(thisdiv).children('.autoPadDiv:first').contents()); style = list.style == 'undefined' ? list.style : ''; $(thisdiv).removeClass('hasCorners').attr('style', style ); return false; } } ); }); }; $.fn.redrawCorners = function() { return this.each(function(i, e) { thisdiv = e; $.each( redrawList, function( intIndex, list ){ if (list.node==thisdiv) { //$('div:not(.autoPadDiv)', thisdiv).remove(); //$('.autoPadDiv', thisdiv).replaceWith( $('.autoPadDiv', thisdiv).contents() ); //style = list.style == 'undefined' ? list.style : ''; //$(thisdiv).removeClass('hasCorners').attr('style', style ); $(thisdiv).corner(list.spec); return false; } } ); }); }; $.fn.dispatch = function() { return this.each(function(i, e) { obj = e; if ('dispatch' in obj) obj.dispatch(); else throw Error('No dispatch function') }); }; $(function(){ // Detect styles and apply corners in browsers with no native border-radius support if ($.browser.msie) { /* Force caching of bg images in IE6 */ try { document.execCommand("BackgroundImageCache", false, true); } catch(e) {}; function units(num) { if (!parseInt(num)) return 'px'; // '0' becomes '0px' for simplicity's sake var matches = /^[\d.]+(\w+)$/.exec(num); return matches[1]; }; /* Detect and Apply Corners */ var t, i, j; function procIEStyles(rule) { var style = rule.style; if (jQuery.browser.version > 6.0) { var allR = style['-moz-border-radius'] || 0; var tR = style['-moz-border-radius-topright'] || 0; var tL = style['-moz-border-radius-topleft'] || 0; var bR = style['-moz-border-radius-bottomright'] || 0; var bL = style['-moz-border-radius-bottomleft'] || 0; } else { var allR = style['moz-border-radius'] || 0; var tR = style['moz-border-radius-topright'] || 0; var tL = style['moz-border-radius-topleft'] || 0; var bR = style['moz-border-radius-bottomright'] || 0; var bL = style['moz-border-radius-bottomleft'] || 0; } if (allR) { var t = allR.split('/'); // ignore elliptical spec. t = t[0].split(/\s+/); if (t[t.length - 1] === '') t.pop(); switch (t.length) { case 3: tL = t[0]; tR = bL = t[1]; bR = t[2]; allR = false; break; case 2: tL = bR = t[0]; tR = bL = t[1]; allR = false; case 1: break; case 4: tL = t[0]; tR = t[1]; bR = t[2]; bL = t[3]; allR = false; break; default: alert('Illegal corners specification: ' + allR); } } if (allR || tL || tR || bR || bL) { var settings = new curvyCnrSpec(rule.selectorText); if (allR) settings.setcorner(null, null, parseInt(allR), units(allR)); else { if (tR) settings.setcorner('t', 'r', parseInt(tR), units(tR)); if (tL) settings.setcorner('t', 'l', parseInt(tL), units(tL)); if (bL) settings.setcorner('b', 'l', parseInt(bL), units(bL)); if (bR) settings.setcorner('b', 'r', parseInt(bR), units(bR)); } $(rule.selectorText).corner(settings); } } for (t = 0; t < document.styleSheets.length; ++t) { try { if (document.styleSheets[t].imports) { for (i = 0; i < document.styleSheets[t].imports.length; ++i) { for (j = 0; j < document.styleSheets[t].imports[i].rules.length; ++j) { procIEStyles(document.styleSheets[t].imports[i].rules[j]); } } } for (i = 0; i < document.styleSheets[t].rules.length; ++i) procIEStyles(document.styleSheets[t].rules[i]); } catch (e) {} } } else if ($.browser.opera) { // Apply if border radius is not supported try { checkStandard = (document.body.style.BorderRadius !== undefined); } catch(err) {} if (!checkStandard) { function opera_contains_border_radius(sheetnumber) { return /border-((top|bottom)-(left|right)-)?radius/.test(document.styleSheets.item(sheetnumber).ownerNode.text); }; rules = []; for (t = 0; t < document.styleSheets.length; ++t) { if (opera_contains_border_radius(t)) { var txt = document.styleSheets.item(sheetnumber).ownerNode.text; txt = txt.replace(/\/\*(\n|\r|.)*?\*\//g, ''); // strip comments var pat = new RegExp("^\\s*([\\w.#][-\\w.#, ]+)[\\n\\s]*\\{([^}]+border-((top|bottom)-(left|right)-)?radius[^}]*)\\}", "mg"); var matches; while ((matches = pat.exec(txt)) !== null) { var pat2 = new RegExp("(..)border-((top|bottom)-(left|right)-)?radius:\\s*([\\d.]+)(in|em|px|ex|pt)", "g"); var submatches, cornerspec = new curvyCnrSpec(matches[1]); while ((submatches = pat2.exec(matches[2])) !== null) { if (submatches[1] !== "z-") cornerspec.setcorner(submatches[3], submatches[4], submatches[5], submatches[6]); rules.push(cornerspec); } } } } for (i in rules) if (!isNaN(i)) $(rules[i].selectorText).corner(rules[i]); } } }); })(jQuery); // ./jquery.jqDnR.js /* * jqDnR - Minimalistic Drag'n'Resize for jQuery. * * Copyright (c) 2007 Brice Burgess , http://www.iceburg.net * Licensed under the MIT License: * http://www.opensource.org/licenses/mit-license.php * * $Version: 2007.08.19 +r2 */ (function($){ $.fn.jqDrag=function(h){return i(this,h,'d');}; $.fn.jqResize=function(h){return i(this,h,'r');}; $.jqDnR={dnr:{},e:0, drag:function(v){ if(M.k == 'd')E.css({left:M.X+v.pageX-M.pX,top:M.Y+v.pageY-M.pY}); else E.css({width:Math.max(v.pageX-M.pX+M.W,0),height:Math.max(v.pageY-M.pY+M.H,0)}); return false;}, stop:function(){E.css('opacity',M.o);$().unbind('mousemove',J.drag).unbind('mouseup',J.stop);} }; var J=$.jqDnR,M=J.dnr,E=J.e, i=function(e,h,k){return e.each(function(){h=(h)?$(h,e):e; h.bind('mousedown',{e:e,k:k},function(v){var d=v.data,p={};E=d.e; // attempt utilization of dimensions plugin to fix IE issues if(E.css('position') != 'relative'){try{E.position(p);}catch(e){}} M={X:p.left||f('left')||0,Y:p.top||f('top')||0,W:f('width')||E[0].scrollWidth||0,H:f('height')||E[0].scrollHeight||0,pX:v.pageX,pY:v.pageY,k:d.k,o:E.css('opacity')}; E.css({opacity:0.8});$().mousemove($.jqDnR.drag).mouseup($.jqDnR.stop); return false; }); });}, f=function(k){return parseInt(E.css(k))||false;}; })(jQuery); // ./highslide-full.packed.js /** * Name: Highslide JS * Version: 4.1.9 (2010-07-05) * Author: Torstein Hønsi * Support: www.highslide.com/support * License: www.highslide.com/#license */ eval(function(p,a,c,k,e,d){e=function(c){return(c35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('q(!m){A m={14:{9s:\'ar\',al:\'eX...\',am:\'8R 2g eY\',bD:\'8R 2g eK 2g ek\',9v:\'en 2g eJ D (f)\',cu:\'ex by ag ah\',cs:\'ez 2g eB ag ah fN\',8t:\'aa\',8n:\'ao\',8f:\'an\',8l:\'af\',8i:\'af (fQ)\',b6:\'fH\',aT:\'ae\',b1:\'ae 1p (ad)\',aW:\'ab\',aU:\'ab 1p (ad)\',8s:\'aa (8Q 18)\',8w:\'ao (8Q 3o)\',8h:\'an\',bb:\'1:1\',3N:\'ff %1 fh %2\',9F:\'8R 2g 2b 2R, fj a8 fy 2g 3A. g3 8Q cR O 1C a8 2W.\'},5p:\'K/dW/\',7M:\'dZ.4X\',5w:\'e0.4X\',7s:5S,9Y:5S,4y:15,9h:15,4T:15,77:15,4t:e1,ak:0.75,91:M,9o:5,3F:2,dV:3,5A:1j,bR:\'4j 3o\',bP:1,c2:M,cp:\'dQ://K.dS/\',cx:\'dv\',az:M,9U:[\'a\',\'5j\'],3i:[],cz:5S,48:0,95:50,7N:1j,7G:M,4z:M,3J:\'5D\',9E:M,4l:\'1Q\',9n:\'1Q\',b7:I,b8:I,9N:M,4B:aZ,5G:aZ,5T:M,1Y:\'dp-dt\',9R:{35:\'

    <6c>\'+\'<1K 1W="K-2W">\'+\'\'+\'<1D>{m.14.8t}\'+\'\'+\'<1K 1W="K-3I">\'+\'\'+\'<1D>{m.14.aT}\'+\'\'+\'<1K 1W="K-3r">\'+\'\'+\'<1D>{m.14.aW}\'+\'\'+\'<1K 1W="K-1C">\'+\'\'+\'<1D>{m.14.8n}\'+\'\'+\'<1K 1W="K-3A">\'+\'\'+\'<1D>{m.14.8f}\'+\'\'+\'<1K 1W="K-19-2H">\'+\'\'+\'<1D>{m.14.bb}\'+\'\'+\'<1K 1W="K-2b">\'+\'\'+\'<1D>{m.14.8l}\'+\'\'+\'

    \',aK:\'

    <6c>\'+\'<1K 1W="K-2W">\'+\'\'+\'<1D>{m.14.8t}\'+\'\'+\'<1K 1W="K-1C">\'+\'\'+\'<1D>{m.14.8n}\'+\'\'+\'<1K 1W="K-3A">\'+\'\'+\'<1D>{m.14.8f}\'+\'\'+\'<1K 1W="K-2b">\'+\'\'+\'<1D>{m.14.8l}\'+\'\'+\'

    \'+\'

    \'+\'

    \'+\'<1D 1W="K-4g" 2j="{m.14.b6}"><1D>\'+\'

    \'},6s:[],a0:M,16:[],a1:[\'5T\',\'3x\',\'4l\',\'9n\',\'b7\',\'b8\',\'1Y\',\'3F\',\'cW\',\'cP\',\'dU\',\'aR\',\'e3\',\'eb\',\'ea\',\'aS\',\'cr\',\'9N\',\'4d\',\'64\',\'3i\',\'48\',\'L\',\'N\',\'7X\',\'7N\',\'7G\',\'4z\',\'e9\',\'e5\',\'e4\',\'2F\',\'9E\',\'4f\',\'4m\',\'3J\',\'8e\',\'8Y\',\'4B\',\'5G\',\'6J\',\'8W\',\'aM\',\'2N\',\'2O\',\'cw\',\'ct\',\'1e\'],1T:[],61:0,88:{x:[\'c5\',\'18\',\'4J\',\'3o\',\'c6\'],y:[\'5X\',\'Y\',\'9i\',\'4j\',\'7w\']},7u:{},aS:{},aR:{},8e:{aF:{},2c:{},ax:{}},44:[],5O:[],4A:{},4s:[],6S:[],5b:[],6F:{},a5:{},7l:[],3f:/e8\\/4\\.0/.1a(56.6y)?8:8C((56.6y.6p().31(/.+(?:aB|dO|dN|1E)[\\/: ]([\\d.]+)/)||[0,\'0\'])[1]),1E:(W.6w&&!1S.3u),4H:/dw/.1a(56.6y),5I:/dy.+aB:1\\.[0-8].+dD/.1a(56.6y),$:C(1x){q(1x)E W.92(1x)},2k:C(26,3g){26[26.V]=3g},1b:C(aA,46,3W,5v,au){A el=W.1b(aA);q(46)m.3s(el,46);q(au)m.R(el,{8O:0,8g:\'1F\',97:0});q(3W)m.R(el,3W);q(5v)5v.21(el);E el},3s:C(el,46){O(A x 3e 46)el[x]=46[x];E el},R:C(el,3W){O(A x 3e 3W){q(m.1E&&x==\'1z\'){q(3W[x]>0.99)el.G.dE(\'60\');J el.G.60=\'aN(1z=\'+(3W[x]*2x)+\')\'}J el.G[x]=3W[x]}},2u:C(el,1d,3B){A 4F,54,4v;q(1G 3B!=\'7F\'||3B===I){A 2G=ck;3B={45:2G[2],2O:2G[3],6O:2G[4]}}q(1G 3B.45!=\'3N\')3B.45=5S;3B.2O=1i[3B.2O]||1i.aq;3B.7o=m.3s({},1d);O(A 2X 3e 1d){A e=1J m.fx(el,3B,2X);4F=8C(m.8p(el,2X))||0;54=8C(1d[2X]);4v=2X!=\'1z\'?\'F\':\'\';e.3y(4F,54,4v)}},8p:C(el,1d){q(el.G[1d]){E el.G[1d]}J q(W.84){E W.84.cf(el,I).bB(1d)}J{q(1d==\'1z\')1d=\'60\';A 3g=el.5H[1d.2d(/\\-(\\w)/g,C(a,b){E b.aE()})];q(1d==\'60\')3g=3g.2d(/aN\\(1z=([0-9]+)\\)/,C(a,b){E b/2x});E 3g===\'\'?1:3g}},7k:C(){A d=W,w=1S,6k=d.7t&&d.7t!=\'8I\'?d.59:d.1f;A L=m.1E?6k.8F:(d.59.8F||7q.dM),N=m.1E?6k.ca:7q.dL;m.4e={L:L,N:N,6v:m.1E?6k.6v:dK,69:m.1E?6k.69:dB};E m.4e},71:C(el){q(/5j/i.1a(el.3O)){A 6V=W.2A(\'1R\');O(A i=0;i<6V.V;i++){A u=6V[i].dA;q(u&&u.2d(/^.*?#/,\'\')==el.22.2X){el=6V[i];5a}}}A p={x:el.4O,y:el.8K};5o(el.aO){el=el.aO;p.x+=el.4O;p.y+=el.8K;q(el!=W.1f&&el!=W.59){p.x-=el.6v;p.y-=el.69}}E p},2H:C(a,2c,3y,T){q(!a)a=m.1b(\'a\',I,{1o:\'1F\'},m.29);q(1G a.6d==\'C\')E 2c;q(T==\'3w\'){O(A i=0;ia2){a2=1B;7c=i}}}q(7c==-1)m.2Y=-1;J 16[7c].3P()},43:C(a,6j){a.6d=a.2n;A p=a.6d?a.6d():I;a.6d=I;E(p&&1G p[6j]!=\'1V\')?p[6j]:(1G m[6j]!=\'1V\'?m[6j]:I)},7L:C(a){A 1e=m.43(a,\'1e\');q(1e)E 1e;E a.24},4o:C(1x){A 1O=m.$(1x),4S=m.a5[1x],a={};q(!1O&&!4S)E I;q(!4S){4S=1O.5B(M);4S.1x=\'\';m.a5[1x]=4S;E 1O}J{E 4S.5B(M)}},3v:C(d){q(d)m.8X.21(d);m.8X.2i=\'\'},1w:C(B){q(!m.2S){m.2S=m.1b(\'P\',{1c:\'K-ee K-2t-D\',67:\'\',2n:C(){q(m.1A(m,\'ed\'))m.2b()}},{1n:\'1X\',1z:0},m.29,M)}m.2S.G.1o=\'\';m.2S.67+=\'|\'+B.Q;q(m.5I&&m.ay)m.R(m.2S,{9k:\'7R(\'+m.5p+\'ec.bf)\',1z:1});J m.2u(m.2S,{1z:B.48},m.95)},9H:C(Q){q(!m.2S)E;q(1G Q!=\'1V\')m.2S.67=m.2S.67.2d(\'|\'+Q,\'\');q((1G Q!=\'1V\'&&m.2S.67!=\'\')||(m.2s&&m.43(m.2s,\'48\')))E;q(m.5I&&m.ay)m.2S.G.1o=\'1F\';J m.2u(m.2S,{1z:0},m.95,I,C(){m.2S.G.1o=\'1F\'})},8A:C(78,B){A 1h=B||m.2B();B=1h;q(m.2s)E 1j;J m.1h=1h;m.4R(W,1S.3u?\'7f\':\'7b\',m.5V);1t{m.2s=78;78.2n()}1v(e){m.1h=m.2s=I}1t{q(!78||B.3i[1]!=\'42\')B.2b()}1v(e){}E 1j},6B:C(el,2q){A B=m.2B(el);q(B)E m.8A(B.8J(2q),B);J E 1j},2W:C(el){E m.6B(el,-1)},1C:C(el){E m.6B(el,1)},5V:C(e){q(!e)e=1S.2v;q(!e.2C)e.2C=e.9X;q(1G e.2C.a3!=\'1V\')E M;q(!m.1A(m,\'dR\',e))E M;A B=m.2B();A 2q=I;ba(e.do){28 70:q(B)B.74();E M;28 32:2q=2;5a;28 34:28 39:28 40:2q=1;5a;28 8:28 33:28 37:28 38:2q=-1;5a;28 27:28 13:2q=0}q(2q!==I){m.4R(W,1S.3u?\'7f\':\'7b\',m.5V);q(!m.az)E M;q(e.5g)e.5g();J e.cv=1j;q(B){q(2q==0){B.2b()}J q(2q==2){q(B.1p)B.1p.bi()}J{q(B.1p)B.1p.3r();m.6B(B.Q,2q)}E 1j}}E M},cO:C(11){m.2k(m.1T,m.3s(11,{23:\'23\'+m.61++}))},cQ:C(1r){A 2Z=1r.2N;q(1G 2Z==\'7F\'){O(A i=0;i<2Z.V;i++){A o={};O(A x 3e 1r)o[x]=1r[x];o.2N=2Z[i];m.2k(m.5O,o)}}J{m.2k(m.5O,1r)}},82:C(6A,6P){A el,2o=/^K-U-([0-9]+)$/;el=6A;5o(el.22){q(el.6I!==1V)E el.6I;q(el.1x&&2o.1a(el.1x))E el.1x.2d(2o,"$1");el=el.22}q(!6P){el=6A;5o(el.22){q(el.3O&&m.6U(el)){O(A Q=0;Q1)E M;q(!e.2C)e.2C=e.9X;A el=e.2C;5o(el.22&&!(/K-(2R|3A|3w|4g)/.1a(el.1c))){el=el.22}A B=m.2B(el);q(B&&(B.5J||!B.5i))E M;q(B&&e.T==\'7W\'){q(e.2C.a3)E M;A 31=el.1c.31(/K-(2R|3A|4g)/);q(31){m.2w={B:B,T:31[1],18:B.x.H,L:B.x.D,Y:B.y.H,N:B.y.D,b4:e.7r,b3:e.7P};m.2m(W,\'7x\',m.7n);q(e.5g)e.5g();q(/K-(2R|3w)-9K/.1a(B.S.1c)){B.3P();m.9f=M}E 1j}J q(/K-3w/.1a(el.1c)&&m.2Y!=B.Q){B.3P();B.5l(\'1q\')}}J q(e.T==\'bh\'){m.4R(W,\'7x\',m.7n);q(m.2w){q(m.58&&m.2w.T==\'2R\')m.2w.B.S.G.4w=m.58;A 3G=m.2w.3G;q(!3G&&!m.9f&&!/(3A|4g)/.1a(m.2w.T)){q(m.1A(B,\'dg\'))B.2b()}J q(3G||(!3G&&m.bd)){m.2w.B.5l(\'1q\')}q(m.2w.B.3H)m.2w.B.3H.G.1o=\'1F\';q(3G)m.1A(m.2w.B,\'df\',m.2w);m.9f=1j;m.2w=I}J q(/K-2R-9K/.1a(el.1c)){el.G.4w=m.58}}E 1j},7n:C(e){q(!m.2w)E M;q(!e)e=1S.2v;A a=m.2w,B=a.B;q(B.1k){q(!B.3H)B.3H=m.1b(\'P\',I,{1l:\'2l\',L:B.x.D+\'F\',N:B.y.D+\'F\',18:B.x.cb+\'F\',Y:B.y.cb+\'F\',1B:4,9k:(m.1E?\'dc\':\'1F\'),1z:0.dh},B.U,M);q(B.3H.G.1o==\'1F\')B.3H.G.1o=\'\'}a.dX=e.7r-a.b4;a.dY=e.7P-a.b3;A 9x=1i.dl(1i.aX(a.dX,2)+1i.aX(a.dY,2));q(!a.3G)a.3G=(a.T!=\'2R\'&&9x>0)||(9x>(m.db||5));q(a.3G&&e.7r>5&&e.7P>5){q(!m.1A(B,\'d1\',a))E 1j;q(a.T==\'4g\')B.4g(a);J{B.9B(a.18+a.dX,a.Y+a.dY);q(a.T==\'2R\')B.S.G.4w=\'3A\'}}E 1j},aL:C(e){1t{q(!e)e=1S.2v;A 6f=/d0/i.1a(e.T);q(!e.2C)e.2C=e.9X;q(m.1E)e.98=6f?e.cZ:e.d3;A B=m.2B(e.2C);q(!B.5i)E;q(!B||!e.98||m.2B(e.98,M)==B||m.2w)E;m.1A(B,6f?\'d8\':\'d6\',e);O(A i=0;i=k.1r.45+k.8U){k.4i=k.54;k.H=k.9r=1;k.9m();k.1r.7o[k.1d]=M;A 94=M;O(A i 3e k.1r.7o)q(k.1r.7o[i]!==M)94=1j;q(94){q(k.1r.6O)k.1r.6O.aj(k.30)}E 1j}J{A n=t-k.8U;k.9r=n/k.1r.45;k.H=k.1r.2O(n,0,1,k.1r.45);k.4i=k.4F+((k.54-k.4F)*k.H);k.9m()}E M}};m.3s(m.fx,{3U:{1z:C(fx){m.R(fx.30,{1z:fx.4i})},a7:C(fx){1t{q(fx.30.G&&fx.30.G[fx.1d]!=I)fx.30.G[fx.1d]=fx.4i+fx.4v;J fx.30[fx.1d]=fx.4i}1v(e){}}}});m.5L=C(1Y,3z){k.3z=3z;k.1Y=1Y;A v=m.3f,3X;k.9e=m.1E&&v>=5.5&&v<7;q(!1Y){q(3z)3z();E}m.7A();k.2h=m.1b(\'2h\',{fo:0},{1n:\'1q\',1l:\'2l\',fm:\'fE\',L:0},m.29,M);A 4q=m.1b(\'4q\',I,I,k.2h,1);k.2E=[];O(A i=0;i<=8;i++){q(i%3==0)3X=m.1b(\'3X\',I,{N:\'1Q\'},4q,M);k.2E[i]=m.1b(\'2E\',I,I,3X,M);A G=i!=4?{fF:0,fW:0}:{1l:\'4n\'};m.R(k.2E[i],G)}k.2E[4].1c=1Y+\' K-1g\';k.ap()};m.5L.5e={ap:C(){A 1e=m.5p+(m.fU||"fX/")+k.1Y+".bf";A b2=m.4H&&m.3f<7O?m.29:I;k.3L=m.1b(\'1R\',I,{1l:\'2l\',Y:\'-4k\'},b2,M);A 3C=k;k.3L.4L=C(){3C.aY()};k.3L.1e=1e},aY:C(){A o=k.1y=k.3L.L/4,H=[[0,0],[0,-4],[-2,0],[0,-8],0,[-2,-8],[0,-2],[0,-6],[-2,-2]],1w={N:(2*o)+\'F\',L:(2*o)+\'F\'};O(A i=0;i<=8;i++){q(H[i]){q(k.9e){A w=(i==1||i==7)?\'2x%\':k.3L.L+\'F\';A P=m.1b(\'P\',I,{L:\'2x%\',N:\'2x%\',1l:\'4n\',2e:\'1q\'},k.2E[i],M);m.1b(\'P\',I,{60:"fZ:fS.bT.fR(fK=fJ, 1e=\'"+k.3L.1e+"\')",1l:\'2l\',L:w,N:k.3L.N+\'F\',18:(H[i][0]*o)+\'F\',Y:(H[i][1]*o)+\'F\'},P,M)}J{m.R(k.2E[i],{9k:\'7R(\'+k.3L.1e+\') \'+(H[i][0]*o)+\'F \'+(H[i][1]*o)+\'F\'})}q(1S.3u&&(i==3||i==5))m.1b(\'P\',I,1w,k.2E[i],M);m.R(k.2E[i],1w)}}k.3L=I;q(m.4A[k.1Y])m.4A[k.1Y].6q();m.4A[k.1Y]=k;q(k.3z)k.3z()},4G:C(H,1y,at,4b,2O){A B=k.B,5K=B.U.G,1y=1y||0,H=H||{x:B.x.H+1y,y:B.y.H+1y,w:B.x.Z(\'2f\')-2*1y,h:B.y.Z(\'2f\')-2*1y};q(at)k.2h.G.1n=(H.h>=4*k.1y)?\'1X\':\'1q\';m.R(k.2h,{18:(H.x-k.1y)+\'F\',Y:(H.y-k.1y)+\'F\',L:(H.w+2*k.1y)+\'F\'});H.w-=2*k.1y;H.h-=2*k.1y;m.R(k.2E[4],{L:H.w>=0?H.w+\'F\':0,N:H.h>=0?H.h+\'F\':0});q(k.9e)k.2E[3].G.N=k.2E[5].G.N=k.2E[4].G.N},6q:C(be){q(be)k.2h.G.1n=\'1q\';J m.3v(k.2h)}};m.6T=C(B,1w){k.B=B;k.1w=1w;k.3n=1w==\'x\'?\'bH\':\'bI\';k.3l=k.3n.6p();k.5Q=1w==\'x\'?\'bv\':\'bG\';k.7a=k.5Q.6p();k.9q=1w==\'x\'?\'cg\':\'bF\';k.b5=k.9q.6p();k.1H=k.3b=0};m.6T.5e={Z:C(Q){ba(Q){28\'9G\':E k.1L+k.3m+(k.t-m.2r[\'1y\'+k.3n])/2;28\'9I\':E k.H+k.cb+k.1H+(k.D-m.2r[\'1y\'+k.3n])/2;28\'2f\':E k.D+2*k.cb+k.1H+k.3b;28\'5c\':E k.4E-k.3p-k.4D;28\'89\':E k.Z(\'5c\')-2*k.cb-k.1H-k.3b;28\'63\':E k.H-(k.B.1g?k.B.1g.1y:0);28\'83\':E k.Z(\'2f\')+(k.B.1g?2*k.B.1g.1y:0);28\'2I\':E k.1Z?1i.3c((k.D-k.1Z)/2):0}},86:C(){k.cb=(k.B.S[\'1y\'+k.3n]-k.t)/2;k.4D=m[\'97\'+k.9q]},9w:C(){k.t=k.B.el[k.3l]?3M(k.B.el[k.3l]):k.B.el[\'1y\'+k.3n];k.1L=k.B.1L[k.1w];k.3m=(k.B.el[\'1y\'+k.3n]-k.t)/2;q(k.1L==0||k.1L==-1){k.1L=(m.4e[k.3l]/2)+m.4e[\'2a\'+k.5Q]}},87:C(){A B=k.B;k.2Q=\'1Q\';q(B.9n==\'4J\')k.2Q=\'4J\';J q(1J 5s(k.7a).1a(B.4l))k.2Q=I;J q(1J 5s(k.b5).1a(B.4l))k.2Q=\'4x\';k.H=k.1L-k.cb+k.3m;q(k.8W&&k.1w==\'x\')B.6J=1i.3d(B.6J||k.19,B.8W*k.19/B.y.19);k.D=1i.3d(k.19,B[\'4x\'+k.3n]||k.19);k.2L=B.5T?1i.3d(B[\'3d\'+k.3n],k.19):k.19;q(B.2D&&B.3x){k.D=B[k.3l];k.1Z=k.19}q(k.1w==\'x\'&&m.5A)k.2L=B.4B;k.2C=B[\'2C\'+k.1w.aE()];k.3p=m[\'97\'+k.5Q];k.2a=m.4e[\'2a\'+k.5Q];k.4E=m.4e[k.3l]},73:C(i){A B=k.B;q(B.2D&&(B.3x||m.5A)){k.1Z=i;k.D=1i.4x(k.D,k.1Z);B.S.G[k.7a]=k.Z(\'2I\')+\'F\'}J k.D=i;B.S.G[k.3l]=i+\'F\';B.U.G[k.3l]=k.Z(\'2f\')+\'F\';q(B.1g)B.1g.4G();q(B.3H)B.3H.G[k.3l]=i+\'F\';q(k.1w==\'y\'&&B.5U&&B.1f.G.N!=\'1Q\')1t{B.5U.1f.G.2e=\'1Q\'}1v(e){}q(B.2y){A d=B.2p;q(k.9S===1V)k.9S=B.1s[\'1y\'+k.3n]-d[\'1y\'+k.3n];d.G[k.3l]=(k.D-k.9S)+\'F\';q(k.1w==\'x\')B.3V.G.L=\'1Q\';q(B.1f)B.1f.G[k.3l]=\'1Q\'}q(k.1w==\'x\'&&B.1u)B.55(M);q(k.1w==\'x\'&&B.1p&&B.2D){q(i==k.19)B.1p.53(\'19-2H\');J B.1p.4N(\'19-2H\')}},9z:C(i){k.H=i;k.B.U.G[k.7a]=i+\'F\';q(k.B.1g)k.B.1g.4G()}};m.6l=C(a,2c,3y,36){q(W.bW&&m.1E&&!m.a4){m.2m(W,\'41\',C(){1J m.6l(a,2c,3y,36)});E}k.a=a;k.3y=3y;k.36=36||\'2R\';k.2y=(36==\'3w\');k.2D=!k.2y;m.a0=1j;k.1T=[];k.1h=m.1h;m.1h=I;m.7A();A Q=k.Q=m.16.V;O(A i=0;ip.2a+p.4E-p.4D)p.H=p.2a+p.4E-p.D-p.3p-p.4D-p.1H-p.3b;q(p.H(k.x.1Z||k.x.D)){k.c0();q(k.1T.V==1)k.55()}}k.8Z()}1v(e){k.9L(e)}},8r:C(5v,1Q){A c=m.4K(5v,\'79\',\'K-1f\');q(/(1k|3t)/.1a(k.2F)){q(k.4f)c.G.L=k.4f+\'F\';q(k.4m)c.G.N=k.4m+\'F\'}},6L:C(){q(k.aw)E;A B=k;k.1f=m.4K(k.1s,\'79\',\'K-1f\');q(k.2F==\'1k\'){k.65();A 5m=m.3D.5B(1);k.1f.21(5m);k.f5=k.1s.1N;q(!k.4f)k.4f=5m.1N;A 5k=k.1s.1U-k.1f.1U,h=k.4m||m.4e.N-5k-m.4T-m.77,4L=k.3J==\'5D\'?\' 4L="q (m.16[\'+k.Q+\']) m.16[\'+k.Q+\'].5Y()" \':\'\';k.1f.2i+=\'<1k 2X="m\'+(1J 7C()).7D()+\'" f1="0" Q="\'+k.Q+\'" \'+\' G="L:\'+k.4f+\'F; N:\'+h+\'F" \'+4L+\' 1e="\'+k.1e+\'" >\';k.5m=k.1f.2A(\'P\')[0];k.1k=k.1f.2A(\'1k\')[0];q(k.3J==\'5P\')k.7U()}q(k.2F==\'3t\'){k.1f.1x=k.1f.1x||\'m-f6-1x-\'+k.Q;A a=k.8e;q(!a.2c)a.2c={};q(1G a.2c.aG==\'1V\')a.2c.aG=\'f7\';q(96)96.fc(k.1e,k.1f.1x,k.4f,k.4m,a.fb||\'7\',a.fa,a.aF,a.2c,a.ax)}k.aw=M},8B:C(){q(k.1k&&!k.4m){k.1k.G.N=k.1f.G.N=k.8E()+\'F\'}k.1s.21(m.3D);q(!k.x.19)k.x.19=k.1s.1N;k.y.19=k.1s.1U;k.1s.8T(m.3D);q(m.1E&&k.av>3M(k.1s.5H.N)){k.av=3M(k.1s.5H.N)}m.R(k.U,{1l:\'2l\',8O:\'0\'});m.R(k.S,{L:k.x.t+\'F\',N:k.y.t+\'F\'})},8E:C(){A h;1t{A 2z=k.5U=k.1k.9c||k.1k.6i.W;A 3D=2z.1b(\'P\');3D.G.aD=\'aC\';2z.1f.21(3D);h=3D.8K;q(m.1E)h+=3M(2z.1f.5H.4T)+3M(2z.1f.5H.77)-1}1v(e){h=eZ}E h},7U:C(){A 5n=k.1s.1N-k.5m.1N;m.3v(k.5m);q(5n<0)5n=0;A 5k=k.1s.1U-k.1k.1U;q(k.5U&&!k.4m&&!k.N&&k.y.D==k.y.19)1t{k.5U.1f.G.2e=\'1q\'}1v(e){}m.R(k.1k,{L:1i.9D(k.x.D-5n)+\'F\',N:1i.9D(k.y.D-5k)+\'F\'});m.R(k.1f,{L:k.1k.G.L,N:k.1k.G.N});k.4Z=k.1k;k.2p=k.4Z},bc:C(){k.8r(k.1s);q(k.2F==\'3t\'&&k.3J==\'5D\')k.6L();q(k.x.D1O.1U){1O.G.L=(3M(1O.G.L)+7I)+\'F\'}k.4Z=1O;k.2p=k.4Z}q(k.1k&&k.3J==\'5D\')k.7U();q(!k.4Z&&k.y.Dk.2p.22.1U){47("1t { m.16["+k.Q+"].2p.G.2e = \'1Q\'; } 1v(e) {}",m.7s)}},ac:C(5j){A c=5j.eU.6z(\',\');O(A i=0;ip.2a+p.4E-p.4D){q(!5f&&8b&&52){p.D=1i.3d(p.D,p.Z(1w==\'y\'?\'5c\':\'89\'))}J q(p.Z(\'2f\')2V){ 3a=4c*2V;q(3ak.5G&&x.D>k.4B&&y.Z(\'2f\')>y.Z(\'5c\')){y.D-=10;q(2V)x.D=y.D*2V;k.55(0,1);3K=M}}E 3K},eT:C(){q(k.2p){A h=/1k/i.1a(k.2p.3O)?(k.8E()+1)+\'F\':\'1Q\';q(k.1f)k.1f.G.N=h;k.2p.G.N=h;k.y.73(k.1s.1U)}},8Z:C(){A x=k.x,y=k.y;k.5l(\'1q\');m.1A(k,\'eS\');q(k.1p&&k.1p.2J)k.1p.2J.4W();k.9Z(1,{U:{L:x.Z(\'2f\'),N:y.Z(\'2f\'),18:x.H,Y:y.H},S:{18:x.1H+x.Z(\'2I\'),Y:y.1H+y.Z(\'2I\'),L:x.1Z||x.D,N:y.1Z||y.D}},m.7s)},9Z:C(1I,2g,4b){A 5x=k.3i,8G=1I?(k.1h?k.1h.a:I):m.2s,t=(5x[1]&&8G&&m.43(8G,\'3i\')[1]==5x[1])?5x[1]:5x[0];q(k[t]&&t!=\'2H\'){k[t](1I,2g);E}q(k.1g&&!k.3F){q(1I)k.1g.4G();J k.1g.6q((k.2y&&k.4z))}q(!1I)k.7H();A B=k,x=B.x,y=B.y,2O=k.2O;q(!1I)2O=k.cw||2O;A 5P=1I?C(){q(B.1g)B.1g.2h.G.1n="1X";47(C(){B.6C()},50)}:C(){B.5z()};q(1I)m.R(k.U,{L:x.t+\'F\',N:y.t+\'F\'});q(1I&&k.2y){m.R(k.U,{18:(x.1L-x.cb+x.3m)+\'F\',Y:(y.1L-y.cb+y.3m)+\'F\'})}q(k.ct){m.R(k.U,{1z:1I?0:1});m.3s(2g.U,{1z:1I})}m.2u(k.U,2g.U,{45:4b,2O:2O,3U:C(3g,2G){q(B.1g&&B.3F&&2G.1d==\'Y\'){A 5C=1I?2G.H:1-2G.H;A H={w:x.t+(x.Z(\'2f\')-x.t)*5C,h:y.t+(y.Z(\'2f\')-y.t)*5C,x:x.1L+(x.H-x.1L)*5C,y:y.1L+(y.H-y.1L)*5C};B.1g.4G(H,0,1)}q(B.2y){q(2G.1d==\'18\')B.3V.G.18=(x.H-3g)+\'F\';q(2G.1d==\'Y\')B.3V.G.Y=(y.H-3g)+\'F\'}}});m.2u(k.S,2g.S,4b,2O,5P);q(1I){k.U.G.1n=\'1X\';k.S.G.1n=\'1X\';q(k.2y)k.1s.G.1n=\'1X\';k.a.1c+=\' K-57-4l\'}},6b:C(1I,2g){k.3F=1j;A B=k,t=1I?m.7s:0;q(1I){m.2u(k.U,2g.U,0);m.R(k.U,{1z:0,1n:\'1X\'});m.2u(k.S,2g.S,0);k.S.G.1n=\'1X\';m.2u(k.U,{1z:1},t,I,C(){B.6C()})}q(k.1g){k.1g.2h.G.1B=k.U.G.1B;A 7z=1I||-1,1y=k.1g.1y,8y=1I?3:1y,8L=1I?1y:3;O(A i=8y;7z*i<=7z*8L;i+=7z,t+=25){(C(){A o=1I?8L-i:8y-i;47(C(){B.1g.4G(0,o,1)},t)})()}}q(1I){}J{47(C(){q(B.1g)B.1g.6q(B.4z);B.7H();m.2u(B.U,{1z:0},m.9Y,I,C(){B.5z()})},t)}},42:C(1I,2g,8m){q(!1I)E;A B=k,1h=k.1h,x=k.x,y=k.y,3k=1h.x,3q=1h.y,U=k.U,S=k.S,1u=k.1u;m.4R(W,\'7x\',m.7n);m.R(S,{L:(x.1Z||x.D)+\'F\',N:(y.1Z||y.D)+\'F\'});q(1u)1u.G.2e=\'1X\';k.1g=1h.1g;q(k.1g)k.1g.B=B;1h.1g=I;A 5u=m.1b(\'P\',{1c:\'K-\'+k.36},{1l:\'2l\',1B:4,2e:\'1q\',1o:\'1F\'});A 8j={cI:1h,cC:k};O(A n 3e 8j){k[n]=8j[n].S.5B(1);m.R(k[n],{1l:\'2l\',8g:0,1n:\'1X\'});5u.21(k[n])}U.21(5u);q(k.2y)m.R(k.3V,{18:0,Y:0});q(1u){1u.1c=\'\';U.21(1u)}5u.G.1o=\'\';1h.S.G.1o=\'1F\';q(m.4H&&m.3f<7O){k.U.G.1n=\'1X\'}m.2u(U,{L:x.D},{45:m.cz,3U:C(3g,2G){A H=2G.H,4C=1-H;A 1d,D={},8v=[\'H\',\'D\',\'1H\',\'3b\'];O(A n 3e 8v){1d=8v[n];D[\'x\'+1d]=1i.3c(4C*3k[1d]+H*x[1d]);D[\'y\'+1d]=1i.3c(4C*3q[1d]+H*y[1d]);D.cq=1i.3c(4C*(3k.1Z||3k.D)+H*(x.1Z||x.D));D.7h=1i.3c(4C*3k.Z(\'2I\')+H*x.Z(\'2I\'));D.cL=1i.3c(4C*(3q.1Z||3q.D)+H*(y.1Z||y.D));D.6E=1i.3c(4C*3q.Z(\'2I\')+H*y.Z(\'2I\'))}q(B.1g)B.1g.4G({x:D.3j,y:D.4u,w:D.5F+D.49+D.8q+2*x.cb,h:D.5Z+D.4a+D.8z+2*y.cb});1h.U.G.eN=\'eM(\'+(D.4u-3q.H)+\'F, \'+(D.5F+D.49+D.8q+D.3j+2*3k.cb-3k.H)+\'F, \'+(D.5Z+D.4a+D.8z+D.4u+2*3q.cb-3q.H)+\'F, \'+(D.3j-3k.H)+\'F)\';m.R(S,{Y:(D.4a+y.Z(\'2I\'))+\'F\',18:(D.49+x.Z(\'2I\'))+\'F\',4T:(y.H-D.4u)+\'F\',4y:(x.H-D.3j)+\'F\'});m.R(U,{Y:D.4u+\'F\',18:D.3j+\'F\',L:(D.49+D.8q+D.5F+2*x.cb)+\'F\',N:(D.4a+D.8z+D.5Z+2*y.cb)+\'F\'});m.R(5u,{L:(D.cq||D.5F)+\'F\',N:(D.cL||D.5Z)+\'F\',18:(D.49+D.7h)+\'F\',Y:(D.4a+D.6E)+\'F\',1n:\'1X\'});m.R(B.cI,{Y:(3q.H-D.4u+3q.1H-D.4a+3q.Z(\'2I\')-D.6E)+\'F\',18:(3k.H-D.3j+3k.1H-D.49+3k.Z(\'2I\')-D.7h)+\'F\'});m.R(B.cC,{1z:H,Y:(y.H-D.4u+y.1H-D.4a+y.Z(\'2I\')-D.6E)+\'F\',18:(x.H-D.3j+x.1H-D.49+x.Z(\'2I\')-D.7h)+\'F\'});q(1u)m.R(1u,{L:D.5F+\'F\',N:D.5Z+\'F\',18:(D.49+x.cb)+\'F\',Y:(D.4a+y.cb)+\'F\'})},6O:C(){U.G.1n=S.G.1n=\'1X\';S.G.1o=\'3Q\';m.3v(5u);B.6C();1h.5z();B.1h=I}})},br:C(o,el){q(!k.1h)E 1j;O(A i=0;i\'+s+\'

    \'+k[k.64].2i}}},90:C(){q(!k.1h){O(A i=0;ik.x.Z(\'63\')+k.x.Z(\'83\'));A bg=(3T.y+3T.hk.y.Z(\'63\')+k.y.Z(\'83\'))}A 6Z=m.82(1m[i]);q(!bz&&!bg&&6Z!=k.Q){q(!2P){1m[i].5E(\'1q-by\',\'[\'+k.Q+\']\');1m[i].9d=1m[i].G[1d];1m[i].G[1d]=\'1q\'}J q(2P.bx(\'[\'+k.Q+\']\')==-1){1m[i].5E(\'1q-by\',2P+\'[\'+k.Q+\']\')}}J q((2P==\'[\'+k.Q+\']\'||m.2Y==6Z)&&6Z!=k.Q){1m[i].5E(\'1q-by\',\'\');1m[i].G[1d]=1m[i].9d||\'\'}J q(2P&&2P.bx(\'[\'+k.Q+\']\')>-1){1m[i].5E(\'1q-by\',2P.2d(\'[\'+k.Q+\']\',\'\'))}}}}},3P:C(){k.U.G.1B=m.4t+=2;O(A i=0;i11.22.1N)11.G.L=\'2x%\'}J q(11.22!=k.1u)k.1u.21(11);q(/18$/.1a(p))11.G.18=6D+\'F\';q(/4J$/.1a(p))m.R(11,{18:\'50%\',4y:(6D-1i.3c(11.1N/2))+\'F\'});q(/3o$/.1a(p))11.G.3o=-6D+\'F\';q(/^c5$/.1a(p)){m.R(11,{3o:\'2x%\',9h:k.x.cb+\'F\',Y:-k.y.cb+\'F\',4j:-k.y.cb+\'F\',2e:\'1Q\'});k.x.1H=11.1N}J q(/^c6$/.1a(p)){m.R(11,{18:\'2x%\',4y:k.x.cb+\'F\',Y:-k.y.cb+\'F\',4j:-k.y.cb+\'F\',2e:\'1Q\'});k.x.3b=11.1N}A 9j=11.22.1U;11.G.N=\'1Q\';q(4Y&&11.1U>9j)11.G.N=m.5h?9j+\'F\':\'2x%\';q(/^Y/.1a(p))11.G.Y=6H+\'F\';q(/^9i/.1a(p))m.R(11,{Y:\'50%\',4T:(6H-1i.3c(11.1U/2))+\'F\'});q(/^4j/.1a(p))11.G.4j=-6H+\'F\';q(/^5X$/.1a(p)){m.R(11,{18:(-k.x.1H-k.x.cb)+\'F\',3o:(-k.x.3b-k.x.cb)+\'F\',4j:\'2x%\',77:k.y.cb+\'F\',L:\'1Q\'});k.y.1H=11.1U}J q(/^7w$/.1a(p)){m.R(11,{1l:\'4n\',18:(-k.x.1H-k.x.cb)+\'F\',3o:(-k.x.3b-k.x.cb)+\'F\',Y:\'2x%\',4T:k.y.cb+\'F\',L:\'1Q\'});k.y.3b=11.1U;11.G.1l=\'2l\'}},c3:C(){k.9V([\'4U\',\'9M\'],M);k.c1();q(k.9M)m.1A(k,\'g2\');q(k.4U)m.1A(k,\'fV\');q(k.4U&&k.9N)k.4U.1c+=\' K-3A\';q(m.c2)k.c8();O(A i=0;i=5.5){s=s.2d(1J 5s(\']*>\',\'c9\'),\'\').2d(1J 5s(\']*>.*?\',\'c9\'),\'\');q(k.1k){A 2z=k.1k.9c;q(!2z&&k.1k.6i)2z=k.1k.6i.W;q(!2z){A 3C=k;47(C(){3C.6h()},25);E}2z.c7();2z.cN(s);2z.2b();1t{s=2z.92(k.1x).2i}1v(e){1t{s=k.1k.W.92(k.1x).2i}1v(e){}}m.3v(k.1k)}J{7g=/(<1f[^>]*>|<\\/1f>)/de;q(7g.1a(s))s=s.6z(7g)[m.1E?1:2]}}m.4K(k.S,\'79\',\'K-1f\').2i=s;k.3z();O(A x 3e k)k[x]=I}};m.9W=C(4h,1r){q(m.dT!==1j)m.93();k.4h=4h;O(A x 3e 1r)k[x]=1r[x];q(k.e2)k.c4();q(k.2J)k.2J=m.bm(k)};m.9W.5e={c4:C(){k.35=m.1b(\'P\',{2i:m.9Q(m.9R.35)},I,m.29);A 6a=[\'3I\',\'3r\',\'2W\',\'1C\',\'3A\',\'19-2H\',\'2b\'];k.1M={};A 3C=k;O(A i=0;i<6a.V;i++){k.1M[6a[i]]=m.4K(k.35,\'1K\',\'K-\'+6a[i]);k.4N(6a[i])}k.1M.3r.G.1o=\'1F\'},bp:C(){q(k.bs||!k.35)E;A B=m.16[k.4h],4X=B.6Q(),2o=/7e$/;q(4X==0)k.53(\'2W\');J q(2o.1a(k.1M.2W.2A(\'a\')[0].1c))k.4N(\'2W\');q(4X+1==m.4P.3h[B.2N||\'1F\'].V){k.53(\'1C\');k.53(\'3I\')}J q(2o.1a(k.1M.1C.2A(\'a\')[0].1c)){k.4N(\'1C\');k.4N(\'3I\')}},4N:C(1M){q(!k.1M)E;A bo=k,a=k.1M[1M].2A(\'a\')[0],2o=/7e$/;a.2n=C(){bo[1M]();E 1j};q(2o.1a(a.1c))a.1c=a.1c.2d(2o,\'\')},53:C(1M){q(!k.1M)E;A a=k.1M[1M].2A(\'a\')[0];a.2n=C(){E 1j};q(!/7e$/.1a(a.1c))a.1c+=\' 7e\'},bi:C(){q(k.4d)k.3r();J k.3I()},3I:C(bk){q(k.1M){k.1M.3I.G.1o=\'1F\';k.1M.3r.G.1o=\'\'}k.4d=M;q(!bk)m.1C(k.4h)},3r:C(){q(k.1M){k.1M.3r.G.1o=\'1F\';k.1M.3I.G.1o=\'\'}e7(k.4d);k.4d=I},2W:C(){k.3r();m.2W(k.1M.2W)},1C:C(){k.3r();m.1C(k.1M.1C)},3A:C(){},\'19-2H\':C(){m.2B().74()},2b:C(){m.2b(k.1M.2b)}};m.bm=C(1p){C 6K(B){m.3s(1r||{},{4I:4Q,23:\'2J\',1c:\'K-2J-\'+51+\'-11 \'+(1r.1c||\'\')});q(m.5h)1r.6b=0;B.4p(1r);m.R(4Q.22,{2e:\'1q\'})};C 2a(3S){4W(1V,1i.3c(3S*4Q[3R?\'1N\':\'1U\']*0.7))};C 4W(i,9J){q(i===1V)O(A j=0;j<6x.V;j++){q(6x[j]==m.16[1p.4h].a){i=j;5a}}q(i===1V)E;A as=4Q.2A(\'a\'),57=as[i],3Y=57.22,18=3R?\'bv\':\'bG\',3o=3R?\'cg\':\'bF\',L=3R?\'bH\':\'bI\',4O=\'1y\'+18,1N=\'1y\'+L,6Y=P.22.22[1N],4V=6Y-2h[1N],6n=3M(2h.G[3R?\'18\':\'Y\'])||0,2M=6n,dz=20;q(9J!==1V){2M=6n-9J;q(4V>0)4V=0;q(2M>0)2M=0;q(2M<4V)2M=4V}J{O(A j=0;j0?as[i-1].22[4O]:3Y[4O],80=3Y[4O]+3Y[1N]+(as[i+1]?as[i+1].22[1N]:0);q(80>6Y-6n)2M=6Y-80;J q(85<-6n)2M=-85}A 7V=3Y[4O]+(3Y[1N]-76[1N])/2+2M;m.2u(2h,3R?{18:2M}:{Y:2M},I,\'8d\');m.2u(76,3R?{18:7V}:{Y:7V},I,\'8d\');8P.G.1o=2M<0?\'3Q\':\'1F\';8N.G.1o=(2M>4V)?\'3Q\':\'1F\'};A 6x=m.4P.3h[m.16[1p.4h].2N||\'1F\'],1r=1p.2J,51=1r.51||\'bE\',8H=(51==\'dr\'),3Z=8H?[\'P\',\'6c\',\'1K\',\'1D\']:[\'2h\',\'4q\',\'3X\',\'2E\'],3R=(51==\'bE\'),4Q=m.1b(\'P\',{1c:\'K-2J K-2J-\'+51,2i:\'

    \'+\'<\'+3Z[0]+\'><\'+3Z[1]+\'>

    \'+\'

    \'+\'

    \'+\'

    \'},{1o:\'1F\'},m.29),6t=4Q.7Q,P=6t[0],8P=6t[1],8N=6t[2],76=6t[3],2h=P.dH,4q=4Q.2A(3Z[1])[0],3X;O(A i=0;i<6x.V;i++){q(i==0||!3R)3X=m.1b(3Z[2],I,I,4q);(C(){A a=6x[i],3Y=m.1b(3Z[3],I,I,3X),dC=i;m.1b(\'a\',{24:a.24,2n:C(){m.2B(k).3P();E m.8A(a)},2i:m.bA?m.bA(a):a.2i},I,3Y)})()}q(!8H){8P.2n=C(){2a(-1)};8N.2n=C(){2a(1)};m.2m(4q,W.dG!==1V?\'dF\':\'ds\',C(e){A 3S=0;e=e||1S.2v;q(e.cy){3S=e.cy/e6;q(m.3u)3S=-3S}J q(e.cE){3S=-e.cE/3}q(3S)2a(-3S*0.2);q(e.5g)e.5g();e.cv=1j})}E{6K:6K,4W:4W}};m.6N=m.14;A dd=m.6l;q(m.1E&&1S==1S.Y){(C(){1t{W.59.di(\'18\')}1v(e){47(ck.dj,50);E}m.41()})()}m.2m(W,\'d7\',m.41);m.2m(1S,\'81\',m.41);m.2m(W,\'41\',C(){q(m.7M||m.48){A G=m.1b(\'G\',{T:\'d5/8p\'},I,W.2A(\'da\')[0]);C 6o(8u,8o){q(!m.1E){G.21(W.cS(8u+" {"+8o+"}"))}J{A 1h=W.cm[W.cm.V-1];q(1G(1h.6o)=="7F")1h.6o(8u,8o)}}C 6g(1d){E\'dP( ( ( dq = W.59.\'+1d+\' ? W.59.\'+1d+\' : W.1f.\'+1d+\' ) ) + \\\'F\\\' );\'}q(m.7M)6o(\'.K 1R\',\'4w: 7R(\'+m.5p+m.7M+\'), 7i !ef;\');6o(\'.K-2t-D\',m.1E&&(m.3f<7||W.7t==\'8I\')?\'1l: 2l; \'+\'18:\'+6g(\'6v\')+\'Y:\'+6g(\'69\')+\'L:\'+6g(\'8F\')+\'N:\'+6g(\'ca\'):\'1l: fg; L: 2x%; N: 2x%; 18: 0; Y: 0\')}});m.2m(1S,\'4g\',C(){m.7k();q(m.2t)O(A i=0;i /** ///////////////////////// FAQ und Glossar neu seit dem 23 Aug 2011 ///////////////////////// **/ function losearticlefaqm(id){ $('#faqcontent_'+id).toggle(); $('#faqlinkmore_'+id).toggle(); } function showFAQContent(id,genkey){ $('.faqcontent').hide(); $('.faqmoreinfos').show(); $('#faqcontent_'+id).toggle(); $('#faqlinkmore_'+id).toggle(); $("#faqcontent_"+id).load('/includesOpen/faq_loader.php?key=faqml&id='+id+'&genkey='+genkey+'&true'); } function opentabinlay(indikator){ $("#glossarinfo").addClass('nichtzeigen'); $("#glossarinfo").animate({ width: '0px', opacity: 0.4, marginLeft: '0px', marginTop: '0px' }, 300 ); $(".zeigenmasterdingsda").addClass('nichtzeigenmasterdingsda'); $(".zeigenmasterdingsda").removeClass('zeigenmasterdingsda'); $("#MasterDings_"+indikator).removeClass('nichtzeigenmasterdingsda'); $("#MasterDings_"+indikator).addClass('zeigenmasterdingsda'); } function closeinfo() { $("#glossarinfo").removeClass(); $("#glossarinfo").addClass('zeigiding nichtzeigen quickinfos'); $("#glossarinfo").animate({ width: '0px', opacity: 0, marginLeft: '0px', marginTop: '0px' }, 300 ); } function getinfos(loadtext,identer,datenid) { if($("#glossarinfo").hasClass('nichtzeigen')) { $("#glossarinfo").addClass('LOAD_'+datenid+identer); $("#glossarinfo").removeClass('nichtzeigen'); $("#glossarinfo").animate({ width: '450px', opacity: 1, marginLeft: '-465px' }, 300 ); $("#quickinfosinlay").html(loadtext); }else{ if($("#glossarinfo").hasClass('LOAD_'+datenid+identer)) { $("#glossarinfo").removeClass('LOAD_'+datenid+identer); $("#glossarinfo").addClass('nichtzeigen'); $("#glossarinfo").animate({ width: '0px', opacity: 0, marginLeft: '0px', marginTop: '0px' }, 300 ); }else{ $("#glossarinfo").addClass('LOAD_'+datenid+identer); $("#quickinfosinlay").html(loadtext); } } } /** ///////////////////////// ENDE FAQ und Glossar ///////////////////////// **/ function tellafriend(){ $.facebox({ ajax: '/includesOpen/tellafriend.php'}); } function checkDomain(nname) { var arr = new Array( '.com','.net','.org','.biz','.coop','.info','.museum','.name', '.pro','.edu','.gov','.int','.mil','.ac','.ad','.ae','.af','.ag', '.ai','.al','.am','.an','.ao','.aq','.ar','.as','.at','.au','.aw', '.az','.ba','.bb','.bd','.be','.bf','.bg','.bh','.bi','.bj','.bm', '.bn','.bo','.br','.bs','.bt','.bv','.bw','.by','.bz','.ca','.cc', '.cd','.cf','.cg','.ch','.ci','.ck','.cl','.cm','.cn','.co','.cr', '.cu','.cv','.cx','.cy','.cz','.de','.dj','.dk','.dm','.do','.dz', '.ec','.ee','.eg','.eh','.er','.es','.et','.eu','.fi','.fj','.fk','.fm', '.fo','.fr','.ga','.gd','.ge','.gf','.gg','.gh','.gi','.gl','.gm', '.gn','.gp','.gq','.gr','.gs','.gt','.gu','.gv','.gy','.hk','.hm', '.hn','.hr','.ht','.hu','.id','.ie','.il','.im','.in','.io','.iq', '.ir','.is','.it','.je','.jm','.jo','.jp','.ke','.kg','.kh','.ki', '.km','.kn','.kp','.kr','.kw','.ky','.kz','.la','.lb','.lc','.li', '.lk','.lr','.ls','.lt','.lu','.lv','.ly','.ma','.mc','.md','.mg', '.mh','.mk','.ml','.mm','.mn','.mo','.mp','.mq','.mr','.ms','.mt', '.mu','.mv','.mw','.mx','.my','.mz','.na','.nc','.ne','.nf','.ng', '.ni','.nl','.no','.np','.nr','.nu','.nz','.om','.pa','.pe','.pf', '.pg','.ph','.pk','.pl','.pm','.pn','.pr','.ps','.pt','.pw','.py', '.qa','.re','.ro','.rw','.ru','.sa','.sb','.sc','.sd','.se','.sg', '.sh','.si','.sj','.sk','.sl','.sm','.sn','.so','.sr','.st','.sv', '.sy','.sz','.tc','.td','.tf','.tg','.th','.tj','.tk','.tm','.tn', '.to','.tp','.tr','.tt','.tv','.tw','.tz','.ua','.ug','.uk','.um', '.us','.uy','.uz','.va','.vc','.ve','.vg','.vi','.vn','.vu','.ws', '.wf','.ye','.yt','.yu','.za','.zm','.zw'); var mai = nname; var val = true; var dot = mai.lastIndexOf("."); var dname = mai.substring(0,dot); var ext = mai.substring(dot,mai.length); //alert(ext); if(dot>2 && dot<57){ for(var i=0; i 47 && hh<59) || (hh > 64 && hh<91) || (hh > 96 && hh<123) || hh==45 || hh==46) { if((j==0 || j==dname.length-1) && hh == 45) { //alert("Domains dürfen nicht mit '-' beginnen oder enden"); return false; } } else { //alert("Domains dürfen keine Sonderzeichen enthalten"); return false; } } } } else { //alert("Domains müssen zwischen 3 und 56 Zeichen lang sein"); return false; } return true; } function mtDotspot(NAME,DOMAIN,SUBJECT,BODY){ var SUBJECT1 = ""; if(SUBJECT.length<2) { var SUBJECT1 = SUBJECT; } var BODY1 = ""; if(BODY.length<2) { var BODY1 = BODY; } getURL("mailto:"+NAME+"@"+DOMAIN+"?subject="+escape(SUBJECT1)+"&body="+escape(BODY1),'_blank'); } function mailprintfooter(a,b,c){ document.write(""+a+"@"+b+"."+c+""); } function mailprint(a,b,c){ document.write(""+a+"@"+b+"."+c+""); } ///////////////////////////////////////////////////////////////// function SubmitDelete_WP(MSG){ if(MSG=='') { alert('Es ist ein Fehler im Programm (javascript)'); }else{ Check = confirm(MSG); if (Check == true) { document.wp_delete.submit(); }else{ return false; } } } function SubmitDelete_MYPOSTWP(MSG) { if(MSG=='') { alert('Es ist ein Fehler im Programm (javascript)'); }else{ Check = confirm(MSG); if (Check == true) { document.mwp_delete.submit(); }else{ return false; } } } function TesteValues5(values) { return TesteValuesmitle(values,5); } function TesteValues4(values) { return TesteValuesmitle(values,4); } function TesteValues3(values) { return TesteValuesmitle(values,3); } function TesteValues2(values) { return TesteValuesmitle(values,2); } function TesteValuesmitle(values,lenge) { if(values.length5) { return false; }else{ var ist_zahl = false; for(n=0; n < values.length; n++) { if( values.charAt(n) < '0' || values.charAt(n) > '9') { ist_zahl = false; break; }else{ ist_zahl = true; } } ////////////////////// if(ist_zahl) { if( values <= 999 ) { return false; }else{ return true; } }else{ return false; } } } function generateAlerts(indikator) { var ErDATAPW='Bitte geben Sie Ihr Passwort ein. Bitte kontrollieren Sie die Schreibweise: keine Sonderzeichen oder Umlaute; (nur a-z und 0 bis 9 sind erlaubt)'; if( indikator == 1 ) { ERRORSMSGALERT = ''; } if (indikator == 2) { ERRORSMSGALERT = ''; } if (indikator == 3) { ERRORSMSGALERT = 'Username/Passwort Grossbuchstaben und Sonderzeichen (ausser Bindestrich und Unterstrich) sind nicht erlaubt. Bitte mindestens 6 Zeichen angeben.'; } if (indikator == 4) { ERRORSMSGALERT = 'Ihre E-Mail-Adresse ist falsch; bitte kontrollieren Sie die Schreibweise'; } if (indikator == 5) { ERRORSMSGALERT = 'Dieser Username ist leider bereits schon vergeben. Bitte geben Sie einen anderen Username ein.'; } if( indikator == 6 ) { ERRORSMSGALERT = 'Bitte geben Sie Ihren Nachnamen ein'; } if (indikator == 7) { ERRORSMSGALERT = 'Bitte geben Sie Ihren Vorname an'; } if (indikator == 8) { ERRORSMSGALERT = 'Bitte geben Sie die Adresse ein'; } if (indikator == 9) { ERRORSMSGALERT = 'Bitte geben Sie die PLZ an'; } if (indikator == 10) { ERRORSMSGALERT = 'Bitte geben Sie eine Ortschaft an'; } if (indikator == 11) { ERRORSMSGALERT = 'Tel ist nicht korrekt eingegeben (nur +, -, / und 0 bis 9 sind erlaubt)'; } if (indikator == 12) { ERRORSMSGALERT = 'Ihr Bestellfeld ist leer'; } if (indikator == 13) { ERRORSMSGALERT = 'Die Sicherheitsabfrage ist leer!'; } if (indikator == 14) { ERRORSMSGALERT = 'Der Wochenplatztitel ist nicht gesetzt!'; } if (indikator == 15) { ERRORSMSGALERT = 'Die Zeit ist nicht gesetzt!'; } if (indikator == 16) { ERRORSMSGALERT = 'Bitte geben Sie eine anz. Stunden an!'; } if (indikator == 17) { ERRORSMSGALERT = 'Bitte beschreiben Sie Ihr Anliegen.'; } if (indikator == 18) { ERRORSMSGALERT = 'Bitte wiederholen Sie Ihr Passwort'; } if (indikator == 19) { ERRORSMSGALERT = 'Bitte geben Sie Ihr Passwort ein'; } if (indikator == 20) { ERRORSMSGALERT = 'Bitte geben Sie Ihren Rufname an'; } if (indikator == 21) { ERRORSMSGALERT = 'Die Natelnummer ist nicht korrekt (nur +, -, / und 0 bis 9 sind erlaubt)'; } if (indikator == 22) { ERRORSMSGALERT = 'Bitte geben Sie Ihr Geburtsjahr ein'; } if (indikator == 23) { ERRORSMSGALERT = 'Bitte geben Sie Ihr Geburtsmonat ein'; } if (indikator == 24) { ERRORSMSGALERT = 'Bitte geben Sie Ihr Geburtstag ein'; } if(ERRORSMSGALERT){ alert(ERRORSMSGALERT); } } function testeTellAFriend() { var X=0; if( !TesteValues(document.getElementById('t_name_empf').value) ) { X++; return false; } if( !TesteValues(document.getElementById('t_mail_empf').value) ) { X++; return false; } if( !validateEmail('t_mail_empf') ) { X++; generateAlerts(4); return false; } if( !TesteValues(document.getElementById('t_mail_sender').value) ) { X++; return false; } if( !TesteValues(document.getElementById('t_mail_sender').value) ) { X++; return false; } if( !validateEmail('t_mail_sender') ) { X++; generateAlerts(4); return false; } if($("#t_mail_empf").val() == $("#t_mail_sender").val()) { X++; alert("Absender und Empfänger können nicht die selben sein"); return false; } if( X == 0 ) { $.ajax({ url: '/includesOpen/captcha/checkCaptcha.php', type: 'post', dataType: 'json', data: { code: $("#captchaInput").val() }, success: function(data) { if(data === true) { $("#tellafriend").submit(); } else { alert('Bitte überprüfen Sie Ihre Captcha-Eingabe'); } } }); }else{ return false; } } function testeMeineDaten() { var X=0; if( !TesteValues(document.getElementById('mu_Passwort').value) ) { X++; generateAlerts(19); return false; } if( !validatePassword('mu_Passwort') ) { X++; generateAlerts(19); return false; } if( document.getElementById('mu_Passwort').value != document.getElementById('mu_Passwort2').value ) { X++; generateAlerts(18); return false; } if( !TesteValues(document.getElementById('mu_Name').value) ) { X++; generateAlerts(6); return false; } if( !TesteValues(document.getElementById('mu_Vorname').value) ) { X++; generateAlerts(7); return false; } if( !TesteValues(document.getElementById('mu_Adresse').value) ) { X++; generateAlerts(8); return false; } if( !TesteValues(document.getElementById('mu_PLZ').value) ) { X++; generateAlerts(9); return false; } if( !TestZIP(document.getElementById('mu_PLZ').value) ) { X++; generateAlerts(9); return false; } if( !TesteValues(document.getElementById('mu_Ort').value) ) { X++; generateAlerts(10); return false; } if( X == 0 ) { document.meineDaten.submit(); }else{ return false; } } function shopDataControll() { var X=0; if( !TesteValues(document.getElementById('id_4').value) ) { X++; generateAlerts(6); return false; } if( !TesteValues(document.getElementById('id_5').value) ) { X++; generateAlerts(7); return false; } if( !TesteValues(document.getElementById('id_8').value) ) { X++; generateAlerts(9); return false; } if( !TesteValues(document.getElementById('id_9').value) ) { X++; generateAlerts(10); return false; } if( !TesteValues(document.getElementById('id_11').value) ) { X++; generateAlerts(4); return false; } if( !validateEmail('id_11') ) { X++; generateAlerts(4); return false; } if( X == 0 ) { document.getElementById('bestellen').value='bestellen'; document.bestellung_b.submit(); }else{ return false; } } function testeForm_kontakt() { var X=0; if( !TesteValues(document.getElementById('firstName').value) ) { X++; generateAlerts(6); return false; } if( !TesteValues(document.getElementById('lastName').value) ) { X++; generateAlerts(7); return false; } if( !TesteValues(document.getElementById('email').value) ) { X++; generateAlerts(4); return false; } if( !validateEmail('email') ) { X++; generateAlerts(4); return false; } if( !TesteValues(document.getElementById('message').value) ) { X++; generateAlerts(17); return false; } if( X == 0 ) { document.kontakt_form.submit(); }else{ return false; } } function NLTest() { var X=0; if(document.getElementById('myusersnl_status').checked){ if(!TesteValues($('#myusersVorname').val()) ) { X++; $('#myusersVorname').focus(); generateAlerts(7); return false; } if(!TesteValues($('#myusersNachname').val()) ) { X++; $('#myusersNachname').focus(); generateAlerts(6); return false; } } if( !TesteValues($('#myusersEmail').val()) ) { X++; $('#myusersEmail').focus(); generateAlerts(4); return false; } if(!validateEmail('myusersEmail')){ X++; $('#myusersEmail').focus(); generateAlerts(4); return false; } if( !TesteValues($('#captchaInput').val()) ) { X++; $('#captchaInput').focus(); generateAlerts(13); return false; } if( X == 0 ) { $.ajax({ url: '/includesOpen/captcha/checkCaptcha.php', type: 'post', dataType: 'json', data: { code: $("#captchaInput").val() }, success: function(data) { if(data === true) { document.nlform.submit(); } else { alert('Bitte überprüfen Sie Ihre Captcha-Eingabe'); } } }); }else{ return false; } } /////////////////////////////////////////// function browsersize(breite) { return parseInt(1250-(breite/2)); } function goToContextHelp(id) { var ID = id; Fenster1 = window.open('/_popups/admin_help.php?helpCenterID='+ID,'help','width=500,height=250,left=100,top=100,resizable=no,status=no,scrollbars=yes'); Fenster1.focus(); } function Fensterweite () { var A = window.innerWidth; var B = document.body.offsetWidth; var C = self.innerWidth; if(!B) { if(!A) { return C; }else{ return A; } }else{ return B; } } function Fensterhoehe () { if (window.innerHeight) { return window.innerHeight; } else if (document.body && document.body.offsetHeight) { return document.body.offsetHeight; }else{ return 0; } } function neuAufbau () { if (Weite != Fensterweite() || Hoehe != Fensterhoehe()) location.href = location.href; } function sendwein() { submit(); } function myprint() { self.focus(); window.print(); } function MM_displayStatusMsg(msgStr) { //v1.0 top.status=msgStr; document.MM_returnValue = true; } function MM_findObj(n, d) { //v4.01 var p,i,x; if(!d) d=document; if((p=n.indexOf('?'))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i 2) { if ((img = MM_findObj(args[2])) != null && !img.MM_init) { img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src; if ((nbArr = document[grpName]) == null) nbArr = document[grpName] = new Array(); nbArr[nbArr.length] = img; for (i=4; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) { if (!img.MM_up) img.MM_up = img.src; img.src = img.MM_dn = args[i+1]; nbArr[nbArr.length] = img; } } } else if (event == 'over') { document.MM_nbOver = nbArr = new Array(); for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i])) != null) { if (!img.MM_up) img.MM_up = img.src; img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])? args[i+1] : img.MM_up); nbArr[nbArr.length] = img; } } else if (event == 'out' ) { for (i=0; i < document.MM_nbOver.length; i++) { img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn : img.MM_up; } } else if (event == 'down') { nbArr = document[grpName]; if (nbArr) for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src = img.MM_up; img.MM_dn = 0; } document[grpName] = nbArr = new Array(); for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) { if (!img.MM_up) img.MM_up = img.src; img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up; nbArr[nbArr.length] = img; } } } function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i4) { return false; } var stryear = year; var day = Number(day); var mon = Number(mon); var year = Number(year); if((isNaN(day)) || (isNaN(mon)) || (isNaN(year))) { return false; } if(stryear.length==2) { return false; } if(year<1900 || year>2000) { return false; } if ((mon == 4 || mon == 6 || mon == 9 || mon == 11) && day == 31) { return false; } if (mon == 2) { var isleap=(year%4==0 && (year%100!=0 || year%400==0)); if (day > 29 || (day == 29 && !isleap)) { return false; } } return true; } function formular_select(formname, lang, id, meldung) { var imgprint = "img_"+id; if("" == document.forms[formname]['id_'+id][document.forms[formname]['id_'+id].selectedIndex].value || "Bitte wählen Sie:" == document.forms[formname]['id_'+id][document.forms[formname]['id_'+id].selectedIndex].value || "Veuillez choisir:" == document.forms[formname]['id_'+id][document.forms[formname]['id_'+id].selectedIndex].value || "Choississez s.v.p.:" == document.forms[formname]['id_'+id][document.forms[formname]['id_'+id].selectedIndex].value) { nonAustausch(imgprint); if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); }else{ austausch(imgprint); } } function formular_imput(formname, lang, id, meldung, stingtyp) { var imgprint = "img_"+id; var imput = document.forms[formname]['id_'+id].value; if(imput == "" || imput == " ") { if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); }else{ if( stingtyp == "string" ) { if(imput.length<1) { if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); }else{ austausch(imgprint); } } if(stingtyp == "email") { if(imput.indexOf('@') == -1 || imput.indexOf('.') == -1) { if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); }else{ austausch(imgprint); } } if( stingtyp == "zip" ) { if(imput.length<5) { if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); }else{ for(n=0; n < imput.length; n++) { if( imput.charAt(n) < "0" || imput.charAt(n) > "9") { ist_zahl = false; break; }else{ ist_zahl = true; } } if(ist_zahl) { wert = document.forms[formname]['id_'+id].value; if( wert <= 999 ) { if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); }else{ austausch(imgprint); } }else{ if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); } } } if(stingtyp == "nummeric") { for(n=0; n < imput.length; n++) { if( imput.charAt(n) < "0" || imput.charAt(n) > "9") { ist_zahl=false; break; }else{ ist_zahl=true; } } if(ist_zahl) { austausch(imgprint); }else{ if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); } } if(stingtyp == "tel") { var nur_das ="/+-() "; for(n=0; n < imput.length; n++) { if( imput.charAt(n) < "0" || imput.charAt(n) > "9") { if( nur_das.indexOf(imput.charAt(n)) < "0" ) { ist_zahl=false; break; } }else{ ist_zahl=true; } } if(ist_zahl) { austausch(imgprint); }else{ if( meldung == "no value" || meldung == "" ) { }else{ alert(meldung); } document.forms[formname]['id_'+id].focus(); nonAustausch(imgprint); } } } } var swfobject=function(){var D="undefined",r="object",S="Shockwave Flash",W="ShockwaveFlash.ShockwaveFlash",q="application/x-shockwave-flash",R="SWFObjectExprInst",x="onreadystatechange",O=window,j=document,t=navigator,T=false,U=[h],o=[],N=[],I=[],l,Q,E,B,J=false,a=false,n,G,m=true,M=function(){var aa=typeof j.getElementById!=D&&typeof j.getElementsByTagName!=D&&typeof j.createElement!=D,ah=t.userAgent.toLowerCase(),Y=t.platform.toLowerCase(),ae=Y?/win/.test(Y):/win/.test(ah),ac=Y?/mac/.test(Y):/mac/.test(ah),af=/webkit/.test(ah)?parseFloat(ah.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):false,X=!+"\v1",ag=[0,0,0],ab=null;if(typeof t.plugins!=D&&typeof t.plugins[S]==r){ab=t.plugins[S].description;if(ab&&!(typeof t.mimeTypes!=D&&t.mimeTypes[q]&&!t.mimeTypes[q].enabledPlugin)){T=true;X=false;ab=ab.replace(/^.*\s+(\S+\s+\S+$)/,"$1");ag[0]=parseInt(ab.replace(/^(.*)\..*$/,"$1"),10);ag[1]=parseInt(ab.replace(/^.*\.(.*)\s.*$/,"$1"),10);ag[2]=/[a-zA-Z]/.test(ab)?parseInt(ab.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0}}else{if(typeof O.ActiveXObject!=D){try{var ad=new ActiveXObject(W);if(ad){ab=ad.GetVariable("$version");if(ab){X=true;ab=ab.split(" ")[1].split(",");ag=[parseInt(ab[0],10),parseInt(ab[1],10),parseInt(ab[2],10)]}}}catch(Z){}}}return{w3:aa,pv:ag,wk:af,ie:X,win:ae,mac:ac}}(),k=function(){if(!M.w3){return}if((typeof j.readyState!=D&&j.readyState=="complete")||(typeof j.readyState==D&&(j.getElementsByTagName("body")[0]||j.body))){f()}if(!J){if(typeof j.addEventListener!=D){j.addEventListener("DOMContentLoaded",f,false)}if(M.ie&&M.win){j.attachEvent(x,function(){if(j.readyState=="complete"){j.detachEvent(x,arguments.callee);f()}});if(O==top){(function(){if(J){return}try{j.documentElement.doScroll("left")}catch(X){setTimeout(arguments.callee,0);return}f()})()}}if(M.wk){(function(){if(J){return}if(!/loaded|complete/.test(j.readyState)){setTimeout(arguments.callee,0);return}f()})()}s(f)}}();function f(){if(J){return}try{var Z=j.getElementsByTagName("body")[0].appendChild(C("span"));Z.parentNode.removeChild(Z)}catch(aa){return}J=true;var X=U.length;for(var Y=0;Y0){for(var af=0;af0){var ae=c(Y);if(ae){if(F(o[af].swfVersion)&&!(M.wk&&M.wk<312)){w(Y,true);if(ab){aa.success=true;aa.ref=z(Y);ab(aa)}}else{if(o[af].expressInstall&&A()){var ai={};ai.data=o[af].expressInstall;ai.width=ae.getAttribute("width")||"0";ai.height=ae.getAttribute("height")||"0";if(ae.getAttribute("class")){ai.styleclass=ae.getAttribute("class")}if(ae.getAttribute("align")){ai.align=ae.getAttribute("align")}var ah={};var X=ae.getElementsByTagName("param");var ac=X.length;for(var ad=0;ad'}}aa.outerHTML='"+af+"";N[N.length]=ai.id;X=c(ai.id)}else{var Z=C(r);Z.setAttribute("type",q);for(var ac in ai){if(ai[ac]!=Object.prototype[ac]){if(ac.toLowerCase()=="styleclass"){Z.setAttribute("class",ai[ac])}else{if(ac.toLowerCase()!="classid"){Z.setAttribute(ac,ai[ac])}}}}for(var ab in ag){if(ag[ab]!=Object.prototype[ab]&&ab.toLowerCase()!="movie"){e(Z,ab,ag[ab])}}aa.parentNode.replaceChild(Z,aa);X=Z}}return X}function e(Z,X,Y){var aa=C("param");aa.setAttribute("name",X);aa.setAttribute("value",Y);Z.appendChild(aa)}function y(Y){var X=c(Y);if(X&&X.nodeName=="OBJECT"){if(M.ie&&M.win){X.style.display="none";(function(){if(X.readyState==4){b(Y)}else{setTimeout(arguments.callee,10)}})()}else{X.parentNode.removeChild(X)}}}function b(Z){var Y=c(Z);if(Y){for(var X in Y){if(typeof Y[X]=="function"){Y[X]=null}}Y.parentNode.removeChild(Y)}}function c(Z){var X=null;try{X=j.getElementById(Z)}catch(Y){}return X}function C(X){return j.createElement(X)}function i(Z,X,Y){Z.attachEvent(X,Y);I[I.length]=[Z,X,Y]}function F(Z){var Y=M.pv,X=Z.split(".");X[0]=parseInt(X[0],10);X[1]=parseInt(X[1],10)||0;X[2]=parseInt(X[2],10)||0;return(Y[0]>X[0]||(Y[0]==X[0]&&Y[1]>X[1])||(Y[0]==X[0]&&Y[1]==X[1]&&Y[2]>=X[2]))?true:false}function v(ac,Y,ad,ab){if(M.ie&&M.mac){return}var aa=j.getElementsByTagName("head")[0];if(!aa){return}var X=(ad&&typeof ad=="string")?ad:"screen";if(ab){n=null;G=null}if(!n||G!=X){var Z=C("style");Z.setAttribute("type","text/css");Z.setAttribute("media",X);n=aa.appendChild(Z);if(M.ie&&M.win&&typeof j.styleSheets!=D&&j.styleSheets.length>0){n=j.styleSheets[j.styleSheets.length-1]}G=X}if(M.ie&&M.win){if(n&&typeof n.addRule==r){n.addRule(ac,Y)}}else{if(n&&typeof j.createTextNode!=D){n.appendChild(j.createTextNode(ac+" {"+Y+"}"))}}}function w(Z,X){if(!m){return}var Y=X?"visible":"hidden";if(J&&c(Z)){c(Z).style.visibility=Y}else{v("#"+Z,"visibility:"+Y)}}function L(Y){var Z=/[\\\"<>\.;]/;var X=Z.exec(Y)!=null;return X&&typeof encodeURIComponent!=D?encodeURIComponent(Y):Y}var d=function(){if(M.ie&&M.win){window.attachEvent("onunload",function(){var ac=I.length;for(var ab=0;ab