;(function($){$.ui={plugin:{add:function(module,option,set){var proto=$.ui[module].prototype;for(var i in set){proto.plugins[i]=proto.plugins[i]||[];proto.plugins[i].push([option,set[i]]);}},call:function(instance,name,args){var set=instance.plugins[name];if(!set){return;} for(var i=0;i').addclass(name).css({position:'absolute',top:'-5000px',left:'-5000px',display:'block'}).appendto('body');$.ui.csscache[name]=!!((!(/auto|default/).test(tmp.css('cursor'))||(/^[1-9]/).test(tmp.css('height'))||(/^[1-9]/).test(tmp.css('width'))||!(/none/).test(tmp.css('backgroundimage'))||!(/transparent|rgba\(0, 0, 0, 0\)/).test(tmp.css('backgroundcolor'))));try{$('body').get(0).removechild(tmp.get(0));}catch(e){} return $.ui.csscache[name];},disableselection:function(el){$(el).attr('unselectable','on').css('mozuserselect','none');},enableselection:function(el){$(el).attr('unselectable','off').css('mozuserselect','');},hasscroll:function(e,a){var scroll=/top/.test(a||"top")?'scrolltop':'scrollleft',has=false;if(e[scroll]>0)return true;e[scroll]=1;has=e[scroll]>0?true:false;e[scroll]=0;return has;}};var _remove=$.fn.remove;$.fn.remove=function(){$("*",this).add(this).triggerhandler("remove");return _remove.apply(this,arguments);};function getter(namespace,plugin,method){var methods=$[namespace][plugin].getter||[];methods=(typeof methods=="string"?methods.split(/,?\s+/):methods);return($.inarray(method,methods)!=-1);} $.widget=function(name,prototype){var namespace=name.split(".")[0];name=name.split(".")[1];$.fn[name]=function(options){var ismethodcall=(typeof options=='string'),args=array.prototype.slice.call(arguments,1);if(ismethodcall&&getter(namespace,name,options)){var instance=$.data(this[0],name);return(instance?instance[options].apply(instance,args):undefined);} return this.each(function(){var instance=$.data(this,name);if(ismethodcall&&instance&&$.isfunction(instance[options])){instance[options].apply(instance,args);}else if(!ismethodcall){$.data(this,name,new $[namespace][name](this,options));}});};$[namespace][name]=function(element,options){var self=this;this.widgetname=name;this.widgetbaseclass=namespace+'-'+name;this.options=$.extend({},$.widget.defaults,$[namespace][name].defaults,options);this.element=$(element).bind('setdata.'+name,function(e,key,value){return self.setdata(key,value);}).bind('getdata.'+name,function(e,key){return self.getdata(key);}).bind('remove',function(){return self.destroy();});this.init();};$[namespace][name].prototype=$.extend({},$.widget.prototype,prototype);};$.widget.prototype={init:function(){},destroy:function(){this.element.removedata(this.widgetname);},getdata:function(key){return this.options[key];},setdata:function(key,value){this.options[key]=value;if(key=='disabled'){this.element[value?'addclass':'removeclass'](this.widgetbaseclass+'-disabled');}},enable:function(){this.setdata('disabled',false);},disable:function(){this.setdata('disabled',true);}};$.widget.defaults={disabled:false};$.ui.mouse={mouseinit:function(){var self=this;this.element.bind('mousedown.'+this.widgetname,function(e){return self.mousedown(e);});if($.browser.msie){this._mouseunselectable=this.element.attr('unselectable');this.element.attr('unselectable','on');} this.started=false;},mousedestroy:function(){this.element.unbind('.'+this.widgetname);($.browser.msie&&this.element.attr('unselectable',this._mouseunselectable));},mousedown:function(e){(this._mousestarted&&this.mouseup(e));this._mousedownevent=e;var self=this,btnisleft=(e.which==1),eliscancel=(typeof this.options.cancel=="string"?$(e.target).parents().add(e.target).filter(this.options.cancel).length:false);if(!btnisleft||eliscancel||!this.mousecapture(e)){return true;} this._mousedelaymet=!this.options.delay;if(!this._mousedelaymet){this._mousedelaytimer=settimeout(function(){self._mousedelaymet=true;},this.options.delay);} if(this.mousedistancemet(e)&&this.mousedelaymet(e)){this._mousestarted=(this.mousestart(e)!==false);if(!this._mousestarted){e.preventdefault();return true;}} this._mousemovedelegate=function(e){return self.mousemove(e);};this._mouseupdelegate=function(e){return self.mouseup(e);};$(document).bind('mousemove.'+this.widgetname,this._mousemovedelegate).bind('mouseup.'+this.widgetname,this._mouseupdelegate);return false;},mousemove:function(e){if($.browser.msie&&!e.button){return this.mouseup(e);} if(this._mousestarted){this.mousedrag(e);return false;} if(this.mousedistancemet(e)&&this.mousedelaymet(e)){this._mousestarted=(this.mousestart(this._mousedownevent,e)!==false);(this._mousestarted?this.mousedrag(e):this.mouseup(e));} return!this._mousestarted;},mouseup:function(e){$(document).unbind('mousemove.'+this.widgetname,this._mousemovedelegate).unbind('mouseup.'+this.widgetname,this._mouseupdelegate);if(this._mousestarted){this._mousestarted=false;this.mousestop(e);} return false;},mousedistancemet:function(e){return(math.max(math.abs(this._mousedownevent.pagex-e.pagex),math.abs(this._mousedownevent.pagey-e.pagey))>=this.options.distance);},mousedelaymet:function(e){return this._mousedelaymet;},mousestart:function(e){},mousedrag:function(e){},mousestop:function(e){},mousecapture:function(e){return true;}};$.ui.mouse.defaults={cancel:null,distance:1,delay:0};})(jquery);(function($){$.widget("ui.draggable",$.extend({},$.ui.mouse,{init:function(){var o=this.options;if(o.helper=='original'&&!(/(relative|absolute|fixed)/).test(this.element.css('position'))) this.element.css('position','relative');this.element.addclass('ui-draggable');(o.disabled&&this.element.addclass('ui-draggable-disabled'));this.mouseinit();},mousestart:function(e){var o=this.options;if(this.helper||o.disabled||$(e.target).is('.ui-resizable-handle'))return false;var handle=!this.options.handle||!$(this.options.handle,this.element).length?true:false;$(this.options.handle,this.element).find("*").andself().each(function(){if(this==e.target)handle=true;});if(!handle)return false;if($.ui.ddmanager)$.ui.ddmanager.current=this;this.helper=$.isfunction(o.helper)?$(o.helper.apply(this.element[0],[e])):(o.helper=='clone'?this.element.clone():this.element);if(!this.helper.parents('body').length)this.helper.appendto((o.appendto=='parent'?this.element[0].parentnode:o.appendto));if(this.helper[0]!=this.element[0]&&!(/(fixed|absolute)/).test(this.helper.css("position")))this.helper.css("position","absolute");this.margins={left:(parseint(this.element.css("marginleft"),10)||0),top:(parseint(this.element.css("margintop"),10)||0)};this.cssposition=this.helper.css("position");this.offset=this.element.offset();this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left};this.offset.click={left:e.pagex-this.offset.left,top:e.pagey-this.offset.top};this.offsetparent=this.helper.offsetparent();var po=this.offsetparent.offset();if(this.offsetparent[0]==document.body&&$.browser.mozilla)po={top:0,left:0};this.offset.parent={top:po.top+(parseint(this.offsetparent.css("bordertopwidth"),10)||0),left:po.left+(parseint(this.offsetparent.css("borderleftwidth"),10)||0)};var p=this.element.position();this.offset.relative=this.cssposition=="relative"?{top:p.top-(parseint(this.helper.css("top"),10)||0)+this.offsetparent[0].scrolltop,left:p.left-(parseint(this.helper.css("left"),10)||0)+this.offsetparent[0].scrollleft}:{top:0,left:0};this.originalposition=this.generateposition(e);this.helperproportions={width:this.helper.outerwidth(),height:this.helper.outerheight()};if(o.cursorat){if(o.cursorat.left!=undefined)this.offset.click.left=o.cursorat.left+this.margins.left;if(o.cursorat.right!=undefined)this.offset.click.left=this.helperproportions.width-o.cursorat.right+this.margins.left;if(o.cursorat.top!=undefined)this.offset.click.top=o.cursorat.top+this.margins.top;if(o.cursorat.bottom!=undefined)this.offset.click.top=this.helperproportions.height-o.cursorat.bottom+this.margins.top;} if(o.containment){if(o.containment=='parent')o.containment=this.helper[0].parentnode;if(o.containment=='document'||o.containment=='window')this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,$(o.containment=='document'?document:window).width()-this.offset.relative.left-this.offset.parent.left-this.helperproportions.width-this.margins.left-(parseint(this.element.css("marginright"),10)||0),($(o.containment=='document'?document:window).height()||document.body.parentnode.scrollheight)-this.offset.relative.top-this.offset.parent.top-this.helperproportions.height-this.margins.top-(parseint(this.element.css("marginbottom"),10)||0)];if(!(/^(document|window|parent)$/).test(o.containment)){var ce=$(o.containment)[0];var co=$(o.containment).offset();this.containment=[co.left+(parseint($(ce).css("borderleftwidth"),10)||0)-this.offset.relative.left-this.offset.parent.left,co.top+(parseint($(ce).css("bordertopwidth"),10)||0)-this.offset.relative.top-this.offset.parent.top,co.left+math.max(ce.scrollwidth,ce.offsetwidth)-(parseint($(ce).css("borderleftwidth"),10)||0)-this.offset.relative.left-this.offset.parent.left-this.helperproportions.width-this.margins.left-(parseint(this.element.css("marginright"),10)||0),co.top+math.max(ce.scrollheight,ce.offsetheight)-(parseint($(ce).css("bordertopwidth"),10)||0)-this.offset.relative.top-this.offset.parent.top-this.helperproportions.height-this.margins.top-(parseint(this.element.css("marginbottom"),10)||0)];}} this.propagate("start",e);this.helperproportions={width:this.helper.outerwidth(),height:this.helper.outerheight()};if($.ui.ddmanager&&!o.dropbehaviour)$.ui.ddmanager.prepareoffsets(this,e);this.helper.addclass("ui-draggable-dragging");this.mousedrag(e);return true;},convertpositionto:function(d,pos){if(!pos)pos=this.position;var mod=d=="absolute"?1:-1;return{top:(pos.top +this.offset.relative.top*mod +this.offset.parent.top*mod -(this.cssposition=="fixed"||(this.cssposition=="absolute"&&this.offsetparent[0]==document.body)?0:this.offsetparent[0].scrolltop)*mod +(this.cssposition=="fixed"?$(document).scrolltop():0)*mod +this.margins.top*mod),left:(pos.left +this.offset.relative.left*mod +this.offset.parent.left*mod -(this.cssposition=="fixed"||(this.cssposition=="absolute"&&this.offsetparent[0]==document.body)?0:this.offsetparent[0].scrollleft)*mod +(this.cssposition=="fixed"?$(document).scrollleft():0)*mod +this.margins.left*mod)};},generateposition:function(e){var o=this.options;var position={top:(e.pagey -this.offset.click.top -this.offset.relative.top -this.offset.parent.top +(this.cssposition=="fixed"||(this.cssposition=="absolute"&&this.offsetparent[0]==document.body)?0:this.offsetparent[0].scrolltop) -(this.cssposition=="fixed"?$(document).scrolltop():0)),left:(e.pagex -this.offset.click.left -this.offset.relative.left -this.offset.parent.left +(this.cssposition=="fixed"||(this.cssposition=="absolute"&&this.offsetparent[0]==document.body)?0:this.offsetparent[0].scrollleft) -(this.cssposition=="fixed"?$(document).scrollleft():0))};if(!this.originalposition)return position;if(this.containment){if(position.leftthis.containment[2])position.left=this.containment[2];if(position.top>this.containment[3])position.top=this.containment[3];} if(o.grid){var top=this.originalposition.top+math.round((position.top-this.originalposition.top)/o.grid[1])*o.grid[1];position.top=this.containment?(!(topthis.containment[3])?top:(!(topthis.containment[2])?left:(!(left').css({width:this.offsetwidth+"px",height:this.offsetheight+"px",position:"absolute",opacity:"0.001",zindex:1000}).css($(this).offset()).appendto("body");});},stop:function(e,ui){$("div.dragdropiframefix").each(function(){this.parentnode.removechild(this);});}});$.ui.plugin.add("draggable","scroll",{start:function(e,ui){var o=ui.options;var i=$(this).data("draggable");o.scrollsensitivity=o.scrollsensitivity||20;o.scrollspeed=o.scrollspeed||20;i.overflowy=function(el){do{if(/auto|scroll/.test(el.css('overflow'))||(/auto|scroll/).test(el.css('overflow-y')))return el;el=el.parent();}while(el[0].parentnode);return $(document);}(this);i.overflowx=function(el){do{if(/auto|scroll/.test(el.css('overflow'))||(/auto|scroll/).test(el.css('overflow-x')))return el;el=el.parent();}while(el[0].parentnode);return $(document);}(this);if(i.overflowy[0]!=document&&i.overflowy[0].tagname!='html')i.overflowyoffset=i.overflowy.offset();if(i.overflowx[0]!=document&&i.overflowx[0].tagname!='html')i.overflowxoffset=i.overflowx.offset();},drag:function(e,ui){var o=ui.options;var i=$(this).data("draggable");if(i.overflowy[0]!=document&&i.overflowy[0].tagname!='html'){if((i.overflowyoffset.top+i.overflowy[0].offsetheight)-e.pagey=0;i--){var l=inst.snapelements[i].left,r=l+inst.snapelements[i].width,t=inst.snapelements[i].top,b=t+inst.snapelements[i].height;if(!((l-d=t&&y1<=b)||(y2>=t&&y2<=b)||(y1b))&&((x1>=l&&x1<=r)||(x2>=l&&x2<=r)||(x1r));break;default:return false;break;}};$.ui.ddmanager={current:null,droppables:[],prepareoffsets:function(t,e){var m=$.ui.ddmanager.droppables;var type=e?e.type:null;for(var i=0;i').css({position:el.css('position'),width:el.outerwidth(),height:el.outerheight(),top:el.css('top'),left:el.css('left')}));var oel=this.element;this.element=this.element.parent();this.element.data('resizable',this);this.element.css({marginleft:oel.css("marginleft"),margintop:oel.css("margintop"),marginright:oel.css("marginright"),marginbottom:oel.css("marginbottom")});oel.css({marginleft:0,margintop:0,marginright:0,marginbottom:0});if($.browser.safari&&o.preventdefault)oel.css('resize','none');o.proportionallyresize=oel.css({position:'static',zoom:1,display:'block'});this.element.css({margin:oel.css('margin')});this._proportionallyresize();} if(!o.handles)o.handles=!$('.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(o.handles.constructor==string){o.zindex=o.zindex||1000;if(o.handles=='all')o.handles='n,e,s,w,se,sw,ne,nw';var n=o.handles.split(",");o.handles={};var insertionsdefault={handle:'position: absolute; display: none; overflow:hidden;',n:'top: 0pt; width:100%;',e:'right: 0pt; height:100%;',s:'bottom: 0pt; width:100%;',w:'left: 0pt; height:100%;',se:'bottom: 0pt; right: 0px;',sw:'bottom: 0pt; left: 0px;',ne:'top: 0pt; right: 0px;',nw:'top: 0pt; left: 0px;'};for(var i=0;i'].join('')).css(applyzindex);o.handles[handle]='.ui-resizable-'+handle;this.element.append(axis.css(loaddefault?alldeftheme:{}).css(o.knobhandles?allknobtheme:{}).addclass(o.knobhandles?'ui-resizable-knob-handle':'').addclass(o.knobhandles));} if(o.knobhandles)this.element.addclass('ui-resizable-knob').css(!$.ui.css('ui-resizable-knob')?{}:{});} this._renderaxis=function(target){target=target||this.element;for(var i in o.handles){if(o.handles[i].constructor==string) o.handles[i]=$(o.handles[i],this.element).show();if(o.transparent) o.handles[i].css({opacity:0});if(this.element.is('.ui-wrapper')&&o._nodename.match(/textarea|input|select|button/i)){var axis=$(o.handles[i],this.element),padwrapper=0;padwrapper=/sw|ne|nw|se|n|s/.test(i)?axis.outerheight():axis.outerwidth();var padpos=['padding',/ne|nw|n/.test(i)?'top':/se|sw|s/.test(i)?'bottom':/^e$/.test(i)?'right':'left'].join("");if(!o.transparent) target.css(padpos,padwrapper);this._proportionallyresize();} if(!$(o.handles[i]).length)continue;}};this._renderaxis(this.element);o._handles=$('.ui-resizable-handle',self.element);if(o.disableselection) o._handles.each(function(i,e){$.ui.disableselection(e);});o._handles.mouseover(function(){if(!o.resizing){if(this.classname) var axis=this.classname.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i);self.axis=o.axis=axis&&axis[1]?axis[1]:'se';}});if(o.autohide){o._handles.hide();$(self.element).addclass("ui-resizable-autohide").hover(function(){$(this).removeclass("ui-resizable-autohide");o._handles.show();},function(){if(!o.resizing){$(this).addclass("ui-resizable-autohide");o._handles.hide();}});} this.mouseinit();},plugins:{},ui:function(){return{originalelement:this.originalelement,element:this.element,helper:this.helper,position:this.position,size:this.size,options:this.options,originalsize:this.originalsize,originalposition:this.originalposition};},propagate:function(n,e){$.ui.plugin.call(this,n,[e,this.ui()]);if(n!="resize")this.element.triggerhandler(["resize",n].join(""),[e,this.ui()],this.options[n]);},destroy:function(){var el=this.element,wrapped=el.children(".ui-resizable").get(0);this.mousedestroy();var _destroy=function(exp){$(exp).removeclass("ui-resizable ui-resizable-disabled").removedata("resizable").unbind(".resizable").find('.ui-resizable-handle').remove();};_destroy(el);if(el.is('.ui-wrapper')&&wrapped){el.parent().append($(wrapped).css({position:el.css('position'),width:el.outerwidth(),height:el.outerheight(),top:el.css('top'),left:el.css('left')})).end().remove();_destroy(wrapped);}},mousestart:function(e){if(this.options.disabled)return false;var handle=false;for(var i in this.options.handles){if($(this.options.handles[i])[0]==e.target)handle=true;} if(!handle)return false;var o=this.options,inipos=this.element.position(),el=this.element,num=function(v){return parseint(v,10)||0;},ie6=$.browser.msie&&$.browser.version<7;o.resizing=true;o.documentscroll={top:$(document).scrolltop(),left:$(document).scrollleft()};if(el.is('.ui-draggable')||(/absolute/).test(el.css('position'))){var soffset=$.browser.msie&&!o.containment&&(/absolute/).test(el.css('position'))&&!(/relative/).test(el.parent().css('position'));var dscrollt=soffset?o.documentscroll.top:0,dscrolll=soffset?o.documentscroll.left:0;el.css({position:'absolute',top:(inipos.top+dscrollt),left:(inipos.left+dscrolll)});} if($.browser.opera&&/relative/.test(el.css('position'))) el.css({position:'relative',top:'auto',left:'auto'});this._renderproxy();var curleft=num(this.helper.css('left')),curtop=num(this.helper.css('top'));if(o.containment){curleft+=$(o.containment).scrollleft()||0;curtop+=$(o.containment).scrolltop()||0;} this.offset=this.helper.offset();this.position={left:curleft,top:curtop};this.size=o.helper||ie6?{width:el.outerwidth(),height:el.outerheight()}:{width:el.width(),height:el.height()};this.originalsize=o.helper||ie6?{width:el.outerwidth(),height:el.outerheight()}:{width:el.width(),height:el.height()};this.originalposition={left:curleft,top:curtop};this.sizediff={width:el.outerwidth()-el.width(),height:el.outerheight()-el.height()};this.originalmouseposition={left:e.pagex,top:e.pagey};o.aspectratio=(typeof o.aspectratio=='number')?o.aspectratio:((this.originalsize.height/this.originalsize.width)||1);if(o.preservecursor) $('body').css('cursor',this.axis+'-resize');this.propagate("start",e);return true;},mousedrag:function(e){var el=this.helper,o=this.options,props={},self=this,smp=this.originalmouseposition,a=this.axis;var dx=(e.pagex-smp.left)||0,dy=(e.pagey-smp.top)||0;var trigger=this._change[a];if(!trigger)return false;var data=trigger.apply(this,[e,dx,dy]),ie6=$.browser.msie&&$.browser.version<7,csdif=this.sizediff;if(o._aspectratio||e.shiftkey) data=this._updateratio(data,e);data=this._respectsize(data,e);this.propagate("resize",e);el.css({top:this.position.top+"px",left:this.position.left+"px",width:this.size.width+"px",height:this.size.height+"px"});if(!o.helper&&o.proportionallyresize) this._proportionallyresize();this._updatecache(data);this.element.triggerhandler("resize",[e,this.ui()],this.options["resize"]);return false;},mousestop:function(e){this.options.resizing=false;var o=this.options,num=function(v){return parseint(v,10)||0;},self=this;if(o.helper){var pr=o.proportionallyresize,ista=pr&&(/textarea/i).test(pr.get(0).nodename),soffseth=ista&&$.ui.hasscroll(pr.get(0),'left')?0:self.sizediff.height,soffsetw=ista?0:self.sizediff.width;var s={width:(self.size.width-soffsetw),height:(self.size.height-soffseth)},left=(parseint(self.element.css('left'),10)+(self.position.left-self.originalposition.left))||null,top=(parseint(self.element.css('top'),10)+(self.position.top-self.originalposition.top))||null;if(!o.animate) this.element.css($.extend(s,{top:top,left:left}));if(o.helper&&!o.animate)this._proportionallyresize();} if(o.preservecursor) $('body').css('cursor','auto');this.propagate("stop",e);if(o.helper)this.helper.remove();return false;},_updatecache:function(data){var o=this.options;this.offset=this.helper.offset();if(data.left)this.position.left=data.left;if(data.top)this.position.top=data.top;if(data.height)this.size.height=data.height;if(data.width)this.size.width=data.width;},_updateratio:function(data,e){var o=this.options,cpos=this.position,csize=this.size,a=this.axis;if(data.height)data.width=(csize.height/o.aspectratio);else if(data.width)data.height=(csize.width*o.aspectratio);if(a=='sw'){data.left=cpos.left+(csize.width-data.width);data.top=null;} if(a=='nw'){data.top=cpos.top+(csize.height-data.height);data.left=cpos.left+(csize.width-data.width);} return data;},_respectsize:function(data,e){var el=this.helper,o=this.options,pratio=o._aspectratio||e.shiftkey,a=this.axis,ismaxw=data.width&&o.maxwidth&&o.maxwidthdata.width,isminh=data.height&&o.minheight&&o.minheight>data.height;if(isminw)data.width=o.minwidth;if(isminh)data.height=o.minheight;if(ismaxw)data.width=o.maxwidth;if(ismaxh)data.height=o.maxheight;var dw=this.originalposition.left+this.originalsize.width,dh=this.position.top+this.size.height;var cw=/sw|nw|w/.test(a),ch=/nw|ne|n/.test(a);if(isminw&&cw)data.left=dw-o.minwidth;if(ismaxw&&cw)data.left=dw-o.maxwidth;if(isminh&&ch)data.top=dh-o.minheight;if(ismaxh&&ch)data.top=dh-o.maxheight;var isnotwh=!data.width&&!data.height;if(isnotwh&&!data.left&&data.top)data.top=null;else if(isnotwh&&!data.top&&data.left)data.left=null;return data;},_proportionallyresize:function(){var o=this.options;if(!o.proportionallyresize)return;var prel=o.proportionallyresize,el=this.helper||this.element;if(!o.borderdif){var b=[prel.css('bordertopwidth'),prel.css('borderrightwidth'),prel.css('borderbottomwidth'),prel.css('borderleftwidth')],p=[prel.css('paddingtop'),prel.css('paddingright'),prel.css('paddingbottom'),prel.css('paddingleft')];o.borderdif=$.map(b,function(v,i){var border=parseint(v,10)||0,padding=parseint(p[i],10)||0;return border+padding;});} prel.css({height:(el.height()-o.borderdif[0]-o.borderdif[2])+"px",width:(el.width()-o.borderdif[1]-o.borderdif[3])+"px"});},_renderproxy:function(){var el=this.element,o=this.options;this.elementoffset=el.offset();if(o.helper){this.helper=this.helper||$('
');var ie6=$.browser.msie&&$.browser.version<7,ie6offset=(ie6?1:0),pxyoffset=(ie6?2:-1);this.helper.addclass(o.helper).css({width:el.outerwidth()+pxyoffset,height:el.outerheight()+pxyoffset,position:'absolute',left:this.elementoffset.left-ie6offset+'px',top:this.elementoffset.top-ie6offset+'px',zindex:++o.zindex});this.helper.appendto("body");if(o.disableselection) $.ui.disableselection(this.helper.get(0));}else{this.helper=el;}},_change:{e:function(e,dx,dy){return{width:this.originalsize.width+dx};},w:function(e,dx,dy){var o=this.options,cs=this.originalsize,sp=this.originalposition;return{left:sp.left+dx,width:cs.width-dx};},n:function(e,dx,dy){var o=this.options,cs=this.originalsize,sp=this.originalposition;return{top:sp.top+dy,height:cs.height-dy};},s:function(e,dx,dy){return{height:this.originalsize.height+dy};},se:function(e,dx,dy){return $.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,dx,dy]));},sw:function(e,dx,dy){return $.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,dx,dy]));},ne:function(e,dx,dy){return $.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,dx,dy]));},nw:function(e,dx,dy){return $.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,dx,dy]));}}}));$.extend($.ui.resizable,{defaults:{cancel:":input",distance:1,delay:0,preventdefault:true,transparent:false,minwidth:10,minheight:10,aspectratio:false,disableselection:true,preservecursor:true,autohide:false,knobhandles:false}});$.ui.plugin.add("resizable","containment",{start:function(e,ui){var o=ui.options,self=$(this).data("resizable"),el=self.element;var oc=o.containment,ce=(oc instanceof $)?oc.get(0):(/parent/.test(oc))?el.parent().get(0):oc;if(!ce)return;self.containerelement=$(ce);if(/document/.test(oc)||oc==document){self.containeroffset={left:0,top:0};self.containerposition={left:0,top:0};self.parentdata={element:$(document),left:0,top:0,width:$(document).width(),height:$(document).height()||document.body.parentnode.scrollheight};} else{self.containeroffset=$(ce).offset();self.containerposition=$(ce).position();self.containersize={height:$(ce).innerheight(),width:$(ce).innerwidth()};var co=self.containeroffset,ch=self.containersize.height,cw=self.containersize.width,width=($.ui.hasscroll(ce,"left")?ce.scrollwidth:cw),height=($.ui.hasscroll(ce)?ce.scrollheight:ch);self.parentdata={element:ce,left:co.left,top:co.top,width:width,height:height};}},resize:function(e,ui){var o=ui.options,self=$(this).data("resizable"),ps=self.containersize,co=self.containeroffset,cs=self.size,cp=self.position,pratio=o._aspectratio||e.shiftkey,cop={top:0,left:0},ce=self.containerelement;if(ce[0]!=document&&/static/.test(ce.css('position'))) cop=self.containerposition;if(cp.left<(o.helper?co.left:cop.left)){self.size.width=self.size.width+(o.helper?(self.position.left-co.left):(self.position.left-cop.left));if(pratio)self.size.height=self.size.width*o.aspectratio;self.position.left=o.helper?co.left:cop.left;} if(cp.top<(o.helper?co.top:0)){self.size.height=self.size.height+(o.helper?(self.position.top-co.top):self.position.top);if(pratio)self.size.width=self.size.height/o.aspectratio;self.position.top=o.helper?co.top:0;} var woset=(o.helper?self.offset.left-co.left:(self.position.left-cop.left))+self.sizediff.width,hoset=(o.helper?self.offset.top-co.top:self.position.top)+self.sizediff.height;if(woset+self.size.width>=self.parentdata.width){self.size.width=self.parentdata.width-woset;if(pratio)self.size.height=self.size.width*o.aspectratio;} if(hoset+self.size.height>=self.parentdata.height){self.size.height=self.parentdata.height-hoset;if(pratio)self.size.width=self.size.height/o.aspectratio;}},stop:function(e,ui){var o=ui.options,self=$(this).data("resizable"),cp=self.position,co=self.containeroffset,cop=self.containerposition,ce=self.containerelement;var helper=$(self.helper),ho=helper.offset(),w=helper.innerwidth(),h=helper.innerheight();if(o.helper&&!o.animate&&/relative/.test(ce.css('position'))) $(this).css({left:(ho.left-co.left),top:(ho.top-co.top),width:w,height:h});if(o.helper&&!o.animate&&/static/.test(ce.css('position'))) $(this).css({left:cop.left+(ho.left-co.left),top:cop.top+(ho.top-co.top),width:w,height:h});}});$.ui.plugin.add("resizable","grid",{resize:function(e,ui){var o=ui.options,self=$(this).data("resizable"),cs=self.size,os=self.originalsize,op=self.originalposition,a=self.axis,ratio=o._aspectratio||e.shiftkey;o.grid=typeof o.grid=="number"?[o.grid,o.grid]:o.grid;var ox=math.round((cs.width-os.width)/(o.grid[0]||1))*(o.grid[0]||1),oy=math.round((cs.height-os.height)/(o.grid[1]||1))*(o.grid[1]||1);if(/^(se|s|e)$/.test(a)){self.size.width=os.width+ox;self.size.height=os.height+oy;} else if(/^(ne)$/.test(a)){self.size.width=os.width+ox;self.size.height=os.height+oy;self.position.top=op.top-oy;} else if(/^(sw)$/.test(a)){self.size.width=os.width+ox;self.size.height=os.height+oy;self.position.left=op.left-ox;} else{self.size.width=os.width+ox;self.size.height=os.height+oy;self.position.top=op.top-oy;self.position.left=op.left-ox;}}});$.ui.plugin.add("resizable","animate",{stop:function(e,ui){var o=ui.options,self=$(this).data("resizable");var pr=o.proportionallyresize,ista=pr&&(/textarea/i).test(pr.get(0).nodename),soffseth=ista&&$.ui.hasscroll(pr.get(0),'left')?0:self.sizediff.height,soffsetw=ista?0:self.sizediff.width;var style={width:(self.size.width-soffsetw),height:(self.size.height-soffseth)},left=(parseint(self.element.css('left'),10)+(self.position.left-self.originalposition.left))||null,top=(parseint(self.element.css('top'),10)+(self.position.top-self.originalposition.top))||null;self.element.animate($.extend(style,top&&left?{top:top,left:left}:{}),{duration:o.animateduration||"slow",easing:o.animateeasing||"swing",step:function(){var data={width:parseint(self.element.css('width'),10),height:parseint(self.element.css('height'),10),top:parseint(self.element.css('top'),10),left:parseint(self.element.css('left'),10)};if(pr)pr.css({width:data.width,height:data.height});self._updatecache(data);self.propagate("animate",e);}});}});$.ui.plugin.add("resizable","ghost",{start:function(e,ui){var o=ui.options,self=$(this).data("resizable"),pr=o.proportionallyresize,cs=self.size;if(!pr)self.ghost=self.element.clone();else self.ghost=pr.clone();self.ghost.css({opacity:.25,display:'block',position:'relative',height:cs.height,width:cs.width,margin:0,left:0,top:0}).addclass('ui-resizable-ghost').addclass(typeof o.ghost=='string'?o.ghost:'');self.ghost.appendto(self.helper);},resize:function(e,ui){var o=ui.options,self=$(this).data("resizable"),pr=o.proportionallyresize;if(self.ghost)self.ghost.css({position:'relative',height:self.size.height,width:self.size.width});},stop:function(e,ui){var o=ui.options,self=$(this).data("resizable"),pr=o.proportionallyresize;if(self.ghost&&self.helper)self.helper.get(0).removechild(self.ghost.get(0));}});$.ui.plugin.add("resizable","alsoresize",{start:function(e,ui){var o=ui.options,self=$(this).data("resizable"),_store=function(exp){$(exp).each(function(){$(this).data("resizable-alsoresize",{width:parseint($(this).width(),10),height:parseint($(this).height(),10),left:parseint($(this).css('left'),10),top:parseint($(this).css('top'),10)});});};if(typeof(o.alsoresize)=='object'){if(o.alsoresize.length){o.alsoresize=o.alsoresize[0];_store(o.alsoresize);} else{$.each(o.alsoresize,function(exp,c){_store(exp);});}}else{_store(o.alsoresize);}},resize:function(e,ui){var o=ui.options,self=$(this).data("resizable"),os=self.originalsize,op=self.originalposition;var delta={height:(self.size.height-os.height)||0,width:(self.size.width-os.width)||0,top:(self.position.top-op.top)||0,left:(self.position.left-op.left)||0},_alsoresize=function(exp,c){$(exp).each(function(){var start=$(this).data("resizable-alsoresize"),style={},css=c&&c.length?c:['width','height','top','left'];$.each(css||['width','height','top','left'],function(i,prop){var sum=(start[prop]||0)+(delta[prop]||0);if(sum&&sum>=0) style[prop]=sum||null;});$(this).css(style);});};if(typeof(o.alsoresize)=='object'){$.each(o.alsoresize,function(exp,c){_alsoresize(exp,c);});}else{_alsoresize(o.alsoresize);}},stop:function(e,ui){$(this).removedata("resizable-alsoresize-start");}});})(jquery);(function($){$.widget("ui.selectable",$.extend({},$.ui.mouse,{init:function(){var self=this;this.element.addclass("ui-selectable");this.dragged=false;var selectees;this.refresh=function(){selectees=$(self.options.filter,self.element[0]);selectees.each(function(){var $this=$(this);var pos=$this.offset();$.data(this,"selectable-item",{element:this,$element:$this,left:pos.left,top:pos.top,right:pos.left+$this.width(),bottom:pos.top+$this.height(),startselected:false,selected:$this.hasclass('ui-selected'),selecting:$this.hasclass('ui-selecting'),unselecting:$this.hasclass('ui-unselecting')});});};this.refresh();this.selectees=selectees.addclass("ui-selectee");this.mouseinit();this.helper=$(document.createelement('div')).css({border:'1px dotted black'});},toggle:function(){if(this.options.disabled){this.enable();}else{this.disable();}},destroy:function(){this.element.removeclass("ui-selectable ui-selectable-disabled").removedata("selectable").unbind(".selectable");this.mousedestroy();},mousestart:function(e){var self=this;this.opos=[e.pagex,e.pagey];if(this.options.disabled) return;var options=this.options;this.selectees=$(options.filter,this.element[0]);this.element.triggerhandler("selectablestart",[e,{"selectable":this.element[0],"options":options}],options.start);$('body').append(this.helper);this.helper.css({"z-index":100,"position":"absolute","left":e.clientx,"top":e.clienty,"width":0,"height":0});if(options.autorefresh){this.refresh();} this.selectees.filter('.ui-selected').each(function(){var selectee=$.data(this,"selectable-item");selectee.startselected=true;if(!e.ctrlkey){selectee.$element.removeclass('ui-selected');selectee.selected=false;selectee.$element.addclass('ui-unselecting');selectee.unselecting=true;self.element.triggerhandler("selectableunselecting",[e,{selectable:self.element[0],unselecting:selectee.element,options:options}],options.unselecting);}});var isselectee=false;$(e.target).parents().andself().each(function(){if($.data(this,"selectable-item"))isselectee=true;});return this.options.keyboard?!isselectee:true;},mousedrag:function(e){var self=this;this.dragged=true;if(this.options.disabled) return;var options=this.options;var x1=this.opos[0],y1=this.opos[1],x2=e.pagex,y2=e.pagey;if(x1>x2){var tmp=x2;x2=x1;x1=tmp;} if(y1>y2){var tmp=y2;y2=y1;y1=tmp;} this.helper.css({left:x1,top:y1,width:x2-x1,height:y2-y1});this.selectees.each(function(){var selectee=$.data(this,"selectable-item");if(!selectee||selectee.element==self.element[0]) return;var hit=false;if(options.tolerance=='touch'){hit=(!(selectee.left>x2||selectee.righty2||selectee.bottomx1&&selectee.righty1&&selectee.bottomitem[this.floating?'width':'height'])){return(y1+this.offset.click.top>t&&y1+this.offset.click.topl&&x1+this.offset.click.leftitem[this.floating?'width':'height'])){if(!(y1+this.offset.click.top>t&&y1+this.offset.click.topl&&x1+this.offset.click.leftl&&x1+this.offset.click.leftl+item.width/2&&x1+this.offset.click.leftt&&y1+this.offset.click.topt+item.height/2&&y1+this.offset.click.topl&&x1r)return 1;}else{if(y2>t&&y1b)return 2;}} return false;},refresh:function(){this.refreshitems();this.refreshpositions();},refreshitems:function(){this.items=[];this.containers=[this];var items=this.items;var self=this;var queries=[[$.isfunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentitem}):$(this.options.items,this.element),this]];if(this.options.connectwith){for(var i=this.options.connectwith.length-1;i>=0;i--){var cur=$(this.options.connectwith[i]);for(var j=cur.length-1;j>=0;j--){var inst=$.data(cur[j],'sortable');if(inst&&!inst.options.disabled){queries.push([$.isfunction(inst.options.items)?inst.options.items.call(inst.element):$(inst.options.items,inst.element),inst]);this.containers.push(inst);}};};} for(var i=queries.length-1;i>=0;i--){queries[i][0].each(function(){$.data(this,'sortable-item',queries[i][1]);items.push({item:$(this),instance:queries[i][1],width:0,height:0,left:0,top:0});});};},refreshpositions:function(fast){if(this.offsetparent){var po=this.offsetparent.offset();this.offset.parent={top:po.top+this.offsetparentborders.top,left:po.left+this.offsetparentborders.left};} for(var i=this.items.length-1;i>=0;i--){if(this.items[i].instance!=this.currentcontainer&&this.currentcontainer&&this.items[i].item[0]!=this.currentitem[0]) continue;var t=this.options.toleranceelement?$(this.options.toleranceelement,this.items[i].item):this.items[i].item;if(!fast){this.items[i].width=t[0].offsetwidth;this.items[i].height=t[0].offsetheight;} var p=t.offset();this.items[i].left=p.left;this.items[i].top=p.top;};if(this.options.custom&&this.options.custom.refreshcontainers){this.options.custom.refreshcontainers.call(this);}else{for(var i=this.containers.length-1;i>=0;i--){var p=this.containers[i].element.offset();this.containers[i].containercache.left=p.left;this.containers[i].containercache.top=p.top;this.containers[i].containercache.width=this.containers[i].element.outerwidth();this.containers[i].containercache.height=this.containers[i].element.outerheight();};}},destroy:function(){this.element.removeclass("ui-sortable ui-sortable-disabled").removedata("sortable").unbind(".sortable");this.mousedestroy();for(var i=this.items.length-1;i>=0;i--) this.items[i].item.removedata("sortable-item");},createplaceholder:function(that){var self=that||this,o=self.options;if(o.placeholder.constructor==string){var classname=o.placeholder;o.placeholder={element:function(){return $('
').addclass(classname)[0];},update:function(i,p){p.css(i.offset()).css({width:i.outerwidth(),height:i.outerheight()});}};} self.placeholder=$(o.placeholder.element.call(self.element,self.currentitem)).appendto('body').css({position:'absolute'});o.placeholder.update.call(self.element,self.currentitem,self.placeholder);},contactcontainers:function(e){for(var i=this.containers.length-1;i>=0;i--){if(this.intersectswith(this.containers[i].containercache)){if(!this.containers[i].containercache.over){if(this.currentcontainer!=this.containers[i]){var dist=10000;var itemwithleastdistance=null;var base=this.positionabs[this.containers[i].floating?'left':'top'];for(var j=this.items.length-1;j>=0;j--){if(!contains(this.containers[i].element[0],this.items[j].item[0]))continue;var cur=this.items[j][this.containers[i].floating?'left':'top'];if(math.abs(cur-base)=0;i--){this.containers[i].propagate("activate",e,this);}} if($.ui.ddmanager)$.ui.ddmanager.current=this;if($.ui.ddmanager&&!o.dropbehaviour)$.ui.ddmanager.prepareoffsets(this,e);this.dragging=true;this.mousedrag(e);return true;},convertpositionto:function(d,pos){if(!pos)pos=this.position;var mod=d=="absolute"?1:-1;return{top:(pos.top +this.offset.parent.top*mod -(this.offsetparent[0]==document.body?0:this.offsetparent[0].scrolltop)*mod +this.margins.top*mod),left:(pos.left +this.offset.parent.left*mod -(this.offsetparent[0]==document.body?0:this.offsetparent[0].scrollleft)*mod +this.margins.left*mod)};},generateposition:function(e){var o=this.options;var position={top:(e.pagey -this.offset.click.top -this.offset.parent.top +(this.offsetparent[0]==document.body?0:this.offsetparent[0].scrolltop)),left:(e.pagex -this.offset.click.left -this.offset.parent.left +(this.offsetparent[0]==document.body?0:this.offsetparent[0].scrollleft))};if(!this.originalposition)return position;if(this.containment){if(position.leftthis.containment[2])position.left=this.containment[2];if(position.top>this.containment[3])position.top=this.containment[3];} if(o.grid){var top=this.originalposition.top+math.round((position.top-this.originalposition.top)/o.grid[1])*o.grid[1];position.top=this.containment?(!(topthis.containment[3])?top:(!(topthis.containment[2])?left:(!(left=0;i--){var intersection=this.intersectswithedge(this.items[i]);if(!intersection)continue;if(this.items[i].item[0]!=this.currentitem[0]&&this.currentitem[intersection==1?"next":"prev"]()[0]!=this.items[i].item[0]&&!contains(this.currentitem[0],this.items[i].item[0])&&(this.options.type=='semi-dynamic'?!contains(this.element[0],this.items[i].item[0]):true)){this.direction=intersection==1?"down":"up";this.rearrange(e,this.items[i]);this.propagate("change",e);break;}} this.contactcontainers(e);if($.ui.ddmanager)$.ui.ddmanager.drag(this,e);this.element.triggerhandler("sort",[e,this.ui()],this.options["sort"]);return false;},rearrange:function(e,i,a,hardrefresh){a?a[0].appendchild(this.currentitem[0]):i.item[0].parentnode.insertbefore(this.currentitem[0],(this.direction=='down'?i.item[0]:i.item[0].nextsibling));this.counter=this.counter?++this.counter:1;var self=this,counter=this.counter;window.settimeout(function(){if(counter==self.counter)self.refreshpositions(!hardrefresh);},0);if(this.options.placeholder) this.options.placeholder.update.call(this.element,this.currentitem,this.placeholder);},mousestop:function(e,nopropagation){if($.ui.ddmanager&&!this.options.dropbehaviour) $.ui.ddmanager.drop(this,e);if(this.options.revert){var self=this;var cur=self.currentitem.offset();if(self.placeholder)self.placeholder.animate({opacity:'hide'},(parseint(this.options.revert,10)||500)-50);$(this.helper).animate({left:cur.left-this.offset.parent.left-self.margins.left+(this.offsetparent[0]==document.body?0:this.offsetparent[0].scrollleft),top:cur.top-this.offset.parent.top-self.margins.top+(this.offsetparent[0]==document.body?0:this.offsetparent[0].scrolltop)},parseint(this.options.revert,10)||500,function(){self.clear(e);});}else{this.clear(e,nopropagation);} return false;},clear:function(e,nopropagation){if(this.domposition.prev!=this.currentitem.prev().not(".ui-sortable-helper")[0]||this.domposition.parent!=this.currentitem.parent()[0])this.propagate("update",e,null,nopropagation);if(!contains(this.element[0],this.currentitem[0])){this.propagate("remove",e,null,nopropagation);for(var i=this.containers.length-1;i>=0;i--){if(contains(this.containers[i].element[0],this.currentitem[0])){this.containers[i].propagate("update",e,this,nopropagation);this.containers[i].propagate("receive",e,this,nopropagation);}};};for(var i=this.containers.length-1;i>=0;i--){this.containers[i].propagate("deactivate",e,this,nopropagation);if(this.containers[i].containercache.over){this.containers[i].propagate("out",e,this);this.containers[i].containercache.over=0;}} this.dragging=false;if(this.cancelhelperremoval){this.propagate("stop",e,null,nopropagation);return false;} $(this.currentitem).css('visibility','');if(this.placeholder)this.placeholder.remove();this.helper.remove();this.helper=null;this.propagate("stop",e,null,nopropagation);return true;}}));$.extend($.ui.sortable,{getter:"serialize toarray",defaults:{helper:"clone",tolerance:"guess",distance:1,delay:0,scroll:true,scrollsensitivity:20,scrollspeed:20,cancel:":input",items:'> *',zindex:1000,droponempty:true,appendto:"parent"}});$.ui.plugin.add("sortable","cursor",{start:function(e,ui){var t=$('body');if(t.css("cursor"))ui.options._cursor=t.css("cursor");t.css("cursor",ui.options.cursor);},stop:function(e,ui){if(ui.options._cursor)$('body').css("cursor",ui.options._cursor);}});$.ui.plugin.add("sortable","zindex",{start:function(e,ui){var t=ui.helper;if(t.css("zindex"))ui.options._zindex=t.css("zindex");t.css('zindex',ui.options.zindex);},stop:function(e,ui){if(ui.options._zindex)$(ui.helper).css('zindex',ui.options._zindex);}});$.ui.plugin.add("sortable","opacity",{start:function(e,ui){var t=ui.helper;if(t.css("opacity"))ui.options._opacity=t.css("opacity");t.css('opacity',ui.options.opacity);},stop:function(e,ui){if(ui.options._opacity)$(ui.helper).css('opacity',ui.options._opacity);}});$.ui.plugin.add("sortable","scroll",{start:function(e,ui){var o=ui.options;var i=$(this).data("sortable");i.overflowy=function(el){do{if(/auto|scroll/.test(el.css('overflow'))||(/auto|scroll/).test(el.css('overflow-y')))return el;el=el.parent();}while(el[0].parentnode);return $(document);}(i.currentitem);i.overflowx=function(el){do{if(/auto|scroll/.test(el.css('overflow'))||(/auto|scroll/).test(el.css('overflow-x')))return el;el=el.parent();}while(el[0].parentnode);return $(document);}(i.currentitem);if(i.overflowy[0]!=document&&i.overflowy[0].tagname!='html')i.overflowyoffset=i.overflowy.offset();if(i.overflowx[0]!=document&&i.overflowx[0].tagname!='html')i.overflowxoffset=i.overflowx.offset();},sort:function(e,ui){var o=ui.options;var i=$(this).data("sortable");if(i.overflowy[0]!=document&&i.overflowy[0].tagname!='html'){if((i.overflowyoffset.top+i.overflowy[0].offsetheight)-e.pagey").insertbefore(options.headers);$("").appendto(options.headers);options.headers.addclass("ui-accordion-header").attr("tabindex","0");} var maxheight;if(options.fillspace){maxheight=this.element.parent().height();options.headers.each(function(){maxheight-=$(this).outerheight();});var maxpadding=0;options.headers.next().each(function(){maxpadding=math.max(maxpadding,$(this).innerheight()-$(this).height());}).height(maxheight-maxpadding);}else if(options.autoheight){maxheight=0;options.headers.next().each(function(){maxheight=math.max(maxheight,$(this).outerheight());}).height(maxheight);} options.headers.not(options.active||"").next().hide();options.active.parent().andself().addclass(options.selectedclass);if(options.event){this.element.bind((options.event)+".accordion",clickhandler);}},activate:function(index){clickhandler.call(this.element[0],{target:findactive(this.options.headers,index)[0]});},destroy:function(){this.options.headers.next().css("display","");if(this.options.fillspace||this.options.autoheight){this.options.headers.next().css("height","");} $.removedata(this.element[0],"accordion");this.element.removeclass("ui-accordion").unbind(".accordion");}});function scopecallback(callback,scope){return function(){return callback.apply(scope,arguments);};};function completed(cancel){if(!$.data(this,"accordion")){return;} var instance=$.data(this,"accordion");var options=instance.options;options.running=cancel?0:--options.running;if(options.running){return;} if(options.clearstyle){options.toshow.add(options.tohide).css({height:"",overflow:""});} $(this).triggerhandler("accordionchange",[$.event.fix({type:'accordionchange',target:instance.element[0]}),options.data],options.change);} function toggle(toshow,tohide,data,clickedactive,down){var options=$.data(this,"accordion").options;options.toshow=toshow;options.tohide=tohide;options.data=data;var complete=scopecallback(completed,this);options.running=tohide.size()===0?toshow.size():tohide.size();if(options.animated){if(!options.alwaysopen&&clickedactive){$.ui.accordion.animations[options.animated]({toshow:jquery([]),tohide:tohide,complete:complete,down:down,autoheight:options.autoheight});}else{$.ui.accordion.animations[options.animated]({toshow:toshow,tohide:tohide,complete:complete,down:down,autoheight:options.autoheight});}}else{if(!options.alwaysopen&&clickedactive){toshow.toggle();}else{tohide.hide();toshow.show();} complete(true);}} function clickhandler(event){var options=$.data(this,"accordion").options;if(options.disabled){return false;} if(!event.target&&!options.alwaysopen){options.active.parent().andself().toggleclass(options.selectedclass);var tohide=options.active.next(),data={options:options,newheader:jquery([]),oldheader:options.active,newcontent:jquery([]),oldcontent:tohide},toshow=(options.active=$([]));toggle.call(this,toshow,tohide,data);return false;} var clicked=$(event.target);clicked=$(clicked.parents(options.header)[0]||clicked);var clickedactive=clicked[0]==options.active[0];if(options.running||(options.alwaysopen&&clickedactive)){return false;} if(!clicked.is(options.header)){return;} options.active.parent().andself().toggleclass(options.selectedclass);if(!clickedactive){clicked.parent().andself().addclass(options.selectedclass);} var toshow=clicked.next(),tohide=options.active.next(),data={options:options,newheader:clicked,oldheader:options.active,newcontent:toshow,oldcontent:tohide},down=options.headers.index(options.active[0])>options.headers.index(clicked[0]);options.active=clickedactive?$([]):clicked;toggle.call(this,toshow,tohide,data,clickedactive,down);return false;};function findactive(headers,selector){return selector!=undefined?typeof selector=="number"?headers.filter(":eq("+selector+")"):headers.not(headers.not(selector)):selector===false?$([]):headers.filter(":eq(0)");} $.extend($.ui.accordion,{defaults:{selectedclass:"selected",alwaysopen:true,animated:'slide',event:"click",header:"a",autoheight:true,running:0,navigationfilter:function(){return this.href.tolowercase()==location.href.tolowercase();}},animations:{slide:function(options,additions){options=$.extend({easing:"swing",duration:300},options,additions);if(!options.tohide.size()){options.toshow.animate({height:"show"},options);return;} var hideheight=options.tohide.height(),showheight=options.toshow.height(),difference=showheight/hideheight;options.toshow.css({height:0,overflow:'hidden'}).show();options.tohide.filter(":hidden").each(options.complete).end().filter(":visible").animate({height:"hide"},{step:function(now){var current=(hideheight-now)*difference;if($.browser.msie||$.browser.opera){current=math.ceil(current);} options.toshow.height(current);},duration:options.duration,easing:options.easing,complete:function(){if(!options.autoheight){options.toshow.css("height","auto");} options.complete();}});},bounceslide:function(options){this.slide(options,{easing:options.down?"bounceout":"swing",duration:options.down?1000:200});},easeslide:function(options){this.slide(options,{easing:"easeinout",duration:700});}}});$.fn.activate=function(index){return this.accordion("activate",index);};})(jquery);(function($){var setdataswitch={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"};$.widget("ui.dialog",{init:function(){var self=this,options=this.options,resizehandles=typeof options.resizable=='string'?options.resizable:'n,e,s,w,se,sw,ne,nw',uidialogcontent=this.element.addclass('ui-dialog-content').wrap('
').wrap('
'),uidialogcontainer=(this.uidialogcontainer=uidialogcontent.parent().addclass('ui-dialog-container').css({position:'relative',width:'100%',height:'100%'})),title=options.title||uidialogcontent.attr('title')||'',uidialogtitlebar=(this.uidialogtitlebar=$('
')).append(''+title+'').append('x').prependto(uidialogcontainer),uidialog=(this.uidialog=uidialogcontainer.parent()).appendto(document.body).hide().addclass('ui-dialog').addclass(options.dialogclass).addclass(uidialogcontent.attr('classname')).removeclass('ui-dialog-content').css({position:'absolute',width:options.width,height:options.height,overflow:'hidden',zindex:options.zindex}).attr('tabindex',-1).css('outline',0).keydown(function(ev){if(options.closeonescape){var esc=27;(ev.keycode&&ev.keycode==esc&&self.close());}}).mousedown(function(){self.movetotop();}),uidialogbuttonpane=(this.uidialogbuttonpane=$('
')).addclass('ui-dialog-buttonpane').css({position:'absolute',bottom:0}).appendto(uidialog);this.uidialogtitlebarclose=$('.ui-dialog-titlebar-close',uidialogtitlebar).hover(function(){$(this).addclass('ui-dialog-titlebar-close-hover');},function(){$(this).removeclass('ui-dialog-titlebar-close-hover');}).mousedown(function(ev){ev.stoppropagation();}).click(function(){self.close();return false;});this.uidialogtitlebar.find("*").add(this.uidialogtitlebar).each(function(){$.ui.disableselection(this);});if($.fn.draggable){uidialog.draggable({cancel:'.ui-dialog-content',helper:options.draghelper,handle:'.ui-dialog-titlebar',start:function(e,ui){self.movetotop();(options.dragstart&&options.dragstart.apply(self.element[0],arguments));},drag:function(e,ui){(options.drag&&options.drag.apply(self.element[0],arguments));},stop:function(e,ui){(options.dragstop&&options.dragstop.apply(self.element[0],arguments));$.ui.dialog.overlay.resize();}});(options.draggable||uidialog.draggable('disable'));} if($.fn.resizable){uidialog.resizable({cancel:'.ui-dialog-content',helper:options.resizehelper,maxwidth:options.maxwidth,maxheight:options.maxheight,minwidth:options.minwidth,minheight:options.minheight,start:function(){(options.resizestart&&options.resizestart.apply(self.element[0],arguments));},resize:function(e,ui){(options.autoresize&&self.size.apply(self));(options.resize&&options.resize.apply(self.element[0],arguments));},handles:resizehandles,stop:function(e,ui){(options.autoresize&&self.size.apply(self));(options.resizestop&&options.resizestop.apply(self.element[0],arguments));$.ui.dialog.overlay.resize();}});(options.resizable||uidialog.resizable('disable'));} this.createbuttons(options.buttons);this.isopen=false;(options.bgiframe&&$.fn.bgiframe&&uidialog.bgiframe());(options.autoopen&&this.open());},setdata:function(key,value){(setdataswitch[key]&&this.uidialog.data(setdataswitch[key],value));switch(key){case"buttons":this.createbuttons(value);break;case"draggable":this.uidialog.draggable(value?'enable':'disable');break;case"height":this.uidialog.height(value);break;case"position":this.position(value);break;case"resizable":(typeof value=='string'&&this.uidialog.data('handles.resizable',value));this.uidialog.resizable(value?'enable':'disable');break;case"title":$(".ui-dialog-title",this.uidialogtitlebar).text(value);break;case"width":this.uidialog.width(value);break;} $.widget.prototype.setdata.apply(this,arguments);},position:function(pos){var wnd=$(window),doc=$(document),ptop=doc.scrolltop(),pleft=doc.scrollleft(),mintop=ptop;if($.inarray(pos,['center','top','right','bottom','left'])>=0){pos=[pos=='right'||pos=='left'?pos:'center',pos=='top'||pos=='bottom'?pos:'middle'];} if(pos.constructor!=array){pos=['center','middle'];} if(pos[0].constructor==number){pleft+=pos[0];}else{switch(pos[0]){case'left':pleft+=0;break;case'right':pleft+=wnd.width()-this.uidialog.width();break;default:case'center':pleft+=(wnd.width()-this.uidialog.width())/2;}} if(pos[1].constructor==number){ptop+=pos[1];}else{switch(pos[1]){case'top':ptop+=0;break;case'bottom':ptop+=wnd.height()-this.uidialog.height();break;default:case'middle':ptop+=(wnd.height()-this.uidialog.height())/2;}} ptop=math.max(ptop,mintop);this.uidialog.css({top:ptop,left:pleft});},size:function(){var container=this.uidialogcontainer,titlebar=this.uidialogtitlebar,content=this.element,tbmargin=parseint(content.css('margin-top'),10)+parseint(content.css('margin-bottom'),10),lrmargin=parseint(content.css('margin-left'),10)+parseint(content.css('margin-right'),10);content.height(container.height()-titlebar.outerheight()-tbmargin);content.width(container.width()-lrmargin);},open:function(){if(this.isopen){return;} this.overlay=this.options.modal?new $.ui.dialog.overlay(this):null;(this.uidialog.next().length>0)&&this.uidialog.appendto('body');this.position(this.options.position);this.uidialog.show(this.options.show);this.options.autoresize&&this.size();this.movetotop(true);var openev=null;var openui={options:this.options};this.uidialogtitlebarclose.focus();this.element.triggerhandler("dialogopen",[openev,openui],this.options.open);this.isopen=true;},movetotop:function(force){if((this.options.modal&&!force)||(!this.options.stack&&!this.options.modal)){return this.element.triggerhandler("dialogfocus",[null,{options:this.options}],this.options.focus);} var maxz=this.options.zindex,options=this.options;$('.ui-dialog:visible').each(function(){maxz=math.max(maxz,parseint($(this).css('z-index'),10)||options.zindex);});(this.overlay&&this.overlay.$el.css('z-index',++maxz));this.uidialog.css('z-index',++maxz);this.element.triggerhandler("dialogfocus",[null,{options:this.options}],this.options.focus);},close:function(){(this.overlay&&this.overlay.destroy());this.uidialog.hide(this.options.hide);var closeev=null;var closeui={options:this.options};this.element.triggerhandler("dialogclose",[closeev,closeui],this.options.close);$.ui.dialog.overlay.resize();this.isopen=false;},destroy:function(){(this.overlay&&this.overlay.destroy());this.uidialog.hide();this.element.unbind('.dialog').removedata('dialog').removeclass('ui-dialog-content').hide().appendto('body');this.uidialog.remove();},createbuttons:function(buttons){var self=this,hasbuttons=false,uidialogbuttonpane=this.uidialogbuttonpane;uidialogbuttonpane.empty().hide();$.each(buttons,function(){return!(hasbuttons=true);});if(hasbuttons){uidialogbuttonpane.show();$.each(buttons,function(name,fn){$('
');} $.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(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'+new date().gettime();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){return{id:target[0].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);if(input.hasclass(this.markerclassname)) return;var appendtext=this._get(inst,'appendtext');var isrtl=this._get(inst,'isrtl');if(appendtext) input[isrtl?'before':'after'](''+appendtext+'');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');var 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'](trigger);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 input=$(target);if(input.hasclass(this.markerclassname)) return;input.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);},_dialogdatepicker:function(input,datetext,onselect,settings,pos){var inst=this._dialoginst;if(!inst){var id='dp'+new date().gettime();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 nodename=target.nodename.tolowercase();var $target=$(target);$.removedata(target,prop_name);if(nodename=='input'){$target.siblings('.'+this._appendclass).remove().end().siblings('.'+this._triggerclass).remove().end().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){target.disabled=false;$(target).siblings('button.'+this._triggerclass).each(function(){this.disabled=false;}).end().siblings('img.'+this._triggerclass).css({opacity:'1.0',cursor:''});this._disabledinputs=$.map(this._disabledinputs,function(value){return(value==target?null:value);});},_disabledatepicker:function(target){target.disabled=true;$(target).siblings('button.'+this._triggerclass).each(function(){this.disabled=true;}).end().siblings('img.'+this._triggerclass).css({opacity:'0.5',cursor:'default'});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=$.data(input,prop_name);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);inst.dpdiv.width($.datepicker._getnumberofmonths(inst)[1]*$('.ui-datepicker',inst.dpdiv[0])[0].offsetwidth);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)<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};inst.dpdiv.empty().append(this._generatedatepicker(inst)).find('iframe.ui-datepicker-cover').css({width:dims.width,height:dims.height});var nummonths=this._getnumberofmonths(inst);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.input[0]).focus();},_checkoffset:function(inst,offset,isfixed){var pos=inst.input?this._findpos(inst.input[0]):null;var browserwidth=window.innerwidth||document.documentelement.clientwidth;var browserheight=window.innerheight||document.documentelement.clientheight;var scrollx=document.documentelement.scrollleft||document.body.scrollleft;var scrolly=document.documentelement.scrolltop||document.body.scrolltop;if(this._get(inst,'isrtl')||(offset.left+inst.dpdiv.width()-scrollx)>browserwidth) offset.left=math.max((isfixed?0:scrollx),pos[0]+(inst.input?inst.input.width():0)-(isfixed?scrollx:0)-inst.dpdiv.width()- (isfixed&&$.browser.opera?document.documentelement.scrollleft:0));else offset.left-=(isfixed?scrollx:0);if((offset.top+inst.dpdiv.height()-scrolly)>browserheight) offset.top=math.max((isfixed?0:scrolly),pos[1]-(isfixed?scrolly:0)-(this._indialog?0:inst.dpdiv.height())- (isfixed&&$.browser.opera?document.documentelement.scrolltop:0));else offset.top-=(isfixed?scrolly: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) return;var rangeselect=this._get(inst,'rangeselect');if(rangeselect&&this._stayopen) this._selectdate('#'+inst.id,this._formatdate(inst,inst.currentday,inst.currentmonth,inst.currentyear));this._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),[this._getdate(inst),inst]);this._datepickershowing=false;this._lastinput=null;inst.settings.prompt=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');$('.'+this._promptclass,inst.dpdiv).remove();},_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=$.data(target[0],prop_name);this._adjustinstdate(inst,offset,period);this._updatedatepicker(inst);},_gototoday:function(id){var target=$(id);var inst=$.data(target[0],prop_name);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._adjustdate(target);this._notifychange(inst);},_selectmonthyear:function(id,select,period){var target=$(id);var inst=$.data(target[0],prop_name);inst._selectingmonthyear=false;inst[period=='m'?'drawmonth':'drawyear']=select.options[select.selectedindex].value-0;this._adjustdate(target);this._notifychange(inst);},_clickmonthyear:function(id){var target=$(id);var inst=$.data(target[0],prop_name);if(inst.input&&inst._selectingmonthyear&&!$.browser.msie) inst.input[0].focus();inst._selectingmonthyear=!inst._selectingmonthyear;},_changefirstday:function(id,day){var target=$(id);var inst=$.data(target[0],prop_name);inst.settings.firstday=day;this._updatedatepicker(inst);},_selectday:function(id,month,year,td){if($(td).hasclass(this._unselectableclass)) return;var target=$(id);var inst=$.data(target[0],prop_name);var rangeselect=this._get(inst,'rangeselect');if(rangeselect){this._stayopen=!this._stayopen;if(this._stayopen){$('.ui-datepicker td').removeclass(this._currentclass);$(td).addclass(this._currentclass);}} inst.selectedday=inst.currentday=$('a',td).html();inst.selectedmonth=inst.currentmonth=month;inst.selectedyear=inst.currentyear=year;if(this._stayopen){inst.endday=inst.endmonth=inst.endyear=null;} else if(rangeselect){inst.endday=inst.currentday;inst.endmonth=inst.currentmonth;inst.endyear=inst.currentyear;} this._selectdate(id,this._formatdate(inst,inst.currentday,inst.currentmonth,inst.currentyear));if(this._stayopen){inst.rangestart=this._daylightsavingadjust(new date(inst.currentyear,inst.currentmonth,inst.currentday));this._updatedatepicker(inst);} else if(rangeselect){inst.selectedday=inst.currentday=inst.rangestart.getdate();inst.selectedmonth=inst.currentmonth=inst.rangestart.getmonth();inst.selectedyear=inst.currentyear=inst.rangestart.getfullyear();inst.rangestart=null;if(inst.inline) this._updatedatepicker(inst);}},_cleardate:function(id){var target=$(id);var inst=$.data(target[0],prop_name);if(this._get(inst,'mandatory')) return;this._stayopen=false;inst.endday=inst.endmonth=inst.endyear=inst.rangestart=null;this._selectdate(target,'');},_selectdate:function(id,datestr){var target=$(id);var inst=$.data(target[0],prop_name);datestr=(datestr!=null?datestr:this._formatdate(inst));if(this._get(inst,'rangeselect')&&datestr) datestr=(inst.rangestart?this._formatdate(inst,inst.rangestart):datestr)+this._get(inst,'rangeseparator')+datestr;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(!this._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');var date=this._getdate(inst);datestr=(isarray(date)?(!date[0]&&!date[1]?'':this.formatdate(altformat,date[0],this._getformatconfig(inst))+ this._get(inst,'rangeseparator')+this.formatdate(altformat,date[1]||date[0],this._getformatconfig(inst))):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+(value.charat(ivalue++)-0);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&&ivalue0){var settings=this._getformatconfig(inst);if(dates.length>1){date=this.parsedate(dateformat,dates[1],settings)||defaultdate;inst.endday=date.getdate();inst.endmonth=date.getmonth();inst.endyear=date.getfullyear();} try{date=this.parsedate(dateformat,dates[0],settings)||defaultdate;}catch(e){this.log(e);date=defaultdate;}} inst.selectedday=date.getdate();inst.drawmonth=inst.selectedmonth=date.getmonth();inst.drawyear=inst.selectedyear=date.getfullyear();inst.currentday=(dates[0]?date.getdate():0);inst.currentmonth=(dates[0]?date.getmonth():0);inst.currentyear=(dates[0]?date.getfullyear():0);this._adjustinstdate(inst);},_getdefaultdate:function(inst){var date=this._determinedate(this._get(inst,'defaultdate'),new date());var mindate=this._getminmaxdate(inst,'min',true);var maxdate=this._getminmaxdate(inst,'max');date=(mindate&&datemaxdate?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+=(matches[1]-0);break;case'w':case'w':day+=(matches[1]*7);break;case'm':case'm':month+=(matches[1]-0);day=math.min(day,getdaysinmonth(year,month));break;case'y':case'y':year+=(matches[1]-0);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);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(this._get(inst,'rangeselect')){if(enddate){enddate=this._determinedate(enddate,null);inst.endday=enddate.getdate();inst.endmonth=enddate.getmonth();inst.endyear=enddate.getfullyear();}else{inst.endday=inst.currentday;inst.endmonth=inst.currentmonth;inst.endyear=inst.currentyear;}} this._adjustinstdate(inst);if(inst.input) inst.input.val(clear?'':this._formatdate(inst)+ (!this._get(inst,'rangeselect')?'':this._get(inst,'rangeseparator')+ this._formatdate(inst,inst.endday,inst.endmonth,inst.endyear)));},_getdate:function(inst){var startdate=(!inst.currentyear||(inst.input&&inst.input.val()=='')?null:this._daylightsavingadjust(new date(inst.currentyear,inst.currentmonth,inst.currentday)));if(this._get(inst,'rangeselect')){return[inst.rangestart||startdate,(!inst.endyear?inst.rangestart||startdate:this._daylightsavingadjust(new date(inst.endyear,inst.endmonth,inst.endday)))];}else return startdate;},_generatedatepicker:function(inst){var today=new date();today=this._daylightsavingadjust(new date(today.getfullyear(),today.getmonth(),today.getdate()));var showstatus=this._get(inst,'showstatus');var isrtl=this._get(inst,'isrtl');var clear=(this._get(inst,'mandatory')?'':'');var controls='
'+(isrtl?'':clear)+''+(isrtl?clear:'')+'
';var prompt=this._get(inst,'prompt');var closeattop=this._get(inst,'closeattop');var hideifnoprevnext=this._get(inst,'hideifnoprevnext');var navigationasdateformat=this._get(inst,'navigationasdateformat');var nummonths=this._getnumberofmonths(inst);var stepmonths=this._get(inst,'stepmonths');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;var drawyear=inst.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--;}}} 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?'':''))+'
';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?'':''))+'
';var currenttext=this._get(inst,'currenttext');currenttext=(!navigationasdateformat?currenttext:this.formatdate(currenttext,today,this._getformatconfig(inst)));var html=(prompt?'
'+prompt+'
':'')+ (closeattop&&!inst.inline?controls:'')+'';var firstday=this._get(inst,'firstday');var changefirstday=this._get(inst,'changefirstday');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 beforeshowday=this._get(inst,'beforeshowday');var highlightweek=this._get(inst,'highlightweek');var showothermonths=this._get(inst,'showothermonths');var showweeks=this._get(inst,'showweeks');var calculateweek=this._get(inst,'calculateweek')||this.iso8601week;var status=(showstatus?this._get(inst,'daystatus')||' ':'');var datestatus=this._get(inst,'statusfordate')||this.datestatus;var enddate=inst.endday?this._daylightsavingadjust(new date(inst.endyear,inst.endmonth,inst.endday)):currentdate;for(var row=0;row'+ this._generatemonthyearheader(inst,drawmonth,drawyear,mindate,maxdate,selecteddate,row>0||col>0,showstatus,monthnames)+''+''+ (showweeks?'':'');for(var dow=0;dow<7;dow++){var day=(dow+firstday)%7;var daystatus=(status.indexof('dd')>-1?status.replace(/dd/,daynames[day]):status.replace(/d/,daynamesshort[day]));html+='=5?' class="ui-datepicker-week-end-cell"':'')+'>'+ (!changefirstday?''+ daynamesmin[day]+(changefirstday?'':'')+'';} html+='';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'+ (showweeks?'':'');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);html+='';printdate.setdate(printdate.getdate()+1);printdate=this._daylightsavingadjust(printdate);} html+='';} drawmonth++;if(drawmonth>11){drawmonth=0;drawyear++;} html+='
'+this._get(inst,'weekheader')+'
'+calculateweek(printdate)+''+ (othermonth?(showothermonths?printdate.getdate():' '):(unselectable?printdate.getdate():''+printdate.getdate()+''))+'
';} html+=(showstatus?'
'+(this._get(inst,'initstatus')||' ')+'
':'')+ (!closeattop&&!inst.inline?controls:'')+'
'+ ($.browser.msie&&parseint($.browser.version)<7&&!inst.inline?'':'');return html;},_generatemonthyearheader:function(inst,drawmonth,drawyear,mindate,maxdate,selecteddate,secondary,showstatus,monthnames){mindate=(inst.rangestart&&mindate&&selecteddate';for(var month=0;month<12;month++){if((!inminyear||month>=mindate.getmonth())&&(!inmaxyear||month<=maxdate.getmonth())) html+='';} html+='';} if(secondary||!this._get(inst,'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=endyear=new date().getfullyear();year+=parseint(years[0],10);endyear+=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+='';} html+='
';return html;},_addstatus:function(inst,text){return' onmouseover="jquery(\'#ui-datepicker-status-'+inst.id+'\').html(\''+text+'\');" '+'onmouseout="jquery(\'#ui-datepicker-status-'+inst.id+'\').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),[new date(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){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));return this.each(function(){typeof options=='string'?$.datepicker['_'+options+'datepicker'].apply($.datepicker,[this].concat(otherargs)):$.datepicker._attachdatepicker(this,options);});};$.datepicker=new datepicker();$(document).ready(function(){$(document.body).append($.datepicker.dpdiv).mousedown($.datepicker._checkexternalclick);});})(jquery);;(function($){$.effects=$.effects||{};$.extend($.effects,{save:function(el,set){for(var i=0;i
');var wrapper=el.parent();if(el.css('position')=='static'){wrapper.css({position:'relative'});el.css({position:'relative'});}else{var top=el.css('top');if(isnan(parseint(top)))top='auto';var left=el.css('left');if(isnan(parseint(left)))left='auto';wrapper.css({position:el.css('position'),top:top,left:left,zindex:el.css('z-index')}).show();el.css({position:'relative',top:0,left:0});} wrapper.css(props);return wrapper;},removewrapper:function(el){if(el.parent().attr('id')=='fxwrapper') return el.parent().replacewith(el);return el;},settransition:function(el,list,factor,val){val=val||{};$.each(list,function(i,x){unit=el.cssunit(x);if(unit[0]>0)val[x]=unit[0]*factor+unit[1];});return val;},animateclass:function(value,duration,easing,callback){var cb=(typeof easing=="function"?easing:(callback?callback:null));var ea=(typeof easing=="object"?easing:null);return this.each(function(){var offset={};var that=$(this);var oldstyleattr=that.attr("style")||'';if(typeof oldstyleattr=='object')oldstyleattr=oldstyleattr["csstext"];if(value.toggle){that.hasclass(value.toggle)?value.remove=value.toggle:value.add=value.toggle;} var oldstyle=$.extend({},(document.defaultview?document.defaultview.getcomputedstyle(this,null):this.currentstyle));if(value.add)that.addclass(value.add);if(value.remove)that.removeclass(value.remove);var newstyle=$.extend({},(document.defaultview?document.defaultview.getcomputedstyle(this,null):this.currentstyle));if(value.add)that.removeclass(value.add);if(value.remove)that.addclass(value.remove);for(var n in newstyle){if(typeof newstyle[n]!="function"&&newstyle[n]&&n.indexof("moz")==-1&&n.indexof("length")==-1&&newstyle[n]!=oldstyle[n]&&(n.match(/color/i)||(!n.match(/color/i)&&!isnan(parseint(newstyle[n],10))))&&(oldstyle.position!="static"||(oldstyle.position=="static"&&!n.match(/left|top|bottom|right/))))offset[n]=newstyle[n];} that.animate(offset,duration,ea,function(){if(typeof $(this).attr("style")=='object'){$(this).attr("style")["csstext"]="";$(this).attr("style")["csstext"]=oldstyleattr;}else $(this).attr("style",oldstyleattr);if(value.add)$(this).addclass(value.add);if(value.remove)$(this).removeclass(value.remove);if(cb)cb.apply(this,arguments);});});}});$.fn.extend({_show:$.fn.show,_hide:$.fn.hide,__toggle:$.fn.toggle,_addclass:$.fn.addclass,_removeclass:$.fn.removeclass,_toggleclass:$.fn.toggleclass,effect:function(fx,o,speed,callback){return $.effects[fx]?$.effects[fx].call(this,{method:fx,options:o||{},duration:speed,callback:callback}):null;},show:function(){if(!arguments[0]||(arguments[0].constructor==number||/(slow|normal|fast)/.test(arguments[0]))) return this._show.apply(this,arguments);else{var o=arguments[1]||{};o['mode']='show';return this.effect.apply(this,[arguments[0],o,arguments[2]||o.duration,arguments[3]||o.callback]);}},hide:function(){if(!arguments[0]||(arguments[0].constructor==number||/(slow|normal|fast)/.test(arguments[0]))) return this._hide.apply(this,arguments);else{var o=arguments[1]||{};o['mode']='hide';return this.effect.apply(this,[arguments[0],o,arguments[2]||o.duration,arguments[3]||o.callback]);}},toggle:function(){if(!arguments[0]||(arguments[0].constructor==number||/(slow|normal|fast)/.test(arguments[0]))||(arguments[0].constructor==function)) return this.__toggle.apply(this,arguments);else{var o=arguments[1]||{};o['mode']='toggle';return this.effect.apply(this,[arguments[0],o,arguments[2]||o.duration,arguments[3]||o.callback]);}},addclass:function(classnames,speed,easing,callback){return speed?$.effects.animateclass.apply(this,[{add:classnames},speed,easing,callback]):this._addclass(classnames);},removeclass:function(classnames,speed,easing,callback){return speed?$.effects.animateclass.apply(this,[{remove:classnames},speed,easing,callback]):this._removeclass(classnames);},toggleclass:function(classnames,speed,easing,callback){return speed?$.effects.animateclass.apply(this,[{toggle:classnames},speed,easing,callback]):this._toggleclass(classnames);},morph:function(remove,add,speed,easing,callback){return $.effects.animateclass.apply(this,[{add:add,remove:remove},speed,easing,callback]);},switchclass:function(){return this.morph.apply(this,arguments);},cssunit:function(key){var style=this.css(key),val=[];$.each(['em','px','%','pt'],function(i,unit){if(style.indexof(unit)>0) val=[parsefloat(style),unit];});return val;}});jquery.each(['backgroundcolor','borderbottomcolor','borderleftcolor','borderrightcolor','bordertopcolor','color','outlinecolor'],function(i,attr){jquery.fx.step[attr]=function(fx){if(fx.state==0){fx.start=getcolor(fx.elem,attr);fx.end=getrgb(fx.end);} fx.elem.style[attr]="rgb("+[math.max(math.min(parseint((fx.pos*(fx.end[0]-fx.start[0]))+fx.start[0]),255),0),math.max(math.min(parseint((fx.pos*(fx.end[1]-fx.start[1]))+fx.start[1]),255),0),math.max(math.min(parseint((fx.pos*(fx.end[2]-fx.start[2]))+fx.start[2]),255),0)].join(",")+")";}});function getrgb(color){var result;if(color&&color.constructor==array&&color.length==3) return color;if(result=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(color)) return[parseint(result[1]),parseint(result[2]),parseint(result[3])];if(result=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(color)) return[parsefloat(result[1])*2.55,parsefloat(result[2])*2.55,parsefloat(result[3])*2.55];if(result=/#([a-fa-f0-9]{2})([a-fa-f0-9]{2})([a-fa-f0-9]{2})/.exec(color)) return[parseint(result[1],16),parseint(result[2],16),parseint(result[3],16)];if(result=/#([a-fa-f0-9])([a-fa-f0-9])([a-fa-f0-9])/.exec(color)) return[parseint(result[1]+result[1],16),parseint(result[2]+result[2],16),parseint(result[3]+result[3],16)];if(result=/rgba\(0, 0, 0, 0\)/.exec(color)) return colors['transparent'] return colors[jquery.trim(color).tolowercase()];} function getcolor(elem,attr){var color;do{color=jquery.curcss(elem,attr);if(color!=''&&color!='transparent'||jquery.nodename(elem,"body")) break;attr="backgroundcolor";}while(elem=elem.parentnode);return getrgb(color);};var colors={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]};jquery.easing['jswing']=jquery.easing['swing'];jquery.extend(jquery.easing,{def:'easeoutquad',swing:function(x,t,b,c,d){return jquery.easing[jquery.easing.def](x,t,b,c,d);},easeinquad:function(x,t,b,c,d){return c*(t/=d)*t+b;},easeoutquad:function(x,t,b,c,d){return-c*(t/=d)*(t-2)+b;},easeinoutquad:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t+b;return-c/2*((--t)*(t-2)-1)+b;},easeincubic:function(x,t,b,c,d){return c*(t/=d)*t*t+b;},easeoutcubic:function(x,t,b,c,d){return c*((t=t/d-1)*t*t+1)+b;},easeinoutcubic:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t+b;return c/2*((t-=2)*t*t+2)+b;},easeinquart:function(x,t,b,c,d){return c*(t/=d)*t*t*t+b;},easeoutquart:function(x,t,b,c,d){return-c*((t=t/d-1)*t*t*t-1)+b;},easeinoutquart:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t*t+b;return-c/2*((t-=2)*t*t*t-2)+b;},easeinquint:function(x,t,b,c,d){return c*(t/=d)*t*t*t*t+b;},easeoutquint:function(x,t,b,c,d){return c*((t=t/d-1)*t*t*t*t+1)+b;},easeinoutquint:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t*t*t+b;return c/2*((t-=2)*t*t*t*t+2)+b;},easeinsine:function(x,t,b,c,d){return-c*math.cos(t/d*(math.pi/2))+c+b;},easeoutsine:function(x,t,b,c,d){return c*math.sin(t/d*(math.pi/2))+b;},easeinoutsine:function(x,t,b,c,d){return-c/2*(math.cos(math.pi*t/d)-1)+b;},easeinexpo:function(x,t,b,c,d){return(t==0)?b:c*math.pow(2,10*(t/d-1))+b;},easeoutexpo:function(x,t,b,c,d){return(t==d)?b+c:c*(-math.pow(2,-10*t/d)+1)+b;},easeinoutexpo:function(x,t,b,c,d){if(t==0)return b;if(t==d)return b+c;if((t/=d/2)<1)return c/2*math.pow(2,10*(t-1))+b;return c/2*(-math.pow(2,-10*--t)+2)+b;},easeincirc:function(x,t,b,c,d){return-c*(math.sqrt(1-(t/=d)*t)-1)+b;},easeoutcirc:function(x,t,b,c,d){return c*math.sqrt(1-(t=t/d-1)*t)+b;},easeinoutcirc:function(x,t,b,c,d){if((t/=d/2)<1)return-c/2*(math.sqrt(1-t*t)-1)+b;return c/2*(math.sqrt(1-(t-=2)*t)+1)+b;},easeinelastic:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d)==1)return b+c;if(!p)p=d*.3;if(a').css({position:'absolute',visibility:'visible',left:-j*(width/cells),top:-i*(height/rows)}).parent().addclass('effects-explode').css({position:'absolute',overflow:'hidden',width:width/cells,height:height/rows,left:offset.left+j*(width/cells)+(o.options.mode=='show'?(j-math.floor(cells/2))*(width/cells):0),top:offset.top+i*(height/rows)+(o.options.mode=='show'?(i-math.floor(rows/2))*(height/rows):0),opacity:o.options.mode=='show'?0:1}).animate({left:offset.left+j*(width/cells)+(o.options.mode=='show'?0:(j-math.floor(cells/2))*(width/cells)),top:offset.top+i*(height/rows)+(o.options.mode=='show'?0:(i-math.floor(rows/2))*(height/rows)),opacity:o.options.mode=='show'?1:0},o.duration||500);}} settimeout(function(){o.options.mode=='show'?el.css({visibility:'visible'}):el.css({visibility:'visible'}).hide();if(o.callback)o.callback.apply(el[0]);el.dequeue();$('.effects-explode').remove();},o.duration||500);});};})(jquery);(function($){$.effects.fold=function(o){return this.queue(function(){var el=$(this),props=['position','top','left'];var mode=$.effects.setmode(el,o.options.mode||'hide');var size=o.options.size||15;var horizfirst=!(!o.options.horizfirst);$.effects.save(el,props);el.show();var wrapper=$.effects.createwrapper(el).css({overflow:'hidden'});var widthfirst=((mode=='show')!=horizfirst);var ref=widthfirst?['width','height']:['height','width'];var distance=widthfirst?[wrapper.width(),wrapper.height()]:[wrapper.height(),wrapper.width()];var percent=/([0-9]+)%/.exec(size);if(percent)size=parseint(percent[1])/100*distance[mode=='hide'?0:1];if(mode=='show')wrapper.css(horizfirst?{height:0,width:size}:{height:size,width:0});var animation1={},animation2={};animation1[ref[0]]=mode=='show'?distance[0]:size;animation2[ref[1]]=mode=='show'?distance[1]:0;wrapper.animate(animation1,o.duration/2,o.options.easing).animate(animation2,o.duration/2,o.options.easing,function(){if(mode=='hide')el.hide();$.effects.restore(el,props);$.effects.removewrapper(el);if(o.callback)o.callback.apply(el[0],arguments);el.dequeue();});});};})(jquery);;(function($){$.effects.highlight=function(o){return this.queue(function(){var el=$(this),props=['backgroundimage','backgroundcolor','opacity'];var mode=$.effects.setmode(el,o.options.mode||'show');var color=o.options.color||"#ffff99";var oldcolor=el.css("backgroundcolor");$.effects.save(el,props);el.show();el.css({backgroundimage:'none',backgroundcolor:color});var animation={backgroundcolor:oldcolor};if(mode=="hide")animation['opacity']=0;el.animate(animation,{queue:false,duration:o.duration,easing:o.options.easing,complete:function(){if(mode=="hide")el.hide();$.effects.restore(el,props);if(mode=="show"&&jquery.browser.msie)this.style.removeattribute('filter');if(o.callback)o.callback.apply(this,arguments);el.dequeue();}});});};})(jquery);(function($){$.effects.pulsate=function(o){return this.queue(function(){var el=$(this);var mode=$.effects.setmode(el,o.options.mode||'show');var times=o.options.times||5;if(mode=='hide')times--;if(el.is(':hidden')){el.css('opacity',0);el.show();el.animate({opacity:1},o.duration/2,o.options.easing);times=times-2;} for(var i=0;i').appendto(document.body);if(o.options.classname)transfer.addclass(o.options.classname);transfer.addclass(o.options.classname);transfer.css({top:position.top,left:position.left,height:el.outerheight()-parseint(transfer.css('bordertopwidth'))-parseint(transfer.css('borderbottomwidth')),width:el.outerwidth()-parseint(transfer.css('borderleftwidth'))-parseint(transfer.css('borderrightwidth')),position:'absolute'});position=target.offset();animation={top:position.top,left:position.left,height:target.outerheight()-parseint(transfer.css('bordertopwidth'))-parseint(transfer.css('borderbottomwidth')),width:target.outerwidth()-parseint(transfer.css('borderleftwidth'))-parseint(transfer.css('borderrightwidth'))};transfer.animate(animation,o.duration,o.options.easing,function(){transfer.remove();if(o.callback)o.callback.apply(el[0],arguments);el.dequeue();});});};})(jquery);/* |xgv00|549d3a27df687a72a24cdd0089c78671 */