Файл: i/js/0.js
Строк: 12694
<?php
function createCookie(a,b,c){if(c){var d=new Date;d.setTime(d.getTime()+24*c*60*60*1e3);var e="; expires="+d.toGMTString()}else var e="";document.cookie=a+"="+b+e+"; path=/"}function readCookie(a){for(var b=a+"=",c=document.cookie.split(";"),d=0;d<c.length;d++){for(var e=c[d];" "==e.charAt(0);)e=e.substring(1,e.length);if(0==e.indexOf(b))return e.substring(b.length,e.length)}return null}function eraseCookie(a){createCookie(a,"",-1)}function fixEvent(a,b){if(a=a||window.event,a.currentTarget||(a.currentTarget=b),a.target||(a.target=a.srcElement),a.relatedTarget||("mouseover"==a.type&&(a.relatedTarget=a.fromElement),"mouseout"==a.type&&(a.relatedTarget=a.toElement)),null==a.pageX&&null!=a.clientX){var c=document.documentElement,d=document.body;a.pageX=a.clientX+(c.scrollLeft||d&&d.scrollLeft||0),a.pageX-=c.clientLeft||0,a.pageY=a.clientY+(c.scrollTop||d&&d.scrollTop||0),a.pageY-=c.clientTop||0}return!a.which&&a.button&&(a.which=1&a.button?1:2&a.button?3:4&a.button?2:0),a}function implode(a,b){return b instanceof Array?b.join(a):b}function str_replace(a,b,c){if(!(b instanceof Array)&&(b=new Array(b),a instanceof Array))for(;a.length>b.length;)b[b.length]=b[0];for(a instanceof Array||(a=new Array(a));a.length>b.length;)b[b.length]="";if(c instanceof Array){for(d in c)c[d]=str_replace(a,b,c[d]);return c}for(var d=0;d<a.length;d++)for(var e=c.indexOf(a[d]);e>-1;)c=c.replace(a[d],b[d]),e=c.indexOf(a[d],e);return c}function rurl(a){for(var b=new Array("%80","%81","%82","%83","%84","%85","%86","%87","%88","%89","%8A","%8B","%8C","%8D","%8E","%8F","%90","%91","%92","%93","%94","%95","%96","%97","%99","%9A","%9B","%9C","%9D","%9E","%9F","%A1","%A2","%A3","%A4","%A5","%A6","%A7","%A8","%A9","%AA","%AB","%AC","%AE","%AF","%B0","%B1","%B2","%B3","%B4","%B5","%B6","%B7","%B8","%B9","%BA","%BB","%BC","%BD","%BE","%BF","%C0","%C1","%C2","%C3","%C4","%C5","%C6","%C7","%C8","%C9","%CA","%CB","%CC","%CD","%CE","%CF","%D0","%D1","%D2","%D3","%D4","%D5","%D6","%D7","%D8","%D9","%DA","%DB","%DC","%DD","%DE","%DF","%E0","%E1","%E2","%E3","%E4","%E5","%E6","%E7","%E8","%E9","%EA","%EB","%EC","%ED","%EE","%EF","%F0","%F1","%F2","%F3","%F4","%F5","%F6","%F7","%F8","%F9","%FA","%FB","%FC","%FD","%FE","%FF"),c=new Array("Ђ","Ѓ","‚","ѓ","„","…","†","‡","€","‰","Љ","‹","Њ","Ќ","Ћ","Џ","ђ","‘","’","“","”","•","–","—","™","љ","›","њ","ќ","ћ","џ","Ў","ў","Ј","¤","Ґ","¦","§","Ё","©","Є","«","¬","®","Ї","°","±","І","і","ґ","µ","¶","·","ё","№","є","»","ј","Ѕ","ѕ","ї","А","Б","В","Г","Д","Е","Ж","З","И","Й","К","Л","М","Н","О","П","Р","С","Т","У","Ф","Х","Ц","Ч","Ш","Щ","Ъ","Ы","Ь","Э","Ю","Я","а","б","в","г","д","е","ж","з","и","й","к","л","м","н","о","п","р","с","т","у","ф","х","ц","ч","ш","щ","ъ","ы","ь","э","ю","я"),d=0;d<b.length;d++)a=a.replace(new RegExp(b[d],"g"),c[d]);return a}function Player(){var a=this;a.data={css:{search:"#search-value",lyrics:"#lyrics"},text:{loading:"Загрузка...",mode:{prefix:"Режим воспроизведения: ",line:"весь плейлист",repeat:"повторять текущий трек",shuffle:"в случайном порядке",stop:"остановить в конце песни"},seek:"Перемотка: ",unavailable:"Выбранная песня сейчас недоступна",volume:"Громкость: ",mute:"Звук: отключен",added:"Песня добавлена в плейлист",playonesong:"Прослушать",pauseonesong:"Пауза",cf:{on:"Плавный переход включен",off:"Плавный переход выключен"}},url:{home:window.location.protocol+"//"+window.location.host,favicon:"/i/img/favicon-%mode%.png",swf:"/i/swf/",save_pl:"/public/api.playlist.php",lyrics:"/public/api.lyrics.php"},delay:1e3,error_timeout:3e3},a.state={pl:"main",i:0,user_pl:0,sound:null,info:null,pb:"stop",mode:"line",started:!1,paused:!1,position:0,duration:0,volume:75,unmute:75,muted:!1,cf:!1,radio:!1},a.init=function(){SM.setup({autoStart:!1,useThrottling:!1,usePeakData:!0,useWaveformData:!1,useEQData:!1,useFavIcon:!1,url:a.data.url.swf,preferFlash:!1,flashVersion:9,useHighPerformance:!0,debugMode:!1,ontimeout:function(){SM.flashLoadTimeout=0,SM.onerror={},SM.reboot()},onready:function(){a.playlist.init(),a.ui.init()}})},a.sound=function(b,c,d,e,f){var g=null;b="undefined"==typeof b?a.state.i:b,c="undefined"==typeof c?a.state.pl:c,d="undefined"==typeof d?a.track(b,c):d,e="undefined"==typeof e?a.info(d):e;var h=SM.getSoundById("sound"+e.id),i="object"==typeof h?h:SM.createSound({id:"sound"+e.id,url:e.mp3.replace("/file/","/listen/"),onload:function(){2==this.readyState&&(SM.stopAll(),a.next(!0))},onstop:function(){this.destruct()},onplay:function(){this.dur=this.durationEstimate;var b=3!=this.readyState?"0":"100%";$(a.ui.css.progress.loaded).css({width:b}),this.position>0&&this.setPosition(0);var c=a.time(this.dur);$(a.ui.css.progress.time).text("0:00"),$(a.ui.css.progress.total).text(c)},onfinish:function(){this.isHTML5&&a.next(!0)},whileloading:function(){if(this.active){this.dur=this.durationEstimate;var b=(this.bytesLoaded/this.bytesTotal*100).toFixed(2);$(a.ui.css.progress.loaded).css({width:b+"%"})}},whileplaying:function(){if(this.active){this.dur=this.durationEstimate;var b=(this.position/this.dur*100).toFixed(2),d=a.time(this.position),e=parseInt(this.dur)-parseInt(this.position),f=a.time(this.dur);this.position<100&&a.ui.notify(a.data.text.loading,1),a.ui.seek.animated||$(a.ui.css.progress.position).css({width:b+"%"}),$(a.ui.css.progress.time).text(d),$(a.ui.css.progress.total).text(f),a.state.position=this.position}this.isHTML5||(e<a.crossfade.preload&&a.state.cf&&"object"!=typeof g&&(g=a.sound(a.get_next(),c),g.load()),e<a.crossfade.duration&&a.state.cf&&(a.next(!0),"repeat"!=a.state.mode&&(this.active=!1,a.crossfade.fade_out(this))))}});return"load"==f&&i.load(),i},a.play=function(b,c){var g,h,d=a.state.sound,e=a.state.sound,f=parseInt((new Date).getTime());b="undefined"==typeof b?0:b,c="undefined"==typeof c?"main":c,g=a.track(b,c),h=a.info(g),a.ui.notify(a.data.text.loading),d=a.sound(b,c,g,h),$(a.ui.css.progress.position).css({width:0}),a.ui.playback("play"),a.ui.update(h),a.playlist.set(b,c),a.state.pl=c,a.state.i=b,a.state.sound=d,a.state.info=h,a.state.pb="play",a.state.started=!0,a.state.paused=!1,a.state.duration=h.duration;var j=null!=e?e.id:null;d.id==j?(a.ui.seek.set(0,!0,!1),d.paused?d.resume():0==d.playState&&(d.play(),d.active=!0)):(f-a.crossfade.end<4001?SM.stopAll():a.crossfade.fade_out(e),a.crossfade.fade_in(d),a.crossfade.end=f),a.radio.update(h),$(":hover").length>0&&$.jStorage.set("player",(new Date).getTime())},a.next=function(b){if("onesongblock"==a.state.pl)return void("repeat"==a.state.mode?a.play(a.state.i,a.state.pl):a.stop());var c=a.get_next(b),d=a.state.pl,e=a.state.mode;switch(e="repeat"!=e&&"stop"!=e||b?e:"line"){case"line":a.play(c,d,!0);break;case"repeat":a.play(c,d);break;case"stop":a.stop();break;case"shuffle":a.play(c,d,!0)}(b||"user"==d)&&a.playlist.scroll(c,d)},a.prev=function(){var c,b=a.state.pl;switch(b){case"main":c=$(a.playlist.css.main.tracks);break;case"user":c=$(a.playlist.css.user.tracks);break;case"radio":c=$(a.playlist.css.radio.main.stations);break;case"radio_mini":c=$(a.playlist.css.radio.mini.stations)}var d=c.length,e=c.filter(".act").length>0,f=e?a.state.i:0,g=a.state.i,h=a.data.delay,i=a.state.pb,j="play"==i||"pause"==i?a.state.position:0;j>h&&"radio"!=b&&"radio_mini"!=b?a.ui.seek.set(0,!0,!1):(g=f>0||e?f-1:d-1,e||(g=d-1),a.play(g,b),"user"==b&&a.playlist.scroll(g,b))},a.pause=function(){var b=a.state.i,c=a.state.pl,d=a.state.sound,e=$("li.track.act, li.user-track.act").length>0;d.pause(),e&&"main"==c&&a.playlist.set(b,c,"pause"),a.ui.playback("pause"),a.state.pb="pause",a.state.paused=!0},a.resume=function(){var b=a.state.i,c=a.state.pl,d=a.state.sound,e=a.state.info,f=$("li.track.act, li.user-track.act").length>0;e.radio?(d.destruct(),a.play(a.state.i,a.state.pl)):d.resume(),f&&"main"==c&&a.playlist.set(b,c),a.ui.playback("play"),a.state.pb="play",a.state.paused=!1,$(":hover").length>0&&$.jStorage.set("player",(new Date).getTime())},a.stop=function(){a.state.started&&(SM.stopAll(),a.state.sound.unload(),a.ui.seek.set(0,!1,!1),a.ui.playback("stop"),a.playlist.set(void 0,void 0,"stop"),$(a.ui.css.progress.total).text("0:00"),$(a.ui.css.progress.loaded).css({width:"100%"}),"onesongblock"==a.state.pl&&$(".onesongblock-btns a:first").removeClass("act").html(player.data.text.playonesong),a.state.i=0,a.state.sound=null,a.state.info=null,a.state.pb="stop",a.state.started=!1,a.state.paused=!1,a.state.position=0,a.state.duration=0,iplayer.run.player_title())},a.ui={css:{player:"#fixplayer",lcd:{container:"#fixplayer-lcd",title:{container:"#fixplayer-title",artist:"#fixplayer-title b",song:"#fixplayer-title i"},notification:"#fixplayer-notification",cover:"#fixplayer-cover"},buttons:{playback:"#fixplayer-pbtns",play:"#fixplayer-pbtns-play",pause:"#fixplayer-pbtns-pause",next:"#fixplayer-pbtns-next",prev:"#fixplayer-pbtns-back",lyrics:"#fixplaylist-lyrics",add:"#fixplayer-fav_add",remove:"#fixplayer-fav_del",download:"#fixplayer-download",crossfade:"#fixplayer-cf",mode:"#fixplayer-pmod"},progress:{bar:"#fixplayer-prokrutka",placeholder:"#fixplayer-prokrutka-for_js",loaded:"#fixplayer-prokrutka b",position:"#fixplayer-prokrutka i",time:"#fixplayer-prokrutka-proshlo",total:"#fixplayer-prokrutka-dlina",lyrics_class:"fixplayer-prok-lyrics_true"},volume:{container:"#fixplayer-volume",placeholder:"#fixplayer-volume-for_js",value:"#fixplayer-volume i",mute:"#fixplayer-volume-i"}},pressed:!1,holded:!1,seek_delay:500,seek_interval:5e3,seek_timer:null,init:function(){a.ui.mode.init(),a.ui.seek.init(),a.ui.volume.init(),a.ui.buttons.init(),a.crossfade.init()},playback:function(b){"play"==b?($(a.ui.css.buttons.play).addClass("hidden"),$(a.ui.css.buttons.pause).removeClass("hidden"),a.ui.blink("stop")):"pause"==b?($(a.ui.css.buttons.pause).addClass("hidden"),$(a.ui.css.buttons.play).removeClass("hidden"),a.ui.blink("start")):"stop"==b&&($(a.ui.css.buttons.pause).addClass("hidden"),$(a.ui.css.buttons.play).removeClass("hidden"),a.ui.blink("stop")),"stop"==b&&(b="default"),0==a.state.volume?a.favicon("mute"):a.favicon(b)},update:function(b){var c=$(a.ui.css.lcd.title.artist),d=$(a.ui.css.lcd.title.song),e={artist:c.text(),song:d.text()};"undefined"!=typeof b.artist&&c.text(b.artist),"undefined"!=typeof b.song&&d.text(b.song),"undefined"!=typeof b.artist&&b.artist!=e.artist?a.ui.rotation():"undefined"!=typeof b.song&&b.song!=e.song&&a.ui.rotation(),"undefined"!=typeof b.mp3&&$(a.ui.css.buttons.download).attr("href",b.mp3)},rotation:function(){var b=$(a.ui.css.lcd.container),c=$(a.ui.css.lcd.title.artist),d=$(a.ui.css.lcd.title.song),e={artist:c.width()-b.width(),song:d.width()-b.width()},f=.03;e.artist>0?c.stop(!0,!1).stopTime("controlled").animate({textIndent:0},200).everyTime(500,"controlled",function(){c.animate({textIndent:"-"+e.artist+"px"},e.artist/f,"swing"),c.animate({textIndent:0},e.artist/f,"swing")}):c.stop(!0,!1).stopTime("controlled").animate({textIndent:0},200,"swing"),e.song>0?d.stop(!0,!1).stopTime("controlled").animate({textIndent:0},200).everyTime(500,"controlled",function(){d.animate({textIndent:"-"+e.song+"px"},e.song/f,"swing"),d.animate({textIndent:0},e.song/f,"swing")}):d.stop(!0,!1).stopTime("controlled").animate({textIndent:0},200,"swing")},mode:{modes:["line","repeat","shuffle","stop"],init:function(){var b=null!=readCookie("mode")?readCookie("mode"):a.state.mode;a.ui.mode.set(b,!1),$(a.ui.css.buttons.mode).click(function(b){a.ui.mode.set(),b.preventDefault()}).disableSelection()},set:function(b,c){var d=$(a.ui.css.buttons.mode),e=a.ui.mode.modes,f=a.state.mode,g=e.indexOf(f)+1,h=g>=e.length?e[0]:e[g],i=e.join(" ");b="undefined"==typeof b?h:b,c="undefined"==typeof c||c,d.removeClass(i).addClass(b),a.state.mode=b,createCookie("mode",b,100),c&&a.ui.notify(a.data.text.mode.prefix+"<strong>"+a.data.text.mode[b]+"</strong>")}},seek:{pressed:!1,animated:!1,inside:!1,init:function(){$(document).bind({mousemove:function(b){if(1==a.ui.seek.pressed&&0==a.ui.seek.inside){var c=$(a.ui.css.progress.placeholder).width(),d=b.pageX-$(a.ui.css.progress.placeholder).offset().left,e=(d/c*100).toFixed(2);a.ui.seek.set(e,!1,!0)}},mouseup:function(){a.ui.seek.pressed=!1}}),$(a.ui.css.progress.placeholder).bind({mousedown:function(b){b=fixEvent(b,this),a.ui.seek.pressed=!0;var c=$(this).width(),d=b.pageX-$(this).offset().left,e=(d/c*100).toFixed(2);a.ui.seek.set(e),b.stopPropagation(),b.preventDefault()},mousemove:function(b){if(a.ui.seek.inside=!0,a.ui.seek.pressed){b=fixEvent(b,this);var c=$(this).width(),d=b.pageX-$(this).offset().left,e=(d/c*100).toFixed(2);a.ui.seek.set(e,!1),$(this).css({cursor:"e-resize"})}else $(this).css({cursor:"default"})},mouseleave:function(){a.ui.seek.inside=!1},mouseup:function(){a.ui.seek.pressed=!1}}),a.ui.seek.set(0,!1,!1),$(a.ui.css.progress.text).disableSelection()},set:function(b,c,d){var e=a.state.sound,f=$(a.ui.css.progress.position),g=$(a.ui.css.progress.time),h=0;c="undefined"==typeof c||c,d="undefined"==typeof d||d,loaded=0,null!==e&&(h=(e.durationEstimate/100*b).toFixed(),h<0&&(h=0),h>e.durationEstimate&&(h=e.durationEstimate),b<0&&(b=0),b>100&&(b=100),loaded=(e.bytesLoaded/e.bytesTotal*100).toFixed(),b=parseInt(b)>parseInt(loaded)?loaded:b,c?(a.ui.seek.animated=!0,f.stop(!0,!1).animate({width:b+"%"},100,function(){a.ui.seek.animated=!1})):f.stop(!0,!1).css({width:b+"%"}),d&&a.ui.notify(a.data.text.seek+parseInt(b).toFixed()+"%",1),g.text(a.time(h)),e.setPosition(h),a.state.paused&&(a.state.position=h))},forward:function(b){var f,g,c=parseInt(a.state.position),d=parseInt(a.state.duration),e=a.ui.seek_interval;f=c+e,g=(f/d*100).toFixed(),b="undefined"==typeof b||b,clearTimeout(a.ui.quick_seek_timer),a.ui.quick_seek_timer=setTimeout(function(){parseInt(g)>99?a.next(!0):a.ui.seek.set(g,b)},100)},rewind:function(b){var f,g,c=a.state.position,d=a.state.duration,e=a.ui.seek_interval;f=c-e,g=(f/d*100).toFixed(),g=g<0?0:g,b="undefined"==typeof b||b,clearTimeout(a.ui.quick_seek_timer),a.ui.quick_seek_timer=setTimeout(function(){a.ui.seek.set(g,b)},100)}},volume:{pressed:!1,inside:!1,init:function(){var b=null!=readCookie("volume")?readCookie("volume"):a.state.volume,c=null!=readCookie("muted")&&readCookie("muted");a.ui.volume.set(b,!1,!1),c!==!1&&(a.state.unmute=c,a.state.muted=!0),document.onmousemove=function(b){if(b=fixEvent(b,this),1==a.ui.volume.pressed&&0==a.ui.volume.inside){var c=$(a.ui.css.volume.placeholder),d=c.width(),e=b.pageX-c.offset().left,f=(e/d*100).toFixed(2);a.ui.volume.set(f,!1,!0)}},document.onmouseup=function(){a.ui.volume.pressed=!1},$(a.ui.css.volume.placeholder).bind({mousedown:function(b){b=fixEvent(b,this),a.ui.volume.pressed=!0;var c=$(this).width(),d=b.pageX-$(this).offset().left,e=(d/c*100).toFixed(2);a.ui.volume.set(e),b.stopPropagation(),b.preventDefault()},mousemove:function(b){if(a.ui.volume.inside=!0,a.ui.volume.pressed){b=fixEvent(b,this);var c=$(this).width(),d=b.pageX-$(this).offset().left,e=(d/c*100).toFixed(2);a.ui.volume.set(e,!1,!0)}},mouseleave:function(){a.ui.volume.inside=!1},mouseup:function(){a.ui.volume.pressed=!1}}).disableSelection(),$(a.ui.css.player).bind({mousewheel:function(b,c){c<0?a.ui.volume.set("-"):c>0&&a.ui.volume.set("+"),b.preventDefault()}}),$(a.ui.css.volume.mute).click(function(b){var c=a.state.muted;c?a.ui.volume.unmute():a.ui.volume.mute(),b.preventDefault()})},set:function(b,c,d){var e=$(a.ui.css.volume.mute),f=$(a.ui.css.volume.value),g=a.state.sound,h=a.state.pb,i=parseInt(a.state.volume);"+"==b?b=i+5:"-"==b&&(b=i-5),b=parseInt(b)>100?100:parseInt(b).toFixed(),b=parseInt(b)<0?0:parseInt(b).toFixed(),c="undefined"==typeof c||c,d="undefined"==typeof d||d,null!=g&&(g.unmute(),g.setVolume(b)),a.state.volume=b,a.state.unmute=b,a.state.muted=!1,createCookie("volume",b,100),eraseCookie("muted"),c?f.stop(!0,!1).animate({width:b+"%"},100):f.css({width:b+"%"}),d&&a.ui.notify(a.data.text.volume+b+"%",1),0==b?e.attr("class","i0"):b>0&&b<35?e.attr("class","i1"):b>34&&b<75?e.attr("class","i2"):(b>74||100==b)&&e.attr("class","i3"),0==b?a.favicon("mute"):0==i&&a.favicon(h.replace("stop","default"))},mute:function(){var b=a.state.volume;a.ui.volume.set(0,!0,!1),a.ui.notify(a.data.text.mute),a.state.unmute=b,a.state.muted=!0,createCookie("muted",b,100)},unmute:function(){a.ui.volume.set(a.state.unmute)}},buttons:{init:function(){a.ui.buttons.playback(),a.ui.buttons.media(),a.ui.buttons.add(),a.ui.buttons.lyrics()},playback:function(){$(a.ui.css.buttons.playback).bind({mousedown:function(b){var c=b.target.id,d={next:a.ui.css.buttons.next.replace("#",""),prev:a.ui.css.buttons.prev.replace("#","")};c!=d.next&&c!=d.prev||(a.ui.pressed=(new Date).getTime(),a.ui.seek_timer=window.setInterval(function(){var b=(new Date).getTime();a.ui.pressed&&b-a.ui.pressed>a.ui.seek_delay&&(a.ui.holded=!0,c==d.next?a.ui.seek.forward():c==d.prev&&a.ui.seek.rewind())},300)),b.preventDefault()},mouseleave:function(){a.ui.pressed=!1,clearInterval(a.ui.seek_timer)},mouseup:function(b){b=fixEvent(b);var c=b.target.id,d={play:a.ui.css.buttons.play.replace("#",""),pause:a.ui.css.buttons.pause.replace("#",""),next:a.ui.css.buttons.next.replace("#",""),prev:a.ui.css.buttons.prev.replace("#","")};a.ui.pressed=!1,clearInterval(a.ui.seek_timer),c==d.play?$(".act").length>0?a.resume():a.state.started?a.play():$(a.playlist.css.user.tracks).length>0?a.play(0,"user"):$(".onesongblock-btns").length?a.play($(".onesongblock-btns a:first"),"onesongblock"):a.play(0,"main"):c==d.pause?a.pause():c==d.next?(a.ui.holded||a.next(),a.ui.holded=!1):c==d.prev&&(a.ui.holded||a.prev(),a.ui.holded=!1),b.preventDefault()},click:function(a){a.preventDefault()}})},media:function(){$(document).keydown(function(b){var c=b.keyCode,d=b.ctrlKey;$("input:text:focus, input:password:focus, textarea:focus").length>0||d||(179==c||80==c||88==c?($(a.ui.css.buttons.play+":not(.hidden),"+a.ui.css.buttons.pause+":not(.hidden)").trigger("mouseup"),b.preventDefault()):177==c||90==c?(a.prev(),b.preventDefault()):176==c||67==c?(a.next(),b.preventDefault()):37==c?(a.ui.seek.rewind(!1),b.preventDefault()):39==c?(a.ui.seek.forward(!1),b.preventDefault()):77==c?($(a.ui.css.volume.mute).click(),b.preventDefault()):89==c?(a.ui.mode.set(),b.preventDefault()):70==c&&($(a.data.css.search).val("").focus(),$(window).scrollTop(0),b.preventDefault()))})},add:function(){$(a.ui.css.buttons.add).click(function(b){var c=a.state.info,d=a.state.started;d&&(a.playlist.user_pl.add(c),a.ui.notify(a.data.text.added)),b.preventDefault()})},lyrics:function(){$(a.ui.css.buttons.lyrics).click(function(b){var c=$(this).data("id");a.lyrics(c),b.preventDefault()})}},notify:function(b,c){var d=$(a.ui.css.lcd.container),e=$(a.ui.css.lcd.notification);c="undefined"==typeof c?parseInt(2400):parseInt(1e3*c+400),e.html(b),d.addClass("notify"),clearTimeout(a.ui.notify_timer),a.ui.notify_timer=setTimeout(function(){d.removeClass("notify")},c)},blink:function(b){b="undefined"==typeof b?"start":b,"start"==b?$(a.ui.css.lcd.title.container).everyTime(1e3,"controlled",function(){$(this).animate({opacity:.1},1e3),$(this).animate({opacity:1},1e3)}):$(a.ui.css.lcd.title.container).stop(!0).stopTime("controlled").animate({opacity:1},100)}},a.playlist={css:{tools:{container:"#playlist-tools",reload:"#reload",edit:"#playlist-edit",scroll:"#inf-scroll"},pagination:{container:"ul.listalka1"},main:{list:"#playlist",track:"li.track",tracks:"#playlist li.track",play:"a.player-playback",download:"a.playlist-down",add:"a.z-icon-fav_false",lyrics:"a.player-text",lyrics_container:".playlist-lyrics"},user:{list:"#usbl-my_fav",track:"li.user-track",tracks:"#usbl-my_fav li.user-track",remove:"a.z-icon-mdel",ul:"#usbl-my_fav",empty:"#usbl-my_fav_empty, .banner_usbl_banner"},radio:{main:{list:"#playlist-radio",station:".radio-station",stations:"#playlist-radio .radio-station"},mini:{list:"#playlist-radio-mini",station:".radio-station-mini",stations:"#playlist-radio-mini .radio-station-mini"}},all:{list:"#playlist, #usbl-my_fav",tracks:"li.track, li.user-track",stations:"li.radio-station, li.radio-station-mini",tracks_stations:"li.track, li.user-track, li.radio-station, li.radio-station-mini"}},init:function(){a.playlist.reindex(),a.playlist.events(),a.playlist.user_pl.init()},tracks:function(b){var c,d=[];return b="undefined"==typeof b?"main":b,c="main"==b?$(a.playlist.css.main_tracks):$(a.playlist.css.user.tracks),c.each(function(b){d[b]=a.info($(this))}),d},reindex:function(){$(a.playlist.css.main.tracks).each(function(a){$(this).data("index",a),$(this).attr("data-index",a)}),$(a.playlist.css.user.tracks).each(function(a){$(this).data("index",a),$(this).attr("data-index",a)}),a.state.i=a.playlist.act(),$(".nanoscroller").nanoScroller(),a.playlist.empty()},empty:function(){var b=$(a.playlist.css.user.empty),c=$(a.playlist.css.user.tracks);c.length>0?b.addClass("hidden"):b.removeClass("hidden")},act:function(){if("onesongblock"==a.state.pl)return 0;var b=a.state.pl,c="main"==b?$(a.playlist.css.main.tracks):$(a.playlist.css.user.tracks),d=c.filter(".act").length>0?parseInt(c.filter(".act").data("index")):0;return d},set:function(b,c,d){var e="act";c="undefined"==typeof c?"main":c,d="undefined"==typeof d?"play":d;var f=a.track(b,c);if($("li.act").removeClass(e),$(a.playlist.css.main.play).removeClass("playlist-pause").addClass("playlist-play"),"stop"!=d)switch(c){case"main":f.addClass(e);var g=f.find(a.playlist.css.main.play);"pause"==d?g.removeClass("playlist-pause").addClass("playlist-play"):"play"==d&&g.removeClass("playlist-play").addClass("playlist-pause");break;default:f.addClass(e)}},scroll:function(a,b){},events:function(){$(document).on("click",a.playlist.css.all.tracks,function(b){var c=$(this).data("index"),d=$(this).hasClass("track")?"main":"user",e=player.state.paused,f=!!$(this).hasClass("act");f?e?a.resume():a.pause():a.play(c,d),b.preventDefault()}),$(document).on("click",a.playlist.css.main.download,function(a){a.stopPropagation()}),$(document).on("click",a.playlist.css.main.add,function(b){var c=a.info($(this).parent("em").parent(a.playlist.css.main.track));a.playlist.user_pl.add(c),b.stopPropagation(),b.preventDefault()}),$(document).on("click",a.playlist.css.user.remove,function(b){var c=$(this).parent("em").parent(a.playlist.css.user.track).data("index");a.playlist.user_pl.remove(c),b.stopPropagation(),b.preventDefault()}),$(document).on("click",a.playlist.css.main.lyrics,function(b){var c=$(this).parent("em").parent(a.playlist.css.main.track);$(this).is(".active")?($(this).removeClass("active"),c.find(a.playlist.css.main.lyrics_container).hide()):$(this).is(":not(.active)")&&($(this).addClass("active"),a.pl_lyrics(c)),b.stopPropagation(),b.preventDefault()}),$(document).on("click",a.playlist.css.main.lyrics_container,function(a){a.stopPropagation(),a.preventDefault()}),$(a.playlist.css.main.track).live({mouseenter:function(){var a=$(this),b=$(this).find(".playlist-title a"),c=b.width()-a.width()+120,d=c/.04;c>0&&b.everyTime(1e3,"controlled",function(){b.animate({marginLeft:"-"+c+"px"},d,"linear"),b.animate({marginLeft:0},d,"linear")})},mouseleave:function(){var a=$(this).find(".playlist-title a");a.stop(!0,!1).stopTime("controlled").animate({marginLeft:0},200)}}),$(document).on("click",a.playlist.css.all.stations,function(b){var c=$(this).data("index"),d=$(this).hasClass("radio-station")?"radio":"radio_mini",e=player.state.paused,f=!!$(this).hasClass("act");f?e?a.resume():a.pause():a.play(c,d),b.preventDefault()}),$(document).on("click",".js-link",function(a){var b=$(this).data("href");console.log("jsLinkUrl = "+b),b&&window.open(b,"_blank")})},tools:function(){a.playlist.sortable(!0),null!=readCookie("infinite_scroll")&&a.playlist.infinite(!0),$(a.playlist.css.tools.container).disableSelection(),$(a.playlist.css.tools.reload).click(function(){History.pushState(null,document.title,window.location.href),event.preventDefault()}),$(a.playlist.css.tools.edit).click(function(b){var c=null!=readCookie("playlist_sortable");c?a.playlist.sortable(!1):a.playlist.sortable(!0),b.preventDefault()}),$(a.playlist.css.tools.scroll).click(function(b){var c=null!=readCookie("infinite_scroll");c?a.playlist.infinite(!1):a.playlist.infinite(!0),b.preventDefault()})},activate:function(){var c,b=null!=a.state.info&&a.state.info.id,d=a.state.paused?"pause":"play",e=a.state.pl;"user"!=e&&b&&(c=$(a.playlist.css.all.tracks_stations).filter('li[data-id="'+b+'"]').filter(":first"),c.length>0&&a.playlist.set(c.data("index"),e,d))},sortable:function(b){b="undefined"==typeof b||b,b?($(a.playlist.css.tools.edit).addClass("active"),createCookie("playlist_sortable","true",100),$(a.playlist.css.main.list).sortable("destroy").sortable({axis:"y",revert:100,handle:".playlist-move",update:function(b,c){a.playlist.reindex()}})):($(a.playlist.css.tools.edit).removeClass("active"),eraseCookie("playlist_sortable"),$(a.playlist.css.main.list).sortable("destroy"))},infinite:function(b){if(b="undefined"==typeof b||b){var c=$(a.playlist.css.pagination.container),d=c.length>0,e=$(a.playlist.css.main.list);$(a.playlist.css.tools.scroll).addClass("active"),createCookie("infinite_scroll","true",100),$(window).unbind("scroll",a.playlist.IShandler),a.playlist.IShandler=function(b){c=$(a.playlist.css.pagination.container);var d=parseInt($(window).scrollTop())+parseInt($(window).height()+200),f=parseInt(c.offset().top),g=$("body.loading").length>0,h=!!c.data("next-page")&&c.data("next-page");d>f&&!g&&h&&(a.infinite_request=$.ajax({type:"GET",url:h,beforeSend:function(){"object"==typeof a.infinite_request&&a.infinite_request.abort(),c.slideUp(200),$("body").addClass("loading")},success:function(b){var d=$(b).find(a.playlist.css.main.tracks),f=$(b).find(a.playlist.css.pagination.container);e.append(d),c.replaceWith(f),a.playlist.reindex(),$("body").removeClass("loading")},dataType:"html"}))},d&&$(window).bind("scroll",a.playlist.IShandler)}else $(a.playlist.css.tools.scroll).removeClass("active"),eraseCookie("infinite_scroll"),$(window).unbind("scroll",a.playlist.IShandler)},user_pl:{ajax:!1,init:function(){$(".nanoscroller").nanoScroller(),a.playlist.user_pl.sortable()},add:function(b){var c=$('<li class="user-track" data-index="" data-id="'+b.id+'" data-mp3="'+b.mp3+'" data-duration="'+b.duration+'"><div class="playlist-title"><b><span>'+b.artist+'</span></b> - <a href="#" class="no-ajaxy"><span>'+b.song+'</span></a></div><em><a href="#" class="z-icon-mdel no-ajaxy" title="удалить из избранного">(удалить)</a>'+player.time(b.duration)+"</em></li>");playlist=a.playlist.css.user.ul,c.prependTo(playlist).css({display:"none"}).slideDown(100),a.playlist.user_pl.save(),a.playlist.user_pl.sortable()},remove:function(b){var c=$(a.playlist.css.user.tracks).eq(b);c.animate({height:0},100,function(){$(this).remove(),a.playlist.user_pl.save(),a.playlist.user_pl.sortable()})},save:function(){var b=a.data.url.save_pl,c=[];$(a.playlist.css.user.tracks).each(function(a){c[a]=$(this).data("id")}),c=implode(",",c),a.playlist.reindex(),$.ajax({type:"POST",url:b,data:{tracks:c}})},sortable:function(){$(a.playlist.css.user.ul).sortable("destroy").sortable({axis:"y",revert:100,update:function(){a.playlist.user_pl.save()}})}}},a.radio={interval:1e4,update:function(b){b.radio&&b.cover?$(a.ui.css.lcd.cover).html('<img src="'+b.cover+'" alt="'+b.artist+'" />'):$(a.ui.css.lcd.cover).html(""),b.radio&&b.now&&a.radio.rds.start(),b.radio?$(a.ui.css.player).addClass("is-radio"):$(a.ui.css.player).removeClass("is-radio")},rds:{start:function(){a.radio.rds.get(),a.radio.rds.stop(),a.radio.timer=setInterval(function(){a.radio.rds.get()},a.radio.interval)},stop:function(){clearInterval(a.radio.timer)},get:function(){a.state.info.radio&&a.state.info.now&&$.ajax({type:"GET",url:a.state.info.now,dataType:"json",success:function(b){b.song&&b.artist&&a.ui.update(b)}})}}},a.crossfade={duration:3e3,preload:15e3,tail:null,end:0,init:function(b){null!=readCookie("crossfade_disabled")?a.crossfade.set(!1,!0):a.crossfade.set(!0,!0),b="undefined"!=typeof b&&b,b||$(a.ui.css.buttons.crossfade).click(function(b){var c=null==readCookie("crossfade_disabled");c?a.crossfade.set(!1):a.crossfade.set(!0),b.preventDefault()}).disableSelection()},set:function(b,c){b="undefined"==typeof b||b,c="undefined"!=typeof c&&c;var d=$(a.ui.css.buttons.crossfade);b?(d.addClass("on"),c||a.ui.notify(a.data.text.cf.on),eraseCookie("crossfade_disabled"),a.state.cf=!0):(d.removeClass("on"),c||a.ui.notify(a.data.text.cf.off),createCookie("crossfade_disabled","true",100),a.state.cf=!1)},fade_out:function(b){if(null!=b){var c=a.state.cf,d=parseInt((new Date).getTime()),e=parseInt(a.crossfade.duration),f=d+e,g=b.volume;b.active=!1,clearInterval(b.cf_out_timer),b.cf&&clearInterval(b.cf_in_timer),b.setVolume(g),c?b.cf_out_timer=window.setInterval(function(){var a=(new Date).getTime();if(a<f){var c=((f-a)/e*g).toFixed();b.setVolume(c),b.cf=!0}else clearInterval(b.cf_out_timer),b.unload().stop(),b.cf=!1},50):b.unload().stop()}},fade_in:function(b){if(null!=b){var c=a.state.cf,d=parseInt((new Date).getTime()),e=parseInt(a.crossfade.duration),f=d+e,g=parseInt(a.state.volume);b.active=!0,c?(clearInterval(b.cf_in_timer),b.cf&&clearInterval(b.cf_out_timer),b.setVolume(0),b.play(),b.cf_in_timer=window.setInterval(function(){var a=parseInt((new Date).getTime());if(a<f){var c=(g-(f-a)/e*g).toFixed();b.setVolume(c),b.cf=!0}else clearInterval(b.cf_in_timer),b.setVolume(g),b.cf=!1},50)):(b.setVolume(g),b.play())}}},a.lyrics=function(b){var c=a.data.url.lyrics,d=$(a.data.css.lyrics);isNaN(b)||(a.lyrics.request=$.ajax({type:"POST",url:c,data:{id:b},success:function(a){d.html(""),d.append(a),$.fn.colorbox({width:"460px",height:"600px",maxWidth:"95%",maxHeight:"95%",href:"#lyrics",inline:!0,fixed:!0})},beforeSend:function(){"object"==a.lyrics.request&&a.lyrics.request.abort(),$("body").addClass("loading")},complete:function(){$("body").removeClass("loading")},dataType:"html"}))},a.pl_lyrics=function(b){var c=a.data.url.lyrics,d=b.find(a.playlist.css.main.lyrics_container).length>0,e=b.data("lyrics-id");d?b.find(a.playlist.css.main.lyrics_container).show():a.lyrics.request=$.ajax({type:"POST",url:c,data:{id:e},success:function(a){b.append('<div class="playlist-lyrics">'+a+"</div>")},beforeSend:function(){"object"==a.lyrics.request&&a.lyrics.request.abort(),$("body").addClass("loading")},complete:function(){$("body").removeClass("loading")},dataType:"html"})},a.check=function(b,c,d){clearTimeout(a.error_timer),$.ajax({url:b,type:"head",crossDomain:!1,error:function(){a.error_timer_count="undefined"==typeof a.error_timer_count?1:parseInt(a.error_timer_count)+1;var e=a.error_timer_count;e<3?a.error_timer=setTimeout(function(){a.check(b,c,d)},1500):a.error_timer_count>2&&(a.error_timer_count=0,c.css({opacity:.3}),a.ui.notify(a.data.text.unavailable),d.destruct(),a.next(!0))},success:function(){c.css({opactity:1})}})},a.get_next=function(b){var d,c=a.state.pl;switch(c){case"main":d=$(a.playlist.css.main.tracks);break;case"user":d=$(a.playlist.css.user.tracks);break;case"radio":d=$(a.playlist.css.radio.main.stations);break;case"radio_mini":d=$(a.playlist.css.radio.mini.stations)}var e=d.length,f=d.filter(".act").length>0,g=f?a.state.i:0,h=null,i=a.state.mode;switch(i="repeat"!=i&&"stop"!=i||b?i:"line"){case"line":h=g+1,(h+1>e||!f)&&(h=0);break;case"repeat":h=g;break;case"stop":h=g;break;case"shuffle":h=Math.floor(Math.random()*e),h==g&&(h=Math.floor(Math.random()*e)),h==g&&(h=Math.floor(Math.random()*e))}return h},a.track=function(b,c){var d;switch(c){case"main":d=$(a.playlist.css.main.tracks).eq(b);break;case"user":d=$(a.playlist.css.user.tracks).eq(b);break;case"onesongblock":d=b;break;case"radio":d=$(a.playlist.css.radio.main.stations).eq(b);break;case"radio_mini":d=$(a.playlist.css.radio.mini.stations).eq(b)}return d},a.info=function(b){if(b.closest(".onesongblock").length)return{index:-1,mp3:b.data("mp3"),id:b.data("id"),duration:parseInt(b.data("duration")),artist:b.parent().parent().find("h1 b").text(),song:b.parent().parent().find("h1 em").text()};var c=!(!b.hasClass("radio-station")&&!b.hasClass("radio-station-mini"));return{index:b.data("index"),mp3:b.data("mp3"),id:b.data("id"),
duration:b.data("duration"),artist:c?b.find(".playlist-title").text():b.find(".playlist-title b:first-child span").text(),song:c?a.data.text.loading:b.find(".playlist-title a:nth-child(2) span").text(),radio:c,now:!!c&&b.data("now"),cover:!!(c&&b.find("img").length>0)&&b.find("img").attr("src"),lyrics:b.data("lyrics-id")}},a.favicon=function(b){var c="default"==b?"/favicon.ico":a.data.url.favicon.replace("%mode%",b);$('link[rel$="icon"]').remove(),$("head").append('<link rel="shortcut icon" type="image/x-icon" href="'+c+'" />')},a.time=function(a){a/=1e3;var b=parseInt(a/60,10),c=parseInt(a-60*b,10);1==String(c).length&&(c="0"+c);var d=b+":"+c;return d},a.notify=function(a,b,c,d){var e={text:"undefined"==typeof a?"":"<p>"+a+"</p>",caption:"undefined"==typeof d?"":"<h4>"+d+"</h4>",type:"undefined"==typeof b?"info":b,time:"undefined"==typeof c?3:c},f=document.createElement("div");$("#notifications").length<1&&$(document.body).append('<div id="notifications"></div>'),$(f).css("display","none").addClass("notification").addClass("notification-"+e.type).html(e.caption+e.text).appendTo($("#notifications")).slideDown(200),setTimeout(function(){$(f).animate({opacity:0,height:0},200,function(){$(f).remove()})},1e3*e.time)}}function iframeDataURITest(){var a,b=document.createElement("iframe");b.style.display="none",b.setAttribute("src","data:text/html;base64,Kg=="),document.body.appendChild(b);try{a=!!b.contentDocument}catch(b){a=!1}return document.body.removeChild(b),a}function iPlayer(){var a=this;a.data={css:{search:{form:"#search-form",value:"#search-value",submit:"#search-submit",submitter:"#search-submitter",cleaner:"#search-cleaner"},player_title:"#player-page-title"},url:{search:"/public/api.search.php"},text:{loading:"Загрузка..."}},a.init=function(){a.run.navigation(),a.run.storage(),a.history()},a.history=function(){a.loadOnesongBlock(),a.run.search(),a.run.selects(),a.run.colorbox(),a.run.liru(),a.run.metrikaHit(),a.run.player_title(),player.playlist.tools(),player.playlist.activate(),$(window).scrollTop(0)},a.run={navigation:function(){$(document.body).append('<span id="load-indicator">'+a.data.text.loading+"</span>")},search:function(){var b=$(a.data.css.search.form),c=$(a.data.css.search.value),d=$(a.data.css.search.submit),e=$(a.data.css.search.submitter),f=c.data("placeholder"),g=$(a.data.css.search.cleaner);window.history&&history.pushState&&b.bind({submit:function(b){var f=$(a.data.css.search.value).val().replace("/","").replace(/&/g,"&"),g=a.data.url.search;f!=c.val()&&(c.attr("disabled",!0),d.attr("disabled",!0)),$.ajax({type:"POST",url:g,data:{q:f},success:function(a){e.attr("href",a).click()},dataType:"html"}),c.blur(),b.preventDefault()}}),c.bind({focus:function(){c.val()==f&&c.val(""),c.val().length>0?g.removeClass("hidden"):g.addClass("hidden")},blur:function(){""==c.val()&&c.val(f)},keyup:function(){c.val().length>0?g.removeClass("hidden"):g.addClass("hidden")}}),g.bind({click:function(a){$(this).addClass("hidden"),c.val("").focus(),a.preventDefault()}})},storage:function(){var a=$.jStorage;a.storageAvailable()&&a.listenKeyChange("player",function(a,b){"updated"==b&&0==$(":hover").length&&player.pause()})},selects:function(){$(".rselect select:not(.rselect-ready)").each(function(){var a=""!=$("option:selected",this).val()?$("option:selected",this).text():$(this).attr("title");$(this).addClass("rselect-ready").css({"z-index":10,opacity:0,"-khtml-appearance":"none"}).after('<span class="select">'+a+"</span>").change(function(){val=$("option:selected",this).text(),$(this).next().text(val)})}),$("select.rtform:not(.rselect-ready)").addClass("rselect-ready").wrap('<span class="select"></span>')},colorbox:function(){$(".cb-img").colorbox(),$(".cb-html").colorbox({inline:!0}),$(".cb-lyrics").colorbox({inline:!0,maxWidth:"70%",maxHeight:"95%"})},liru:function(){var a="undefined"!=typeof window.custom_ref?window.custom_ref:document.referrer;(new Image).src="//counter.yadro.ru/hit;xn--41a-ws?r"+escape(a)+("undefined"==typeof screen?"":";s"+screen.width+"*"+screen.height+"*"+(screen.colorDepth?screen.colorDepth:screen.pixelDepth))+";u"+escape(document.URL)+";"+Math.random()},metrikaHit:function(){if("undefined"!=typeof yaCounter123){var a="undefined"!=typeof window.custom_ref?window.custom_ref:document.referrer;yaCounter123.hit(document.URL,null,a)}},player_title:function(){var b=$(a.data.css.player_title),c=function(){b.length>0&&"stop"==player.state.pb&&player.ui.update({artist:b.find("b").html(),song:b.find("span").html()})};"object"==typeof player?c():SM.onready=c()}},a.loadOnesongBlock=function(){var a=window.location.pathname.split('/');a[1]=parseInt(a[2]);if(a&&a.length==5){var b=0;if(player.state.info&&"undefined"!=typeof player.state.info.id&&(b=player.state.info.id,"main"==player.state.pl&&(player.state.pl="onesongblock")),b==a[1]){var c=player.state.paused?player.data.text.playonesong:player.data.text.pauseonesong;$(".onesongblock-btns a:first").addClass("act").html(c)}$(".onesongblock-btns a:first").on("click",function(){var b=0;if(player.state.info&&"undefined"!=typeof player.state.info.id&&(b=player.state.info.id),b!=a[1])player.play($(this),"onesongblock"),$(this).html(player.data.text.pauseonesong);else{var c=player.state.paused;c?($(this).html(player.data.text.pauseonesong),player.resume()):($(this).html(player.data.text.playonesong),player.pause())}})}else"undefined"!=typeof player&&"onesongblock"==player.state.pl&&(player.state.pl="main")}}!function(a,b){function c(a){var b=oa[a]={};return $.each(a.split(ba),function(a,c){b[c]=!0}),b}function d(a,c,d){if(d===b&&1===a.nodeType){var e="data-"+c.replace(qa,"-$1").toLowerCase();if(d=a.getAttribute(e),"string"==typeof d){try{d="true"===d||"false"!==d&&("null"===d?null:+d+""===d?+d:pa.test(d)?$.parseJSON(d):d)}catch(a){}$.data(a,c,d)}else d=b}return d}function e(a){var b;for(b in a)if(("data"!==b||!$.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function f(){return!1}function g(){return!0}function h(a){return!a||!a.parentNode||11===a.parentNode.nodeType}function i(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}function j(a,b,c){if(b=b||0,$.isFunction(b))return $.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return $.grep(a,function(a,d){return a===b===c});if("string"==typeof b){var d=$.grep(a,function(a){return 1===a.nodeType});if(Ka.test(b))return $.filter(b,d,!c);b=$.filter(b,d)}return $.grep(a,function(a,d){return $.inArray(a,b)>=0===c})}function k(a){var b=Na.split("|"),c=a.createDocumentFragment();if(c.createElement)for(;b.length;)c.createElement(b.pop());return c}function l(a,b){return a.getElementsByTagName(b)[0]||a.appendChild(a.ownerDocument.createElement(b))}function m(a,b){if(1===b.nodeType&&$.hasData(a)){var c,d,e,f=$._data(a),g=$._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;d<e;d++)$.event.add(b,c,h[c][d])}g.data&&(g.data=$.extend({},g.data))}}function n(a,b){var c;1===b.nodeType&&(b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase(),"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),$.support.html5Clone&&a.innerHTML&&!$.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&Xa.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.selected=a.defaultSelected:"input"===c||"textarea"===c?b.defaultValue=a.defaultValue:"script"===c&&b.text!==a.text&&(b.text=a.text),b.removeAttribute($.expando))}function o(a){return"undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName("*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll("*"):[]}function p(a){Xa.test(a.type)&&(a.defaultChecked=a.checked)}function q(a,b){if(b in a)return b;for(var c=b.charAt(0).toUpperCase()+b.slice(1),d=b,e=rb.length;e--;)if(b=rb[e]+c,b in a)return b;return d}function r(a,b){return a=b||a,"none"===$.css(a,"display")||!$.contains(a.ownerDocument,a)}function s(a,b){for(var c,d,e=[],f=0,g=a.length;f<g;f++)c=a[f],c.style&&(e[f]=$._data(c,"olddisplay"),b?(!e[f]&&"none"===c.style.display&&(c.style.display=""),""===c.style.display&&r(c)&&(e[f]=$._data(c,"olddisplay",w(c.nodeName)))):(d=cb(c,"display"),!e[f]&&"none"!==d&&$._data(c,"olddisplay",d)));for(f=0;f<g;f++)c=a[f],c.style&&(b&&"none"!==c.style.display&&""!==c.style.display||(c.style.display=b?e[f]||"":"none"));return a}function t(a,b,c){var d=kb.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function u(a,b,c,d){for(var e=c===(d?"border":"content")?4:"width"===b?1:0,f=0;e<4;e+=2)"margin"===c&&(f+=$.css(a,c+qb[e],!0)),d?("content"===c&&(f-=parseFloat(cb(a,"padding"+qb[e]))||0),"margin"!==c&&(f-=parseFloat(cb(a,"border"+qb[e]+"Width"))||0)):(f+=parseFloat(cb(a,"padding"+qb[e]))||0,"padding"!==c&&(f+=parseFloat(cb(a,"border"+qb[e]+"Width"))||0));return f}function v(a,b,c){var d="width"===b?a.offsetWidth:a.offsetHeight,e=!0,f=$.support.boxSizing&&"border-box"===$.css(a,"boxSizing");if(d<=0||null==d){if(d=cb(a,b),(d<0||null==d)&&(d=a.style[b]),lb.test(d))return d;e=f&&($.support.boxSizingReliable||d===a.style[b]),d=parseFloat(d)||0}return d+u(a,b,c||(f?"border":"content"),e)+"px"}function w(a){if(nb[a])return nb[a];var b=$("<"+a+">").appendTo(P.body),c=b.css("display");return b.remove(),"none"!==c&&""!==c||(db=P.body.appendChild(db||$.extend(P.createElement("iframe"),{frameBorder:0,width:0,height:0})),eb&&db.createElement||(eb=(db.contentWindow||db.contentDocument).document,eb.write("<!doctype html><html><body>"),eb.close()),b=eb.body.appendChild(eb.createElement(a)),c=cb(b,"display"),P.body.removeChild(db)),nb[a]=c,c}function x(a,b,c,d){var e;if($.isArray(b))$.each(b,function(b,e){c||ub.test(a)?d(a,e):x(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==$.type(b))d(a,b);else for(e in b)x(a+"["+e+"]",b[e],c,d)}function y(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e,f,g=b.toLowerCase().split(ba),h=0,i=g.length;if($.isFunction(c))for(;h<i;h++)d=g[h],f=/^+/.test(d),f&&(d=d.substr(1)||"*"),e=a[d]=a[d]||[],e[f?"unshift":"push"](c)}}function z(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;for(var h,i=a[f],j=0,k=i?i.length:0,l=a===Kb;j<k&&(l||!h);j++)h=i[j](c,d,e),"string"==typeof h&&(!l||g[h]?h=b:(c.dataTypes.unshift(h),h=z(a,c,d,e,h,g)));return(l||!h)&&!g["*"]&&(h=z(a,c,d,e,"*",g)),h}function A(a,c){var d,e,f=$.ajaxSettings.flatOptions||{};for(d in c)c[d]!==b&&((f[d]?a:e||(e={}))[d]=c[d]);e&&$.extend(!0,a,e)}function B(a,c,d){var e,f,g,h,i=a.contents,j=a.dataTypes,k=a.responseFields;for(f in k)f in d&&(c[k[f]]=d[f]);for(;"*"===j[0];)j.shift(),e===b&&(e=a.mimeType||c.getResponseHeader("content-type"));if(e)for(f in i)if(i[f]&&i[f].test(e)){j.unshift(f);break}if(j[0]in d)g=j[0];else{for(f in d){if(!j[0]||a.converters[f+" "+j[0]]){g=f;break}h||(h=f)}g=g||h}if(g)return g!==j[0]&&j.unshift(g),d[g]}function C(a,b){var c,d,e,f,g=a.dataTypes.slice(),h=g[0],i={},j=0;if(a.dataFilter&&(b=a.dataFilter(b,a.dataType)),g[1])for(c in a.converters)i[c.toLowerCase()]=a.converters[c];for(;e=g[++j];)if("*"!==e){if("*"!==h&&h!==e){if(c=i[h+" "+e]||i["* "+e],!c)for(d in i)if(f=d.split(" "),f[1]===e&&(c=i[h+" "+f[0]]||i["* "+f[0]])){c===!0?c=i[d]:i[d]!==!0&&(e=f[0],g.splice(j--,0,e));break}if(c!==!0)if(c&&a.throws)b=c(b);else try{b=c(b)}catch(a){return{state:"parsererror",error:c?a:"No conversion from "+h+" to "+e}}}h=e}return{state:"success",data:b}}function D(){try{return new a.XMLHttpRequest}catch(a){}}function E(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(a){}}function F(){return setTimeout(function(){Ub=b},0),Ub=$.now()}function G(a,b){$.each(b,function(b,c){for(var d=($b[b]||[]).concat($b["*"]),e=0,f=d.length;e<f;e++)if(d[e].call(a,b,c))return})}function H(a,b,c){var d,e=0,g=Zb.length,h=$.Deferred().always(function(){delete i.elem}),i=function(){for(var b=Ub||F(),c=Math.max(0,j.startTime+j.duration-b),d=1-(c/j.duration||0),e=0,f=j.tweens.length;e<f;e++)j.tweens[e].run(d);return h.notifyWith(a,[j,d,c]),d<1&&f?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:$.extend({},b),opts:$.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:Ub||F(),duration:c.duration,tweens:[],createTween:function(b,c,d){var e=$.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(e),e},stop:function(b){for(var c=0,d=b?j.tweens.length:0;c<d;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(I(k,j.opts.specialEasing);e<g;e++)if(d=Zb[e].call(j,a,k,j.opts))return d;return G(j,k),$.isFunction(j.opts.start)&&j.opts.start.call(a,j),$.fx.timer($.extend(i,{anim:j,queue:j.opts.queue,elem:a})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}function I(a,b){var c,d,e,f,g;for(c in a)if(d=$.camelCase(c),e=b[d],f=a[c],$.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=$.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function J(a,b,c){var d,e,f,g,h,i,j,k,l=this,m=a.style,n={},o=[],p=a.nodeType&&r(a);c.queue||(j=$._queueHooks(a,"fx"),null==j.unqueued&&(j.unqueued=0,k=j.empty.fire,j.empty.fire=function(){j.unqueued||k()}),j.unqueued++,l.always(function(){l.always(function(){j.unqueued--,$.queue(a,"fx").length||j.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[m.overflow,m.overflowX,m.overflowY],"inline"===$.css(a,"display")&&"none"===$.css(a,"float")&&($.support.inlineBlockNeedsLayout&&"inline"!==w(a.nodeName)?m.zoom=1:m.display="inline-block")),c.overflow&&(m.overflow="hidden",$.support.shrinkWrapBlocks||l.done(function(){m.overflow=c.overflow[0],m.overflowX=c.overflow[1],m.overflowY=c.overflow[2]}));for(d in b)if(f=b[d],Wb.exec(f)){if(delete b[d],f===(p?"hide":"show"))continue;o.push(d)}if(g=o.length)for(h=$._data(a,"fxshow")||$._data(a,"fxshow",{}),p?$(a).show():l.done(function(){$(a).hide()}),l.done(function(){var b;$.removeData(a,"fxshow",!0);for(b in n)$.style(a,b,n[b])}),d=0;d<g;d++)e=o[d],i=l.createTween(e,p?h[e]:0),n[e]=h[e]||$.style(a,e),e in h||(h[e]=i.start,p&&(i.end=i.start,i.start="width"===e||"height"===e?1:0))}function K(a,b,c,d,e){return new K.prototype.init(a,b,c,d,e)}function L(a,b){var c,d={height:a},e=0;for(b=b?1:0;e<4;e+=2-b)c=qb[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function M(a){return $.isWindow(a)?a:9===a.nodeType&&(a.defaultView||a.parentWindow)}var N,O,P=a.document,Q=a.location,R=a.navigator,S=a.jQuery,T=a.$,U=Array.prototype.push,V=Array.prototype.slice,W=Array.prototype.indexOf,X=Object.prototype.toString,Y=Object.prototype.hasOwnProperty,Z=String.prototype.trim,$=function(a,b){return new $.fn.init(a,b,N)},_=/[-+]?(?:d*.|)d+(?:[eE][-+]?d+|)/.source,aa=/S/,ba=/s+/,ca=/^[suFEFFxA0]+|[suFEFFxA0]+$/g,da=/^(?:[^#<]*(<[wW]+>)[^>]*$|#([w-]*)$)/,ea=/^<(w+)s*/?>(?:</1>|)$/,fa=/^[],:{}s]*$/,ga=/(?:^|:|,)(?:s*[)+/g,ha=/\(?:["\/bfnrt]|u[da-fA-F]{4})/g,ia=/"[^"\rn]*"|true|false|null|-?(?:dd*.|)d+(?:[eE][-+]?d+|)/g,ja=/^-ms-/,ka=/-([da-z])/gi,la=function(a,b){return(b+"").toUpperCase()},ma=function(){P.addEventListener?(P.removeEventListener("DOMContentLoaded",ma,!1),$.ready()):"complete"===P.readyState&&(P.detachEvent("onreadystatechange",ma),$.ready())},na={};$.fn=$.prototype={constructor:$,init:function(a,c,d){var e,f,h;if(!a)return this;if(a.nodeType)return this.context=this[0]=a,this.length=1,this;if("string"==typeof a){if(e="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:da.exec(a),e&&(e[1]||!c)){if(e[1])return c=c instanceof $?c[0]:c,h=c&&c.nodeType?c.ownerDocument||c:P,a=$.parseHTML(e[1],h,!0),ea.test(e[1])&&$.isPlainObject(c)&&this.attr.call(a,c,!0),$.merge(this,a);if(f=P.getElementById(e[2]),f&&f.parentNode){if(f.id!==e[2])return d.find(a);this.length=1,this[0]=f}return this.context=P,this.selector=a,this}return!c||c.jquery?(c||d).find(a):this.constructor(c).find(a)}return $.isFunction(a)?d.ready(a):(a.selector!==b&&(this.selector=a.selector,this.context=a.context),$.makeArray(a,this))},selector:"",jquery:"1.8.2",length:0,size:function(){return this.length},toArray:function(){return V.call(this)},get:function(a){return null==a?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=$.merge(this.constructor(),a);return d.prevObject=this,d.context=this.context,"find"===b?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")"),d},each:function(a,b){return $.each(this,a,b)},ready:function(a){return $.ready.promise().done(a),this},eq:function(a){return a=+a,a===-1?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(V.apply(this,arguments),"slice",V.call(arguments).join(","))},map:function(a){return this.pushStack($.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:U,sort:[].sort,splice:[].splice},$.fn.init.prototype=$.fn,$.extend=$.fn.extend=function(){var a,c,d,e,f,g,h=arguments[0]||{},i=1,j=arguments.length,k=!1;for("boolean"==typeof h&&(k=h,h=arguments[1]||{},i=2),"object"!=typeof h&&!$.isFunction(h)&&(h={}),j===i&&(h=this,--i);i<j;i++)if(null!=(a=arguments[i]))for(c in a)d=h[c],e=a[c],h!==e&&(k&&e&&($.isPlainObject(e)||(f=$.isArray(e)))?(f?(f=!1,g=d&&$.isArray(d)?d:[]):g=d&&$.isPlainObject(d)?d:{},h[c]=$.extend(k,g,e)):e!==b&&(h[c]=e));return h},$.extend({noConflict:function(b){return a.$===$&&(a.$=T),b&&a.jQuery===$&&(a.jQuery=S),$},isReady:!1,readyWait:1,holdReady:function(a){a?$.readyWait++:$.ready(!0)},ready:function(a){if(a===!0?!--$.readyWait:!$.isReady){if(!P.body)return setTimeout($.ready,1);$.isReady=!0,a!==!0&&--$.readyWait>0||(O.resolveWith(P,[$]),$.fn.trigger&&$(P).trigger("ready").off("ready"))}},isFunction:function(a){return"function"===$.type(a)},isArray:Array.isArray||function(a){return"array"===$.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return null==a?String(a):na[X.call(a)]||"object"},isPlainObject:function(a){if(!a||"object"!==$.type(a)||a.nodeType||$.isWindow(a))return!1;try{if(a.constructor&&!Y.call(a,"constructor")&&!Y.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(a){return!1}var c;for(c in a);return c===b||Y.call(a,c)},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},error:function(a){throw new Error(a)},parseHTML:function(a,b,c){var d;return a&&"string"==typeof a?("boolean"==typeof b&&(c=b,b=0),b=b||P,(d=ea.exec(a))?[b.createElement(d[1])]:(d=$.buildFragment([a],b,c?null:[]),$.merge([],(d.cacheable?$.clone(d.fragment):d.fragment).childNodes))):null},parseJSON:function(b){return b&&"string"==typeof b?(b=$.trim(b),a.JSON&&a.JSON.parse?a.JSON.parse(b):fa.test(b.replace(ha,"@").replace(ia,"]").replace(ga,""))?new Function("return "+b)():void $.error("Invalid JSON: "+b)):null},parseXML:function(c){var d,e;if(!c||"string"!=typeof c)return null;try{a.DOMParser?(e=new DOMParser,d=e.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(a){d=b}return(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&$.error("Invalid XML: "+c),d},noop:function(){},globalEval:function(b){b&&aa.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(ja,"ms-").replace(ka,la)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,c,d){var e,f=0,g=a.length,h=g===b||$.isFunction(a);if(d)if(h){for(e in a)if(c.apply(a[e],d)===!1)break}else for(;f<g&&c.apply(a[f++],d)!==!1;);else if(h){for(e in a)if(c.call(a[e],e,a[e])===!1)break}else for(;f<g&&c.call(a[f],f,a[f++])!==!1;);return a},trim:Z&&!Z.call("ufeff ")?function(a){return null==a?"":Z.call(a)}:function(a){return null==a?"":(a+"").replace(ca,"")},makeArray:function(a,b){var c,d=b||[];return null!=a&&(c=$.type(a),null==a.length||"string"===c||"function"===c||"regexp"===c||$.isWindow(a)?U.call(d,a):$.merge(d,a)),d},inArray:function(a,b,c){var d;if(b){if(W)return W.call(b,a,c);for(d=b.length,c=c?c<0?Math.max(0,d+c):c:0;c<d;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,c){var d=c.length,e=a.length,f=0;if("number"==typeof d)for(;f<d;f++)a[e++]=c[f];else for(;c[f]!==b;)a[e++]=c[f++];return a.length=e,a},grep:function(a,b,c){var d,e=[],f=0,g=a.length;for(c=!!c;f<g;f++)d=!!b(a[f],f),c!==d&&e.push(a[f]);return e},map:function(a,c,d){var e,f,g=[],h=0,i=a.length,j=a instanceof $||i!==b&&"number"==typeof i&&(i>0&&a[0]&&a[i-1]||0===i||$.isArray(a));if(j)for(;h<i;h++)e=c(a[h],h,d),null!=e&&(g[g.length]=e);else for(f in a)e=c(a[f],f,d),null!=e&&(g[g.length]=e);return g.concat.apply([],g)},guid:1,proxy:function(a,c){var d,e,f;return"string"==typeof c&&(d=a[c],c=a,a=d),$.isFunction(a)?(e=V.call(arguments,2),f=function(){return a.apply(c,e.concat(V.call(arguments)))},f.guid=a.guid=a.guid||$.guid++,f):b},access:function(a,c,d,e,f,g,h){var i,j=null==d,k=0,l=a.length;if(d&&"object"==typeof d){for(k in d)$.access(a,c,k,d[k],1,g,e);f=1}else if(e!==b){if(i=h===b&&$.isFunction(e),j&&(i?(i=c,c=function(a,b,c){return i.call($(a),c)}):(c.call(a,e),c=null)),c)for(;k<l;k++)c(a[k],d,i?e.call(a[k],k,c(a[k],d)):e,h);f=1}return f?a:j?c.call(a):l?c(a[0],d):g},now:function(){return(new Date).getTime()}}),$.ready.promise=function(b){if(!O)if(O=$.Deferred(),"complete"===P.readyState)setTimeout($.ready,1);else if(P.addEventListener)P.addEventListener("DOMContentLoaded",ma,!1),a.addEventListener("load",$.ready,!1);else{P.attachEvent("onreadystatechange",ma),a.attachEvent("onload",$.ready);var c=!1;try{c=null==a.frameElement&&P.documentElement}catch(a){}c&&c.doScroll&&function a(){if(!$.isReady){try{c.doScroll("left")}catch(b){return setTimeout(a,50)}$.ready()}}()}return O.promise(b)},$.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){na["[object "+b+"]"]=b.toLowerCase()}),N=$(P);var oa={};$.Callbacks=function(a){a="string"==typeof a?oa[a]||c(a):$.extend({},a);var d,e,f,g,h,i,j=[],k=!a.once&&[],l=function(b){for(d=a.memory&&b,e=!0,i=g||0,g=0,h=j.length,f=!0;j&&i<h;i++)if(j[i].apply(b[0],b[1])===!1&&a.stopOnFalse){d=!1;break}f=!1,j&&(k?k.length&&l(k.shift()):d?j=[]:m.disable())},m={add:function(){if(j){var b=j.length;!function b(c){$.each(c,function(c,d){var e=$.type(d);"function"!==e||a.unique&&m.has(d)?d&&d.length&&"string"!==e&&b(d):j.push(d)})}(arguments),f?h=j.length:d&&(g=b,l(d))}return this},remove:function(){return j&&$.each(arguments,function(a,b){for(var c;(c=$.inArray(b,j,c))>-1;)j.splice(c,1),f&&(c<=h&&h--,c<=i&&i--)}),this},has:function(a){return $.inArray(a,j)>-1},empty:function(){return j=[],this},disable:function(){return j=k=d=b,this},disabled:function(){return!j},lock:function(){return k=b,d||m.disable(),this},locked:function(){return!k},fireWith:function(a,b){return b=b||[],b=[a,b.slice?b.slice():b],j&&(!e||k)&&(f?k.push(b):l(b)),this},fire:function(){return m.fireWith(this,arguments),this},fired:function(){return!!e}};return m},$.extend({Deferred:function(a){var b=[["resolve","done",$.Callbacks("once memory"),"resolved"],["reject","fail",$.Callbacks("once memory"),"rejected"],["notify","progress",$.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return $.Deferred(function(c){$.each(b,function(b,d){var f=d[0],g=a[b];e[d[1]]($.isFunction(g)?function(){var a=g.apply(this,arguments);a&&$.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f+"With"](this===e?c:this,[a])}:c[f])}),a=null}).promise()},promise:function(a){return null!=a?$.extend(a,d):d}},e={};return d.pipe=d.then,$.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=g.fire,e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var h,i,j,b=0,c=V.call(arguments),d=c.length,e=1!==d||a&&$.isFunction(a.promise)?d:0,f=1===e?a:$.Deferred(),g=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?V.call(arguments):d,c===h?f.notifyWith(b,c):--e||f.resolveWith(b,c)}};if(d>1)for(h=new Array(d),i=new Array(d),j=new Array(d);b<d;b++)c[b]&&$.isFunction(c[b].promise)?c[b].promise().done(g(b,j,c)).fail(f.reject).progress(g(b,i,h)):--e;return e||f.resolveWith(j,c),f.promise()}}),$.support=function(){var b,c,d,e,f,g,h,i,j,k,l,m=P.createElement("div");if(m.setAttribute("className","t"),m.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",c=m.getElementsByTagName("*"),d=m.getElementsByTagName("a")[0],d.style.cssText="top:1px;float:left;opacity:.5",!c||!c.length)return{};e=P.createElement("select"),f=e.appendChild(P.createElement("option")),g=m.getElementsByTagName("input")[0],b={leadingWhitespace:3===m.firstChild.nodeType,tbody:!m.getElementsByTagName("tbody").length,htmlSerialize:!!m.getElementsByTagName("link").length,style:/top/.test(d.getAttribute("style")),hrefNormalized:"/a"===d.getAttribute("href"),opacity:/^0.5/.test(d.style.opacity),cssFloat:!!d.style.cssFloat,checkOn:"on"===g.value,optSelected:f.selected,getSetAttribute:"t"!==m.className,enctype:!!P.createElement("form").enctype,html5Clone:"<:nav></:nav>"!==P.createElement("nav").cloneNode(!0).outerHTML,boxModel:"CSS1Compat"===P.compatMode,submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},g.checked=!0,b.noCloneChecked=g.cloneNode(!0).checked,e.disabled=!0,b.optDisabled=!f.disabled;try{delete m.test}catch(a){b.deleteExpando=!1}if(!m.addEventListener&&m.attachEvent&&m.fireEvent&&(m.attachEvent("onclick",l=function(){b.noCloneEvent=!1}),m.cloneNode(!0).fireEvent("onclick"),m.detachEvent("onclick",l)),g=P.createElement("input"),g.value="t",g.setAttribute("type","radio"),b.radioValue="t"===g.value,g.setAttribute("checked","checked"),g.setAttribute("name","t"),m.appendChild(g),h=P.createDocumentFragment(),h.appendChild(m.lastChild),b.checkClone=h.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=g.checked,h.removeChild(g),h.appendChild(m),m.attachEvent)for(j in{submit:!0,change:!0,focusin:!0})i="on"+j,k=i in m,k||(m.setAttribute(i,"return;"),k="function"==typeof m[i]),b[j+"Bubbles"]=k;return $(function(){var c,d,e,f,g="padding:0;margin:0;border:0;display:block;overflow:hidden;",h=P.getElementsByTagName("body")[0];h&&(c=P.createElement("div"),c.style.cssText="visibility:hidden;border:0;width:0;height:0;position:static;top:0;margin-top:1px",h.insertBefore(c,h.firstChild),d=P.createElement("div"),c.appendChild(d),d.innerHTML="<table><tr><td></td><td>t</td></tr></table>",e=d.getElementsByTagName("td"),e[0].style.cssText="padding:0;margin:0;border:0;display:none",k=0===e[0].offsetHeight,e[0].style.display="",e[1].style.display="none",b.reliableHiddenOffsets=k&&0===e[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",b.boxSizing=4===d.offsetWidth,b.doesNotIncludeMarginInBodyOffset=1!==h.offsetTop,a.getComputedStyle&&(b.pixelPosition="1%"!==(a.getComputedStyle(d,null)||{}).top,b.boxSizingReliable="4px"===(a.getComputedStyle(d,null)||{width:"4px"}).width,f=P.createElement("div"),f.style.cssText=d.style.cssText=g,f.style.marginRight=f.style.width="0",d.style.width="1px",d.appendChild(f),b.reliableMarginRight=!parseFloat((a.getComputedStyle(f,null)||{}).marginRight)),"undefined"!=typeof d.style.zoom&&(d.innerHTML="",d.style.cssText=g+"width:1px;padding:1px;display:inline;zoom:1",b.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.style.overflow="visible",d.innerHTML="<div></div>",d.firstChild.style.width="5px",b.shrinkWrapBlocks=3!==d.offsetWidth,c.style.zoom=1),h.removeChild(c),c=d=e=f=null)}),h.removeChild(m),c=d=e=f=g=h=m=null,b}();var pa=/(?:{[sS]*}|[[sS]*])$/,qa=/([A-Z])/g;$.extend({cache:{},deletedIds:[],uuid:0,expando:"jQuery"+($.fn.jquery+Math.random()).replace(/D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){return a=a.nodeType?$.cache[a[$.expando]]:a[$.expando],!!a&&!e(a)},data:function(a,c,d,e){if($.acceptData(a)){var f,g,h=$.expando,i="string"==typeof c,j=a.nodeType,k=j?$.cache:a,l=j?a[h]:a[h]&&h;if(l&&k[l]&&(e||k[l].data)||!i||d!==b)return l||(j?a[h]=l=$.deletedIds.pop()||$.guid++:l=h),k[l]||(k[l]={},j||(k[l].toJSON=$.noop)),"object"!=typeof c&&"function"!=typeof c||(e?k[l]=$.extend(k[l],c):k[l].data=$.extend(k[l].data,c)),f=k[l],e||(f.data||(f.data={}),f=f.data),d!==b&&(f[$.camelCase(c)]=d),i?(g=f[c],null==g&&(g=f[$.camelCase(c)])):g=f,g}},removeData:function(a,b,c){if($.acceptData(a)){var d,f,g,h=a.nodeType,i=h?$.cache:a,j=h?a[$.expando]:$.expando;if(i[j]){if(b&&(d=c?i[j]:i[j].data)){$.isArray(b)||(b in d?b=[b]:(b=$.camelCase(b),b=b in d?[b]:b.split(" ")));for(f=0,g=b.length;f<g;f++)delete d[b[f]];if(!(c?e:$.isEmptyObject)(d))return}(c||(delete i[j].data,e(i[j])))&&(h?$.cleanData([a],!0):$.support.deleteExpando||i!=i.window?delete i[j]:i[j]=null)}}},_data:function(a,b,c){return $.data(a,b,c,!0)},acceptData:function(a){var b=a.nodeName&&$.noData[a.nodeName.toLowerCase()];return!b||b!==!0&&a.getAttribute("classid")===b}}),$.fn.extend({data:function(a,c){var e,f,g,h,i,j=this[0],k=0,l=null;if(a===b){if(this.length&&(l=$.data(j),1===j.nodeType&&!$._data(j,"parsedAttrs"))){for(g=j.attributes,i=g.length;k<i;k++)h=g[k].name,h.indexOf("data-")||(h=$.camelCase(h.substring(5)),d(j,h,l[h]));$._data(j,"parsedAttrs",!0)}return l}return"object"==typeof a?this.each(function(){$.data(this,a)}):(e=a.split(".",2),e[1]=e[1]?"."+e[1]:"",f=e[1]+"!",$.access(this,function(c){return c===b?(l=this.triggerHandler("getData"+f,[e[0]]),l===b&&j&&(l=$.data(j,a),l=d(j,a,l)),l===b&&e[1]?this.data(e[0]):l):(e[1]=c,void this.each(function(){var b=$(this);b.triggerHandler("setData"+f,e),$.data(this,a,c),b.triggerHandler("changeData"+f,e)}))},null,c,arguments.length>1,null,!1))},removeData:function(a){return this.each(function(){$.removeData(this,a)})}}),$.extend({queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=$._data(a,b),c&&(!d||$.isArray(c)?d=$._data(a,b,$.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=$.queue(a,b),d=c.length,e=c.shift(),f=$._queueHooks(a,b),g=function(){$.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return $._data(a,c)||$._data(a,c,{empty:$.Callbacks("once memory").add(function(){$.removeData(a,b+"queue",!0),$.removeData(a,c,!0)})})}}),$.fn.extend({queue:function(a,c){var d=2;return"string"!=typeof a&&(c=a,a="fx",d--),arguments.length<d?$.queue(this[0],a):c===b?this:this.each(function(){var b=$.queue(this,a,c);$._queueHooks(this,a),"fx"===a&&"inprogress"!==b[0]&&$.dequeue(this,a)})},dequeue:function(a){return this.each(function(){$.dequeue(this,a)})},delay:function(a,b){return a=$.fx?$.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){var d,e=1,f=$.Deferred(),g=this,h=this.length,i=function(){--e||f.resolveWith(g,[g])};for("string"!=typeof a&&(c=a,a=b),a=a||"fx";h--;)d=$._data(g[h],a+"queueHooks"),d&&d.empty&&(e++,d.empty.add(i));return i(),f.promise(c)}});var ra,sa,ta,ua=/[trn]/g,va=/r/g,wa=/^(?:button|input)$/i,xa=/^(?:button|input|object|select|textarea)$/i,ya=/^a(?:rea|)$/i,za=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,Aa=$.support.getSetAttribute;$.fn.extend({attr:function(a,b){return $.access(this,$.attr,a,b,arguments.length>1);
},removeAttr:function(a){return this.each(function(){$.removeAttr(this,a)})},prop:function(a,b){return $.access(this,$.prop,a,b,arguments.length>1)},removeProp:function(a){return a=$.propFix[a]||a,this.each(function(){try{this[a]=b,delete this[a]}catch(a){}})},addClass:function(a){var b,c,d,e,f,g,h;if($.isFunction(a))return this.each(function(b){$(this).addClass(a.call(this,b,this.className))});if(a&&"string"==typeof a)for(b=a.split(ba),c=0,d=this.length;c<d;c++)if(e=this[c],1===e.nodeType)if(e.className||1!==b.length){for(f=" "+e.className+" ",g=0,h=b.length;g<h;g++)f.indexOf(" "+b[g]+" ")<0&&(f+=b[g]+" ");e.className=$.trim(f)}else e.className=a;return this},removeClass:function(a){var c,d,e,f,g,h,i;if($.isFunction(a))return this.each(function(b){$(this).removeClass(a.call(this,b,this.className))});if(a&&"string"==typeof a||a===b)for(c=(a||"").split(ba),h=0,i=this.length;h<i;h++)if(e=this[h],1===e.nodeType&&e.className){for(d=(" "+e.className+" ").replace(ua," "),f=0,g=c.length;f<g;f++)for(;d.indexOf(" "+c[f]+" ")>=0;)d=d.replace(" "+c[f]+" "," ");e.className=a?$.trim(d):""}return this},toggleClass:function(a,b){var c=typeof a,d="boolean"==typeof b;return $.isFunction(a)?this.each(function(c){$(this).toggleClass(a.call(this,c,this.className,b),b)}):this.each(function(){if("string"===c)for(var e,f=0,g=$(this),h=b,i=a.split(ba);e=i[f++];)h=d?h:!g.hasClass(e),g[h?"addClass":"removeClass"](e);else"undefined"!==c&&"boolean"!==c||(this.className&&$._data(this,"__className__",this.className),this.className=this.className||a===!1?"":$._data(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;c<d;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ua," ").indexOf(b)>=0)return!0;return!1},val:function(a){var c,d,e,f=this[0];{if(arguments.length)return e=$.isFunction(a),this.each(function(d){var f,g=$(this);1===this.nodeType&&(f=e?a.call(this,d,g.val()):a,null==f?f="":"number"==typeof f?f+="":$.isArray(f)&&(f=$.map(f,function(a){return null==a?"":a+""})),c=$.valHooks[this.type]||$.valHooks[this.nodeName.toLowerCase()],c&&"set"in c&&c.set(this,f,"value")!==b||(this.value=f))});if(f)return c=$.valHooks[f.type]||$.valHooks[f.nodeName.toLowerCase()],c&&"get"in c&&(d=c.get(f,"value"))!==b?d:(d=f.value,"string"==typeof d?d.replace(va,""):null==d?"":d)}}}),$.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c,d,e,f=a.selectedIndex,g=[],h=a.options,i="select-one"===a.type;if(f<0)return null;for(c=i?f:0,d=i?f+1:h.length;c<d;c++)if(e=h[c],e.selected&&($.support.optDisabled?!e.disabled:null===e.getAttribute("disabled"))&&(!e.parentNode.disabled||!$.nodeName(e.parentNode,"optgroup"))){if(b=$(e).val(),i)return b;g.push(b)}return i&&!g.length&&h.length?$(h[f]).val():g},set:function(a,b){var c=$.makeArray(b);return $(a).find("option").each(function(){this.selected=$.inArray($(this).val(),c)>=0}),c.length||(a.selectedIndex=-1),c}}},attrFn:{},attr:function(a,c,d,e){var f,g,h,i=a.nodeType;if(a&&3!==i&&8!==i&&2!==i)return e&&$.isFunction($.fn[c])?$(a)[c](d):"undefined"==typeof a.getAttribute?$.prop(a,c,d):(h=1!==i||!$.isXMLDoc(a),h&&(c=c.toLowerCase(),g=$.attrHooks[c]||(za.test(c)?sa:ra)),d!==b?null===d?void $.removeAttr(a,c):g&&"set"in g&&h&&(f=g.set(a,d,c))!==b?f:(a.setAttribute(c,d+""),d):g&&"get"in g&&h&&null!==(f=g.get(a,c))?f:(f=a.getAttribute(c),null===f?b:f))},removeAttr:function(a,b){var c,d,e,f,g=0;if(b&&1===a.nodeType)for(d=b.split(ba);g<d.length;g++)e=d[g],e&&(c=$.propFix[e]||e,f=za.test(e),f||$.attr(a,e,""),a.removeAttribute(Aa?e:c),f&&c in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(wa.test(a.nodeName)&&a.parentNode)$.error("type property can't be changed");else if(!$.support.radioValue&&"radio"===b&&$.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}},value:{get:function(a,b){return ra&&$.nodeName(a,"button")?ra.get(a,b):b in a?a.value:null},set:function(a,b,c){return ra&&$.nodeName(a,"button")?ra.set(a,b,c):void(a.value=b)}}},propFix:{tabindex:"tabIndex",readonly:"readOnly",for:"htmlFor",class:"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e,f,g,h=a.nodeType;if(a&&3!==h&&8!==h&&2!==h)return g=1!==h||!$.isXMLDoc(a),g&&(c=$.propFix[c]||c,f=$.propHooks[c]),d!==b?f&&"set"in f&&(e=f.set(a,d,c))!==b?e:a[c]=d:f&&"get"in f&&null!==(e=f.get(a,c))?e:a[c]},propHooks:{tabIndex:{get:function(a){var c=a.getAttributeNode("tabindex");return c&&c.specified?parseInt(c.value,10):xa.test(a.nodeName)||ya.test(a.nodeName)&&a.href?0:b}}}}),sa={get:function(a,c){var d,e=$.prop(a,c);return e===!0||"boolean"!=typeof e&&(d=a.getAttributeNode(c))&&d.nodeValue!==!1?c.toLowerCase():b},set:function(a,b,c){var d;return b===!1?$.removeAttr(a,c):(d=$.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase())),c}},Aa||(ta={name:!0,id:!0,coords:!0},ra=$.valHooks.button={get:function(a,c){var d;return d=a.getAttributeNode(c),d&&(ta[c]?""!==d.value:d.specified)?d.value:b},set:function(a,b,c){var d=a.getAttributeNode(c);return d||(d=P.createAttribute(c),a.setAttributeNode(d)),d.value=b+""}},$.each(["width","height"],function(a,b){$.attrHooks[b]=$.extend($.attrHooks[b],{set:function(a,c){if(""===c)return a.setAttribute(b,"auto"),c}})}),$.attrHooks.contenteditable={get:ra.get,set:function(a,b,c){""===b&&(b="false"),ra.set(a,b,c)}}),$.support.hrefNormalized||$.each(["href","src","width","height"],function(a,c){$.attrHooks[c]=$.extend($.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return null===d?b:d}})}),$.support.style||($.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=b+""}}),$.support.optSelected||($.propHooks.selected=$.extend($.propHooks.selected,{get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}})),$.support.enctype||($.propFix.enctype="encoding"),$.support.checkOn||$.each(["radio","checkbox"],function(){$.valHooks[this]={get:function(a){return null===a.getAttribute("value")?"on":a.value}}}),$.each(["radio","checkbox"],function(){$.valHooks[this]=$.extend($.valHooks[this],{set:function(a,b){if($.isArray(b))return a.checked=$.inArray($(a).val(),b)>=0}})});var Ba=/^(?:textarea|input|select)$/i,Ca=/^([^.]*|)(?:.(.+)|)$/,Da=/(?:^|s)hover(.S+|)b/,Ea=/^key/,Fa=/^(?:mouse|contextmenu)|click/,Ga=/^(?:focusinfocus|focusoutblur)$/,Ha=function(a){return $.event.special.hover?a:a.replace(Da,"mouseenter$1 mouseleave$1")};$.event={add:function(a,c,d,e,f){var g,h,i,j,k,l,m,n,o,p,q;if(3!==a.nodeType&&8!==a.nodeType&&c&&d&&(g=$._data(a))){for(d.handler&&(o=d,d=o.handler,f=o.selector),d.guid||(d.guid=$.guid++),i=g.events,i||(g.events=i={}),h=g.handle,h||(g.handle=h=function(a){return"undefined"==typeof $||a&&$.event.triggered===a.type?b:$.event.dispatch.apply(h.elem,arguments)},h.elem=a),c=$.trim(Ha(c)).split(" "),j=0;j<c.length;j++)k=Ca.exec(c[j])||[],l=k[1],m=(k[2]||"").split(".").sort(),q=$.event.special[l]||{},l=(f?q.delegateType:q.bindType)||l,q=$.event.special[l]||{},n=$.extend({type:l,origType:k[1],data:e,handler:d,guid:d.guid,selector:f,needsContext:f&&$.expr.match.needsContext.test(f),namespace:m.join(".")},o),p=i[l],p||(p=i[l]=[],p.delegateCount=0,q.setup&&q.setup.call(a,e,m,h)!==!1||(a.addEventListener?a.addEventListener(l,h,!1):a.attachEvent&&a.attachEvent("on"+l,h))),q.add&&(q.add.call(a,n),n.handler.guid||(n.handler.guid=d.guid)),f?p.splice(p.delegateCount++,0,n):p.push(n),$.event.global[l]=!0;a=null}},global:{},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q=$.hasData(a)&&$._data(a);if(q&&(m=q.events)){for(b=$.trim(Ha(b||"")).split(" "),f=0;f<b.length;f++)if(g=Ca.exec(b[f])||[],h=i=g[1],j=g[2],h){for(n=$.event.special[h]||{},h=(d?n.delegateType:n.bindType)||h,o=m[h]||[],k=o.length,j=j?new RegExp("(^|\.)"+j.split(".").sort().join("\.(?:.*\.|)")+"(\.|$)"):null,l=0;l<o.length;l++)p=o[l],(e||i===p.origType)&&(!c||c.guid===p.guid)&&(!j||j.test(p.namespace))&&(!d||d===p.selector||"**"===d&&p.selector)&&(o.splice(l--,1),p.selector&&o.delegateCount--,n.remove&&n.remove.call(a,p));0===o.length&&k!==o.length&&((!n.teardown||n.teardown.call(a,j,q.handle)===!1)&&$.removeEvent(a,h,q.handle),delete m[h])}else for(h in m)$.event.remove(a,h+b[f],c,d,!0);$.isEmptyObject(m)&&(delete q.handle,$.removeData(a,"events",!0))}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,f){if(!e||3!==e.nodeType&&8!==e.nodeType){var g,h,i,j,k,l,m,n,o,p,q=c.type||c,r=[];if(Ga.test(q+$.event.triggered))return;if(q.indexOf("!")>=0&&(q=q.slice(0,-1),h=!0),q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),(!e||$.event.customEvent[q])&&!$.event.global[q])return;if(c="object"==typeof c?c[$.expando]?c:new $.Event(q,c):new $.Event(q),c.type=q,c.isTrigger=!0,c.exclusive=h,c.namespace=r.join("."),c.namespace_re=c.namespace?new RegExp("(^|\.)"+r.join("\.(?:.*\.|)")+"(\.|$)"):null,l=q.indexOf(":")<0?"on"+q:"",!e){g=$.cache;for(i in g)g[i].events&&g[i].events[q]&&$.event.trigger(c,d,g[i].handle.elem,!0);return}if(c.result=b,c.target||(c.target=e),d=null!=d?$.makeArray(d):[],d.unshift(c),m=$.event.special[q]||{},m.trigger&&m.trigger.apply(e,d)===!1)return;if(o=[[e,m.bindType||q]],!f&&!m.noBubble&&!$.isWindow(e)){for(p=m.delegateType||q,j=Ga.test(p+q)?e:e.parentNode,k=e;j;j=j.parentNode)o.push([j,p]),k=j;k===(e.ownerDocument||P)&&o.push([k.defaultView||k.parentWindow||a,p])}for(i=0;i<o.length&&!c.isPropagationStopped();i++)j=o[i][0],c.type=o[i][1],n=($._data(j,"events")||{})[c.type]&&$._data(j,"handle"),n&&n.apply(j,d),n=l&&j[l],n&&$.acceptData(j)&&n.apply&&n.apply(j,d)===!1&&c.preventDefault();return c.type=q,!f&&!c.isDefaultPrevented()&&(!m._default||m._default.apply(e.ownerDocument,d)===!1)&&("click"!==q||!$.nodeName(e,"a"))&&$.acceptData(e)&&l&&e[q]&&("focus"!==q&&"blur"!==q||0!==c.target.offsetWidth)&&!$.isWindow(e)&&(k=e[l],k&&(e[l]=null),$.event.triggered=q,e[q](),$.event.triggered=b,k&&(e[l]=k)),c.result}},dispatch:function(c){c=$.event.fix(c||a.event);var d,e,f,g,h,i,j,k,l,n=($._data(this,"events")||{})[c.type]||[],o=n.delegateCount,p=V.call(arguments),q=!c.exclusive&&!c.namespace,r=$.event.special[c.type]||{},s=[];if(p[0]=c,c.delegateTarget=this,!r.preDispatch||r.preDispatch.call(this,c)!==!1){if(o&&(!c.button||"click"!==c.type))for(f=c.target;f!=this;f=f.parentNode||this)if(f.disabled!==!0||"click"!==c.type){for(h={},j=[],d=0;d<o;d++)k=n[d],l=k.selector,h[l]===b&&(h[l]=k.needsContext?$(l,this).index(f)>=0:$.find(l,this,null,[f]).length),h[l]&&j.push(k);j.length&&s.push({elem:f,matches:j})}for(n.length>o&&s.push({elem:this,matches:n.slice(o)}),d=0;d<s.length&&!c.isPropagationStopped();d++)for(i=s[d],c.currentTarget=i.elem,e=0;e<i.matches.length&&!c.isImmediatePropagationStopped();e++)k=i.matches[e],(q||!c.namespace&&!k.namespace||c.namespace_re&&c.namespace_re.test(k.namespace))&&(c.data=k.data,c.handleObj=k,g=(($.event.special[k.origType]||{}).handle||k.handler).apply(i.elem,p),g!==b&&(c.result=g,g===!1&&(c.preventDefault(),c.stopPropagation())));return r.postDispatch&&r.postDispatch.call(this,c),c.result}},props:"attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,c){var d,e,f,g=c.button,h=c.fromElement;return null==a.pageX&&null!=c.clientX&&(d=a.target.ownerDocument||P,e=d.documentElement,f=d.body,a.pageX=c.clientX+(e&&e.scrollLeft||f&&f.scrollLeft||0)-(e&&e.clientLeft||f&&f.clientLeft||0),a.pageY=c.clientY+(e&&e.scrollTop||f&&f.scrollTop||0)-(e&&e.clientTop||f&&f.clientTop||0)),!a.relatedTarget&&h&&(a.relatedTarget=h===a.target?c.toElement:h),!a.which&&g!==b&&(a.which=1&g?1:2&g?3:4&g?2:0),a}},fix:function(a){if(a[$.expando])return a;var b,c,d=a,e=$.event.fixHooks[a.type]||{},f=e.props?this.props.concat(e.props):this.props;for(a=$.Event(d),b=f.length;b;)c=f[--b],a[c]=d[c];return a.target||(a.target=d.srcElement||P),3===a.target.nodeType&&(a.target=a.target.parentNode),a.metaKey=!!a.metaKey,e.filter?e.filter(a,d):a},special:{load:{noBubble:!0},focus:{delegateType:"focusin"},blur:{delegateType:"focusout"},beforeunload:{setup:function(a,b,c){$.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}},simulate:function(a,b,c,d){var e=$.extend(new $.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?$.event.trigger(e,null,b):$.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},$.event.handle=$.event.dispatch,$.removeEvent=P.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){var d="on"+b;a.detachEvent&&("undefined"==typeof a[d]&&(a[d]=null),a.detachEvent(d,c))},$.Event=function(a,b){return this instanceof $.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?g:f):this.type=a,b&&$.extend(this,b),this.timeStamp=a&&a.timeStamp||$.now(),this[$.expando]=!0,void 0):new $.Event(a,b)},$.Event.prototype={preventDefault:function(){this.isDefaultPrevented=g;var a=this.originalEvent;a&&(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=g;var a=this.originalEvent;a&&(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=g,this.stopPropagation()},isDefaultPrevented:f,isPropagationStopped:f,isImmediatePropagationStopped:f},$.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){$.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;f.selector;return e&&(e===d||$.contains(d,e))||(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),$.support.submitBubbles||($.event.special.submit={setup:function(){return!$.nodeName(this,"form")&&void $.event.add(this,"click._submit keypress._submit",function(a){var c=a.target,d=$.nodeName(c,"input")||$.nodeName(c,"button")?c.form:b;d&&!$._data(d,"_submit_attached")&&($.event.add(d,"submit._submit",function(a){a._submit_bubble=!0}),$._data(d,"_submit_attached",!0))})},postDispatch:function(a){a._submit_bubble&&(delete a._submit_bubble,this.parentNode&&!a.isTrigger&&$.event.simulate("submit",this.parentNode,a,!0))},teardown:function(){return!$.nodeName(this,"form")&&void $.event.remove(this,"._submit")}}),$.support.changeBubbles||($.event.special.change={setup:function(){return Ba.test(this.nodeName)?("checkbox"!==this.type&&"radio"!==this.type||($.event.add(this,"propertychange._change",function(a){"checked"===a.originalEvent.propertyName&&(this._just_changed=!0)}),$.event.add(this,"click._change",function(a){this._just_changed&&!a.isTrigger&&(this._just_changed=!1),$.event.simulate("change",this,a,!0)})),!1):void $.event.add(this,"beforeactivate._change",function(a){var b=a.target;Ba.test(b.nodeName)&&!$._data(b,"_change_attached")&&($.event.add(b,"change._change",function(a){this.parentNode&&!a.isSimulated&&!a.isTrigger&&$.event.simulate("change",this.parentNode,a,!0)}),$._data(b,"_change_attached",!0))})},handle:function(a){var b=a.target;if(this!==b||a.isSimulated||a.isTrigger||"radio"!==b.type&&"checkbox"!==b.type)return a.handleObj.handler.apply(this,arguments)},teardown:function(){return $.event.remove(this,"._change"),!Ba.test(this.nodeName)}}),$.support.focusinBubbles||$.each({focus:"focusin",blur:"focusout"},function(a,b){var c=0,d=function(a){$.event.simulate(b,a.target,$.event.fix(a),!0)};$.event.special[b]={setup:function(){0===c++&&P.addEventListener(a,d,!0)},teardown:function(){0===--c&&P.removeEventListener(a,d,!0)}}}),$.fn.extend({on:function(a,c,d,e,g){var h,i;if("object"==typeof a){"string"!=typeof c&&(d=d||c,c=b);for(i in a)this.on(i,c,d,a[i],g);return this}if(null==d&&null==e?(e=c,d=c=b):null==e&&("string"==typeof c?(e=d,d=b):(e=d,d=c,c=b)),e===!1)e=f;else if(!e)return this;return 1===g&&(h=e,e=function(a){return $().off(a),h.apply(this,arguments)},e.guid=h.guid||(h.guid=$.guid++)),this.each(function(){$.event.add(this,a,e,d,c)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,c,d){var e,g;if(a&&a.preventDefault&&a.handleObj)return e=a.handleObj,$(a.delegateTarget).off(e.namespace?e.origType+"."+e.namespace:e.origType,e.selector,e.handler),this;if("object"==typeof a){for(g in a)this.off(g,c,a[g]);return this}return c!==!1&&"function"!=typeof c||(d=c,c=b),d===!1&&(d=f),this.each(function(){$.event.remove(this,a,d,c)})},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},live:function(a,b,c){return $(this.context).on(a,this.selector,b,c),this},die:function(a,b){return $(this.context).off(a,this.selector||"**",b),this},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)},trigger:function(a,b){return this.each(function(){$.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return $.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||$.guid++,d=0,e=function(c){var e=($._data(this,"lastToggle"+a.guid)||0)%d;return $._data(this,"lastToggle"+a.guid,e+1),c.preventDefault(),b[e].apply(this,arguments)||!1};for(e.guid=c;d<b.length;)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),$.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){$.fn[b]=function(a,c){return null==c&&(c=a,a=null),arguments.length>0?this.on(b,null,a,c):this.trigger(b)},Ea.test(b)&&($.event.fixHooks[b]=$.event.keyHooks),Fa.test(b)&&($.event.fixHooks[b]=$.event.mouseHooks)}),function(a,b){function c(a,b,c,d){c=c||[],b=b||F;var e,f,g,h,i=b.nodeType;if(!a||"string"!=typeof a)return c;if(1!==i&&9!==i)return[];if(g=v(b),!g&&!d&&(e=ca.exec(a)))if(h=e[1]){if(9===i){if(f=b.getElementById(h),!f||!f.parentNode)return c;if(f.id===h)return c.push(f),c}else if(b.ownerDocument&&(f=b.ownerDocument.getElementById(h))&&w(b,f)&&f.id===h)return c.push(f),c}else{if(e[2])return K.apply(c,L.call(b.getElementsByTagName(a),0)),c;if((h=e[3])&&oa&&b.getElementsByClassName)return K.apply(c,L.call(b.getElementsByClassName(h),0)),c}return p(a.replace(Z,"$1"),b,c,d,g)}function d(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function e(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function f(a){return N(function(b){return b=+b,N(function(c,d){for(var e,f=a([],c.length,b),g=f.length;g--;)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function g(a,b,c){if(a===b)return c;for(var d=a.nextSibling;d;){if(d===b)return-1;d=d.nextSibling}return 1}function h(a,b){var d,e,f,g,h,i,j,k=Q[D][a];if(k)return b?0:k.slice(0);for(h=a,i=[],j=t.preFilter;h;){d&&!(e=_.exec(h))||(e&&(h=h.slice(e[0].length)),i.push(f=[])),d=!1,(e=aa.exec(h))&&(f.push(d=new E(e.shift())),h=h.slice(d.length),d.type=e[0].replace(Z," "));for(g in t.filter)(e=ja[g].exec(h))&&(!j[g]||(e=j[g](e,F,!0)))&&(f.push(d=new E(e.shift())),h=h.slice(d.length),d.type=g,d.matches=e);if(!d)break}return b?h.length:h?c.error(a):Q(a,i).slice(0)}function i(a,b,c){var d=b.dir,e=c&&"parentNode"===b.dir,f=I++;return b.first?function(b,c,f){for(;b=b[d];)if(e||1===b.nodeType)return a(b,c,f)}:function(b,c,g){if(g){for(;b=b[d];)if((e||1===b.nodeType)&&a(b,c,g))return b}else for(var h,i=H+" "+f+" ",j=i+r;b=b[d];)if(e||1===b.nodeType){if((h=b[D])===j)return b.sizset;if("string"==typeof h&&0===h.indexOf(i)){if(b.sizset)return b}else{if(b[D]=j,a(b,c,g))return b.sizset=!0,b;b.sizset=!1}}}}function j(a){return a.length>1?function(b,c,d){for(var e=a.length;e--;)if(!a[e](b,c,d))return!1;return!0}:a[0]}function k(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;h<i;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function l(a,b,c,d,e,f){return d&&!d[D]&&(d=l(d)),e&&!e[D]&&(e=l(e,f)),N(function(f,g,h,i){if(!f||!e){var j,l,m,n=[],p=[],q=g.length,r=f||o(b||"*",h.nodeType?[h]:h,[],f),s=!a||!f&&b?r:k(r,n,a,h,i),t=c?e||(f?a:q||d)?[]:g:s;if(c&&c(s,t,h,i),d)for(m=k(t,p),d(m,[],h,i),j=m.length;j--;)(l=m[j])&&(t[p[j]]=!(s[p[j]]=l));if(f)for(j=a&&t.length;j--;)(l=t[j])&&(f[n[j]]=!(g[n[j]]=l));else t=k(t===g?t.splice(q,t.length):t),e?e(null,g,t,i):K.apply(g,t)}})}function m(a){for(var b,c,d,e=a.length,f=t.relative[a[0].type],g=f||t.relative[" "],h=f?1:0,k=i(function(a){return a===b},g,!0),n=i(function(a){return M.call(b,a)>-1},g,!0),o=[function(a,c,d){return!f&&(d||c!==A)||((b=c).nodeType?k(a,c,d):n(a,c,d))}];h<e;h++)if(c=t.relative[a[h].type])o=[i(j(o),c)];else{if(c=t.filter[a[h].type].apply(null,a[h].matches),c[D]){for(d=++h;d<e&&!t.relative[a[d].type];d++);return l(h>1&&j(o),h>1&&a.slice(0,h-1).join("").replace(Z,"$1"),c,h<d&&m(a.slice(h,d)),d<e&&m(a=a.slice(d)),d<e&&a.join(""))}o.push(c)}return j(o)}function n(a,b){var d=b.length>0,e=a.length>0,f=function(g,h,i,j,l){var m,n,o,p=[],q=0,s="0",u=g&&[],v=null!=l,w=A,x=g||e&&t.find.TAG("*",l&&h.parentNode||h),y=H+=null==w?1:Math.E;for(v&&(A=h!==F&&h,r=f.el);null!=(m=x[s]);s++){if(e&&m){for(n=0;o=a[n];n++)if(o(m,h,i)){j.push(m);break}v&&(H=y,r=++f.el)}d&&((m=!o&&m)&&q--,g&&u.push(m))}if(q+=s,d&&s!==q){for(n=0;o=b[n];n++)o(u,p,h,i);if(g){if(q>0)for(;s--;)!u[s]&&!p[s]&&(p[s]=J.call(j));p=k(p)}K.apply(j,p),v&&!g&&p.length>0&&q+b.length>1&&c.uniqueSort(j)}return v&&(H=y,A=w),u};return f.el=0,d?N(f):f}function o(a,b,d,e){for(var f=0,g=b.length;f<g;f++)c(a,b[f],d,e);return d}function p(a,b,c,d,e){var f,g,i,j,k,l=h(a);l.length;if(!d&&1===l.length){if(g=l[0]=l[0].slice(0),g.length>2&&"ID"===(i=g[0]).type&&9===b.nodeType&&!e&&t.relative[g[1].type]){if(b=t.find.ID(i.matches[0].replace(ia,""),b,e)[0],!b)return c;a=a.slice(g.shift().length)}for(f=ja.POS.test(a)?-1:g.length-1;f>=0&&(i=g[f],!t.relative[j=i.type]);f--)if((k=t.find[j])&&(d=k(i.matches[0].replace(ia,""),ea.test(g[0].type)&&b.parentNode||b,e))){if(g.splice(f,1),a=d.length&&g.join(""),!a)return K.apply(c,L.call(d,0)),c;break}}return x(a,l)(d,b,e,c,ea.test(a)),c}function q(){}var r,s,t,u,v,w,x,y,z,A,B=!0,C="undefined",D=("sizcache"+Math.random()).replace(".",""),E=String,F=a.document,G=F.documentElement,H=0,I=0,J=[].pop,K=[].push,L=[].slice,M=[].indexOf||function(a){for(var b=0,c=this.length;b<c;b++)if(this[b]===a)return b;return-1},N=function(a,b){return a[D]=null==b||b,a},O=function(){var a={},b=[];return N(function(c,d){return b.push(c)>t.cacheLength&&delete a[b.shift()],a[c]=d},a)},P=O(),Q=O(),R=O(),S="[\x20\t\r\n\f]",T="(?:\\.|[-\w]|[^\x00-\xa0])+",U=T.replace("w","w#"),V="([*^$|!~]?=)",W="\["+S+"*("+T+")"+S+"*(?:"+V+S+"*(?:(['"])((?:\\.|[^\\])*?)\3|("+U+")|)|)"+S+"*\]",X=":("+T+")(?:\((?:(['"])((?:\\.|[^\\])*?)\2|([^()[\]]*|(?:(?:"+W+")|[^:]|\\.)*|.*))\)|)",Y=":(even|odd|eq|gt|lt|nth|first|last)(?:\("+S+"*((?:-\d)?\d*)"+S+"*\)|)(?=[^-]|$)",Z=new RegExp("^"+S+"+|((?:^|[^\\])(?:\\.)*)"+S+"+$","g"),_=new RegExp("^"+S+"*,"+S+"*"),aa=new RegExp("^"+S+"*([\x20\t\r\n\f>+~])"+S+"*"),ba=new RegExp(X),ca=/^(?:#([w-]+)|(w+)|.([w-]+))$/,ea=/[x20trnf]*[+~]/,ga=/hd/i,ha=/input|select|textarea|button/i,ia=/\(?!\)/g,ja={ID:new RegExp("^#("+T+")"),CLASS:new RegExp("^\.("+T+")"),NAME:new RegExp("^\[name=['"]?("+T+")['"]?\]"),TAG:new RegExp("^("+T.replace("w","w*")+")"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+X),POS:new RegExp(Y,"i"),CHILD:new RegExp("^:(only|nth|first|last)-child(?:\("+S+"*(even|odd|(([+-]|)(\d*)n|)"+S+"*(?:([+-]|)"+S+"*(\d+)|))"+S+"*\)|)","i"),needsContext:new RegExp("^"+S+"*[>+~]|"+Y,"i")},ka=function(a){var b=F.createElement("div");try{return a(b)}catch(a){return!1}finally{b=null}},la=ka(function(a){return a.appendChild(F.createComment("")),!a.getElementsByTagName("*").length}),ma=ka(function(a){return a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!==C&&"#"===a.firstChild.getAttribute("href")}),na=ka(function(a){a.innerHTML="<select></select>";var b=typeof a.lastChild.getAttribute("multiple");return"boolean"!==b&&"string"!==b}),oa=ka(function(a){return a.innerHTML="<div class='hidden e'></div><div class='hidden'></div>",!(!a.getElementsByClassName||!a.getElementsByClassName("e").length)&&(a.lastChild.className="e",2===a.getElementsByClassName("e").length)}),pa=ka(function(a){a.id=D+0,a.innerHTML="<a name='"+D+"'></a><div name='"+D+"'></div>",G.insertBefore(a,G.firstChild);var b=F.getElementsByName&&F.getElementsByName(D).length===2+F.getElementsByName(D+0).length;return s=!F.getElementById(D),G.removeChild(a),b});try{L.call(G.childNodes,0)[0].nodeType}catch(a){L=function(a){for(var b,c=[];b=this[a];a++)c.push(b);return c}}c.matches=function(a,b){return c(a,null,null,b)},c.matchesSelector=function(a,b){return c(b,null,null,[a]).length>0},u=c.getText=function(a){var b,c="",d=0,e=a.nodeType;if(e){if(1===e||9===e||11===e){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=u(a)}else if(3===e||4===e)return a.nodeValue}else for(;b=a[d];d++)c+=u(b);return c},v=c.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return!!b&&"HTML"!==b.nodeName},w=c.contains=G.contains?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!!(d&&1===d.nodeType&&c.contains&&c.contains(d))}:G.compareDocumentPosition?function(a,b){return b&&!!(16&a.compareDocumentPosition(b))}:function(a,b){for(;b=b.parentNode;)if(b===a)return!0;return!1},c.attr=function(a,b){var c,d=v(a);return d||(b=b.toLowerCase()),(c=t.attrHandle[b])?c(a):d||na?a.getAttribute(b):(c=a.getAttributeNode(b),c?"boolean"==typeof a[b]?a[b]?b:null:c.specified?c.value:null:null)},t=c.selectors={cacheLength:50,createPseudo:N,match:ja,attrHandle:ma?{}:{href:function(a){return a.getAttribute("href",2)},type:function(a){return a.getAttribute("type")}},find:{ID:s?function(a,b,c){if(typeof b.getElementById!==C&&!c){var d=b.getElementById(a);return d&&d.parentNode?[d]:[]}}:function(a,c,d){if(typeof c.getElementById!==C&&!d){var e=c.getElementById(a);return e?e.id===a||typeof e.getAttributeNode!==C&&e.getAttributeNode("id").value===a?[e]:b:[]}},TAG:la?function(a,b){if(typeof b.getElementsByTagName!==C)return b.getElementsByTagName(a)}:function(a,b){var c=b.getElementsByTagName(a);if("*"===a){for(var d,e=[],f=0;d=c[f];f++)1===d.nodeType&&e.push(d);return e}return c},NAME:pa&&function(a,b){if(typeof b.getElementsByName!==C)return b.getElementsByName(name)},CLASS:oa&&function(a,b,c){if(typeof b.getElementsByClassName!==C&&!c)return b.getElementsByClassName(a)}},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ia,""),a[3]=(a[4]||a[5]||"").replace(ia,""),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1]?(a[2]||c.error(a[0]),a[3]=+(a[3]?a[4]+(a[5]||1):2*("even"===a[2]||"odd"===a[2])),a[4]=+(a[6]+a[7]||"odd"===a[2])):a[2]&&c.error(a[0]),a},PSEUDO:function(a){var b,c;return ja.CHILD.test(a[0])?null:(a[3]?a[2]=a[3]:(b=a[4])&&(ba.test(b)&&(c=h(b,!0))&&(c=b.indexOf(")",b.length-c)-b.length)&&(b=b.slice(0,c),a[0]=a[0].slice(0,c)),a[2]=b),a.slice(0,3))}},filter:{ID:s?function(a){return a=a.replace(ia,""),function(b){return b.getAttribute("id")===a}}:function(a){return a=a.replace(ia,""),function(b){var c=typeof b.getAttributeNode!==C&&b.getAttributeNode("id");return c&&c.value===a}},TAG:function(a){return"*"===a?function(){return!0}:(a=a.replace(ia,"").toLowerCase(),function(b){return b.nodeName&&b.nodeName.toLowerCase()===a})},CLASS:function(a){var b=P[D][a];return b||(b=P(a,new RegExp("(^|"+S+")"+a+"("+S+"|$)"))),function(a){return b.test(a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")}},ATTR:function(a,b,d){return function(e,f){var g=c.attr(e,a);return null==g?"!="===b:!b||(g+="","="===b?g===d:"!="===b?g!==d:"^="===b?d&&0===g.indexOf(d):"*="===b?d&&g.indexOf(d)>-1:"$="===b?d&&g.substr(g.length-d.length)===d:"~="===b?(" "+g+" ").indexOf(d)>-1:"|="===b&&(g===d||g.substr(0,d.length+1)===d+"-"))}},CHILD:function(a,b,c,d){return"nth"===a?function(a){var b,e,f=a.parentNode;if(1===c&&0===d)return!0;if(f)for(e=0,b=f.firstChild;b&&(1!==b.nodeType||(e++,a!==b));b=b.nextSibling);return e-=d,e===c||e%c===0&&e/c>=0}:function(b){var c=b;switch(a){case"only":case"first":for(;c=c.previousSibling;)if(1===c.nodeType)return!1;if("first"===a)return!0;c=b;case"last":for(;c=c.nextSibling;)if(1===c.nodeType)return!1;return!0}}},PSEUDO:function(a,b){var d,e=t.pseudos[a]||t.setFilters[a.toLowerCase()]||c.error("unsupported pseudo: "+a);return e[D]?e(b):e.length>1?(d=[a,a,"",b],t.setFilters.hasOwnProperty(a.toLowerCase())?N(function(a,c){for(var d,f=e(a,b),g=f.length;g--;)d=M.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,d)}):e}},pseudos:{not:N(function(a){var b=[],c=[],d=x(a.replace(Z,"$1"));return d[D]?N(function(a,b,c,e){for(var f,g=d(a,null,e,[]),h=a.length;h--;)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:N(function(a){return function(b){return c(a,b).length>0}}),contains:N(function(a){return function(b){return(b.textContent||b.innerText||u(b)).indexOf(a)>-1}}),enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},parent:function(a){return!t.pseudos.empty(a)},empty:function(a){var b;for(a=a.firstChild;a;){if(a.nodeName>"@"||3===(b=a.nodeType)||4===b)return!1;a=a.nextSibling}return!0},header:function(a){return ga.test(a.nodeName)},text:function(a){var b,c;return"input"===a.nodeName.toLowerCase()&&"text"===(b=a.type)&&(null==(c=a.getAttribute("type"))||c.toLowerCase()===b)},radio:d("radio"),checkbox:d("checkbox"),file:d("file"),password:d("password"),image:d("image"),submit:e("submit"),reset:e("reset"),button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},input:function(a){return ha.test(a.nodeName)},focus:function(a){var b=a.ownerDocument;return a===b.activeElement&&(!b.hasFocus||b.hasFocus())&&(!!a.type||!!a.href)},active:function(a){return a===a.ownerDocument.activeElement},first:f(function(a,b,c){return[0]}),last:f(function(a,b,c){return[b-1]}),eq:f(function(a,b,c){return[c<0?c+b:c]}),even:f(function(a,b,c){for(var d=0;d<b;d+=2)a.push(d);return a}),odd:f(function(a,b,c){for(var d=1;d<b;d+=2)a.push(d);return a}),lt:f(function(a,b,c){for(var d=c<0?c+b:c;--d>=0;)a.push(d);return a}),gt:f(function(a,b,c){for(var d=c<0?c+b:c;++d<b;)a.push(d);return a})}},y=G.compareDocumentPosition?function(a,b){return a===b?(z=!0,0):(a.compareDocumentPosition&&b.compareDocumentPosition?4&a.compareDocumentPosition(b):a.compareDocumentPosition)?-1:1}:function(a,b){if(a===b)return z=!0,0;if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],h=a.parentNode,i=b.parentNode,j=h;if(h===i)return g(a,b);if(!h)return-1;if(!i)return 1;for(;j;)e.unshift(j),j=j.parentNode;for(j=i;j;)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return g(e[k],f[k]);return k===c?g(a,f[k],-1):g(e[k],b,1)},[0,0].sort(y),
B=!z,c.uniqueSort=function(a){var b,c=1;if(z=B,a.sort(y),z)for(;b=a[c];c++)b===a[c-1]&&a.splice(c--,1);return a},c.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},x=c.compile=function(a,b){var c,d=[],e=[],f=R[D][a];if(!f){for(b||(b=h(a)),c=b.length;c--;)f=m(b[c]),f[D]?d.push(f):e.push(f);f=R(a,n(e,d))}return f},F.querySelectorAll&&function(){var a,b=p,d=/'|\/g,e=/=[x20trnf]*([^'"]]*)[x20trnf]*]/g,f=[":focus"],g=[":active",":focus"],i=G.matchesSelector||G.mozMatchesSelector||G.webkitMatchesSelector||G.oMatchesSelector||G.msMatchesSelector;ka(function(a){a.innerHTML="<select><option selected=''></option></select>",a.querySelectorAll("[selected]").length||f.push("\["+S+"*(?:checked|disabled|ismap|multiple|readonly|selected|value)"),a.querySelectorAll(":checked").length||f.push(":checked")}),ka(function(a){a.innerHTML="<p test=''></p>",a.querySelectorAll("[test^='']").length&&f.push("[*^$]="+S+"*(?:""|'')"),a.innerHTML="<input type='hidden'/>",a.querySelectorAll(":enabled").length||f.push(":enabled",":disabled")}),f=new RegExp(f.join("|")),p=function(a,c,e,g,i){if(!(g||i||f&&f.test(a))){var j,k,l=!0,m=D,n=c,o=9===c.nodeType&&a;if(1===c.nodeType&&"object"!==c.nodeName.toLowerCase()){for(j=h(a),(l=c.getAttribute("id"))?m=l.replace(d,"\$&"):c.setAttribute("id",m),m="[id='"+m+"'] ",k=j.length;k--;)j[k]=m+j[k].join("");n=ea.test(a)&&c.parentNode||c,o=j.join(",")}if(o)try{return K.apply(e,L.call(n.querySelectorAll(o),0)),e}catch(a){}finally{l||c.removeAttribute("id")}}return b(a,c,e,g,i)},i&&(ka(function(b){a=i.call(b,"div");try{i.call(b,"[test!='']:sizzle"),g.push("!=",X)}catch(a){}}),g=new RegExp(g.join("|")),c.matchesSelector=function(b,d){if(d=d.replace(e,"='$1']"),!(v(b)||g.test(d)||f&&f.test(d)))try{var h=i.call(b,d);if(h||a||b.document&&11!==b.document.nodeType)return h}catch(a){}return c(d,null,null,[b]).length>0})}(),t.pseudos.nth=t.pseudos.eq,t.filters=q.prototype=t.pseudos,t.setFilters=new q,c.attr=$.attr,$.find=c,$.expr=c.selectors,$.expr[":"]=$.expr.pseudos,$.unique=c.uniqueSort,$.text=c.getText,$.isXMLDoc=c.isXML,$.contains=c.contains}(a);var Ia=/Until$/,Ja=/^(?:parents|prev(?:Until|All))/,Ka=/^.[^:#[.,]*$/,La=$.expr.match.needsContext,Ma={children:!0,contents:!0,next:!0,prev:!0};$.fn.extend({find:function(a){var b,c,d,e,f,g,h=this;if("string"!=typeof a)return $(a).filter(function(){for(b=0,c=h.length;b<c;b++)if($.contains(h[b],this))return!0});for(g=this.pushStack("","find",a),b=0,c=this.length;b<c;b++)if(d=g.length,$.find(a,this[b],g),b>0)for(e=d;e<g.length;e++)for(f=0;f<d;f++)if(g[f]===g[e]){g.splice(e--,1);break}return g},has:function(a){var b,c=$(a,this),d=c.length;return this.filter(function(){for(b=0;b<d;b++)if($.contains(this,c[b]))return!0})},not:function(a){return this.pushStack(j(this,a,!1),"not",a)},filter:function(a){return this.pushStack(j(this,a,!0),"filter",a)},is:function(a){return!!a&&("string"==typeof a?La.test(a)?$(a,this.context).index(this[0])>=0:$.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=La.test(a)||"string"!=typeof a?$(a,b||this.context):0;d<e;d++)for(c=this[d];c&&c.ownerDocument&&c!==b&&11!==c.nodeType;){if(g?g.index(c)>-1:$.find.matchesSelector(c,a)){f.push(c);break}c=c.parentNode}return f=f.length>1?$.unique(f):f,this.pushStack(f,"closest",a)},index:function(a){return a?"string"==typeof a?$.inArray(this[0],$(a)):$.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(a,b){var c="string"==typeof a?$(a,b):$.makeArray(a&&a.nodeType?[a]:a),d=$.merge(this.get(),c);return this.pushStack(h(c[0])||h(d[0])?d:$.unique(d))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}}),$.fn.andSelf=$.fn.addBack,$.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return $.dir(a,"parentNode")},parentsUntil:function(a,b,c){return $.dir(a,"parentNode",c)},next:function(a){return i(a,"nextSibling")},prev:function(a){return i(a,"previousSibling")},nextAll:function(a){return $.dir(a,"nextSibling")},prevAll:function(a){return $.dir(a,"previousSibling")},nextUntil:function(a,b,c){return $.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return $.dir(a,"previousSibling",c)},siblings:function(a){return $.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return $.sibling(a.firstChild)},contents:function(a){return $.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:$.merge([],a.childNodes)}},function(a,b){$.fn[a]=function(c,d){var e=$.map(this,b,c);return Ia.test(a)||(d=c),d&&"string"==typeof d&&(e=$.filter(d,e)),e=this.length>1&&!Ma[a]?$.unique(e):e,this.length>1&&Ja.test(a)&&(e=e.reverse()),this.pushStack(e,a,V.call(arguments).join(","))}}),$.extend({filter:function(a,b,c){return c&&(a=":not("+a+")"),1===b.length?$.find.matchesSelector(b[0],a)?[b[0]]:[]:$.find.matches(a,b)},dir:function(a,c,d){for(var e=[],f=a[c];f&&9!==f.nodeType&&(d===b||1!==f.nodeType||!$(f).is(d));)1===f.nodeType&&e.push(f),f=f[c];return e},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}});var Na="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",Oa=/ jQueryd+="(?:null|d+)"/g,Pa=/^s+/,Qa=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([w:]+)[^>]*)/>/gi,Ra=/<([w:]+)/,Sa=/<tbody/i,Ta=/<|&#?w+;/,Ua=/<(?:script|style|link)/i,Va=/<(?:script|object|embed|option|style)/i,Wa=new RegExp("<(?:"+Na+")[\s/>]","i"),Xa=/^(?:checkbox|radio)$/,Ya=/checkeds*(?:[^=]|=s*.checked.)/i,Za=//(java|ecma)script/i,$a=/^s*<!(?:[CDATA[|--)|[]-]{2}>s*$/g,_a={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]},ab=k(P),bb=ab.appendChild(P.createElement("div"));_a.optgroup=_a.option,_a.tbody=_a.tfoot=_a.colgroup=_a.caption=_a.thead,_a.th=_a.td,$.support.htmlSerialize||(_a._default=[1,"X<div>","</div>"]),$.fn.extend({text:function(a){return $.access(this,function(a){return a===b?$.text(this):this.empty().append((this[0]&&this[0].ownerDocument||P).createTextNode(a))},null,a,arguments.length)},wrapAll:function(a){if($.isFunction(a))return this.each(function(b){$(this).wrapAll(a.call(this,b))});if(this[0]){var b=$(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){for(var a=this;a.firstChild&&1===a.firstChild.nodeType;)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return $.isFunction(a)?this.each(function(b){$(this).wrapInner(a.call(this,b))}):this.each(function(){var b=$(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=$.isFunction(a);return this.each(function(c){$(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){$.nodeName(this,"body")||$(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){(1===this.nodeType||11===this.nodeType)&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){(1===this.nodeType||11===this.nodeType)&&this.insertBefore(a,this.firstChild)})},before:function(){if(!h(this[0]))return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=$.clean(arguments);return this.pushStack($.merge(a,this),"before",this.selector)}},after:function(){if(!h(this[0]))return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=$.clean(arguments);return this.pushStack($.merge(this,a),"after",this.selector)}},remove:function(a,b){for(var c,d=0;null!=(c=this[d]);d++)a&&!$.filter(a,[c]).length||(!b&&1===c.nodeType&&($.cleanData(c.getElementsByTagName("*")),$.cleanData([c])),c.parentNode&&c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)for(1===a.nodeType&&$.cleanData(a.getElementsByTagName("*"));a.firstChild;)a.removeChild(a.firstChild);return this},clone:function(a,b){return a=null!=a&&a,b=null==b?a:b,this.map(function(){return $.clone(this,a,b)})},html:function(a){return $.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return 1===c.nodeType?c.innerHTML.replace(Oa,""):b;if("string"==typeof a&&!Ua.test(a)&&($.support.htmlSerialize||!Wa.test(a))&&($.support.leadingWhitespace||!Pa.test(a))&&!_a[(Ra.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Qa,"<$1></$2>");try{for(;d<e;d++)c=this[d]||{},1===c.nodeType&&($.cleanData(c.getElementsByTagName("*")),c.innerHTML=a);c=0}catch(a){}}c&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(a){return h(this[0])?this.length?this.pushStack($($.isFunction(a)?a():a),"replaceWith",a):this:$.isFunction(a)?this.each(function(b){var c=$(this),d=c.html();c.replaceWith(a.call(this,b,d))}):("string"!=typeof a&&(a=$(a).detach()),this.each(function(){var b=this.nextSibling,c=this.parentNode;$(this).remove(),b?$(b).before(a):$(c).append(a)}))},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){a=[].concat.apply([],a);var e,f,g,h,i=0,j=a[0],k=[],m=this.length;if(!$.support.checkClone&&m>1&&"string"==typeof j&&Ya.test(j))return this.each(function(){$(this).domManip(a,c,d)});if($.isFunction(j))return this.each(function(e){var f=$(this);a[0]=j.call(this,e,c?f.html():b),f.domManip(a,c,d)});if(this[0]){if(e=$.buildFragment(a,this,k),g=e.fragment,f=g.firstChild,1===g.childNodes.length&&(g=f),f)for(c=c&&$.nodeName(f,"tr"),h=e.cacheable||m-1;i<m;i++)d.call(c&&$.nodeName(this[i],"table")?l(this[i],"tbody"):this[i],i===h?g:$.clone(g,!0,!0));g=f=null,k.length&&$.each(k,function(a,b){b.src?$.ajax?$.ajax({url:b.src,type:"GET",dataType:"script",async:!1,global:!1,throws:!0}):$.error("no ajax"):$.globalEval((b.text||b.textContent||b.innerHTML||"").replace($a,"")),b.parentNode&&b.parentNode.removeChild(b)})}return this}}),$.buildFragment=function(a,c,d){var e,f,g,h=a[0];return c=c||P,c=!c.nodeType&&c[0]||c,c=c.ownerDocument||c,1===a.length&&"string"==typeof h&&h.length<512&&c===P&&"<"===h.charAt(0)&&!Va.test(h)&&($.support.checkClone||!Ya.test(h))&&($.support.html5Clone||!Wa.test(h))&&(f=!0,e=$.fragments[h],g=e!==b),e||(e=c.createDocumentFragment(),$.clean(a,c,e,d),f&&($.fragments[h]=g&&e)),{fragment:e,cacheable:f}},$.fragments={},$.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){$.fn[a]=function(c){var d,e=0,f=[],g=$(c),h=g.length,i=1===this.length&&this[0].parentNode;if((null==i||i&&11===i.nodeType&&1===i.childNodes.length)&&1===h)return g[b](this[0]),this;for(;e<h;e++)d=(e>0?this.clone(!0):this).get(),$(g[e])[b](d),f=f.concat(d);return this.pushStack(f,a,g.selector)}}),$.extend({clone:function(a,b,c){var d,e,f,g;if($.support.html5Clone||$.isXMLDoc(a)||!Wa.test("<"+a.nodeName+">")?g=a.cloneNode(!0):(bb.innerHTML=a.outerHTML,bb.removeChild(g=bb.firstChild)),!($.support.noCloneEvent&&$.support.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||$.isXMLDoc(a)))for(n(a,g),d=o(a),e=o(g),f=0;d[f];++f)e[f]&&n(d[f],e[f]);if(b&&(m(a,g),c))for(d=o(a),e=o(g),f=0;d[f];++f)m(d[f],e[f]);return d=e=null,g},clean:function(a,b,c,d){var e,f,g,h,i,j,l,m,n,q,r,s=b===P&&ab,t=[];for(b&&"undefined"!=typeof b.createDocumentFragment||(b=P),e=0;null!=(g=a[e]);e++)if("number"==typeof g&&(g+=""),g){if("string"==typeof g)if(Ta.test(g)){for(s=s||k(b),l=b.createElement("div"),s.appendChild(l),g=g.replace(Qa,"<$1></$2>"),h=(Ra.exec(g)||["",""])[1].toLowerCase(),i=_a[h]||_a._default,j=i[0],l.innerHTML=i[1]+g+i[2];j--;)l=l.lastChild;if(!$.support.tbody)for(m=Sa.test(g),n="table"!==h||m?"<table>"!==i[1]||m?[]:l.childNodes:l.firstChild&&l.firstChild.childNodes,f=n.length-1;f>=0;--f)$.nodeName(n[f],"tbody")&&!n[f].childNodes.length&&n[f].parentNode.removeChild(n[f]);!$.support.leadingWhitespace&&Pa.test(g)&&l.insertBefore(b.createTextNode(Pa.exec(g)[0]),l.firstChild),g=l.childNodes,l.parentNode.removeChild(l)}else g=b.createTextNode(g);g.nodeType?t.push(g):$.merge(t,g)}if(l&&(g=l=s=null),!$.support.appendChecked)for(e=0;null!=(g=t[e]);e++)$.nodeName(g,"input")?p(g):"undefined"!=typeof g.getElementsByTagName&&$.grep(g.getElementsByTagName("input"),p);if(c)for(q=function(a){if(!a.type||Za.test(a.type))return d?d.push(a.parentNode?a.parentNode.removeChild(a):a):c.appendChild(a)},e=0;null!=(g=t[e]);e++)$.nodeName(g,"script")&&q(g)||(c.appendChild(g),"undefined"!=typeof g.getElementsByTagName&&(r=$.grep($.merge([],g.getElementsByTagName("script")),q),t.splice.apply(t,[e+1,0].concat(r)),e+=r.length));return t},cleanData:function(a,b){for(var c,d,e,f,g=0,h=$.expando,i=$.cache,j=$.support.deleteExpando,k=$.event.special;null!=(e=a[g]);g++)if((b||$.acceptData(e))&&(d=e[h],c=d&&i[d])){if(c.events)for(f in c.events)k[f]?$.event.remove(e,f):$.removeEvent(e,f,c.handle);i[d]&&(delete i[d],j?delete e[h]:e.removeAttribute?e.removeAttribute(h):e[h]=null,$.deletedIds.push(d))}}}),function(){var a,b;$.uaMatch=function(a){a=a.toLowerCase();var b=/(chrome)[ /]([w.]+)/.exec(a)||/(webkit)[ /]([w.]+)/.exec(a)||/(opera)(?:.*version|)[ /]([w.]+)/.exec(a)||/(msie) ([w.]+)/.exec(a)||a.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([w.]+)|)/.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},a=$.uaMatch(R.userAgent),b={},a.browser&&(b[a.browser]=!0,b.version=a.version),b.chrome?b.webkit=!0:b.webkit&&(b.safari=!0),$.browser=b,$.sub=function(){function a(b,c){return new a.fn.init(b,c)}$.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function c(c,d){return d&&d instanceof $&&!(d instanceof a)&&(d=a(d)),$.fn.init.call(this,c,d,b)},a.fn.init.prototype=a.fn;var b=a(P);return a}}();var cb,db,eb,fb=/alpha([^)]*)/i,gb=/opacity=([^)]*)/,hb=/^(top|right|bottom|left)$/,ib=/^(none|table(?!-c[ea]).+)/,jb=/^margin/,kb=new RegExp("^("+_+")(.*)$","i"),lb=new RegExp("^("+_+")(?!px)[a-z%]+$","i"),mb=new RegExp("^([-+])=("+_+")","i"),nb={},ob={position:"absolute",visibility:"hidden",display:"block"},pb={letterSpacing:0,fontWeight:400},qb=["Top","Right","Bottom","Left"],rb=["Webkit","O","Moz","ms"],sb=$.fn.toggle;$.fn.extend({css:function(a,c){return $.access(this,function(a,c,d){return d!==b?$.style(a,c,d):$.css(a,c)},a,c,arguments.length>1)},show:function(){return s(this,!0)},hide:function(){return s(this)},toggle:function(a,b){var c="boolean"==typeof a;return $.isFunction(a)&&$.isFunction(b)?sb.apply(this,arguments):this.each(function(){(c?a:r(this))?$(this).show():$(this).hide()})}}),$.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=cb(a,"opacity");return""===c?"1":c}}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{float:$.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var f,g,h,i=$.camelCase(c),j=a.style;if(c=$.cssProps[i]||($.cssProps[i]=q(j,i)),h=$.cssHooks[c]||$.cssHooks[i],d===b)return h&&"get"in h&&(f=h.get(a,!1,e))!==b?f:j[c];if(g=typeof d,"string"===g&&(f=mb.exec(d))&&(d=(f[1]+1)*f[2]+parseFloat($.css(a,c)),g="number"),!(null==d||"number"===g&&isNaN(d)||("number"===g&&!$.cssNumber[i]&&(d+="px"),h&&"set"in h&&(d=h.set(a,d,e))===b)))try{j[c]=d}catch(a){}}},css:function(a,c,d,e){var f,g,h,i=$.camelCase(c);return c=$.cssProps[i]||($.cssProps[i]=q(a.style,i)),h=$.cssHooks[c]||$.cssHooks[i],h&&"get"in h&&(f=h.get(a,!0,e)),f===b&&(f=cb(a,c)),"normal"===f&&c in pb&&(f=pb[c]),d||e!==b?(g=parseFloat(f),d||$.isNumeric(g)?g||0:f):f},swap:function(a,b,c){var d,e,f={};for(e in b)f[e]=a.style[e],a.style[e]=b[e];d=c.call(a);for(e in b)a.style[e]=f[e];return d}}),a.getComputedStyle?cb=function(b,c){var d,e,f,g,h=a.getComputedStyle(b,null),i=b.style;return h&&(d=h[c],""===d&&!$.contains(b.ownerDocument,b)&&(d=$.style(b,c)),lb.test(d)&&jb.test(c)&&(e=i.width,f=i.minWidth,g=i.maxWidth,i.minWidth=i.maxWidth=i.width=d,d=h.width,i.width=e,i.minWidth=f,i.maxWidth=g)),d}:P.documentElement.currentStyle&&(cb=function(a,b){var c,d,e=a.currentStyle&&a.currentStyle[b],f=a.style;return null==e&&f&&f[b]&&(e=f[b]),lb.test(e)&&!hb.test(b)&&(c=f.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),f.left="fontSize"===b?"1em":e,e=f.pixelLeft+"px",f.left=c,d&&(a.runtimeStyle.left=d)),""===e?"auto":e}),$.each(["height","width"],function(a,b){$.cssHooks[b]={get:function(a,c,d){if(c)return 0===a.offsetWidth&&ib.test(cb(a,"display"))?$.swap(a,ob,function(){return v(a,b,d)}):v(a,b,d)},set:function(a,c,d){return t(a,c,d?u(a,b,d,$.support.boxSizing&&"border-box"===$.css(a,"boxSizing")):0)}}}),$.support.opacity||($.cssHooks.opacity={get:function(a,b){return gb.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=$.isNumeric(b)?"alpha(opacity="+100*b+")":"",f=d&&d.filter||c.filter||"";c.zoom=1,b>=1&&""===$.trim(f.replace(fb,""))&&c.removeAttribute&&(c.removeAttribute("filter"),d&&!d.filter)||(c.filter=fb.test(f)?f.replace(fb,e):f+" "+e)}}),$(function(){$.support.reliableMarginRight||($.cssHooks.marginRight={get:function(a,b){return $.swap(a,{display:"inline-block"},function(){if(b)return cb(a,"marginRight")})}}),!$.support.pixelPosition&&$.fn.position&&$.each(["top","left"],function(a,b){$.cssHooks[b]={get:function(a,c){if(c){var d=cb(a,b);return lb.test(d)?$(a).position()[b]+"px":d}}}})}),$.expr&&$.expr.filters&&($.expr.filters.hidden=function(a){return 0===a.offsetWidth&&0===a.offsetHeight||!$.support.reliableHiddenOffsets&&"none"===(a.style&&a.style.display||cb(a,"display"))},$.expr.filters.visible=function(a){return!$.expr.filters.hidden(a)}),$.each({margin:"",padding:"",border:"Width"},function(a,b){$.cssHooks[a+b]={expand:function(c){var d,e="string"==typeof c?c.split(" "):[c],f={};for(d=0;d<4;d++)f[a+qb[d]+b]=e[d]||e[d-2]||e[0];return f}},jb.test(a)||($.cssHooks[a+b].set=t)});var tb=/%20/g,ub=/[]$/,vb=/r?n/g,wb=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,xb=/^(?:select|textarea)/i;$.fn.extend({serialize:function(){return $.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?$.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||xb.test(this.nodeName)||wb.test(this.type))}).map(function(a,b){var c=$(this).val();return null==c?null:$.isArray(c)?$.map(c,function(a,c){return{name:b.name,value:a.replace(vb,"rn")}}):{name:b.name,value:c.replace(vb,"rn")}}).get()}}),$.param=function(a,c){var d,e=[],f=function(a,b){b=$.isFunction(b)?b():null==b?"":b,e[e.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(c===b&&(c=$.ajaxSettings&&$.ajaxSettings.traditional),$.isArray(a)||a.jquery&&!$.isPlainObject(a))$.each(a,function(){f(this.name,this.value)});else for(d in a)x(d,a[d],c,f);return e.join("&").replace(tb,"+")};var yb,zb,Ab=/#.*$/,Bb=/^(.*?):[ t]*([^rn]*)r?$/gm,Cb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Db=/^(?:GET|HEAD)$/,Eb=/^///,Fb=/?/,Gb=/<scriptb[^<]*(?:(?!</script>)<[^<]*)*</script>/gi,Hb=/([?&])_=[^&]*/,Ib=/^([w+.-]+:)(?://([^/?#:]*)(?::(d+)|)|)/,Jb=$.fn.load,Kb={},Lb={},Mb=["*/"]+["*"];try{zb=Q.href}catch(a){zb=P.createElement("a"),zb.href="",zb=zb.href}yb=Ib.exec(zb.toLowerCase())||[],$.fn.load=function(a,c,d){if("string"!=typeof a&&Jb)return Jb.apply(this,arguments);if(!this.length)return this;var e,f,g,h=this,i=a.indexOf(" ");return i>=0&&(e=a.slice(i,a.length),a=a.slice(0,i)),$.isFunction(c)?(d=c,c=b):c&&"object"==typeof c&&(f="POST"),$.ajax({url:a,type:f,dataType:"html",data:c,complete:function(a,b){d&&h.each(d,g||[a.responseText,b,a])}}).done(function(a){g=arguments,h.html(e?$("<div>").append(a.replace(Gb,"")).find(e):a)}),this},$.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){$.fn[b]=function(a){return this.on(b,a)}}),$.each(["get","post"],function(a,c){$[c]=function(a,d,e,f){return $.isFunction(d)&&(f=f||e,e=d,d=b),$.ajax({type:c,url:a,data:d,success:e,dataType:f})}}),$.extend({getScript:function(a,c){return $.get(a,b,c,"script")},getJSON:function(a,b,c){return $.get(a,b,c,"json")},ajaxSetup:function(a,b){return b?A(a,$.ajaxSettings):(b=a,a=$.ajaxSettings),A(a,b),a},ajaxSettings:{url:zb,isLocal:Cb.test(yb[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":Mb},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":$.parseJSON,"text xml":$.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:y(Kb),ajaxTransport:y(Lb),ajax:function(a,c){function d(a,c,d,g){var j,l,s,t,v,x=c;2!==u&&(u=2,i&&clearTimeout(i),h=b,f=g||"",w.readyState=a>0?4:0,d&&(t=B(m,w,d)),a>=200&&a<300||304===a?(m.ifModified&&(v=w.getResponseHeader("Last-Modified"),v&&($.lastModified[e]=v),v=w.getResponseHeader("Etag"),v&&($.etag[e]=v)),304===a?(x="notmodified",j=!0):(j=C(m,t),x=j.state,l=j.data,s=j.error,j=!s)):(s=x,x&&!a||(x="error",a<0&&(a=0))),w.status=a,w.statusText=(c||x)+"",j?p.resolveWith(n,[l,x,w]):p.rejectWith(n,[w,x,s]),w.statusCode(r),r=b,k&&o.trigger("ajax"+(j?"Success":"Error"),[w,m,j?l:s]),q.fireWith(n,[w,x]),k&&(o.trigger("ajaxComplete",[w,m]),--$.active||$.event.trigger("ajaxStop")))}"object"==typeof a&&(c=a,a=b),c=c||{};var e,f,g,h,i,j,k,l,m=$.ajaxSetup({},c),n=m.context||m,o=n!==m&&(n.nodeType||n instanceof $)?$(n):$.event,p=$.Deferred(),q=$.Callbacks("once memory"),r=m.statusCode||{},s={},t={},u=0,v="canceled",w={readyState:0,setRequestHeader:function(a,b){if(!u){var c=a.toLowerCase();a=t[c]=t[c]||a,s[a]=b}return this},getAllResponseHeaders:function(){return 2===u?f:null},getResponseHeader:function(a){var c;if(2===u){if(!g)for(g={};c=Bb.exec(f);)g[c[1].toLowerCase()]=c[2];c=g[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){return u||(m.mimeType=a),this},abort:function(a){return a=a||v,h&&h.abort(a),d(0,a),this}};if(p.promise(w),w.success=w.done,w.error=w.fail,w.complete=q.add,w.statusCode=function(a){if(a){var b;if(u<2)for(b in a)r[b]=[r[b],a[b]];else b=a[w.status],w.always(b)}return this},m.url=((a||m.url)+"").replace(Ab,"").replace(Eb,yb[1]+"//"),m.dataTypes=$.trim(m.dataType||"*").toLowerCase().split(ba),null==m.crossDomain&&(j=Ib.exec(m.url.toLowerCase())||!1,m.crossDomain=j&&j.join(":")+(j[3]?"":"http:"===j[1]?80:443)!==yb.join(":")+(yb[3]?"":"http:"===yb[1]?80:443)),m.data&&m.processData&&"string"!=typeof m.data&&(m.data=$.param(m.data,m.traditional)),z(Kb,m,c,w),2===u)return w;if(k=m.global,m.type=m.type.toUpperCase(),m.hasContent=!Db.test(m.type),k&&0===$.active++&&$.event.trigger("ajaxStart"),!m.hasContent&&(m.data&&(m.url+=(Fb.test(m.url)?"&":"?")+m.data,delete m.data),e=m.url,m.cache===!1)){var x=$.now(),y=m.url.replace(Hb,"$1_="+x);m.url=y+(y===m.url?(Fb.test(m.url)?"&":"?")+"_="+x:"")}(m.data&&m.hasContent&&m.contentType!==!1||c.contentType)&&w.setRequestHeader("Content-Type",m.contentType),m.ifModified&&(e=e||m.url,$.lastModified[e]&&w.setRequestHeader("If-Modified-Since",$.lastModified[e]),$.etag[e]&&w.setRequestHeader("If-None-Match",$.etag[e])),w.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+Mb+"; q=0.01":""):m.accepts["*"]);for(l in m.headers)w.setRequestHeader(l,m.headers[l]);if(!m.beforeSend||m.beforeSend.call(n,w,m)!==!1&&2!==u){v="abort";for(l in{success:1,error:1,complete:1})w[l](m[l]);if(h=z(Lb,m,c,w)){w.readyState=1,k&&o.trigger("ajaxSend",[w,m]),m.async&&m.timeout>0&&(i=setTimeout(function(){w.abort("timeout")},m.timeout));try{u=1,h.send(s,d)}catch(a){if(!(u<2))throw a;d(-1,a)}}else d(-1,"No Transport");return w}return w.abort()},active:0,lastModified:{},etag:{}});var Nb=[],Ob=/?/,Pb=/(=)?(?=&|$)|??/,Qb=$.now();$.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Nb.pop()||$.expando+"_"+Qb++;return this[a]=!0,a}}),$.ajaxPrefilter("json jsonp",function(c,d,e){var f,g,h,i=c.data,j=c.url,k=c.jsonp!==!1,l=k&&Pb.test(j),m=k&&!l&&"string"==typeof i&&!(c.contentType||"").indexOf("application/x-www-form-urlencoded")&&Pb.test(i);if("jsonp"===c.dataTypes[0]||l||m)return f=c.jsonpCallback=$.isFunction(c.jsonpCallback)?c.jsonpCallback():c.jsonpCallback,g=a[f],l?c.url=j.replace(Pb,"$1"+f):m?c.data=i.replace(Pb,"$1"+f):k&&(c.url+=(Ob.test(j)?"&":"?")+c.jsonp+"="+f),c.converters["script json"]=function(){return h||$.error(f+" was not called"),h[0]},c.dataTypes[0]="json",a[f]=function(){h=arguments},e.always(function(){a[f]=g,c[f]&&(c.jsonpCallback=d.jsonpCallback,Nb.push(f)),h&&$.isFunction(g)&&g(h[0]),h=g=b}),"script"}),$.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){return $.globalEval(a),a}}}),$.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),$.ajaxTransport("script",function(a){if(a.crossDomain){var c,d=P.head||P.getElementsByTagName("head")[0]||P.documentElement;return{send:function(e,f){c=P.createElement("script"),c.async="async",a.scriptCharset&&(c.charset=a.scriptCharset),c.src=a.url,c.onload=c.onreadystatechange=function(a,e){(e||!c.readyState||/loaded|complete/.test(c.readyState))&&(c.onload=c.onreadystatechange=null,d&&c.parentNode&&d.removeChild(c),c=b,e||f(200,"success"))},d.insertBefore(c,d.firstChild)},abort:function(){c&&c.onload(0,1)}}}});var Rb,Sb=!!a.ActiveXObject&&function(){for(var a in Rb)Rb[a](0,1)},Tb=0;$.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&D()||E()}:D,function(a){$.extend($.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}($.ajaxSettings.xhr()),$.support.ajax&&$.ajaxTransport(function(c){if(!c.crossDomain||$.support.cors){var d;return{send:function(e,f){var g,h,i=c.xhr();if(c.username?i.open(c.type,c.url,c.async,c.username,c.password):i.open(c.type,c.url,c.async),c.xhrFields)for(h in c.xhrFields)i[h]=c.xhrFields[h];c.mimeType&&i.overrideMimeType&&i.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(h in e)i.setRequestHeader(h,e[h])}catch(a){}i.send(c.hasContent&&c.data||null),d=function(a,e){var h,j,k,l,m;try{if(d&&(e||4===i.readyState))if(d=b,g&&(i.onreadystatechange=$.noop,Sb&&delete Rb[g]),e)4!==i.readyState&&i.abort();else{h=i.status,k=i.getAllResponseHeaders(),l={},m=i.responseXML,m&&m.documentElement&&(l.xml=m);try{l.text=i.responseText}catch(a){}try{j=i.statusText}catch(a){j=""}h||!c.isLocal||c.crossDomain?1223===h&&(h=204):h=l.text?200:404}}catch(a){e||f(-1,a)}l&&f(h,j,l,k)},c.async?4===i.readyState?setTimeout(d,0):(g=++Tb,Sb&&(Rb||(Rb={},$(a).unload(Sb)),Rb[g]=d),i.onreadystatechange=d):d()},abort:function(){d&&d(0,1)}}}});var Ub,Vb,Wb=/^(?:toggle|show|hide)$/,Xb=new RegExp("^(?:([-+])=|)("+_+")([a-z%]*)$","i"),Yb=/queueHooks$/,Zb=[J],$b={"*":[function(a,b){var c,d,e=this.createTween(a,b),f=Xb.exec(b),g=e.cur(),h=+g||0,i=1,j=20;if(f){if(c=+f[2],d=f[3]||($.cssNumber[a]?"":"px"),"px"!==d&&h){h=$.css(e.elem,a,!0)||c||1;do i=i||".5",h/=i,$.style(e.elem,a,h+d);while(i!==(i=e.cur()/g)&&1!==i&&--j)}e.unit=d,e.start=h,e.end=f[1]?h+(f[1]+1)*c:c}return e}]};$.Animation=$.extend(H,{tweener:function(a,b){$.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;d<e;d++)c=a[d],$b[c]=$b[c]||[],$b[c].unshift(b)},prefilter:function(a,b){b?Zb.unshift(a):Zb.push(a)}}),$.Tween=K,K.prototype={constructor:K,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||($.cssNumber[c]?"":"px")},cur:function(){var a=K.propHooks[this.prop];return a&&a.get?a.get(this):K.propHooks._default.get(this)},run:function(a){var b,c=K.propHooks[this.prop];return this.options.duration?this.pos=b=$.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):K.propHooks._default.set(this),this}},K.prototype.init.prototype=K.prototype,K.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=$.css(a.elem,a.prop,!1,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){$.fx.step[a.prop]?$.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[$.cssProps[a.prop]]||$.cssHooks[a.prop])?$.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},K.propHooks.scrollTop=K.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},$.each(["toggle","show","hide"],function(a,b){var c=$.fn[b];$.fn[b]=function(d,e,f){return null==d||"boolean"==typeof d||!a&&$.isFunction(d)&&$.isFunction(e)?c.apply(this,arguments):this.animate(L(b,!0),d,e,f)}}),$.fn.extend({fadeTo:function(a,b,c,d){return this.filter(r).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=$.isEmptyObject(a),f=$.speed(b,c,d),g=function(){var b=H(this,$.extend({},a),f);e&&b.stop(!0)};return e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,c,d){var e=function(a){var b=a.stop;delete a.stop,b(d)};return"string"!=typeof a&&(d=c,c=a,a=b),c&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,c=null!=a&&a+"queueHooks",f=$.timers,g=$._data(this);if(c)g[c]&&g[c].stop&&e(g[c]);else for(c in g)g[c]&&g[c].stop&&Yb.test(c)&&e(g[c]);for(c=f.length;c--;)f[c].elem===this&&(null==a||f[c].queue===a)&&(f[c].anim.stop(d),b=!1,f.splice(c,1));(b||!d)&&$.dequeue(this,a)})}}),$.each({slideDown:L("show"),slideUp:L("hide"),slideToggle:L("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){$.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),$.speed=function(a,b,c){var d=a&&"object"==typeof a?$.extend({},a):{complete:c||!c&&b||$.isFunction(a)&&a,duration:a,easing:c&&b||b&&!$.isFunction(b)&&b};return d.duration=$.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in $.fx.speeds?$.fx.speeds[d.duration]:$.fx.speeds._default,null!=d.queue&&d.queue!==!0||(d.queue="fx"),d.old=d.complete,d.complete=function(){$.isFunction(d.old)&&d.old.call(this),d.queue&&$.dequeue(this,d.queue)},d},$.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},$.timers=[],$.fx=K.prototype.init,$.fx.tick=function(){for(var a,b=$.timers,c=0;c<b.length;c++)a=b[c],!a()&&b[c]===a&&b.splice(c--,1);b.length||$.fx.stop()},$.fx.timer=function(a){a()&&$.timers.push(a)&&!Vb&&(Vb=setInterval($.fx.tick,$.fx.interval))},$.fx.interval=13,$.fx.stop=function(){clearInterval(Vb),Vb=null},$.fx.speeds={slow:600,fast:200,_default:400},$.fx.step={},$.expr&&$.expr.filters&&($.expr.filters.animated=function(a){return $.grep($.timers,function(b){return a===b.elem}).length});var _b=/^(?:body|html)$/i;$.fn.offset=function(a){if(arguments.length)return a===b?this:this.each(function(b){$.offset.setOffset(this,a,b)});var c,d,e,f,g,h,i,j={top:0,left:0},k=this[0],l=k&&k.ownerDocument;if(l)return(d=l.body)===k?$.offset.bodyOffset(k):(c=l.documentElement,$.contains(c,k)?("undefined"!=typeof k.getBoundingClientRect&&(j=k.getBoundingClientRect()),e=M(l),f=c.clientTop||d.clientTop||0,g=c.clientLeft||d.clientLeft||0,h=e.pageYOffset||c.scrollTop,i=e.pageXOffset||c.scrollLeft,{top:j.top+h-f,left:j.left+i-g}):j)},$.offset={bodyOffset:function(a){
var b=a.offsetTop,c=a.offsetLeft;return $.support.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat($.css(a,"marginTop"))||0,c+=parseFloat($.css(a,"marginLeft"))||0),{top:b,left:c}},setOffset:function(a,b,c){var d=$.css(a,"position");"static"===d&&(a.style.position="relative");var l,m,e=$(a),f=e.offset(),g=$.css(a,"top"),h=$.css(a,"left"),i=("absolute"===d||"fixed"===d)&&$.inArray("auto",[g,h])>-1,j={},k={};i?(k=e.position(),l=k.top,m=k.left):(l=parseFloat(g)||0,m=parseFloat(h)||0),$.isFunction(b)&&(b=b.call(a,c,f)),null!=b.top&&(j.top=b.top-f.top+l),null!=b.left&&(j.left=b.left-f.left+m),"using"in b?b.using.call(a,j):e.css(j)}},$.fn.extend({position:function(){if(this[0]){var a=this[0],b=this.offsetParent(),c=this.offset(),d=_b.test(b[0].nodeName)?{top:0,left:0}:b.offset();return c.top-=parseFloat($.css(a,"marginTop"))||0,c.left-=parseFloat($.css(a,"marginLeft"))||0,d.top+=parseFloat($.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat($.css(b[0],"borderLeftWidth"))||0,{top:c.top-d.top,left:c.left-d.left}}},offsetParent:function(){return this.map(function(){for(var a=this.offsetParent||P.body;a&&!_b.test(a.nodeName)&&"static"===$.css(a,"position");)a=a.offsetParent;return a||P.body})}}),$.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);$.fn[a]=function(e){return $.access(this,function(a,e,f){var g=M(a);return f===b?g?c in g?g[c]:g.document.documentElement[e]:a[e]:void(g?g.scrollTo(d?$(g).scrollLeft():f,d?f:$(g).scrollTop()):a[e]=f)},a,e,arguments.length,null)}}),$.each({Height:"height",Width:"width"},function(a,c){$.each({padding:"inner"+a,content:c,"":"outer"+a},function(d,e){$.fn[e]=function(e,f){var g=arguments.length&&(d||"boolean"!=typeof e),h=d||(e===!0||f===!0?"margin":"border");return $.access(this,function(c,d,e){var f;return $.isWindow(c)?c.document.documentElement["client"+a]:9===c.nodeType?(f=c.documentElement,Math.max(c.body["scroll"+a],f["scroll"+a],c.body["offset"+a],f["offset"+a],f["client"+a])):e===b?$.css(c,d,e,h):$.style(c,d,e,h)},c,g?e:b,g,null)}})}),a.jQuery=a.$=$,"function"==typeof define&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return $})}(window),function(a,b){function c(b,c){var e=b.nodeName.toLowerCase();if("area"===e){var h,f=b.parentNode,g=f.name;return!(!b.href||!g||"map"!==f.nodeName.toLowerCase())&&(h=a("img[usemap=#"+g+"]")[0],!!h&&d(h))}return(/input|select|textarea|button|object/.test(e)?!b.disabled:"a"==e?b.href||c:c)&&d(b)}function d(b){return!a(b).parents().andSelf().filter(function(){return"hidden"===a.curCSS(this,"visibility")||a.expr.filters.hidden(this)}).length}a.ui=a.ui||{},a.ui.version||(a.extend(a.ui,{version:"1.8.24",keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91}}),a.fn.extend({propAttr:a.fn.prop||a.fn.attr,_focus:a.fn.focus,focus:function(b,c){return"number"==typeof b?this.each(function(){var d=this;setTimeout(function(){a(d).focus(),c&&c.call(d)},b)}):this._focus.apply(this,arguments)},scrollParent:function(){var b;return b=a.browser.msie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(a.curCSS(this,"position",1))&&/(auto|scroll)/.test(a.curCSS(this,"overflow",1)+a.curCSS(this,"overflow-y",1)+a.curCSS(this,"overflow-x",1))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(a.curCSS(this,"overflow",1)+a.curCSS(this,"overflow-y",1)+a.curCSS(this,"overflow-x",1))}).eq(0),/fixed/.test(this.css("position"))||!b.length?a(document):b},zIndex:function(c){if(c!==b)return this.css("zIndex",c);if(this.length)for(var e,f,d=a(this[0]);d.length&&d[0]!==document;){if(e=d.css("position"),("absolute"===e||"relative"===e||"fixed"===e)&&(f=parseInt(d.css("zIndex"),10),!isNaN(f)&&0!==f))return f;d=d.parent()}return 0},disableSelection:function(){return this.bind((a.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(a){a.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}}),a("<a>").outerWidth(1).jquery||a.each(["Width","Height"],function(c,d){function e(b,c,d,e){return a.each(f,function(){c-=parseFloat(a.curCSS(b,"padding"+this,!0))||0,d&&(c-=parseFloat(a.curCSS(b,"border"+this+"Width",!0))||0),e&&(c-=parseFloat(a.curCSS(b,"margin"+this,!0))||0)}),c}var f="Width"===d?["Left","Right"]:["Top","Bottom"],g=d.toLowerCase(),h={innerWidth:a.fn.innerWidth,innerHeight:a.fn.innerHeight,outerWidth:a.fn.outerWidth,outerHeight:a.fn.outerHeight};a.fn["inner"+d]=function(c){return c===b?h["inner"+d].call(this):this.each(function(){a(this).css(g,e(this,c)+"px")})},a.fn["outer"+d]=function(b,c){return"number"!=typeof b?h["outer"+d].call(this,b):this.each(function(){a(this).css(g,e(this,b,!0,c)+"px")})}}),a.extend(a.expr[":"],{data:a.expr.createPseudo?a.expr.createPseudo(function(b){return function(c){return!!a.data(c,b)}}):function(b,c,d){return!!a.data(b,d[3])},focusable:function(b){return c(b,!isNaN(a.attr(b,"tabindex")))},tabbable:function(b){var d=a.attr(b,"tabindex"),e=isNaN(d);return(e||d>=0)&&c(b,!e)}}),a(function(){var b=document.body,c=b.appendChild(c=document.createElement("div"));c.offsetHeight,a.extend(c.style,{minHeight:"100px",height:"auto",padding:0,borderWidth:0}),a.support.minHeight=100===c.offsetHeight,a.support.selectstart="onselectstart"in c,b.removeChild(c).style.display="none"}),a.curCSS||(a.curCSS=a.css),a.extend(a.ui,{plugin:{add:function(b,c,d){var e=a.ui[b].prototype;for(var f in d)e.plugins[f]=e.plugins[f]||[],e.plugins[f].push([c,d[f]])},call:function(a,b,c){var d=a.plugins[b];if(d&&a.element[0].parentNode)for(var e=0;e<d.length;e++)a.options[d[e][0]]&&d[e][1].apply(a.element,c)}},contains:function(a,b){return document.compareDocumentPosition?16&a.compareDocumentPosition(b):a!==b&&a.contains(b)},hasScroll:function(b,c){if("hidden"===a(b).css("overflow"))return!1;var d=c&&"left"===c?"scrollLeft":"scrollTop",e=!1;return b[d]>0||(b[d]=1,e=b[d]>0,b[d]=0,e)},isOverAxis:function(a,b,c){return a>b&&a<b+c},isOver:function(b,c,d,e,f,g){return a.ui.isOverAxis(b,d,f)&&a.ui.isOverAxis(c,e,g)}}))}(jQuery),function(a,b){if(a.cleanData){var c=a.cleanData;a.cleanData=function(b){for(var e,d=0;null!=(e=b[d]);d++)try{a(e).triggerHandler("remove")}catch(a){}c(b)}}else{var d=a.fn.remove;a.fn.remove=function(b,c){return this.each(function(){return c||(!b||a.filter(b,[this]).length)&&a("*",this).add([this]).each(function(){try{a(this).triggerHandler("remove")}catch(a){}}),d.call(a(this),b,c)})}}a.widget=function(b,c,d){var f,e=b.split(".")[0];b=b.split(".")[1],f=e+"-"+b,d||(d=c,c=a.Widget),a.expr[":"][f]=function(c){return!!a.data(c,b)},a[e]=a[e]||{},a[e][b]=function(a,b){arguments.length&&this._createWidget(a,b)};var g=new c;g.options=a.extend(!0,{},g.options),a[e][b].prototype=a.extend(!0,g,{namespace:e,widgetName:b,widgetEventPrefix:a[e][b].prototype.widgetEventPrefix||b,widgetBaseClass:f},d),a.widget.bridge(b,a[e][b])},a.widget.bridge=function(c,d){a.fn[c]=function(e){var f="string"==typeof e,g=Array.prototype.slice.call(arguments,1),h=this;return e=!f&&g.length?a.extend.apply(null,[!0,e].concat(g)):e,f&&"_"===e.charAt(0)?h:(f?this.each(function(){var d=a.data(this,c),f=d&&a.isFunction(d[e])?d[e].apply(d,g):d;if(f!==d&&f!==b)return h=f,!1}):this.each(function(){var b=a.data(this,c);b?b.option(e||{})._init():a.data(this,c,new d(e,this))}),h)}},a.Widget=function(a,b){arguments.length&&this._createWidget(a,b)},a.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",options:{disabled:!1},_createWidget:function(b,c){a.data(c,this.widgetName,this),this.element=a(c),this.options=a.extend(!0,{},this.options,this._getCreateOptions(),b);var d=this;this.element.bind("remove."+this.widgetName,function(){d.destroy()}),this._create(),this._trigger("create"),this._init()},_getCreateOptions:function(){return a.metadata&&a.metadata.get(this.element[0])[this.widgetName]},_create:function(){},_init:function(){},destroy:function(){this.element.unbind("."+this.widgetName).removeData(this.widgetName),this.widget().unbind("."+this.widgetName).removeAttr("aria-disabled").removeClass(this.widgetBaseClass+"-disabled ui-state-disabled")},widget:function(){return this.element},option:function(c,d){var e=c;if(0===arguments.length)return a.extend({},this.options);if("string"==typeof c){if(d===b)return this.options[c];e={},e[c]=d}return this._setOptions(e),this},_setOptions:function(b){var c=this;return a.each(b,function(a,b){c._setOption(a,b)}),this},_setOption:function(a,b){return this.options[a]=b,"disabled"===a&&this.widget()[b?"addClass":"removeClass"](this.widgetBaseClass+"-disabled ui-state-disabled").attr("aria-disabled",b),this},enable:function(){return this._setOption("disabled",!1)},disable:function(){return this._setOption("disabled",!0)},_trigger:function(b,c,d){var e,f,g=this.options[b];if(d=d||{},c=a.Event(c),c.type=(b===this.widgetEventPrefix?b:this.widgetEventPrefix+b).toLowerCase(),c.target=this.element[0],f=c.originalEvent,f)for(e in f)e in c||(c[e]=f[e]);return this.element.trigger(c,d),!(a.isFunction(g)&&g.call(this.element[0],c,d)===!1||c.isDefaultPrevented())}}}(jQuery),function(a,b){var c=!1;a(document).mouseup(function(a){c=!1}),a.widget("ui.mouse",{options:{cancel:":input,option",distance:1,delay:0},_mouseInit:function(){var b=this;this.element.bind("mousedown."+this.widgetName,function(a){return b._mouseDown(a)}).bind("click."+this.widgetName,function(c){if(!0===a.data(c.target,b.widgetName+".preventClickEvent"))return a.removeData(c.target,b.widgetName+".preventClickEvent"),c.stopImmediatePropagation(),!1}),this.started=!1},_mouseDestroy:function(){this.element.unbind("."+this.widgetName),this._mouseMoveDelegate&&a(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(b){if(!c){this._mouseStarted&&this._mouseUp(b),this._mouseDownEvent=b;var d=this,e=1==b.which,f=!("string"!=typeof this.options.cancel||!b.target.nodeName)&&a(b.target).closest(this.options.cancel).length;return!(e&&!f&&this._mouseCapture(b))||(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){d.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(b)&&this._mouseDelayMet(b)&&(this._mouseStarted=this._mouseStart(b)!==!1,!this._mouseStarted)?(b.preventDefault(),!0):(!0===a.data(b.target,this.widgetName+".preventClickEvent")&&a.removeData(b.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(a){return d._mouseMove(a)},this._mouseUpDelegate=function(a){return d._mouseUp(a)},a(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate),b.preventDefault(),c=!0,!0))}},_mouseMove:function(b){return!a.browser.msie||document.documentMode>=9||b.button?this._mouseStarted?(this._mouseDrag(b),b.preventDefault()):(this._mouseDistanceMet(b)&&this._mouseDelayMet(b)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,b)!==!1,this._mouseStarted?this._mouseDrag(b):this._mouseUp(b)),!this._mouseStarted):this._mouseUp(b)},_mouseUp:function(b){return a(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,b.target==this._mouseDownEvent.target&&a.data(b.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(b)),!1},_mouseDistanceMet:function(a){return Math.max(Math.abs(this._mouseDownEvent.pageX-a.pageX),Math.abs(this._mouseDownEvent.pageY-a.pageY))>=this.options.distance},_mouseDelayMet:function(a){return this.mouseDelayMet},_mouseStart:function(a){},_mouseDrag:function(a){},_mouseStop:function(a){},_mouseCapture:function(a){return!0}})}(jQuery),function(a,b){a.ui=a.ui||{};var c=/left|center|right/,d=/top|center|bottom/,e="center",f={},g=a.fn.position,h=a.fn.offset;a.fn.position=function(b){if(!b||!b.of)return g.apply(this,arguments);b=a.extend({},b);var l,m,n,h=a(b.of),i=h[0],j=(b.collision||"flip").split(" "),k=b.offset?b.offset.split(" "):[0,0];return 9===i.nodeType?(l=h.width(),m=h.height(),n={top:0,left:0}):i.setTimeout?(l=h.width(),m=h.height(),n={top:h.scrollTop(),left:h.scrollLeft()}):i.preventDefault?(b.at="left top",l=m=0,n={top:b.of.pageY,left:b.of.pageX}):(l=h.outerWidth(),m=h.outerHeight(),n=h.offset()),a.each(["my","at"],function(){var a=(b[this]||"").split(" ");1===a.length&&(a=c.test(a[0])?a.concat([e]):d.test(a[0])?[e].concat(a):[e,e]),a[0]=c.test(a[0])?a[0]:e,a[1]=d.test(a[1])?a[1]:e,b[this]=a}),1===j.length&&(j[1]=j[0]),k[0]=parseInt(k[0],10)||0,1===k.length&&(k[1]=k[0]),k[1]=parseInt(k[1],10)||0,"right"===b.at[0]?n.left+=l:b.at[0]===e&&(n.left+=l/2),"bottom"===b.at[1]?n.top+=m:b.at[1]===e&&(n.top+=m/2),n.left+=k[0],n.top+=k[1],this.each(function(){var r,c=a(this),d=c.outerWidth(),g=c.outerHeight(),h=parseInt(a.curCSS(this,"marginLeft",!0))||0,i=parseInt(a.curCSS(this,"marginTop",!0))||0,o=d+h+(parseInt(a.curCSS(this,"marginRight",!0))||0),p=g+i+(parseInt(a.curCSS(this,"marginBottom",!0))||0),q=a.extend({},n);"right"===b.my[0]?q.left-=d:b.my[0]===e&&(q.left-=d/2),"bottom"===b.my[1]?q.top-=g:b.my[1]===e&&(q.top-=g/2),f.fractions||(q.left=Math.round(q.left),q.top=Math.round(q.top)),r={left:q.left-h,top:q.top-i},a.each(["left","top"],function(c,e){a.ui.position[j[c]]&&a.ui.position[j[c]][e](q,{targetWidth:l,targetHeight:m,elemWidth:d,elemHeight:g,collisionPosition:r,collisionWidth:o,collisionHeight:p,offset:k,my:b.my,at:b.at})}),a.fn.bgiframe&&c.bgiframe(),c.offset(a.extend(q,{using:b.using}))})},a.ui.position={fit:{left:function(b,c){var d=a(window),e=c.collisionPosition.left+c.collisionWidth-d.width()-d.scrollLeft();b.left=e>0?b.left-e:Math.max(b.left-c.collisionPosition.left,b.left)},top:function(b,c){var d=a(window),e=c.collisionPosition.top+c.collisionHeight-d.height()-d.scrollTop();b.top=e>0?b.top-e:Math.max(b.top-c.collisionPosition.top,b.top)}},flip:{left:function(b,c){if(c.at[0]!==e){var d=a(window),f=c.collisionPosition.left+c.collisionWidth-d.width()-d.scrollLeft(),g="left"===c.my[0]?-c.elemWidth:"right"===c.my[0]?c.elemWidth:0,h="left"===c.at[0]?c.targetWidth:-c.targetWidth,i=-2*c.offset[0];b.left+=c.collisionPosition.left<0?g+h+i:f>0?g+h+i:0}},top:function(b,c){if(c.at[1]!==e){var d=a(window),f=c.collisionPosition.top+c.collisionHeight-d.height()-d.scrollTop(),g="top"===c.my[1]?-c.elemHeight:"bottom"===c.my[1]?c.elemHeight:0,h="top"===c.at[1]?c.targetHeight:-c.targetHeight,i=-2*c.offset[1];b.top+=c.collisionPosition.top<0?g+h+i:f>0?g+h+i:0}}}},a.offset.setOffset||(a.offset.setOffset=function(b,c){/static/.test(a.curCSS(b,"position"))&&(b.style.position="relative");var d=a(b),e=d.offset(),f=parseInt(a.curCSS(b,"top",!0),10)||0,g=parseInt(a.curCSS(b,"left",!0),10)||0,h={top:c.top-e.top+f,left:c.left-e.left+g};"using"in c?c.using.call(b,h):d.css(h)},a.fn.offset=function(b){var c=this[0];return c&&c.ownerDocument?b?a.isFunction(b)?this.each(function(c){a(this).offset(b.call(this,c,a(this).offset()))}):this.each(function(){a.offset.setOffset(this,b)}):h.call(this):null}),a.curCSS||(a.curCSS=a.css),function(){var d,e,g,h,i,b=document.getElementsByTagName("body")[0],c=document.createElement("div");d=document.createElement(b?"div":"body"),g={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"},b&&a.extend(g,{position:"absolute",left:"-1000px",top:"-1000px"});for(var j in g)d.style[j]=g[j];d.appendChild(c),e=b||document.documentElement,e.insertBefore(d,e.firstChild),c.style.cssText="position: absolute; left: 10.7432222px; top: 10.432325px; height: 30px; width: 201px;",h=a(c).offset(function(a,b){return b}).offset(),d.innerHTML="",e.removeChild(d),i=h.top+h.left+(b?2e3:0),f.fractions=i>21&&i<22}()}(jQuery),function(a,b){a.widget("ui.draggable",a.ui.mouse,{widgetEventPrefix:"drag",options:{addClasses:!0,appendTo:"parent",axis:!1,connectToSortable:!1,containment:!1,cursor:"auto",cursorAt:!1,grid:!1,handle:!1,helper:"original",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:"default",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:"both",snapTolerance:20,stack:!1,zIndex:!1},_create:function(){"original"==this.options.helper&&!/^(?:r|a|f)/.test(this.element.css("position"))&&(this.element[0].style.position="relative"),this.options.addClasses&&this.element.addClass("ui-draggable"),this.options.disabled&&this.element.addClass("ui-draggable-disabled"),this._mouseInit()},destroy:function(){if(this.element.data("draggable"))return this.element.removeData("draggable").unbind(".draggable").removeClass("ui-draggable ui-draggable-dragging ui-draggable-disabled"),this._mouseDestroy(),this},_mouseCapture:function(b){var c=this.options;return!(this.helper||c.disabled||a(b.target).is(".ui-resizable-handle"))&&(this.handle=this._getHandle(b),!!this.handle&&(c.iframeFix&&a(c.iframeFix===!0?"iframe":c.iframeFix).each(function(){a('<div class="ui-draggable-iframeFix" style="background: #fff;"></div>').css({width:this.offsetWidth+"px",height:this.offsetHeight+"px",position:"absolute",opacity:"0.001",zIndex:1e3}).css(a(this).offset()).appendTo("body")}),!0))},_mouseStart:function(b){var c=this.options;return this.helper=this._createHelper(b),this.helper.addClass("ui-draggable-dragging"),this._cacheHelperProportions(),a.ui.ddmanager&&(a.ui.ddmanager.current=this),this._cacheMargins(),this.cssPosition=this.helper.css("position"),this.scrollParent=this.helper.scrollParent(),this.offset=this.positionAbs=this.element.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},a.extend(this.offset,{click:{left:b.pageX-this.offset.left,top:b.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.originalPosition=this.position=this._generatePosition(b),this.originalPageX=b.pageX,this.originalPageY=b.pageY,c.cursorAt&&this._adjustOffsetFromHelper(c.cursorAt),c.containment&&this._setContainment(),this._trigger("start",b)===!1?(this._clear(),!1):(this._cacheHelperProportions(),a.ui.ddmanager&&!c.dropBehaviour&&a.ui.ddmanager.prepareOffsets(this,b),this._mouseDrag(b,!0),a.ui.ddmanager&&a.ui.ddmanager.dragStart(this,b),!0)},_mouseDrag:function(b,c){if(this.position=this._generatePosition(b),this.positionAbs=this._convertPositionTo("absolute"),!c){var d=this._uiHash();if(this._trigger("drag",b,d)===!1)return this._mouseUp({}),!1;this.position=d.position}return this.options.axis&&"y"==this.options.axis||(this.helper[0].style.left=this.position.left+"px"),this.options.axis&&"x"==this.options.axis||(this.helper[0].style.top=this.position.top+"px"),a.ui.ddmanager&&a.ui.ddmanager.drag(this,b),!1},_mouseStop:function(b){var c=!1;a.ui.ddmanager&&!this.options.dropBehaviour&&(c=a.ui.ddmanager.drop(this,b)),this.dropped&&(c=this.dropped,this.dropped=!1);for(var d=this.element[0],e=!1;d&&(d=d.parentNode);)d==document&&(e=!0);if(!e&&"original"===this.options.helper)return!1;if("invalid"==this.options.revert&&!c||"valid"==this.options.revert&&c||this.options.revert===!0||a.isFunction(this.options.revert)&&this.options.revert.call(this.element,c)){var f=this;a(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){f._trigger("stop",b)!==!1&&f._clear()})}else this._trigger("stop",b)!==!1&&this._clear();return!1},_mouseUp:function(b){return a("div.ui-draggable-iframeFix").each(function(){this.parentNode.removeChild(this)}),a.ui.ddmanager&&a.ui.ddmanager.dragStop(this,b),a.ui.mouse.prototype._mouseUp.call(this,b)},cancel:function(){return this.helper.is(".ui-draggable-dragging")?this._mouseUp({}):this._clear(),this},_getHandle:function(b){var c=!this.options.handle||!a(this.options.handle,this.element).length;return a(this.options.handle,this.element).find("*").andSelf().each(function(){this==b.target&&(c=!0)}),c},_createHelper:function(b){var c=this.options,d=a.isFunction(c.helper)?a(c.helper.apply(this.element[0],[b])):"clone"==c.helper?this.element.clone().removeAttr("id"):this.element;return d.parents("body").length||d.appendTo("parent"==c.appendTo?this.element[0].parentNode:c.appendTo),d[0]!=this.element[0]&&!/(fixed|absolute)/.test(d.css("position"))&&d.css("position","absolute"),d},_adjustOffsetFromHelper:function(b){"string"==typeof b&&(b=b.split(" ")),a.isArray(b)&&(b={left:+b[0],top:+b[1]||0}),"left"in b&&(this.offset.click.left=b.left+this.margins.left),"right"in b&&(this.offset.click.left=this.helperProportions.width-b.right+this.margins.left),"top"in b&&(this.offset.click.top=b.top+this.margins.top),"bottom"in b&&(this.offset.click.top=this.helperProportions.height-b.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var b=this.offsetParent.offset();return"absolute"==this.cssPosition&&this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])&&(b.left+=this.scrollParent.scrollLeft(),b.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]==document.body||this.offsetParent[0].tagName&&"html"==this.offsetParent[0].tagName.toLowerCase()&&a.browser.msie)&&(b={top:0,left:0}),{top:b.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:b.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"==this.cssPosition){var a=this.element.position();return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:a.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var b=this.options;if("parent"==b.containment&&(b.containment=this.helper[0].parentNode),"document"!=b.containment&&"window"!=b.containment||(this.containment=["document"==b.containment?0:a(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,"document"==b.containment?0:a(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,("document"==b.containment?0:a(window).scrollLeft())+a("document"==b.containment?document:window).width()-this.helperProportions.width-this.margins.left,("document"==b.containment?0:a(window).scrollTop())+(a("document"==b.containment?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),/^(document|window|parent)$/.test(b.containment)||b.containment.constructor==Array)b.containment.constructor==Array&&(this.containment=b.containment);else{var c=a(b.containment),d=c[0];if(!d)return;var f=(c.offset(),"hidden"!=a(d).css("overflow"));this.containment=[(parseInt(a(d).css("borderLeftWidth"),10)||0)+(parseInt(a(d).css("paddingLeft"),10)||0),(parseInt(a(d).css("borderTopWidth"),10)||0)+(parseInt(a(d).css("paddingTop"),10)||0),(f?Math.max(d.scrollWidth,d.offsetWidth):d.offsetWidth)-(parseInt(a(d).css("borderLeftWidth"),10)||0)-(parseInt(a(d).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(f?Math.max(d.scrollHeight,d.offsetHeight):d.offsetHeight)-(parseInt(a(d).css("borderTopWidth"),10)||0)-(parseInt(a(d).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relative_container=c}},_convertPositionTo:function(b,c){c||(c=this.position);var d="absolute"==b?1:-1,f=(this.options,"absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent),g=/(html|body)/i.test(f[0].tagName);return{top:c.top+this.offset.relative.top*d+this.offset.parent.top*d-(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollTop():g?0:f.scrollTop())*d),left:c.left+this.offset.relative.left*d+this.offset.parent.left*d-(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollLeft():g?0:f.scrollLeft())*d)}},_generatePosition:function(b){var c=this.options,d="absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,e=/(html|body)/i.test(d[0].tagName),f=b.pageX,g=b.pageY;if(this.originalPosition){var h;if(this.containment){if(this.relative_container){var i=this.relative_container.offset();h=[this.containment[0]+i.left,this.containment[1]+i.top,this.containment[2]+i.left,this.containment[3]+i.top]}else h=this.containment;b.pageX-this.offset.click.left<h[0]&&(f=h[0]+this.offset.click.left),b.pageY-this.offset.click.top<h[1]&&(g=h[1]+this.offset.click.top),b.pageX-this.offset.click.left>h[2]&&(f=h[2]+this.offset.click.left),b.pageY-this.offset.click.top>h[3]&&(g=h[3]+this.offset.click.top)}if(c.grid){var j=c.grid[1]?this.originalPageY+Math.round((g-this.originalPageY)/c.grid[1])*c.grid[1]:this.originalPageY;g=h&&(j-this.offset.click.top<h[1]||j-this.offset.click.top>h[3])?j-this.offset.click.top<h[1]?j+c.grid[1]:j-c.grid[1]:j;var k=c.grid[0]?this.originalPageX+Math.round((f-this.originalPageX)/c.grid[0])*c.grid[0]:this.originalPageX;f=h&&(k-this.offset.click.left<h[0]||k-this.offset.click.left>h[2])?k-this.offset.click.left<h[0]?k+c.grid[0]:k-c.grid[0]:k}}return{top:g-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollTop():e?0:d.scrollTop()),left:f-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollLeft():e?0:d.scrollLeft())}},_clear:function(){this.helper.removeClass("ui-draggable-dragging"),this.helper[0]!=this.element[0]&&!this.cancelHelperRemoval&&this.helper.remove(),this.helper=null,this.cancelHelperRemoval=!1},_trigger:function(b,c,d){return d=d||this._uiHash(),a.ui.plugin.call(this,b,[c,d]),"drag"==b&&(this.positionAbs=this._convertPositionTo("absolute")),a.Widget.prototype._trigger.call(this,b,c,d)},plugins:{},_uiHash:function(a){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),a.extend(a.ui.draggable,{version:"1.8.24"}),a.ui.plugin.add("draggable","connectToSortable",{start:function(b,c){var d=a(this).data("draggable"),e=d.options,f=a.extend({},c,{item:d.element});d.sortables=[],a(e.connectToSortable).each(function(){var c=a.data(this,"sortable");c&&!c.options.disabled&&(d.sortables.push({instance:c,shouldRevert:c.options.revert}),c.refreshPositions(),c._trigger("activate",b,f))})},stop:function(b,c){var d=a(this).data("draggable"),e=a.extend({},c,{item:d.element});a.each(d.sortables,function(){this.instance.isOver?(this.instance.isOver=0,d.cancelHelperRemoval=!0,this.instance.cancelHelperRemoval=!1,this.shouldRevert&&(this.instance.options.revert=!0),this.instance._mouseStop(b),this.instance.options.helper=this.instance.options._helper,"original"==d.options.helper&&this.instance.currentItem.css({top:"auto",left:"auto"})):(this.instance.cancelHelperRemoval=!1,this.instance._trigger("deactivate",b,e))})},drag:function(b,c){var d=a(this).data("draggable"),e=this;a.each(d.sortables,function(f){this.instance.positionAbs=d.positionAbs,this.instance.helperProportions=d.helperProportions,this.instance.offset.click=d.offset.click,this.instance._intersectsWith(this.instance.containerCache)?(this.instance.isOver||(this.instance.isOver=1,this.instance.currentItem=a(e).clone().removeAttr("id").appendTo(this.instance.element).data("sortable-item",!0),this.instance.options._helper=this.instance.options.helper,this.instance.options.helper=function(){return c.helper[0]},b.target=this.instance.currentItem[0],this.instance._mouseCapture(b,!0),this.instance._mouseStart(b,!0,!0),this.instance.offset.click.top=d.offset.click.top,this.instance.offset.click.left=d.offset.click.left,this.instance.offset.parent.left-=d.offset.parent.left-this.instance.offset.parent.left,this.instance.offset.parent.top-=d.offset.parent.top-this.instance.offset.parent.top,d._trigger("toSortable",b),d.dropped=this.instance.element,d.currentItem=d.element,this.instance.fromOutside=d),this.instance.currentItem&&this.instance._mouseDrag(b)):this.instance.isOver&&(this.instance.isOver=0,this.instance.cancelHelperRemoval=!0,this.instance.options.revert=!1,this.instance._trigger("out",b,this.instance._uiHash(this.instance)),this.instance._mouseStop(b,!0),this.instance.options.helper=this.instance.options._helper,this.instance.currentItem.remove(),this.instance.placeholder&&this.instance.placeholder.remove(),d._trigger("fromSortable",b),d.dropped=!1)})}}),a.ui.plugin.add("draggable","cursor",{start:function(b,c){var d=a("body"),e=a(this).data("draggable").options;d.css("cursor")&&(e._cursor=d.css("cursor")),d.css("cursor",e.cursor)},stop:function(b,c){var d=a(this).data("draggable").options;d._cursor&&a("body").css("cursor",d._cursor)}}),a.ui.plugin.add("draggable","opacity",{start:function(b,c){var d=a(c.helper),e=a(this).data("draggable").options;d.css("opacity")&&(e._opacity=d.css("opacity")),d.css("opacity",e.opacity)},stop:function(b,c){var d=a(this).data("draggable").options;d._opacity&&a(c.helper).css("opacity",d._opacity)}}),a.ui.plugin.add("draggable","scroll",{start:function(b,c){var d=a(this).data("draggable");d.scrollParent[0]!=document&&"HTML"!=d.scrollParent[0].tagName&&(d.overflowOffset=d.scrollParent.offset())},drag:function(b,c){var d=a(this).data("draggable"),e=d.options,f=!1;d.scrollParent[0]!=document&&"HTML"!=d.scrollParent[0].tagName?(e.axis&&"x"==e.axis||(d.overflowOffset.top+d.scrollParent[0].offsetHeight-b.pageY<e.scrollSensitivity?d.scrollParent[0].scrollTop=f=d.scrollParent[0].scrollTop+e.scrollSpeed:b.pageY-d.overflowOffset.top<e.scrollSensitivity&&(d.scrollParent[0].scrollTop=f=d.scrollParent[0].scrollTop-e.scrollSpeed)),e.axis&&"y"==e.axis||(d.overflowOffset.left+d.scrollParent[0].offsetWidth-b.pageX<e.scrollSensitivity?d.scrollParent[0].scrollLeft=f=d.scrollParent[0].scrollLeft+e.scrollSpeed:b.pageX-d.overflowOffset.left<e.scrollSensitivity&&(d.scrollParent[0].scrollLeft=f=d.scrollParent[0].scrollLeft-e.scrollSpeed))):(e.axis&&"x"==e.axis||(b.pageY-a(document).scrollTop()<e.scrollSensitivity?f=a(document).scrollTop(a(document).scrollTop()-e.scrollSpeed):a(window).height()-(b.pageY-a(document).scrollTop())<e.scrollSensitivity&&(f=a(document).scrollTop(a(document).scrollTop()+e.scrollSpeed))),e.axis&&"y"==e.axis||(b.pageX-a(document).scrollLeft()<e.scrollSensitivity?f=a(document).scrollLeft(a(document).scrollLeft()-e.scrollSpeed):a(window).width()-(b.pageX-a(document).scrollLeft())<e.scrollSensitivity&&(f=a(document).scrollLeft(a(document).scrollLeft()+e.scrollSpeed)))),f!==!1&&a.ui.ddmanager&&!e.dropBehaviour&&a.ui.ddmanager.prepareOffsets(d,b)}}),a.ui.plugin.add("draggable","snap",{start:function(b,c){var d=a(this).data("draggable"),e=d.options;d.snapElements=[],a(e.snap.constructor!=String?e.snap.items||":data(draggable)":e.snap).each(function(){var b=a(this),c=b.offset();this!=d.element[0]&&d.snapElements.push({item:this,width:b.outerWidth(),height:b.outerHeight(),top:c.top,left:c.left})})},drag:function(b,c){for(var d=a(this).data("draggable"),e=d.options,f=e.snapTolerance,g=c.offset.left,h=g+d.helperProportions.width,i=c.offset.top,j=i+d.helperProportions.height,k=d.snapElements.length-1;k>=0;k--){
var l=d.snapElements[k].left,m=l+d.snapElements[k].width,n=d.snapElements[k].top,o=n+d.snapElements[k].height;if(l-f<g&&g<m+f&&n-f<i&&i<o+f||l-f<g&&g<m+f&&n-f<j&&j<o+f||l-f<h&&h<m+f&&n-f<i&&i<o+f||l-f<h&&h<m+f&&n-f<j&&j<o+f){if("inner"!=e.snapMode){var p=Math.abs(n-j)<=f,q=Math.abs(o-i)<=f,r=Math.abs(l-h)<=f,s=Math.abs(m-g)<=f;p&&(c.position.top=d._convertPositionTo("relative",{top:n-d.helperProportions.height,left:0}).top-d.margins.top),q&&(c.position.top=d._convertPositionTo("relative",{top:o,left:0}).top-d.margins.top),r&&(c.position.left=d._convertPositionTo("relative",{top:0,left:l-d.helperProportions.width}).left-d.margins.left),s&&(c.position.left=d._convertPositionTo("relative",{top:0,left:m}).left-d.margins.left)}var t=p||q||r||s;if("outer"!=e.snapMode){var p=Math.abs(n-i)<=f,q=Math.abs(o-j)<=f,r=Math.abs(l-g)<=f,s=Math.abs(m-h)<=f;p&&(c.position.top=d._convertPositionTo("relative",{top:n,left:0}).top-d.margins.top),q&&(c.position.top=d._convertPositionTo("relative",{top:o-d.helperProportions.height,left:0}).top-d.margins.top),r&&(c.position.left=d._convertPositionTo("relative",{top:0,left:l}).left-d.margins.left),s&&(c.position.left=d._convertPositionTo("relative",{top:0,left:m-d.helperProportions.width}).left-d.margins.left)}!d.snapElements[k].snapping&&(p||q||r||s||t)&&d.options.snap.snap&&d.options.snap.snap.call(d.element,b,a.extend(d._uiHash(),{snapItem:d.snapElements[k].item})),d.snapElements[k].snapping=p||q||r||s||t}else d.snapElements[k].snapping&&d.options.snap.release&&d.options.snap.release.call(d.element,b,a.extend(d._uiHash(),{snapItem:d.snapElements[k].item})),d.snapElements[k].snapping=!1}}}),a.ui.plugin.add("draggable","stack",{start:function(b,c){var d=a(this).data("draggable").options,e=a.makeArray(a(d.stack)).sort(function(b,c){return(parseInt(a(b).css("zIndex"),10)||0)-(parseInt(a(c).css("zIndex"),10)||0)});if(e.length){var f=parseInt(e[0].style.zIndex)||0;a(e).each(function(a){this.style.zIndex=f+a}),this[0].style.zIndex=f+e.length}}}),a.ui.plugin.add("draggable","zIndex",{start:function(b,c){var d=a(c.helper),e=a(this).data("draggable").options;d.css("zIndex")&&(e._zIndex=d.css("zIndex")),d.css("zIndex",e.zIndex)},stop:function(b,c){var d=a(this).data("draggable").options;d._zIndex&&a(c.helper).css("zIndex",d._zIndex)}})}(jQuery),function(a,b){a.widget("ui.droppable",{widgetEventPrefix:"drop",options:{accept:"*",activeClass:!1,addClasses:!0,greedy:!1,hoverClass:!1,scope:"default",tolerance:"intersect"},_create:function(){var b=this.options,c=b.accept;this.isover=0,this.isout=1,this.accept=a.isFunction(c)?c:function(a){return a.is(c)},this.proportions={width:this.element[0].offsetWidth,height:this.element[0].offsetHeight},a.ui.ddmanager.droppables[b.scope]=a.ui.ddmanager.droppables[b.scope]||[],a.ui.ddmanager.droppables[b.scope].push(this),b.addClasses&&this.element.addClass("ui-droppable")},destroy:function(){for(var b=a.ui.ddmanager.droppables[this.options.scope],c=0;c<b.length;c++)b[c]==this&&b.splice(c,1);return this.element.removeClass("ui-droppable ui-droppable-disabled").removeData("droppable").unbind(".droppable"),this},_setOption:function(b,c){"accept"==b&&(this.accept=a.isFunction(c)?c:function(a){return a.is(c)}),a.Widget.prototype._setOption.apply(this,arguments)},_activate:function(b){var c=a.ui.ddmanager.current;this.options.activeClass&&this.element.addClass(this.options.activeClass),c&&this._trigger("activate",b,this.ui(c))},_deactivate:function(b){var c=a.ui.ddmanager.current;this.options.activeClass&&this.element.removeClass(this.options.activeClass),c&&this._trigger("deactivate",b,this.ui(c))},_over:function(b){var c=a.ui.ddmanager.current;c&&(c.currentItem||c.element)[0]!=this.element[0]&&this.accept.call(this.element[0],c.currentItem||c.element)&&(this.options.hoverClass&&this.element.addClass(this.options.hoverClass),this._trigger("over",b,this.ui(c)))},_out:function(b){var c=a.ui.ddmanager.current;c&&(c.currentItem||c.element)[0]!=this.element[0]&&this.accept.call(this.element[0],c.currentItem||c.element)&&(this.options.hoverClass&&this.element.removeClass(this.options.hoverClass),this._trigger("out",b,this.ui(c)))},_drop:function(b,c){var d=c||a.ui.ddmanager.current;if(!d||(d.currentItem||d.element)[0]==this.element[0])return!1;var e=!1;return this.element.find(":data(droppable)").not(".ui-draggable-dragging").each(function(){var b=a.data(this,"droppable");if(b.options.greedy&&!b.options.disabled&&b.options.scope==d.options.scope&&b.accept.call(b.element[0],d.currentItem||d.element)&&a.ui.intersect(d,a.extend(b,{offset:b.element.offset()}),b.options.tolerance))return e=!0,!1}),!e&&(!!this.accept.call(this.element[0],d.currentItem||d.element)&&(this.options.activeClass&&this.element.removeClass(this.options.activeClass),this.options.hoverClass&&this.element.removeClass(this.options.hoverClass),this._trigger("drop",b,this.ui(d)),this.element))},ui:function(a){return{draggable:a.currentItem||a.element,helper:a.helper,position:a.position,offset:a.positionAbs}}}),a.extend(a.ui.droppable,{version:"1.8.24"}),a.ui.intersect=function(b,c,d){if(!c.offset)return!1;var e=(b.positionAbs||b.position.absolute).left,f=e+b.helperProportions.width,g=(b.positionAbs||b.position.absolute).top,h=g+b.helperProportions.height,i=c.offset.left,j=i+c.proportions.width,k=c.offset.top,l=k+c.proportions.height;switch(d){case"fit":return i<=e&&f<=j&&k<=g&&h<=l;case"intersect":return i<e+b.helperProportions.width/2&&f-b.helperProportions.width/2<j&&k<g+b.helperProportions.height/2&&h-b.helperProportions.height/2<l;case"pointer":var m=(b.positionAbs||b.position.absolute).left+(b.clickOffset||b.offset.click).left,n=(b.positionAbs||b.position.absolute).top+(b.clickOffset||b.offset.click).top,o=a.ui.isOver(n,m,k,i,c.proportions.height,c.proportions.width);return o;case"touch":return(g>=k&&g<=l||h>=k&&h<=l||g<k&&h>l)&&(e>=i&&e<=j||f>=i&&f<=j||e<i&&f>j);default:return!1}},a.ui.ddmanager={current:null,droppables:{default:[]},prepareOffsets:function(b,c){var d=a.ui.ddmanager.droppables[b.options.scope]||[],e=c?c.type:null,f=(b.currentItem||b.element).find(":data(droppable)").andSelf();a:for(var g=0;g<d.length;g++)if(!(d[g].options.disabled||b&&!d[g].accept.call(d[g].element[0],b.currentItem||b.element))){for(var h=0;h<f.length;h++)if(f[h]==d[g].element[0]){d[g].proportions.height=0;continue a}d[g].visible="none"!=d[g].element.css("display"),d[g].visible&&("mousedown"==e&&d[g]._activate.call(d[g],c),d[g].offset=d[g].element.offset(),d[g].proportions={width:d[g].element[0].offsetWidth,height:d[g].element[0].offsetHeight})}},drop:function(b,c){var d=!1;return a.each(a.ui.ddmanager.droppables[b.options.scope]||[],function(){this.options&&(!this.options.disabled&&this.visible&&a.ui.intersect(b,this,this.options.tolerance)&&(d=this._drop.call(this,c)||d),!this.options.disabled&&this.visible&&this.accept.call(this.element[0],b.currentItem||b.element)&&(this.isout=1,this.isover=0,this._deactivate.call(this,c)))}),d},dragStart:function(b,c){b.element.parents(":not(body,html)").bind("scroll.droppable",function(){b.options.refreshPositions||a.ui.ddmanager.prepareOffsets(b,c)})},drag:function(b,c){b.options.refreshPositions&&a.ui.ddmanager.prepareOffsets(b,c),a.each(a.ui.ddmanager.droppables[b.options.scope]||[],function(){if(!this.options.disabled&&!this.greedyChild&&this.visible){var d=a.ui.intersect(b,this,this.options.tolerance),e=d||1!=this.isover?d&&0==this.isover?"isover":null:"isout";if(e){var f;if(this.options.greedy){var g=this.options.scope,h=this.element.parents(":data(droppable)").filter(function(){return a.data(this,"droppable").options.scope===g});h.length&&(f=a.data(h[0],"droppable"),f.greedyChild="isover"==e?1:0)}f&&"isover"==e&&(f.isover=0,f.isout=1,f._out.call(f,c)),this[e]=1,this["isout"==e?"isover":"isout"]=0,this["isover"==e?"_over":"_out"].call(this,c),f&&"isout"==e&&(f.isout=0,f.isover=1,f._over.call(f,c))}}})},dragStop:function(b,c){b.element.parents(":not(body,html)").unbind("scroll.droppable"),b.options.refreshPositions||a.ui.ddmanager.prepareOffsets(b,c)}}}(jQuery),function(a,b){a.widget("ui.resizable",a.ui.mouse,{widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:1e3},_create:function(){var b=this,c=this.options;if(this.element.addClass("ui-resizable"),a.extend(this,{_aspectRatio:!!c.aspectRatio,aspectRatio:c.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:c.helper||c.ghost||c.animate?c.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/canvas|textarea|input|select|button|img/i)&&(this.element.wrap(a('<div class="ui-wrapper" style="overflow: hidden;"></div>').css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("resizable",this.element.data("resizable")),this.elementIsWrapper=!0,this.element.css({marginLeft:this.originalElement.css("marginLeft"),marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom")}),this.originalElement.css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0}),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css({margin:this.originalElement.css("margin")}),this._proportionallyResize()),this.handles=c.handles||(a(".ui-resizable-handle",this.element).length?{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"}:"e,s,se"),this.handles.constructor==String){"all"==this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw");var d=this.handles.split(",");this.handles={};for(var e=0;e<d.length;e++){var f=a.trim(d[e]),g="ui-resizable-"+f,h=a('<div class="ui-resizable-handle '+g+'"></div>');h.css({zIndex:c.zIndex}),"se"==f&&h.addClass("ui-icon ui-icon-gripsmall-diagonal-se"),this.handles[f]=".ui-resizable-"+f,this.element.append(h)}}this._renderAxis=function(b){b=b||this.element;for(var c in this.handles){if(this.handles[c].constructor==String&&(this.handles[c]=a(this.handles[c],this.element).show()),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/textarea|input|select|button/i)){var d=a(this.handles[c],this.element),e=0;e=/sw|ne|nw|se|n|s/.test(c)?d.outerHeight():d.outerWidth();var f=["padding",/ne|nw|n/.test(c)?"Top":/se|sw|s/.test(c)?"Bottom":/^e$/.test(c)?"Right":"Left"].join("");b.css(f,e),this._proportionallyResize()}a(this.handles[c]).length}},this._renderAxis(this.element),this._handles=a(".ui-resizable-handle",this.element).disableSelection(),this._handles.mouseover(function(){if(!b.resizing){if(this.className)var a=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i);b.axis=a&&a[1]?a[1]:"se"}}),c.autoHide&&(this._handles.hide(),a(this.element).addClass("ui-resizable-autohide").hover(function(){c.disabled||(a(this).removeClass("ui-resizable-autohide"),b._handles.show())},function(){c.disabled||b.resizing||(a(this).addClass("ui-resizable-autohide"),b._handles.hide())})),this._mouseInit()},destroy:function(){this._mouseDestroy();var b=function(b){a(b).removeClass("ui-resizable ui-resizable-disabled ui-resizable-resizing").removeData("resizable").unbind(".resizable").find(".ui-resizable-handle").remove()};if(this.elementIsWrapper){b(this.element);var c=this.element;c.after(this.originalElement.css({position:c.css("position"),width:c.outerWidth(),height:c.outerHeight(),top:c.css("top"),left:c.css("left")})).remove()}return this.originalElement.css("resize",this.originalResizeStyle),b(this.originalElement),this},_mouseCapture:function(b){var c=!1;for(var d in this.handles)a(this.handles[d])[0]==b.target&&(c=!0);return!this.options.disabled&&c},_mouseStart:function(b){var d=this.options,e=this.element.position(),f=this.element;this.resizing=!0,this.documentScroll={top:a(document).scrollTop(),left:a(document).scrollLeft()},(f.is(".ui-draggable")||/absolute/.test(f.css("position")))&&f.css({position:"absolute",top:e.top,left:e.left}),this._renderProxy();var g=c(this.helper.css("left")),h=c(this.helper.css("top"));d.containment&&(g+=a(d.containment).scrollLeft()||0,h+=a(d.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:g,top:h},this.size=this._helper?{width:f.outerWidth(),height:f.outerHeight()}:{width:f.width(),height:f.height()},this.originalSize=this._helper?{width:f.outerWidth(),height:f.outerHeight()}:{width:f.width(),height:f.height()},this.originalPosition={left:g,top:h},this.sizeDiff={width:f.outerWidth()-f.width(),height:f.outerHeight()-f.height()},this.originalMousePosition={left:b.pageX,top:b.pageY},this.aspectRatio="number"==typeof d.aspectRatio?d.aspectRatio:this.originalSize.width/this.originalSize.height||1;var i=a(".ui-resizable-"+this.axis).css("cursor");return a("body").css("cursor","auto"==i?this.axis+"-resize":i),f.addClass("ui-resizable-resizing"),this._propagate("start",b),!0},_mouseDrag:function(b){var c=this.helper,g=(this.options,this.originalMousePosition),h=this.axis,i=b.pageX-g.left||0,j=b.pageY-g.top||0,k=this._change[h];if(!k)return!1;var l=k.apply(this,[b,i,j]);a.browser.msie&&a.browser.version<7,this.sizeDiff;return this._updateVirtualBoundaries(b.shiftKey),(this._aspectRatio||b.shiftKey)&&(l=this._updateRatio(l,b)),l=this._respectSize(l,b),this._propagate("resize",b),c.css({top:this.position.top+"px",left:this.position.left+"px",width:this.size.width+"px",height:this.size.height+"px"}),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),this._updateCache(l),this._trigger("resize",b,this.ui()),!1},_mouseStop:function(b){this.resizing=!1;var c=this.options,d=this;if(this._helper){var e=this._proportionallyResizeElements,f=e.length&&/textarea/i.test(e[0].nodeName),g=f&&a.ui.hasScroll(e[0],"left")?0:d.sizeDiff.height,h=f?0:d.sizeDiff.width,i={width:d.helper.width()-h,height:d.helper.height()-g},j=parseInt(d.element.css("left"),10)+(d.position.left-d.originalPosition.left)||null,k=parseInt(d.element.css("top"),10)+(d.position.top-d.originalPosition.top)||null;c.animate||this.element.css(a.extend(i,{top:k,left:j})),d.helper.height(d.size.height),d.helper.width(d.size.width),this._helper&&!c.animate&&this._proportionallyResize()}return a("body").css("cursor","auto"),this.element.removeClass("ui-resizable-resizing"),this._propagate("stop",b),this._helper&&this.helper.remove(),!1},_updateVirtualBoundaries:function(a){var c,e,f,g,h,b=this.options;h={minWidth:d(b.minWidth)?b.minWidth:0,maxWidth:d(b.maxWidth)?b.maxWidth:1/0,minHeight:d(b.minHeight)?b.minHeight:0,maxHeight:d(b.maxHeight)?b.maxHeight:1/0},(this._aspectRatio||a)&&(c=h.minHeight*this.aspectRatio,f=h.minWidth/this.aspectRatio,e=h.maxHeight*this.aspectRatio,g=h.maxWidth/this.aspectRatio,c>h.minWidth&&(h.minWidth=c),f>h.minHeight&&(h.minHeight=f),e<h.maxWidth&&(h.maxWidth=e),g<h.maxHeight&&(h.maxHeight=g)),this._vBoundaries=h},_updateCache:function(a){this.options;this.offset=this.helper.offset(),d(a.left)&&(this.position.left=a.left),d(a.top)&&(this.position.top=a.top),d(a.height)&&(this.size.height=a.height),d(a.width)&&(this.size.width=a.width)},_updateRatio:function(a,b){var e=(this.options,this.position),f=this.size,g=this.axis;return d(a.height)?a.width=a.height*this.aspectRatio:d(a.width)&&(a.height=a.width/this.aspectRatio),"sw"==g&&(a.left=e.left+(f.width-a.width),a.top=null),"nw"==g&&(a.top=e.top+(f.height-a.height),a.left=e.left+(f.width-a.width)),a},_respectSize:function(a,b){var e=(this.helper,this._vBoundaries),g=(this._aspectRatio||b.shiftKey,this.axis),h=d(a.width)&&e.maxWidth&&e.maxWidth<a.width,i=d(a.height)&&e.maxHeight&&e.maxHeight<a.height,j=d(a.width)&&e.minWidth&&e.minWidth>a.width,k=d(a.height)&&e.minHeight&&e.minHeight>a.height;j&&(a.width=e.minWidth),k&&(a.height=e.minHeight),h&&(a.width=e.maxWidth),i&&(a.height=e.maxHeight);var l=this.originalPosition.left+this.originalSize.width,m=this.position.top+this.size.height,n=/sw|nw|w/.test(g),o=/nw|ne|n/.test(g);j&&n&&(a.left=l-e.minWidth),h&&n&&(a.left=l-e.maxWidth),k&&o&&(a.top=m-e.minHeight),i&&o&&(a.top=m-e.maxHeight);var p=!a.width&&!a.height;return p&&!a.left&&a.top?a.top=null:p&&!a.top&&a.left&&(a.left=null),a},_proportionallyResize:function(){this.options;if(this._proportionallyResizeElements.length)for(var c=this.helper||this.element,d=0;d<this._proportionallyResizeElements.length;d++){var e=this._proportionallyResizeElements[d];if(!this.borderDif){var f=[e.css("borderTopWidth"),e.css("borderRightWidth"),e.css("borderBottomWidth"),e.css("borderLeftWidth")],g=[e.css("paddingTop"),e.css("paddingRight"),e.css("paddingBottom"),e.css("paddingLeft")];this.borderDif=a.map(f,function(a,b){var c=parseInt(a,10)||0,d=parseInt(g[b],10)||0;return c+d})}a.browser.msie&&(a(c).is(":hidden")||a(c).parents(":hidden").length)||e.css({height:c.height()-this.borderDif[0]-this.borderDif[2]||0,width:c.width()-this.borderDif[1]-this.borderDif[3]||0})}},_renderProxy:function(){var b=this.element,c=this.options;if(this.elementOffset=b.offset(),this._helper){this.helper=this.helper||a('<div style="overflow:hidden;"></div>');var d=a.browser.msie&&a.browser.version<7,e=d?1:0,f=d?2:-1;this.helper.addClass(this._helper).css({width:this.element.outerWidth()+f,height:this.element.outerHeight()+f,position:"absolute",left:this.elementOffset.left-e+"px",top:this.elementOffset.top-e+"px",zIndex:++c.zIndex}),this.helper.appendTo("body").disableSelection()}else this.helper=this.element},_change:{e:function(a,b,c){return{width:this.originalSize.width+b}},w:function(a,b,c){var e=(this.options,this.originalSize),f=this.originalPosition;return{left:f.left+b,width:e.width-b}},n:function(a,b,c){var e=(this.options,this.originalSize),f=this.originalPosition;return{top:f.top+c,height:e.height-c}},s:function(a,b,c){return{height:this.originalSize.height+c}},se:function(b,c,d){return a.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[b,c,d]))},sw:function(b,c,d){return a.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[b,c,d]))},ne:function(b,c,d){return a.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[b,c,d]))},nw:function(b,c,d){return a.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[b,c,d]))}},_propagate:function(b,c){a.ui.plugin.call(this,b,[c,this.ui()]),"resize"!=b&&this._trigger(b,c,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),a.extend(a.ui.resizable,{version:"1.8.24"}),a.ui.plugin.add("resizable","alsoResize",{start:function(b,c){var d=a(this).data("resizable"),e=d.options,f=function(b){a(b).each(function(){var b=a(this);b.data("resizable-alsoresize",{width:parseInt(b.width(),10),height:parseInt(b.height(),10),left:parseInt(b.css("left"),10),top:parseInt(b.css("top"),10)})})};"object"!=typeof e.alsoResize||e.alsoResize.parentNode?f(e.alsoResize):e.alsoResize.length?(e.alsoResize=e.alsoResize[0],f(e.alsoResize)):a.each(e.alsoResize,function(a){f(a)})},resize:function(b,c){var d=a(this).data("resizable"),e=d.options,f=d.originalSize,g=d.originalPosition,h={height:d.size.height-f.height||0,width:d.size.width-f.width||0,top:d.position.top-g.top||0,left:d.position.left-g.left||0},i=function(b,d){a(b).each(function(){var b=a(this),e=a(this).data("resizable-alsoresize"),f={},g=d&&d.length?d:b.parents(c.originalElement[0]).length?["width","height"]:["width","height","top","left"];a.each(g,function(a,b){var c=(e[b]||0)+(h[b]||0);c&&c>=0&&(f[b]=c||null)}),b.css(f)})};"object"!=typeof e.alsoResize||e.alsoResize.nodeType?i(e.alsoResize):a.each(e.alsoResize,function(a,b){i(a,b)})},stop:function(b,c){a(this).removeData("resizable-alsoresize")}}),a.ui.plugin.add("resizable","animate",{stop:function(b,c){var d=a(this).data("resizable"),e=d.options,f=d._proportionallyResizeElements,g=f.length&&/textarea/i.test(f[0].nodeName),h=g&&a.ui.hasScroll(f[0],"left")?0:d.sizeDiff.height,i=g?0:d.sizeDiff.width,j={width:d.size.width-i,height:d.size.height-h},k=parseInt(d.element.css("left"),10)+(d.position.left-d.originalPosition.left)||null,l=parseInt(d.element.css("top"),10)+(d.position.top-d.originalPosition.top)||null;d.element.animate(a.extend(j,l&&k?{top:l,left:k}:{}),{duration:e.animateDuration,easing:e.animateEasing,step:function(){var c={width:parseInt(d.element.css("width"),10),height:parseInt(d.element.css("height"),10),top:parseInt(d.element.css("top"),10),left:parseInt(d.element.css("left"),10)};f&&f.length&&a(f[0]).css({width:c.width,height:c.height}),d._updateCache(c),d._propagate("resize",b)}})}}),a.ui.plugin.add("resizable","containment",{start:function(b,d){var e=a(this).data("resizable"),f=e.options,g=e.element,h=f.containment,i=h instanceof a?h.get(0):/parent/.test(h)?g.parent().get(0):h;if(i)if(e.containerElement=a(i),/document/.test(h)||h==document)e.containerOffset={left:0,top:0},e.containerPosition={left:0,top:0},e.parentData={element:a(document),left:0,top:0,width:a(document).width(),height:a(document).height()||document.body.parentNode.scrollHeight};else{var j=a(i),k=[];a(["Top","Right","Left","Bottom"]).each(function(a,b){k[a]=c(j.css("padding"+b))}),e.containerOffset=j.offset(),e.containerPosition=j.position(),e.containerSize={height:j.innerHeight()-k[3],width:j.innerWidth()-k[1]};var l=e.containerOffset,m=e.containerSize.height,n=e.containerSize.width,o=a.ui.hasScroll(i,"left")?i.scrollWidth:n,p=a.ui.hasScroll(i)?i.scrollHeight:m;e.parentData={element:i,left:l.left,top:l.top,width:o,height:p}}},resize:function(b,c){var d=a(this).data("resizable"),e=d.options,g=(d.containerSize,d.containerOffset),i=(d.size,d.position),j=d._aspectRatio||b.shiftKey,k={top:0,left:0},l=d.containerElement;l[0]!=document&&/static/.test(l.css("position"))&&(k=g),i.left<(d._helper?g.left:0)&&(d.size.width=d.size.width+(d._helper?d.position.left-g.left:d.position.left-k.left),j&&(d.size.height=d.size.width/d.aspectRatio),d.position.left=e.helper?g.left:0),i.top<(d._helper?g.top:0)&&(d.size.height=d.size.height+(d._helper?d.position.top-g.top:d.position.top),j&&(d.size.width=d.size.height*d.aspectRatio),d.position.top=d._helper?g.top:0),d.offset.left=d.parentData.left+d.position.left,d.offset.top=d.parentData.top+d.position.top;var m=Math.abs((d._helper?d.offset.left-k.left:d.offset.left-k.left)+d.sizeDiff.width),n=Math.abs((d._helper?d.offset.top-k.top:d.offset.top-g.top)+d.sizeDiff.height),o=d.containerElement.get(0)==d.element.parent().get(0),p=/relative|absolute/.test(d.containerElement.css("position"));o&&p&&(m-=d.parentData.left),m+d.size.width>=d.parentData.width&&(d.size.width=d.parentData.width-m,j&&(d.size.height=d.size.width/d.aspectRatio)),n+d.size.height>=d.parentData.height&&(d.size.height=d.parentData.height-n,j&&(d.size.width=d.size.height*d.aspectRatio))},stop:function(b,c){var d=a(this).data("resizable"),e=d.options,g=(d.position,d.containerOffset),h=d.containerPosition,i=d.containerElement,j=a(d.helper),k=j.offset(),l=j.outerWidth()-d.sizeDiff.width,m=j.outerHeight()-d.sizeDiff.height;d._helper&&!e.animate&&/relative/.test(i.css("position"))&&a(this).css({left:k.left-h.left-g.left,width:l,height:m}),d._helper&&!e.animate&&/static/.test(i.css("position"))&&a(this).css({left:k.left-h.left-g.left,width:l,height:m})}}),a.ui.plugin.add("resizable","ghost",{start:function(b,c){var d=a(this).data("resizable"),e=d.options,f=d.size;d.ghost=d.originalElement.clone(),d.ghost.css({opacity:.25,display:"block",position:"relative",height:f.height,width:f.width,margin:0,left:0,top:0}).addClass("ui-resizable-ghost").addClass("string"==typeof e.ghost?e.ghost:""),d.ghost.appendTo(d.helper)},resize:function(b,c){var d=a(this).data("resizable");d.options;d.ghost&&d.ghost.css({position:"relative",height:d.size.height,width:d.size.width})},stop:function(b,c){var d=a(this).data("resizable");d.options;d.ghost&&d.helper&&d.helper.get(0).removeChild(d.ghost.get(0))}}),a.ui.plugin.add("resizable","grid",{resize:function(b,c){var d=a(this).data("resizable"),e=d.options,f=d.size,g=d.originalSize,h=d.originalPosition,i=d.axis;e._aspectRatio||b.shiftKey;e.grid="number"==typeof e.grid?[e.grid,e.grid]:e.grid;var k=Math.round((f.width-g.width)/(e.grid[0]||1))*(e.grid[0]||1),l=Math.round((f.height-g.height)/(e.grid[1]||1))*(e.grid[1]||1);/^(se|s|e)$/.test(i)?(d.size.width=g.width+k,d.size.height=g.height+l):/^(ne)$/.test(i)?(d.size.width=g.width+k,d.size.height=g.height+l,d.position.top=h.top-l):/^(sw)$/.test(i)?(d.size.width=g.width+k,d.size.height=g.height+l,d.position.left=h.left-k):(d.size.width=g.width+k,d.size.height=g.height+l,d.position.top=h.top-l,d.position.left=h.left-k)}});var c=function(a){return parseInt(a,10)||0},d=function(a){return!isNaN(parseInt(a,10))}}(jQuery),function(a,b){a.widget("ui.selectable",a.ui.mouse,{options:{appendTo:"body",autoRefresh:!0,distance:0,filter:"*",tolerance:"touch"},_create:function(){var b=this;this.element.addClass("ui-selectable"),this.dragged=!1;var c;this.refresh=function(){c=a(b.options.filter,b.element[0]),c.addClass("ui-selectee"),c.each(function(){var b=a(this),c=b.offset();a.data(this,"selectable-item",{element:this,$element:b,left:c.left,top:c.top,right:c.left+b.outerWidth(),bottom:c.top+b.outerHeight(),startselected:!1,selected:b.hasClass("ui-selected"),selecting:b.hasClass("ui-selecting"),unselecting:b.hasClass("ui-unselecting")})})},this.refresh(),this.selectees=c.addClass("ui-selectee"),this._mouseInit(),this.helper=a("<div class='ui-selectable-helper'></div>")},destroy:function(){return this.selectees.removeClass("ui-selectee").removeData("selectable-item"),this.element.removeClass("ui-selectable ui-selectable-disabled").removeData("selectable").unbind(".selectable"),this._mouseDestroy(),this},_mouseStart:function(b){var c=this;if(this.opos=[b.pageX,b.pageY],!this.options.disabled){var d=this.options;this.selectees=a(d.filter,this.element[0]),this._trigger("start",b),a(d.appendTo).append(this.helper),this.helper.css({left:b.clientX,top:b.clientY,width:0,height:0}),d.autoRefresh&&this.refresh(),this.selectees.filter(".ui-selected").each(function(){var d=a.data(this,"selectable-item");d.startselected=!0,!b.metaKey&&!b.ctrlKey&&(d.$element.removeClass("ui-selected"),d.selected=!1,d.$element.addClass("ui-unselecting"),d.unselecting=!0,c._trigger("unselecting",b,{unselecting:d.element}))}),a(b.target).parents().andSelf().each(function(){var d=a.data(this,"selectable-item");if(d){var e=!b.metaKey&&!b.ctrlKey||!d.$element.hasClass("ui-selected");return d.$element.removeClass(e?"ui-unselecting":"ui-selected").addClass(e?"ui-selecting":"ui-unselecting"),d.unselecting=!e,d.selecting=e,d.selected=e,e?c._trigger("selecting",b,{selecting:d.element}):c._trigger("unselecting",b,{unselecting:d.element}),!1}})}},_mouseDrag:function(b){var c=this;if(this.dragged=!0,!this.options.disabled){var d=this.options,e=this.opos[0],f=this.opos[1],g=b.pageX,h=b.pageY;if(e>g){var i=g;g=e,e=i}if(f>h){var i=h;h=f,f=i}return this.helper.css({left:e,top:f,width:g-e,height:h-f}),this.selectees.each(function(){var i=a.data(this,"selectable-item");if(i&&i.element!=c.element[0]){var j=!1;"touch"==d.tolerance?j=!(i.left>g||i.right<e||i.top>h||i.bottom<f):"fit"==d.tolerance&&(j=i.left>e&&i.right<g&&i.top>f&&i.bottom<h),j?(i.selected&&(i.$element.removeClass("ui-selected"),i.selected=!1),i.unselecting&&(i.$element.removeClass("ui-unselecting"),i.unselecting=!1),i.selecting||(i.$element.addClass("ui-selecting"),i.selecting=!0,c._trigger("selecting",b,{selecting:i.element}))):(i.selecting&&((b.metaKey||b.ctrlKey)&&i.startselected?(i.$element.removeClass("ui-selecting"),i.selecting=!1,i.$element.addClass("ui-selected"),i.selected=!0):(i.$element.removeClass("ui-selecting"),i.selecting=!1,i.startselected&&(i.$element.addClass("ui-unselecting"),i.unselecting=!0),c._trigger("unselecting",b,{unselecting:i.element}))),i.selected&&!b.metaKey&&!b.ctrlKey&&!i.startselected&&(i.$element.removeClass("ui-selected"),i.selected=!1,i.$element.addClass("ui-unselecting"),i.unselecting=!0,c._trigger("unselecting",b,{unselecting:i.element})))}}),!1}},_mouseStop:function(b){var c=this;this.dragged=!1;this.options;return a(".ui-unselecting",this.element[0]).each(function(){var d=a.data(this,"selectable-item");d.$element.removeClass("ui-unselecting"),d.unselecting=!1,d.startselected=!1,c._trigger("unselected",b,{unselected:d.element})}),a(".ui-selecting",this.element[0]).each(function(){var d=a.data(this,"selectable-item");d.$element.removeClass("ui-selecting").addClass("ui-selected"),d.selecting=!1,d.selected=!0,d.startselected=!0,c._trigger("selected",b,{selected:d.element})}),this._trigger("stop",b),this.helper.remove(),!1}}),a.extend(a.ui.selectable,{version:"1.8.24"})}(jQuery),function(a,b){a.widget("ui.sortable",a.ui.mouse,{widgetEventPrefix:"sort",ready:!1,options:{appendTo:"parent",axis:!1,connectWith:!1,containment:!1,cursor:"auto",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:"original",items:"> *",opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1e3},_create:function(){var a=this.options;this.containerCache={},this.element.addClass("ui-sortable"),this.refresh(),this.floating=!!this.items.length&&("x"===a.axis||/left|right/.test(this.items[0].item.css("float"))||/inline|table-cell/.test(this.items[0].item.css("display"))),this.offset=this.element.offset(),this._mouseInit(),this.ready=!0},destroy:function(){a.Widget.prototype.destroy.call(this),this.element.removeClass("ui-sortable ui-sortable-disabled"),this._mouseDestroy();for(var b=this.items.length-1;b>=0;b--)this.items[b].item.removeData(this.widgetName+"-item");return this},_setOption:function(b,c){"disabled"===b?(this.options[b]=c,this.widget()[c?"addClass":"removeClass"]("ui-sortable-disabled")):a.Widget.prototype._setOption.apply(this,arguments)},_mouseCapture:function(b,c){var d=this;if(this.reverting)return!1;if(this.options.disabled||"static"==this.options.type)return!1;this._refreshItems(b);var e=null,f=this;a(b.target).parents().each(function(){if(a.data(this,d.widgetName+"-item")==f)return e=a(this),!1});if(a.data(b.target,d.widgetName+"-item")==f&&(e=a(b.target)),!e)return!1;if(this.options.handle&&!c){var h=!1;if(a(this.options.handle,e).find("*").andSelf().each(function(){this==b.target&&(h=!0)}),!h)return!1}return this.currentItem=e,this._removeCurrentsFromItems(),!0},_mouseStart:function(b,c,d){var e=this.options,f=this;if(this.currentContainer=this,this.refreshPositions(),this.helper=this._createHelper(b),this._cacheHelperProportions(),this._cacheMargins(),this.scrollParent=this.helper.scrollParent(),this.offset=this.currentItem.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},a.extend(this.offset,{click:{left:b.pageX-this.offset.left,top:b.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.helper.css("position","absolute"),this.cssPosition=this.helper.css("position"),this.originalPosition=this._generatePosition(b),this.originalPageX=b.pageX,this.originalPageY=b.pageY,e.cursorAt&&this._adjustOffsetFromHelper(e.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!=this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),e.containment&&this._setContainment(),e.cursor&&(a("body").css("cursor")&&(this._storedCursor=a("body").css("cursor")),a("body").css("cursor",e.cursor)),
e.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",e.opacity)),e.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",e.zIndex)),this.scrollParent[0]!=document&&"HTML"!=this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this._trigger("start",b,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!d)for(var g=this.containers.length-1;g>=0;g--)this.containers[g]._trigger("activate",b,f._uiHash(this));return a.ui.ddmanager&&(a.ui.ddmanager.current=this),a.ui.ddmanager&&!e.dropBehaviour&&a.ui.ddmanager.prepareOffsets(this,b),this.dragging=!0,this.helper.addClass("ui-sortable-helper"),this._mouseDrag(b),!0},_mouseDrag:function(b){if(this.position=this._generatePosition(b),this.positionAbs=this._convertPositionTo("absolute"),this.lastPositionAbs||(this.lastPositionAbs=this.positionAbs),this.options.scroll){var c=this.options,d=!1;this.scrollParent[0]!=document&&"HTML"!=this.scrollParent[0].tagName?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-b.pageY<c.scrollSensitivity?this.scrollParent[0].scrollTop=d=this.scrollParent[0].scrollTop+c.scrollSpeed:b.pageY-this.overflowOffset.top<c.scrollSensitivity&&(this.scrollParent[0].scrollTop=d=this.scrollParent[0].scrollTop-c.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-b.pageX<c.scrollSensitivity?this.scrollParent[0].scrollLeft=d=this.scrollParent[0].scrollLeft+c.scrollSpeed:b.pageX-this.overflowOffset.left<c.scrollSensitivity&&(this.scrollParent[0].scrollLeft=d=this.scrollParent[0].scrollLeft-c.scrollSpeed)):(b.pageY-a(document).scrollTop()<c.scrollSensitivity?d=a(document).scrollTop(a(document).scrollTop()-c.scrollSpeed):a(window).height()-(b.pageY-a(document).scrollTop())<c.scrollSensitivity&&(d=a(document).scrollTop(a(document).scrollTop()+c.scrollSpeed)),b.pageX-a(document).scrollLeft()<c.scrollSensitivity?d=a(document).scrollLeft(a(document).scrollLeft()-c.scrollSpeed):a(window).width()-(b.pageX-a(document).scrollLeft())<c.scrollSensitivity&&(d=a(document).scrollLeft(a(document).scrollLeft()+c.scrollSpeed))),d!==!1&&a.ui.ddmanager&&!c.dropBehaviour&&a.ui.ddmanager.prepareOffsets(this,b)}this.positionAbs=this._convertPositionTo("absolute"),this.options.axis&&"y"==this.options.axis||(this.helper[0].style.left=this.position.left+"px"),this.options.axis&&"x"==this.options.axis||(this.helper[0].style.top=this.position.top+"px");for(var e=this.items.length-1;e>=0;e--){var f=this.items[e],g=f.item[0],h=this._intersectsWithPointer(f);if(h&&f.instance===this.currentContainer&&!(g==this.currentItem[0]||this.placeholder[1==h?"next":"prev"]()[0]==g||a.ui.contains(this.placeholder[0],g)||"semi-dynamic"==this.options.type&&a.ui.contains(this.element[0],g))){if(this.direction=1==h?"down":"up","pointer"!=this.options.tolerance&&!this._intersectsWithSides(f))break;this._rearrange(b,f),this._trigger("change",b,this._uiHash());break}}return this._contactContainers(b),a.ui.ddmanager&&a.ui.ddmanager.drag(this,b),this._trigger("sort",b,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(b,c){if(b){if(a.ui.ddmanager&&!this.options.dropBehaviour&&a.ui.ddmanager.drop(this,b),this.options.revert){var d=this,e=d.placeholder.offset();d.reverting=!0,a(this.helper).animate({left:e.left-this.offset.parent.left-d.margins.left+(this.offsetParent[0]==document.body?0:this.offsetParent[0].scrollLeft),top:e.top-this.offset.parent.top-d.margins.top+(this.offsetParent[0]==document.body?0:this.offsetParent[0].scrollTop)},parseInt(this.options.revert,10)||500,function(){d._clear(b)})}else this._clear(b,c);return!1}},cancel:function(){var b=this;if(this.dragging){this._mouseUp({target:null}),"original"==this.options.helper?this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper"):this.currentItem.show();for(var c=this.containers.length-1;c>=0;c--)this.containers[c]._trigger("deactivate",null,b._uiHash(this)),this.containers[c].containerCache.over&&(this.containers[c]._trigger("out",null,b._uiHash(this)),this.containers[c].containerCache.over=0)}return this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),"original"!=this.options.helper&&this.helper&&this.helper[0].parentNode&&this.helper.remove(),a.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?a(this.domPosition.prev).after(this.currentItem):a(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(b){var c=this._getItemsAsjQuery(b&&b.connected),d=[];return b=b||{},a(c).each(function(){var c=(a(b.item||this).attr(b.attribute||"id")||"").match(b.expression||/(.+)[-=_](.+)/);c&&d.push((b.key||c[1]+"[]")+"="+(b.key&&b.expression?c[1]:c[2]))}),!d.length&&b.key&&d.push(b.key+"="),d.join("&")},toArray:function(b){var c=this._getItemsAsjQuery(b&&b.connected),d=[];return b=b||{},c.each(function(){d.push(a(b.item||this).attr(b.attribute||"id")||"")}),d},_intersectsWith:function(a){var b=this.positionAbs.left,c=b+this.helperProportions.width,d=this.positionAbs.top,e=d+this.helperProportions.height,f=a.left,g=f+a.width,h=a.top,i=h+a.height,j=this.offset.click.top,k=this.offset.click.left,l=d+j>h&&d+j<i&&b+k>f&&b+k<g;return"pointer"==this.options.tolerance||this.options.forcePointerForContainers||"pointer"!=this.options.tolerance&&this.helperProportions[this.floating?"width":"height"]>a[this.floating?"width":"height"]?l:f<b+this.helperProportions.width/2&&c-this.helperProportions.width/2<g&&h<d+this.helperProportions.height/2&&e-this.helperProportions.height/2<i},_intersectsWithPointer:function(b){var c="x"===this.options.axis||a.ui.isOverAxis(this.positionAbs.top+this.offset.click.top,b.top,b.height),d="y"===this.options.axis||a.ui.isOverAxis(this.positionAbs.left+this.offset.click.left,b.left,b.width),e=c&&d,f=this._getDragVerticalDirection(),g=this._getDragHorizontalDirection();return!!e&&(this.floating?g&&"right"==g||"down"==f?2:1:f&&("down"==f?2:1))},_intersectsWithSides:function(b){var c=a.ui.isOverAxis(this.positionAbs.top+this.offset.click.top,b.top+b.height/2,b.height),d=a.ui.isOverAxis(this.positionAbs.left+this.offset.click.left,b.left+b.width/2,b.width),e=this._getDragVerticalDirection(),f=this._getDragHorizontalDirection();return this.floating&&f?"right"==f&&d||"left"==f&&!d:e&&("down"==e&&c||"up"==e&&!c)},_getDragVerticalDirection:function(){var a=this.positionAbs.top-this.lastPositionAbs.top;return 0!=a&&(a>0?"down":"up")},_getDragHorizontalDirection:function(){var a=this.positionAbs.left-this.lastPositionAbs.left;return 0!=a&&(a>0?"right":"left")},refresh:function(a){return this._refreshItems(a),this.refreshPositions(),this},_connectWith:function(){var a=this.options;return a.connectWith.constructor==String?[a.connectWith]:a.connectWith},_getItemsAsjQuery:function(b){var d=[],e=[],f=this._connectWith();if(f&&b)for(var g=f.length-1;g>=0;g--)for(var h=a(f[g]),i=h.length-1;i>=0;i--){var j=a.data(h[i],this.widgetName);j&&j!=this&&!j.options.disabled&&e.push([a.isFunction(j.options.items)?j.options.items.call(j.element):a(j.options.items,j.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),j])}e.push([a.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):a(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]);for(var g=e.length-1;g>=0;g--)e[g][0].each(function(){d.push(this)});return a(d)},_removeCurrentsFromItems:function(){for(var a=this.currentItem.find(":data("+this.widgetName+"-item)"),b=0;b<this.items.length;b++)for(var c=0;c<a.length;c++)a[c]==this.items[b].item[0]&&this.items.splice(b,1)},_refreshItems:function(b){this.items=[],this.containers=[this];var c=this.items,e=[[a.isFunction(this.options.items)?this.options.items.call(this.element[0],b,{item:this.currentItem}):a(this.options.items,this.element),this]],f=this._connectWith();if(f&&this.ready)for(var g=f.length-1;g>=0;g--)for(var h=a(f[g]),i=h.length-1;i>=0;i--){var j=a.data(h[i],this.widgetName);j&&j!=this&&!j.options.disabled&&(e.push([a.isFunction(j.options.items)?j.options.items.call(j.element[0],b,{item:this.currentItem}):a(j.options.items,j.element),j]),this.containers.push(j))}for(var g=e.length-1;g>=0;g--)for(var k=e[g][1],l=e[g][0],i=0,m=l.length;i<m;i++){var n=a(l[i]);n.data(this.widgetName+"-item",k),c.push({item:n,instance:k,width:0,height:0,left:0,top:0})}},refreshPositions:function(b){this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset());for(var c=this.items.length-1;c>=0;c--){var d=this.items[c];if(d.instance==this.currentContainer||!this.currentContainer||d.item[0]==this.currentItem[0]){var e=this.options.toleranceElement?a(this.options.toleranceElement,d.item):d.item;b||(d.width=e.outerWidth(),d.height=e.outerHeight());var f=e.offset();d.left=f.left,d.top=f.top}}if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(var c=this.containers.length-1;c>=0;c--){var f=this.containers[c].element.offset();this.containers[c].containerCache.left=f.left,this.containers[c].containerCache.top=f.top,this.containers[c].containerCache.width=this.containers[c].element.outerWidth(),this.containers[c].containerCache.height=this.containers[c].element.outerHeight()}return this},_createPlaceholder:function(b){var c=b||this,d=c.options;if(!d.placeholder||d.placeholder.constructor==String){var e=d.placeholder;d.placeholder={element:function(){var b=a(document.createElement(c.currentItem[0].nodeName)).addClass(e||c.currentItem[0].className+" ui-sortable-placeholder").removeClass("ui-sortable-helper")[0];return e||(b.style.visibility="hidden"),b},update:function(a,b){e&&!d.forcePlaceholderSize||(b.height()||b.height(c.currentItem.innerHeight()-parseInt(c.currentItem.css("paddingTop")||0,10)-parseInt(c.currentItem.css("paddingBottom")||0,10)),b.width()||b.width(c.currentItem.innerWidth()-parseInt(c.currentItem.css("paddingLeft")||0,10)-parseInt(c.currentItem.css("paddingRight")||0,10)))}}}c.placeholder=a(d.placeholder.element.call(c.element,c.currentItem)),c.currentItem.after(c.placeholder),d.placeholder.update(c,c.placeholder)},_contactContainers:function(b){for(var c=null,d=null,e=this.containers.length-1;e>=0;e--)if(!a.ui.contains(this.currentItem[0],this.containers[e].element[0]))if(this._intersectsWith(this.containers[e].containerCache)){if(c&&a.ui.contains(this.containers[e].element[0],c.element[0]))continue;c=this.containers[e],d=e}else this.containers[e].containerCache.over&&(this.containers[e]._trigger("out",b,this._uiHash(this)),this.containers[e].containerCache.over=0);if(c)if(1===this.containers.length)this.containers[d]._trigger("over",b,this._uiHash(this)),this.containers[d].containerCache.over=1;else if(this.currentContainer!=this.containers[d]){for(var f=1e4,g=null,h=this.positionAbs[this.containers[d].floating?"left":"top"],i=this.items.length-1;i>=0;i--)if(a.ui.contains(this.containers[d].element[0],this.items[i].item[0])){var j=this.containers[d].floating?this.items[i].item.offset().left:this.items[i].item.offset().top;Math.abs(j-h)<f&&(f=Math.abs(j-h),g=this.items[i],this.direction=j-h>0?"down":"up")}if(!g&&!this.options.dropOnEmpty)return;this.currentContainer=this.containers[d],g?this._rearrange(b,g,null,!0):this._rearrange(b,null,this.containers[d].element,!0),this._trigger("change",b,this._uiHash()),this.containers[d]._trigger("change",b,this._uiHash(this)),this.options.placeholder.update(this.currentContainer,this.placeholder),this.containers[d]._trigger("over",b,this._uiHash(this)),this.containers[d].containerCache.over=1}},_createHelper:function(b){var c=this.options,d=a.isFunction(c.helper)?a(c.helper.apply(this.element[0],[b,this.currentItem])):"clone"==c.helper?this.currentItem.clone():this.currentItem;return d.parents("body").length||a("parent"!=c.appendTo?c.appendTo:this.currentItem[0].parentNode)[0].appendChild(d[0]),d[0]==this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css("position"),top:this.currentItem.css("top"),left:this.currentItem.css("left")}),(""==d[0].style.width||c.forceHelperSize)&&d.width(this.currentItem.width()),(""==d[0].style.height||c.forceHelperSize)&&d.height(this.currentItem.height()),d},_adjustOffsetFromHelper:function(b){"string"==typeof b&&(b=b.split(" ")),a.isArray(b)&&(b={left:+b[0],top:+b[1]||0}),"left"in b&&(this.offset.click.left=b.left+this.margins.left),"right"in b&&(this.offset.click.left=this.helperProportions.width-b.right+this.margins.left),"top"in b&&(this.offset.click.top=b.top+this.margins.top),"bottom"in b&&(this.offset.click.top=this.helperProportions.height-b.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var b=this.offsetParent.offset();return"absolute"==this.cssPosition&&this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])&&(b.left+=this.scrollParent.scrollLeft(),b.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]==document.body||this.offsetParent[0].tagName&&"html"==this.offsetParent[0].tagName.toLowerCase()&&a.browser.msie)&&(b={top:0,left:0}),{top:b.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:b.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"==this.cssPosition){var a=this.currentItem.position();return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:a.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css("marginLeft"),10)||0,top:parseInt(this.currentItem.css("marginTop"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var b=this.options;if("parent"==b.containment&&(b.containment=this.helper[0].parentNode),"document"!=b.containment&&"window"!=b.containment||(this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,a("document"==b.containment?document:window).width()-this.helperProportions.width-this.margins.left,(a("document"==b.containment?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),!/^(document|window|parent)$/.test(b.containment)){var c=a(b.containment)[0],d=a(b.containment).offset(),e="hidden"!=a(c).css("overflow");this.containment=[d.left+(parseInt(a(c).css("borderLeftWidth"),10)||0)+(parseInt(a(c).css("paddingLeft"),10)||0)-this.margins.left,d.top+(parseInt(a(c).css("borderTopWidth"),10)||0)+(parseInt(a(c).css("paddingTop"),10)||0)-this.margins.top,d.left+(e?Math.max(c.scrollWidth,c.offsetWidth):c.offsetWidth)-(parseInt(a(c).css("borderLeftWidth"),10)||0)-(parseInt(a(c).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,d.top+(e?Math.max(c.scrollHeight,c.offsetHeight):c.offsetHeight)-(parseInt(a(c).css("borderTopWidth"),10)||0)-(parseInt(a(c).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top]}},_convertPositionTo:function(b,c){c||(c=this.position);var d="absolute"==b?1:-1,f=(this.options,"absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent),g=/(html|body)/i.test(f[0].tagName);return{top:c.top+this.offset.relative.top*d+this.offset.parent.top*d-(a.browser.safari&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollTop():g?0:f.scrollTop())*d),left:c.left+this.offset.relative.left*d+this.offset.parent.left*d-(a.browser.safari&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollLeft():g?0:f.scrollLeft())*d)}},_generatePosition:function(b){var c=this.options,d="absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,e=/(html|body)/i.test(d[0].tagName);"relative"==this.cssPosition&&(this.scrollParent[0]==document||this.scrollParent[0]==this.offsetParent[0])&&(this.offset.relative=this._getRelativeOffset());var f=b.pageX,g=b.pageY;if(this.originalPosition&&(this.containment&&(b.pageX-this.offset.click.left<this.containment[0]&&(f=this.containment[0]+this.offset.click.left),b.pageY-this.offset.click.top<this.containment[1]&&(g=this.containment[1]+this.offset.click.top),b.pageX-this.offset.click.left>this.containment[2]&&(f=this.containment[2]+this.offset.click.left),b.pageY-this.offset.click.top>this.containment[3]&&(g=this.containment[3]+this.offset.click.top)),c.grid)){var h=this.originalPageY+Math.round((g-this.originalPageY)/c.grid[1])*c.grid[1];g=this.containment&&(h-this.offset.click.top<this.containment[1]||h-this.offset.click.top>this.containment[3])?h-this.offset.click.top<this.containment[1]?h+c.grid[1]:h-c.grid[1]:h;var i=this.originalPageX+Math.round((f-this.originalPageX)/c.grid[0])*c.grid[0];f=this.containment&&(i-this.offset.click.left<this.containment[0]||i-this.offset.click.left>this.containment[2])?i-this.offset.click.left<this.containment[0]?i+c.grid[0]:i-c.grid[0]:i}return{top:g-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(a.browser.safari&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollTop():e?0:d.scrollTop()),left:f-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(a.browser.safari&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollLeft():e?0:d.scrollLeft())}},_rearrange:function(a,b,c,d){c?c[0].appendChild(this.placeholder[0]):b.item[0].parentNode.insertBefore(this.placeholder[0],"down"==this.direction?b.item[0]:b.item[0].nextSibling),this.counter=this.counter?++this.counter:1;var e=this,f=this.counter;window.setTimeout(function(){f==e.counter&&e.refreshPositions(!d)},0)},_clear:function(b,c){this.reverting=!1;var d=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]==this.currentItem[0]){for(var f in this._storedCSS)"auto"!=this._storedCSS[f]&&"static"!=this._storedCSS[f]||(this._storedCSS[f]="");this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper")}else this.currentItem.show();this.fromOutside&&!c&&d.push(function(a){this._trigger("receive",a,this._uiHash(this.fromOutside))}),(this.fromOutside||this.domPosition.prev!=this.currentItem.prev().not(".ui-sortable-helper")[0]||this.domPosition.parent!=this.currentItem.parent()[0])&&!c&&d.push(function(a){this._trigger("update",a,this._uiHash())}),this!==this.currentContainer&&(c||(d.push(function(a){this._trigger("remove",a,this._uiHash())}),d.push(function(a){return function(b){a._trigger("receive",b,this._uiHash(this))}}.call(this,this.currentContainer)),d.push(function(a){return function(b){a._trigger("update",b,this._uiHash(this))}}.call(this,this.currentContainer))));for(var f=this.containers.length-1;f>=0;f--)c||d.push(function(a){return function(b){a._trigger("deactivate",b,this._uiHash(this))}}.call(this,this.containers[f])),this.containers[f].containerCache.over&&(d.push(function(a){return function(b){a._trigger("out",b,this._uiHash(this))}}.call(this,this.containers[f])),this.containers[f].containerCache.over=0);if(this._storedCursor&&a("body").css("cursor",this._storedCursor),this._storedOpacity&&this.helper.css("opacity",this._storedOpacity),this._storedZIndex&&this.helper.css("zIndex","auto"==this._storedZIndex?"":this._storedZIndex),this.dragging=!1,this.cancelHelperRemoval){if(!c){this._trigger("beforeStop",b,this._uiHash());for(var f=0;f<d.length;f++)d[f].call(this,b);this._trigger("stop",b,this._uiHash())}return this.fromOutside=!1,!1}if(c||this._trigger("beforeStop",b,this._uiHash()),this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.helper[0]!=this.currentItem[0]&&this.helper.remove(),this.helper=null,!c){for(var f=0;f<d.length;f++)d[f].call(this,b);this._trigger("stop",b,this._uiHash())}return this.fromOutside=!1,!0},_trigger:function(){a.Widget.prototype._trigger.apply(this,arguments)===!1&&this.cancel()},_uiHash:function(b){var c=b||this;return{helper:c.helper,placeholder:c.placeholder||a([]),position:c.position,originalPosition:c.originalPosition,offset:c.positionAbs,item:c.currentItem,sender:b?b.element:null}}}),a.extend(a.ui.sortable,{version:"1.8.24"})}(jQuery);var JSON;JSON||(JSON={}),function(){function f(a){return a<10?"0"+a:a}function quote(a){return escapable.lastIndex=0,escapable.test(a)?'"'+a.replace(escapable,function(a){var b=meta[a];return"string"==typeof b?b:"\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function str(a,b){var c,d,e,f,h,g=gap,i=b[a];switch(i&&"object"==typeof i&&"function"==typeof i.toJSON&&(i=i.toJSON(a)),"function"==typeof rep&&(i=rep.call(b,a,i)),typeof i){case"string":return quote(i);case"number":return isFinite(i)?String(i):"null";case"boolean":case"null":return String(i);case"object":if(!i)return"null";if(gap+=indent,h=[],"[object Array]"===Object.prototype.toString.apply(i)){for(f=i.length,c=0;c<f;c+=1)h[c]=str(c,i)||"null";return e=0===h.length?"[]":gap?"[n"+gap+h.join(",n"+gap)+"n"+g+"]":"["+h.join(",")+"]",gap=g,e}if(rep&&"object"==typeof rep)for(f=rep.length,c=0;c<f;c+=1)"string"==typeof rep[c]&&(d=rep[c],e=str(d,i),e&&h.push(quote(d)+(gap?": ":":")+e));else for(d in i)Object.prototype.hasOwnProperty.call(i,d)&&(e=str(d,i),e&&h.push(quote(d)+(gap?": ":":")+e));return e=0===h.length?"{}":gap?"{n"+gap+h.join(",n"+gap)+"n"+g+"}":"{"+h.join(",")+"}",gap=g,e}}"function"!=typeof Date.prototype.toJSON&&(Date.prototype.toJSON=function(a){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(a){return this.valueOf()});var cx=/[u0000u00adu0600-u0604u070fu17b4u17b5u200c-u200fu2028-u202fu2060-u206fufeffufff0-uffff]/g,escapable=/[\"x00-x1fx7f-x9fu00adu0600-u0604u070fu17b4u17b5u200c-u200fu2028-u202fu2060-u206fufeffufff0-uffff]/g,gap,indent,meta={"b":"\b","t":"\t","n":"\n","f":"\f","r":"\r",'"':'\"',"\":"\\"},rep;"function"!=typeof JSON.stringify&&(JSON.stringify=function(a,b,c){var d;if(gap="",indent="","number"==typeof c)for(d=0;d<c;d+=1)indent+=" ";else"string"==typeof c&&(indent=c);if(rep=b,b&&"function"!=typeof b&&("object"!=typeof b||"number"!=typeof b.length))throw new Error("JSON.stringify");return str("",{"":a})}),"function"!=typeof JSON.parse&&(JSON.parse=function(text,reviver){function walk(a,b){var c,d,e=a[b];if(e&&"object"==typeof e)for(c in e)Object.prototype.hasOwnProperty.call(e,c)&&(d=walk(e,c),void 0!==d?e[c]=d:delete e[c]);return reviver.call(a,b,e)}var j;if(text=String(text),cx.lastIndex=0,cx.test(text)&&(text=text.replace(cx,function(a){return"\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})),/^[],:{}s]*$/.test(text.replace(/\(?:["\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\nr]*"|true|false|null|-?d+(?:.d*)?(?:[eE][+-]?d+)?/g,"]").replace(/(?:^|:|,)(?:s*[)+/g,"")))return j=eval("("+text+")"),"function"==typeof reviver?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}(),function(a){function b(b){var c=b||window.event,d=[].slice.call(arguments,1),e=0,g=0,h=0;return b=a.event.fix(c),b.type="mousewheel",c.wheelDelta&&(e=c.wheelDelta/120),c.detail&&(e=-c.detail/3),h=e,void 0!==c.axis&&c.axis===c.HORIZONTAL_AXIS&&(h=0,g=-1*e),void 0!==c.wheelDeltaY&&(h=c.wheelDeltaY/120),void 0!==c.wheelDeltaX&&(g=-1*c.wheelDeltaX/120),d.unshift(b,e,g,h),(a.event.dispatch||a.event.handle).apply(this,d)}var c=["DOMMouseScroll","mousewheel"];if(a.event.fixHooks)for(var d=c.length;d;)a.event.fixHooks[c[--d]]=a.event.mouseHooks;a.event.special.mousewheel={setup:function(){if(this.addEventListener)for(var a=c.length;a;)this.addEventListener(c[--a],b,!1);else this.onmousewheel=b},teardown:function(){if(this.removeEventListener)for(var a=c.length;a;)this.removeEventListener(c[--a],b,!1);else this.onmousewheel=null}},a.fn.extend({mousewheel:function(a){return a?this.bind("mousewheel",a):this.trigger("mousewheel")},unmousewheel:function(a){return this.unbind("mousewheel",a)}})}(jQuery),function(a){function c(a){return"object"==typeof a?a:{top:a,left:a}}var b=a.scrollTo=function(b,c,d){a(window).scrollTo(b,c,d)};b.defaults={axis:"xy",duration:parseFloat(a.fn.jquery)>=1.3?0:1},b.window=function(b){return a(window)._scrollable()},a.fn._scrollable=function(){return this.map(function(){var b=this,c=!b.nodeName||a.inArray(b.nodeName.toLowerCase(),["iframe","#document","html","body"])!=-1;if(!c)return b;var d=(b.contentWindow||b).document||b.ownerDocument||b;return a.browser.safari||"BackCompat"==d.compatMode?d.body:d.documentElement})},a.fn.scrollTo=function(d,e,f){return"object"==typeof e&&(f=e,e=0),"function"==typeof f&&(f={onAfter:f}),"max"==d&&(d=9e9),f=a.extend({},b.defaults,f),e=e||f.speed||f.duration,f.queue=f.queue&&f.axis.length>1,f.queue&&(e/=2),f.offset=c(f.offset),f.over=c(f.over),this._scrollable().each(function(){function m(a){h.animate(k,e,f.easing,a&&function(){a.call(this,d,f)})}var j,g=this,h=a(g),i=d,k={},l=h.is("html,body");switch(typeof i){case"number":case"string":if(/^([+-]=)?d+(.d+)?(px|%)?$/.test(i)){i=c(i);break}i=a(i,this);case"object":(i.is||i.style)&&(j=(i=a(i)).offset())}a.each(f.axis.split(""),function(a,c){var d="x"==c?"Left":"Top",e=d.toLowerCase(),n="scroll"+d,o=g[n],p=b.max(g,c);if(j)k[n]=j[e]+(l?0:o-h.offset()[e]),f.margin&&(k[n]-=parseInt(i.css("margin"+d))||0,k[n]-=parseInt(i.css("border"+d+"Width"))||0),k[n]+=f.offset[e]||0,f.over[e]&&(k[n]+=i["x"==c?"width":"height"]()*f.over[e]);else{var q=i[e];k[n]=q.slice&&"%"==q.slice(-1)?parseFloat(q)/100*p:q}/^d+$/.test(k[n])&&(k[n]=k[n]<=0?0:Math.min(k[n],p)),!a&&f.queue&&(o!=k[n]&&m(f.onAfterFirst),delete k[n])}),m(f.onAfter)}).end()},b.max=function(b,c){var d="x"==c?"Width":"Height",e="scroll"+d;if(!a(b).is("html,body"))return b[e]-a(b)[d.toLowerCase()]();var f="client"+d,g=b.ownerDocument.documentElement,h=b.ownerDocument.body;return Math.max(g[e],h[e])-Math.min(g[f],h[f])}}(jQuery),function(){function a(){var a=!1;if("localStorage"in window)try{window.localStorage.setItem("_tmptest","tmpval"),a=!0,window.localStorage.removeItem("_tmptest")}catch(a){}if(a)try{window.localStorage&&(v=window.localStorage,y="localStorage",B=v.jStorage_update)}catch(a){}else if("globalStorage"in window)try{window.globalStorage&&(v=window.globalStorage[window.location.hostname],y="globalStorage",B=v.jStorage_update)}catch(a){}else{if(w=document.createElement("link"),!w.addBehavior)return void(w=null);w.style.behavior="url(#default#userData)",document.getElementsByTagName("head")[0].appendChild(w);try{w.load("jStorage")}catch(a){w.setAttribute("jStorage","{}"),w.save("jStorage"),w.load("jStorage")}var c="{}";try{c=w.getAttribute("jStorage")}catch(a){}try{B=w.getAttribute("jStorage_update")}catch(a){}v.jStorage=c,y="userDataBehavior"}i(),l(),b("local"),b("session"),d(),m(),"addEventListener"in window&&window.addEventListener("pageshow",function(a){a.persisted&&e()},!1)}function b(a,c){function d(){if("session"==a)try{j=t.parse(window.name||"{}")}catch(a){j={}}}function e(){"session"==a&&(window.name=t.stringify(j))}var h,i,f=!1,g=0,j={};Math.random();if(c||"undefined"==typeof window[a+"Storage"]){if("local"==a&&window.globalStorage)return void(localStorage=window.globalStorage[window.location.hostname]);if("userDataBehavior"==y){c&&window[a+"Storage"]&&window[a+"Storage"].parentNode&&window[a+"Storage"].parentNode.removeChild(window[a+"Storage"]),i=document.createElement("button"),document.getElementsByTagName("head")[0].appendChild(i),"local"==a?j=u:"session"==a&&d();for(h in j)j.hasOwnProperty(h)&&"__jstorage_meta"!=h&&"length"!=h&&"undefined"!=typeof j[h]&&(h in i||g++,i[h]=j[h]);i.length=g,i.key=function(a){var c,b=0;d();for(c in j)if(j.hasOwnProperty(c)&&"__jstorage_meta"!=c&&"length"!=c&&"undefined"!=typeof j[c]){if(b==a)return c;b++}},i.getItem=function(b){return d(),"session"==a?j[b]:s.jStorage.get(b)},i.setItem=function(a,b){"undefined"!=typeof b&&(i[a]=(b||"").toString())},i.removeItem=function(b){return"local"==a?s.jStorage.deleteKey(b):(i[b]=void 0,f=!0,b in i&&i.removeAttribute(b),void(f=!1))},i.clear=function(){return"session"==a?(window.name="",void b("session",!0)):void s.jStorage.flush()},"local"==a&&(H=function(a,b){"length"!=a&&(f=!0,"undefined"==typeof b?a in i&&(g--,i.removeAttribute(a)):(a in i||g++,i[a]=(b||"").toString()),i.length=g,f=!1)}),i.attachEvent("onpropertychange",function(b){if("length"!=b.propertyName&&!f&&"length"!=b.propertyName){if("local"==a)b.propertyName in j||"undefined"==typeof i[b.propertyName]||g++;else if("session"==a)return d(),"undefined"==typeof i[b.propertyName]||b.propertyName in j?"undefined"==typeof i[b.propertyName]&&b.propertyName in j?(delete j[b.propertyName],g--):j[b.propertyName]=i[b.propertyName]:(j[b.propertyName]=i[b.propertyName],g++),e(),void(i.length=g);s.jStorage.set(b.propertyName,i[b.propertyName]),i.length=g}}),window[a+"Storage"]=i}}}function c(){var a="{}";if("userDataBehavior"==y){w.load("jStorage");try{a=w.getAttribute("jStorage")}catch(a){}try{B=w.getAttribute("jStorage_update")}catch(a){}v.jStorage=a}i(),l(),m()}function d(){"localStorage"==y||"globalStorage"==y?"addEventListener"in window?window.addEventListener("storage",e,!1):document.attachEvent("onstorage",e):"userDataBehavior"==y&&setInterval(e,1e3)}function e(){var a;clearTimeout(A),A=setTimeout(function(){if("localStorage"==y||"globalStorage"==y)a=v.jStorage_update;else if("userDataBehavior"==y){w.load("jStorage");try{a=w.getAttribute("jStorage_update")}catch(a){}}a&&a!=B&&(B=a,f())},25)}function f(){var b,a=t.parse(t.stringify(u.__jstorage_meta.CRC32));c(),b=t.parse(t.stringify(u.__jstorage_meta.CRC32));var d,e=[],f=[];for(d in a)if(a.hasOwnProperty(d)){if(!b[d]){f.push(d);continue}a[d]!=b[d]&&e.push(d)}for(d in b)b.hasOwnProperty(d)&&(a[d]||e.push(d));g(e,"updated"),g(f,"deleted")}function g(a,b){if(a=[].concat(a||[]),"flushed"==b){a=[];for(var c in z)z.hasOwnProperty(c)&&a.push(c);b="deleted"}for(var d=0,e=a.length;d<e;d++)if(z[a[d]])for(var f=0,g=z[a[d]].length;f<g;f++)z[a[d]][f](a[d],b)}function h(){var a=(+new Date).toString();"localStorage"==y||"globalStorage"==y?v.jStorage_update=a:"userDataBehavior"==y&&(w.setAttribute("jStorage_update",a),w.save("jStorage")),e()}function i(){if(v.jStorage)try{u=t.parse(String(v.jStorage))}catch(a){v.jStorage="{}"}else v.jStorage="{}";x=v.jStorage?String(v.jStorage).length:0,u.__jstorage_meta||(u.__jstorage_meta={}),u.__jstorage_meta.CRC32||(u.__jstorage_meta.CRC32={})}function j(){o();try{v.jStorage=t.stringify(u),w&&(w.setAttribute("jStorage",v.jStorage),w.save("jStorage")),x=v.jStorage?String(v.jStorage).length:0}catch(a){}}function k(a){if(!a||"string"!=typeof a&&"number"!=typeof a)throw new TypeError("Key name must be string or numeric");if("__jstorage_meta"==a)throw new TypeError("Reserved key name");return!0}function l(){var a,b,c,d,e=1/0,f=!1,i=[];if(clearTimeout(E),u.__jstorage_meta&&"object"==typeof u.__jstorage_meta.TTL){a=+new Date,c=u.__jstorage_meta.TTL,d=u.__jstorage_meta.CRC32;for(b in c)c.hasOwnProperty(b)&&(c[b]<=a?(delete c[b],delete d[b],delete u[b],f=!0,i.push(b)):c[b]<e&&(e=c[b]));e!=1/0&&(E=setTimeout(l,e-a)),f&&(j(),h(),g(i,"deleted"))}}function m(){if(u.__jstorage_meta.PubSub){for(var a,b=D,c=len=u.__jstorage_meta.PubSub.length-1;c>=0;c--)a=u.__jstorage_meta.PubSub[c],a[0]>D&&(b=a[0],n(a[1],a[2]));D=b}}function n(a,b){if(C[a])for(var c=0,d=C[a].length;c<d;c++)C[a][c](a,t.parse(t.stringify(b)));
}function o(){if(u.__jstorage_meta.PubSub){for(var a=+new Date-2e3,b=0,c=u.__jstorage_meta.PubSub.length;b<c;b++)if(u.__jstorage_meta.PubSub[b][0]<=a){u.__jstorage_meta.PubSub.splice(b,u.__jstorage_meta.PubSub.length-b);break}u.__jstorage_meta.PubSub.length||delete u.__jstorage_meta.PubSub}}function p(a,b){u.__jstorage_meta||(u.__jstorage_meta={}),u.__jstorage_meta.PubSub||(u.__jstorage_meta.PubSub=[]),u.__jstorage_meta.PubSub.unshift([+new Date,a,b]),j(),h()}function q(a,b){b=b||0;var c=0,d=0;b^=-1;for(var e=0,f=a.length;e<f;e++)c=255&(b^a.charCodeAt(e)),d="0x"+F.substr(9*c,8),b=b>>>8^d;return b^-1}var r="0.3.0",s=window.jQuery||window.$||(window.$={}),t={parse:window.JSON&&(window.JSON.parse||window.JSON.decode)||String.prototype.evalJSON&&function(a){return String(a).evalJSON()}||s.parseJSON||s.evalJSON,stringify:Object.toJSON||window.JSON&&(window.JSON.stringify||window.JSON.encode)||s.toJSON};if(!t.parse||!t.stringify)throw new Error("No JSON support found, include //cdnjs.cloudflare.com/ajax/libs/json2/20110223/json2.js to page");var E,u={},v={jStorage:"{}"},w=null,x=0,y=!1,z={},A=!1,B=0,C={},D=+new Date,F="00000000 77073096 EE0E612C 990951BA 076DC419 706AF48F E963A535 9E6495A3 0EDB8832 79DCB8A4 E0D5E91E 97D2D988 09B64C2B 7EB17CBD E7B82D07 90BF1D91 1DB71064 6AB020F2 F3B97148 84BE41DE 1ADAD47D 6DDDE4EB F4D4B551 83D385C7 136C9856 646BA8C0 FD62F97A 8A65C9EC 14015C4F 63066CD9 FA0F3D63 8D080DF5 3B6E20C8 4C69105E D56041E4 A2677172 3C03E4D1 4B04D447 D20D85FD A50AB56B 35B5A8FA 42B2986C DBBBC9D6 ACBCF940 32D86CE3 45DF5C75 DCD60DCF ABD13D59 26D930AC 51DE003A C8D75180 BFD06116 21B4F4B5 56B3C423 CFBA9599 B8BDA50F 2802B89E 5F058808 C60CD9B2 B10BE924 2F6F7C87 58684C11 C1611DAB B6662D3D 76DC4190 01DB7106 98D220BC EFD5102A 71B18589 06B6B51F 9FBFE4A5 E8B8D433 7807C9A2 0F00F934 9609A88E E10E9818 7F6A0DBB 086D3D2D 91646C97 E6635C01 6B6B51F4 1C6C6162 856530D8 F262004E 6C0695ED 1B01A57B 8208F4C1 F50FC457 65B0D9C6 12B7E950 8BBEB8EA FCB9887C 62DD1DDF 15DA2D49 8CD37CF3 FBD44C65 4DB26158 3AB551CE A3BC0074 D4BB30E2 4ADFA541 3DD895D7 A4D1C46D D3D6F4FB 4369E96A 346ED9FC AD678846 DA60B8D0 44042D73 33031DE5 AA0A4C5F DD0D7CC9 5005713C 270241AA BE0B1010 C90C2086 5768B525 206F85B3 B966D409 CE61E49F 5EDEF90E 29D9C998 B0D09822 C7D7A8B4 59B33D17 2EB40D81 B7BD5C3B C0BA6CAD EDB88320 9ABFB3B6 03B6E20C 74B1D29A EAD54739 9DD277AF 04DB2615 73DC1683 E3630B12 94643B84 0D6D6A3E 7A6A5AA8 E40ECF0B 9309FF9D 0A00AE27 7D079EB1 F00F9344 8708A3D2 1E01F268 6906C2FE F762575D 806567CB 196C3671 6E6B06E7 FED41B76 89D32BE0 10DA7A5A 67DD4ACC F9B9DF6F 8EBEEFF9 17B7BE43 60B08ED5 D6D6A3E8 A1D1937E 38D8C2C4 4FDFF252 D1BB67F1 A6BC5767 3FB506DD 48B2364B D80D2BDA AF0A1B4C 36034AF6 41047A60 DF60EFC3 A867DF55 316E8EEF 4669BE79 CB61B38C BC66831A 256FD2A0 5268E236 CC0C7795 BB0B4703 220216B9 5505262F C5BA3BBE B2BD0B28 2BB45A92 5CB36A04 C2D7FFA7 B5D0CF31 2CD99E8B 5BDEAE1D 9B64C2B0 EC63F226 756AA39C 026D930A 9C0906A9 EB0E363F 72076785 05005713 95BF4A82 E2B87A14 7BB12BAE 0CB61B38 92D28E9B E5D5BE0D 7CDCEFB7 0BDBDF21 86D3D2D4 F1D4E242 68DDB3F8 1FDA836E 81BE16CD F6B9265B 6FB077E1 18B74777 88085AE6 FF0F6A70 66063BCA 11010B5C 8F659EFF F862AE69 616BFFD3 166CCF45 A00AE278 D70DD2EE 4E048354 3903B3C2 A7672661 D06016F7 4969474D 3E6E77DB AED16A4A D9D65ADC 40DF0B66 37D83BF0 A9BCAE53 DEBB9EC5 47B2CF7F 30B5FFE9 BDBDF21C CABAC28A 53B39330 24B4A3A6 BAD03605 CDD70693 54DE5729 23D967BF B3667A2E C4614AB8 5D681B02 2A6F2B94 B40BBE37 C30C8EA1 5A05DF1B 2D02EF8D",G={isXML:function(a){var b=(a?a.ownerDocument||a:0).documentElement;return!!b&&"HTML"!==b.nodeName},encode:function(a){if(!this.isXML(a))return!1;try{return(new XMLSerializer).serializeToString(a)}catch(b){try{return a.xml}catch(a){}}return!1},decode:function(a){var c,b="DOMParser"in window&&(new DOMParser).parseFromString||window.ActiveXObject&&function(a){var b=new ActiveXObject("Microsoft.XMLDOM");return b.async="false",b.loadXML(a),b};return!!b&&(c=b.call("DOMParser"in window&&new DOMParser||window,a,"text/xml"),!!this.isXML(c)&&c)}},H=function(){};s.jStorage={version:r,set:function(a,b,c){if(k(a),c=c||{},"undefined"==typeof b)return this.deleteKey(a),b;if(G.isXML(b))b={_is_xml:!0,xml:G.encode(b)};else{if("function"==typeof b)return;b&&"object"==typeof b&&(b=t.parse(t.stringify(b)))}return u[a]=b,u.__jstorage_meta.CRC32[a]=q(t.stringify(b)),this.setTTL(a,c.TTL||0),H(a,b),g(a,"updated"),b},get:function(a,b){return k(a),a in u?u[a]&&"object"==typeof u[a]&&u[a]._is_xml&&u[a]._is_xml?G.decode(u[a].xml):u[a]:"undefined"==typeof b?null:b},deleteKey:function(a){return k(a),a in u&&(delete u[a],"object"==typeof u.__jstorage_meta.TTL&&a in u.__jstorage_meta.TTL&&delete u.__jstorage_meta.TTL[a],delete u.__jstorage_meta.CRC32[a],H(a,void 0),j(),h(),g(a,"deleted"),!0)},setTTL:function(a,b){var c=+new Date;return k(a),b=Number(b)||0,a in u&&(u.__jstorage_meta.TTL||(u.__jstorage_meta.TTL={}),b>0?u.__jstorage_meta.TTL[a]=c+b:delete u.__jstorage_meta.TTL[a],j(),l(),h(),!0)},getTTL:function(a){var c,b=+new Date;return k(a),a in u&&u.__jstorage_meta.TTL&&u.__jstorage_meta.TTL[a]?(c=u.__jstorage_meta.TTL[a]-b,c||0):0},flush:function(){return u={__jstorage_meta:{CRC32:{}}},b("local",!0),j(),h(),g(null,"flushed"),!0},storageObj:function(){function a(){}return a.prototype=u,new a},index:function(){var b,a=[];for(b in u)u.hasOwnProperty(b)&&"__jstorage_meta"!=b&&a.push(b);return a},storageSize:function(){return x},currentBackend:function(){return y},storageAvailable:function(){return!!y},listenKeyChange:function(a,b){k(a),z[a]||(z[a]=[]),z[a].push(b)},stopListening:function(a,b){if(k(a),z[a]){if(!b)return void delete z[a];for(var c=z[a].length-1;c>=0;c--)z[a][c]==b&&z[a].splice(c,1)}},subscribe:function(a,b){if(a=(a||"").toString(),!a)throw new TypeError("Channel not defined");C[a]||(C[a]=[]),C[a].push(b)},publish:function(a,b){if(a=(a||"").toString(),!a)throw new TypeError("Channel not defined");p(a,b)},reInit:function(){c()}},a()}(),function(a,b){function c(c,d){function e(a){return h.preferFlash&&Aa&&!h.ignoreFlash&&h.flash[a]!==b&&h.flash[a]}function f(a){return function(b){var c=this._s;return c&&c._a?a.call(this,b):null}}this.setupOptions={url:c||null,flashVersion:8,debugMode:!0,debugFlash:!1,useConsole:!0,consoleOnly:!0,waitForWindowLoad:!1,bgColor:"#ffffff",useHighPerformance:!1,flashPollingInterval:null,html5PollingInterval:null,flashLoadTimeout:1e3,wmode:null,allowScriptAccess:"always",useFlashBlock:!1,useHTML5Audio:!0,html5Test:/^(probably|maybe)$/i,preferFlash:!1,noSWFCache:!1,idPrefix:"sound"},this.defaultOptions={autoLoad:!1,autoPlay:!1,from:null,loops:1,onid3:null,onload:null,whileloading:null,onplay:null,onpause:null,onresume:null,whileplaying:null,onposition:null,onstop:null,onfailure:null,onfinish:null,multiShot:!0,multiShotEvents:!1,position:null,pan:0,stream:!0,to:null,type:null,usePolicyFile:!1,volume:100},this.flash9Options={isMovieStar:null,usePeakData:!1,useWaveformData:!1,useEQData:!1,onbufferchange:null,ondataerror:null},this.movieStarOptions={bufferTime:3,serverURL:null,onconnect:null,duration:null},this.audioFormats={mp3:{type:['audio/mpeg; codecs="mp3"',"audio/mpeg","audio/mp3","audio/MPA","audio/mpa-robust"],required:!0},mp4:{related:["aac","m4a","m4b"],type:['audio/mp4; codecs="mp4a.40.2"',"audio/aac","audio/x-m4a","audio/MP4A-LATM","audio/mpeg4-generic"],required:!1},ogg:{type:["audio/ogg; codecs=vorbis"],required:!1},opus:{type:["audio/ogg; codecs=opus","audio/opus"],required:!1},wav:{type:['audio/wav; codecs="1"',"audio/wav","audio/wave","audio/x-wav"],required:!1}},this.movieID="sm2-container",this.id=d||"sm2movie",this.debugID="soundmanager-debug",this.debugURLParam=/([#?&])debug=1/i,this.versionNumber="V2.97a.20140901",this.altURL=this.movieURL=this.version=null,this.enabled=this.swfLoaded=!1,this.oMC=null,this.sounds={},this.soundIDs=[],this.didFlashBlock=this.muted=!1,this.filePattern=null,this.filePatterns={flash8:/.mp3(?.*)?$/i,flash9:/.mp3(?.*)?$/i},this.features={buffering:!1,peakData:!1,waveformData:!1,eqData:!1,movieStar:!1},this.sandbox={},this.html5={usingFlash:null},this.flash={},this.ignoreFlash=this.html5Only=!1;var g,k,o,p,q,r,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,$,_,aa,ba,ca,da,ga,ha,ia,la,na,pa,qa,ra,sa,ta,ua,va,wa,za,Aa,Ba,Ca,Da,Ea,h=this,i=null,j=null,l=navigator.userAgent,m=a.location.href.toString(),n=document,s=[],t=!1,u=!1,v=!1,w=!1,x=!1,Y=null,Z=null,ea=!1,fa=!1,ja=0,ka=null,ma=[],oa=null,xa=Array.prototype.slice,ya=!1,Fa=0,Ga=l.match(/(ipad|iphone|ipod)/i),Ha=l.match(/android/i),Ia=l.match(/msie/i),Ja=l.match(/webkit/i),Ka=l.match(/safari/i)&&!l.match(/chrome/i),La=l.match(/opera/i),Ma=l.match(/(mobile|pre/|xoom)/i)||Ga||Ha,Na=!m.match(/usehtml5audio/i)&&!m.match(/sm2-ignorebadua/i)&&Ka&&!l.match(/silk/i)&&l.match(/OS X 10_6_([3-7])/i),Oa=n.hasFocus!==b?n.hasFocus():null,Pa=Ka&&(n.hasFocus===b||!n.hasFocus()),Qa=!Pa,Ra=/(mp3|mp4|mpa|m4a|m4b)/i,Sa=n.location?n.location.protocol.match(/http/i):null,Ta=Sa?"":"http://",Ua=/^s*audio/(?:x-)?(?:mpeg4|aac|flv|mov|mp4||m4v|m4a|m4b|mp4v|3gp|3g2)s*(?:$|;)/i,Va="mpeg4 aac flv mov mp4 m4v f4v m4a m4b mp4v 3gp 3g2".split(" "),Wa=RegExp("\.("+Va.join("|")+")(\?.*)?$","i");this.mimePattern=/^s*audio/(?:x-)?(?:mp(?:eg|3))s*(?:$|;)/i,this.useAltURL=!Sa;var Xa;try{Xa=Audio!==b&&(La&&opera!==b&&10>opera.version()?new Audio(null):new Audio).canPlayType!==b}catch(a){Xa=!1}this.hasHTML5=Xa,this.setup=function(a){var c=!h.url;return a!==b&&v&&oa&&h.ok(),A(a),a&&(c&&P&&a.url!==b&&h.beginDelayedInit(),!P&&a.url!==b&&"complete"===n.readyState&&setTimeout(N,1)),h},this.supported=this.ok=function(){return oa?v&&!w:h.useHTML5Audio&&h.hasHTML5},this.getMovie=function(b){return k(b)||n[b]||a[b]},this.createSound=function(a,c){function d(){return e=ba(e),h.sounds[e.id]=new g(e),h.soundIDs.push(e.id),h.sounds[e.id]}var e,f=null;if(!v||!h.ok())return!1;if(c!==b&&(a={id:a,url:c}),e=z(a),e.url=la(e.url),void 0===e.id&&(e.id=h.setupOptions.idPrefix+Fa++),da(e.id,!0))return h.sounds[e.id];if(qa(e))f=d(),f._setup_html5(e);else{if(h.html5Only||h.html5.usingFlash&&e.url&&e.url.match(/data:/i))return d();8<r&&null===e.isMovieStar&&(e.isMovieStar=!(!e.serverURL&&!(e.type&&e.type.match(Ua)||e.url&&e.url.match(Wa)))),e=ca(e,void 0),f=d(),8===r?j._createSound(e.id,e.loops||1,e.usePolicyFile):(j._createSound(e.id,e.url,e.usePeakData,e.useWaveformData,e.useEQData,e.isMovieStar,!!e.isMovieStar&&e.bufferTime,e.loops||1,e.serverURL,e.duration||null,e.autoPlay,!0,e.autoLoad,e.usePolicyFile),e.serverURL||(f.connected=!0,e.onconnect&&e.onconnect.apply(f))),!e.serverURL&&(e.autoLoad||e.autoPlay)&&f.load(e)}return!e.serverURL&&e.autoPlay&&f.play(),f},this.destroySound=function(a,b){if(!da(a))return!1;var d,c=h.sounds[a];for(c._iO={},c.stop(),c.unload(),d=0;d<h.soundIDs.length;d++)if(h.soundIDs[d]===a){h.soundIDs.splice(d,1);break}return b||c.destruct(!0),delete h.sounds[a],!0},this.load=function(a,b){return!!da(a)&&h.sounds[a].load(b)},this.unload=function(a){return!!da(a)&&h.sounds[a].unload()},this.onposition=this.onPosition=function(a,b,c,d){return!!da(a)&&h.sounds[a].onposition(b,c,d)},this.clearOnPosition=function(a,b,c){return!!da(a)&&h.sounds[a].clearOnPosition(b,c)},this.start=this.play=function(a,b){var c=null,d=b&&!(b instanceof Object);if(!v||!h.ok())return!1;if(da(a,d))d&&(b={url:b});else{if(!d)return!1;d&&(b={url:b}),b&&b.url&&(b.id=a,c=h.createSound(b).play())}return null===c&&(c=h.sounds[a].play(b)),c},this.setPosition=function(a,b){return!!da(a)&&h.sounds[a].setPosition(b)},this.stop=function(a){return!!da(a)&&h.sounds[a].stop()},this.stopAll=function(){for(var a in h.sounds)h.sounds.hasOwnProperty(a)&&h.sounds[a].stop()},this.pause=function(a){return!!da(a)&&h.sounds[a].pause()},this.pauseAll=function(){var a;for(a=h.soundIDs.length-1;0<=a;a--)h.sounds[h.soundIDs[a]].pause()},this.resume=function(a){return!!da(a)&&h.sounds[a].resume()},this.resumeAll=function(){var a;for(a=h.soundIDs.length-1;0<=a;a--)h.sounds[h.soundIDs[a]].resume()},this.togglePause=function(a){return!!da(a)&&h.sounds[a].togglePause()},this.setPan=function(a,b){return!!da(a)&&h.sounds[a].setPan(b)},this.setVolume=function(a,b){return!!da(a)&&h.sounds[a].setVolume(b)},this.mute=function(a){var b=0;if(a instanceof String&&(a=null),a)return!!da(a)&&h.sounds[a].mute();for(b=h.soundIDs.length-1;0<=b;b--)h.sounds[h.soundIDs[b]].mute();return h.muted=!0},this.muteAll=function(){h.mute()},this.unmute=function(a){if(a instanceof String&&(a=null),a)return!!da(a)&&h.sounds[a].unmute();for(a=h.soundIDs.length-1;0<=a;a--)h.sounds[h.soundIDs[a]].unmute();return h.muted=!1,!0},this.unmuteAll=function(){h.unmute()},this.toggleMute=function(a){return!!da(a)&&h.sounds[a].toggleMute()},this.getMemoryUse=function(){var a=0;return j&&8!==r&&(a=parseInt(j._getMemoryUse(),10)),a},this.disable=function(c){var d;if(c===b&&(c=!1),w)return!1;for(w=!0,d=h.soundIDs.length-1;0<=d;d--)V(h.sounds[h.soundIDs[d]]);return y(c),wa.remove(a,"load",E),!0},this.canPlayMIME=function(a){var b;return h.hasHTML5&&(b=ra({type:a})),!b&&oa&&(b=a&&h.ok()?!!(8<r&&a.match(Ua)||a.match(h.mimePattern)):null),b},this.canPlayURL=function(a){var b;return h.hasHTML5&&(b=ra({url:a})),!b&&oa&&(b=a&&h.ok()?!!a.match(h.filePattern):null),b},this.canPlayLink=function(a){return!(a.type===b||!a.type||!h.canPlayMIME(a.type))||h.canPlayURL(a.href)},this.getSoundById=function(a,b){return a?h.sounds[a]:null},this.onready=function(b,c){if("function"!=typeof b)throw $("needFunction","onready");return c||(c=a),C("onready",b,c),D(),!0},this.ontimeout=function(b,c){if("function"!=typeof b)throw $("needFunction","ontimeout");return c||(c=a),C("ontimeout",b,c),D({type:"ontimeout"}),!0},this._wD=this._writeDebug=function(a,b){return!0},this._debug=function(){},this.reboot=function(b,c){var d,e,f;for(d=h.soundIDs.length-1;0<=d;d--)h.sounds[h.soundIDs[d]].destruct();if(j)try{Ia&&(Z=j.innerHTML),Y=j.parentNode.removeChild(j)}catch(a){}if(Z=Y=oa=j=null,h.enabled=P=v=ea=fa=t=u=w=ya=h.swfLoaded=!1,h.soundIDs=[],h.sounds={},Fa=0,b)s=[];else for(d in s)if(s.hasOwnProperty(d))for(e=0,f=s[d].length;e<f;e++)s[d][e].fired=!1;return h.html5={usingFlash:null},h.flash={},h.html5Only=!1,h.ignoreFlash=!1,a.setTimeout(function(){M(),c||h.beginDelayedInit()},20),h},this.reset=function(){return h.reboot(!0,!0)},this.getMoviePercent=function(){return j&&"PercentLoaded"in j?j.PercentLoaded():null},this.beginDelayedInit=function(){x=!0,N(),setTimeout(function(){return!fa&&(R(),L(),fa=!0)},20),F()},this.destruct=function(){h.disable(!0)},g=function(a){var c,d,f,g,k,l,m,n,s,t,v,e=this,o=!1,p=[],q=0,u=null;d=c=null,this.sID=this.id=a.id,this.url=a.url,this._iO=this.instanceOptions=this.options=z(a),this.pan=this.options.pan,this.volume=this.options.volume,this.isHTML5=!1,this._a=null,v=!this.url,this.id3={},this._debug=function(){},this.load=function(a){var d,c=null;if(a!==b?e._iO=z(a,e.options):(a=e.options,e._iO=a,u&&u!==e.url&&(e._iO.url=e.url,e.url=null)),e._iO.url||(e._iO.url=e.url),e._iO.url=la(e._iO.url),d=e.instanceOptions=e._iO,!d.url&&!e.url)return e;if(d.url===e.url&&0!==e.readyState&&2!==e.readyState)return 3===e.readyState&&d.onload&&Ea(e,function(){d.onload.apply(e,[!!e.duration])}),e;if(e.loaded=!1,e.readyState=1,e.playState=0,e.id3={},qa(d))c=e._setup_html5(d),c._called_load||(e._html5_canplay=!1,e.url!==d.url&&(e._a.src=d.url,e.setPosition(0)),e._a.autobuffer="auto",e._a.preload="auto",e._a._called_load=!0);else{if(h.html5Only||e._iO.url&&e._iO.url.match(/data:/i))return e;try{e.isHTML5=!1,e._iO=ca(ba(d)),e._iO.autoPlay&&(e._iO.position||e._iO.from)&&(e._iO.autoPlay=!1),d=e._iO,8===r?j._load(e.id,d.url,d.stream,d.autoPlay,d.usePolicyFile):j._load(e.id,d.url,!!d.stream,!!d.autoPlay,d.loops||1,!!d.autoLoad,d.usePolicyFile)}catch(a){S({type:"SMSOUND_LOAD_JS_EXCEPTION",fatal:!0})}}return e.url=d.url,e},this.unload=function(){return 0!==e.readyState&&(e.isHTML5?(l(),e._a&&(e._a.pause(),u=ta(e._a))):8===r?j._unload(e.id,"about:blank"):j._unload(e.id),f()),e},this.destruct=function(a){e.isHTML5?(l(),e._a&&(e._a.pause(),ta(e._a),ya||k(),e._a._s=null,e._a=null)):(e._iO.onfailure=null,j._destroySound(e.id)),a||h.destroySound(e.id,!0)},this.start=this.play=function(a,c){var d,f,g,i,k;if(f=!0,f=null,c=c===b||c,a||(a={}),e.url&&(e._iO.url=e.url),e._iO=z(e._iO,e.options),e._iO=z(a,e._iO),e._iO.url=la(e._iO.url),e.instanceOptions=e._iO,!e.isHTML5&&e._iO.serverURL&&!e.connected)return e.getAutoPlay()||e.setAutoPlay(!0),e;if(qa(e._iO)&&(e._setup_html5(e._iO),m()),1===e.playState&&!e.paused&&(d=e._iO.multiShot,d||(e.isHTML5&&e.setPosition(e._iO.position),f=e)),null!==f)return f;if(a.url&&a.url!==e.url&&(e.readyState||e.isHTML5||8!==r||!v?e.load(e._iO):v=!1),e.loaded||(0===e.readyState?(e.isHTML5||h.html5Only?e.isHTML5?e.load(e._iO):f=e:(e._iO.autoPlay=!0,e.load(e._iO)),e.instanceOptions=e._iO):2===e.readyState&&(f=e)),null!==f)return f;if(!e.isHTML5&&9===r&&0<e.position&&e.position===e.duration&&(a.position=0),e.paused&&0<=e.position&&(!e._iO.serverURL||0<e.position))e.resume();else{if(e._iO=z(a,e._iO),(!e.isHTML5&&null!==e._iO.position&&0<e._iO.position||null!==e._iO.from&&0<e._iO.from||null!==e._iO.to)&&0===e.instanceCount&&0===e.playState&&!e._iO.serverURL){if(d=function(){e._iO=z(a,e._iO),e.play(e._iO)},e.isHTML5&&!e._html5_canplay?(e.load({_oncanplay:d}),f=!1):e.isHTML5||e.loaded||e.readyState&&2===e.readyState||(e.load({onload:d}),f=!1),null!==f)return f;e._iO=t()}(!e.instanceCount||e._iO.multiShotEvents||e.isHTML5&&e._iO.multiShot&&!ya||!e.isHTML5&&8<r&&!e.getAutoPlay())&&e.instanceCount++,e._iO.onposition&&0===e.playState&&n(e),e.playState=1,e.paused=!1,e.position=e._iO.position===b||isNaN(e._iO.position)?0:e._iO.position,e.isHTML5||(e._iO=ca(ba(e._iO))),e._iO.onplay&&c&&(e._iO.onplay.apply(e),o=!0),e.setVolume(e._iO.volume,!0),e.setPan(e._iO.pan,!0),e.isHTML5?2>e.instanceCount?(m(),f=e._setup_html5(),e.setPosition(e._iO.position),f.play()):(g=new Audio(e._iO.url),i=function(){wa.remove(g,"ended",i),e._onfinish(e),ta(g),g=null},k=function(){wa.remove(g,"canplay",k);try{g.currentTime=e._iO.position/1e3}catch(a){}g.play()},wa.add(g,"ended",i),void 0!==e._iO.volume&&(g.volume=Math.max(0,Math.min(1,e._iO.volume/100))),e.muted&&(g.muted=!0),e._iO.position?wa.add(g,"canplay",k):g.play()):(f=j._start(e.id,e._iO.loops||1,9===r?e.position:e.position/1e3,e._iO.multiShot||!1),9===r&&!f&&e._iO.onplayerror&&e._iO.onplayerror.apply(e))}return e},this.stop=function(a){var b=e._iO;return 1===e.playState&&(e._onbufferchange(0),e._resetOnPosition(0),e.paused=!1,e.isHTML5||(e.playState=0),s(),b.to&&e.clearOnPosition(b.to),e.isHTML5?e._a&&(a=e.position,e.setPosition(0),e.position=a,e._a.pause(),e.playState=0,e._onTimer(),l()):(j._stop(e.id,a),b.serverURL&&e.unload()),e.instanceCount=0,e._iO={},b.onstop&&b.onstop.apply(e)),e},this.setAutoPlay=function(a){e._iO.autoPlay=a,e.isHTML5||(j._setAutoPlay(e.id,a),a&&!e.instanceCount&&1===e.readyState&&e.instanceCount++)},this.getAutoPlay=function(){return e._iO.autoPlay},this.setPosition=function(a){a===b&&(a=0);var c=e.isHTML5?Math.max(a,0):Math.min(e.duration||e._iO.duration,Math.max(a,0));if(e.position=c,a=e.position/1e3,e._resetOnPosition(e.position),e._iO.position=c,e.isHTML5){if(e._a){if(e._html5_canplay){if(e._a.currentTime!==a)try{e._a.currentTime=a,(0===e.playState||e.paused)&&e._a.pause()}catch(a){}}else if(a)return e;e.paused&&e._onTimer(!0)}}else a=9===r?e.position:a,e.readyState&&2!==e.readyState&&j._setPosition(e.id,a,e.paused||!e.playState,e._iO.multiShot);return e},this.pause=function(a){return e.paused||0===e.playState&&1!==e.readyState?e:(e.paused=!0,e.isHTML5?(e._setup_html5().pause(),l()):(a||a===b)&&j._pause(e.id,e._iO.multiShot),e._iO.onpause&&e._iO.onpause.apply(e),e)},this.resume=function(){var a=e._iO;return e.paused?(e.paused=!1,e.playState=1,e.isHTML5?(e._setup_html5().play(),m()):(a.isMovieStar&&!a.serverURL&&e.setPosition(e.position),j._pause(e.id,a.multiShot)),!o&&a.onplay?(a.onplay.apply(e),o=!0):a.onresume&&a.onresume.apply(e),e):e},this.togglePause=function(){return 0===e.playState?(e.play({position:9!==r||e.isHTML5?e.position/1e3:e.position}),e):(e.paused?e.resume():e.pause(),e)},this.setPan=function(a,c){return a===b&&(a=0),c===b&&(c=!1),e.isHTML5||j._setPan(e.id,a),e._iO.pan=a,c||(e.pan=a,e.options.pan=a),e},this.setVolume=function(a,c){return a===b&&(a=100),c===b&&(c=!1),e.isHTML5?e._a&&(h.muted&&!e.muted&&(e.muted=!0,e._a.muted=!0),e._a.volume=Math.max(0,Math.min(1,a/100))):j._setVolume(e.id,h.muted&&!e.muted||e.muted?0:a),e._iO.volume=a,c||(e.volume=a,e.options.volume=a),e},this.mute=function(){return e.muted=!0,e.isHTML5?e._a&&(e._a.muted=!0):j._setVolume(e.id,0),e},this.unmute=function(){e.muted=!1;var a=e._iO.volume!==b;return e.isHTML5?e._a&&(e._a.muted=!1):j._setVolume(e.id,a?e._iO.volume:e.options.volume),e},this.toggleMute=function(){return e.muted?e.unmute():e.mute()},this.onposition=this.onPosition=function(a,c,d){return p.push({position:parseInt(a,10),method:c,scope:d!==b?d:e,fired:!1}),e},this.clearOnPosition=function(a,b){var c;if(a=parseInt(a,10),isNaN(a))return!1;for(c=0;c<p.length;c++)a!==p[c].position||b&&b!==p[c].method||(p[c].fired&&q--,p.splice(c,1))},this._processOnPosition=function(){var a,b;if(a=p.length,!a||!e.playState||q>=a)return!1;for(a-=1;0<=a;a--)b=p[a],!b.fired&&e.position>=b.position&&(b.fired=!0,q++,b.method.apply(b.scope,[b.position]));return!0},this._resetOnPosition=function(a){var b,c;if(b=p.length,!b)return!1;for(b-=1;0<=b;b--)c=p[b],c.fired&&a<=c.position&&(c.fired=!1,q--);return!0},t=function(){var d,f,a=e._iO,b=a.from,c=a.to;return f=function(){e.clearOnPosition(c,f),e.stop()},d=function(){null===c||isNaN(c)||e.onPosition(c,f)},null!==b&&!isNaN(b)&&(a.position=b,a.multiShot=!1,d()),a},n=function(){var a,b=e._iO.onposition;if(b)for(a in b)b.hasOwnProperty(a)&&e.onPosition(parseInt(a,10),b[a])},s=function(){var a,b=e._iO.onposition;if(b)for(a in b)b.hasOwnProperty(a)&&e.clearOnPosition(parseInt(a,10))},m=function(){e.isHTML5&&ga(e)},l=function(){e.isHTML5&&ha(e)},f=function(a){a||(p=[],q=0),o=!1,e._hasTimer=null,e._a=null,e._html5_canplay=!1,e.bytesLoaded=null,e.bytesTotal=null,e.duration=e._iO&&e._iO.duration?e._iO.duration:null,e.durationEstimate=null,e.buffered=[],e.eqData=[],e.eqData.left=[],e.eqData.right=[],e.failures=0,e.isBuffering=!1,e.instanceOptions={},e.instanceCount=0,e.loaded=!1,e.metadata={},e.readyState=0,e.muted=!1,e.paused=!1,e.peakData={left:0,right:0},e.waveformData={left:[],right:[]},e.playState=0,e.position=null,e.id3={}},f(),this._onTimer=function(a){var b,f=!1,g={};if(e._hasTimer||a)return e._a&&(a||(0<e.playState||1===e.readyState)&&!e.paused)&&(b=e._get_html5_duration(),b!==c&&(c=b,e.duration=b,f=!0),e.durationEstimate=e.duration,b=1e3*e._a.currentTime||0,b!==d&&(d=b,f=!0),(f||a)&&e._whileplaying(b,g,g,g,g)),f},this._get_html5_duration=function(){var a=e._iO;return(a=e._a&&e._a.duration?1e3*e._a.duration:a&&a.duration?a.duration:null)&&!isNaN(a)&&1/0!==a?a:null},this._apply_loop=function(a,b){a.loop=1<b?"loop":""},this._setup_html5=function(a){a=z(e._iO,a);var d,b=ya?i:e._a,c=decodeURI(a.url);if(ya?c===decodeURI(za)&&(d=!0):c===decodeURI(u)&&(d=!0),b){if(b._s)if(ya)b._s&&b._s.playState&&!d&&b._s.stop();else if(!ya&&c===decodeURI(u))return e._apply_loop(b,a.loops),b;d||(u&&f(!1),b.src=a.url,za=u=e.url=a.url,b._called_load=!1)}else a.autoLoad||a.autoPlay?(e._a=new Audio(a.url),e._a.load()):e._a=La&&10>opera.version()?new Audio(null):new Audio,b=e._a,b._called_load=!1,ya&&(i=b);return e.isHTML5=!0,e._a=b,b._s=e,g(),e._apply_loop(b,a.loops),a.autoLoad||a.autoPlay?e.load():(b.autobuffer=!1,b.preload="auto"),b},g=function(){if(e._a._added_events)return!1;var a;e._a._added_events=!0;for(a in Da)Da.hasOwnProperty(a)&&e._a&&e._a.addEventListener(a,Da[a],!1);return!0},k=function(){var a;e._a._added_events=!1;for(a in Da)Da.hasOwnProperty(a)&&e._a&&e._a.removeEventListener(a,Da[a],!1)},this._onload=function(a){var b=!!a||!e.isHTML5&&8===r&&e.duration;return e.loaded=b,e.readyState=b?3:2,e._onbufferchange(0),e._iO.onload&&Ea(e,function(){e._iO.onload.apply(e,[b])}),!0},this._onbufferchange=function(a){return!(0===e.playState||a&&e.isBuffering||!a&&!e.isBuffering)&&(e.isBuffering=1===a,e._iO.onbufferchange&&e._iO.onbufferchange.apply(e,[a]),!0)},this._onsuspend=function(){return e._iO.onsuspend&&e._iO.onsuspend.apply(e),!0},this._onfailure=function(a,b,c){e.failures++,e._iO.onfailure&&1===e.failures&&e._iO.onfailure(a,b,c)},this._onwarning=function(a,b,c){e._iO.onwarning&&e._iO.onwarning(a,b,c)},this._onfinish=function(){var a=e._iO.onfinish;e._onbufferchange(0),e._resetOnPosition(0),e.instanceCount&&(e.instanceCount--,e.instanceCount||(s(),e.playState=0,e.paused=!1,e.instanceCount=0,e.instanceOptions={},e._iO={},l(),e.isHTML5&&(e.position=0)),(!e.instanceCount||e._iO.multiShotEvents)&&a&&Ea(e,function(){a.apply(e)}))},this._whileloading=function(a,b,c,d){var f=e._iO;e.bytesLoaded=a,e.bytesTotal=b,e.duration=Math.floor(c),e.bufferLength=d,e.durationEstimate=e.isHTML5||f.isMovieStar?e.duration:f.duration?e.duration>f.duration?e.duration:f.duration:parseInt(e.bytesTotal/e.bytesLoaded*e.duration,10),e.isHTML5||(e.buffered=[{start:0,end:e.duration}]),(3!==e.readyState||e.isHTML5)&&f.whileloading&&f.whileloading.apply(e)},this._whileplaying=function(a,c,d,f,g){var h=e._iO;return!isNaN(a)&&null!==a&&(e.position=Math.max(0,a),e._processOnPosition(),!e.isHTML5&&8<r&&(h.usePeakData&&c!==b&&c&&(e.peakData={left:c.leftPeak,right:c.rightPeak}),h.useWaveformData&&d!==b&&d&&(e.waveformData={left:d.split(","),right:f.split(",")}),h.useEQData&&g!==b&&g&&g.leftEQ&&(a=g.leftEQ.split(","),e.eqData=a,e.eqData.left=a,g.rightEQ!==b&&g.rightEQ&&(e.eqData.right=g.rightEQ.split(",")))),1===e.playState&&(!e.isHTML5&&8===r&&!e.position&&e.isBuffering&&e._onbufferchange(0),h.whileplaying&&h.whileplaying.apply(e)),!0)},this._oncaptiondata=function(a){e.captiondata=a,e._iO.oncaptiondata&&e._iO.oncaptiondata.apply(e,[a])},this._onmetadata=function(a,b){var d,f,c={};for(d=0,f=a.length;d<f;d++)c[a[d]]=b[d];e.metadata=c,console.log("updated metadata",e.metadata),e._iO.onmetadata&&e._iO.onmetadata.call(e,e.metadata)},this._onid3=function(a,b){var d,f,c=[];for(d=0,f=a.length;d<f;d++)c[a[d]]=b[d];e.id3=z(e.id3,c),e._iO.onid3&&e._iO.onid3.apply(e)},this._onconnect=function(a){a=1===a,(e.connected=a)&&(e.failures=0,da(e.id)&&(e.getAutoPlay()?e.play(b,e.getAutoPlay()):e._iO.autoLoad&&e.load()),e._iO.onconnect&&e._iO.onconnect.apply(e,[a]))},this._ondataerror=function(a){0<e.playState&&e._iO.ondataerror&&e._iO.ondataerror.apply(e)}},Q=function(){return n.body||n.getElementsByTagName("div")[0]},k=function(a){return n.getElementById(a)},z=function(a,c){var e,f,d=a||{};e=c===b?h.defaultOptions:c;for(f in e)e.hasOwnProperty(f)&&d[f]===b&&(d[f]="object"!=typeof e[f]||null===e[f]?e[f]:z(d[f],e[f]));return d},Ea=function(b,c){b.isHTML5||8!==r?c():a.setTimeout(c,0)},B={onready:1,ontimeout:1,defaultOptions:1,flash9Options:1,movieStarOptions:1},A=function(a,c){var d,e=!0,f=c!==b,g=h.setupOptions;for(d in a)if(a.hasOwnProperty(d))if("object"!=typeof a[d]||null===a[d]||a[d]instanceof Array||a[d]instanceof RegExp)f&&B[c]!==b?h[c][d]=a[d]:g[d]!==b?(h.setupOptions[d]=a[d],h[d]=a[d]):B[d]===b?e=!1:h[d]instanceof Function?h[d].apply(h,a[d]instanceof Array?a[d]:[a[d]]):h[d]=a[d];else{if(B[d]!==b)return A(a[d],d);e=!1}return e},wa=function(){function b(a){a=xa.call(a);var b=a.length;return d?(a[1]="on"+a[1],3<b&&a.pop()):3===b&&a.push(!1),a}function c(a,b){var c=a.shift(),f=[e[b]];d?c[f](a[0],a[1]):c[f].apply(c,a)}var d=a.attachEvent,e={add:d?"attachEvent":"addEventListener",remove:d?"detachEvent":"removeEventListener"};return{add:function(){c(b(arguments),"add")},remove:function(){c(b(arguments),"remove")}}}(),Da={abort:f(function(){}),canplay:f(function(){var c,a=this._s;if(a._html5_canplay)return!0;if(a._html5_canplay=!0,a._onbufferchange(0),c=a._iO.position===b||isNaN(a._iO.position)?null:a._iO.position/1e3,this.currentTime!==c)try{this.currentTime=c}catch(a){}a._iO._oncanplay&&a._iO._oncanplay()}),canplaythrough:f(function(){var a=this._s;a.loaded||(a._onbufferchange(0),a._whileloading(a.bytesLoaded,a.bytesTotal,a._get_html5_duration()),a._onload(!0))}),durationchange:f(function(){var b,a=this._s;b=a._get_html5_duration(),!isNaN(b)&&b!==a.duration&&(a.durationEstimate=a.duration=b)}),ended:f(function(){this._s._onfinish()}),error:f(function(){this._s._onload(!1)}),loadeddata:f(function(){var a=this._s;!a._loaded&&!Ka&&(a.duration=a._get_html5_duration())}),loadedmetadata:f(function(){}),loadstart:f(function(){this._s._onbufferchange(1)}),play:f(function(){this._s._onbufferchange(0)}),playing:f(function(){this._s._onbufferchange(0)}),progress:f(function(a){var c,d,b=this._s,e=0,e=a.target.buffered;c=a.loaded||0;var f=a.total||1;if(b.buffered=[],e&&e.length){for(c=0,d=e.length;c<d;c++)b.buffered.push({start:1e3*e.start(c),end:1e3*e.end(c)});e=1e3*(e.end(0)-e.start(0)),c=Math.min(1,e/(1e3*a.target.duration))}isNaN(c)||(b._whileloading(c,f,b._get_html5_duration()),c&&f&&c===f&&Da.canplaythrough.call(this,a))}),ratechange:f(function(){}),suspend:f(function(a){var b=this._s;Da.progress.call(this,a),b._onsuspend()}),stalled:f(function(){}),timeupdate:f(function(){this._s._onTimer()}),waiting:f(function(){this._s._onbufferchange(1)})},qa=function(a){return!(!a||!(a.type||a.url||a.serverURL))&&(!(a.serverURL||a.type&&e(a.type))&&(a.type?ra({type:a.type}):ra({url:a.url})||h.html5Only||a.url.match(/data:/i)))},ta=function(a){var b;return a&&(b=Ka?"about:blank":h.html5.canPlayType("audio/wav")?"data:audio/wave;base64,/UklGRiYAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQIAAAD//w==":"about:blank",a.src=b,void 0!==a._called_unload&&(a._called_load=!1)),ya&&(za=null),b},ra=function(a){if(!h.useHTML5Audio||!h.hasHTML5)return!1;var c=a.url||null;a=a.type||null;var f,d=h.audioFormats;if(a&&h.html5[a]!==b)return h.html5[a]&&!e(a);if(!sa){sa=[];for(f in d)d.hasOwnProperty(f)&&(sa.push(f),d[f].related&&(sa=sa.concat(d[f].related)));sa=RegExp("\.("+sa.join("|")+")(\?.*)?$","i")}return f=c?c.toLowerCase().match(sa):null,f&&f.length?f=f[1]:a&&(c=a.indexOf(";"),f=(-1!==c?a.substr(0,c):a).substr(6)),f&&h.html5[f]!==b?c=h.html5[f]&&!e(f):(a="audio/"+f,c=h.html5.canPlayType({type:a}),c=(h.html5[f]=c)&&h.html5[a]&&!e(a)),c},va=function(){function a(a){var b,d=b=!1;if(!c||"function"!=typeof c.canPlayType)return b;if(a instanceof Array){for(i=0,b=a.length;i<b;i++)(h.html5[a[i]]||c.canPlayType(a[i]).match(h.html5Test))&&(d=!0,h.html5[a[i]]=!0,h.flash[a[i]]=!!a[i].match(Ra));b=d}else a=!(!c||"function"!=typeof c.canPlayType)&&c.canPlayType(a),b=!(!a||!a.match(h.html5Test));return b}if(!h.useHTML5Audio||!h.hasHTML5)return oa=h.html5.usingFlash=!0,!1;var d,e,g,i,c=Audio!==b?La&&10>opera.version()?new Audio(null):new Audio:null,f={};g=h.audioFormats;for(d in g)if(g.hasOwnProperty(d)&&(e="audio/"+d,f[d]=a(g[d].type),f[e]=f[d],d.match(Ra)?(h.flash[d]=!0,h.flash[e]=!0):(h.flash[d]=!1,h.flash[e]=!1),g[d]&&g[d].related))for(i=g[d].related.length-1;0<=i;i--)f["audio/"+g[d].related[i]]=f[d],h.html5[g[d].related[i]]=f[d],h.flash[g[d].related[i]]=f[d];return f.canPlayType=c?a:null,h.html5=z(h.html5,f),h.html5.usingFlash=pa(),oa=h.html5.usingFlash,!0},K={},$=function(){},ba=function(a){return 8===r&&1<a.loops&&a.stream&&(a.stream=!1),a},ca=function(a,b){return a&&!a.usePolicyFile&&(a.onid3||a.usePeakData||a.useWaveformData||a.useEQData)&&(a.usePolicyFile=!0),a},o=function(){return!1},V=function(a){for(var b in a)a.hasOwnProperty(b)&&"function"==typeof a[b]&&(a[b]=o)},W=function(a){a===b&&(a=!1),(w||a)&&h.disable(a)},X=function(a){var b=null;if(a)if(a.match(/.swf(?.*)?$/i)){if(b=a.substr(a.toLowerCase().lastIndexOf(".swf?")+4))return a}else a.lastIndexOf("/")!==a.length-1&&(a+="/");return a=(a&&-1!==a.lastIndexOf("/")?a.substr(0,a.lastIndexOf("/")+1):"./")+h.movieURL,h.noSWFCache&&(a+="?ts="+(new Date).getTime()),a},I=function(){r=parseInt(h.flashVersion,10),8!==r&&9!==r&&(h.flashVersion=r=8);var a=h.debugMode||h.debugFlash?"_debug.swf":".swf";h.useHTML5Audio&&!h.html5Only&&h.audioFormats.mp4.required&&9>r&&(h.flashVersion=r=9),h.version=h.versionNumber+(h.html5Only?" (HTML5-only mode)":9===r?" (AS3/Flash 9)":" (AS2/Flash 8)"),
8<r?(h.defaultOptions=z(h.defaultOptions,h.flash9Options),h.features.buffering=!0,h.defaultOptions=z(h.defaultOptions,h.movieStarOptions),h.filePatterns.flash9=RegExp("\.(mp3|"+Va.join("|")+")(\?.*)?$","i"),h.features.movieStar=!0):h.features.movieStar=!1,h.filePattern=h.filePatterns[8!==r?"flash9":"flash8"],h.movieURL=(8===r?"soundmanager2.swf":"soundmanager2_flash9.swf").replace(".swf",a),h.features.peakData=h.features.waveformData=h.features.eqData=8<r},T=function(a,b){return!!j&&void j._setPolling(a,b)},U=function(){},da=this.getSoundById,aa=function(){var a=[];return h.debugMode&&a.push("sm2_debug"),h.debugFlash&&a.push("flash_debug"),h.useHighPerformance&&a.push("high_performance"),a.join(" ")},_=function(){$("fbHandler");var a=h.getMoviePercent(),b={type:"FLASHBLOCK"};return!h.html5Only&&void(h.ok()?h.oMC&&(h.oMC.className=[aa(),"movieContainer","swf_loaded"+(h.didFlashBlock?" swf_unblocked":"")].join(" ")):(oa&&(h.oMC.className=aa()+" movieContainer "+(null===a?"swf_timedout":"swf_error")),h.didFlashBlock=!0,D({type:"ontimeout",ignoreInit:!0,error:b}),S(b)))},C=function(a,c,d){s[a]===b&&(s[a]=[]),s[a].push({method:c,scope:d||null,fired:!1})},D=function(a){if(a||(a={type:h.ok()?"onready":"ontimeout"}),!v&&a&&!a.ignoreInit||"ontimeout"===a.type&&(h.ok()||w&&!a.ignoreInit))return!1;var e,b={success:a&&a.ignoreInit?h.ok():!w},c=a&&a.type?s[a.type]||[]:[],d=[],b=[b],f=oa&&!h.ok();for(a.error&&(b[0].error=a.error),a=0,e=c.length;a<e;a++)!0!==c[a].fired&&d.push(c[a]);if(d.length)for(a=0,e=d.length;a<e;a++)d[a].scope?d[a].method.apply(d[a].scope,b):d[a].method.apply(this,b),f||(d[a].fired=!0);return!0},E=function(){a.setTimeout(function(){h.useFlashBlock&&_(),D(),"function"==typeof h.onload&&h.onload.apply(a),h.waitForWindowLoad&&wa.add(a,"load",E)},1)},Ba=function(){if(Aa!==b)return Aa;var f,c=!1,d=navigator,e=d.plugins,g=a.ActiveXObject;if(e&&e.length)(d=d.mimeTypes)&&d["application/x-shockwave-flash"]&&d["application/x-shockwave-flash"].enabledPlugin&&d["application/x-shockwave-flash"].enabledPlugin.description&&(c=!0);else if(g!==b&&!l.match(/MSAppHost/i)){try{f=new g("ShockwaveFlash.ShockwaveFlash")}catch(a){f=null}c=!!f}return Aa=c},pa=function(){var a,b,c=h.audioFormats;if(Ga&&l.match(/os (1|2|3_0|3_1)s/i)?(h.hasHTML5=!1,h.html5Only=!0,h.oMC&&(h.oMC.style.display="none")):!h.useHTML5Audio||h.html5&&h.html5.canPlayType||(h.hasHTML5=!1),h.useHTML5Audio&&h.hasHTML5)for(b in na=!0,c)c.hasOwnProperty(b)&&c[b].required&&(h.html5.canPlayType(c[b].type)?h.preferFlash&&(h.flash[b]||h.flash[c[b].type])&&(a=!0):(na=!1,a=!0));return h.ignoreFlash&&(a=!1,na=!0),h.html5Only=h.hasHTML5&&h.useHTML5Audio&&!a,!h.html5Only},la=function(a){var b,c,d=0;if(a instanceof Array){for(b=0,c=a.length;b<c;b++)if(a[b]instanceof Object){if(h.canPlayMIME(a[b].type)){d=b;break}}else if(h.canPlayURL(a[b])){d=b;break}a[d].url&&(a[d]=a[d].url),a=a[d]}return a},ga=function(a){a._hasTimer||(a._hasTimer=!0,!Ma&&h.html5PollingInterval&&(null===ka&&0===ja&&(ka=setInterval(ia,h.html5PollingInterval)),ja++))},ha=function(a){a._hasTimer&&(a._hasTimer=!1,!Ma&&h.html5PollingInterval&&ja--)},ia=function(){var a;if(null!==ka&&!ja)return clearInterval(ka),ka=null,!1;for(a=h.soundIDs.length-1;0<=a;a--)h.sounds[h.soundIDs[a]].isHTML5&&h.sounds[h.soundIDs[a]]._hasTimer&&h.sounds[h.soundIDs[a]]._onTimer()},S=function(c){c=c!==b?c:{},"function"==typeof h.onerror&&h.onerror.apply(a,[{type:c.type!==b?c.type:null}]),c.fatal!==b&&c.fatal&&h.disable()},Ca=function(){if(!Na||!Ba())return!1;var b,c,a=h.audioFormats;for(c in a)if(a.hasOwnProperty(c)&&("mp3"===c||"mp4"===c)&&(h.html5[c]=!1,a[c]&&a[c].related))for(b=a[c].related.length-1;0<=b;b--)h.html5[a[c].related[b]]=!1},this._setSandboxType=function(a){},this._externalInterfaceOK=function(a){return!h.swfLoaded&&(h.swfLoaded=!0,Pa=!1,Na&&Ca(),void setTimeout(q,Ia?100:1))},R=function(a,c){function d(a,b){return'<param name="'+a+'" value="'+b+'" />'}if(t&&u)return!1;if(h.html5Only)return I(),h.oMC=k(h.movieID),q(),u=t=!0,!1;var m,o,p,e=c||h.url,f=h.altURL||e,g=Q(),i=aa(),j=null,j=n.getElementsByTagName("html")[0],j=j&&j.dir&&j.dir.match(/rtl/i);if(a=a===b?h.id:a,I(),h.url=X(Sa?e:f),c=h.url,h.wmode=!h.wmode&&h.useHighPerformance?"transparent":h.wmode,null!==h.wmode&&(l.match(/msie 8/i)||!Ia&&!h.useHighPerformance)&&navigator.platform.match(/win32|win64/i)&&(ma.push(K.spcWmode),h.wmode=null),g={name:a,id:a,src:c,quality:"high",allowScriptAccess:h.allowScriptAccess,bgcolor:h.bgColor,pluginspage:Ta+"www.macromedia.com/go/getflashplayer",title:"JS/Flash audio component (SoundManager 2)",type:"application/x-shockwave-flash",wmode:h.wmode,hasPriority:"true"},h.debugFlash&&(g.FlashVars="debug=1"),h.wmode||delete g.wmode,Ia)e=n.createElement("div"),o=['<object id="'+a+'" data="'+c+'" type="'+g.type+'" title="'+g.title+'" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="'+Ta+'download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0">',d("movie",c),d("AllowScriptAccess",h.allowScriptAccess),d("quality",g.quality),h.wmode?d("wmode",h.wmode):"",d("bgcolor",h.bgColor),d("hasPriority","true"),h.debugFlash?d("FlashVars",g.FlashVars):"","</object>"].join("");else for(m in e=n.createElement("embed"),g)g.hasOwnProperty(m)&&e.setAttribute(m,g[m]);if(U(),i=aa(),g=Q())if(h.oMC=k(h.movieID)||n.createElement("div"),h.oMC.id)p=h.oMC.className,h.oMC.className=(p?p+" ":"movieContainer")+(i?" "+i:""),h.oMC.appendChild(e),Ia&&(m=h.oMC.appendChild(n.createElement("div")),m.className="sm2-object-box",m.innerHTML=o),u=!0;else{if(h.oMC.id=h.movieID,h.oMC.className="movieContainer "+i,m=i=null,h.useFlashBlock||(h.useHighPerformance?i={position:"fixed",width:"8px",height:"8px",bottom:"0px",left:"0px",overflow:"hidden"}:(i={position:"absolute",width:"6px",height:"6px",top:"-9999px",left:"-9999px"},j&&(i.left=Math.abs(parseInt(i.left,10))+"px"))),Ja&&(h.oMC.style.zIndex=1e4),!h.debugFlash)for(p in i)i.hasOwnProperty(p)&&(h.oMC.style[p]=i[p]);try{Ia||h.oMC.appendChild(e),g.appendChild(h.oMC),Ia&&(m=h.oMC.appendChild(n.createElement("div")),m.className="sm2-object-box",m.innerHTML=o),u=!0}catch(a){throw Error($("domError")+" n"+a.toString())}}return t=!0},L=function(){return h.html5Only?(R(),!1):!(j||!h.url)&&(j=h.getMovie(h.id),j||(Y?(Ia?h.oMC.innerHTML=Z:h.oMC.appendChild(Y),Y=null,t=!0):R(h.id,h.url),j=h.getMovie(h.id)),"function"==typeof h.oninitmovie&&setTimeout(h.oninitmovie,1),!0)},F=function(){setTimeout(G,1e3)},H=function(){a.setTimeout(function(){h.setup({preferFlash:!1}).reboot(),h.didFlashBlock=!0,h.beginDelayedInit()},1)},G=function(){var b,c=!1;return!(!h.url||ea)&&(ea=!0,wa.remove(a,"load",F),!(Aa&&Pa&&!Oa)&&(v||(b=h.getMoviePercent(),0<b&&100>b&&(c=!0)),void setTimeout(function(){return b=h.getMoviePercent(),c?(ea=!1,a.setTimeout(F,1),!1):void(!v&&Qa&&(null===b?h.useFlashBlock||0===h.flashLoadTimeout?h.useFlashBlock&&_():!h.useFlashBlock&&na?H():D({type:"ontimeout",ignoreInit:!0,error:{type:"INIT_FLASHBLOCK"}}):0!==h.flashLoadTimeout&&(!h.useFlashBlock&&na?H():W(!0))))},h.flashLoadTimeout)))},J=function(){return Oa||!Pa?(wa.remove(a,"focus",J),!0):(Oa=Qa=!0,ea=!1,F(),wa.remove(a,"focus",J),!0)},y=function(b){if(v)return!1;if(h.html5Only)return v=!0,E(),!0;var d,c=!0;return h.useFlashBlock&&h.flashLoadTimeout&&!h.getMoviePercent()||(v=!0),d={type:!Aa&&oa?"NO_FLASH":"INIT_TIMEOUT"},(w||b)&&(h.useFlashBlock&&h.oMC&&(h.oMC.className=aa()+" "+(null===h.getMoviePercent()?"swf_timedout":"swf_error")),D({type:"ontimeout",error:d,ignoreInit:!0}),S(d),c=!1),w||(h.waitForWindowLoad&&!x?wa.add(a,"load",E):E()),c},p=function(){var a,c=h.setupOptions;for(a in c)c.hasOwnProperty(a)&&(h[a]===b?h[a]=c[a]:h[a]!==c[a]&&(h.setupOptions[a]=h[a]))},q=function(){if(v)return!1;if(h.html5Only)return v||(wa.remove(a,"load",h.beginDelayedInit),h.enabled=!0,y()),!0;L();try{j._externalInterfaceTest(!1),T(!0,h.flashPollingInterval||(h.useHighPerformance?10:50)),h.debugMode||j._disableDebug(),h.enabled=!0,h.html5Only||wa.add(a,"unload",o)}catch(a){return S({type:"JS_TO_FLASH_EXCEPTION",fatal:!0}),W(!0),y(),!1}return y(),wa.remove(a,"load",h.beginDelayedInit),!0},N=function(){return!P&&(P=!0,p(),U(),!Aa&&h.hasHTML5&&h.setup({useHTML5Audio:!0,preferFlash:!1}),va(),!Aa&&oa&&(ma.push(K.needFlash),h.setup({flashLoadTimeout:1})),n.removeEventListener&&n.removeEventListener("DOMContentLoaded",N,!1),L(),!0)},ua=function(){return"complete"===n.readyState&&(N(),n.detachEvent("onreadystatechange",ua)),!0},O=function(){x=!0,N(),wa.remove(a,"load",O)},M=function(){Ma&&(h.setupOptions.useHTML5Audio=!0,h.setupOptions.preferFlash=!1,Ga||Ha&&!l.match(/androids2.3/i))&&(Ga&&(h.ignoreFlash=!0),ya=!0)},M(),Ba(),wa.add(a,"focus",J),wa.add(a,"load",F),wa.add(a,"load",O),n.addEventListener?n.addEventListener("DOMContentLoaded",N,!1):n.attachEvent?n.attachEvent("onreadystatechange",ua):S({type:"NO_DOM2_EVENTS",fatal:!0})}if(!a||!a.document)throw Error("SoundManager requires a browser with window and document objects.");var d=null;void 0!==a.SM2_DEFER&&SM2_DEFER||(d=new c),"object"==typeof module&&module&&"object"==typeof module.exports?(a.soundManager=d,module.exports.SoundManager=c,module.exports.soundManager=d):"function"==typeof define&&define.amd?define("SoundManager",[],function(){return{SoundManager:c,soundManager:d}}):(a.SoundManager=c,a.soundManager=d)}(window),function(a,b,c){var d,e,f,g,h;g={paneClass:"pane",sliderClass:"slider",contentClass:"content",iOSNativeScrolling:!1,preventPageScrolling:!1,disableResize:!1,alwaysVisible:!1,flashDelay:1500,sliderMinHeight:20,sliderMaxHeight:null},d="Microsoft Internet Explorer"===b.navigator.appName&&/msie 7./i.test(b.navigator.appVersion)&&b.ActiveXObject,e=null,h=function(){var a,b;return a=c.createElement("div"),b=a.style,b.position="absolute",b.width="100px",b.height="100px",b.overflow="scroll",b.top="-9999px",c.body.appendChild(a),b=a.offsetWidth-a.clientWidth,c.body.removeChild(a),b},f=function(){function f(d,f){this.el=d,this.options=f,e||(e=h()),this.$el=a(this.el),this.doc=a(c),this.win=a(b),this.generate(),this.createEvents(),this.addEvents(),this.reset()}return f.prototype.preventScrolling=function(a,b){this.isActive&&("DOMMouseScroll"===a.type?("down"===b&&0<a.originalEvent.detail||"up"===b&&0>a.originalEvent.detail)&&a.preventDefault():"mousewheel"===a.type&&a.originalEvent&&a.originalEvent.wheelDelta&&("down"===b&&0>a.originalEvent.wheelDelta||"up"===b&&0<a.originalEvent.wheelDelta)&&a.preventDefault())},f.prototype.updateScrollValues=function(){var a;a=this.content[0],this.maxScrollTop=a.scrollHeight-a.clientHeight,this.contentScrollTop=a.scrollTop,this.maxSliderTop=this.paneHeight-this.sliderHeight,this.sliderTop=this.contentScrollTop*this.maxSliderTop/this.maxScrollTop},f.prototype.createEvents=function(){var a=this;this.events={down:function(b){return a.isBeingDragged=!0,a.offsetY=b.pageY-a.slider.offset().top,a.pane.addClass("active"),a.doc.bind("mousemove",a.events.drag).bind("mouseup",a.events.up),!1},drag:function(b){return a.sliderY=b.pageY-a.$el.offset().top-a.offsetY,a.scroll(),a.updateScrollValues(),a.contentScrollTop>=a.maxScrollTop?a.$el.trigger("scrollend"):0===a.contentScrollTop&&a.$el.trigger("scrolltop"),!1},up:function(){return a.isBeingDragged=!1,a.pane.removeClass("active"),a.doc.unbind("mousemove",a.events.drag).unbind("mouseup",a.events.up),!1},resize:function(){a.reset()},panedown:function(b){return a.sliderY=(b.offsetY||b.originalEvent.layerY)-.5*a.sliderHeight,a.scroll(),a.events.down(b),!1},scroll:function(b){a.isBeingDragged||(a.updateScrollValues(),a.sliderY=a.sliderTop,a.slider.css({top:a.sliderTop}),null!=b&&(a.contentScrollTop>=a.maxScrollTop?(a.options.preventPageScrolling&&a.preventScrolling(b,"down"),a.$el.trigger("scrollend")):0===a.contentScrollTop&&(a.options.preventPageScrolling&&a.preventScrolling(b,"up"),a.$el.trigger("scrolltop"))))},wheel:function(b){if(null!=b)return a.sliderY+=-b.wheelDeltaY||-b.delta,a.scroll(),!1}}},f.prototype.addEvents=function(){var a;this.removeEvents(),a=this.events,this.options.disableResize||this.win.bind("resize",a.resize),this.slider.bind("mousedown",a.down),this.pane.bind("mousedown",a.panedown).bind("mousewheel DOMMouseScroll",a.wheel),this.content.bind("scroll mousewheel DOMMouseScroll touchmove",a.scroll)},f.prototype.removeEvents=function(){var a;a=this.events,this.win.unbind("resize",a.resize),this.slider.unbind(),this.pane.unbind(),this.content.unbind("scroll mousewheel DOMMouseScroll touchmove",a.scroll).unbind("keydown",a.keydown).unbind("keyup",a.keyup)},f.prototype.generate=function(){var a,b,c,d,f;return c=this.options,d=c.paneClass,f=c.sliderClass,a=c.contentClass,!this.$el.find(""+d).length&&!this.$el.find(""+f).length&&this.$el.append('<div class="'+d+'"><div class="'+f+'" /></div>'),this.content=this.$el.children("."+a),this.content.attr("tabindex",0),this.slider=this.$el.find("."+f),this.pane=this.$el.find("."+d),e&&(b={right:-e},this.$el.addClass("has-scrollbar")),c.iOSNativeScrolling&&(null==b&&(b={}),b.WebkitOverflowScrolling="touch"),null!=b&&this.content.css(b),c.alwaysVisible&&this.pane.css({opacity:1,visibility:"visible"}),this},f.prototype.restore=function(){return this.stopped=!1,this.pane.show(),this.addEvents()},f.prototype.reset=function(){var a,b,c,f,g,h,i;return this.$el.find("."+this.options.paneClass).length||this.generate().stop(),this.stopped&&this.restore(),a=this.content[0],c=a.style,f=c.overflowY,d&&this.content.css({height:this.content.height()}),b=a.scrollHeight+e,h=this.pane.outerHeight(),i=parseInt(this.pane.css("top"),10),g=parseInt(this.pane.css("bottom"),10),g=h+i+g,i=Math.round(g/b*g),i<this.options.sliderMinHeight?i=this.options.sliderMinHeight:null!=this.options.sliderMaxHeight&&i>this.options.sliderMaxHeight&&(i=this.options.sliderMaxHeight),"scroll"===f&&"scroll"!==c.overflowX&&(i+=e),this.maxSliderTop=g-i,this.contentHeight=b,this.paneHeight=h,this.paneOuterHeight=g,this.sliderHeight=i,this.slider.height(i),this.events.scroll(),this.pane.show(),this.isActive=!0,this.pane.outerHeight(!0)>=a.scrollHeight&&"scroll"!==f?(this.pane.hide(),this.isActive=!1):this.el.clientHeight===a.scrollHeight&&"scroll"===f?this.slider.hide():this.slider.show(),this},f.prototype.scroll=function(){return this.sliderY=Math.max(0,this.sliderY),this.sliderY=Math.min(this.maxSliderTop,this.sliderY),this.content.scrollTop(-1*((this.paneHeight-this.contentHeight+e)*this.sliderY/this.maxSliderTop)),this.slider.css({top:this.sliderY}),this},f.prototype.scrollBottom=function(a){return this.reset(),this.content.scrollTop(this.contentHeight-this.content.height()-a).trigger("mousewheel"),this},f.prototype.scrollTop=function(a){return this.reset(),this.content.scrollTop(+a).trigger("mousewheel"),this},f.prototype.scrollTo=function(b){return this.reset(),b=a(b).offset().top,b>this.maxSliderTop&&(b/=this.contentHeight,this.sliderY=b*=this.maxSliderTop,this.scroll()),this},f.prototype.stop=function(){return this.stopped=!0,this.removeEvents(),this.pane.hide(),this},f.prototype.flash=function(){var a=this;return this.pane.addClass("flashed"),setTimeout(function(){a.pane.removeClass("flashed")},this.options.flashDelay),this},f}(),a.fn.nanoScroller=function(b){return this.each(function(){var c;if((c=this.nanoscroller)||(c=a.extend({},g),b&&"object"==typeof b&&(c=a.extend(c,b)),this.nanoscroller=c=new f(this,c)),b&&"object"==typeof b){if(a.extend(c.options,b),b.scrollBottom)return c.scrollBottom(b.scrollBottom);if(b.scrollTop)return c.scrollTop(b.scrollTop);if(b.scrollTo)return c.scrollTo(b.scrollTo);if("bottom"===b.scroll)return c.scrollBottom(0);if("top"===b.scroll)return c.scrollTop(0);if(b.scroll&&b.scroll instanceof a)return c.scrollTo(b.scroll);if(b.stop)return c.stop();if(b.flash)return c.flash()}return c.reset()})}}(jQuery,window,document),jQuery.fn.extend({everyTime:function(a,b,c,d,e){return this.each(function(){jQuery.timer.add(this,a,b,c,d,e)})},oneTime:function(a,b,c){return this.each(function(){jQuery.timer.add(this,a,b,c,1)})},stopTime:function(a,b){return this.each(function(){jQuery.timer.remove(this,a,b)})}}),jQuery.extend({timer:{guid:1,global:{},regex:/^([0-9]+)s*(.*s)?$/,powers:{ms:1,cs:10,ds:100,s:1e3,das:1e4,hs:1e5,ks:1e6},timeParse:function(a){if(void 0==a||null==a)return null;var b=this.regex.exec(jQuery.trim(a.toString()));if(b[2]){var c=parseInt(b[1],10),d=this.powers[b[2]]||1;return c*d}return a},add:function(a,b,c,d,e,f){var g=0;if(jQuery.isFunction(c)&&(e||(e=d),d=c,c=b),b=jQuery.timer.timeParse(b),!("number"!=typeof b||isNaN(b)||b<=0)){e&&e.constructor!=Number&&(f=!!e,e=0),e=e||0,f=f||!1,a.$timers||(a.$timers={}),a.$timers[c]||(a.$timers[c]={}),d.$timerID=d.$timerID||this.guid++;var h=function(){f&&this.inProgress||(this.inProgress=!0,(++g>e&&0!==e||d.call(a,g)===!1)&&jQuery.timer.remove(a,c,d),this.inProgress=!1)};h.$timerID=d.$timerID,a.$timers[c][d.$timerID]||(a.$timers[c][d.$timerID]=window.setInterval(h,b)),this.global[c]||(this.global[c]=[]),this.global[c].push(a)}},remove:function(a,b,c){var e,d=a.$timers;if(d){if(b){if(d[b]){if(c)c.$timerID&&(window.clearInterval(d[b][c.$timerID]),delete d[b][c.$timerID]);else for(var c in d[b])window.clearInterval(d[b][c]),delete d[b][c];for(e in d[b])break;e||(e=null,delete d[b])}}else for(b in d)this.remove(a,b,c);for(e in d)break;e||(a.$timers=null)}}}}),jQuery.browser.msie&&jQuery(window).one("unload",function(){var a=jQuery.timer.global;for(var b in a)for(var c=a[b],d=c.length;--d;)jQuery.timer.remove(c[d],b)}),function(a,b,c){function d(c,d,e){var f=b.createElement(c);return d&&(f.id=r+d),e&&(f.style.cssText=e),a(f)}function e(a){var b=K.length,c=(aa+a)%b;return c<0?b+c:c}function f(a,b){return Math.round((/%/.test(a)?("x"===b?h():i())/100:1)*parseInt(a,10))}function g(a){return W.photo||/.(gif|png|jp(e|g|eg)|bmp|ico)((#|?).*)?$/i.test(a)}function h(){return c.innerWidth||L.width()}function i(){return c.innerHeight||L.height()}function j(){var b,c=a.data(_,q);null==c?(W=a.extend({},p),console&&console.log&&console.log("Error: cboxElement missing settings object")):W=a.extend({},c);for(b in W)a.isFunction(W[b])&&"on"!==b.slice(0,2)&&(W[b]=W[b].call(_));W.rel=W.rel||_.rel||"nofollow",W.href=W.href||a(_).attr("href"),W.title=W.title||_.title,"string"==typeof W.href&&(W.href=a.trim(W.href))}function k(b,c){a.event.trigger(b),c&&c.call(_)}function l(){var a,d,e,b=r+"Slideshow_",c="click."+r;W.slideshow&&K[1]?(d=function(){R.text(W.slideshowStop).unbind(c).bind(v,function(){(W.loop||K[aa+1])&&(a=setTimeout(ga.next,W.slideshowSpeed))}).bind(u,function(){clearTimeout(a)}).one(c+" "+w,e),D.removeClass(b+"off").addClass(b+"on"),a=setTimeout(ga.next,W.slideshowSpeed)},e=function(){clearTimeout(a),R.text(W.slideshowStart).unbind([v,u,w,c].join(" ")).one(c,function(){ga.next(),d()}),D.removeClass(b+"on").addClass(b+"off")},W.slideshowAuto?d():e()):D.removeClass(b+"off "+b+"on")}function m(b){ea||(_=b,j(),K=a(_),aa=0,"nofollow"!==W.rel&&(K=a("."+s).filter(function(){var c,b=a.data(this,q);return b&&(c=b.rel||this.rel),c===W.rel}),aa=K.index(_),aa===-1&&(K=K.add(_),aa=K.length-1)),ca||(ca=da=!0,D.show(),W.returnFocus&&a(_).blur().one(x,function(){a(this).focus()}),C.css({opacity:+W.opacity,cursor:W.overlayClose?"pointer":"auto"}).show(),W.w=f(W.initialWidth,"x"),W.h=f(W.initialHeight,"y"),ga.position(),A&&L.bind("resize."+B+" scroll."+B,function(){C.css({width:h(),height:i(),top:L.scrollTop(),left:L.scrollLeft()})}).trigger("resize."+B),k(t,W.onOpen),V.add(P).hide(),U.html(W.close).show()),ga.load(!0))}function n(){!D&&b.body&&(ia=!1,L=a(c),D=d(ha).attr({id:q,class:z?r+(A?"IE6":"IE"):""}).hide(),C=d(ha,"Overlay",A?"position:absolute":"").hide(),O=d(ha,"LoadingOverlay").add(d(ha,"LoadingGraphic")),E=d(ha,"Wrapper"),F=d(ha,"Content").append(M=d(ha,"LoadedContent","width:0; height:0; overflow:hidden"),P=d(ha,"Title"),Q=d(ha,"Current"),S=d(ha,"Next"),T=d(ha,"Previous"),R=d(ha,"Slideshow").bind(t,l),U=d(ha,"Close")),E.append(d(ha).append(d(ha,"TopLeft"),G=d(ha,"TopCenter"),d(ha,"TopRight")),d(ha,!1,"clear:left").append(H=d(ha,"MiddleLeft"),F,I=d(ha,"MiddleRight")),d(ha,!1,"clear:left").append(d(ha,"BottomLeft"),J=d(ha,"BottomCenter"),d(ha,"BottomRight"))).find("div div").css({float:"left"}),N=d(ha,!1,"position:absolute; width:9999px; visibility:hidden; display:none"),V=S.add(T).add(Q).add(R),a(b.body).append(C,D.append(E,N)))}function o(){return!!D&&(ia||(ia=!0,X=G.height()+J.height()+F.outerHeight(!0)-F.height(),Y=H.width()+I.width()+F.outerWidth(!0)-F.width(),Z=M.outerHeight(!0),$=M.outerWidth(!0),D.css({"padding-bottom":X,"padding-right":Y}),S.click(function(){ga.next()}),T.click(function(){ga.prev()}),U.click(function(){ga.close()}),C.click(function(){W.overlayClose&&ga.close()}),a(b).bind("keydown."+r,function(a){var b=a.keyCode;ca&&W.escKey&&27===b&&(a.preventDefault(),ga.close()),ca&&W.arrowKey&&K[1]&&(37===b?(a.preventDefault(),T.click()):39===b&&(a.preventDefault(),S.click()))}),a("."+s,b).live("click",function(a){a.which>1||a.shiftKey||a.altKey||a.metaKey||(a.preventDefault(),m(this))})),!0)}var C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z,$,_,aa,ba,ca,da,ea,fa,ga,ia,p={transition:"elastic",speed:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,inline:!1,html:!1,iframe:!1,fastIframe:!0,photo:!1,href:!1,title:!1,rel:!1,opacity:.9,preloading:!0,current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",open:!1,returnFocus:!0,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0},q="colorbox",r="cbox",s=r+"Element",t=r+"_open",u=r+"_load",v=r+"_complete",w=r+"_cleanup",x=r+"_closed",y=r+"_purge",z=!a.support.opacity&&!a.support.style,A=z&&!c.XMLHttpRequest,B=r+"_IE6",ha="div";a.colorbox||(a(n),ga=a.fn[q]=a[q]=function(b,c){var d=this;if(b=b||{},n(),o()){if(!d[0]){if(d.selector)return d;d=a("<a/>"),b.open=!0}c&&(b.onComplete=c),d.each(function(){a.data(this,q,a.extend({},a.data(this,q)||p,b))}).addClass(s),(a.isFunction(b.open)&&b.open.call(d)||b.open)&&m(d[0])}return d},ga.position=function(a,b){function c(a){G[0].style.width=J[0].style.width=F[0].style.width=a.style.width,F[0].style.height=H[0].style.height=I[0].style.height=a.style.height}var d,k,l,e=0,g=0,j=D.offset();L.unbind("resize."+r),D.css({top:-9e4,left:-9e4}),k=L.scrollTop(),l=L.scrollLeft(),W.fixed&&!A?(j.top-=k,j.left-=l,D.css({position:"fixed"})):(e=k,g=l,D.css({position:"absolute"})),g+=W.right!==!1?Math.max(h()-W.w-$-Y-f(W.right,"x"),0):W.left!==!1?f(W.left,"x"):Math.round(Math.max(h()-W.w-$-Y,0)/2),e+=W.bottom!==!1?Math.max(i()-W.h-Z-X-f(W.bottom,"y"),0):W.top!==!1?f(W.top,"y"):Math.round(Math.max(i()-W.h-Z-X,0)/2),D.css({top:j.top,left:j.left}),a=D.width()===W.w+$&&D.height()===W.h+Z?0:a||0,E[0].style.width=E[0].style.height="9999px",d={width:W.w+$,height:W.h+Z,top:e,left:g},0===a&&D.css(d),D.dequeue().animate(d,{duration:a,complete:function(){c(this),da=!1,E[0].style.width=W.w+$+Y+"px",E[0].style.height=W.h+Z+X+"px",W.reposition&&setTimeout(function(){L.bind("resize."+r,ga.position)},1),b&&b()},step:function(){c(this)}})},ga.resize=function(a){ca&&(a=a||{},a.width&&(W.w=f(a.width,"x")-$-Y),a.innerWidth&&(W.w=f(a.innerWidth,"x")),M.css({width:W.w}),a.height&&(W.h=f(a.height,"y")-Z-X),a.innerHeight&&(W.h=f(a.innerHeight,"y")),!a.innerHeight&&!a.height&&(M.css({height:"auto"}),W.h=M.height()),M.css({height:W.h}),ga.position("none"===W.transition?0:W.speed))},ga.prep=function(b){function c(){return W.w=W.w||M.width(),W.w=W.mw&&W.mw<W.w?W.mw:W.w,W.w}function f(){return W.h=W.h||M.height(),W.h=W.mh&&W.mh<W.h?W.mh:W.h,W.h}if(ca){var h,i="none"===W.transition?0:W.speed;M.remove(),M=d(ha,"LoadedContent").append(b),M.hide().appendTo(N.show()).css({width:c(),overflow:W.scrolling?"auto":"hidden"}).css({height:f()}).prependTo(F),N.hide(),a(ba).css({float:"none"}),A&&a("select").not(D.find("select")).filter(function(){return"hidden"!==this.style.visibility}).css({visibility:"hidden"}).one(w,function(){this.style.visibility="inherit"}),h=function(){function b(){z&&D[0].style.removeAttribute("filter")}var c,f,j,n,o,p,s,h=K.length,l="frameBorder",m="allowTransparency";if(ca){if(n=function(){clearTimeout(fa),O.detach().hide(),k(v,W.onComplete)},z&&ba&&M.fadeIn(100),P.html(W.title).add(M).show(),h>1){if("string"==typeof W.current&&Q.html(W.current.replace("{current}",aa+1).replace("{total}",h)).show(),S[W.loop||aa<h-1?"show":"hide"]().html(W.next),T[W.loop||aa?"show":"hide"]().html(W.previous),W.slideshow&&R.show(),W.preloading)for(c=[e(-1),e(1)];f=K[c.pop()];)s=a.data(f,q),s&&s.href?(o=s.href,a.isFunction(o)&&(o=o.call(f))):o=f.href,g(o)&&(p=new Image,p.src=o)}else V.hide();W.iframe?(j=d("iframe")[0],l in j&&(j[l]=0),m in j&&(j[m]="true"),j.name=r+ +new Date,W.fastIframe?n():a(j).one("load",n),j.src=W.href,W.scrolling||(j.scrolling="no"),a(j).addClass(r+"Iframe").appendTo(M).one(y,function(){j.src="//about:blank"})):n(),"fade"===W.transition?D.fadeTo(i,1,b):b()}},"fade"===W.transition?D.fadeTo(i,0,function(){ga.position(0,h)}):ga.position(i,h)}},ga.load=function(b){var c,e,h=ga.prep;da=!0,ba=!1,_=K[aa],b||j(),k(y),k(u,W.onLoad),W.h=W.height?f(W.height,"y")-Z-X:W.innerHeight&&f(W.innerHeight,"y"),W.w=W.width?f(W.width,"x")-$-Y:W.innerWidth&&f(W.innerWidth,"x"),W.mw=W.w,W.mh=W.h,W.maxWidth&&(W.mw=f(W.maxWidth,"x")-$-Y,W.mw=W.w&&W.w<W.mw?W.w:W.mw),W.maxHeight&&(W.mh=f(W.maxHeight,"y")-Z-X,W.mh=W.h&&W.h<W.mh?W.h:W.mh),c=W.href,fa=setTimeout(function(){O.show().appendTo(F)},100),W.inline?(d(ha).hide().insertBefore(a(c)[0]).one(y,function(){a(this).replaceWith(M.children())}),h(a(c))):W.iframe?h(" "):W.html?h(W.html):g(c)?(a(ba=new Image).addClass(r+"Photo").error(function(){W.title=!1,h(d(ha,"Error").html(W.imgError))}).load(function(){var a;ba.onload=null,W.scalePhotos&&(e=function(){ba.height-=ba.height*a,ba.width-=ba.width*a},W.mw&&ba.width>W.mw&&(a=(ba.width-W.mw)/ba.width,e()),W.mh&&ba.height>W.mh&&(a=(ba.height-W.mh)/ba.height,e())),W.h&&(ba.style.marginTop=Math.max(W.h-ba.height,0)/2+"px"),K[1]&&(W.loop||K[aa+1])&&(ba.style.cursor="pointer",ba.onclick=function(){ga.next()}),z&&(ba.style.msInterpolationMode="bicubic"),setTimeout(function(){h(ba)},1)}),setTimeout(function(){ba.src=c},1)):c&&N.load(c,W.data,function(b,c,e){h("error"===c?d(ha,"Error").html(W.xhrError):a(this).contents())})},ga.next=function(){!da&&K[1]&&(W.loop||K[aa+1])&&(aa=e(1),ga.load())},ga.prev=function(){!da&&K[1]&&(W.loop||aa)&&(aa=e(-1),ga.load())},ga.close=function(){ca&&!ea&&(ea=!0,ca=!1,k(w,W.onCleanup),L.unbind("."+r+" ."+B),C.fadeTo(200,0),D.stop().fadeTo(300,0,function(){D.add(C).css({opacity:1,cursor:"auto"}).hide(),k(y),M.remove(),setTimeout(function(){ea=!1,k(x,W.onClosed)},1)}))},ga.remove=function(){a([]).add(D).add(C).remove(),D=null,a("."+s).removeData(q).removeClass(s).die()},ga.element=function(){return a(_)},ga.settings=p)}(jQuery,document,this),function(){var a={};this.tmpl=function b(c,d){var e=/W/.test(c)?new Function("obj","var p=[],print=function(){p.push.apply(p,arguments);};with(obj){p.push('"+c.replace(/[rtn]/g," ").split("<%").join("t").replace(/((^|%>)[^t]*)'/g,"$1r").replace(/t=(.*?)%>/g,"',$1,'").split("t").join("');").split("%>").join("p.push('").split("r").join("\'")+"');}return p.join('');"):a[c]=a[c]||b(document.getElementById(c).innerHTML);return d?e(d):e}}(),function(a,b){var c=a.jQuery,d=a.document;c(function(){function o(){var a=d.location.protocol+"//"+(d.location.hostname||d.location.host);return d.location.port&&(a+=":"+d.location.port),a+="/"}function p(){var m=a.location.href;relativeUrl=m.replace(l,""),k.addClass("loading"),e.animate({opacity:.7},100),c.ajax({url:m,complete:function(l){var r,s,t,o=c(n(l.responseText)),p=o.find(".document-body:first"),q=p.find(b).filter(":first");if(t=q.find(".document-script"),t.length&&t.detach(),s=q.html()||o.html(),!s)return d.location.href=m,!1;r=g.find(j),r.filter(i).removeClass(h),r=r.has('a[href^="'+relativeUrl+'"],a[href^="/'+relativeUrl+'"],a[href^="'+m+'"]'),1===r.length&&r.addClass(h),e.stop(!0,!0),e.html(s).ajaxify().css("opacity",100).show(),d.title=o.find(".document-title:first").text();try{d.getElementsByTagName("title")[0].innerHTML=d.title.replace("<","<").replace(">",">").replace(" & "," & ")}catch(a){}t.each(function(){var a=c(this),b=a.text(),e=d.createElement("script");e.appendChild(d.createTextNode(b)),f.appendChild(e)}),k.removeClass("loading"),iplayer.history(),"undefined"!=typeof a.pageTracker&&a.pageTracker._trackPageview(relativeUrl)}})}var b="#xx1,#content,article:first,.article:first,.post:first",e=c(b).filter(":first"),f=e.get(0),g=c("#menu,#nav,nav:first,.nav:first").filter(":first"),h="active selected current youarehere",i=".active,.selected,.current,.youarehere",j="> li,> ul > li",k=c(d.body),l=o();0===e.length&&(e=k),c.expr[":"].internal=function(a,b,d,e){var h,f=c(a),g=f.attr("href")||"";return h=g.substring(0,l.length)===l||g.indexOf(":")===-1};var n=function(a){var b=String(a).replace(/<!DOCTYPE[^>]*>/i,"").replace(/<(html|head|body|title|meta|script)([s>])/gi,'<div class="document-$1"$2').replace(/</(html|head|body|title|meta|script)>/gi,"</div>");return b};c.fn.ajaxify=function(){var b=c(this);return b.find("a:internal:not(.no-ajaxy)").click(function(b){var e=c(this),f=e.attr("href"),g=e.attr("title")||null;return!(2!=b.which&&!b.metaKey)||(a.custom_ref=d.location.href,_gaq.push(["_trackPageview",a.location.pathname+a.location.search]),history.pushState(null,g,f),p(),b.preventDefault(),!1)}),b},k.ajaxify(),c(a).bind("popstate",function(){p()})})}(window),$(function(){var a=document.location.hostname.toLowerCase(),b="skachat-mp3.download";if(""!==a&&a!=b){}});var SM=soundManager,player=null;jQuery(document).ready(function(){player=new Player,player.init()});var downloadLinkClick123=function(a){a.stopPropagation();var b=$(this).attr("href"),c=$(this).data("id"),d=$(this).data("artist"),e=$(this).data("title");if("undefined"==typeof f)var f=iframeDataURITest();$.ajax({type:"POST",async:!1,contentType:"application/x-www-form-urlencoded",dataType:"json",url:"/public/api.download.php",data:{song_id:c,song_mp3:b,song_artist:d,song_name:e,data_uri_not_supported:f?"false":"true"},success:function(b){0==b.download&&(a.preventDefault(),$("body").prepend(b.code))}}),a.stopPropagation()};$(".onesongblock-download").live("click",downloadLinkClick123),jQuery(document).ready(function(){iplayer=new iPlayer,iplayer.init()}),jQuery(document).ready(function(a){function i(){VK.init({apiId:b}),j()}function j(){VK.Auth.getLoginStatus(function(a){"connected"===a.status&&(c=!0,d=a.session.mid)})}function k(){n(),VK.Auth.login(function(a){j(),c?l():n(f.not_installed,"error")},VK.access.AUDIO)}function l(){var b=a(e.start),c=a(e.connect),g=a(e.list),h=a(e.list_div);b.addClass("hidden"),c.addClass("hidden"),n(f.loading),VK.api("audio.get",{uid:d},function(b){n(),b.response.length>0?(h.html(""),a(b.response).each(function(a){h.append('<li class="track" data-index="'+a+'" data-id="'+b.response[a].aid+'" data-mp3="'+b.response[a].url+'" data-duration="'+b.response[a].duration*1000+'" data-lyrics-id="'+b.response[a].lyrics_id+'"><ul class="playlist-btns"><li><a href="javascript:void(0);" class="no-ajaxy player-playback playlist-play" title="воспроизвести">(воспроизвести)</a></li><li><a target="_blank" href="'+b.response[a].url+'" class="playlist-down" title="скачать" download="'+b.response[a].artist+' - '+b.response[a].title+'">(скачать)</a></li></ul><div class="playlist-title"><b>'+b.response[a].artist+'</b> - <i>'+b.response[a].title+'</i></div></li>')}),g.removeClass("hidden").addClass("nanoscroller_no"),g.nanoScroller(),o(),m()):n(f.not_found,"error")})}function m(){var p,b=h.interval,c=h.size,d=a(e.progress),i=a(e.close),j=a(e.progress).find("span"),k=a(e.list),l=a(e.list_div).find("span"),m=l.length,o=[],q=0;n(f.begin),d.removeClass("hidden"),window.vk_save_timer=setInterval(function(){l=a(e.list_div).find("span"),o=[],p=l.length,l.filter(":lt("+c+")").each(function(b){}),q=(m-p)/m*100,j.animate({width:q+"%"},200),a.ajax({}),p<c&&(clearInterval(window.vk_save_timer),j.animate({width:"100%"},200,function(){d.addClass("hidden"),k.addClass("hidden"),n(f.success,"success"),i.removeClass("hidden")}))},1e3*b)}function n(b,c){var d=a(e.message);"undefined"!=typeof b?d.html(b).removeClass("hidden"):d.html("").addClass("hidden"),d.removeClass("error success default"),"undefined"!=typeof c?d.addClass(c):d.addClass("default"),o()}function o(){a.colorbox.resize({width:300,height:200}),a.colorbox.close()}var b=5620916,c=!1,d=null,e={caller:"#usbl-vk_export",start:"#vk-start",connect:"#vk-connect",list:"#playlist",list_div:"#playlist ",progress:"#vk-import-progress",message:"#vk-message",close:"#vk-cancel"},f={loading:"Загрузка...",not_found:"Аудиозаписи не найдены",not_installed:"Приложение не установлено. Импорт аудиозаписей отменен",begin:"Идет процесс импорта. Пожалуйста, не закрывайте страницу до завершения процесса!",success:"Импорт успешно завершен. Это окно можно закрыть."},g={api:"https://vk.com/js/api/openapi.js",form:"/public/import.vk.html"},h={interval:99999,size:20};!function(){a(e.caller).live("click",function(b){a.getScript(g.api,function(){i()}),a.colorbox({open:!0,href:g.form,scrolling:!1,width:300,height:200}),b.preventDefault()}),a(e.connect).live("click",function(a){k(),a.preventDefault()}),a(e.close).live("click",function(b){a.colorbox.close(),b.preventDefault()})}()}),$(function(){$("body").on("click","#opcl-usbl",function(){$("body").hasClass("right_side__open")?$("body").removeClass("right_side__open"):($("body").addClass("right_side__open"),$(document).bind("click.eventHideSide",function(a){$(a.target).closest("#usbl").length||$(a.target).closest("#header").length||$(a.target).closest("#fixplayer").length||($("body").removeClass("right_side__open"),$(document).unbind("click.eventHideSide"))}))})});
?>