From 9705d0c8cb5bcb90898a7668b7fad475eca2f2b3 Mon Sep 17 00:00:00 2001 From: Craig Michael Thompson Date: Thu, 6 Jan 2011 21:41:21 +0000 Subject: [PATCH] Moved describedby and labelledby ARIA attributes onto the target instead of the tooltip. Also optimized the code by removing redundant vars --- dist/jquery.qtip.css | 2 +- dist/jquery.qtip.js | 85 ++++++++++++-------------- dist/jquery.qtip.min.js | 125 +++++++++++++++++++-------------------- dist/jquery.qtip.pack.js | 4 +- src/core.js | 83 ++++++++++++-------------- 5 files changed, 140 insertions(+), 159 deletions(-) diff --git a/dist/jquery.qtip.css b/dist/jquery.qtip.css index 05799dfa..f8c5a792 100644 --- a/dist/jquery.qtip.css +++ b/dist/jquery.qtip.css @@ -9,7 +9,7 @@ * http://en.wikipedia.org/wiki/MIT_License * http://en.wikipedia.org/wiki/GNU_General_Public_License * -* Date: Thu Jan 6 02:43:20 2011 +0000 +* Date: Thu Jan 6 04:21:55 2011 +0000 */ /* Fluid class for determining actual width in IE */ diff --git a/dist/jquery.qtip.js b/dist/jquery.qtip.js index 4faf82fb..be84316e 100644 --- a/dist/jquery.qtip.js +++ b/dist/jquery.qtip.js @@ -9,7 +9,7 @@ * http://en.wikipedia.org/wiki/MIT_License * http://en.wikipedia.org/wiki/GNU_General_Public_License * -* Date: Thu Jan 6 02:43:20 2011 +0000 +* Date: Thu Jan 6 04:21:55 2011 +0000 */ "use strict"; // Enable ECMAScript "strict" operation for this function. See more: http://ejohn.org/blog/ecmascript-5-strict-mode-json-and-more/ @@ -119,7 +119,8 @@ function QTip(target, options, id) { // Declare this reference var self = this, - docBody = document.body; + docBody = document.body, + tooltip; // Setup class attributes self.id = id; @@ -185,14 +186,14 @@ function QTip(target, options, id) } function isVisible() { - return self.elements.tooltip.css('left') !== hideOffset; + return tooltip.css('left') !== hideOffset; } function setWidget() { var elems = self.elements, on = options.style.widget; - elems.tooltip.toggleClass(widget, on); + tooltip.toggleClass(widget, on); elems.content.toggleClass(widget+'-content', on); if(elems.titlebar){ @@ -210,7 +211,7 @@ function QTip(target, options, id) if(elems.title) { elems.titlebar.remove(); elems.titlebar = elems.title = elems.button = NULL; - elems.tooltip.removeAttr('aria-labelledby'); + target.removeAttr('aria-labelledby'); self.reposition(); } } @@ -244,7 +245,7 @@ function QTip(target, options, id) .attr('role', 'button') .hover(function(event){ $(this).toggleClass('ui-state-hover', event.type === 'mouseenter'); }) .click(function(event) { - if(!elems.tooltip.hasClass(disabled)) { self.hide(event); } + if(!tooltip.hasClass(disabled)) { self.hide(event); } return FALSE; }) .bind('mousedown keydown mouseup keyup mouseout', function(event) { @@ -277,7 +278,7 @@ function QTip(target, options, id) .insertBefore(elems.content); // Add ARIA attribute - elems.tooltip.attr('aria-labelledby', id); + target.attr('aria-labelledby', id); // Create button if enabled if(options.content.title.button) { createButton(); } @@ -347,7 +348,7 @@ function QTip(target, options, id) } // Insert into 'fx' queue our image dimension checker which will halt the showing of the tooltip until image dimensions can be detected - elements.tooltip.queue('fx', function(next) { + tooltip.queue('fx', function(next) { // Find all content images without dimensions var images = $('img:not([height]):not([width])', self.elements.content); @@ -396,14 +397,13 @@ function QTip(target, options, id) return self; } - function assignEvents(show, hide, tooltip, doc) + function assignEvents(show, hide, tip, doc) { var namespace = '.qtip-'+id, posOptions = options.position, targets = { show: options.show.target, hide: options.hide.target, - tooltip: self.elements.tooltip, container: posOptions.container[0] === docBody ? document : posOptions.container }, events = { show: String(options.show.event).split(' '), hide: String(options.hide.event).split(' ') }, @@ -412,7 +412,7 @@ function QTip(target, options, id) // Define show event method function showMethod(event) { - if(targets.tooltip.hasClass(disabled)) { return FALSE; } + if(tooltip.hasClass(disabled)) { return FALSE; } // If set, hide tooltip when inactive for delay period targets.show.trigger('qtip-'+id+'-inactive'); @@ -432,7 +432,7 @@ function QTip(target, options, id) // Define hide method function hideMethod(event) { - if(targets.tooltip.hasClass(disabled)) { return FALSE; } + if(tooltip.hasClass(disabled)) { return FALSE; } // Check if new target was actually the tooltip element var ontoTooltip = $(event.relatedTarget || event.target).parents(selector)[0] === targets.tooltip[0], @@ -452,7 +452,7 @@ function QTip(target, options, id) } // If tooltip has displayed, start hide timer - targets.tooltip.stop(1, 1); + tooltip.stop(1, 1); if(options.hide.delay > 0) { self.timers.hide = setTimeout(function(){ self.hide(event); }, options.hide.delay); @@ -463,7 +463,7 @@ function QTip(target, options, id) // Define inactive method function inactiveMethod(event) { - if(targets.tooltip.hasClass(disabled)) { return FALSE; } + if(tooltip.hasClass(disabled)) { return FALSE; } // Clear timer clearTimeout(self.timers.inactive); @@ -480,22 +480,22 @@ function QTip(target, options, id) } // Assign tooltip events - if(tooltip) { + if(tip) { // Enable hide.fixed if(options.hide.fixed) { // Add tooltip as a hide target targets.hide = targets.hide.add(targets.tooltip); // Clear hide timer on tooltip hover to prevent it from closing - targets.tooltip.bind('mouseover'+namespace, function() { - if(!targets.tooltip.hasClass(disabled)) { + tooltip.bind('mouseover'+namespace, function() { + if(!tooltip.hasClass(disabled)) { clearTimeout(self.timers.hide); } }); } // Focus/blur the tooltip - targets.tooltip.bind('mouseenter'+namespace+' mouseleave'+namespace, function(event) { + tooltip.bind('mouseenter'+namespace+' mouseleave'+namespace, function(event) { self[ event.type === 'mouseenter' ? 'focus' : 'blur' ](event); }); } @@ -551,15 +551,13 @@ function QTip(target, options, id) } // Adjust tooltip position on scroll if screen adjustment is enabled - if(posOptions.viewport || (IE6 && targets.tooltip.css('position') === 'fixed')) { + if(posOptions.viewport || (IE6 && tooltip.css('position') === 'fixed')) { $(posOptions.viewport).bind('scroll'+namespace, repositionMethod); } // Hide tooltip on document mousedown if unfocus events are enabled if((/unfocus/i).test(options.hide.event)) { $(document).bind('mousedown'+namespace, function(event) { - var tooltip = self.elements.tooltip; - if($(event.target).parents(selector).length === 0 && $(event.target).add(target).length > 1 && isVisible() && !tooltip.hasClass(disabled)) { self.hide(event); @@ -571,7 +569,7 @@ function QTip(target, options, id) if(posOptions.target === 'mouse') { $(document).bind('mousemove'+namespace, function(event) { // Update the tooltip position only if the tooltip is visible and adjustment is enabled - if(posOptions.adjust.mouse && !targets.tooltip.hasClass(disabled) && isVisible()) { + if(posOptions.adjust.mouse && !tooltip.hasClass(disabled) && isVisible()) { self.reposition(event || $.fn.qtip.mouse); } }); @@ -619,13 +617,15 @@ function QTip(target, options, id) var elements = self.elements, callback = $.Event('tooltiprender'); + // Add ARIA properties to target + target.attr('aria-describedby', uitooltip + '-' + id + '-content'); + // Create tooltip element - elements.tooltip = $('
') + tooltip = elements.tooltip = $('
') .attr({ 'id': uitooltip + '-'+id, 'role': 'alert', // Apparently "tooltip" doesn't work too well... so we'll use alert 'class': uitooltip + ' qtip ui-helper-reset ' + options.style.classes, - 'aria-describedby': uitooltip + '-' + self.id + '-content', 'tabindex': -1 }) .toggleClass(disabled, self.cache.disabled) @@ -656,7 +656,7 @@ function QTip(target, options, id) $.each(options.events, function(name, callback) { if(callback) { var events = name === 'toggle' ? 'tooltipshow tooltiphide' : 'tooltip'+name; - elements.tooltip.bind(events, callback); + tooltip.bind(events, callback); } }); @@ -665,14 +665,14 @@ function QTip(target, options, id) * * See: updateContent method */ - elements.tooltip.queue('fx', function(next) { + tooltip.queue('fx', function(next) { // Trigger tooltiprender event and pass original triggering event as original callback.originalEvent = self.cache.event; - elements.tooltip.trigger(callback, [self]); + tooltip.trigger(callback, [self]); // Update tooltip position and show tooltip if needed if(options.show.ready || show) { - elements.tooltip.hide(); + tooltip.hide(); self.show(self.cache.event); } @@ -684,8 +684,7 @@ function QTip(target, options, id) get: function(notation) { - var tooltip = self.elements.tooltip, - result, o; + var result, o; switch(notation.toLowerCase()) { @@ -715,7 +714,6 @@ function QTip(target, options, id) notation = notation.toLowerCase(); var option = convertNotation(notation), elems = self.elements, - tooltip = elems.tooltip, previous, category, rule, checks = { @@ -767,7 +765,7 @@ function QTip(target, options, id) // Style checks '^style.classes$': function() { - self.elements.tooltip.attr('class', uitooltip + ' qtip ui-helper-reset ' + value); + tooltip.attr('class', uitooltip + ' qtip ui-helper-reset ' + value); }, '^style.widget|content.title': setWidget, @@ -814,7 +812,6 @@ function QTip(target, options, id) if(self.rendered === FALSE) { return FALSE; } var type = state ? 'show' : 'hide', - tooltip = self.elements.tooltip, opts = options[type], visible = isVisible(), callback; @@ -920,8 +917,7 @@ function QTip(target, options, id) { if(self.rendered === FALSE) { return FALSE; } - var tooltip = self.elements.tooltip, - qtips = $(selector), + var qtips = $(selector), curIndex = parseInt(tooltip[0].style.zIndex, 10), newIndex = $.fn.qtip.zindex + qtips.length, cachedEvent = $.extend({}, event), @@ -963,8 +959,7 @@ function QTip(target, options, id) blur: function(event) { - var tooltip = self.elements.tooltip, - cachedEvent = $.extend({}, event), + var cachedEvent = $.extend({}, event), callback; // Set focused status to FALSE @@ -984,13 +979,12 @@ function QTip(target, options, id) if(self.rendered === FALSE) { return FALSE; } var target = options.position.target, - tooltip = self.elements.tooltip, posOptions = options.position, my = posOptions.my, at = posOptions.at, adjust = posOptions.adjust, - elemWidth = self.elements.tooltip.outerWidth(), - elemHeight = self.elements.tooltip.outerHeight(), + elemWidth = tooltip.outerWidth(), + elemHeight = tooltip.outerHeight(), targetWidth = 0, targetHeight = 0, callback = $.Event('tooltipmove'), @@ -1159,8 +1153,7 @@ function QTip(target, options, id) // Make sure tooltip is rendered and the browser needs the redraw if(!self.rendered || !($.browser.msie && parseInt($.browser.version.charAt(0), 10) < 9)) { return FALSE; } - var tooltip = self.elements.tooltip, - fluid = uitooltip + '-fluid', + var fluid = uitooltip + '-fluid', dimensions; // Reset the height and width and add the fluid class to reset max/min widths @@ -1188,8 +1181,7 @@ function QTip(target, options, id) disable: function(state) { - var tooltip = self.elements.tooltip, - c = disabled; + var c = disabled; if('boolean' !== typeof state) { state = !(tooltip.hasClass(c) || self.cache.disabled); @@ -1207,12 +1199,11 @@ function QTip(target, options, id) destroy: function() { - var elements = self.elements, - oldtitle = elements.target.data('oldtitle'); + var oldtitle = target.data('oldtitle'); // Destroy tooltip and any associated plugins if rendered if(self.rendered) { - elements.tooltip.remove(); + tooltip.remove(); $.each(self.plugins, function() { if(this.initialize === 'render') { this.destroy(); } diff --git a/dist/jquery.qtip.min.js b/dist/jquery.qtip.min.js index 731ddcb6..7769e5e4 100644 --- a/dist/jquery.qtip.min.js +++ b/dist/jquery.qtip.min.js @@ -9,72 +9,71 @@ * http://en.wikipedia.org/wiki/MIT_License * http://en.wikipedia.org/wiki/GNU_General_Public_License * -* Date: Thu Jan 6 02:43:20 2011 +0000 +* Date: Thu Jan 6 04:21:55 2011 +0000 */ "use strict"; // Enable ECMAScript "strict" operation for this function. See more: http://ejohn.org/blog/ecmascript-5-strict-mode-json-and-more/ /*jslint browser: true, onevar: true, undef: true, nomen: true, bitwise: true, regexp: true, newcap: true, immed: true, strict: true */ /*global window: false, jQuery: false */ -(function(d,K,O){function U(f){var a;if(!f)return m;if("object"!==typeof f.metadata)f.metadata={type:f.metadata};if("content"in f){if("object"!==typeof f.content||f.content.jquery)f.content={text:f.content};a=f.content.text||m;if(!d.isFunction(a)&&(!a&&!a.attr||a.length<1||"object"===typeof a&&!a.jquery))a=f.content.text=m;if("title"in f.content&&"object"!==typeof f.content.title)f.content.title={text:f.content.title}}if("position"in f)if("object"!==typeof f.position)f.position={my:f.position,at:f.position}; -if("show"in f)if("object"!==typeof f.show)f.show=f.show.jquery?{target:f.show}:{event:f.show};if("hide"in f)if("object"!==typeof f.hide)f.hide=f.hide.jquery?{target:f.hide}:{event:f.hide};if("style"in f)if("object"!==typeof f.style)f.style={classes:f.style};d.each(d.fn.qtip.plugins,function(){this.sanitize&&this.sanitize(f)});return f}function Y(f,a,p){function h(c){var e,g=c.split("."),l=a[g[0]];for(c=1;c",{"class":"ui-state-default "+(a.style.widget?"":H+"-icon"),title:"Close"}).prepend(d("",{"class":"ui-icon ui-icon-close",html:"×"}));c.button.prependTo(c.titlebar).attr("role","button").hover(function(g){d(this).toggleClass("ui-state-hover", -g.type==="mouseenter")}).click(function(g){c.tooltip.hasClass(M)||b.hide(g);return m}).bind("mousedown keydown mouseup keyup mouseout",function(g){d(this).toggleClass("ui-state-active ui-state-focus",/down$/i.test(g.type))});b.redraw()}function z(){var c=b.elements,e=H+"-"+b.id+"-title";c.titlebar&&s();c.titlebar=d("
",{"class":H+"-titlebar "+(a.style.widget?"ui-widget-header":"")}).append(c.title=d("
",{id:e,"class":H+"-title",html:a.content.title.text})).insertBefore(c.content);c.tooltip.attr("aria-labelledby", -e);if(a.content.title.button)o();else b.rendered===t&&b.redraw()}function D(c){var e=b.elements;if(!b.rendered||!c)return m;if(d.isFunction(c))c=c.call(f);c.jquery&&c.length>0?e.content.empty().append(c.css({display:"block"})):e.content.html(c);e.tooltip.queue("fx",function(g){function l(r){i=i.not(r);if(i.length===0){b.redraw();b.rendered===t&&b.reposition(b.cache.event);g()}}var i=d("img:not([height]):not([width])",b.elements.content);i.each(function(r,q){var E=["abort","error","load","unload", -""].join(".qtip-image ");d(this).bind(E,function(){clearTimeout(b.timers.img[r]);l(this)});(function C(){if(q.height)return l(q);b.timers.img[r]=setTimeout(C,20)})();return t});i.length===0&&l(i)});return b}function G(c,e,g,l){function i(A){if(u.tooltip.hasClass(M))return m;u.show.trigger("qtip-"+p+"-inactive");clearTimeout(b.timers.show);clearTimeout(b.timers.hide);var B=function(){b.show(A)};if(a.show.delay>0)b.timers.show=setTimeout(B,a.show.delay);else B()}function r(A){if(u.tooltip.hasClass(M))return m; -var B=d(A.relatedTarget||A.target).parents(Q)[0]===u.tooltip[0],w=d(A.relatedTarget||A.target)[0]===u.show[0];clearTimeout(b.timers.show);clearTimeout(b.timers.hide);if(a.hide.fixed&&(x.target==="mouse"&&B||/mouse(out|leave|move)/.test(A.type)&&(B||w))){A.stopPropagation();A.preventDefault();return m}u.tooltip.stop(1,1);if(a.hide.delay>0)b.timers.hide=setTimeout(function(){b.hide(A)},a.hide.delay);else b.hide(A)}function q(A){if(u.tooltip.hasClass(M))return m;clearTimeout(b.timers.inactive);b.timers.inactive= -setTimeout(function(){b.hide(A)},a.hide.inactive)}function E(A){if(!b.cache.processing){b.cache.processing=1;j()&&b.reposition(A);b.cache.processing=0}}var C=".qtip-"+p,x=a.position,u={show:a.show.target,hide:a.hide.target,tooltip:b.elements.tooltip,container:x.container[0]===y?document:x.container},I={show:String(a.show.event).split(" "),hide:String(a.hide.event).split(" ")},P=d.browser.msie&&parseInt(d.browser.version,10)===6;if(g){if(a.hide.fixed){u.hide=u.hide.add(u.tooltip);u.tooltip.bind("mouseover"+ -C,function(){u.tooltip.hasClass(M)||clearTimeout(b.timers.hide)})}u.tooltip.bind("mouseenter"+C+" mouseleave"+C,function(A){b[A.type==="mouseenter"?"focus":"blur"](A)})}if(e){if("number"===typeof a.hide.inactive){u.show.bind("qtip-"+p+"-inactive",q);d.each(d.fn.qtip.inactiveEvents,function(A,B){u.hide.add(b.elements.tooltip).bind(B+C+"-inactive",q)})}d.each(I.hide,function(A,B){var w=d.inArray(B,I.show);if(w>-1&&d(u.hide).add(u.show).length===d(u.hide).length||B==="unfocus"){u.show.bind(B+C,function(R){j()? -r(R):i(R)});delete I.show[w]}else u.hide.bind(B+C,r)})}c&&d.each(I.show,function(A,B){u.show.bind(B+C,i)});if(l){if(x.adjust.resize||x.viewport)d(d.event.special.resize?x.viewport:K).bind("resize"+C,E);if(x.viewport||P&&u.tooltip.css("position")==="fixed")d(x.viewport).bind("scroll"+C,E);/unfocus/i.test(a.hide.event)&&d(document).bind("mousedown"+C,function(A){var B=b.elements.tooltip;d(A.target).parents(Q).length===0&&d(A.target).add(f).length>1&&j()&&!B.hasClass(M)&&b.hide(A)});x.target==="mouse"&& -d(document).bind("mousemove"+C,function(A){if(x.adjust.mouse&&!u.tooltip.hasClass(M)&&j())b.reposition(A||d.fn.qtip.mouse)})}}function k(c,e,g,l){l=parseInt(l,10)!==0;var i=".qtip-"+p;e={show:c?a.show.target:F,hide:e?a.hide.target:F,tooltip:g?b.elements.tooltip:F,content:g?b.elements.content:F,container:l?a.position.container[0]===y?document:a.position.container:F,window:l?K:F};if(b.rendered)d([]).pushStack(d.grep([e.show,e.hide,e.tooltip,e.container,e.content,e.window],function(){return this!==null})).unbind(i); -else c&&e.show.unbind(i+"-create")}var b=this,y=document.body;b.id=p;b.rendered=m;b.elements={target:f};b.timers={img:[]};b.options=a;b.plugins={};b.cache={event:{},target:F,disabled:m,lastFocus:y};d.extend(b,{render:function(c){if(b.rendered)return m;var e=b.elements,g=d.Event("tooltiprender");e.tooltip=d("
").attr({id:H+"-"+p,role:"alert","class":H+" qtip ui-helper-reset "+a.style.classes,"aria-describedby":H+"-"+b.id+"-content",tabindex:-1}).toggleClass(M,b.cache.disabled).data("qtip",b).appendTo(a.position.container).append(e.content= -d("
",{"class":H+"-content",id:H+"-"+p+"-content"}));b.rendered=t;a.content.title.text&&z();D(a.content.text);d.each(d.fn.qtip.plugins,function(){this.initialize==="render"&&this(b)});G(1,1,1,1);d.each(a.events,function(l,i){if(i)e.tooltip.bind(l==="toggle"?"tooltipshow tooltiphide":"tooltip"+l,i)});e.tooltip.queue("fx",function(l){g.originalEvent=b.cache.event;e.tooltip.trigger(g,[b]);if(a.show.ready||c){e.tooltip.hide();b.show(b.cache.event)}l()});return b},get:function(c){var e=b.elements.tooltip; -switch(c.toLowerCase()){case "dimensions":c={height:e.outerHeight(),width:e.outerWidth()};break;case "offset":c=n(e[0],a.position.container);break;default:c=h(c.toLowerCase());c=c[0].precedance?c[0].string():c[0].jquery?c[0]:c[0][c[1]];break}return c},set:function(c,e){c=c.toLowerCase();var g=h(c),l=b.elements,i=l.tooltip,r,q,E,C={builtin:{"^id$":function(){var x=e===t?d.fn.qtip.nextid:e,u=H+"-"+x;if(x!==m&&x.length>0&&!d("#"+u).length){i[0].id=u;l.content[0].id=u+"-content";l.title[0].id=u+"-title"}}, -"^content.text$":function(){D(e)},"^content.title.text$":function(){if(b.rendered)if(!b.elements.title&&e){z();b.reposition()}else e?b.elements.title.html(e):s()},"^content.title.button$":function(){var x=b.elements.button,u=b.elements.title;if(b.rendered)if(e){u||z();o()}else x.remove()},"^position.(my|at)$":function(){var x=/my$/i.test(c)?"my":"at";if("string"===typeof e)a.position[x]=new d.fn.qtip.plugins.Corner(e)},"^position.container$":function(){b.rendered===t&&i.appendTo(e)},"^(show|hide).(event|target|fixed|delay|inactive)$":function(x, -u,I,P){var A=c.search(/fixed/i)>-1?[0,[0,1,1,1]]:[c.substr(0,3),c.charAt(0)==="s"?[1,0,0,0]:[0,1,0,0]];if(A[0])x[u]=P;k.apply(b,A[1]);if(A[0])x[u]=I;G.apply(b,A[1])},"^show.ready$":function(){b.rendered===m&&b.show()},"^style.classes$":function(){b.elements.tooltip.attr("class",H+" qtip ui-helper-reset "+e)},"^style.widget|content.title":v,"^events.(render|show|move|hide|focus|blur)$":function(x,u,I){l.tooltip[(d.isFunction(e)?"":"un")+"bind"]("tooltip"+u,I)},"^position.(my|at|adjust|target|container)|style|content":function(){b.reposition()}}}; -d.each(b.plugins,function(x){if("object"===typeof this.checks)C[x]=this.checks});r=g[0][g[1]];g[0][g[1]]=e.nodeType?d(e):e;U(a);for(q in C)for(E in C[q])RegExp(E,"i").test(c)&&C[q][E].call(b,g[0],g[1],e,r);return b},toggle:function(c,e){function g(){if(c)d.browser.msie&&i[0].style.removeAttribute("filter");else i.css({display:"block",visibility:"hidden",width:"",opacity:"",left:V,top:V})}if(b.rendered===m)return m;var l=c?"show":"hide",i=b.elements.tooltip,r=a[l],q=j();if((typeof c).search("boolean|number"))c= -!q;if(!q&&!c||i.is(":animated"))return b;if(e){if(/over|enter/.test(e.type)&&/out|leave/.test(b.cache.event.type)&&e.target===a.show.target[0]&&i.has(e.relatedTarget).length)return b;b.cache.event=d.extend({},e)}q=d.Event("tooltip"+l);q.originalEvent=e?b.cache.event:F;i.trigger(q,[b,90]);if(q.isDefaultPrevented())return b;if(c){i.hide().css({visibility:""});b.focus(e);i[0].focus();b.cache.lastFocus.focus();b.reposition(e,0);r.solo&&d(Q).not(i).qtip("hide")}else{clearTimeout(b.timers.show);b.blur(e)}i.attr("aria-hidden", -Boolean(!c));i.stop(1,1);if(d.isFunction(r.effect)){r.effect.call(i,b);i.queue("fx",function(E){g.call(this,E);E()})}else if(r.effect===m){i[l]();g.call(i)}else i.fadeTo(90,c?1:0,g);c&&r.target.trigger("qtip-"+p+"-inactive");return b},show:function(c){b.toggle(t,c)},hide:function(c){b.toggle(m,c)},focus:function(c){if(b.rendered===m)return m;var e=b.elements.tooltip,g=d(Q),l=parseInt(e[0].style.zIndex,10),i=d.fn.qtip.zindex+g.length;c=d.extend({},c);if(!e.hasClass(T)){if(l!==i){g.each(function(){if(this.style.zIndex> -l)this.style.zIndex-=1});d(Q+"."+T).qtip("blur",c)}b.cache.lastFocus=document.activeElement;g=d.Event("tooltipfocus");g.originalEvent=c;e.trigger(g,[b,i]);if(!g.isDefaultPrevented())e.addClass(T)[0].style.zIndex=i}return b},blur:function(c){var e=b.elements.tooltip;c=d.extend({},c);var g;e.removeClass(T);g=d.Event("tooltipblur");g.originalEvent=c;e.trigger(g,[b]);b.cache.lastFocus.focus()},reposition:function(c,e){if(b.rendered===m)return m;var g=a.position.target,l=b.elements.tooltip,i=a.position, -r=i.my,q=i.at,E=i.adjust,C=b.elements.tooltip.outerWidth(),x=b.elements.tooltip.outerHeight(),u=0,I=0,P=d.Event("tooltipmove"),A=l.css("position")==="fixed",B=i.viewport.jquery?i.viewport:d(K),w={left:0,top:0},R={left:function(L){var J=B.scrollLeft,N=q.x==="left"?u:q.x==="right"?-u:-u/2,S=J-L;J=L+C-B.width-J;N=(r.x==="left"?C:r.x==="right"?-C:-C/2)-(r.precedance==="x"||r.x===r.y?N:0);if(S>0&&(r.x!=="left"||J>0))w.left-=N;else if(J>0&&(r.x!=="right"||S>0))w.left-=(r.x==="center"?-1:1)*N+2*E.x;if(w.left< -0&&-w.left>J)w.left=L;return w.left-L},top:function(L){var J=B.scrollTop,N=q.y==="top"?I:q.y==="bottom"?-I:-I/2,S=J-L;J=L+x-B.height-J;N=(r.y==="top"?x:r.y==="bottom"?-x:-x/2)-(r.precedance==="y"||r.x===r.y?N:0);if(S>0&&(r.y!=="top"||J>0))w.top-=N;else if(J>0&&(r.y!=="bottom"||S>0))w.top-=(r.y==="center"?-1:1)*N+2*E.y;if(w.top<0&&-w.top>J)w.top=L;return w.top-L}};e=e===O||!!e||m;B=!B?m:{elem:B,height:B[(B[0]===K?"h":"outerH")+"eight"](),width:B[(B[0]===K?"w":"outerW")+"idth"](),scrollLeft:B.scrollLeft(), -scrollTop:B.scrollTop()};if(g==="mouse"){q={x:"left",y:"top"};c=c&&(c.type==="resize"||c.type==="scroll")?b.cache.event:E.mouse||!c||!c.pageX?d.extend({},d.fn.qtip.mouse):c;w={top:c.pageY,left:c.pageX}}else{if(g==="event")g=c&&c.target&&c.type!=="scroll"&&c.type!=="resize"?b.cache.target=d(c.target):b.cache.target;g=d(g).eq(0);if(g.length===0)return b;else if(g[0]===document||g[0]===K){u=g.width();I=g.height();if(g[0]===K)w={top:A?0:B.scrollTop,left:A?0:B.scrollLeft}}else if(g.is("area")&&d.fn.qtip.plugins.imagemap){w= -d.fn.qtip.plugins.imagemap(g,q);u=w.width;I=w.height;w=w.offset}else{u=g.outerWidth();I=g.outerHeight();w=n(g[0],i.container[0])}w.left+=q.x==="right"?u:q.x==="center"?u/2:0;w.top+=q.y==="bottom"?I:q.y==="center"?I/2:0}w.left+=E.x+(r.x==="right"?-C:r.x==="center"?-C/2:0);w.top+=E.y+(r.y==="bottom"?-x:r.y==="center"?-x/2:0);w.adjusted=i.viewport.jquery&&g[0]!==K&&g[0]!==y?{left:R.left(w.left),top:R.top(w.top)}:{left:0,top:0};l.attr("class",function(){return d(this).attr("class").replace(/ui-tooltip-pos-\w+/i, -"")}).addClass(H+"-pos-"+r.abbreviation());P.originalEvent=d.extend({},c);l.trigger(P,[b,w,B.elem]);if(P.isDefaultPrevented())return b;delete w.adjusted;if(!e||!isNaN(w.left,w.top))l.css(w);else if(j()&&d.isFunction(i.effect)){i.effect.call(l,b,w);l.queue(function(L){d(this).css({opacity:"",height:""});d.browser.msie&&this.style&&this.style.removeAttribute("filter");L()})}return b},redraw:function(){if(!b.rendered||!(d.browser.msie&&parseInt(d.browser.version.charAt(0),10)<9))return m;var c=b.elements.tooltip, -e=H+"-fluid",g;c.css({width:"auto",height:"auto"}).addClass(e);g={height:c.outerHeight(),width:c.outerWidth()};d.each(["width","height"],function(l,i){var r=parseInt(c.css("max-"+i),10)||0,q=parseInt(c.css("min-"+i),10)||0;g[i]=r+q?Math.min(Math.max(g[i],q),r):g[i]});c.css(g).removeClass(e)},disable:function(c){var e=b.elements.tooltip,g=M;if("boolean"!==typeof c)c=!(e.hasClass(g)||b.cache.disabled);if(b.rendered)e.toggleClass(g,c);else b.cache.disabled=!!c;return b},destroy:function(){var c=b.elements, -e=c.target.data("oldtitle");if(b.rendered){c.tooltip.remove();d.each(b.plugins,function(){this.initialize==="render"&&this.destroy()})}clearTimeout(b.timers.show);clearTimeout(b.timers.hide);k(1,1,1,1);f.removeData("qtip");e&&f.attr("title",e);f.removeAttr("aria-describedby");return f}})}function Z(f,a){var p,h,n=d(this),j=d(document.body),v=this===document?j:n;h=n.metadata?n.metadata(a.metadata):F;var s=d.extend(t,{},d.fn.qtip.defaults,a,U((h&&a.metadata.type==="html5"?h[a.metadata.name]:F)||h)); -n.removeData("metadata");h=s.position;if("boolean"===typeof s.content.text)if(s.content.attr!==m&&n.attr(s.content.attr))s.content.text=n.attr(s.content.attr);else return m;if(h.container===m)h.container=j;if(h.target===m)h.target=v;if(s.show.target===m)s.show.target=v;if(s.hide.target===m)s.hide.target=v;if(s.position.viewport===t)s.position.viewport=h.container;h.at=new d.fn.qtip.plugins.Corner(h.at);h.my=new d.fn.qtip.plugins.Corner(h.my);if(n.data("qtip"))if(s.overwrite)n.qtip("destroy");else if(s.overwrite=== -m)return m;n.attr("title")&&n.data("oldtitle",n.attr("title")).removeAttr("title");p=new Y(n,s,f);n.data("qtip",p);n.bind("remove.qtip",function(){p.destroy()});return p}function $(f){var a=this,p=f.elements.tooltip,h=f.options.content.ajax;a.checks={"^content.ajax":function(n,j){if(j==="once")a.once();else h&&h.url&&a.load()}};d.extend(a,{init:function(){if(h&&h.url){a.load();a.once()}},once:function(){h.once?a.destroy():p.bind("tooltipshow.ajax",function(){a.load()})},load:function(){d.ajax(d.extend({success:function(n){f.set("content.text", -n)},error:function(n,j,v){f.set("content.text",j+": "+v)},context:f},h));return a},destroy:function(){p.unbind(".ajax")}});a.init()}function X(f,a,p){var h=Math.ceil(a/2),n=Math.ceil(p/2);a={bottomright:[[0,0],[a,p],[a,0]],bottomleft:[[0,0],[a,0],[0,p]],topright:[[0,p],[a,0],[a,p]],topleft:[[0,0],[0,p],[a,p]],topcenter:[[0,p],[h,0],[a,p]],bottomcenter:[[0,0],[a,0],[h,p]],rightcenter:[[0,0],[a,n],[0,p]],leftcenter:[[a,0],[a,p],[0,n]]};a.lefttop=a.bottomright;a.righttop=a.bottomleft;a.leftbottom=a.topright; -a.rightbottom=a.topleft;return a[f.string()]}function aa(f){function a(k,b,y){if(j.tip){k=d.extend({},h.corner);b=y.adjusted;var c;if(h.corner.fixed!==t){if(b.left)k.x=k.x==="center"?b.left>0?"left":"right":k.x==="left"?"right":"left";if(b.top)k.y=k.y==="center"?b.top>0?"top":"bottom":k.y==="top"?"bottom":"top";if(k.string()!==s.corner&&(s.top!==b.top||s.left!==b.left))c=h.update(k)}c||(c=h.position(k,0));if(c.right!==O)c.left=c.right;if(c.bottom!==O)c.top=c.bottom;c.option=Math.max(0,n.offset);y.left-= -c.left.charAt?c.option:(c.right?-1:1)*c.left;y.top-=c.top.charAt?c.option:(c.bottom?-1:1)*c.top;s.left=b.left;s.top=b.top;s.corner=k.string()}}function p(k,b,y){b=!b?k[k.precedance]:b;b="border-"+b+"-width";k=parseInt((j.titlebar&&k.y==="top"?j.titlebar:j.content).css(b),10);return(y?k||parseInt(v.css(b),10):k)||0}var h=this,n=f.options.style.tip,j=f.elements,v=j.tooltip,s={top:0,left:0,corner:""},o={width:n.width,height:n.height},z={},D=n.border||0,G=n.method||m;h.corner=F;h.mimic=F;h.checks={"^position.my|style.tip.(corner|mimic|method|border)$":function(){h.init()|| -h.destroy();f.reposition()},"^style.tip.(height|width)$":function(){o={width:n.width,height:n.height};h.create();h.update();f.reposition()},"^content.title.text|style.(classes|widget)$":function(){j.tip&&h.update()}};d.extend(h,{init:function(){var k=h.detectCorner();if(k){if(G!=="polygon")G=d("")[0].getContext?"canvas":d.browser.msie?"vml":"polygon";h.create();h.update();v.unbind(".qtip-tip").bind("tooltipmove.qtip-tip",a)}return k},detectCorner:function(){var k=n.corner,b=f.options.position, -y=b.at;b=b.my.string?b.my.string():b.my;if(k===m||b===m&&y===m)return m;else if(k===t)h.corner=new d.fn.qtip.plugins.Corner(b);else if(!k.string){h.corner=new d.fn.qtip.plugins.Corner(k);h.corner.fixed=t}return h.corner.string()!=="centercenter"},detectColours:function(){var k=j.tip.css({backgroundColor:"",border:""}),b=h.corner,y=b[b.precedance],c="border-"+y+"-color";y="border"+y.charAt(0)+y.substr(1)+"Color";var e=/rgba?\(0, 0, 0(, 0)?\)|transparent/i;b=j.titlebar&&(b.y==="top"||b.y==="center"&& -k.position().top+o.height/2+n.offset",{"class":"ui-tooltip-tip"}).css(o).prependTo(v);switch(G){case "canvas":d('').appendTo(j.tip)[0].getContext("2d").save();break;case "vml":k='';j.tip.html(D?k+=k:k);break;case "polygon":j.tip.append('
').append(D? -'
':"");break}},update:function(k){var b=j.tip.children(),y=o.width,c=o.height,e=n.mimic,g,l,i,r,q;if(!k)k=h.corner;if(e===m)e=k;else{e=new d.fn.qtip.plugins.Corner(e);e.precedance=k.precedance;if(e.x==="inherit")e.x=k.x;else if(e.y==="inherit")e.y=k.y;else if(e.x===e.y)e[k.precedance]=k[k.precedance]}D=n.border===t?p(k,F,t):n.border;g=D>0?0:1;r=e.string().indexOf("center")>-1;q=Math[/b|r/.test(e[e.precedance==="y"?"x":"y"])?"ceil":"floor"];k=h.position(k,1);h.detectColours(); -switch(G){case "canvas":l=b[0].getContext("2d");l.restore&&l.restore();l.clearRect(0,0,3E3,3E3);for(i=X(e,y,c);g<2;g++){if(g){l.save();l.translate(q((e.x==="left"?1:e.x==="right"?-1:0)*(D+1)*(e.precedance==="y"?0.5:1)),q((e.y==="top"?1:e.y==="bottom"?-1:0)*(D+1)*(e.precedance==="x"?0.5:1)))}l.beginPath();l.moveTo(i[0][0],i[0][1]);l.lineTo(i[1][0],i[1][1]);l.lineTo(i[2][0],i[2][1]);l.closePath();l.fillStyle=z[g?"fill":"border"];l.fill()}break;case "vml":i=X(e,y,c);i="m"+i[0][0]+","+i[0][1]+" l"+i[1][0]+ -","+i[1][1]+" "+i[2][0]+","+i[2][1]+" xe";b.each(function(E){d(this).attr({path:i,fillcolor:z[E||!D?"fill":"border"]}).css("antialias",""+r)});break;case "polygon":b.removeAttr("style").css({position:"absolute",left:0,top:0}).each(function(E){var C={x:e.precedance==="x"?e.x==="left"?"right":"left":e.x,y:e.precedance==="y"?e.y==="top"?"bottom":"top":e.y},x=e.x==="center"?["left","right",C.y,c,y]:["top","bottom",C.x,y,c];E=z[!E&&D?"border":"fill"];e.x==="center"||e.y==="center"?d(this).css("border-"+ -x[2],x[3]+"px solid "+E).css("border-"+x[0],q(x[4]/2)+"px dashed transparent").css("border-"+x[1],q(x[4]/2)+"px dashed transparent"):d(this).css("border-width",q(c/2)+"px "+q(y/2)+"px").css("border-"+C.x,q(y/2)+"px solid "+E).css("border-"+C.y,q(c/2)+"px solid "+E)});break}if(G!=="canvas"&&D){g=[D*2.75,D];g=e.precedance==="y"?[e.x==="left"?g[1]:e.x==="right"?-g[1]:0,e.y==="bottom"?-g[0]:g[0]]:[e.x==="left"?g[0]:-g[0],e.y==="bottom"?-g[1]:e.y==="top"?g[1]:0];b.eq(1).css({left:g[0],top:g[1]})}return k}, -position:function(k,b){var y=j.tip,c={},e=Math.max(0,n.offset),g,l;if(n.corner===m||!y)return m;k=k||h.corner;g=k.precedance;l=o[g==="x"?"width":"height"];d.each(g==="y"?[k.x,k.y]:[k.y,k.x],function(i,r){var q;if(r==="center"){q=g==="y"?"left":"top";c[q]="50%";c["margin-"+q]=-Math.floor(l/2)+e}else{q=p(k,r,t);if(i||D===O)q=p(k,r);else{if(q)q=0;else{q=d.browser.mozilla;var E=k.y+(q?"":"-")+k.x;q=(q?"-moz-":d.browser.webkit?"-webkit-":"")+(q?"border-radius-"+E:"border-"+E+"-radius");q=parseInt((j.titlebar&& -k.y==="top"?j.titlebar:j.content).css(q),10)||parseInt(v.css(q),10)||0}q=e+q}c[r]=q}});c[k[g]]-=l;b&&y.css({top:"",bottom:"",left:"",right:"",margin:""}).css(c);return c},destroy:function(){j.tip&&j.tip.remove();v.unbind(".qtip-tip")}});h.init()}function ba(f){var a=this,p=f.options.show.modal,h=f.elements,n=h.tooltip;a.checks={"^show.modal.(on|blur)$":function(){a.init();h.overlay.toggle(n.is(":visible"))}};d.extend(a,{init:function(){if(p.on){n.unbind(".qtipmodal").bind("tooltipshow.qtipmodal tooltiphide.qtipmodal", -function(j,v,s){j=j.type.replace("tooltip","");d.isFunction(p[j])?p[j].call(h.overlay,s,v):a[j](s)});a.create();p.blur===t&&h.overlay.unbind(".qtipmodal"+f.id).bind("click.qtipmodal"+f.id,function(){f.hide.call(f)})}},create:function(){var j=d("#qtip-overlay");if(j.length)h.overlay=j;else{h.overlay=d("
",{id:"#qtip-overlay".substr(1),css:{position:"absolute",top:0,left:0,display:"none",zIndex:parseInt(n.css("z-index"),10)-1}}).appendTo(document.body);d(K).bind("resize.qtipmodal",function(){h.overlay.css({height:Math.max(d(K).height(), -d(document).height()),width:Math.max(d(K).width(),d(document).width())})}).trigger("resize")}},toggle:function(j){var v=h.overlay,s=f.options.show.modal.effect,o=j?"show":"hide";v.stop(t,m);if(d.isFunction(s))s.call(v,j);else s===m?v[o]():v.fadeTo(90,j?0.7:0,function(){j||d(this).hide()})},show:function(){a.toggle(t)},hide:function(){a.toggle(m)},destroy:function(){var j=t;d("*").each(function(){var v=d(this).data("qtip");if(v&&v.id!==f.id&&v.options.show.modal)return j=m});if(j){h.overlay.remove(); -d(K).unbind(".qtipmodal")}else h.overlay.unbind(".qtipmodal"+f.id);n.unbind("tooltipshow.qtipmodal tooltiphide.qtipmodal")}});a.init()}function ca(f){var a=this,p=f.elements,h=p.tooltip,n=".bgiframe-"+f.id,j="tooltipmove"+n+" tooltipshow"+n;d.extend(a,{init:function(){p.bgiframe=d('');p.bgiframe.appendTo(h);h.bind(j,a.adjust)}, -adjust:function(){var v=f.get("dimensions"),s=f.plugins.tip,o=f.elements.tip,z;z=parseInt(h.css("border-left-width"),10)||0;z={left:-z,top:-z};if(s&&o){s=s.corner.precedance==="x"?["width","left"]:["height","top"];z[s[1]]-=o[s[0]]()}p.bgiframe.css(z).css(v)},destroy:function(){a.iframe.remove();h.unbind(j)}});a.init()}var t=true,m=false,F=null,H="ui-tooltip",W="ui-widget",M="ui-state-disabled",Q=".qtip."+H,T=H+"-focus",V="-31000px";d.fn.qtip=function(f,a,p){var h=String(f).toLowerCase(),n=F,j=h=== -"disable"?[t]:d.makeArray(arguments).slice(1,10),v=j[j.length-1],s;if(!arguments.length&&this.data("qtip")||h==="api")return(s=this.data("qtip"))?s:O;else if("string"===typeof f){this.each(function(){var o=d(this).data("qtip");if(!o)return t;if(/option|set/.test(h)&&a)if(p!==O)o.set(a,p);else n=o.get(a);else{if(!o.rendered&&(h==="show"||h==="toggle")){if(v&&v.timeStamp)o.cache.event=v;o.render(1)}else if(h==="enable"){h="disable";j=[m]}o[h]&&o[h].apply(o[h],j)}});return n!==F?n:this}else if("object"=== -typeof f||!arguments.length){s=U(d.extend(t,{},f));return d.fn.qtip.bind.call(this,s,v)}};d.fn.qtip.bind=function(f,a){return this.each(function(){function p(z){function D(){o.render(typeof z==="object"||h.show.ready);n.show.unbind(j.show);n.hide.unbind(j.hide)}if(o.cache.disabled)return m;o.cache.event=d.extend({},z);if(h.show.delay>0){clearTimeout(o.timers.show);o.timers.show=setTimeout(D,h.show.delay);j.show!==j.hide&&n.hide.bind(j.hide,function(){clearTimeout(o.timers.show)})}else D()}var h,n, -j,v=f.id=!f.id||f.id===m||f.id.length<1||d("#"+H+"-"+f.id).length?d.fn.qtip.nextid++:f.id,s=".qtip-"+v+"-create",o=Z.call(this,v,f);if(o===m)return t;h=o.options;d.each(d.fn.qtip.plugins,function(){this.initialize==="initialize"&&this(o)});n={show:h.show.target,hide:h.hide.target};j={show:String(h.show.event).replace(" ",s+" ")+s,hide:String(h.hide.event).replace(" ",s+" ")+s};n.show.bind(j.show,p);if(h.show.ready||h.prerender)p(a)})};d.each({attr:function(f){var a=d(this),p=a.data("qtip");return arguments.length=== -1&&f==="title"&&p&&p.rendered===t?a.data("oldtitle"):F},remove:d.ui?F:function(f,a){d(this).each(function(){if(!a)if(!f||d.filter(f,[this]).length)d("*",this).add(this).each(function(){d(this).triggerHandler("remove")})})}},function(f,a){if(!a)return t;d.fn["Old"+f]=d.fn[f];d.fn[f]=function(){return a.apply(this,arguments)||d.fn["Old"+f].apply(this,arguments)}});d(document).ready(function(){var f=document.body;d(f).attr("role",function(a,p){return!p?"application":p});d(document).bind("mousemove.qtip", -function(a){d.fn.qtip.mouse={pageX:a.pageX,pageY:a.pageY}});document.activeElement===O&&document.addEventListener("focus",function(a){if(a&&a.target)document.activeElement=a.target===document?f:a.target},true)});d.fn.qtip.version="2.0.0pre";d.fn.qtip.nextid=0;d.fn.qtip.inactiveEvents="click dblclick mousedown mouseup mousemove mouseleave mouseenter".split(" ");d.fn.qtip.zindex=15E3;d.fn.qtip.plugins={Corner:function(f){f=String(f).replace(/([A-Z])/," $1").replace(/middle/gi,"center").toLowerCase(); -this.x=(f.match(/left|right/i)||f.match(/center/)||["inherit"])[0].toLowerCase();this.y=(f.match(/top|bottom|center/i)||["inherit"])[0].toLowerCase();this.precedance=f.charAt(0).search(/^(t|b)/)>-1?"y":"x";this.string=function(){return this.precedance==="y"?this.y+this.x:this.x+this.y};this.abbreviation=function(){var a=this.x.substr(0,1),p=this.y.substr(0,1);return a===p?a:a==="c"||a!=="c"&&p!=="c"?p+a:a+p}},iOS:parseFloat((/CPU.+OS ([0-9_]{3}).*AppleWebkit.*Mobile/i.exec(navigator.userAgent)||[0, -"4_2"])[1].replace("_","."))<4.1};d.fn.qtip.defaults={prerender:m,id:m,overwrite:t,metadata:{type:"class"},content:{text:t,attr:"title",title:{text:m,button:m}},position:{my:"top left",at:"bottom right",target:m,container:m,viewport:m,adjust:{x:0,y:0,mouse:t,resize:t},effect:t},show:{target:m,event:"mouseenter",effect:t,delay:90,solo:m,ready:m},hide:{target:m,event:"mouseleave",effect:t,delay:0,fixed:m,inactive:m},style:{classes:"",widget:m},events:{render:F,move:F,show:F,hide:F,toggle:F,focus:F, -blur:F}};d.fn.qtip.plugins.ajax=function(f){var a=f.plugins.ajax;return"object"===typeof a?a:f.plugins.ajax=new $(f)};d.fn.qtip.plugins.ajax.initialize="render";d.fn.qtip.plugins.ajax.sanitize=function(f){var a=f.content;if(a&&"ajax"in a){a=a.ajax;if(typeof a!=="object")a=f.content.ajax={url:a};if("boolean"!==typeof a.once&&a.once)a.once=!!a.once}};d.extend(t,d.fn.qtip.defaults,{content:{ajax:{once:t}}});d.fn.qtip.plugins.tip=function(f){var a=f.plugins.tip;return"object"===typeof a?a:f.plugins.tip= -new aa(f)};d.fn.qtip.plugins.tip.initialize="render";d.fn.qtip.plugins.tip.sanitize=function(f){var a=f.style;if(a&&"tip"in a){a=f.style.tip;if(typeof a!=="object")f.style.tip={corner:a};if(!/string|boolean/i.test(typeof a.corner))a.corner=t;if(typeof a.method!=="string")a.method=t;if(!/canvas|polygon/i.test(a.method))a.method=t;typeof a.width!=="number"&&delete a.width;typeof a.height!=="number"&&delete a.height;typeof a.border!=="number"&&a.border!==t&&delete a.border;typeof a.offset!=="number"&& -delete a.offset}};d.extend(t,d.fn.qtip.defaults,{style:{tip:{corner:t,mimic:m,method:t,width:8,height:8,border:t,offset:0}}});d.fn.qtip.plugins.imagemap=function(f,a){function p(G,k){for(var b=0,y=1,c=1,e=0,g=0,l=G.width,i=G.height;l>0&&i>0&&y>0&&c>0;){l=Math.floor(l/2);i=Math.floor(i/2);if(a.x==="left")y=l;else if(a.x==="right")y=G.width-l;else y+=Math.floor(l/2);if(a.y==="top")c=i;else if(a.y==="bottom")c=G.height-i;else c+=Math.floor(i/2);for(b=k.length;b--;){if(k.length<2)break;e=k[b][0]-G.offset.left; -g=k[b][1]-G.offset.top;if(a.x==="left"&&e>=y||a.x==="right"&&e<=y||a.x==="center"&&(eG.width-y)||a.y==="top"&&g>=c||a.y==="bottom"&&g<=c||a.y==="center"&&(gG.height-c))k.splice(b,1)}}return{left:k[0][0],top:k[0][1]}}var h=f.attr("shape").toLowerCase(),n=f.attr("coords").split(","),j=[],v=d('img[usemap="#'+f.parent("map").attr("name")+'"]'),s=v.offset(),o={width:0,height:0,offset:{top:1E10,right:0,bottom:0,left:1E10}},z=0,D=0;s.left+=Math.ceil((v.outerWidth()-v.width())/2);s.top+=Math.ceil((v.outerHeight()- -v.height())/2);if(h==="poly")for(z=n.length;z--;){D=[parseInt(n[--z],10),parseInt(n[z+1],10)];if(D[0]>o.offset.right)o.offset.right=D[0];if(D[0]o.offset.bottom)o.offset.bottom=D[1];if(D[1]",{"class":"ui-state-default "+(a.style.widget?"":H+"-icon"),title:"Close"}).prepend(c("",{"class":"ui-icon ui-icon-close",html:"×"}));b.button.prependTo(b.titlebar).attr("role","button").hover(function(i){c(this).toggleClass("ui-state-hover", +i.type==="mouseenter")}).click(function(i){g.hasClass(M)||d.hide(i);return m}).bind("mousedown keydown mouseup keyup mouseout",function(i){c(this).toggleClass("ui-state-active ui-state-focus",/down$/i.test(i.type))});d.redraw()}function z(){var b=d.elements,f=H+"-"+d.id+"-title";b.titlebar&&s();b.titlebar=c("
",{"class":H+"-titlebar "+(a.style.widget?"ui-widget-header":"")}).append(b.title=c("
",{id:f,"class":H+"-title",html:a.content.title.text})).insertBefore(b.content);e.attr("aria-labelledby", +f);if(a.content.title.button)r();else d.rendered===u&&d.redraw()}function B(b){var f=d.elements;if(!d.rendered||!b)return m;if(c.isFunction(b))b=b.call(e);b.jquery&&b.length>0?f.content.empty().append(b.css({display:"block"})):f.content.html(b);g.queue("fx",function(i){function l(o){n=n.not(o);if(n.length===0){d.redraw();d.rendered===u&&d.reposition(d.cache.event);i()}}var n=c("img:not([height]):not([width])",d.elements.content);n.each(function(o,C){var F=["abort","error","load","unload",""].join(".qtip-image "); +c(this).bind(F,function(){clearTimeout(d.timers.img[o]);l(this)});(function x(){if(C.height)return l(C);d.timers.img[o]=setTimeout(x,20)})();return u});n.length===0&&l(n)});return d}function G(b,f,i,l){function n(v){if(g.hasClass(M))return m;D.show.trigger("qtip-"+p+"-inactive");clearTimeout(d.timers.show);clearTimeout(d.timers.hide);var t=function(){d.show(v)};if(a.show.delay>0)d.timers.show=setTimeout(t,a.show.delay);else t()}function o(v){if(g.hasClass(M))return m;var t=c(v.relatedTarget||v.target).parents(R)[0]=== +D.tooltip[0],Q=c(v.relatedTarget||v.target)[0]===D.show[0];clearTimeout(d.timers.show);clearTimeout(d.timers.hide);if(a.hide.fixed&&(A.target==="mouse"&&t||/mouse(out|leave|move)/.test(v.type)&&(t||Q))){v.stopPropagation();v.preventDefault();return m}g.stop(1,1);if(a.hide.delay>0)d.timers.hide=setTimeout(function(){d.hide(v)},a.hide.delay);else d.hide(v)}function C(v){if(g.hasClass(M))return m;clearTimeout(d.timers.inactive);d.timers.inactive=setTimeout(function(){d.hide(v)},a.hide.inactive)}function F(v){if(!d.cache.processing){d.cache.processing= +1;j()&&d.reposition(v);d.cache.processing=0}}var x=".qtip-"+p,A=a.position,D={show:a.show.target,hide:a.hide.target,container:A.container[0]===y?document:A.container},L={show:String(a.show.event).split(" "),hide:String(a.hide.event).split(" ")},N=c.browser.msie&&parseInt(c.browser.version,10)===6;if(i){if(a.hide.fixed){D.hide=D.hide.add(D.tooltip);g.bind("mouseover"+x,function(){g.hasClass(M)||clearTimeout(d.timers.hide)})}g.bind("mouseenter"+x+" mouseleave"+x,function(v){d[v.type==="mouseenter"? +"focus":"blur"](v)})}if(f){if("number"===typeof a.hide.inactive){D.show.bind("qtip-"+p+"-inactive",C);c.each(c.fn.qtip.inactiveEvents,function(v,t){D.hide.add(d.elements.tooltip).bind(t+x+"-inactive",C)})}c.each(L.hide,function(v,t){var Q=c.inArray(t,L.show);if(Q>-1&&c(D.hide).add(D.show).length===c(D.hide).length||t==="unfocus"){D.show.bind(t+x,function(I){j()?o(I):n(I)});delete L.show[Q]}else D.hide.bind(t+x,o)})}b&&c.each(L.show,function(v,t){D.show.bind(t+x,n)});if(l){if(A.adjust.resize||A.viewport)c(c.event.special.resize? +A.viewport:K).bind("resize"+x,F);if(A.viewport||N&&g.css("position")==="fixed")c(A.viewport).bind("scroll"+x,F);/unfocus/i.test(a.hide.event)&&c(document).bind("mousedown"+x,function(v){c(v.target).parents(R).length===0&&c(v.target).add(e).length>1&&j()&&!g.hasClass(M)&&d.hide(v)});A.target==="mouse"&&c(document).bind("mousemove"+x,function(v){if(A.adjust.mouse&&!g.hasClass(M)&&j())d.reposition(v||c.fn.qtip.mouse)})}}function k(b,f,i,l){l=parseInt(l,10)!==0;var n=".qtip-"+p;f={show:b?a.show.target: +E,hide:f?a.hide.target:E,tooltip:i?d.elements.tooltip:E,content:i?d.elements.content:E,container:l?a.position.container[0]===y?document:a.position.container:E,window:l?K:E};if(d.rendered)c([]).pushStack(c.grep([f.show,f.hide,f.tooltip,f.container,f.content,f.window],function(){return this!==null})).unbind(n);else b&&f.show.unbind(n+"-create")}var d=this,y=document.body,g;d.id=p;d.rendered=m;d.elements={target:e};d.timers={img:[]};d.options=a;d.plugins={};d.cache={event:{},target:E,disabled:m,lastFocus:y}; +c.extend(d,{render:function(b){if(d.rendered)return m;var f=d.elements,i=c.Event("tooltiprender");e.attr("aria-describedby",H+"-"+p+"-content");g=f.tooltip=c("
").attr({id:H+"-"+p,role:"alert","class":H+" qtip ui-helper-reset "+a.style.classes,tabindex:-1}).toggleClass(M,d.cache.disabled).data("qtip",d).appendTo(a.position.container).append(f.content=c("
",{"class":H+"-content",id:H+"-"+p+"-content"}));d.rendered=u;a.content.title.text&&z();B(a.content.text);c.each(c.fn.qtip.plugins,function(){this.initialize=== +"render"&&this(d)});G(1,1,1,1);c.each(a.events,function(l,n){if(n)g.bind(l==="toggle"?"tooltipshow tooltiphide":"tooltip"+l,n)});g.queue("fx",function(l){i.originalEvent=d.cache.event;g.trigger(i,[d]);if(a.show.ready||b){g.hide();d.show(d.cache.event)}l()});return d},get:function(b){switch(b.toLowerCase()){case "dimensions":b={height:g.outerHeight(),width:g.outerWidth()};break;case "offset":b=q(g[0],a.position.container);break;default:b=h(b.toLowerCase());b=b[0].precedance?b[0].string():b[0].jquery? +b[0]:b[0][b[1]];break}return b},set:function(b,f){b=b.toLowerCase();var i=h(b),l=d.elements,n,o,C,F={builtin:{"^id$":function(){var x=f===u?c.fn.qtip.nextid:f,A=H+"-"+x;if(x!==m&&x.length>0&&!c("#"+A).length){g[0].id=A;l.content[0].id=A+"-content";l.title[0].id=A+"-title"}},"^content.text$":function(){B(f)},"^content.title.text$":function(){if(d.rendered)if(!d.elements.title&&f){z();d.reposition()}else f?d.elements.title.html(f):s()},"^content.title.button$":function(){var x=d.elements.button,A=d.elements.title; +if(d.rendered)if(f){A||z();r()}else x.remove()},"^position.(my|at)$":function(){var x=/my$/i.test(b)?"my":"at";if("string"===typeof f)a.position[x]=new c.fn.qtip.plugins.Corner(f)},"^position.container$":function(){d.rendered===u&&g.appendTo(f)},"^(show|hide).(event|target|fixed|delay|inactive)$":function(x,A,D,L){var N=b.search(/fixed/i)>-1?[0,[0,1,1,1]]:[b.substr(0,3),b.charAt(0)==="s"?[1,0,0,0]:[0,1,0,0]];if(N[0])x[A]=L;k.apply(d,N[1]);if(N[0])x[A]=D;G.apply(d,N[1])},"^show.ready$":function(){d.rendered=== +m&&d.show()},"^style.classes$":function(){g.attr("class",H+" qtip ui-helper-reset "+f)},"^style.widget|content.title":w,"^events.(render|show|move|hide|focus|blur)$":function(x,A,D){l.tooltip[(c.isFunction(f)?"":"un")+"bind"]("tooltip"+A,D)},"^position.(my|at|adjust|target|container)|style|content":function(){d.reposition()}}};c.each(d.plugins,function(x){if("object"===typeof this.checks)F[x]=this.checks});n=i[0][i[1]];i[0][i[1]]=f.nodeType?c(f):f;U(a);for(o in F)for(C in F[o])RegExp(C,"i").test(b)&& +F[o][C].call(d,i[0],i[1],f,n);return d},toggle:function(b,f){function i(){if(b)c.browser.msie&&g[0].style.removeAttribute("filter");else g.css({display:"block",visibility:"hidden",width:"",opacity:"",left:V,top:V})}if(d.rendered===m)return m;var l=b?"show":"hide",n=a[l],o=j();if((typeof b).search("boolean|number"))b=!o;if(!o&&!b||g.is(":animated"))return d;if(f){if(/over|enter/.test(f.type)&&/out|leave/.test(d.cache.event.type)&&f.target===a.show.target[0]&&g.has(f.relatedTarget).length)return d; +d.cache.event=c.extend({},f)}o=c.Event("tooltip"+l);o.originalEvent=f?d.cache.event:E;g.trigger(o,[d,90]);if(o.isDefaultPrevented())return d;if(b){g.hide().css({visibility:""});d.focus(f);g[0].focus();d.cache.lastFocus.focus();d.reposition(f,0);n.solo&&c(R).not(g).qtip("hide")}else{clearTimeout(d.timers.show);d.blur(f)}g.attr("aria-hidden",Boolean(!b));g.stop(1,1);if(c.isFunction(n.effect)){n.effect.call(g,d);g.queue("fx",function(C){i.call(this,C);C()})}else if(n.effect===m){g[l]();i.call(g)}else g.fadeTo(90, +b?1:0,i);b&&n.target.trigger("qtip-"+p+"-inactive");return d},show:function(b){d.toggle(u,b)},hide:function(b){d.toggle(m,b)},focus:function(b){if(d.rendered===m)return m;var f=c(R),i=parseInt(g[0].style.zIndex,10),l=c.fn.qtip.zindex+f.length;b=c.extend({},b);if(!g.hasClass(T)){if(i!==l){f.each(function(){if(this.style.zIndex>i)this.style.zIndex-=1});c(R+"."+T).qtip("blur",b)}d.cache.lastFocus=document.activeElement;f=c.Event("tooltipfocus");f.originalEvent=b;g.trigger(f,[d,l]);if(!f.isDefaultPrevented())g.addClass(T)[0].style.zIndex= +l}return d},blur:function(b){b=c.extend({},b);var f;g.removeClass(T);f=c.Event("tooltipblur");f.originalEvent=b;g.trigger(f,[d]);d.cache.lastFocus.focus()},reposition:function(b,f){if(d.rendered===m)return m;var i=a.position.target,l=a.position,n=l.my,o=l.at,C=l.adjust,F=g.outerWidth(),x=g.outerHeight(),A=0,D=0,L=c.Event("tooltipmove"),N=g.css("position")==="fixed",v=l.viewport.jquery?l.viewport:c(K),t={left:0,top:0},Q={left:function(I){var J=v.scrollLeft,O=o.x==="left"?A:o.x==="right"?-A:-A/2,S= +J-I;J=I+F-v.width-J;O=(n.x==="left"?F:n.x==="right"?-F:-F/2)-(n.precedance==="x"||n.x===n.y?O:0);if(S>0&&(n.x!=="left"||J>0))t.left-=O;else if(J>0&&(n.x!=="right"||S>0))t.left-=(n.x==="center"?-1:1)*O+2*C.x;if(t.left<0&&-t.left>J)t.left=I;return t.left-I},top:function(I){var J=v.scrollTop,O=o.y==="top"?D:o.y==="bottom"?-D:-D/2,S=J-I;J=I+x-v.height-J;O=(n.y==="top"?x:n.y==="bottom"?-x:-x/2)-(n.precedance==="y"||n.x===n.y?O:0);if(S>0&&(n.y!=="top"||J>0))t.top-=O;else if(J>0&&(n.y!=="bottom"||S>0))t.top-= +(n.y==="center"?-1:1)*O+2*C.y;if(t.top<0&&-t.top>J)t.top=I;return t.top-I}};f=f===P||!!f||m;v=!v?m:{elem:v,height:v[(v[0]===K?"h":"outerH")+"eight"](),width:v[(v[0]===K?"w":"outerW")+"idth"](),scrollLeft:v.scrollLeft(),scrollTop:v.scrollTop()};if(i==="mouse"){o={x:"left",y:"top"};b=b&&(b.type==="resize"||b.type==="scroll")?d.cache.event:C.mouse||!b||!b.pageX?c.extend({},c.fn.qtip.mouse):b;t={top:b.pageY,left:b.pageX}}else{if(i==="event")i=b&&b.target&&b.type!=="scroll"&&b.type!=="resize"?d.cache.target= +c(b.target):d.cache.target;i=c(i).eq(0);if(i.length===0)return d;else if(i[0]===document||i[0]===K){A=i.width();D=i.height();if(i[0]===K)t={top:N?0:v.scrollTop,left:N?0:v.scrollLeft}}else if(i.is("area")&&c.fn.qtip.plugins.imagemap){t=c.fn.qtip.plugins.imagemap(i,o);A=t.width;D=t.height;t=t.offset}else{A=i.outerWidth();D=i.outerHeight();t=q(i[0],l.container[0])}t.left+=o.x==="right"?A:o.x==="center"?A/2:0;t.top+=o.y==="bottom"?D:o.y==="center"?D/2:0}t.left+=C.x+(n.x==="right"?-F:n.x==="center"?-F/ +2:0);t.top+=C.y+(n.y==="bottom"?-x:n.y==="center"?-x/2:0);t.adjusted=l.viewport.jquery&&i[0]!==K&&i[0]!==y?{left:Q.left(t.left),top:Q.top(t.top)}:{left:0,top:0};g.attr("class",function(){return c(this).attr("class").replace(/ui-tooltip-pos-\w+/i,"")}).addClass(H+"-pos-"+n.abbreviation());L.originalEvent=c.extend({},b);g.trigger(L,[d,t,v.elem]);if(L.isDefaultPrevented())return d;delete t.adjusted;if(!f||!isNaN(t.left,t.top))g.css(t);else if(j()&&c.isFunction(l.effect)){l.effect.call(g,d,t);g.queue(function(I){c(this).css({opacity:"", +height:""});c.browser.msie&&this.style&&this.style.removeAttribute("filter");I()})}return d},redraw:function(){if(!d.rendered||!(c.browser.msie&&parseInt(c.browser.version.charAt(0),10)<9))return m;var b=H+"-fluid",f;g.css({width:"auto",height:"auto"}).addClass(b);f={height:g.outerHeight(),width:g.outerWidth()};c.each(["width","height"],function(i,l){var n=parseInt(g.css("max-"+l),10)||0,o=parseInt(g.css("min-"+l),10)||0;f[l]=n+o?Math.min(Math.max(f[l],o),n):f[l]});g.css(f).removeClass(b)},disable:function(b){var f= +M;if("boolean"!==typeof b)b=!(g.hasClass(f)||d.cache.disabled);if(d.rendered)g.toggleClass(f,b);else d.cache.disabled=!!b;return d},destroy:function(){var b=e.data("oldtitle");if(d.rendered){g.remove();c.each(d.plugins,function(){this.initialize==="render"&&this.destroy()})}clearTimeout(d.timers.show);clearTimeout(d.timers.hide);k(1,1,1,1);e.removeData("qtip");b&&e.attr("title",b);e.removeAttr("aria-describedby");return e}})}function Z(e,a){var p,h,q=c(this),j=c(document.body),w=this===document?j: +q;h=q.metadata?q.metadata(a.metadata):E;var s=c.extend(u,{},c.fn.qtip.defaults,a,U((h&&a.metadata.type==="html5"?h[a.metadata.name]:E)||h));q.removeData("metadata");h=s.position;if("boolean"===typeof s.content.text)if(s.content.attr!==m&&q.attr(s.content.attr))s.content.text=q.attr(s.content.attr);else return m;if(h.container===m)h.container=j;if(h.target===m)h.target=w;if(s.show.target===m)s.show.target=w;if(s.hide.target===m)s.hide.target=w;if(s.position.viewport===u)s.position.viewport=h.container; +h.at=new c.fn.qtip.plugins.Corner(h.at);h.my=new c.fn.qtip.plugins.Corner(h.my);if(q.data("qtip"))if(s.overwrite)q.qtip("destroy");else if(s.overwrite===m)return m;q.attr("title")&&q.data("oldtitle",q.attr("title")).removeAttr("title");p=new Y(q,s,e);q.data("qtip",p);q.bind("remove.qtip",function(){p.destroy()});return p}function $(e){var a=this,p=e.elements.tooltip,h=e.options.content.ajax;a.checks={"^content.ajax":function(q,j){if(j==="once")a.once();else h&&h.url&&a.load()}};c.extend(a,{init:function(){if(h&& +h.url){a.load();a.once()}},once:function(){h.once?a.destroy():p.bind("tooltipshow.ajax",function(){a.load()})},load:function(){c.ajax(c.extend({success:function(q){e.set("content.text",q)},error:function(q,j,w){e.set("content.text",j+": "+w)},context:e},h));return a},destroy:function(){p.unbind(".ajax")}});a.init()}function X(e,a,p){var h=Math.ceil(a/2),q=Math.ceil(p/2);a={bottomright:[[0,0],[a,p],[a,0]],bottomleft:[[0,0],[a,0],[0,p]],topright:[[0,p],[a,0],[a,p]],topleft:[[0,0],[0,p],[a,p]],topcenter:[[0, +p],[h,0],[a,p]],bottomcenter:[[0,0],[a,0],[h,p]],rightcenter:[[0,0],[a,q],[0,p]],leftcenter:[[a,0],[a,p],[0,q]]};a.lefttop=a.bottomright;a.righttop=a.bottomleft;a.leftbottom=a.topright;a.rightbottom=a.topleft;return a[e.string()]}function aa(e){function a(k,d,y){if(j.tip){k=c.extend({},h.corner);d=y.adjusted;var g;if(h.corner.fixed!==u){if(d.left)k.x=k.x==="center"?d.left>0?"left":"right":k.x==="left"?"right":"left";if(d.top)k.y=k.y==="center"?d.top>0?"top":"bottom":k.y==="top"?"bottom":"top";if(k.string()!== +s.corner&&(s.top!==d.top||s.left!==d.left))g=h.update(k)}g||(g=h.position(k,0));if(g.right!==P)g.left=g.right;if(g.bottom!==P)g.top=g.bottom;g.option=Math.max(0,q.offset);y.left-=g.left.charAt?g.option:(g.right?-1:1)*g.left;y.top-=g.top.charAt?g.option:(g.bottom?-1:1)*g.top;s.left=d.left;s.top=d.top;s.corner=k.string()}}function p(k,d,y){d=!d?k[k.precedance]:d;d="border-"+d+"-width";k=parseInt((j.titlebar&&k.y==="top"?j.titlebar:j.content).css(d),10);return(y?k||parseInt(w.css(d),10):k)||0}var h= +this,q=e.options.style.tip,j=e.elements,w=j.tooltip,s={top:0,left:0,corner:""},r={width:q.width,height:q.height},z={},B=q.border||0,G=q.method||m;h.corner=E;h.mimic=E;h.checks={"^position.my|style.tip.(corner|mimic|method|border)$":function(){h.init()||h.destroy();e.reposition()},"^style.tip.(height|width)$":function(){r={width:q.width,height:q.height};h.create();h.update();e.reposition()},"^content.title.text|style.(classes|widget)$":function(){j.tip&&h.update()}};c.extend(h,{init:function(){var k= +h.detectCorner();if(k){if(G!=="polygon")G=c("")[0].getContext?"canvas":c.browser.msie?"vml":"polygon";h.create();h.update();w.unbind(".qtip-tip").bind("tooltipmove.qtip-tip",a)}return k},detectCorner:function(){var k=q.corner,d=e.options.position,y=d.at;d=d.my.string?d.my.string():d.my;if(k===m||d===m&&y===m)return m;else if(k===u)h.corner=new c.fn.qtip.plugins.Corner(d);else if(!k.string){h.corner=new c.fn.qtip.plugins.Corner(k);h.corner.fixed=u}return h.corner.string()!=="centercenter"}, +detectColours:function(){var k=j.tip.css({backgroundColor:"",border:""}),d=h.corner,y=d[d.precedance],g="border-"+y+"-color";y="border"+y.charAt(0)+y.substr(1)+"Color";var b=/rgba?\(0, 0, 0(, 0)?\)|transparent/i;d=j.titlebar&&(d.y==="top"||d.y==="center"&&k.position().top+r.height/2+q.offset",{"class":"ui-tooltip-tip"}).css(r).prependTo(w);switch(G){case "canvas":c('').appendTo(j.tip)[0].getContext("2d").save();break;case "vml":k='';j.tip.html(B?k+=k:k);break;case "polygon":j.tip.append('
').append(B?'
':"");break}},update:function(k){var d=j.tip.children(),y=r.width,g=r.height,b=q.mimic,f,i,l,n,o;if(!k)k=h.corner;if(b===m)b=k;else{b=new c.fn.qtip.plugins.Corner(b);b.precedance= +k.precedance;if(b.x==="inherit")b.x=k.x;else if(b.y==="inherit")b.y=k.y;else if(b.x===b.y)b[k.precedance]=k[k.precedance]}B=q.border===u?p(k,E,u):q.border;f=B>0?0:1;n=b.string().indexOf("center")>-1;o=Math[/b|r/.test(b[b.precedance==="y"?"x":"y"])?"ceil":"floor"];k=h.position(k,1);h.detectColours();switch(G){case "canvas":i=d[0].getContext("2d");i.restore&&i.restore();i.clearRect(0,0,3E3,3E3);for(l=X(b,y,g);f<2;f++){if(f){i.save();i.translate(o((b.x==="left"?1:b.x==="right"?-1:0)*(B+1)*(b.precedance=== +"y"?0.5:1)),o((b.y==="top"?1:b.y==="bottom"?-1:0)*(B+1)*(b.precedance==="x"?0.5:1)))}i.beginPath();i.moveTo(l[0][0],l[0][1]);i.lineTo(l[1][0],l[1][1]);i.lineTo(l[2][0],l[2][1]);i.closePath();i.fillStyle=z[f?"fill":"border"];i.fill()}break;case "vml":l=X(b,y,g);l="m"+l[0][0]+","+l[0][1]+" l"+l[1][0]+","+l[1][1]+" "+l[2][0]+","+l[2][1]+" xe";d.each(function(C){c(this).attr({path:l,fillcolor:z[C||!B?"fill":"border"]}).css("antialias",""+n)});break;case "polygon":d.removeAttr("style").css({position:"absolute", +left:0,top:0}).each(function(C){var F={x:b.precedance==="x"?b.x==="left"?"right":"left":b.x,y:b.precedance==="y"?b.y==="top"?"bottom":"top":b.y},x=b.x==="center"?["left","right",F.y,g,y]:["top","bottom",F.x,y,g];C=z[!C&&B?"border":"fill"];b.x==="center"||b.y==="center"?c(this).css("border-"+x[2],x[3]+"px solid "+C).css("border-"+x[0],o(x[4]/2)+"px dashed transparent").css("border-"+x[1],o(x[4]/2)+"px dashed transparent"):c(this).css("border-width",o(g/2)+"px "+o(y/2)+"px").css("border-"+F.x,o(y/2)+ +"px solid "+C).css("border-"+F.y,o(g/2)+"px solid "+C)});break}if(G!=="canvas"&&B){f=[B*2.75,B];f=b.precedance==="y"?[b.x==="left"?f[1]:b.x==="right"?-f[1]:0,b.y==="bottom"?-f[0]:f[0]]:[b.x==="left"?f[0]:-f[0],b.y==="bottom"?-f[1]:b.y==="top"?f[1]:0];d.eq(1).css({left:f[0],top:f[1]})}return k},position:function(k,d){var y=j.tip,g={},b=Math.max(0,q.offset),f,i;if(q.corner===m||!y)return m;k=k||h.corner;f=k.precedance;i=r[f==="x"?"width":"height"];c.each(f==="y"?[k.x,k.y]:[k.y,k.x],function(l,n){var o; +if(n==="center"){o=f==="y"?"left":"top";g[o]="50%";g["margin-"+o]=-Math.floor(i/2)+b}else{o=p(k,n,u);if(l||B===P)o=p(k,n);else{if(o)o=0;else{o=c.browser.mozilla;var C=k.y+(o?"":"-")+k.x;o=(o?"-moz-":c.browser.webkit?"-webkit-":"")+(o?"border-radius-"+C:"border-"+C+"-radius");o=parseInt((j.titlebar&&k.y==="top"?j.titlebar:j.content).css(o),10)||parseInt(w.css(o),10)||0}o=b+o}g[n]=o}});g[k[f]]-=i;d&&y.css({top:"",bottom:"",left:"",right:"",margin:""}).css(g);return g},destroy:function(){j.tip&&j.tip.remove(); +w.unbind(".qtip-tip")}});h.init()}function ba(e){var a=this,p=e.options.show.modal,h=e.elements,q=h.tooltip;a.checks={"^show.modal.(on|blur)$":function(){a.init();h.overlay.toggle(q.is(":visible"))}};c.extend(a,{init:function(){if(p.on){q.unbind(".qtipmodal").bind("tooltipshow.qtipmodal tooltiphide.qtipmodal",function(j,w,s){j=j.type.replace("tooltip","");c.isFunction(p[j])?p[j].call(h.overlay,s,w):a[j](s)});a.create();p.blur===u&&h.overlay.unbind(".qtipmodal"+e.id).bind("click.qtipmodal"+e.id,function(){e.hide.call(e)})}}, +create:function(){var j=c("#qtip-overlay");if(j.length)h.overlay=j;else{h.overlay=c("
",{id:"#qtip-overlay".substr(1),css:{position:"absolute",top:0,left:0,display:"none",zIndex:parseInt(q.css("z-index"),10)-1}}).appendTo(document.body);c(K).bind("resize.qtipmodal",function(){h.overlay.css({height:Math.max(c(K).height(),c(document).height()),width:Math.max(c(K).width(),c(document).width())})}).trigger("resize")}},toggle:function(j){var w=h.overlay,s=e.options.show.modal.effect,r=j?"show":"hide"; +w.stop(u,m);if(c.isFunction(s))s.call(w,j);else s===m?w[r]():w.fadeTo(90,j?0.7:0,function(){j||c(this).hide()})},show:function(){a.toggle(u)},hide:function(){a.toggle(m)},destroy:function(){var j=u;c("*").each(function(){var w=c(this).data("qtip");if(w&&w.id!==e.id&&w.options.show.modal)return j=m});if(j){h.overlay.remove();c(K).unbind(".qtipmodal")}else h.overlay.unbind(".qtipmodal"+e.id);q.unbind("tooltipshow.qtipmodal tooltiphide.qtipmodal")}});a.init()}function ca(e){var a=this,p=e.elements,h= +p.tooltip,q=".bgiframe-"+e.id,j="tooltipmove"+q+" tooltipshow"+q;c.extend(a,{init:function(){p.bgiframe=c('');p.bgiframe.appendTo(h);h.bind(j,a.adjust)},adjust:function(){var w=e.get("dimensions"),s=e.plugins.tip,r=e.elements.tip,z;z=parseInt(h.css("border-left-width"),10)||0;z={left:-z,top:-z};if(s&&r){s=s.corner.precedance=== +"x"?["width","left"]:["height","top"];z[s[1]]-=r[s[0]]()}p.bgiframe.css(z).css(w)},destroy:function(){a.iframe.remove();h.unbind(j)}});a.init()}var u=true,m=false,E=null,H="ui-tooltip",W="ui-widget",M="ui-state-disabled",R=".qtip."+H,T=H+"-focus",V="-31000px";c.fn.qtip=function(e,a,p){var h=String(e).toLowerCase(),q=E,j=h==="disable"?[u]:c.makeArray(arguments).slice(1,10),w=j[j.length-1],s;if(!arguments.length&&this.data("qtip")||h==="api")return(s=this.data("qtip"))?s:P;else if("string"===typeof e){this.each(function(){var r= +c(this).data("qtip");if(!r)return u;if(/option|set/.test(h)&&a)if(p!==P)r.set(a,p);else q=r.get(a);else{if(!r.rendered&&(h==="show"||h==="toggle")){if(w&&w.timeStamp)r.cache.event=w;r.render(1)}else if(h==="enable"){h="disable";j=[m]}r[h]&&r[h].apply(r[h],j)}});return q!==E?q:this}else if("object"===typeof e||!arguments.length){s=U(c.extend(u,{},e));return c.fn.qtip.bind.call(this,s,w)}};c.fn.qtip.bind=function(e,a){return this.each(function(){function p(z){function B(){r.render(typeof z==="object"|| +h.show.ready);q.show.unbind(j.show);q.hide.unbind(j.hide)}if(r.cache.disabled)return m;r.cache.event=c.extend({},z);if(h.show.delay>0){clearTimeout(r.timers.show);r.timers.show=setTimeout(B,h.show.delay);j.show!==j.hide&&q.hide.bind(j.hide,function(){clearTimeout(r.timers.show)})}else B()}var h,q,j,w=e.id=!e.id||e.id===m||e.id.length<1||c("#"+H+"-"+e.id).length?c.fn.qtip.nextid++:e.id,s=".qtip-"+w+"-create",r=Z.call(this,w,e);if(r===m)return u;h=r.options;c.each(c.fn.qtip.plugins,function(){this.initialize=== +"initialize"&&this(r)});q={show:h.show.target,hide:h.hide.target};j={show:String(h.show.event).replace(" ",s+" ")+s,hide:String(h.hide.event).replace(" ",s+" ")+s};q.show.bind(j.show,p);if(h.show.ready||h.prerender)p(a)})};c.each({attr:function(e){var a=c(this),p=a.data("qtip");return arguments.length===1&&e==="title"&&p&&p.rendered===u?a.data("oldtitle"):E},remove:c.ui?E:function(e,a){c(this).each(function(){if(!a)if(!e||c.filter(e,[this]).length)c("*",this).add(this).each(function(){c(this).triggerHandler("remove")})})}}, +function(e,a){if(!a)return u;c.fn["Old"+e]=c.fn[e];c.fn[e]=function(){return a.apply(this,arguments)||c.fn["Old"+e].apply(this,arguments)}});c(document).ready(function(){var e=document.body;c(e).attr("role",function(a,p){return!p?"application":p});c(document).bind("mousemove.qtip",function(a){c.fn.qtip.mouse={pageX:a.pageX,pageY:a.pageY}});document.activeElement===P&&document.addEventListener("focus",function(a){if(a&&a.target)document.activeElement=a.target===document?e:a.target},true)});c.fn.qtip.version= +"2.0.0pre";c.fn.qtip.nextid=0;c.fn.qtip.inactiveEvents="click dblclick mousedown mouseup mousemove mouseleave mouseenter".split(" ");c.fn.qtip.zindex=15E3;c.fn.qtip.plugins={Corner:function(e){e=String(e).replace(/([A-Z])/," $1").replace(/middle/gi,"center").toLowerCase();this.x=(e.match(/left|right/i)||e.match(/center/)||["inherit"])[0].toLowerCase();this.y=(e.match(/top|bottom|center/i)||["inherit"])[0].toLowerCase();this.precedance=e.charAt(0).search(/^(t|b)/)>-1?"y":"x";this.string=function(){return this.precedance=== +"y"?this.y+this.x:this.x+this.y};this.abbreviation=function(){var a=this.x.substr(0,1),p=this.y.substr(0,1);return a===p?a:a==="c"||a!=="c"&&p!=="c"?p+a:a+p}},iOS:parseFloat((/CPU.+OS ([0-9_]{3}).*AppleWebkit.*Mobile/i.exec(navigator.userAgent)||[0,"4_2"])[1].replace("_","."))<4.1};c.fn.qtip.defaults={prerender:m,id:m,overwrite:u,metadata:{type:"class"},content:{text:u,attr:"title",title:{text:m,button:m}},position:{my:"top left",at:"bottom right",target:m,container:m,viewport:m,adjust:{x:0,y:0,mouse:u, +resize:u},effect:u},show:{target:m,event:"mouseenter",effect:u,delay:90,solo:m,ready:m},hide:{target:m,event:"mouseleave",effect:u,delay:0,fixed:m,inactive:m},style:{classes:"",widget:m},events:{render:E,move:E,show:E,hide:E,toggle:E,focus:E,blur:E}};c.fn.qtip.plugins.ajax=function(e){var a=e.plugins.ajax;return"object"===typeof a?a:e.plugins.ajax=new $(e)};c.fn.qtip.plugins.ajax.initialize="render";c.fn.qtip.plugins.ajax.sanitize=function(e){var a=e.content;if(a&&"ajax"in a){a=a.ajax;if(typeof a!== +"object")a=e.content.ajax={url:a};if("boolean"!==typeof a.once&&a.once)a.once=!!a.once}};c.extend(u,c.fn.qtip.defaults,{content:{ajax:{once:u}}});c.fn.qtip.plugins.tip=function(e){var a=e.plugins.tip;return"object"===typeof a?a:e.plugins.tip=new aa(e)};c.fn.qtip.plugins.tip.initialize="render";c.fn.qtip.plugins.tip.sanitize=function(e){var a=e.style;if(a&&"tip"in a){a=e.style.tip;if(typeof a!=="object")e.style.tip={corner:a};if(!/string|boolean/i.test(typeof a.corner))a.corner=u;if(typeof a.method!== +"string")a.method=u;if(!/canvas|polygon/i.test(a.method))a.method=u;typeof a.width!=="number"&&delete a.width;typeof a.height!=="number"&&delete a.height;typeof a.border!=="number"&&a.border!==u&&delete a.border;typeof a.offset!=="number"&&delete a.offset}};c.extend(u,c.fn.qtip.defaults,{style:{tip:{corner:u,mimic:m,method:u,width:8,height:8,border:u,offset:0}}});c.fn.qtip.plugins.imagemap=function(e,a){function p(G,k){for(var d=0,y=1,g=1,b=0,f=0,i=G.width,l=G.height;i>0&&l>0&&y>0&&g>0;){i=Math.floor(i/ +2);l=Math.floor(l/2);if(a.x==="left")y=i;else if(a.x==="right")y=G.width-i;else y+=Math.floor(i/2);if(a.y==="top")g=l;else if(a.y==="bottom")g=G.height-l;else g+=Math.floor(l/2);for(d=k.length;d--;){if(k.length<2)break;b=k[d][0]-G.offset.left;f=k[d][1]-G.offset.top;if(a.x==="left"&&b>=y||a.x==="right"&&b<=y||a.x==="center"&&(bG.width-y)||a.y==="top"&&f>=g||a.y==="bottom"&&f<=g||a.y==="center"&&(fG.height-g))k.splice(d,1)}}return{left:k[0][0],top:k[0][1]}}var h=e.attr("shape").toLowerCase(), +q=e.attr("coords").split(","),j=[],w=c('img[usemap="#'+e.parent("map").attr("name")+'"]'),s=w.offset(),r={width:0,height:0,offset:{top:1E10,right:0,bottom:0,left:1E10}},z=0,B=0;s.left+=Math.ceil((w.outerWidth()-w.width())/2);s.top+=Math.ceil((w.outerHeight()-w.height())/2);if(h==="poly")for(z=q.length;z--;){B=[parseInt(q[--z],10),parseInt(q[z+1],10)];if(B[0]>r.offset.right)r.offset.right=B[0];if(B[0]r.offset.bottom)r.offset.bottom=B[1];if(B[1]35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('"5w 5x";(12(d,K,O){12 U(f){15 a;11(!f)18 m;11("1G"!==1o f.2c)f.2c={1T:f.2c};11("1c"2g f){11("1G"!==1o f.1c||f.1c.2f)f.1c={1L:f.1c};a=f.1c.1L||m;11(!d.2E(a)&&(!a&&!a.1x||a.1t<1||"1G"===1o a&&!a.2f))a=f.1c.1L=m;11("1r"2g f.1c&&"1G"!==1o f.1c.1r)f.1c.1r={1L:f.1c.1r}}11("1n"2g f)11("1G"!==1o f.1n)f.1n={1W:f.1n,2s:f.1n};11("13"2g f)11("1G"!==1o f.13)f.13=f.13.2f?{1h:f.13}:{1y:f.13};11("1a"2g f)11("1G"!==1o f.1a)f.1a=f.1a.2f?{1h:f.1a}:{1y:f.1a};11("1q"2g f)11("1G"!==1o f.1q)f.1q={3v:f.1q};d.1B(d.1d.14.1j,12(){19.38&&19.38(f)});18 f}12 Y(f,a,p){12 h(c){15 e,g=c.3f("."),l=a[g[0]];2K(c=1;c",{"1V":"1J-31-48 "+(a.1q.2B?"":H+"-3z"),1r:"5B"}).5C(d("<5D />",{"1V":"1J-3z 1J-3z-5E",3g:"&5F;"}));c.1Y.4Y(c.1O).1x("3W","1Y").5b(12(g){d(19).2x("1J-31-5b",g.1T==="3p")}).4e(12(g){c.1b.2t(M)||b.1a(g);18 m}).1s("4b 5G 4J 5H 74",12(g){d(19).2x("1J-31-5I 1J-31-26",/5J$/i.1N(g.1T))});b.3D()}12 z(){15 c=b.1k,e=H+"-"+b.1u+"-1r";c.1O&&s();c.1O=d("<2w />",{"1V":H+"-1O "+(a.1q.2B?"1J-2B-4v":"")}).3h(c.1r=d("<2w />",{1u:e,"1V":H+"-1r",3g:a.1c.1r.1L})).5K(c.1c);c.1b.1x("3c-4N",e);11(a.1c.1r.1Y)o();1e b.1H===t&&b.3D()}12 D(c){15 e=b.1k;11(!b.1H||!c)18 m;11(d.2E(c))c=c.27(f);c.2f&&c.1t>0?e.1c.5L().3h(c.1f({3k:"3N"})):e.1c.3g(c);e.1b.3I("3Z",12(g){12 l(r){i=i.3C(r);11(i.1t===0){b.3D();b.1H===t&&b.2b(b.1z.1y);g()}}15 i=d("3a:3C([1i]):3C([1g])",b.1k.1c);i.1B(12(r,q){15 E=["5M","4Q","3b","6v",""].5N(".14-5O ");d(19).1s(E,12(){1Z(b.1K.3a[r]);l(19)});(12 C(){11(q.1i)18 l(q);b.1K.3a[r]=3m(C,20)})();18 t});i.1t===0&&l(i)});18 b}12 G(c,e,g,l){12 i(A){11(u.1b.2t(M))18 m;u.13.2D("14-"+p+"-2p");1Z(b.1K.13);1Z(b.1K.1a);15 B=12(){b.13(A)};11(a.13.2u>0)b.1K.13=3m(B,a.13.2u);1e B()}12 r(A){11(u.1b.2t(M))18 m;15 B=d(A.3X||A.1h).4x(Q)[0]===u.1b[0],w=d(A.3X||A.1h)[0]===u.13[0];1Z(b.1K.13);1Z(b.1K.1a);11(a.1a.2v&&(x.1h==="2n"&&B||/2n(4z|4A|3Q)/.1N(A.1T)&&(B||w))){A.6i();A.5P();18 m}u.1b.4k(1,1);11(a.1a.2u>0)b.1K.1a=3m(12(){b.1a(A)},a.1a.2u);1e b.1a(A)}12 q(A){11(u.1b.2t(M))18 m;1Z(b.1K.2p);b.1K.2p=3m(12(){b.1a(A)},a.1a.2p)}12 E(A){11(!b.1z.3Y){b.1z.3Y=1;j()&&b.2b(A);b.1z.3Y=0}}15 C=".14-"+p,x=a.1n,u={13:a.13.1h,1a:a.1a.1h,1b:b.1k.1b,1M:x.1M[0]===y?1D:x.1M},I={13:2U(a.13.1y).3f(" "),1a:2U(a.1a.1y).3f(" ")},P=d.24.2Q&&1R(d.24.3H,10)===6;11(g){11(a.1a.2v){u.1a=u.1a.2Z(u.1b);u.1b.1s("5Q"+C,12(){u.1b.2t(M)||1Z(b.1K.1a)})}u.1b.1s("3p"+C+" 4m"+C,12(A){b[A.1T==="3p"?"26":"2q"](A)})}11(e){11("2V"===1o a.1a.2p){u.13.1s("14-"+p+"-2p",q);d.1B(d.1d.14.4G,12(A,B){u.1a.2Z(b.1k.1b).1s(B+C+"-2p",q)})}d.1B(I.1a,12(A,B){15 w=d.5R(B,I.13);11(w>-1&&d(u.1a).2Z(u.13).1t===d(u.1a).1t||B==="54"){u.13.1s(B+C,12(R){j()?r(R):i(R)});2O I.13[w]}1e u.1a.1s(B+C,r)})}c&&d.1B(I.13,12(A,B){u.13.1s(B+C,i)});11(l){11(x.2F.2A||x.2e)d(d.1y.5S.2A?x.2e:K).1s("2A"+C,E);11(x.2e||P&&u.1b.1f("1n")==="2v")d(x.2e).1s("4j"+C,E);/54/i.1N(a.1a.1y)&&d(1D).1s("4b"+C,12(A){15 B=b.1k.1b;d(A.1h).4x(Q).1t===0&&d(A.1h).2Z(f).1t>1&&j()&&!B.2t(M)&&b.1a(A)});x.1h==="2n"&&d(1D).1s("43"+C,12(A){11(x.2F.2n&&!u.1b.2t(M)&&j())b.2b(A||d.1d.14.2n)})}}12 k(c,e,g,l){l=1R(l,10)!==0;15 i=".14-"+p;e={13:c?a.13.1h:F,1a:e?a.1a.1h:F,1b:g?b.1k.1b:F,1c:g?b.1k.1c:F,1M:l?a.1n.1M[0]===y?1D:a.1n.1M:F,4o:l?K:F};11(b.1H)d([]).69(d.5T([e.13,e.1a,e.1b,e.1M,e.1c,e.4o],12(){18 19!==4q})).1X(i);1e c&&e.13.1X(i+"-2L")}15 b=19,y=1D.35;b.1u=p;b.1H=m;b.1k={1h:f};b.1K={3a:[]};b.2z=a;b.1j={};b.1z={1y:{},1h:F,2W:m,3w:y};d.1F(b,{2a:12(c){11(b.1H)18 m;15 e=b.1k,g=d.3e("68");e.1b=d("<2w/>").1x({1u:H+"-"+p,3W:"5U","1V":H+" 14 1J-4E-4D "+a.1q.3v,"3c-4O":H+"-"+b.1u+"-1c",5n:-1}).2x(M,b.1z.2W).21("14",b).30(a.1n.1M).3h(e.1c=d("<2w />",{"1V":H+"-1c",1u:H+"-"+p+"-1c"}));b.1H=t;a.1c.1r.1L&&z();D(a.1c.1L);d.1B(d.1d.14.1j,12(){19.2C==="2a"&&19(b)});G(1,1,1,1);d.1B(a.4f,12(l,i){11(i)e.1b.1s(l==="2l"?"3s 4l":"1b"+l,i)});e.1b.3I("3Z",12(l){g.36=b.1z.1y;e.1b.2D(g,[b]);11(a.13.2S||c){e.1b.1a();b.13(b.1z.1y)}l()});18 b},3U:12(c){15 e=b.1k.1b;3M(c.2y()){25"4p":c={1i:e.2P(),1g:e.37()};1S;25"1p":c=n(e[0],a.1n.1M);1S;48:c=h(c.2y());c=c[0].1C?c[0].1Q():c[0].2f?c[0]:c[0][c[1]];1S}18 c},32:12(c,e){c=c.2y();15 g=h(c),l=b.1k,i=l.1b,r,q,E,C={5W:{"^1u$":12(){15 x=e===t?d.1d.14.41:e,u=H+"-"+x;11(x!==m&&x.1t>0&&!d("#"+u).1t){i[0].1u=u;l.1c[0].1u=u+"-1c";l.1r[0].1u=u+"-1r"}},"^1c.1L$":12(){D(e)},"^1c.1r.1L$":12(){11(b.1H)11(!b.1k.1r&&e){z();b.2b()}1e e?b.1k.1r.3g(e):s()},"^1c.1r.1Y$":12(){15 x=b.1k.1Y,u=b.1k.1r;11(b.1H)11(e){u||z();o()}1e x.22()},"^1n.(1W|2s)$":12(){15 x=/1W$/i.1N(c)?"1W":"2s";11("1Q"===1o e)a.1n[x]=28 d.1d.14.1j.2J(e)},"^1n.1M$":12(){b.1H===t&&i.30(e)},"^(13|1a).(1y|1h|2v|2u|2p)$":12(x,u,I,P){15 A=c.46(/2v/i)>-1?[0,[0,1,1,1]]:[c.3j(0,3),c.2R(0)==="s"?[1,0,0,0]:[0,1,0,0]];11(A[0])x[u]=P;k.3d(b,A[1]);11(A[0])x[u]=I;G.3d(b,A[1])},"^13.2S$":12(){b.1H===m&&b.13()},"^1q.3v$":12(){b.1k.1b.1x("1V",H+" 14 1J-4E-4D "+e)},"^1q.2B|1c.1r":v,"^4f.(2a|13|3Q|1a|26|2q)$":12(x,u,I){l.1b[(d.2E(e)?"":"5X")+"1s"]("1b"+u,I)},"^1n.(1W|2s|2F|1h|1M)|1q|1c":12(){b.2b()}}};d.1B(b.1j,12(x){11("1G"===1o 19.34)C[x]=19.34});r=g[0][g[1]];g[0][g[1]]=e.63?d(e):e;U(a);2K(q 2g C)2K(E 2g C[q])5Y(E,"i").1N(c)&&C[q][E].27(b,g[0],g[1],e,r);18 b},2l:12(c,e){12 g(){11(c)d.24.2Q&&i[0].1q.5h("3F");1e i.1f({3k:"3N",4B:"4C",1g:"",3P:"",17:V,16:V})}11(b.1H===m)18 m;15 l=c?"13":"1a",i=b.1k.1b,r=a[l],q=j();11((1o c).46("33|2V"))c=!q;11(!q&&!c||i.4i(":5Z"))18 b;11(e){11(/60|61/.1N(e.1T)&&/4z|4A/.1N(b.1z.1y.1T)&&e.1h===a.13.1h[0]&&i.62(e.3X).1t)18 b;b.1z.1y=d.1F({},e)}q=d.3e("1b"+l);q.36=e?b.1z.1y:F;i.2D(q,[b,3L]);11(q.42())18 b;11(c){i.1a().1f({4B:""});b.26(e);i[0].26();b.1z.3w.26();b.2b(e,0);r.5k&&d(Q).3C(i).14("1a")}1e{1Z(b.1K.13);b.2q(e)}i.1x("3c-4C",65(!c));i.4k(1,1);11(d.2E(r.2m)){r.2m.27(i,b);i.3I("3Z",12(E){g.27(19,E);E()})}1e 11(r.2m===m){i[l]();g.27(i)}1e i.5m(3L,c?1:0,g);c&&r.1h.2D("14-"+p+"-2p");18 b},13:12(c){b.2l(t,c)},1a:12(c){b.2l(m,c)},26:12(c){11(b.1H===m)18 m;15 e=b.1k.1b,g=d(Q),l=1R(e[0].1q.3q,10),i=d.1d.14.4K+g.1t;c=d.1F({},c);11(!e.2t(T)){11(l!==i){g.1B(12(){11(19.1q.3q>l)19.1q.3q-=1});d(Q+"."+T).14("2q",c)}b.1z.3w=1D.3V;g=d.3e("66");g.36=c;e.2D(g,[b,i]);11(!g.42())e.44(T)[0].1q.3q=i}18 b},2q:12(c){15 e=b.1k.1b;c=d.1F({},c);15 g;e.4M(T);g=d.3e("67");g.36=c;e.2D(g,[b]);b.1z.3w.26()},2b:12(c,e){11(b.1H===m)18 m;15 g=a.1n.1h,l=b.1k.1b,i=a.1n,r=i.1W,q=i.2s,E=i.2F,C=b.1k.1b.37(),x=b.1k.1b.2P(),u=0,I=0,P=d.3e("4n"),A=l.1f("1n")==="2v",B=i.2e.2f?i.2e:d(K),w={17:0,16:0},R={17:12(L){15 J=B.3u,N=q.x==="17"?u:q.x==="1w"?-u:-u/2,S=J-L;J=L+C-B.1g-J;N=(r.x==="17"?C:r.x==="1w"?-C:-C/2)-(r.1C==="x"||r.x===r.y?N:0);11(S>0&&(r.x!=="17"||J>0))w.17-=N;1e 11(J>0&&(r.x!=="1w"||S>0))w.17-=(r.x==="1I"?-1:1)*N+2*E.x;11(w.17<0&&-w.17>J)w.17=L;18 w.17-L},16:12(L){15 J=B.3r,N=q.y==="16"?I:q.y==="1v"?-I:-I/2,S=J-L;J=L+x-B.1i-J;N=(r.y==="16"?x:r.y==="1v"?-x:-x/2)-(r.1C==="y"||r.x===r.y?N:0);11(S>0&&(r.y!=="16"||J>0))w.16-=N;1e 11(J>0&&(r.y!=="1v"||S>0))w.16-=(r.y==="1I"?-1:1)*N+2*E.y;11(w.16<0&&-w.16>J)w.16=L;18 w.16-L}};e=e===O||!!e||m;B=!B?m:{4I:B,1i:B[(B[0]===K?"h":"6b")+"6c"](),1g:B[(B[0]===K?"w":"6d")+"6e"](),3u:B.3u(),3r:B.3r()};11(g==="2n"){q={x:"17",y:"16"};c=c&&(c.1T==="2A"||c.1T==="4j")?b.1z.1y:E.2n||!c||!c.3A?d.1F({},d.1d.14.2n):c;w={16:c.3T,17:c.3A}}1e{11(g==="1y")g=c&&c.1h&&c.1T!=="4j"&&c.1T!=="2A"?b.1z.1h=d(c.1h):b.1z.1h;g=d(g).5e(0);11(g.1t===0)18 b;1e 11(g[0]===1D||g[0]===K){u=g.1g();I=g.1i();11(g[0]===K)w={16:A?0:B.3r,17:A?0:B.3u}}1e 11(g.4i("6g")&&d.1d.14.1j.40){w=d.1d.14.1j.40(g,q);u=w.1g;I=w.1i;w=w.1p}1e{u=g.37();I=g.2P();w=n(g[0],i.1M[0])}w.17+=q.x==="1w"?u:q.x==="1I"?u/2:0;w.16+=q.y==="1v"?I:q.y==="1I"?I/2:0}w.17+=E.x+(r.x==="1w"?-C:r.x==="1I"?-C/2:0);w.16+=E.y+(r.y==="1v"?-x:r.y==="1I"?-x/2:0);w.45=i.2e.2f&&g[0]!==K&&g[0]!==y?{17:R.17(w.17),16:R.16(w.16)}:{17:0,16:0};l.1x("1V",12(){18 d(19).1x("1V").2H(/1J-1b-4H-\\w+/i,"")}).44(H+"-4H-"+r.4S());P.36=d.1F({},c);l.2D(P,[b,w,B.4I]);11(P.42())18 b;2O w.45;11(!e||!6j(w.17,w.16))l.1f(w);1e 11(j()&&d.2E(i.2m)){i.2m.27(l,b,w);l.3I(12(L){d(19).1f({3P:"",1i:""});d.24.2Q&&19.1q&&19.1q.5h("3F");L()})}18 b},3D:12(){11(!b.1H||!(d.24.2Q&&1R(d.24.3H.2R(0),10)<9))18 m;15 c=b.1k.1b,e=H+"-6l",g;c.1f({1g:"4L",1i:"4L"}).44(e);g={1i:c.2P(),1g:c.37()};d.1B(["1g","1i"],12(l,i){15 r=1R(c.1f("2Y-"+i),10)||0,q=1R(c.1f("55-"+i),10)||0;g[i]=r+q?1E.55(1E.2Y(g[i],q),r):g[i]});c.1f(g).4M(e)},4h:12(c){15 e=b.1k.1b,g=M;11("33"!==1o c)c=!(e.2t(g)||b.1z.2W);11(b.1H)e.2x(g,c);1e b.1z.2W=!!c;18 b},2h:12(){15 c=b.1k,e=c.1h.21("4c");11(b.1H){c.1b.22();d.1B(b.1j,12(){19.2C==="2a"&&19.2h()})}1Z(b.1K.13);1Z(b.1K.1a);k(1,1,1,1);f.4P("14");e&&f.1x("1r",e);f.3J("3c-4O");18 f}})}12 Z(f,a){15 p,h,n=d(19),j=d(1D.35),v=19===1D?j:n;h=n.2c?n.2c(a.2c):F;15 s=d.1F(t,{},d.1d.14.3o,a,U((h&&a.2c.1T==="6n"?h[a.2c.4Z]:F)||h));n.4P("2c");h=s.1n;11("33"===1o s.1c.1L)11(s.1c.1x!==m&&n.1x(s.1c.1x))s.1c.1L=n.1x(s.1c.1x);1e 18 m;11(h.1M===m)h.1M=j;11(h.1h===m)h.1h=v;11(s.13.1h===m)s.13.1h=v;11(s.1a.1h===m)s.1a.1h=v;11(s.1n.2e===t)s.1n.2e=h.1M;h.2s=28 d.1d.14.1j.2J(h.2s);h.1W=28 d.1d.14.1j.2J(h.1W);11(n.21("14"))11(s.4d)n.14("2h");1e 11(s.4d===m)18 m;n.1x("1r")&&n.21("4c",n.1x("1r")).3J("1r");p=28 Y(n,s,f);n.21("14",p);n.1s("22.14",12(){p.2h()});18 p}12 $(f){15 a=19,p=f.1k.1b,h=f.2z.1c.1U;a.34={"^1c.1U":12(n,j){11(j==="2k")a.2k();1e h&&h.3x&&a.3b()}};d.1F(a,{2j:12(){11(h&&h.3x){a.3b();a.2k()}},2k:12(){h.2k?a.2h():p.1s("3s.1U",12(){a.3b()})},3b:12(){d.1U(d.1F({6q:12(n){f.32("1c.1L",n)},4Q:12(n,j,v){f.32("1c.1L",j+": "+v)},6L:f},h));18 a},2h:12(){p.1X(".1U")}});a.2j()}12 X(f,a,p){15 h=1E.39(a/2),n=1E.39(p/2);a={4R:[[0,0],[a,p],[a,0]],4U:[[0,0],[a,0],[0,p]],4T:[[0,p],[a,0],[a,p]],4V:[[0,0],[0,p],[a,p]],6r:[[0,p],[h,0],[a,p]],6s:[[0,0],[a,0],[h,p]],6t:[[0,0],[a,n],[0,p]],6H:[[a,0],[a,p],[0,n]]};a.6w=a.4R;a.6x=a.4U;a.6y=a.4T;a.6z=a.4V;18 a[f.1Q()]}12 4t(f){12 a(k,b,y){11(j.1l){k=d.1F({},h.1A);b=y.45;15 c;11(h.1A.2v!==t){11(b.17)k.x=k.x==="1I"?b.17>0?"17":"1w":k.x==="17"?"1w":"17";11(b.16)k.y=k.y==="1I"?b.16>0?"16":"1v":k.y==="16"?"1v":"16";11(k.1Q()!==s.1A&&(s.16!==b.16||s.17!==b.17))c=h.3i(k)}c||(c=h.1n(k,0));11(c.1w!==O)c.17=c.1w;11(c.1v!==O)c.16=c.1v;c.3y=1E.2Y(0,n.1p);y.17-=c.17.2R?c.3y:(c.1w?-1:1)*c.17;y.16-=c.16.2R?c.3y:(c.1v?-1:1)*c.16;s.17=b.17;s.16=b.16;s.1A=k.1Q()}}12 p(k,b,y){b=!b?k[k.1C]:b;b="1m-"+b+"-1g";k=1R((j.1O&&k.y==="16"?j.1O:j.1c).1f(b),10);18(y?k||1R(v.1f(b),10):k)||0}15 h=19,n=f.2z.1q.1l,j=f.1k,v=j.1b,s={16:0,17:0,1A:""},o={1g:n.1g,1i:n.1i},z={},D=n.1m||0,G=n.2I||m;h.1A=F;h.3B=F;h.34={"^1n.1W|1q.1l.(1A|3B|2I|1m)$":12(){h.2j()||h.2h();f.2b()},"^1q.1l.(1i|1g)$":12(){o={1g:n.1g,1i:n.1i};h.2L();h.3i();f.2b()},"^1c.1r.1L|1q.(3v|2B)$":12(){j.1l&&h.3i()}};d.1F(h,{2j:12(){15 k=h.4W();11(k){11(G!=="3t")G=d("<2G />")[0].4a?"2G":d.24.2Q?"3l":"3t";h.2L();h.3i();v.1X(".14-1l").1s("4n.14-1l",a)}18 k},4W:12(){15 k=n.1A,b=f.2z.1n,y=b.2s;b=b.1W.1Q?b.1W.1Q():b.1W;11(k===m||b===m&&y===m)18 m;1e 11(k===t)h.1A=28 d.1d.14.1j.2J(b);1e 11(!k.1Q){h.1A=28 d.1d.14.1j.2J(k);h.1A.2v=t}18 h.1A.1Q()!=="4w"},53:12(){15 k=j.1l.1f({6B:"",1m:""}),b=h.1A,y=b[b.1C],c="1m-"+y+"-2T";y="1m"+y.2R(0)+y.3j(1)+"6C";15 e=/6E?\\(0, 0, 0(, 0)?\\)|3n/i;b=j.1O&&(b.y==="16"||b.y==="1I"&&k.1n().16+o.1i/2+n.1p",{"1V":"1J-1b-1l"}).1f(o).4Y(v);3M(G){25"2G":d(\'<2G 1i="\'+b+\'" 1g="\'+k+\'" />\').30(j.1l)[0].4a("2d").58();1S;25"3l":k=\'<3l:47 6K="0,0" 6M="\'+k+" "+b+\'" 6O="3S" 1q="6P:3x(#48#6R); 3k:6T-3N; 1n:3O; 5c:3S; 17: 0; 16: 0; 1g:\'+k+"2r; 1i:"+b+\'2r;">\';j.1l.3g(D?k+=k:k);1S;25"3t":j.1l.3h(\'<2w 1V="1J-1b-1l-6V" />\').3h(D?\'<2w 1V="1J-1b-1l-1m" />\':"");1S}},3i:12(k){15 b=j.1l.6X(),y=o.1g,c=o.1i,e=n.3B,g,l,i,r,q;11(!k)k=h.1A;11(e===m)e=k;1e{e=28 d.1d.14.1j.2J(e);e.1C=k.1C;11(e.x==="3G")e.x=k.x;1e 11(e.y==="3G")e.y=k.y;1e 11(e.x===e.y)e[k.1C]=k[k.1C]}D=n.1m===t?p(k,F,t):n.1m;g=D>0?0:1;r=e.1Q().6Z("1I")>-1;q=1E[/b|r/.1N(e[e.1C==="y"?"x":"y"])?"39":"2M"];k=h.1n(k,1);h.53();3M(G){25"2G":l=b[0].4a("2d");l.56&&l.56();l.71(0,0,57,57);2K(i=X(e,y,c);g<2;g++){11(g){l.58();l.73(q((e.x==="17"?1:e.x==="1w"?-1:0)*(D+1)*(e.1C==="y"?0.5:1)),q((e.y==="16"?1:e.y==="1v"?-1:0)*(D+1)*(e.1C==="x"?0.5:1)))}l.76();l.77(i[0][0],i[0][1]);l.5a(i[1][0],i[1][1]);l.5a(i[2][0],i[2][1]);l.78();l.79=z[g?"23":"1m"];l.23()}1S;25"3l":i=X(e,y,c);i="m"+i[0][0]+","+i[0][1]+" l"+i[1][0]+","+i[1][1]+" "+i[2][0]+","+i[2][1]+" 7a";b.1B(12(E){d(19).1x({7c:i,7d:z[E||!D?"23":"1m"]}).1f("5c",""+r)});1S;25"3t":b.3J("1q").1f({1n:"3O",17:0,16:0}).1B(12(E){15 C={x:e.1C==="x"?e.x==="17"?"1w":"17":e.x,y:e.1C==="y"?e.y==="16"?"1v":"16":e.y},x=e.x==="1I"?["17","1w",C.y,c,y]:["16","1v",C.x,y,c];E=z[!E&&D?"1m":"23"];e.x==="1I"||e.y==="1I"?d(19).1f("1m-"+x[2],x[3]+"2r 4g "+E).1f("1m-"+x[0],q(x[4]/2)+"2r 5d 3n").1f("1m-"+x[1],q(x[4]/2)+"2r 5d 3n"):d(19).1f("1m-1g",q(c/2)+"2r "+q(y/2)+"2r").1f("1m-"+C.x,q(y/2)+"2r 4g "+E).1f("1m-"+C.y,q(c/2)+"2r 4g "+E)});1S}11(G!=="2G"&&D){g=[D*2.75,D];g=e.1C==="y"?[e.x==="17"?g[1]:e.x==="1w"?-g[1]:0,e.y==="1v"?-g[0]:g[0]]:[e.x==="17"?g[0]:-g[0],e.y==="1v"?-g[1]:e.y==="16"?g[1]:0];b.5e(1).1f({17:g[0],16:g[1]})}18 k},1n:12(k,b){15 y=j.1l,c={},e=1E.2Y(0,n.1p),g,l;11(n.1A===m||!y)18 m;k=k||h.1A;g=k.1C;l=o[g==="x"?"1g":"1i"];d.1B(g==="y"?[k.x,k.y]:[k.y,k.x],12(i,r){15 q;11(r==="1I"){q=g==="y"?"17":"16";c[q]="50%";c["5j-"+q]=-1E.2M(l/2)+e}1e{q=p(k,r,t);11(i||D===O)q=p(k,r);1e{11(q)q=0;1e{q=d.24.7f;15 E=k.y+(q?"":"-")+k.x;q=(q?"-7g-":d.24.5g?"-5g-":"")+(q?"1m-5i-"+E:"1m-"+E+"-5i");q=1R((j.1O&&k.y==="16"?j.1O:j.1c).1f(q),10)||1R(v.1f(q),10)||0}q=e+q}c[r]=q}});c[k[g]]-=l;b&&y.1f({16:"",1v:"",17:"",1w:"",5j:""}).1f(c);18 c},2h:12(){j.1l&&j.1l.22();v.1X(".14-1l")}});h.2j()}12 51(f){15 a=19,p=f.2z.13.1P,h=f.1k,n=h.1b;a.34={"^13.1P.(2X|2q)$":12(){a.2j();h.29.2l(n.4i(":7i"))}};d.1F(a,{2j:12(){11(p.2X){n.1X(".2o").1s("3s.2o 4l.2o",12(j,v,s){j=j.1T.2H("1b","");d.2E(p[j])?p[j].27(h.29,s,v):a[j](s)});a.2L();p.2q===t&&h.29.1X(".2o"+f.1u).1s("4e.2o"+f.1u,12(){f.1a.27(f)})}},2L:12(){15 j=d("#14-29");11(j.1t)h.29=j;1e{h.29=d("<2w />",{1u:"#14-29".3j(1),1f:{1n:"3O",16:0,17:0,3k:"7j",3q:1R(n.1f("z-5o"),10)-1}}).30(1D.35);d(K).1s("2A.2o",12(){h.29.1f({1i:1E.2Y(d(K).1i(),d(1D).1i()),1g:1E.2Y(d(K).1g(),d(1D).1g())})}).2D("2A")}},2l:12(j){15 v=h.29,s=f.2z.13.1P.2m,o=j?"13":"1a";v.4k(t,m);11(d.2E(s))s.27(v,j);1e s===m?v[o]():v.5m(3L,j?0.7:0,12(){j||d(19).1a()})},13:12(){a.2l(t)},1a:12(){a.2l(m)},2h:12(){15 j=t;d("*").1B(12(){15 v=d(19).21("14");11(v&&v.1u!==f.1u&&v.2z.13.1P)18 j=m});11(j){h.29.22();d(K).1X(".2o")}1e h.29.1X(".2o"+f.1u);n.1X("3s.2o 4l.2o")}});a.2j()}12 4F(f){15 a=19,p=f.1k,h=p.1b,n=".2i-"+f.1u,j="4n"+n+" 3s"+n;d.1F(a,{2j:12(){p.2i=d(\'<3R 1V="1J-1b-2i" 7l="0" 5n="-1" 7m="7n:\\\'\\\';" 1q="3k:3N; 1n:3O; z-5o:-1; 3F:5p(3P=0);">\');p.2i.30(h);h.1s(j,a.2F)},2F:12(){15 v=f.3U("4p"),s=f.1j.1l,o=f.1k.1l,z;z=1R(h.1f("1m-17-1g"),10)||0;z={17:-z,16:-z};11(s&&o){s=s.1A.1C==="x"?["1g","17"]:["1i","16"];z[s[1]]-=o[s[0]]()}p.2i.1f(z).1f(v)},2h:12(){a.3R.22();h.1X(j)}});a.2j()}15 t=5l,m=3S,F=4q,H="1J-1b",W="1J-2B",M="1J-31-2W",Q=".14."+H,T=H+"-26",V="-5r";d.1d.14=12(f,a,p){15 h=2U(f).2y(),n=F,j=h==="4h"?[t]:d.5s(2N).4r(1,10),v=j[j.1t-1],s;11(!2N.1t&&19.21("14")||h==="5t")18(s=19.21("14"))?s:O;1e 11("1Q"===1o f){19.1B(12(){15 o=d(19).21("14");11(!o)18 t;11(/3y|32/.1N(h)&&a)11(p!==O)o.32(a,p);1e n=o.3U(a);1e{11(!o.1H&&(h==="13"||h==="2l")){11(v&&v.5u)o.1z.1y=v;o.2a(1)}1e 11(h==="5v"){h="4h";j=[m]}o[h]&&o[h].3d(o[h],j)}});18 n!==F?n:19}1e 11("1G"===1o f||!2N.1t){s=U(d.1F(t,{},f));18 d.1d.14.1s.27(19,s,v)}};d.1d.14.1s=12(f,a){18 19.1B(12(){12 p(z){12 D(){o.2a(1o z==="1G"||h.13.2S);n.13.1X(j.13);n.1a.1X(j.1a)}11(o.1z.2W)18 m;o.1z.1y=d.1F({},z);11(h.13.2u>0){1Z(o.1K.13);o.1K.13=3m(D,h.13.2u);j.13!==j.1a&&n.1a.1s(j.1a,12(){1Z(o.1K.13)})}1e D()}15 h,n,j,v=f.1u=!f.1u||f.1u===m||f.1u.1t<1||d("#"+H+"-"+f.1u).1t?d.1d.14.41++:f.1u,s=".14-"+v+"-2L",o=Z.27(19,v,f);11(o===m)18 t;h=o.2z;d.1B(d.1d.14.1j,12(){19.2C==="2C"&&19(o)});n={13:h.13.1h,1a:h.1a.1h};j={13:2U(h.13.1y).2H(" ",s+" ")+s,1a:2U(h.1a.1y).2H(" ",s+" ")+s};n.13.1s(j.13,p);11(h.13.2S||h.59)p(a)})};d.1B({1x:12(f){15 a=d(19),p=a.21("14");18 2N.1t===1&&f==="1r"&&p&&p.1H===t?a.21("4c"):F},22:d.1J?F:12(f,a){d(19).1B(12(){11(!a)11(!f||d.3F(f,[19]).1t)d("*",19).2Z(19).1B(12(){d(19).5V("22")})})}},12(f,a){11(!a)18 t;d.1d["4y"+f]=d.1d[f];d.1d[f]=12(){18 a.3d(19,2N)||d.1d["4y"+f].3d(19,2N)}});d(1D).2S(12(){15 f=1D.35;d(f).1x("3W",12(a,p){18!p?"64":p});d(1D).1s("43.14",12(a){d.1d.14.2n={3A:a.3A,3T:a.3T}});1D.3V===O&&1D.6a("26",12(a){11(a&&a.1h)1D.3V=a.1h===1D?f:a.1h},5l)});d.1d.14.3H="2.0.6f";d.1d.14.41=0;d.1d.14.4G="4e 6h 4b 4J 43 4m 3p".3f(" ");d.1d.14.4K=6m;d.1d.14.1j={2J:12(f){f=2U(f).2H(/([A-Z])/," $1").2H(/6o/6p,"1I").2y();19.x=(f.49(/17|1w/i)||f.49(/1I/)||["3G"])[0].2y();19.y=(f.49(/16|1v|1I/i)||["3G"])[0].2y();19.1C=f.2R(0).46(/^(t|b)/)>-1?"y":"x";19.1Q=12(){18 19.1C==="y"?19.y+19.x:19.x+19.y};19.4S=12(){15 a=19.x.3j(0,1),p=19.y.3j(0,1);18 a===p?a:a==="c"||a!=="c"&&p!=="c"?p+a:a+p}},4X:6D((/6F.+6J ([0-6N]{3}).*6Q.*6S/i.6U(6W.6Y)||[0,"70"])[1].2H("72","."))<4.1};d.1d.14.3o={59:m,1u:m,4d:t,2c:{1T:"1V"},1c:{1L:t,1x:"1r",1r:{1L:m,1Y:m}},1n:{1W:"16 17",2s:"1v 1w",1h:m,1M:m,2e:m,2F:{x:0,y:0,2n:t,2A:t},2m:t},13:{1h:m,1y:"3p",2m:t,2u:3L,5k:m,2S:m},1a:{1h:m,1y:"4m",2m:t,2u:0,2v:m,2p:m},1q:{3v:"",2B:m},4f:{2a:F,3Q:F,13:F,1a:F,2l:F,26:F,2q:F}};d.1d.14.1j.1U=12(f){15 a=f.1j.1U;18"1G"===1o a?a:f.1j.1U=28 $(f)};d.1d.14.1j.1U.2C="2a";d.1d.14.1j.1U.38=12(f){15 a=f.1c;11(a&&"1U"2g a){a=a.1U;11(1o a!=="1G")a=f.1c.1U={3x:a};11("33"!==1o a.2k&&a.2k)a.2k=!!a.2k}};d.1F(t,d.1d.14.3o,{1c:{1U:{2k:t}}});d.1d.14.1j.1l=12(f){15 a=f.1j.1l;18"1G"===1o a?a:f.1j.1l=28 4t(f)};d.1d.14.1j.1l.2C="2a";d.1d.14.1j.1l.38=12(f){15 a=f.1q;11(a&&"1l"2g a){a=f.1q.1l;11(1o a!=="1G")f.1q.1l={1A:a};11(!/1Q|33/i.1N(1o a.1A))a.1A=t;11(1o a.2I!=="1Q")a.2I=t;11(!/2G|3t/i.1N(a.2I))a.2I=t;1o a.1g!=="2V"&&2O a.1g;1o a.1i!=="2V"&&2O a.1i;1o a.1m!=="2V"&&a.1m!==t&&2O a.1m;1o a.1p!=="2V"&&2O a.1p}};d.1F(t,d.1d.14.3o,{1q:{1l:{1A:t,3B:m,2I:t,1g:8,1i:8,1m:t,1p:0}}});d.1d.14.1j.40=12(f,a){12 p(G,k){2K(15 b=0,y=1,c=1,e=0,g=0,l=G.1g,i=G.1i;l>0&&i>0&&y>0&&c>0;){l=1E.2M(l/2);i=1E.2M(i/2);11(a.x==="17")y=l;1e 11(a.x==="1w")y=G.1g-l;1e y+=1E.2M(l/2);11(a.y==="16")c=i;1e 11(a.y==="1v")c=G.1i-i;1e c+=1E.2M(i/2);2K(b=k.1t;b--;){11(k.1t<2)1S;e=k[b][0]-G.1p.17;g=k[b][1]-G.1p.16;11(a.x==="17"&&e>=y||a.x==="1w"&&e<=y||a.x==="1I"&&(eG.1g-y)||a.y==="16"&&g>=c||a.y==="1v"&&g<=c||a.y==="1I"&&(gG.1i-c))k.6k(b,1)}}18{17:k[0][0],16:k[0][1]}}15 h=f.1x("47").2y(),n=f.1x("6u").3f(","),j=[],v=d(\'3a[6A="#\'+f.6G("5f").1x("4Z")+\'"]\'),s=v.1p(),o={1g:0,1i:0,1p:{16:52,1w:0,1v:0,17:52}},z=0,D=0;s.17+=1E.39((v.37()-v.1g())/2);s.16+=1E.39((v.2P()-v.1i())/2);11(h==="4s")2K(z=n.1t;z--;){D=[1R(n[--z],10),1R(n[z+1],10)];11(D[0]>o.1p.1w)o.1p.1w=D[0];11(D[0]o.1p.1v)o.1p.1v=D[1];11(D[1]35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('"5v 5w";(12(c,K,P){12 U(e){18 a;11(!e)17 m;11("1G"!==1l e.2g)e.2g={1T:e.2g};11("1b"2j e){11("1G"!==1l e.1b||e.1b.2f)e.1b={1M:e.1b};a=e.1b.1M||m;11(!c.2J(a)&&(!a&&!a.1s||a.1r<1||"1G"===1l a&&!a.2f))a=e.1b.1M=m;11("1p"2j e.1b&&"1G"!==1l e.1b.1p)e.1b.1p={1M:e.1b.1p}}11("1m"2j e)11("1G"!==1l e.1m)e.1m={1W:e.1m,2v:e.1m};11("13"2j e)11("1G"!==1l e.13)e.13=e.13.2f?{1h:e.13}:{1y:e.13};11("1a"2j e)11("1G"!==1l e.1a)e.1a=e.1a.2f?{1h:e.1a}:{1y:e.1a};11("1n"2j e)11("1G"!==1l e.1n)e.1n={3v:e.1n};c.1A(c.1c.14.1i,12(){19.3h&&19.3h(e)});17 e}12 Y(e,a,p){12 h(b){18 f,i=b.3e("."),l=a[i[0]];2F(b=1;b",{"1S":"1J-3b-4a "+(a.1n.2D?"":H+"-3y"),1p:"5A"}).5B(c("<5C />",{"1S":"1J-3y 1J-3y-5D",3j:"&5E;"}));b.1X.4X(b.1O).1s("3Z","1X").5d(12(i){c(19).2z("1J-3b-5d",i.1T==="3r")}).42(12(i){g.2r(M)||d.1a(i);17 m}).1q("43 5F 4J 5G 74",12(i){c(19).2z("1J-3b-5H 1J-3b-2a",/5I$/i.1N(i.1T))});d.3E()}12 z(){18 b=d.1B,f=H+"-"+d.1v+"-1p";b.1O&&s();b.1O=c("<2A />",{"1S":H+"-1O "+(a.1n.2D?"1J-2D-4v":"")}).3g(b.1p=c("<2A />",{1v:f,"1S":H+"-1p",3j:a.1b.1p.1M})).5J(b.1b);e.1s("39-53",f);11(a.1b.1p.1X)r();1d d.1H===u&&d.3E()}12 B(b){18 f=d.1B;11(!d.1H||!b)17 m;11(c.2J(b))b=b.27(e);b.2f&&b.1r>0?f.1b.5K().3g(b.1e({3u:"3N"})):f.1b.3j(b);g.3B("40",12(i){12 l(o){n=n.3C(o);11(n.1r===0){d.3E();d.1H===u&&d.2h(d.1x.1y);i()}}18 n=c("3c:3C([1g]):3C([1f])",d.1B.1b);n.1A(12(o,C){18 F=["5L","4P","3a","6o",""].5M(".14-5N ");c(19).1q(F,12(){1Z(d.1K.3c[o]);l(19)});(12 x(){11(C.1g)17 l(C);d.1K.3c[o]=34(x,20)})();17 u});n.1r===0&&l(n)});17 d}12 G(b,f,i,l){12 n(v){11(g.2r(M))17 m;D.13.2x("14-"+p+"-2i");1Z(d.1K.13);1Z(d.1K.1a);18 t=12(){d.13(v)};11(a.13.2t>0)d.1K.13=34(t,a.13.2t);1d t()}12 o(v){11(g.2r(M))17 m;18 t=c(v.3X||v.1h).4y(R)[0]===D.1w[0],Q=c(v.3X||v.1h)[0]===D.13[0];1Z(d.1K.13);1Z(d.1K.1a);11(a.1a.2s&&(A.1h==="2o"&&t||/2o(4A|4w|3Q)/.1N(v.1T)&&(t||Q))){v.6h();v.5O();17 m}g.4i(1,1);11(a.1a.2t>0)d.1K.1a=34(12(){d.1a(v)},a.1a.2t);1d d.1a(v)}12 C(v){11(g.2r(M))17 m;1Z(d.1K.2i);d.1K.2i=34(12(){d.1a(v)},a.1a.2i)}12 F(v){11(!d.1x.3Y){d.1x.3Y=1;j()&&d.2h(v);d.1x.3Y=0}}18 x=".14-"+p,A=a.1m,D={13:a.13.1h,1a:a.1a.1h,1L:A.1L[0]===y?1E:A.1L},L={13:2W(a.13.1y).3e(" "),1a:2W(a.1a.1y).3e(" ")},N=c.24.2M&&1Q(c.24.3F,10)===6;11(i){11(a.1a.2s){D.1a=D.1a.2Q(D.1w);g.1q("5P"+x,12(){g.2r(M)||1Z(d.1K.1a)})}g.1q("3r"+x+" 4m"+x,12(v){d[v.1T==="3r"?"2a":"2q"](v)})}11(f){11("2Z"===1l a.1a.2i){D.13.1q("14-"+p+"-2i",C);c.1A(c.1c.14.4H,12(v,t){D.1a.2Q(d.1B.1w).1q(t+x+"-2i",C)})}c.1A(L.1a,12(v,t){18 Q=c.5Q(t,L.13);11(Q>-1&&c(D.1a).2Q(D.13).1r===c(D.1a).1r||t==="55"){D.13.1q(t+x,12(I){j()?o(I):n(I)});2P L.13[Q]}1d D.1a.1q(t+x,o)})}b&&c.1A(L.13,12(v,t){D.13.1q(t+x,n)});11(l){11(A.2G.2y||A.2n)c(c.1y.5R.2y?A.2n:K).1q("2y"+x,F);11(A.2n||N&&g.1e("1m")==="2s")c(A.2n).1q("4j"+x,F);/55/i.1N(a.1a.1y)&&c(1E).1q("43"+x,12(v){c(v.1h).4y(R).1r===0&&c(v.1h).2Q(e).1r>1&&j()&&!g.2r(M)&&d.1a(v)});A.1h==="2o"&&c(1E).1q("4c"+x,12(v){11(A.2G.2o&&!g.2r(M)&&j())d.2h(v||c.1c.14.2o)})}}12 k(b,f,i,l){l=1Q(l,10)!==0;18 n=".14-"+p;f={13:b?a.13.1h:E,1a:f?a.1a.1h:E,1w:i?d.1B.1w:E,1b:i?d.1B.1b:E,1L:l?a.1m.1L[0]===y?1E:a.1m.1L:E,4n:l?K:E};11(d.1H)c([]).68(c.69([f.13,f.1a,f.1w,f.1L,f.1b,f.4n],12(){17 19!==4q})).1Y(n);1d b&&f.13.1Y(n+"-2K")}18 d=19,y=1E.36,g;d.1v=p;d.1H=m;d.1B={1h:e};d.1K={3c:[]};d.2B=a;d.1i={};d.1x={1y:{},1h:E,2Y:m,3H:y};c.1I(d,{26:12(b){11(d.1H)17 m;18 f=d.1B,i=c.30("5T");e.1s("39-51",H+"-"+p+"-1b");g=f.1w=c("<2A/>").1s({1v:H+"-"+p,3Z:"5U","1S":H+" 14 1J-4s-4z "+a.1n.3v,5n:-1}).2z(M,d.1x.2Y).21("14",d).3n(a.1m.1L).3g(f.1b=c("<2A />",{"1S":H+"-1b",1v:H+"-"+p+"-1b"}));d.1H=u;a.1b.1p.1M&&z();B(a.1b.1M);c.1A(c.1c.14.1i,12(){19.2C==="26"&&19(d)});G(1,1,1,1);c.1A(a.3P,12(l,n){11(n)g.1q(l==="2k"?"3t 4k":"1w"+l,n)});g.3B("40",12(l){i.3k=d.1x.1y;g.2x(i,[d]);11(a.13.2X||b){g.1a();d.13(d.1x.1y)}l()});17 d},3V:12(b){3M(b.2w()){22"4p":b={1g:g.2O(),1f:g.3i()};1U;22"1o":b=q(g[0],a.1m.1L);1U;4a:b=h(b.2w());b=b[0].1D?b[0].1R():b[0].2f?b[0]:b[0][b[1]];1U}17 b},31:12(b,f){b=b.2w();18 i=h(b),l=d.1B,n,o,C,F={5V:{"^1v$":12(){18 x=f===u?c.1c.14.41:f,A=H+"-"+x;11(x!==m&&x.1r>0&&!c("#"+A).1r){g[0].1v=A;l.1b[0].1v=A+"-1b";l.1p[0].1v=A+"-1p"}},"^1b.1M$":12(){B(f)},"^1b.1p.1M$":12(){11(d.1H)11(!d.1B.1p&&f){z();d.2h()}1d f?d.1B.1p.3j(f):s()},"^1b.1p.1X$":12(){18 x=d.1B.1X,A=d.1B.1p;11(d.1H)11(f){A||z();r()}1d x.25()},"^1m.(1W|2v)$":12(){18 x=/1W$/i.1N(b)?"1W":"2v";11("1R"===1l f)a.1m[x]=29 c.1c.14.1i.2L(f)},"^1m.1L$":12(){d.1H===u&&g.3n(f)},"^(13|1a).(1y|1h|2s|2t|2i)$":12(x,A,D,L){18 N=b.46(/2s/i)>-1?[0,[0,1,1,1]]:[b.3d(0,3),b.2T(0)==="s"?[1,0,0,0]:[0,1,0,0]];11(N[0])x[A]=L;k.35(d,N[1]);11(N[0])x[A]=D;G.35(d,N[1])},"^13.2X$":12(){d.1H===m&&d.13()},"^1n.3v$":12(){g.1s("1S",H+" 14 1J-4s-4z "+f)},"^1n.2D|1b.1p":w,"^3P.(26|13|3Q|1a|2a|2q)$":12(x,A,D){l.1w[(c.2J(f)?"":"5W")+"1q"]("1w"+A,D)},"^1m.(1W|2v|2G|1h|1L)|1n|1b":12(){d.2h()}}};c.1A(d.1i,12(x){11("1G"===1l 19.33)F[x]=19.33});n=i[0][i[1]];i[0][i[1]]=f.63?c(f):f;U(a);2F(o 2j F)2F(C 2j F[o])5X(C,"i").1N(b)&&F[o][C].27(d,i[0],i[1],f,n);17 d},2k:12(b,f){12 i(){11(b)c.24.2M&&g[0].1n.5a("3I");1d g.1e({3u:"3N",4B:"4C",1f:"",4f:"",16:V,15:V})}11(d.1H===m)17 m;18 l=b?"13":"1a",n=a[l],o=j();11((1l b).46("32|2Z"))b=!o;11(!o&&!b||g.4h(":5Y"))17 d;11(f){11(/5Z|60/.1N(f.1T)&&/4A|4w/.1N(d.1x.1y.1T)&&f.1h===a.13.1h[0]&&g.61(f.3X).1r)17 d;d.1x.1y=c.1I({},f)}o=c.30("1w"+l);o.3k=f?d.1x.1y:E;g.2x(o,[d,3L]);11(o.4d())17 d;11(b){g.1a().1e({4B:""});d.2a(f);g[0].2a();d.1x.3H.2a();d.2h(f,0);n.5l&&c(R).3C(g).14("1a")}1d{1Z(d.1K.13);d.2q(f)}g.1s("39-4C",64(!b));g.4i(1,1);11(c.2J(n.2m)){n.2m.27(g,d);g.3B("40",12(C){i.27(19,C);C()})}1d 11(n.2m===m){g[l]();i.27(g)}1d g.5m(3L,b?1:0,i);b&&n.1h.2x("14-"+p+"-2i");17 d},13:12(b){d.2k(u,b)},1a:12(b){d.2k(m,b)},2a:12(b){11(d.1H===m)17 m;18 f=c(R),i=1Q(g[0].1n.3s,10),l=c.1c.14.4K+f.1r;b=c.1I({},b);11(!g.2r(T)){11(i!==l){f.1A(12(){11(19.1n.3s>i)19.1n.3s-=1});c(R+"."+T).14("2q",b)}d.1x.3H=1E.3R;f=c.30("65");f.3k=b;g.2x(f,[d,l]);11(!f.4d())g.45(T)[0].1n.3s=l}17 d},2q:12(b){b=c.1I({},b);18 f;g.4N(T);f=c.30("66");f.3k=b;g.2x(f,[d]);d.1x.3H.2a()},2h:12(b,f){11(d.1H===m)17 m;18 i=a.1m.1h,l=a.1m,n=l.1W,o=l.2v,C=l.2G,F=g.3i(),x=g.2O(),A=0,D=0,L=c.30("4l"),N=g.1e("1m")==="2s",v=l.2n.2f?l.2n:c(K),t={16:0,15:0},Q={16:12(I){18 J=v.38,O=o.x==="16"?A:o.x==="1u"?-A:-A/2,S=J-I;J=I+F-v.1f-J;O=(n.x==="16"?F:n.x==="1u"?-F:-F/2)-(n.1D==="x"||n.x===n.y?O:0);11(S>0&&(n.x!=="16"||J>0))t.16-=O;1d 11(J>0&&(n.x!=="1u"||S>0))t.16-=(n.x==="1F"?-1:1)*O+2*C.x;11(t.16<0&&-t.16>J)t.16=I;17 t.16-I},15:12(I){18 J=v.3q,O=o.y==="15"?D:o.y==="1t"?-D:-D/2,S=J-I;J=I+x-v.1g-J;O=(n.y==="15"?x:n.y==="1t"?-x:-x/2)-(n.1D==="y"||n.x===n.y?O:0);11(S>0&&(n.y!=="15"||J>0))t.15-=O;1d 11(J>0&&(n.y!=="1t"||S>0))t.15-=(n.y==="1F"?-1:1)*O+2*C.y;11(t.15<0&&-t.15>J)t.15=I;17 t.15-I}};f=f===P||!!f||m;v=!v?m:{4I:v,1g:v[(v[0]===K?"h":"6a")+"6b"](),1f:v[(v[0]===K?"w":"6c")+"6d"](),38:v.38(),3q:v.3q()};11(i==="2o"){o={x:"16",y:"15"};b=b&&(b.1T==="2y"||b.1T==="4j")?d.1x.1y:C.2o||!b||!b.3A?c.1I({},c.1c.14.2o):b;t={15:b.3U,16:b.3A}}1d{11(i==="1y")i=b&&b.1h&&b.1T!=="4j"&&b.1T!=="2y"?d.1x.1h=c(b.1h):d.1x.1h;i=c(i).5g(0);11(i.1r===0)17 d;1d 11(i[0]===1E||i[0]===K){A=i.1f();D=i.1g();11(i[0]===K)t={15:N?0:v.3q,16:N?0:v.38}}1d 11(i.4h("6f")&&c.1c.14.1i.4o){t=c.1c.14.1i.4o(i,o);A=t.1f;D=t.1g;t=t.1o}1d{A=i.3i();D=i.2O();t=q(i[0],l.1L[0])}t.16+=o.x==="1u"?A:o.x==="1F"?A/2:0;t.15+=o.y==="1t"?D:o.y==="1F"?D/2:0}t.16+=C.x+(n.x==="1u"?-F:n.x==="1F"?-F/2:0);t.15+=C.y+(n.y==="1t"?-x:n.y==="1F"?-x/2:0);t.47=l.2n.2f&&i[0]!==K&&i[0]!==y?{16:Q.16(t.16),15:Q.15(t.15)}:{16:0,15:0};g.1s("1S",12(){17 c(19).1s("1S").2E(/1J-1w-5c-\\w+/i,"")}).45(H+"-5c-"+n.4T());L.3k=c.1I({},b);g.2x(L,[d,t,v.4I]);11(L.4d())17 d;2P t.47;11(!f||!6i(t.16,t.15))g.1e(t);1d 11(j()&&c.2J(l.2m)){l.2m.27(g,d,t);g.3B(12(I){c(19).1e({4f:"",1g:""});c.24.2M&&19.1n&&19.1n.5a("3I");I()})}17 d},3E:12(){11(!d.1H||!(c.24.2M&&1Q(c.24.3F.2T(0),10)<9))17 m;18 b=H+"-6l",f;g.1e({1f:"4L",1g:"4L"}).45(b);f={1g:g.2O(),1f:g.3i()};c.1A(["1f","1g"],12(i,l){18 n=1Q(g.1e("2N-"+l),10)||0,o=1Q(g.1e("4M-"+l),10)||0;f[l]=n+o?1C.4M(1C.2N(f[l],o),n):f[l]});g.1e(f).4N(b)},3W:12(b){18 f=M;11("32"!==1l b)b=!(g.2r(f)||d.1x.2Y);11(d.1H)g.2z(f,b);1d d.1x.2Y=!!b;17 d},2b:12(){18 b=e.21("44");11(d.1H){g.25();c.1A(d.1i,12(){19.2C==="26"&&19.2b()})}1Z(d.1K.13);1Z(d.1K.1a);k(1,1,1,1);e.4O("14");b&&e.1s("1p",b);e.3J("39-51");17 e}})}12 Z(e,a){18 p,h,q=c(19),j=c(1E.36),w=19===1E?j:q;h=q.2g?q.2g(a.2g):E;18 s=c.1I(u,{},c.1c.14.3p,a,U((h&&a.2g.1T==="6S"?h[a.2g.4Z]:E)||h));q.4O("2g");h=s.1m;11("32"===1l s.1b.1M)11(s.1b.1s!==m&&q.1s(s.1b.1s))s.1b.1M=q.1s(s.1b.1s);1d 17 m;11(h.1L===m)h.1L=j;11(h.1h===m)h.1h=w;11(s.13.1h===m)s.13.1h=w;11(s.1a.1h===m)s.1a.1h=w;11(s.1m.2n===u)s.1m.2n=h.1L;h.2v=29 c.1c.14.1i.2L(h.2v);h.1W=29 c.1c.14.1i.2L(h.1W);11(q.21("14"))11(s.4e)q.14("2b");1d 11(s.4e===m)17 m;q.1s("1p")&&q.21("44",q.1s("1p")).3J("1p");p=29 Y(q,s,e);q.21("14",p);q.1q("25.14",12(){p.2b()});17 p}12 $(e){18 a=19,p=e.1B.1w,h=e.2B.1b.1V;a.33={"^1b.1V":12(q,j){11(j==="2c")a.2c();1d h&&h.3w&&a.3a()}};c.1I(a,{2l:12(){11(h&&h.3w){a.3a();a.2c()}},2c:12(){h.2c?a.2b():p.1q("3t.1V",12(){a.3a()})},3a:12(){c.1V(c.1I({6p:12(q){e.31("1b.1M",q)},4P:12(q,j,w){e.31("1b.1M",j+": "+w)},6q:e},h));17 a},2b:12(){p.1Y(".1V")}});a.2l()}12 X(e,a,p){18 h=1C.37(a/2),q=1C.37(p/2);a={4W:[[0,0],[a,p],[a,0]],4Q:[[0,0],[a,0],[0,p]],4R:[[0,p],[a,0],[a,p]],4S:[[0,0],[0,p],[a,p]],6r:[[0,p],[h,0],[a,p]],6s:[[0,0],[a,0],[h,p]],6t:[[0,0],[a,q],[0,p]],6u:[[a,0],[a,p],[0,q]]};a.6w=a.4W;a.6x=a.4Q;a.6y=a.4R;a.6z=a.4S;17 a[e.1R()]}12 4t(e){12 a(k,d,y){11(j.1j){k=c.1I({},h.1z);d=y.47;18 g;11(h.1z.2s!==u){11(d.16)k.x=k.x==="1F"?d.16>0?"16":"1u":k.x==="16"?"1u":"16";11(d.15)k.y=k.y==="1F"?d.15>0?"15":"1t":k.y==="15"?"1t":"15";11(k.1R()!==s.1z&&(s.15!==d.15||s.16!==d.16))g=h.3f(k)}g||(g=h.1m(k,0));11(g.1u!==P)g.16=g.1u;11(g.1t!==P)g.15=g.1t;g.3x=1C.2N(0,q.1o);y.16-=g.16.2T?g.3x:(g.1u?-1:1)*g.16;y.15-=g.15.2T?g.3x:(g.1t?-1:1)*g.15;s.16=d.16;s.15=d.15;s.1z=k.1R()}}12 p(k,d,y){d=!d?k[k.1D]:d;d="1k-"+d+"-1f";k=1Q((j.1O&&k.y==="15"?j.1O:j.1b).1e(d),10);17(y?k||1Q(w.1e(d),10):k)||0}18 h=19,q=e.2B.1n.1j,j=e.1B,w=j.1w,s={15:0,16:0,1z:""},r={1f:q.1f,1g:q.1g},z={},B=q.1k||0,G=q.2H||m;h.1z=E;h.3z=E;h.33={"^1m.1W|1n.1j.(1z|3z|2H|1k)$":12(){h.2l()||h.2b();e.2h()},"^1n.1j.(1g|1f)$":12(){r={1f:q.1f,1g:q.1g};h.2K();h.3f();e.2h()},"^1b.1p.1M|1n.(3v|2D)$":12(){j.1j&&h.3f()}};c.1I(h,{2l:12(){18 k=h.4U();11(k){11(G!=="3o")G=c("<2I />")[0].4b?"2I":c.24.2M?"3l":"3o";h.2K();h.3f();w.1Y(".14-1j").1q("4l.14-1j",a)}17 k},4U:12(){18 k=q.1z,d=e.2B.1m,y=d.2v;d=d.1W.1R?d.1W.1R():d.1W;11(k===m||d===m&&y===m)17 m;1d 11(k===u)h.1z=29 c.1c.14.1i.2L(d);1d 11(!k.1R){h.1z=29 c.1c.14.1i.2L(k);h.1z.2s=u}17 h.1z.1R()!=="4x"},54:12(){18 k=j.1j.1e({6A:"",1k:""}),d=h.1z,y=d[d.1D],g="1k-"+y+"-2S";y="1k"+y.2T(0)+y.3d(1)+"6C";18 b=/6D?\\(0, 0, 0(, 0)?\\)|3m/i;d=j.1O&&(d.y==="15"||d.y==="1F"&&k.1m().15+r.1g/2+q.1o",{"1S":"1J-1w-1j"}).1e(r).4X(w);3M(G){22"2I":c(\'<2I 1g="\'+d+\'" 1f="\'+k+\'" />\').3n(j.1j)[0].4b("2d").58();1U;22"3l":k=\'<3l:49 6I="0,0" 6K="\'+k+" "+d+\'" 6L="3T" 1n="6N:3w(#4a#6P); 3u:6Q-3N; 1m:3O; 5e:3T; 16: 0; 15: 0; 1f:\'+k+"2u; 1g:"+d+\'2u;">\';j.1j.3j(B?k+=k:k);1U;22"3o":j.1j.3g(\'<2A 1S="1J-1w-1j-6T" />\').3g(B?\'<2A 1S="1J-1w-1j-1k" />\':"");1U}},3f:12(k){18 d=j.1j.6W(),y=r.1f,g=r.1g,b=q.3z,f,i,l,n,o;11(!k)k=h.1z;11(b===m)b=k;1d{b=29 c.1c.14.1i.2L(b);b.1D=k.1D;11(b.x==="3D")b.x=k.x;1d 11(b.y==="3D")b.y=k.y;1d 11(b.x===b.y)b[k.1D]=k[k.1D]}B=q.1k===u?p(k,E,u):q.1k;f=B>0?0:1;n=b.1R().6X("1F")>-1;o=1C[/b|r/.1N(b[b.1D==="y"?"x":"y"])?"37":"2R"];k=h.1m(k,1);h.54();3M(G){22"2I":i=d[0].4b("2d");i.56&&i.56();i.70(0,0,57,57);2F(l=X(b,y,g);f<2;f++){11(f){i.58();i.72(o((b.x==="16"?1:b.x==="1u"?-1:0)*(B+1)*(b.1D==="y"?0.5:1)),o((b.y==="15"?1:b.y==="1t"?-1:0)*(B+1)*(b.1D==="x"?0.5:1)))}i.73();i.76(l[0][0],l[0][1]);i.5b(l[1][0],l[1][1]);i.5b(l[2][0],l[2][1]);i.77();i.78=z[f?"23":"1k"];i.23()}1U;22"3l":l=X(b,y,g);l="m"+l[0][0]+","+l[0][1]+" l"+l[1][0]+","+l[1][1]+" "+l[2][0]+","+l[2][1]+" 79";d.1A(12(C){c(19).1s({7a:l,7c:z[C||!B?"23":"1k"]}).1e("5e",""+n)});1U;22"3o":d.3J("1n").1e({1m:"3O",16:0,15:0}).1A(12(C){18 F={x:b.1D==="x"?b.x==="16"?"1u":"16":b.x,y:b.1D==="y"?b.y==="15"?"1t":"15":b.y},x=b.x==="1F"?["16","1u",F.y,g,y]:["15","1t",F.x,y,g];C=z[!C&&B?"1k":"23"];b.x==="1F"||b.y==="1F"?c(19).1e("1k-"+x[2],x[3]+"2u 4g "+C).1e("1k-"+x[0],o(x[4]/2)+"2u 5f 3m").1e("1k-"+x[1],o(x[4]/2)+"2u 5f 3m"):c(19).1e("1k-1f",o(g/2)+"2u "+o(y/2)+"2u").1e("1k-"+F.x,o(y/2)+"2u 4g "+C).1e("1k-"+F.y,o(g/2)+"2u 4g "+C)});1U}11(G!=="2I"&&B){f=[B*2.75,B];f=b.1D==="y"?[b.x==="16"?f[1]:b.x==="1u"?-f[1]:0,b.y==="1t"?-f[0]:f[0]]:[b.x==="16"?f[0]:-f[0],b.y==="1t"?-f[1]:b.y==="15"?f[1]:0];d.5g(1).1e({16:f[0],15:f[1]})}17 k},1m:12(k,d){18 y=j.1j,g={},b=1C.2N(0,q.1o),f,i;11(q.1z===m||!y)17 m;k=k||h.1z;f=k.1D;i=r[f==="x"?"1f":"1g"];c.1A(f==="y"?[k.x,k.y]:[k.y,k.x],12(l,n){18 o;11(n==="1F"){o=f==="y"?"16":"15";g[o]="50%";g["5k-"+o]=-1C.2R(i/2)+b}1d{o=p(k,n,u);11(l||B===P)o=p(k,n);1d{11(o)o=0;1d{o=c.24.7e;18 C=k.y+(o?"":"-")+k.x;o=(o?"-7f-":c.24.5h?"-5h-":"")+(o?"1k-5j-"+C:"1k-"+C+"-5j");o=1Q((j.1O&&k.y==="15"?j.1O:j.1b).1e(o),10)||1Q(w.1e(o),10)||0}o=b+o}g[n]=o}});g[k[f]]-=i;d&&y.1e({15:"",1t:"",16:"",1u:"",5k:""}).1e(g);17 g},2b:12(){j.1j&&j.1j.25();w.1Y(".14-1j")}});h.2l()}12 4Y(e){18 a=19,p=e.2B.13.1P,h=e.1B,q=h.1w;a.33={"^13.1P.(2V|2q)$":12(){a.2l();h.28.2k(q.4h(":7g"))}};c.1I(a,{2l:12(){11(p.2V){q.1Y(".2p").1q("3t.2p 4k.2p",12(j,w,s){j=j.1T.2E("1w","");c.2J(p[j])?p[j].27(h.28,s,w):a[j](s)});a.2K();p.2q===u&&h.28.1Y(".2p"+e.1v).1q("42.2p"+e.1v,12(){e.1a.27(e)})}},2K:12(){18 j=c("#14-28");11(j.1r)h.28=j;1d{h.28=c("<2A />",{1v:"#14-28".3d(1),1e:{1m:"3O",15:0,16:0,3u:"7h",3s:1Q(q.1e("z-5o"),10)-1}}).3n(1E.36);c(K).1q("2y.2p",12(){h.28.1e({1g:1C.2N(c(K).1g(),c(1E).1g()),1f:1C.2N(c(K).1f(),c(1E).1f())})}).2x("2y")}},2k:12(j){18 w=h.28,s=e.2B.13.1P.2m,r=j?"13":"1a";w.4i(u,m);11(c.2J(s))s.27(w,j);1d s===m?w[r]():w.5m(3L,j?0.7:0,12(){j||c(19).1a()})},13:12(){a.2k(u)},1a:12(){a.2k(m)},2b:12(){18 j=u;c("*").1A(12(){18 w=c(19).21("14");11(w&&w.1v!==e.1v&&w.2B.13.1P)17 j=m});11(j){h.28.25();c(K).1Y(".2p")}1d h.28.1Y(".2p"+e.1v);q.1Y("3t.2p 4k.2p")}});a.2l()}12 4F(e){18 a=19,p=e.1B,h=p.1w,q=".2e-"+e.1v,j="4l"+q+" 3t"+q;c.1I(a,{2l:12(){p.2e=c(\'<3S 1S="1J-1w-2e" 7j="0" 5n="-1" 7l="7m:\\\'\\\';" 1n="3u:3N; 1m:3O; z-5o:-1; 3I:7o(4f=0);">\');p.2e.3n(h);h.1q(j,a.2G)},2G:12(){18 w=e.3V("4p"),s=e.1i.1j,r=e.1B.1j,z;z=1Q(h.1e("1k-16-1f"),10)||0;z={16:-z,15:-z};11(s&&r){s=s.1z.1D==="x"?["1f","16"]:["1g","15"];z[s[1]]-=r[s[0]]()}p.2e.1e(z).1e(w)},2b:12(){a.3S.25();h.1Y(j)}});a.2l()}18 u=4E,m=3T,E=4q,H="1J-1w",W="1J-2D",M="1J-3b-2Y",R=".14."+H,T=H+"-2a",V="-5q";c.1c.14=12(e,a,p){18 h=2W(e).2w(),q=E,j=h==="3W"?[u]:c.5r(2U).4D(1,10),w=j[j.1r-1],s;11(!2U.1r&&19.21("14")||h==="5s")17(s=19.21("14"))?s:P;1d 11("1R"===1l e){19.1A(12(){18 r=c(19).21("14");11(!r)17 u;11(/3x|31/.1N(h)&&a)11(p!==P)r.31(a,p);1d q=r.3V(a);1d{11(!r.1H&&(h==="13"||h==="2k")){11(w&&w.5t)r.1x.1y=w;r.26(1)}1d 11(h==="5u"){h="3W";j=[m]}r[h]&&r[h].35(r[h],j)}});17 q!==E?q:19}1d 11("1G"===1l e||!2U.1r){s=U(c.1I(u,{},e));17 c.1c.14.1q.27(19,s,w)}};c.1c.14.1q=12(e,a){17 19.1A(12(){12 p(z){12 B(){r.26(1l z==="1G"||h.13.2X);q.13.1Y(j.13);q.1a.1Y(j.1a)}11(r.1x.2Y)17 m;r.1x.1y=c.1I({},z);11(h.13.2t>0){1Z(r.1K.13);r.1K.13=34(B,h.13.2t);j.13!==j.1a&&q.1a.1q(j.1a,12(){1Z(r.1K.13)})}1d B()}18 h,q,j,w=e.1v=!e.1v||e.1v===m||e.1v.1r<1||c("#"+H+"-"+e.1v).1r?c.1c.14.41++:e.1v,s=".14-"+w+"-2K",r=Z.27(19,w,e);11(r===m)17 u;h=r.2B;c.1A(c.1c.14.1i,12(){19.2C==="2C"&&19(r)});q={13:h.13.1h,1a:h.1a.1h};j={13:2W(h.13.1y).2E(" ",s+" ")+s,1a:2W(h.1a.1y).2E(" ",s+" ")+s};q.13.1q(j.13,p);11(h.13.2X||h.59)p(a)})};c.1A({1s:12(e){18 a=c(19),p=a.21("14");17 2U.1r===1&&e==="1p"&&p&&p.1H===u?a.21("44"):E},25:c.1J?E:12(e,a){c(19).1A(12(){11(!a)11(!e||c.3I(e,[19]).1r)c("*",19).2Q(19).1A(12(){c(19).5S("25")})})}},12(e,a){11(!a)17 u;c.1c["4G"+e]=c.1c[e];c.1c[e]=12(){17 a.35(19,2U)||c.1c["4G"+e].35(19,2U)}});c(1E).2X(12(){18 e=1E.36;c(e).1s("3Z",12(a,p){17!p?"62":p});c(1E).1q("4c.14",12(a){c.1c.14.2o={3A:a.3A,3U:a.3U}});1E.3R===P&&1E.67("2a",12(a){11(a&&a.1h)1E.3R=a.1h===1E?e:a.1h},4E)});c.1c.14.3F="2.0.6e";c.1c.14.41=0;c.1c.14.4H="42 6g 43 4J 4c 4m 3r".3e(" ");c.1c.14.4K=6j;c.1c.14.1i={2L:12(e){e=2W(e).2E(/([A-Z])/," $1").2E(/6m/6n,"1F").2w();19.x=(e.48(/16|1u/i)||e.48(/1F/)||["3D"])[0].2w();19.y=(e.48(/15|1t|1F/i)||["3D"])[0].2w();19.1D=e.2T(0).46(/^(t|b)/)>-1?"y":"x";19.1R=12(){17 19.1D==="y"?19.y+19.x:19.x+19.y};19.4T=12(){18 a=19.x.3d(0,1),p=19.y.3d(0,1);17 a===p?a:a==="c"||a!=="c"&&p!=="c"?p+a:a+p}},4V:6E((/6F.+6J ([0-6M]{3}).*6O.*6R/i.6U(6V.6Y)||[0,"6Z"])[1].2E("71","."))<4.1};c.1c.14.3p={59:m,1v:m,4e:u,2g:{1T:"1S"},1b:{1M:u,1s:"1p",1p:{1M:m,1X:m}},1m:{1W:"15 16",2v:"1t 1u",1h:m,1L:m,2n:m,2G:{x:0,y:0,2o:u,2y:u},2m:u},13:{1h:m,1y:"3r",2m:u,2t:3L,5l:m,2X:m},1a:{1h:m,1y:"4m",2m:u,2t:0,2s:m,2i:m},1n:{3v:"",2D:m},3P:{26:E,3Q:E,13:E,1a:E,2k:E,2a:E,2q:E}};c.1c.14.1i.1V=12(e){18 a=e.1i.1V;17"1G"===1l a?a:e.1i.1V=29 $(e)};c.1c.14.1i.1V.2C="26";c.1c.14.1i.1V.3h=12(e){18 a=e.1b;11(a&&"1V"2j a){a=a.1V;11(1l a!=="1G")a=e.1b.1V={3w:a};11("32"!==1l a.2c&&a.2c)a.2c=!!a.2c}};c.1I(u,c.1c.14.3p,{1b:{1V:{2c:u}}});c.1c.14.1i.1j=12(e){18 a=e.1i.1j;17"1G"===1l a?a:e.1i.1j=29 4t(e)};c.1c.14.1i.1j.2C="26";c.1c.14.1i.1j.3h=12(e){18 a=e.1n;11(a&&"1j"2j a){a=e.1n.1j;11(1l a!=="1G")e.1n.1j={1z:a};11(!/1R|32/i.1N(1l a.1z))a.1z=u;11(1l a.2H!=="1R")a.2H=u;11(!/2I|3o/i.1N(a.2H))a.2H=u;1l a.1f!=="2Z"&&2P a.1f;1l a.1g!=="2Z"&&2P a.1g;1l a.1k!=="2Z"&&a.1k!==u&&2P a.1k;1l a.1o!=="2Z"&&2P a.1o}};c.1I(u,c.1c.14.3p,{1n:{1j:{1z:u,3z:m,2H:u,1f:8,1g:8,1k:u,1o:0}}});c.1c.14.1i.4o=12(e,a){12 p(G,k){2F(18 d=0,y=1,g=1,b=0,f=0,i=G.1f,l=G.1g;i>0&&l>0&&y>0&&g>0;){i=1C.2R(i/2);l=1C.2R(l/2);11(a.x==="16")y=i;1d 11(a.x==="1u")y=G.1f-i;1d y+=1C.2R(i/2);11(a.y==="15")g=l;1d 11(a.y==="1t")g=G.1g-l;1d g+=1C.2R(l/2);2F(d=k.1r;d--;){11(k.1r<2)1U;b=k[d][0]-G.1o.16;f=k[d][1]-G.1o.15;11(a.x==="16"&&b>=y||a.x==="1u"&&b<=y||a.x==="1F"&&(bG.1f-y)||a.y==="15"&&f>=g||a.y==="1t"&&f<=g||a.y==="1F"&&(fG.1g-g))k.6k(d,1)}}17{16:k[0][0],15:k[0][1]}}18 h=e.1s("49").2w(),q=e.1s("6v").3e(","),j=[],w=c(\'3c[6B="#\'+e.6G("5i").1s("4Z")+\'"]\'),s=w.1o(),r={1f:0,1g:0,1o:{15:52,1u:0,1t:0,16:52}},z=0,B=0;s.16+=1C.37((w.3i()-w.1f())/2);s.15+=1C.37((w.2O()-w.1g())/2);11(h==="4r")2F(z=q.1r;z--;){B=[1Q(q[--z],10),1Q(q[z+1],10)];11(B[0]>r.1o.1u)r.1o.1u=B[0];11(B[0]r.1o.1t)r.1o.1t=B[1];11(B[1] 0) { self.timers.hide = setTimeout(function(){ self.hide(event); }, options.hide.delay); @@ -428,7 +428,7 @@ function QTip(target, options, id) // Define inactive method function inactiveMethod(event) { - if(targets.tooltip.hasClass(disabled)) { return FALSE; } + if(tooltip.hasClass(disabled)) { return FALSE; } // Clear timer clearTimeout(self.timers.inactive); @@ -445,22 +445,22 @@ function QTip(target, options, id) } // Assign tooltip events - if(tooltip) { + if(tip) { // Enable hide.fixed if(options.hide.fixed) { // Add tooltip as a hide target targets.hide = targets.hide.add(targets.tooltip); // Clear hide timer on tooltip hover to prevent it from closing - targets.tooltip.bind('mouseover'+namespace, function() { - if(!targets.tooltip.hasClass(disabled)) { + tooltip.bind('mouseover'+namespace, function() { + if(!tooltip.hasClass(disabled)) { clearTimeout(self.timers.hide); } }); } // Focus/blur the tooltip - targets.tooltip.bind('mouseenter'+namespace+' mouseleave'+namespace, function(event) { + tooltip.bind('mouseenter'+namespace+' mouseleave'+namespace, function(event) { self[ event.type === 'mouseenter' ? 'focus' : 'blur' ](event); }); } @@ -516,15 +516,13 @@ function QTip(target, options, id) } // Adjust tooltip position on scroll if screen adjustment is enabled - if(posOptions.viewport || (IE6 && targets.tooltip.css('position') === 'fixed')) { + if(posOptions.viewport || (IE6 && tooltip.css('position') === 'fixed')) { $(posOptions.viewport).bind('scroll'+namespace, repositionMethod); } // Hide tooltip on document mousedown if unfocus events are enabled if((/unfocus/i).test(options.hide.event)) { $(document).bind('mousedown'+namespace, function(event) { - var tooltip = self.elements.tooltip; - if($(event.target).parents(selector).length === 0 && $(event.target).add(target).length > 1 && isVisible() && !tooltip.hasClass(disabled)) { self.hide(event); @@ -536,7 +534,7 @@ function QTip(target, options, id) if(posOptions.target === 'mouse') { $(document).bind('mousemove'+namespace, function(event) { // Update the tooltip position only if the tooltip is visible and adjustment is enabled - if(posOptions.adjust.mouse && !targets.tooltip.hasClass(disabled) && isVisible()) { + if(posOptions.adjust.mouse && !tooltip.hasClass(disabled) && isVisible()) { self.reposition(event || $.fn.qtip.mouse); } }); @@ -584,13 +582,15 @@ function QTip(target, options, id) var elements = self.elements, callback = $.Event('tooltiprender'); + // Add ARIA properties to target + target.attr('aria-describedby', uitooltip + '-' + id + '-content'); + // Create tooltip element - elements.tooltip = $('
') + tooltip = elements.tooltip = $('
') .attr({ 'id': uitooltip + '-'+id, 'role': 'alert', // Apparently "tooltip" doesn't work too well... so we'll use alert 'class': uitooltip + ' qtip ui-helper-reset ' + options.style.classes, - 'aria-describedby': uitooltip + '-' + self.id + '-content', 'tabindex': -1 }) .toggleClass(disabled, self.cache.disabled) @@ -621,7 +621,7 @@ function QTip(target, options, id) $.each(options.events, function(name, callback) { if(callback) { var events = name === 'toggle' ? 'tooltipshow tooltiphide' : 'tooltip'+name; - elements.tooltip.bind(events, callback); + tooltip.bind(events, callback); } }); @@ -630,14 +630,14 @@ function QTip(target, options, id) * * See: updateContent method */ - elements.tooltip.queue('fx', function(next) { + tooltip.queue('fx', function(next) { // Trigger tooltiprender event and pass original triggering event as original callback.originalEvent = self.cache.event; - elements.tooltip.trigger(callback, [self]); + tooltip.trigger(callback, [self]); // Update tooltip position and show tooltip if needed if(options.show.ready || show) { - elements.tooltip.hide(); + tooltip.hide(); self.show(self.cache.event); } @@ -649,8 +649,7 @@ function QTip(target, options, id) get: function(notation) { - var tooltip = self.elements.tooltip, - result, o; + var result, o; switch(notation.toLowerCase()) { @@ -680,7 +679,6 @@ function QTip(target, options, id) notation = notation.toLowerCase(); var option = convertNotation(notation), elems = self.elements, - tooltip = elems.tooltip, previous, category, rule, checks = { @@ -732,7 +730,7 @@ function QTip(target, options, id) // Style checks '^style.classes$': function() { - self.elements.tooltip.attr('class', uitooltip + ' qtip ui-helper-reset ' + value); + tooltip.attr('class', uitooltip + ' qtip ui-helper-reset ' + value); }, '^style.widget|content.title': setWidget, @@ -779,7 +777,6 @@ function QTip(target, options, id) if(self.rendered === FALSE) { return FALSE; } var type = state ? 'show' : 'hide', - tooltip = self.elements.tooltip, opts = options[type], visible = isVisible(), callback; @@ -885,8 +882,7 @@ function QTip(target, options, id) { if(self.rendered === FALSE) { return FALSE; } - var tooltip = self.elements.tooltip, - qtips = $(selector), + var qtips = $(selector), curIndex = parseInt(tooltip[0].style.zIndex, 10), newIndex = $.fn.qtip.zindex + qtips.length, cachedEvent = $.extend({}, event), @@ -928,8 +924,7 @@ function QTip(target, options, id) blur: function(event) { - var tooltip = self.elements.tooltip, - cachedEvent = $.extend({}, event), + var cachedEvent = $.extend({}, event), callback; // Set focused status to FALSE @@ -949,13 +944,12 @@ function QTip(target, options, id) if(self.rendered === FALSE) { return FALSE; } var target = options.position.target, - tooltip = self.elements.tooltip, posOptions = options.position, my = posOptions.my, at = posOptions.at, adjust = posOptions.adjust, - elemWidth = self.elements.tooltip.outerWidth(), - elemHeight = self.elements.tooltip.outerHeight(), + elemWidth = tooltip.outerWidth(), + elemHeight = tooltip.outerHeight(), targetWidth = 0, targetHeight = 0, callback = $.Event('tooltipmove'), @@ -1124,8 +1118,7 @@ function QTip(target, options, id) // Make sure tooltip is rendered and the browser needs the redraw if(!self.rendered || !($.browser.msie && parseInt($.browser.version.charAt(0), 10) < 9)) { return FALSE; } - var tooltip = self.elements.tooltip, - fluid = uitooltip + '-fluid', + var fluid = uitooltip + '-fluid', dimensions; // Reset the height and width and add the fluid class to reset max/min widths @@ -1153,8 +1146,7 @@ function QTip(target, options, id) disable: function(state) { - var tooltip = self.elements.tooltip, - c = disabled; + var c = disabled; if('boolean' !== typeof state) { state = !(tooltip.hasClass(c) || self.cache.disabled); @@ -1172,12 +1164,11 @@ function QTip(target, options, id) destroy: function() { - var elements = self.elements, - oldtitle = elements.target.data('oldtitle'); + var oldtitle = target.data('oldtitle'); // Destroy tooltip and any associated plugins if rendered if(self.rendered) { - elements.tooltip.remove(); + tooltip.remove(); $.each(self.plugins, function() { if(this.initialize === 'render') { this.destroy(); }