").attr({id:i,role:"tooltip"}).addClass("ui-tooltip ui-widget ui-corner-all ui-widget-content "+(this.options.tooltipClass||""));return t("
").addClass("ui-tooltip-content").appendTo(n),n.appendTo(this.document[0].body),this.tooltips[i]=e,n},_find:function(e){var i=e.data("ui-tooltip-id");return i?t("#"+i):t()},_removeTooltip:function(t){t.remove(),delete this.tooltips[t.attr("id")]},_destroy:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event("blur");n.target=n.currentTarget=s[0],e.close(n,!0),t("#"+i).remove(),s.data("ui-tooltip-title")&&(s.attr("title",s.data("ui-tooltip-title")),s.removeData("ui-tooltip-title"))})}})})(jQuery);(function(t,e){var i="ui-effects-";t.effects={effect:{}},function(t,e){function i(t,e,i){var s=u[e.type]||{};return null==t?i||!e.def?null:e.def:(t=s.floor?~~t:parseFloat(t),isNaN(t)?e.def:s.mod?(t+s.mod)%s.mod:0>t?0:t>s.max?s.max:t)}function s(i){var s=h(),n=s._rgba=[];return i=i.toLowerCase(),f(l,function(t,a){var o,r=a.re.exec(i),l=r&&a.parse(r),h=a.space||"rgba";return l?(o=s[h](l),s[c[h].cache]=o[c[h].cache],n=s._rgba=o._rgba,!1):e}),n.length?("0,0,0,0"===n.join()&&t.extend(n,a.transparent),s):a[i]}function n(t,e,i){return i=(i+1)%1,1>6*i?t+6*(e-t)*i:1>2*i?e:2>3*i?t+6*(e-t)*(2/3-i):t}var a,o="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",r=/^([\-+])=\s*(\d+\.?\d*)/,l=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[t[1],t[2],t[3],t[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[2.55*t[1],2.55*t[2],2.55*t[3],t[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(t){return[t[1],t[2]/100,t[3]/100,t[4]]}}],h=t.Color=function(e,i,s,n){return new t.Color.fn.parse(e,i,s,n)},c={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},u={"byte":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=h.support={},p=t("
")[0],f=t.each;p.style.cssText="background-color:rgba(1,1,1,.5)",d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,f(c,function(t,e){e.cache="_"+t,e.props.alpha={idx:3,type:"percent",def:1}}),h.fn=t.extend(h.prototype,{parse:function(n,o,r,l){if(n===e)return this._rgba=[null,null,null,null],this;(n.jquery||n.nodeType)&&(n=t(n).css(o),o=e);var u=this,d=t.type(n),p=this._rgba=[];return o!==e&&(n=[n,o,r,l],d="array"),"string"===d?this.parse(s(n)||a._default):"array"===d?(f(c.rgba.props,function(t,e){p[e.idx]=i(n[e.idx],e)}),this):"object"===d?(n instanceof h?f(c,function(t,e){n[e.cache]&&(u[e.cache]=n[e.cache].slice())}):f(c,function(e,s){var a=s.cache;f(s.props,function(t,e){if(!u[a]&&s.to){if("alpha"===t||null==n[t])return;u[a]=s.to(u._rgba)}u[a][e.idx]=i(n[t],e,!0)}),u[a]&&0>t.inArray(null,u[a].slice(0,3))&&(u[a][3]=1,s.from&&(u._rgba=s.from(u[a])))}),this):e},is:function(t){var i=h(t),s=!0,n=this;return f(c,function(t,a){var o,r=i[a.cache];return r&&(o=n[a.cache]||a.to&&a.to(n._rgba)||[],f(a.props,function(t,i){return null!=r[i.idx]?s=r[i.idx]===o[i.idx]:e})),s}),s},_space:function(){var t=[],e=this;return f(c,function(i,s){e[s.cache]&&t.push(i)}),t.pop()},transition:function(t,e){var s=h(t),n=s._space(),a=c[n],o=0===this.alpha()?h("transparent"):this,r=o[a.cache]||a.to(o._rgba),l=r.slice();return s=s[a.cache],f(a.props,function(t,n){var a=n.idx,o=r[a],h=s[a],c=u[n.type]||{};null!==h&&(null===o?l[a]=h:(c.mod&&(h-o>c.mod/2?o+=c.mod:o-h>c.mod/2&&(o-=c.mod)),l[a]=i((h-o)*e+o,n)))}),this[n](l)},blend:function(e){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),n=h(e)._rgba;return h(t.map(i,function(t,e){return(1-s)*n[e]+s*t}))},toRgbaString:function(){var e="rgba(",i=t.map(this._rgba,function(t,e){return null==t?e>2?1:0:t});return 1===i[3]&&(i.pop(),e="rgb("),e+i.join()+")"},toHslaString:function(){var e="hsla(",i=t.map(this.hsla(),function(t,e){return null==t&&(t=e>2?1:0),e&&3>e&&(t=Math.round(100*t)+"%"),t});return 1===i[3]&&(i.pop(),e="hsl("),e+i.join()+")"},toHexString:function(e){var i=this._rgba.slice(),s=i.pop();return e&&i.push(~~(255*s)),"#"+t.map(i,function(t){return t=(t||0).toString(16),1===t.length?"0"+t:t}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),h.fn.parse.prototype=h.fn,c.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e,i,s=t[0]/255,n=t[1]/255,a=t[2]/255,o=t[3],r=Math.max(s,n,a),l=Math.min(s,n,a),h=r-l,c=r+l,u=.5*c;return e=l===r?0:s===r?60*(n-a)/h+360:n===r?60*(a-s)/h+120:60*(s-n)/h+240,i=0===h?0:.5>=u?h/c:h/(2-c),[Math.round(e)%360,i,u,null==o?1:o]},c.hsla.from=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e=t[0]/360,i=t[1],s=t[2],a=t[3],o=.5>=s?s*(1+i):s+i-s*i,r=2*s-o;return[Math.round(255*n(r,o,e+1/3)),Math.round(255*n(r,o,e)),Math.round(255*n(r,o,e-1/3)),a]},f(c,function(s,n){var a=n.props,o=n.cache,l=n.to,c=n.from;h.fn[s]=function(s){if(l&&!this[o]&&(this[o]=l(this._rgba)),s===e)return this[o].slice();var n,r=t.type(s),u="array"===r||"object"===r?s:arguments,d=this[o].slice();return f(a,function(t,e){var s=u["object"===r?t:e.idx];null==s&&(s=d[e.idx]),d[e.idx]=i(s,e)}),c?(n=h(c(d)),n[o]=d,n):h(d)},f(a,function(e,i){h.fn[e]||(h.fn[e]=function(n){var a,o=t.type(n),l="alpha"===e?this._hsla?"hsla":"rgba":s,h=this[l](),c=h[i.idx];return"undefined"===o?c:("function"===o&&(n=n.call(this,c),o=t.type(n)),null==n&&i.empty?this:("string"===o&&(a=r.exec(n),a&&(n=c+parseFloat(a[2])*("+"===a[1]?1:-1))),h[i.idx]=n,this[l](h)))})})}),h.hook=function(e){var i=e.split(" ");f(i,function(e,i){t.cssHooks[i]={set:function(e,n){var a,o,r="";if("transparent"!==n&&("string"!==t.type(n)||(a=s(n)))){if(n=h(a||n),!d.rgba&&1!==n._rgba[3]){for(o="backgroundColor"===i?e.parentNode:e;(""===r||"transparent"===r)&&o&&o.style;)try{r=t.css(o,"backgroundColor"),o=o.parentNode}catch(l){}n=n.blend(r&&"transparent"!==r?r:"_default")}n=n.toRgbaString()}try{e.style[i]=n}catch(l){}}},t.fx.step[i]=function(e){e.colorInit||(e.start=h(e.elem,i),e.end=h(e.end),e.colorInit=!0),t.cssHooks[i].set(e.elem,e.start.transition(e.end,e.pos))}})},h.hook(o),t.cssHooks.borderColor={expand:function(t){var e={};return f(["Top","Right","Bottom","Left"],function(i,s){e["border"+s+"Color"]=t}),e}},a=t.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(jQuery),function(){function i(e){var i,s,n=e.ownerDocument.defaultView?e.ownerDocument.defaultView.getComputedStyle(e,null):e.currentStyle,a={};if(n&&n.length&&n[0]&&n[n[0]])for(s=n.length;s--;)i=n[s],"string"==typeof n[i]&&(a[t.camelCase(i)]=n[i]);else for(i in n)"string"==typeof n[i]&&(a[i]=n[i]);return a}function s(e,i){var s,n,o={};for(s in i)n=i[s],e[s]!==n&&(a[s]||(t.fx.step[s]||!isNaN(parseFloat(n)))&&(o[s]=n));return o}var n=["add","remove","toggle"],a={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(e,i){t.fx.step[i]=function(t){("none"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(jQuery.style(t.elem,i,t.end),t.setAttr=!0)}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.effects.animateClass=function(e,a,o,r){var l=t.speed(a,o,r);return this.queue(function(){var a,o=t(this),r=o.attr("class")||"",h=l.children?o.find("*").addBack():o;h=h.map(function(){var e=t(this);return{el:e,start:i(this)}}),a=function(){t.each(n,function(t,i){e[i]&&o[i+"Class"](e[i])})},a(),h=h.map(function(){return this.end=i(this.el[0]),this.diff=s(this.start,this.end),this}),o.attr("class",r),h=h.map(function(){var e=this,i=t.Deferred(),s=t.extend({},l,{queue:!1,complete:function(){i.resolve(e)}});return this.el.animate(this.diff,s),i.promise()}),t.when.apply(t,h.get()).done(function(){a(),t.each(arguments,function(){var e=this.el;t.each(this.diff,function(t){e.css(t,"")})}),l.complete.call(o[0])})})},t.fn.extend({addClass:function(e){return function(i,s,n,a){return s?t.effects.animateClass.call(this,{add:i},s,n,a):e.apply(this,arguments)}}(t.fn.addClass),removeClass:function(e){return function(i,s,n,a){return arguments.length>1?t.effects.animateClass.call(this,{remove:i},s,n,a):e.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(i){return function(s,n,a,o,r){return"boolean"==typeof n||n===e?a?t.effects.animateClass.call(this,n?{add:s}:{remove:s},a,o,r):i.apply(this,arguments):t.effects.animateClass.call(this,{toggle:s},n,a,o)}}(t.fn.toggleClass),switchClass:function(e,i,s,n,a){return t.effects.animateClass.call(this,{add:i,remove:e},s,n,a)}})}(),function(){function s(e,i,s,n){return t.isPlainObject(e)&&(i=e,e=e.effect),e={effect:e},null==i&&(i={}),t.isFunction(i)&&(n=i,s=null,i={}),("number"==typeof i||t.fx.speeds[i])&&(n=s,s=i,i={}),t.isFunction(s)&&(n=s,s=null),i&&t.extend(e,i),s=s||i.duration,e.duration=t.fx.off?0:"number"==typeof s?s:s in t.fx.speeds?t.fx.speeds[s]:t.fx.speeds._default,e.complete=n||i.complete,e}function n(e){return!e||"number"==typeof e||t.fx.speeds[e]?!0:"string"!=typeof e||t.effects.effect[e]?t.isFunction(e)?!0:"object"!=typeof e||e.effect?!1:!0:!0}t.extend(t.effects,{version:"1.10.3",save:function(t,e){for(var s=0;e.length>s;s++)null!==e[s]&&t.data(i+e[s],t[0].style[e[s]])},restore:function(t,s){var n,a;for(a=0;s.length>a;a++)null!==s[a]&&(n=t.data(i+s[a]),n===e&&(n=""),t.css(s[a],n))},setMode:function(t,e){return"toggle"===e&&(e=t.is(":hidden")?"show":"hide"),e},getBaseline:function(t,e){var i,s;switch(t[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=t[0]/e.height}switch(t[1]){case"left":s=0;break;case"center":s=.5;break;case"right":s=1;break;default:s=t[1]/e.width}return{x:s,y:i}},createWrapper:function(e){if(e.parent().is(".ui-effects-wrapper"))return e.parent();var i={width:e.outerWidth(!0),height:e.outerHeight(!0),"float":e.css("float")},s=t("
").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),n={width:e.width(),height:e.height()},a=document.activeElement;try{a.id}catch(o){a=document.body}return e.wrap(s),(e[0]===a||t.contains(e[0],a))&&t(a).focus(),s=e.parent(),"static"===e.css("position")?(s.css({position:"relative"}),e.css({position:"relative"})):(t.extend(i,{position:e.css("position"),zIndex:e.css("z-index")}),t.each(["top","left","bottom","right"],function(t,s){i[s]=e.css(s),isNaN(parseInt(i[s],10))&&(i[s]="auto")}),e.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),e.css(n),s.css(i).show()},removeWrapper:function(e){var i=document.activeElement;return e.parent().is(".ui-effects-wrapper")&&(e.parent().replaceWith(e),(e[0]===i||t.contains(e[0],i))&&t(i).focus()),e},setTransition:function(e,i,s,n){return n=n||{},t.each(i,function(t,i){var a=e.cssUnit(i);a[0]>0&&(n[i]=a[0]*s+a[1])}),n}}),t.fn.extend({effect:function(){function e(e){function s(){t.isFunction(a)&&a.call(n[0]),t.isFunction(e)&&e()}var n=t(this),a=i.complete,r=i.mode;(n.is(":hidden")?"hide"===r:"show"===r)?(n[r](),s()):o.call(n[0],i,s)}var i=s.apply(this,arguments),n=i.mode,a=i.queue,o=t.effects.effect[i.effect];return t.fx.off||!o?n?this[n](i.duration,i.complete):this.each(function(){i.complete&&i.complete.call(this)}):a===!1?this.each(e):this.queue(a||"fx",e)},show:function(t){return function(e){if(n(e))return t.apply(this,arguments);var i=s.apply(this,arguments);return i.mode="show",this.effect.call(this,i)}}(t.fn.show),hide:function(t){return function(e){if(n(e))return t.apply(this,arguments);var i=s.apply(this,arguments);return i.mode="hide",this.effect.call(this,i)}}(t.fn.hide),toggle:function(t){return function(e){if(n(e)||"boolean"==typeof e)return t.apply(this,arguments);var i=s.apply(this,arguments);return i.mode="toggle",this.effect.call(this,i)}}(t.fn.toggle),cssUnit:function(e){var i=this.css(e),s=[];return t.each(["em","px","%","pt"],function(t,e){i.indexOf(e)>0&&(s=[parseFloat(i),e])}),s}})}(),function(){var e={};t.each(["Quad","Cubic","Quart","Quint","Expo"],function(t,i){e[i]=function(e){return Math.pow(e,t+2)}}),t.extend(e,{Sine:function(t){return 1-Math.cos(t*Math.PI/2)},Circ:function(t){return 1-Math.sqrt(1-t*t)},Elastic:function(t){return 0===t||1===t?t:-Math.pow(2,8*(t-1))*Math.sin((80*(t-1)-7.5)*Math.PI/15)},Back:function(t){return t*t*(3*t-2)},Bounce:function(t){for(var e,i=4;((e=Math.pow(2,--i))-1)/11>t;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*e-2)/22-t,2)}}),t.each(e,function(e,i){t.easing["easeIn"+e]=i,t.easing["easeOut"+e]=function(t){return 1-i(1-t)},t.easing["easeInOut"+e]=function(t){return.5>t?i(2*t)/2:1-i(-2*t+2)/2}})}()})(jQuery);(function(t){var e=/up|down|vertical/,i=/up|left|vertical|horizontal/;t.effects.effect.blind=function(s,n){var a,o,r,l=t(this),h=["position","top","bottom","left","right","height","width"],c=t.effects.setMode(l,s.mode||"hide"),u=s.direction||"up",d=e.test(u),p=d?"height":"width",f=d?"top":"left",g=i.test(u),m={},v="show"===c;l.parent().is(".ui-effects-wrapper")?t.effects.save(l.parent(),h):t.effects.save(l,h),l.show(),a=t.effects.createWrapper(l).css({overflow:"hidden"}),o=a[p](),r=parseFloat(a.css(f))||0,m[p]=v?o:0,g||(l.css(d?"bottom":"right",0).css(d?"top":"left","auto").css({position:"absolute"}),m[f]=v?r:o+r),v&&(a.css(p,0),g||a.css(f,r+o)),a.animate(m,{duration:s.duration,easing:s.easing,queue:!1,complete:function(){"hide"===c&&l.hide(),t.effects.restore(l,h),t.effects.removeWrapper(l),n()}})}})(jQuery);(function(t){t.effects.effect.bounce=function(e,i){var s,n,a,o=t(this),r=["position","top","bottom","left","right","height","width"],l=t.effects.setMode(o,e.mode||"effect"),h="hide"===l,c="show"===l,u=e.direction||"up",d=e.distance,p=e.times||5,f=2*p+(c||h?1:0),g=e.duration/f,m=e.easing,v="up"===u||"down"===u?"top":"left",_="up"===u||"left"===u,b=o.queue(),y=b.length;for((c||h)&&r.push("opacity"),t.effects.save(o,r),o.show(),t.effects.createWrapper(o),d||(d=o["top"===v?"outerHeight":"outerWidth"]()/3),c&&(a={opacity:1},a[v]=0,o.css("opacity",0).css(v,_?2*-d:2*d).animate(a,g,m)),h&&(d/=Math.pow(2,p-1)),a={},a[v]=0,s=0;p>s;s++)n={},n[v]=(_?"-=":"+=")+d,o.animate(n,g,m).animate(a,g,m),d=h?2*d:d/2;h&&(n={opacity:0},n[v]=(_?"-=":"+=")+d,o.animate(n,g,m)),o.queue(function(){h&&o.hide(),t.effects.restore(o,r),t.effects.removeWrapper(o),i()}),y>1&&b.splice.apply(b,[1,0].concat(b.splice(y,f+1))),o.dequeue()}})(jQuery);(function(t){t.effects.effect.clip=function(e,i){var s,n,a,o=t(this),r=["position","top","bottom","left","right","height","width"],l=t.effects.setMode(o,e.mode||"hide"),h="show"===l,c=e.direction||"vertical",u="vertical"===c,d=u?"height":"width",p=u?"top":"left",f={};t.effects.save(o,r),o.show(),s=t.effects.createWrapper(o).css({overflow:"hidden"}),n="IMG"===o[0].tagName?s:o,a=n[d](),h&&(n.css(d,0),n.css(p,a/2)),f[d]=h?a:0,f[p]=h?0:a/2,n.animate(f,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){h||o.hide(),t.effects.restore(o,r),t.effects.removeWrapper(o),i()}})}})(jQuery);(function(t){t.effects.effect.drop=function(e,i){var s,n=t(this),a=["position","top","bottom","left","right","opacity","height","width"],o=t.effects.setMode(n,e.mode||"hide"),r="show"===o,l=e.direction||"left",h="up"===l||"down"===l?"top":"left",c="up"===l||"left"===l?"pos":"neg",u={opacity:r?1:0};t.effects.save(n,a),n.show(),t.effects.createWrapper(n),s=e.distance||n["top"===h?"outerHeight":"outerWidth"](!0)/2,r&&n.css("opacity",0).css(h,"pos"===c?-s:s),u[h]=(r?"pos"===c?"+=":"-=":"pos"===c?"-=":"+=")+s,n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){"hide"===o&&n.hide(),t.effects.restore(n,a),t.effects.removeWrapper(n),i()}})}})(jQuery);(function(t){t.effects.effect.explode=function(e,i){function s(){b.push(this),b.length===u*d&&n()}function n(){p.css({visibility:"visible"}),t(b).remove(),g||p.hide(),i()}var a,o,r,l,h,c,u=e.pieces?Math.round(Math.sqrt(e.pieces)):3,d=u,p=t(this),f=t.effects.setMode(p,e.mode||"hide"),g="show"===f,m=p.show().css("visibility","hidden").offset(),v=Math.ceil(p.outerWidth()/d),_=Math.ceil(p.outerHeight()/u),b=[];for(a=0;u>a;a++)for(l=m.top+a*_,c=a-(u-1)/2,o=0;d>o;o++)r=m.left+o*v,h=o-(d-1)/2,p.clone().appendTo("body").wrap("
").css({position:"absolute",visibility:"visible",left:-o*v,top:-a*_}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:v,height:_,left:r+(g?h*v:0),top:l+(g?c*_:0),opacity:g?0:1}).animate({left:r+(g?0:h*v),top:l+(g?0:c*_),opacity:g?1:0},e.duration||500,e.easing,s)}})(jQuery);(function(t){t.effects.effect.fade=function(e,i){var s=t(this),n=t.effects.setMode(s,e.mode||"toggle");s.animate({opacity:n},{queue:!1,duration:e.duration,easing:e.easing,complete:i})}})(jQuery);(function(t){t.effects.effect.fold=function(e,i){var s,n,a=t(this),o=["position","top","bottom","left","right","height","width"],r=t.effects.setMode(a,e.mode||"hide"),l="show"===r,h="hide"===r,c=e.size||15,u=/([0-9]+)%/.exec(c),d=!!e.horizFirst,p=l!==d,f=p?["width","height"]:["height","width"],g=e.duration/2,m={},v={};t.effects.save(a,o),a.show(),s=t.effects.createWrapper(a).css({overflow:"hidden"}),n=p?[s.width(),s.height()]:[s.height(),s.width()],u&&(c=parseInt(u[1],10)/100*n[h?0:1]),l&&s.css(d?{height:0,width:c}:{height:c,width:0}),m[f[0]]=l?n[0]:c,v[f[1]]=l?n[1]:0,s.animate(m,g,e.easing).animate(v,g,e.easing,function(){h&&a.hide(),t.effects.restore(a,o),t.effects.removeWrapper(a),i()})}})(jQuery);(function(t){t.effects.effect.highlight=function(e,i){var s=t(this),n=["backgroundImage","backgroundColor","opacity"],a=t.effects.setMode(s,e.mode||"show"),o={backgroundColor:s.css("backgroundColor")};"hide"===a&&(o.opacity=0),t.effects.save(s,n),s.show().css({backgroundImage:"none",backgroundColor:e.color||"#ffff99"}).animate(o,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){"hide"===a&&s.hide(),t.effects.restore(s,n),i()}})}})(jQuery);(function(t){t.effects.effect.pulsate=function(e,i){var s,n=t(this),a=t.effects.setMode(n,e.mode||"show"),o="show"===a,r="hide"===a,l=o||"hide"===a,h=2*(e.times||5)+(l?1:0),c=e.duration/h,u=0,d=n.queue(),p=d.length;for((o||!n.is(":visible"))&&(n.css("opacity",0).show(),u=1),s=1;h>s;s++)n.animate({opacity:u},c,e.easing),u=1-u;n.animate({opacity:u},c,e.easing),n.queue(function(){r&&n.hide(),i()}),p>1&&d.splice.apply(d,[1,0].concat(d.splice(p,h+1))),n.dequeue()}})(jQuery);(function(t){t.effects.effect.puff=function(e,i){var s=t(this),n=t.effects.setMode(s,e.mode||"hide"),a="hide"===n,o=parseInt(e.percent,10)||150,r=o/100,l={height:s.height(),width:s.width(),outerHeight:s.outerHeight(),outerWidth:s.outerWidth()};t.extend(e,{effect:"scale",queue:!1,fade:!0,mode:n,complete:i,percent:a?o:100,from:a?l:{height:l.height*r,width:l.width*r,outerHeight:l.outerHeight*r,outerWidth:l.outerWidth*r}}),s.effect(e)},t.effects.effect.scale=function(e,i){var s=t(this),n=t.extend(!0,{},e),a=t.effects.setMode(s,e.mode||"effect"),o=parseInt(e.percent,10)||(0===parseInt(e.percent,10)?0:"hide"===a?0:100),r=e.direction||"both",l=e.origin,h={height:s.height(),width:s.width(),outerHeight:s.outerHeight(),outerWidth:s.outerWidth()},c={y:"horizontal"!==r?o/100:1,x:"vertical"!==r?o/100:1};n.effect="size",n.queue=!1,n.complete=i,"effect"!==a&&(n.origin=l||["middle","center"],n.restore=!0),n.from=e.from||("show"===a?{height:0,width:0,outerHeight:0,outerWidth:0}:h),n.to={height:h.height*c.y,width:h.width*c.x,outerHeight:h.outerHeight*c.y,outerWidth:h.outerWidth*c.x},n.fade&&("show"===a&&(n.from.opacity=0,n.to.opacity=1),"hide"===a&&(n.from.opacity=1,n.to.opacity=0)),s.effect(n)},t.effects.effect.size=function(e,i){var s,n,a,o=t(this),r=["position","top","bottom","left","right","width","height","overflow","opacity"],l=["position","top","bottom","left","right","overflow","opacity"],h=["width","height","overflow"],c=["fontSize"],u=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],d=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],p=t.effects.setMode(o,e.mode||"effect"),f=e.restore||"effect"!==p,g=e.scale||"both",m=e.origin||["middle","center"],v=o.css("position"),_=f?r:l,b={height:0,width:0,outerHeight:0,outerWidth:0};"show"===p&&o.show(),s={height:o.height(),width:o.width(),outerHeight:o.outerHeight(),outerWidth:o.outerWidth()},"toggle"===e.mode&&"show"===p?(o.from=e.to||b,o.to=e.from||s):(o.from=e.from||("show"===p?b:s),o.to=e.to||("hide"===p?b:s)),a={from:{y:o.from.height/s.height,x:o.from.width/s.width},to:{y:o.to.height/s.height,x:o.to.width/s.width}},("box"===g||"both"===g)&&(a.from.y!==a.to.y&&(_=_.concat(u),o.from=t.effects.setTransition(o,u,a.from.y,o.from),o.to=t.effects.setTransition(o,u,a.to.y,o.to)),a.from.x!==a.to.x&&(_=_.concat(d),o.from=t.effects.setTransition(o,d,a.from.x,o.from),o.to=t.effects.setTransition(o,d,a.to.x,o.to))),("content"===g||"both"===g)&&a.from.y!==a.to.y&&(_=_.concat(c).concat(h),o.from=t.effects.setTransition(o,c,a.from.y,o.from),o.to=t.effects.setTransition(o,c,a.to.y,o.to)),t.effects.save(o,_),o.show(),t.effects.createWrapper(o),o.css("overflow","hidden").css(o.from),m&&(n=t.effects.getBaseline(m,s),o.from.top=(s.outerHeight-o.outerHeight())*n.y,o.from.left=(s.outerWidth-o.outerWidth())*n.x,o.to.top=(s.outerHeight-o.to.outerHeight)*n.y,o.to.left=(s.outerWidth-o.to.outerWidth)*n.x),o.css(o.from),("content"===g||"both"===g)&&(u=u.concat(["marginTop","marginBottom"]).concat(c),d=d.concat(["marginLeft","marginRight"]),h=r.concat(u).concat(d),o.find("*[width]").each(function(){var i=t(this),s={height:i.height(),width:i.width(),outerHeight:i.outerHeight(),outerWidth:i.outerWidth()};f&&t.effects.save(i,h),i.from={height:s.height*a.from.y,width:s.width*a.from.x,outerHeight:s.outerHeight*a.from.y,outerWidth:s.outerWidth*a.from.x},i.to={height:s.height*a.to.y,width:s.width*a.to.x,outerHeight:s.height*a.to.y,outerWidth:s.width*a.to.x},a.from.y!==a.to.y&&(i.from=t.effects.setTransition(i,u,a.from.y,i.from),i.to=t.effects.setTransition(i,u,a.to.y,i.to)),a.from.x!==a.to.x&&(i.from=t.effects.setTransition(i,d,a.from.x,i.from),i.to=t.effects.setTransition(i,d,a.to.x,i.to)),i.css(i.from),i.animate(i.to,e.duration,e.easing,function(){f&&t.effects.restore(i,h)})})),o.animate(o.to,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){0===o.to.opacity&&o.css("opacity",o.from.opacity),"hide"===p&&o.hide(),t.effects.restore(o,_),f||("static"===v?o.css({position:"relative",top:o.to.top,left:o.to.left}):t.each(["top","left"],function(t,e){o.css(e,function(e,i){var s=parseInt(i,10),n=t?o.to.left:o.to.top;return"auto"===i?n+"px":s+n+"px"})})),t.effects.removeWrapper(o),i()}})}})(jQuery);(function(t){t.effects.effect.shake=function(e,i){var s,n=t(this),a=["position","top","bottom","left","right","height","width"],o=t.effects.setMode(n,e.mode||"effect"),r=e.direction||"left",l=e.distance||20,h=e.times||3,c=2*h+1,u=Math.round(e.duration/c),d="up"===r||"down"===r?"top":"left",p="up"===r||"left"===r,f={},g={},m={},v=n.queue(),_=v.length;for(t.effects.save(n,a),n.show(),t.effects.createWrapper(n),f[d]=(p?"-=":"+=")+l,g[d]=(p?"+=":"-=")+2*l,m[d]=(p?"-=":"+=")+2*l,n.animate(f,u,e.easing),s=1;h>s;s++)n.animate(g,u,e.easing).animate(m,u,e.easing);n.animate(g,u,e.easing).animate(f,u/2,e.easing).queue(function(){"hide"===o&&n.hide(),t.effects.restore(n,a),t.effects.removeWrapper(n),i()}),_>1&&v.splice.apply(v,[1,0].concat(v.splice(_,c+1))),n.dequeue()}})(jQuery);(function(t){t.effects.effect.slide=function(e,i){var s,n=t(this),a=["position","top","bottom","left","right","width","height"],o=t.effects.setMode(n,e.mode||"show"),r="show"===o,l=e.direction||"left",h="up"===l||"down"===l?"top":"left",c="up"===l||"left"===l,u={};t.effects.save(n,a),n.show(),s=e.distance||n["top"===h?"outerHeight":"outerWidth"](!0),t.effects.createWrapper(n).css({overflow:"hidden"}),r&&n.css(h,c?isNaN(s)?"-"+s:-s:s),u[h]=(r?c?"+=":"-=":c?"-=":"+=")+s,n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){"hide"===o&&n.hide(),t.effects.restore(n,a),t.effects.removeWrapper(n),i()}})}})(jQuery);(function(t){t.effects.effect.transfer=function(e,i){var s=t(this),n=t(e.to),a="fixed"===n.css("position"),o=t("body"),r=a?o.scrollTop():0,l=a?o.scrollLeft():0,h=n.offset(),c={top:h.top-r,left:h.left-l,height:n.innerHeight(),width:n.innerWidth()},d=s.offset(),u=t("
").appendTo(document.body).addClass(e.className).css({top:d.top-r,left:d.left-l,height:s.innerHeight(),width:s.innerWidth(),position:a?"fixed":"absolute"}).animate(c,e.duration,e.easing,function(){u.remove(),i()})}})(jQuery);
\ No newline at end of file
diff --git a/workflow/public_html/lib/mafe/mafe.css b/workflow/public_html/lib/mafe/mafe.css
new file mode 120000
index 000000000..a169c2502
--- /dev/null
+++ b/workflow/public_html/lib/mafe/mafe.css
@@ -0,0 +1 @@
+/var/www/michelangelofe/build/css/mafe.css
\ No newline at end of file
diff --git a/workflow/public_html/lib/mafe/mafe.js b/workflow/public_html/lib/mafe/mafe.js
new file mode 120000
index 000000000..7de0412a7
--- /dev/null
+++ b/workflow/public_html/lib/mafe/mafe.js
@@ -0,0 +1 @@
+/var/www/michelangelofe/build/js/mafe.js
\ No newline at end of file
diff --git a/workflow/public_html/lib/pmDraw/pmdraw.css b/workflow/public_html/lib/pmDraw/pmdraw.css
new file mode 120000
index 000000000..de9b67778
--- /dev/null
+++ b/workflow/public_html/lib/pmDraw/pmdraw.css
@@ -0,0 +1 @@
+/var/www/pmdraw/example-beta/css/style.css
\ No newline at end of file
diff --git a/workflow/public_html/lib/pmUI/pmui-1.0.0.css b/workflow/public_html/lib/pmUI/pmui-1.0.0.css
new file mode 120000
index 000000000..df06eb146
--- /dev/null
+++ b/workflow/public_html/lib/pmUI/pmui-1.0.0.css
@@ -0,0 +1 @@
+/var/www/pmui/build/css/pmui-1.0.0.css
\ No newline at end of file
diff --git a/workflow/public_html/lib/pmUI/pmui-1.0.0.js b/workflow/public_html/lib/pmUI/pmui-1.0.0.js
new file mode 120000
index 000000000..5fe6cbba0
--- /dev/null
+++ b/workflow/public_html/lib/pmUI/pmui-1.0.0.js
@@ -0,0 +1 @@
+/var/www/pmui/build/js/pmui-1.0.0.js
\ No newline at end of file
diff --git a/workflow/public_html/lib/pmUI/pmui-1.0.0.min.js b/workflow/public_html/lib/pmUI/pmui-1.0.0.min.js
new file mode 120000
index 000000000..85ae9e4ea
--- /dev/null
+++ b/workflow/public_html/lib/pmUI/pmui-1.0.0.min.js
@@ -0,0 +1 @@
+/var/www/pmui/build/js/min/pmui-1.0.0.min.js
\ No newline at end of file
diff --git a/workflow/public_html/lib/restClient/restclient.js b/workflow/public_html/lib/restClient/restclient.js
new file mode 120000
index 000000000..7e4a6a4a8
--- /dev/null
+++ b/workflow/public_html/lib/restClient/restclient.js
@@ -0,0 +1 @@
+/var/www/pmui/libraries/restclient/restclient.js
\ No newline at end of file
diff --git a/workflow/public_html/lib/translations.js b/workflow/public_html/lib/translations.js
new file mode 120000
index 000000000..ae6f2d1d4
--- /dev/null
+++ b/workflow/public_html/lib/translations.js
@@ -0,0 +1 @@
+/var/www/michelangelofe/translations.js
\ No newline at end of file
diff --git a/workflow/public_html/lib/underscore/underscore-min.js b/workflow/public_html/lib/underscore/underscore-min.js
new file mode 100644
index 000000000..d22f881bc
--- /dev/null
+++ b/workflow/public_html/lib/underscore/underscore-min.js
@@ -0,0 +1,6 @@
+// Underscore.js 1.5.2
+// http://underscorejs.org
+// (c) 2009-2013 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
+// Underscore may be freely distributed under the MIT license.
+(function(){var n=this,t=n._,r={},e=Array.prototype,u=Object.prototype,i=Function.prototype,a=e.push,o=e.slice,c=e.concat,l=u.toString,f=u.hasOwnProperty,s=e.forEach,p=e.map,h=e.reduce,v=e.reduceRight,g=e.filter,d=e.every,m=e.some,y=e.indexOf,b=e.lastIndexOf,x=Array.isArray,w=Object.keys,_=i.bind,j=function(n){return n instanceof j?n:this instanceof j?(this._wrapped=n,void 0):new j(n)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=j),exports._=j):n._=j,j.VERSION="1.5.2";var A=j.each=j.forEach=function(n,t,e){if(null!=n)if(s&&n.forEach===s)n.forEach(t,e);else if(n.length===+n.length){for(var u=0,i=n.length;i>u;u++)if(t.call(e,n[u],u,n)===r)return}else for(var a=j.keys(n),u=0,i=a.length;i>u;u++)if(t.call(e,n[a[u]],a[u],n)===r)return};j.map=j.collect=function(n,t,r){var e=[];return null==n?e:p&&n.map===p?n.map(t,r):(A(n,function(n,u,i){e.push(t.call(r,n,u,i))}),e)};var E="Reduce of empty array with no initial value";j.reduce=j.foldl=j.inject=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),h&&n.reduce===h)return e&&(t=j.bind(t,e)),u?n.reduce(t,r):n.reduce(t);if(A(n,function(n,i,a){u?r=t.call(e,r,n,i,a):(r=n,u=!0)}),!u)throw new TypeError(E);return r},j.reduceRight=j.foldr=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),v&&n.reduceRight===v)return e&&(t=j.bind(t,e)),u?n.reduceRight(t,r):n.reduceRight(t);var i=n.length;if(i!==+i){var a=j.keys(n);i=a.length}if(A(n,function(o,c,l){c=a?a[--i]:--i,u?r=t.call(e,r,n[c],c,l):(r=n[c],u=!0)}),!u)throw new TypeError(E);return r},j.find=j.detect=function(n,t,r){var e;return O(n,function(n,u,i){return t.call(r,n,u,i)?(e=n,!0):void 0}),e},j.filter=j.select=function(n,t,r){var e=[];return null==n?e:g&&n.filter===g?n.filter(t,r):(A(n,function(n,u,i){t.call(r,n,u,i)&&e.push(n)}),e)},j.reject=function(n,t,r){return j.filter(n,function(n,e,u){return!t.call(r,n,e,u)},r)},j.every=j.all=function(n,t,e){t||(t=j.identity);var u=!0;return null==n?u:d&&n.every===d?n.every(t,e):(A(n,function(n,i,a){return(u=u&&t.call(e,n,i,a))?void 0:r}),!!u)};var O=j.some=j.any=function(n,t,e){t||(t=j.identity);var u=!1;return null==n?u:m&&n.some===m?n.some(t,e):(A(n,function(n,i,a){return u||(u=t.call(e,n,i,a))?r:void 0}),!!u)};j.contains=j.include=function(n,t){return null==n?!1:y&&n.indexOf===y?n.indexOf(t)!=-1:O(n,function(n){return n===t})},j.invoke=function(n,t){var r=o.call(arguments,2),e=j.isFunction(t);return j.map(n,function(n){return(e?t:n[t]).apply(n,r)})},j.pluck=function(n,t){return j.map(n,function(n){return n[t]})},j.where=function(n,t,r){return j.isEmpty(t)?r?void 0:[]:j[r?"find":"filter"](n,function(n){for(var r in t)if(t[r]!==n[r])return!1;return!0})},j.findWhere=function(n,t){return j.where(n,t,!0)},j.max=function(n,t,r){if(!t&&j.isArray(n)&&n[0]===+n[0]&&n.length<65535)return Math.max.apply(Math,n);if(!t&&j.isEmpty(n))return-1/0;var e={computed:-1/0,value:-1/0};return A(n,function(n,u,i){var a=t?t.call(r,n,u,i):n;a>e.computed&&(e={value:n,computed:a})}),e.value},j.min=function(n,t,r){if(!t&&j.isArray(n)&&n[0]===+n[0]&&n.length<65535)return Math.min.apply(Math,n);if(!t&&j.isEmpty(n))return 1/0;var e={computed:1/0,value:1/0};return A(n,function(n,u,i){var a=t?t.call(r,n,u,i):n;a
e||r===void 0)return 1;if(e>r||e===void 0)return-1}return n.index-t.index}),"value")};var F=function(n){return function(t,r,e){var u={},i=null==r?j.identity:k(r);return A(t,function(r,a){var o=i.call(e,r,a,t);n(u,o,r)}),u}};j.groupBy=F(function(n,t,r){(j.has(n,t)?n[t]:n[t]=[]).push(r)}),j.indexBy=F(function(n,t,r){n[t]=r}),j.countBy=F(function(n,t){j.has(n,t)?n[t]++:n[t]=1}),j.sortedIndex=function(n,t,r,e){r=null==r?j.identity:k(r);for(var u=r.call(e,t),i=0,a=n.length;a>i;){var o=i+a>>>1;r.call(e,n[o])=0})})},j.difference=function(n){var t=c.apply(e,o.call(arguments,1));return j.filter(n,function(n){return!j.contains(t,n)})},j.zip=function(){for(var n=j.max(j.pluck(arguments,"length").concat(0)),t=new Array(n),r=0;n>r;r++)t[r]=j.pluck(arguments,""+r);return t},j.object=function(n,t){if(null==n)return{};for(var r={},e=0,u=n.length;u>e;e++)t?r[n[e]]=t[e]:r[n[e][0]]=n[e][1];return r},j.indexOf=function(n,t,r){if(null==n)return-1;var e=0,u=n.length;if(r){if("number"!=typeof r)return e=j.sortedIndex(n,t),n[e]===t?e:-1;e=0>r?Math.max(0,u+r):r}if(y&&n.indexOf===y)return n.indexOf(t,r);for(;u>e;e++)if(n[e]===t)return e;return-1},j.lastIndexOf=function(n,t,r){if(null==n)return-1;var e=null!=r;if(b&&n.lastIndexOf===b)return e?n.lastIndexOf(t,r):n.lastIndexOf(t);for(var u=e?r:n.length;u--;)if(n[u]===t)return u;return-1},j.range=function(n,t,r){arguments.length<=1&&(t=n||0,n=0),r=arguments[2]||1;for(var e=Math.max(Math.ceil((t-n)/r),0),u=0,i=new Array(e);e>u;)i[u++]=n,n+=r;return i};var R=function(){};j.bind=function(n,t){var r,e;if(_&&n.bind===_)return _.apply(n,o.call(arguments,1));if(!j.isFunction(n))throw new TypeError;return r=o.call(arguments,2),e=function(){if(!(this instanceof e))return n.apply(t,r.concat(o.call(arguments)));R.prototype=n.prototype;var u=new R;R.prototype=null;var i=n.apply(u,r.concat(o.call(arguments)));return Object(i)===i?i:u}},j.partial=function(n){var t=o.call(arguments,1);return function(){return n.apply(this,t.concat(o.call(arguments)))}},j.bindAll=function(n){var t=o.call(arguments,1);if(0===t.length)throw new Error("bindAll must be passed function names");return A(t,function(t){n[t]=j.bind(n[t],n)}),n},j.memoize=function(n,t){var r={};return t||(t=j.identity),function(){var e=t.apply(this,arguments);return j.has(r,e)?r[e]:r[e]=n.apply(this,arguments)}},j.delay=function(n,t){var r=o.call(arguments,2);return setTimeout(function(){return n.apply(null,r)},t)},j.defer=function(n){return j.delay.apply(j,[n,1].concat(o.call(arguments,1)))},j.throttle=function(n,t,r){var e,u,i,a=null,o=0;r||(r={});var c=function(){o=r.leading===!1?0:new Date,a=null,i=n.apply(e,u)};return function(){var l=new Date;o||r.leading!==!1||(o=l);var f=t-(l-o);return e=this,u=arguments,0>=f?(clearTimeout(a),a=null,o=l,i=n.apply(e,u)):a||r.trailing===!1||(a=setTimeout(c,f)),i}},j.debounce=function(n,t,r){var e,u,i,a,o;return function(){i=this,u=arguments,a=new Date;var c=function(){var l=new Date-a;t>l?e=setTimeout(c,t-l):(e=null,r||(o=n.apply(i,u)))},l=r&&!e;return e||(e=setTimeout(c,t)),l&&(o=n.apply(i,u)),o}},j.once=function(n){var t,r=!1;return function(){return r?t:(r=!0,t=n.apply(this,arguments),n=null,t)}},j.wrap=function(n,t){return function(){var r=[n];return a.apply(r,arguments),t.apply(this,r)}},j.compose=function(){var n=arguments;return function(){for(var t=arguments,r=n.length-1;r>=0;r--)t=[n[r].apply(this,t)];return t[0]}},j.after=function(n,t){return function(){return--n<1?t.apply(this,arguments):void 0}},j.keys=w||function(n){if(n!==Object(n))throw new TypeError("Invalid object");var t=[];for(var r in n)j.has(n,r)&&t.push(r);return t},j.values=function(n){for(var t=j.keys(n),r=t.length,e=new Array(r),u=0;r>u;u++)e[u]=n[t[u]];return e},j.pairs=function(n){for(var t=j.keys(n),r=t.length,e=new Array(r),u=0;r>u;u++)e[u]=[t[u],n[t[u]]];return e},j.invert=function(n){for(var t={},r=j.keys(n),e=0,u=r.length;u>e;e++)t[n[r[e]]]=r[e];return t},j.functions=j.methods=function(n){var t=[];for(var r in n)j.isFunction(n[r])&&t.push(r);return t.sort()},j.extend=function(n){return A(o.call(arguments,1),function(t){if(t)for(var r in t)n[r]=t[r]}),n},j.pick=function(n){var t={},r=c.apply(e,o.call(arguments,1));return A(r,function(r){r in n&&(t[r]=n[r])}),t},j.omit=function(n){var t={},r=c.apply(e,o.call(arguments,1));for(var u in n)j.contains(r,u)||(t[u]=n[u]);return t},j.defaults=function(n){return A(o.call(arguments,1),function(t){if(t)for(var r in t)n[r]===void 0&&(n[r]=t[r])}),n},j.clone=function(n){return j.isObject(n)?j.isArray(n)?n.slice():j.extend({},n):n},j.tap=function(n,t){return t(n),n};var S=function(n,t,r,e){if(n===t)return 0!==n||1/n==1/t;if(null==n||null==t)return n===t;n instanceof j&&(n=n._wrapped),t instanceof j&&(t=t._wrapped);var u=l.call(n);if(u!=l.call(t))return!1;switch(u){case"[object String]":return n==String(t);case"[object Number]":return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case"[object Date]":case"[object Boolean]":return+n==+t;case"[object RegExp]":return n.source==t.source&&n.global==t.global&&n.multiline==t.multiline&&n.ignoreCase==t.ignoreCase}if("object"!=typeof n||"object"!=typeof t)return!1;for(var i=r.length;i--;)if(r[i]==n)return e[i]==t;var a=n.constructor,o=t.constructor;if(a!==o&&!(j.isFunction(a)&&a instanceof a&&j.isFunction(o)&&o instanceof o))return!1;r.push(n),e.push(t);var c=0,f=!0;if("[object Array]"==u){if(c=n.length,f=c==t.length)for(;c--&&(f=S(n[c],t[c],r,e)););}else{for(var s in n)if(j.has(n,s)&&(c++,!(f=j.has(t,s)&&S(n[s],t[s],r,e))))break;if(f){for(s in t)if(j.has(t,s)&&!c--)break;f=!c}}return r.pop(),e.pop(),f};j.isEqual=function(n,t){return S(n,t,[],[])},j.isEmpty=function(n){if(null==n)return!0;if(j.isArray(n)||j.isString(n))return 0===n.length;for(var t in n)if(j.has(n,t))return!1;return!0},j.isElement=function(n){return!(!n||1!==n.nodeType)},j.isArray=x||function(n){return"[object Array]"==l.call(n)},j.isObject=function(n){return n===Object(n)},A(["Arguments","Function","String","Number","Date","RegExp"],function(n){j["is"+n]=function(t){return l.call(t)=="[object "+n+"]"}}),j.isArguments(arguments)||(j.isArguments=function(n){return!(!n||!j.has(n,"callee"))}),"function"!=typeof/./&&(j.isFunction=function(n){return"function"==typeof n}),j.isFinite=function(n){return isFinite(n)&&!isNaN(parseFloat(n))},j.isNaN=function(n){return j.isNumber(n)&&n!=+n},j.isBoolean=function(n){return n===!0||n===!1||"[object Boolean]"==l.call(n)},j.isNull=function(n){return null===n},j.isUndefined=function(n){return n===void 0},j.has=function(n,t){return f.call(n,t)},j.noConflict=function(){return n._=t,this},j.identity=function(n){return n},j.times=function(n,t,r){for(var e=Array(Math.max(0,n)),u=0;n>u;u++)e[u]=t.call(r,u);return e},j.random=function(n,t){return null==t&&(t=n,n=0),n+Math.floor(Math.random()*(t-n+1))};var I={escape:{"&":"&","<":"<",">":">",'"':""","'":"'"}};I.unescape=j.invert(I.escape);var T={escape:new RegExp("["+j.keys(I.escape).join("")+"]","g"),unescape:new RegExp("("+j.keys(I.unescape).join("|")+")","g")};j.each(["escape","unescape"],function(n){j[n]=function(t){return null==t?"":(""+t).replace(T[n],function(t){return I[n][t]})}}),j.result=function(n,t){if(null==n)return void 0;var r=n[t];return j.isFunction(r)?r.call(n):r},j.mixin=function(n){A(j.functions(n),function(t){var r=j[t]=n[t];j.prototype[t]=function(){var n=[this._wrapped];return a.apply(n,arguments),z.call(this,r.apply(j,n))}})};var N=0;j.uniqueId=function(n){var t=++N+"";return n?n+t:t},j.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var q=/(.)^/,B={"'":"'","\\":"\\","\r":"r","\n":"n"," ":"t","\u2028":"u2028","\u2029":"u2029"},D=/\\|'|\r|\n|\t|\u2028|\u2029/g;j.template=function(n,t,r){var e;r=j.defaults({},r,j.templateSettings);var u=new RegExp([(r.escape||q).source,(r.interpolate||q).source,(r.evaluate||q).source].join("|")+"|$","g"),i=0,a="__p+='";n.replace(u,function(t,r,e,u,o){return a+=n.slice(i,o).replace(D,function(n){return"\\"+B[n]}),r&&(a+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'"),e&&(a+="'+\n((__t=("+e+"))==null?'':__t)+\n'"),u&&(a+="';\n"+u+"\n__p+='"),i=o+t.length,t}),a+="';\n",r.variable||(a="with(obj||{}){\n"+a+"}\n"),a="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+a+"return __p;\n";try{e=new Function(r.variable||"obj","_",a)}catch(o){throw o.source=a,o}if(t)return e(t,j);var c=function(n){return e.call(this,n,j)};return c.source="function("+(r.variable||"obj")+"){\n"+a+"}",c},j.chain=function(n){return j(n).chain()};var z=function(n){return this._chain?j(n).chain():n};j.mixin(j),A(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var t=e[n];j.prototype[n]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!=n&&"splice"!=n||0!==r.length||delete r[0],z.call(this,r)}}),A(["concat","join","slice"],function(n){var t=e[n];j.prototype[n]=function(){return z.call(this,t.apply(this._wrapped,arguments))}}),j.extend(j.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}).call(this);
+//# sourceMappingURL=underscore-min.map
\ No newline at end of file
diff --git a/workflow/public_html/lib/wz_jsgraphics/wz_jsgraphics.js b/workflow/public_html/lib/wz_jsgraphics/wz_jsgraphics.js
new file mode 100644
index 000000000..1f9a7b9f4
--- /dev/null
+++ b/workflow/public_html/lib/wz_jsgraphics/wz_jsgraphics.js
@@ -0,0 +1,1108 @@
+/* This notice must be untouched at all times.
+
+wz_jsgraphics.js v. 3.05
+The latest version is available at
+http://www.walterzorn.com
+or http://www.devira.com
+or http://www.walterzorn.de
+
+Copyright (c) 2002-2009 Walter Zorn. All rights reserved.
+Created 3. 11. 2002 by Walter Zorn (Web: http://www.walterzorn.com )
+Last modified: 2. 2. 2009
+
+Performance optimizations for Internet Explorer
+by Thomas Frank and John Holdsworth.
+fillPolygon method implemented by Matthieu Haller.
+
+High Performance JavaScript Graphics Library.
+Provides methods
+- to draw lines, rectangles, ellipses, polygons
+ with specifiable line thickness,
+- to fill rectangles, polygons, ellipses and arcs
+- to draw text.
+NOTE: Operations, functions and branching have rather been optimized
+to efficiency and speed than to shortness of source code.
+
+LICENSE: LGPL
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License (LGPL) as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA,
+or see http://www.gnu.org/copyleft/lesser.html
+*/
+
+
+var jg_ok, jg_ie, jg_fast, jg_dom, jg_moz;
+
+
+function _chkDHTM(wnd, x, i)
+// Under XUL, owner of 'document' must be specified explicitly
+{
+ x = wnd.document.body || null;
+ jg_ie = x && typeof x.insertAdjacentHTML != "undefined" && wnd.document.createElement;
+ jg_dom = (x && !jg_ie &&
+ typeof x.appendChild != "undefined" &&
+ typeof wnd.document.createRange != "undefined" &&
+ typeof (i = wnd.document.createRange()).setStartBefore != "undefined" &&
+ typeof i.createContextualFragment != "undefined");
+ jg_fast = jg_ie && wnd.document.all && !wnd.opera;
+ jg_moz = jg_dom && typeof x.style.MozOpacity != "undefined";
+ jg_ok = !!(jg_ie || jg_dom);
+}
+
+function _pntCnvDom()
+{
+ var x = this.wnd.document.createRange();
+ x.setStartBefore(this.cnv);
+ x = x.createContextualFragment(jg_fast? this._htmRpc() : this.htm);
+ if(this.cnv) this.cnv.appendChild(x);
+ this.htm = "";
+}
+
+function _pntCnvIe()
+{
+ if(this.cnv) this.cnv.insertAdjacentHTML("BeforeEnd", jg_fast? this._htmRpc() : this.htm);
+ this.htm = "";
+}
+
+function _pntDoc()
+{
+ this.wnd.document.write(jg_fast? this._htmRpc() : this.htm);
+ this.htm = '';
+}
+
+function _pntN()
+{
+ ;
+}
+
+function _mkDiv(x, y, w, h)
+{
+ this.htm += '<\/div>';
+}
+
+function _mkDivIe(x, y, w, h)
+{
+ this.htm += '%%'+this.color+';'+x+';'+y+';'+w+';'+h+';';
+}
+
+function _mkDivPrt(x, y, w, h)
+{
+ this.htm += '
<\/div>';
+}
+
+var _regex = /%%([^;]+);([^;]+);([^;]+);([^;]+);([^;]+);/g;
+function _htmRpc()
+{
+ return this.htm.replace(
+ _regex,
+ '
\n');
+}
+
+function _htmPrtRpc()
+{
+ return this.htm.replace(
+ _regex,
+ '
\n');
+}
+
+function _mkLin(x1, y1, x2, y2)
+{
+ if(x1 > x2)
+ {
+ var _x2 = x2;
+ var _y2 = y2;
+ x2 = x1;
+ y2 = y1;
+ x1 = _x2;
+ y1 = _y2;
+ }
+ var dx = x2-x1, dy = Math.abs(y2-y1),
+ x = x1, y = y1,
+ yIncr = (y1 > y2)? -1 : 1;
+
+ if(dx >= dy)
+ {
+ var pr = dy<<1,
+ pru = pr - (dx<<1),
+ p = pr-dx,
+ ox = x;
+ while(dx > 0)
+ {--dx;
+ ++x;
+ if(p > 0)
+ {
+ this._mkDiv(ox, y, x-ox, 1);
+ y += yIncr;
+ p += pru;
+ ox = x;
+ }
+ else p += pr;
+ }
+ this._mkDiv(ox, y, x2-ox+1, 1);
+ }
+
+ else
+ {
+ var pr = dx<<1,
+ pru = pr - (dy<<1),
+ p = pr-dy,
+ oy = y;
+ if(y2 <= y1)
+ {
+ while(dy > 0)
+ {--dy;
+ if(p > 0)
+ {
+ this._mkDiv(x++, y, 1, oy-y+1);
+ y += yIncr;
+ p += pru;
+ oy = y;
+ }
+ else
+ {
+ y += yIncr;
+ p += pr;
+ }
+ }
+ this._mkDiv(x2, y2, 1, oy-y2+1);
+ }
+ else
+ {
+ while(dy > 0)
+ {--dy;
+ y += yIncr;
+ if(p > 0)
+ {
+ this._mkDiv(x++, oy, 1, y-oy);
+ p += pru;
+ oy = y;
+ }
+ else p += pr;
+ }
+ this._mkDiv(x2, oy, 1, y2-oy+1);
+ }
+ }
+}
+
+function _mkLin2D(x1, y1, x2, y2)
+{
+ if(x1 > x2)
+ {
+ var _x2 = x2;
+ var _y2 = y2;
+ x2 = x1;
+ y2 = y1;
+ x1 = _x2;
+ y1 = _y2;
+ }
+ var dx = x2-x1, dy = Math.abs(y2-y1),
+ x = x1, y = y1,
+ yIncr = (y1 > y2)? -1 : 1;
+
+ var s = this.stroke;
+ if(dx >= dy)
+ {
+ if(dx > 0 && s-3 > 0)
+ {
+ var _s = (s*dx*Math.sqrt(1+dy*dy/(dx*dx))-dx-(s>>1)*dy) / dx;
+ _s = (!(s-4)? Math.ceil(_s) : Math.round(_s)) + 1;
+ }
+ else var _s = s;
+ var ad = Math.ceil(s/2);
+
+ var pr = dy<<1,
+ pru = pr - (dx<<1),
+ p = pr-dx,
+ ox = x;
+ while(dx > 0)
+ {--dx;
+ ++x;
+ if(p > 0)
+ {
+ this._mkDiv(ox, y, x-ox+ad, _s);
+ y += yIncr;
+ p += pru;
+ ox = x;
+ }
+ else p += pr;
+ }
+ this._mkDiv(ox, y, x2-ox+ad+1, _s);
+ }
+
+ else
+ {
+ if(s-3 > 0)
+ {
+ var _s = (s*dy*Math.sqrt(1+dx*dx/(dy*dy))-(s>>1)*dx-dy) / dy;
+ _s = (!(s-4)? Math.ceil(_s) : Math.round(_s)) + 1;
+ }
+ else var _s = s;
+ var ad = Math.round(s/2);
+
+ var pr = dx<<1,
+ pru = pr - (dy<<1),
+ p = pr-dy,
+ oy = y;
+ if(y2 <= y1)
+ {
+ ++ad;
+ while(dy > 0)
+ {--dy;
+ if(p > 0)
+ {
+ this._mkDiv(x++, y, _s, oy-y+ad);
+ y += yIncr;
+ p += pru;
+ oy = y;
+ }
+ else
+ {
+ y += yIncr;
+ p += pr;
+ }
+ }
+ this._mkDiv(x2, y2, _s, oy-y2+ad);
+ }
+ else
+ {
+ while(dy > 0)
+ {--dy;
+ y += yIncr;
+ if(p > 0)
+ {
+ this._mkDiv(x++, oy, _s, y-oy+ad);
+ p += pru;
+ oy = y;
+ }
+ else p += pr;
+ }
+ this._mkDiv(x2, oy, _s, y2-oy+ad+1);
+ }
+ }
+}
+
+function _mkLinDott(x1, y1, x2, y2)
+{
+ if(x1 > x2)
+ {
+ var _x2 = x2;
+ var _y2 = y2;
+ x2 = x1;
+ y2 = y1;
+ x1 = _x2;
+ y1 = _y2;
+ }
+ var dx = x2-x1, dy = Math.abs(y2-y1),
+ x = x1, y = y1,
+ yIncr = (y1 > y2)? -1 : 1,
+ drw = true;
+ if(dx >= dy)
+ {
+ var pr = dy<<1,
+ pru = pr - (dx<<1),
+ p = pr-dx;
+ while(dx > 0)
+ {--dx;
+ if(drw) this._mkDiv(x, y, 1, 1);
+ drw = !drw;
+ if(p > 0)
+ {
+ y += yIncr;
+ p += pru;
+ }
+ else p += pr;
+ ++x;
+ }
+ }
+ else
+ {
+ var pr = dx<<1,
+ pru = pr - (dy<<1),
+ p = pr-dy;
+ while(dy > 0)
+ {--dy;
+ if(drw) this._mkDiv(x, y, 1, 1);
+ drw = !drw;
+ y += yIncr;
+ if(p > 0)
+ {
+ ++x;
+ p += pru;
+ }
+ else p += pr;
+ }
+ }
+ if(drw) this._mkDiv(x, y, 1, 1);
+}
+
+function _mkOv(left, top, width, height)
+{
+ var a = (++width)>>1, b = (++height)>>1,
+ wod = width&1, hod = height&1,
+ cx = left+a, cy = top+b,
+ x = 0, y = b,
+ ox = 0, oy = b,
+ aa2 = (a*a)<<1, aa4 = aa2<<1, bb2 = (b*b)<<1, bb4 = bb2<<1,
+ st = (aa2>>1)*(1-(b<<1)) + bb2,
+ tt = (bb2>>1) - aa2*((b<<1)-1),
+ w, h;
+ while(y > 0)
+ {
+ if(st < 0)
+ {
+ st += bb2*((x<<1)+3);
+ tt += bb4*(++x);
+ }
+ else if(tt < 0)
+ {
+ st += bb2*((x<<1)+3) - aa4*(y-1);
+ tt += bb4*(++x) - aa2*(((y--)<<1)-3);
+ w = x-ox;
+ h = oy-y;
+ if((w&2) && (h&2))
+ {
+ this._mkOvQds(cx, cy, x-2, y+2, 1, 1, wod, hod);
+ this._mkOvQds(cx, cy, x-1, y+1, 1, 1, wod, hod);
+ }
+ else this._mkOvQds(cx, cy, x-1, oy, w, h, wod, hod);
+ ox = x;
+ oy = y;
+ }
+ else
+ {
+ tt -= aa2*((y<<1)-3);
+ st -= aa4*(--y);
+ }
+ }
+ w = a-ox+1;
+ h = (oy<<1)+hod;
+ y = cy-oy;
+ this._mkDiv(cx-a, y, w, h);
+ this._mkDiv(cx+ox+wod-1, y, w, h);
+}
+
+function _mkOv2D(left, top, width, height)
+{
+ var s = this.stroke;
+ width += s+1;
+ height += s+1;
+ var a = width>>1, b = height>>1,
+ wod = width&1, hod = height&1,
+ cx = left+a, cy = top+b,
+ x = 0, y = b,
+ aa2 = (a*a)<<1, aa4 = aa2<<1, bb2 = (b*b)<<1, bb4 = bb2<<1,
+ st = (aa2>>1)*(1-(b<<1)) + bb2,
+ tt = (bb2>>1) - aa2*((b<<1)-1);
+
+ if(s-4 < 0 && (!(s-2) || width-51 > 0 && height-51 > 0))
+ {
+ var ox = 0, oy = b,
+ w, h,
+ pxw;
+ while(y > 0)
+ {
+ if(st < 0)
+ {
+ st += bb2*((x<<1)+3);
+ tt += bb4*(++x);
+ }
+ else if(tt < 0)
+ {
+ st += bb2*((x<<1)+3) - aa4*(y-1);
+ tt += bb4*(++x) - aa2*(((y--)<<1)-3);
+ w = x-ox;
+ h = oy-y;
+
+ if(w-1)
+ {
+ pxw = w+1+(s&1);
+ h = s;
+ }
+ else if(h-1)
+ {
+ pxw = s;
+ h += 1+(s&1);
+ }
+ else pxw = h = s;
+ this._mkOvQds(cx, cy, x-1, oy, pxw, h, wod, hod);
+ ox = x;
+ oy = y;
+ }
+ else
+ {
+ tt -= aa2*((y<<1)-3);
+ st -= aa4*(--y);
+ }
+ }
+ this._mkDiv(cx-a, cy-oy, s, (oy<<1)+hod);
+ this._mkDiv(cx+a+wod-s, cy-oy, s, (oy<<1)+hod);
+ }
+
+ else
+ {
+ var _a = (width-(s<<1))>>1,
+ _b = (height-(s<<1))>>1,
+ _x = 0, _y = _b,
+ _aa2 = (_a*_a)<<1, _aa4 = _aa2<<1, _bb2 = (_b*_b)<<1, _bb4 = _bb2<<1,
+ _st = (_aa2>>1)*(1-(_b<<1)) + _bb2,
+ _tt = (_bb2>>1) - _aa2*((_b<<1)-1),
+
+ pxl = new Array(),
+ pxt = new Array(),
+ _pxb = new Array();
+ pxl[0] = 0;
+ pxt[0] = b;
+ _pxb[0] = _b-1;
+ while(y > 0)
+ {
+ if(st < 0)
+ {
+ pxl[pxl.length] = x;
+ pxt[pxt.length] = y;
+ st += bb2*((x<<1)+3);
+ tt += bb4*(++x);
+ }
+ else if(tt < 0)
+ {
+ pxl[pxl.length] = x;
+ st += bb2*((x<<1)+3) - aa4*(y-1);
+ tt += bb4*(++x) - aa2*(((y--)<<1)-3);
+ pxt[pxt.length] = y;
+ }
+ else
+ {
+ tt -= aa2*((y<<1)-3);
+ st -= aa4*(--y);
+ }
+
+ if(_y > 0)
+ {
+ if(_st < 0)
+ {
+ _st += _bb2*((_x<<1)+3);
+ _tt += _bb4*(++_x);
+ _pxb[_pxb.length] = _y-1;
+ }
+ else if(_tt < 0)
+ {
+ _st += _bb2*((_x<<1)+3) - _aa4*(_y-1);
+ _tt += _bb4*(++_x) - _aa2*(((_y--)<<1)-3);
+ _pxb[_pxb.length] = _y-1;
+ }
+ else
+ {
+ _tt -= _aa2*((_y<<1)-3);
+ _st -= _aa4*(--_y);
+ _pxb[_pxb.length-1]--;
+ }
+ }
+ }
+
+ var ox = -wod, oy = b,
+ _oy = _pxb[0],
+ l = pxl.length,
+ w, h;
+ for(var i = 0; i < l; i++)
+ {
+ if(typeof _pxb[i] != "undefined")
+ {
+ if(_pxb[i] < _oy || pxt[i] < oy)
+ {
+ x = pxl[i];
+ this._mkOvQds(cx, cy, x, oy, x-ox, oy-_oy, wod, hod);
+ ox = x;
+ oy = pxt[i];
+ _oy = _pxb[i];
+ }
+ }
+ else
+ {
+ x = pxl[i];
+ this._mkDiv(cx-x, cy-oy, 1, (oy<<1)+hod);
+ this._mkDiv(cx+ox+wod, cy-oy, 1, (oy<<1)+hod);
+ ox = x;
+ oy = pxt[i];
+ }
+ }
+ this._mkDiv(cx-a, cy-oy, 1, (oy<<1)+hod);
+ this._mkDiv(cx+ox+wod, cy-oy, 1, (oy<<1)+hod);
+ }
+}
+
+function _mkOvDott(left, top, width, height)
+{
+ var a = (++width)>>1, b = (++height)>>1,
+ wod = width&1, hod = height&1, hodu = hod^1,
+ cx = left+a, cy = top+b,
+ x = 0, y = b,
+ aa2 = (a*a)<<1, aa4 = aa2<<1, bb2 = (b*b)<<1, bb4 = bb2<<1,
+ st = (aa2>>1)*(1-(b<<1)) + bb2,
+ tt = (bb2>>1) - aa2*((b<<1)-1),
+ drw = true;
+ while(y > 0)
+ {
+ if(st < 0)
+ {
+ st += bb2*((x<<1)+3);
+ tt += bb4*(++x);
+ }
+ else if(tt < 0)
+ {
+ st += bb2*((x<<1)+3) - aa4*(y-1);
+ tt += bb4*(++x) - aa2*(((y--)<<1)-3);
+ }
+ else
+ {
+ tt -= aa2*((y<<1)-3);
+ st -= aa4*(--y);
+ }
+ if(drw && y >= hodu) this._mkOvQds(cx, cy, x, y, 1, 1, wod, hod);
+ drw = !drw;
+ }
+}
+
+function _mkRect(x, y, w, h)
+{
+ var s = this.stroke;
+ this._mkDiv(x, y, w, s);
+ this._mkDiv(x+w, y, s, h);
+ this._mkDiv(x, y+h, w+s, s);
+ this._mkDiv(x, y+s, s, h-s);
+}
+
+function _mkRectDott(x, y, w, h)
+{
+ this.drawLine(x, y, x+w, y);
+ this.drawLine(x+w, y, x+w, y+h);
+ this.drawLine(x, y+h, x+w, y+h);
+ this.drawLine(x, y, x, y+h);
+}
+
+function jsgFont()
+{
+ this.PLAIN = 'font-weight:normal;';
+ this.BOLD = 'font-weight:bold;';
+ this.ITALIC = 'font-style:italic;';
+ this.ITALIC_BOLD = this.ITALIC + this.BOLD;
+ this.BOLD_ITALIC = this.ITALIC_BOLD;
+}
+var Font = new jsgFont();
+
+function jsgStroke()
+{
+ this.DOTTED = -1;
+}
+var Stroke = new jsgStroke();
+
+function JSGraphics(cnv, wnd)
+{
+ this.setColor = function(x)
+ {
+ this.color = x.toLowerCase();
+ };
+
+ this.setStroke = function(x)
+ {
+ this.stroke = x;
+ if(!(x+1))
+ {
+ this.drawLine = _mkLinDott;
+ this._mkOv = _mkOvDott;
+ this.drawRect = _mkRectDott;
+ }
+ else if(x-1 > 0)
+ {
+ this.drawLine = _mkLin2D;
+ this._mkOv = _mkOv2D;
+ this.drawRect = _mkRect;
+ }
+ else
+ {
+ this.drawLine = _mkLin;
+ this._mkOv = _mkOv;
+ this.drawRect = _mkRect;
+ }
+ };
+
+ this.setPrintable = function(arg)
+ {
+ this.printable = arg;
+ if(jg_fast)
+ {
+ this._mkDiv = _mkDivIe;
+ this._htmRpc = arg? _htmPrtRpc : _htmRpc;
+ }
+ else this._mkDiv = arg? _mkDivPrt : _mkDiv;
+ };
+
+ this.setFont = function(fam, sz, sty)
+ {
+ this.ftFam = fam;
+ this.ftSz = sz;
+ this.ftSty = sty || Font.PLAIN;
+ };
+
+ this.drawPolyline = this.drawPolyLine = function(x, y)
+ {
+ for (var i=x.length - 1; i;)
+ {--i;
+ this.drawLine(x[i], y[i], x[i+1], y[i+1]);
+ }
+ };
+
+ this.fillRect = function(x, y, w, h)
+ {
+ this._mkDiv(x, y, w, h);
+ };
+
+ this.drawPolygon = function(x, y)
+ {
+ this.drawPolyline(x, y);
+ this.drawLine(x[x.length-1], y[x.length-1], x[0], y[0]);
+ };
+
+ this.drawEllipse = this.drawOval = function(x, y, w, h)
+ {
+ this._mkOv(x, y, w, h);
+ };
+
+ this.fillEllipse = this.fillOval = function(left, top, w, h)
+ {
+ var a = w>>1, b = h>>1,
+ wod = w&1, hod = h&1,
+ cx = left+a, cy = top+b,
+ x = 0, y = b, oy = b,
+ aa2 = (a*a)<<1, aa4 = aa2<<1, bb2 = (b*b)<<1, bb4 = bb2<<1,
+ st = (aa2>>1)*(1-(b<<1)) + bb2,
+ tt = (bb2>>1) - aa2*((b<<1)-1),
+ xl, dw, dh;
+ if(w) while(y > 0)
+ {
+ if(st < 0)
+ {
+ st += bb2*((x<<1)+3);
+ tt += bb4*(++x);
+ }
+ else if(tt < 0)
+ {
+ st += bb2*((x<<1)+3) - aa4*(y-1);
+ xl = cx-x;
+ dw = (x<<1)+wod;
+ tt += bb4*(++x) - aa2*(((y--)<<1)-3);
+ dh = oy-y;
+ this._mkDiv(xl, cy-oy, dw, dh);
+ this._mkDiv(xl, cy+y+hod, dw, dh);
+ oy = y;
+ }
+ else
+ {
+ tt -= aa2*((y<<1)-3);
+ st -= aa4*(--y);
+ }
+ }
+ this._mkDiv(cx-a, cy-oy, w, (oy<<1)+hod);
+ };
+
+ this.fillArc = function(iL, iT, iW, iH, fAngA, fAngZ)
+ {
+ var a = iW>>1, b = iH>>1,
+ iOdds = (iW&1) | ((iH&1) << 16),
+ cx = iL+a, cy = iT+b,
+ x = 0, y = b, ox = x, oy = y,
+ aa2 = (a*a)<<1, aa4 = aa2<<1, bb2 = (b*b)<<1, bb4 = bb2<<1,
+ st = (aa2>>1)*(1-(b<<1)) + bb2,
+ tt = (bb2>>1) - aa2*((b<<1)-1),
+ // Vars for radial boundary lines
+ xEndA, yEndA, xEndZ, yEndZ,
+ iSects = (1 << (Math.floor((fAngA %= 360.0)/180.0) << 3))
+ | (2 << (Math.floor((fAngZ %= 360.0)/180.0) << 3))
+ | ((fAngA >= fAngZ) << 16),
+ aBndA = new Array(b+1), aBndZ = new Array(b+1);
+
+ // Set up radial boundary lines
+ fAngA *= Math.PI/180.0;
+ fAngZ *= Math.PI/180.0;
+ xEndA = cx+Math.round(a*Math.cos(fAngA));
+ yEndA = cy+Math.round(-b*Math.sin(fAngA));
+ _mkLinVirt(aBndA, cx, cy, xEndA, yEndA);
+ xEndZ = cx+Math.round(a*Math.cos(fAngZ));
+ yEndZ = cy+Math.round(-b*Math.sin(fAngZ));
+ _mkLinVirt(aBndZ, cx, cy, xEndZ, yEndZ);
+
+ while(y > 0)
+ {
+ if(st < 0) // Advance x
+ {
+ st += bb2*((x<<1)+3);
+ tt += bb4*(++x);
+ }
+ else if(tt < 0) // Advance x and y
+ {
+ st += bb2*((x<<1)+3) - aa4*(y-1);
+ ox = x;
+ tt += bb4*(++x) - aa2*(((y--)<<1)-3);
+ this._mkArcDiv(ox, y, oy, cx, cy, iOdds, aBndA, aBndZ, iSects);
+ oy = y;
+ }
+ else // Advance y
+ {
+ tt -= aa2*((y<<1)-3);
+ st -= aa4*(--y);
+ if(y && (aBndA[y] != aBndA[y-1] || aBndZ[y] != aBndZ[y-1]))
+ {
+ this._mkArcDiv(x, y, oy, cx, cy, iOdds, aBndA, aBndZ, iSects);
+ ox = x;
+ oy = y;
+ }
+ }
+ }
+ this._mkArcDiv(x, 0, oy, cx, cy, iOdds, aBndA, aBndZ, iSects);
+ if(iOdds >> 16) // Odd height
+ {
+ if(iSects >> 16) // Start-angle > end-angle
+ {
+ var xl = (yEndA <= cy || yEndZ > cy)? (cx - x) : cx;
+ this._mkDiv(xl, cy, x + cx - xl + (iOdds & 0xffff), 1);
+ }
+ else if((iSects & 0x01) && yEndZ > cy)
+ this._mkDiv(cx - x, cy, x, 1);
+ }
+ };
+
+/* fillPolygon method, implemented by Matthieu Haller.
+This javascript function is an adaptation of the gdImageFilledPolygon for Walter Zorn lib.
+C source of GD 1.8.4 found at http://www.boutell.com/gd/
+
+THANKS to Kirsten Schulz for the polygon fixes!
+
+The intersection finding technique of this code could be improved
+by remembering the previous intertersection, and by using the slope.
+That could help to adjust intersections to produce a nice
+interior_extrema. */
+ this.fillPolygon = function(array_x, array_y)
+ {
+ var i;
+ var y;
+ var miny, maxy;
+ var x1, y1;
+ var x2, y2;
+ var ind1, ind2;
+ var ints;
+
+ var n = array_x.length;
+ if(!n) return;
+
+ miny = array_y[0];
+ maxy = array_y[0];
+ for(i = 1; i < n; i++)
+ {
+ if(array_y[i] < miny)
+ miny = array_y[i];
+
+ if(array_y[i] > maxy)
+ maxy = array_y[i];
+ }
+ for(y = miny; y <= maxy; y++)
+ {
+ var polyInts = new Array();
+ ints = 0;
+ for(i = 0; i < n; i++)
+ {
+ if(!i)
+ {
+ ind1 = n-1;
+ ind2 = 0;
+ }
+ else
+ {
+ ind1 = i-1;
+ ind2 = i;
+ }
+ y1 = array_y[ind1];
+ y2 = array_y[ind2];
+ if(y1 < y2)
+ {
+ x1 = array_x[ind1];
+ x2 = array_x[ind2];
+ }
+ else if(y1 > y2)
+ {
+ y2 = array_y[ind1];
+ y1 = array_y[ind2];
+ x2 = array_x[ind1];
+ x1 = array_x[ind2];
+ }
+ else continue;
+
+ // Modified 11. 2. 2004 Walter Zorn
+ if((y >= y1) && (y < y2))
+ polyInts[ints++] = Math.round((y-y1) * (x2-x1) / (y2-y1) + x1);
+
+ else if((y == maxy) && (y > y1) && (y <= y2))
+ polyInts[ints++] = Math.round((y-y1) * (x2-x1) / (y2-y1) + x1);
+ }
+ polyInts.sort(_CompInt);
+ for(i = 0; i < ints; i+=2)
+ this._mkDiv(polyInts[i], y, polyInts[i+1]-polyInts[i]+1, 1);
+ }
+ };
+
+ this.drawString = function(txt, x, y)
+ {
+ this.htm += '
'+
+ txt +
+ '<\/div>';
+ };
+
+/* drawStringRect() added by Rick Blommers.
+Allows to specify the size of the text rectangle and to align the
+text both horizontally (e.g. right) and vertically within that rectangle */
+ this.drawStringRect = function(txt, x, y, width, halign)
+ {
+ this.htm += '
'+
+ txt +
+ '<\/div>';
+ };
+
+ this.drawImage = function(imgSrc, x, y, w, h, a)
+ {
+ this.htm += '
'+
+ '

'+
+ '<\/div>';
+ };
+
+ this.clear = function()
+ {
+ this.htm = "";
+ if(this.cnv) this.cnv.innerHTML = "";
+ };
+
+ this._mkOvQds = function(cx, cy, x, y, w, h, wod, hod)
+ {
+ var xl = cx - x, xr = cx + x + wod - w, yt = cy - y, yb = cy + y + hod - h;
+ if(xr > xl+w)
+ {
+ this._mkDiv(xr, yt, w, h);
+ this._mkDiv(xr, yb, w, h);
+ }
+ else
+ w = xr - xl + w;
+ this._mkDiv(xl, yt, w, h);
+ this._mkDiv(xl, yb, w, h);
+ };
+
+ this._mkArcDiv = function(x, y, oy, cx, cy, iOdds, aBndA, aBndZ, iSects)
+ {
+ var xrDef = cx + x + (iOdds & 0xffff), y2, h = oy - y, xl, xr, w;
+
+ if(!h) h = 1;
+ x = cx - x;
+
+ if(iSects & 0xff0000) // Start-angle > end-angle
+ {
+ y2 = cy - y - h;
+ if(iSects & 0x00ff)
+ {
+ if(iSects & 0x02)
+ {
+ xl = Math.max(x, aBndZ[y]);
+ w = xrDef - xl;
+ if(w > 0) this._mkDiv(xl, y2, w, h);
+ }
+ if(iSects & 0x01)
+ {
+ xr = Math.min(xrDef, aBndA[y]);
+ w = xr - x;
+ if(w > 0) this._mkDiv(x, y2, w, h);
+ }
+ }
+ else
+ this._mkDiv(x, y2, xrDef - x, h);
+ y2 = cy + y + (iOdds >> 16);
+ if(iSects & 0xff00)
+ {
+ if(iSects & 0x0100)
+ {
+ xl = Math.max(x, aBndA[y]);
+ w = xrDef - xl;
+ if(w > 0) this._mkDiv(xl, y2, w, h);
+ }
+ if(iSects & 0x0200)
+ {
+ xr = Math.min(xrDef, aBndZ[y]);
+ w = xr - x;
+ if(w > 0) this._mkDiv(x, y2, w, h);
+ }
+ }
+ else
+ this._mkDiv(x, y2, xrDef - x, h);
+ }
+ else
+ {
+ if(iSects & 0x00ff)
+ {
+ if(iSects & 0x02)
+ xl = Math.max(x, aBndZ[y]);
+ else
+ xl = x;
+ if(iSects & 0x01)
+ xr = Math.min(xrDef, aBndA[y]);
+ else
+ xr = xrDef;
+ y2 = cy - y - h;
+ w = xr - xl;
+ if(w > 0) this._mkDiv(xl, y2, w, h);
+ }
+ if(iSects & 0xff00)
+ {
+ if(iSects & 0x0100)
+ xl = Math.max(x, aBndA[y]);
+ else
+ xl = x;
+ if(iSects & 0x0200)
+ xr = Math.min(xrDef, aBndZ[y]);
+ else
+ xr = xrDef;
+ y2 = cy + y + (iOdds >> 16);
+ w = xr - xl;
+ if(w > 0) this._mkDiv(xl, y2, w, h);
+ }
+ }
+ };
+
+ this.setStroke(1);
+ this.setFont("verdana,geneva,helvetica,sans-serif", "12px", Font.PLAIN);
+ this.color = "#000000";
+ this.htm = "";
+ this.wnd = wnd || window;
+
+ if(!jg_ok) _chkDHTM(this.wnd);
+ if(jg_ok)
+ {
+ if(cnv)
+ {
+ if(typeof(cnv) == "string")
+ this.cont = document.all? (this.wnd.document.all[cnv] || null)
+ : document.getElementById? (this.wnd.document.getElementById(cnv) || null)
+ : null;
+ else if(cnv == window.document)
+ this.cont = document.getElementsByTagName("body")[0];
+ // If cnv is a direct reference to a canvas DOM node
+ // (option suggested by Andreas Luleich)
+ else this.cont = cnv;
+ // Create new canvas inside container DIV. Thus the drawing and clearing
+ // methods won't interfere with the container's inner html.
+ // Solution suggested by Vladimir.
+ this.cnv = this.wnd.document.createElement("div");
+ this.cnv.style.fontSize=0;
+ this.cont.appendChild(this.cnv);
+ this.paint = jg_dom? _pntCnvDom : _pntCnvIe;
+ }
+ else
+ this.paint = _pntDoc;
+ }
+ else
+ this.paint = _pntN;
+
+ this.setPrintable(false);
+}
+
+function _mkLinVirt(aLin, x1, y1, x2, y2)
+{
+ var dx = Math.abs(x2-x1), dy = Math.abs(y2-y1),
+ x = x1, y = y1,
+ xIncr = (x1 > x2)? -1 : 1,
+ yIncr = (y1 > y2)? -1 : 1,
+ p,
+ i = 0;
+ if(dx >= dy)
+ {
+ var pr = dy<<1,
+ pru = pr - (dx<<1);
+ p = pr-dx;
+ while(dx > 0)
+ {--dx;
+ if(p > 0) // Increment y
+ {
+ aLin[i++] = x;
+ y += yIncr;
+ p += pru;
+ }
+ else p += pr;
+ x += xIncr;
+ }
+ }
+ else
+ {
+ var pr = dx<<1,
+ pru = pr - (dy<<1);
+ p = pr-dy;
+ while(dy > 0)
+ {--dy;
+ y += yIncr;
+ aLin[i++] = x;
+ if(p > 0) // Increment x
+ {
+ x += xIncr;
+ p += pru;
+ }
+ else p += pr;
+ }
+ }
+ for(var len = aLin.length, i = len-i; i;)
+ aLin[len-(i--)] = x;
+};
+
+function _CompInt(x, y)
+{
+ return(x - y);
+}
+