rem
stringlengths 0
126k
| add
stringlengths 0
441k
| context
stringlengths 15
136k
|
---|---|---|
offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("$containing-document$", "xxforms-offline");
|
offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("#document", "xxforms-offline");
|
var formLoadingIntervalID = window.setInterval(function() { if (formLoadingComplete) { window.clearInterval(formLoadingIntervalID); // Load the form in the iframe ORBEON.xforms.Offline.loadFormInIframe(url, function(offlineIframe) { // Wait for the form to be marked as offline before we call the listener var takingFormOfflineIntervalID = window.setInterval(function() { if (! offlineIframe.contentWindow.ORBEON.xforms.Offline.isOnline) { window.clearInterval(takingFormOfflineIntervalID); // Calling listener to notify that the form is now completely offline if (formOfflineListener) formOfflineListener(offlineIframe.contentWindow); } }, 100); // Send offline event to the server offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("$containing-document$", "xxforms-offline"); }); } }, 100);
|
.click(function() { box.hide();callback(false)});
|
$('#jsonEditor').fadeOut('slow', function () { $('#jsonArrayEditor').fadeIn('slow', function() { $('#selectedJSONArrayName').focus().select(); }); });
|
.click(function() { box.hide();callback(false)});
|
stop_offset = stopMakerDiv.offset();
|
$(path).mousedown(function(e) { selectStop(this); drag = cur_stop; $win.mousemove(dragColor).mouseup(remDrags); e.preventDefault(); return false; }).data('stop', stop).data('bg', pathbg).dblclick(function() {
|
|
else a.removeAttribute&&a.removeAttribute(c.expando);delete f[d]}}}});c.fn.extend({data:function(a,b){if(typeof a==="undefined"&&this.length)return c.data(this[0]);else if(typeof a==="object")return this.each(function(){c.data(this,a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===w){var f=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(f===w&&this.length)f=c.data(this[0],a);return f===w&&d[1]?this.data(d[0]):f}else return this.trigger("setData"+d[1]+"!",[d[0],b]).each(function(){c.data(this, a,b)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var f=c.data(a,b);if(!d)return f||[];if(!f||c.isArray(d))f=c.data(a,b,c.makeArray(d));else f.push(d);return f}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),f=d.shift();if(f==="inprogress")f=d.shift();if(f){b==="fx"&&d.unshift("inprogress");f.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b===
|
"margin"+this))||0;else e-=parseFloat(c.css(a,"border"+this+"Width"))||0});return e}function da(a,b,d,e){if(c.isArray(b)&&b.length)c.each(b,function(f,h){d||Ra.test(a)?e(a,h):da(a+"["+(typeof h==="object"||c.isArray(h)?f:"")+"]",h,d,e)});else if(!d&&b!=null&&typeof b==="object")c.isEmptyObject(b)?e(a,""):c.each(b,function(f,h){da(a+"["+f+"]",h,d,e)});else e(a,b)}function S(a,b){var d={};c.each(pa.concat.apply([],pa.slice(0,b)),function(){d[this]=a});return d}function qa(a){if(!ea[a]){var b=c("<"+
|
else a.removeAttribute&&a.removeAttribute(c.expando);delete f[d]}}}});c.fn.extend({data:function(a,b){if(typeof a==="undefined"&&this.length)return c.data(this[0]);else if(typeof a==="object")return this.each(function(){c.data(this,a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===w){var f=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(f===w&&this.length)f=c.data(this[0],a);return f===w&&d[1]?this.data(d[0]):f}else return this.trigger("setData"+d[1]+"!",[d[0],b]).each(function(){c.data(this,a,b)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var f=c.data(a,b);if(!d)return f||[];if(!f||c.isArray(d))f=c.data(a,b,c.makeArray(d));else f.push(d);return f}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),f=d.shift();if(f==="inprogress")f=d.shift();if(f){b==="fx"&&d.unshift("inprogress");f.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b===
|
$('input[type=button].stopwatch_reset').click(function() { stopwatch.reset(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']);
|
$('input[type=button].stopwatch_toggle').click(function() { if (stopwatch.elapsedTime == 0) { stopwatch.stop(); stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); } else if (typeof stopwatch.timerID == 'number') { stopwatch.stop(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); } else { stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); }
|
$('input[type=button].stopwatch_reset').click(function() { stopwatch.reset(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); });
|
$('input[type=checkbox].check_all').click(function() { var matchingName = $(this).attr('name').replace(/_all$/, ''); $(this).closest('form').find('input[type=checkbox][name=' + matchingName + '\[\]]').attr('checked', this.checked);
|
$('input[type=button].stopwatch_toggle').click(function() { if (stopwatch.elapsedTime == 0) { stopwatch.stop(); stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); } else if (typeof stopwatch.timerID == 'number') { stopwatch.stop(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); } else { stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); }
|
$('input[type=checkbox].check_all').click(function() { var matchingName = $(this).attr('name').replace(/_all$/, ''); $(this).closest('form').find('input[type=checkbox][name=' + matchingName + '\[\]]').attr('checked', this.checked); });
|
test_async('should handle error returned with callback from iterfunction', function (content, callback) {
|
test_async('should handle error returned with callback from iterfunction', function (context, complete) {
|
test_async('should handle error returned with callback from iterfunction', function (content, callback) { var list = []; for (var i = 0; i < 100; i++) { list.push(i); } var been_here = false; reduce(list, function (p, c, idx, list, callback) { callback('raised error'); }, 0, function (error, actual) { assertIsFalse(been_here, callback); been_here = true; assertIsTrue(error, callback); callback(); } ); });
|
assertIsFalse(been_here, callback);
|
assertIsFalse(been_here, complete);
|
test_async('should handle error returned with callback from iterfunction', function (content, callback) { var list = []; for (var i = 0; i < 100; i++) { list.push(i); } var been_here = false; reduce(list, function (p, c, idx, list, callback) { callback('raised error'); }, 0, function (error, actual) { assertIsFalse(been_here, callback); been_here = true; assertIsTrue(error, callback); callback(); } ); });
|
assertIsTrue(error, callback); callback();
|
assertIsTrue(error, complete); end_async_test(complete);
|
test_async('should handle error returned with callback from iterfunction', function (content, callback) { var list = []; for (var i = 0; i < 100; i++) { list.push(i); } var been_here = false; reduce(list, function (p, c, idx, list, callback) { callback('raised error'); }, 0, function (error, actual) { assertIsFalse(been_here, callback); been_here = true; assertIsTrue(error, callback); callback(); } ); });
|
});$("span",oSettings.nPaginate).bind("mousedown",function(){return false});$("span",oSettings.nPaginate).bind("selectstart",function(){return false
|
}});$(nNext).click(function(){if(oSettings.oApi._fnPageChange(oSettings,"next")){fnCallbackDraw(oSettings) }});$(nLast).click(function(){if(oSettings.oApi._fnPageChange(oSettings,"last")){fnCallbackDraw(oSettings)
|
});$("span",oSettings.nPaginate).bind("mousedown",function(){return false});$("span",oSettings.nPaginate).bind("selectstart",function(){return false
|
$('input[type=button].stopwatch_toggle').click(function() { if (stopwatch.elapsedTime == 0) { stopwatch.stop(); stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); } else if (typeof stopwatch.timerID == 'number') { stopwatch.stop(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); } else { stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); }
|
$('input[type=checkbox].check_all').click(function() { var matchingName = $(this).attr('name').replace(/_all$/, ''); $(this).closest('form').find('input[type=checkbox][name=' + matchingName + '\[\]]').attr('checked', this.checked);
|
$('input[type=button].stopwatch_toggle').click(function() { if (stopwatch.elapsedTime == 0) { stopwatch.stop(); stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); } else if (typeof stopwatch.timerID == 'number') { stopwatch.stop(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); } else { stopwatch.start(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_stop']); } });
|
this._redisClient.get(lockKey, bind(this, function(err, queryIsHeld) { if (err) { throw logger.error('could not check for query lock', lockKey, err) } if (queryIsHeld) { return } logger.log('Publish request for query observer to monitor this query', queryJSON) this._redisClient.publish(shared.keys.queryRequestChannel, queryJSON) }))
|
this._retrieveSet(key, function(members) { callback({ id: key, op: 'sadd', args: members }) })
|
this._redisClient.get(lockKey, bind(this, function(err, queryIsHeld) { if (err) { throw logger.error('could not check for query lock', lockKey, err) } if (queryIsHeld) { return } logger.log('Publish request for query observer to monitor this query', queryJSON) this._redisClient.publish(shared.keys.queryRequestChannel, queryJSON) }))
|
g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
f,this._uiHash(this.fromOutside))});if((this.fromOutside||this.domPosition.prev!=this.currentItem.prev().not(".ui-sortable-helper")[0]||this.domPosition.parent!=this.currentItem.parent()[0])&&!b)c.push(function(f){this._trigger("update",f,this._uiHash())});if(!d.ui.contains(this.element[0],this.currentItem[0])){b||c.push(function(f){this._trigger("remove",f,this._uiHash())});for(e=this.containers.length-1;e>=0;e--)if(d.ui.contains(this.containers[e].element[0],this.currentItem[0])&&!b){c.push(function(f){return function(g){f._trigger("receive",
|
g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!kb.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return w;if((b==="width"||b==="height")&&parseFloat(d)<0)d=w;var f=a.style||a,e=d!==w;if(!c.support.opacity&&b==="opacity"){if(e){f.zoom=1;b=parseInt(d,10)+""==="NaN"?"":"alpha(opacity="+d*100+")";a=f.filter||c.curCSS(a,"filter")||"";f.filter=
|
c(this),e=d.html();d.replaceWith(a.call(this,b,e))});if(typeof a!=="string")a=c(a).detach();return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){var e,f,h,l=a[0],k=[];if(!c.support.checkClone&&arguments.length===3&&typeof l==="string"&&Da.test(l))return this.each(function(){c(this).domManip(a, b,d,true)});if(c.isFunction(l))return this.each(function(x){var r=c(this);a[0]=l.call(this,x,b?r.html():B);r.domManip(a,b,d)});if(this[0]){e=l&&l.parentNode;e=c.support.parentNode&&e&&e.nodeType===11&&e.childNodes.length===this.length?{fragment:e}:c.buildFragment(a,this,k);h=e.fragment;if(f=h.childNodes.length===1?h=h.firstChild:h.firstChild){b=b&&c.nodeName(f,"tr");f=0;for(var o=this.length;f<o;f++)d.call(b?c.nodeName(this[f],"table")?this[f].getElementsByTagName("tbody")[0]||this[f].appendChild(this[f].ownerDocument.createElement("tbody")):
|
function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!kb.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return w;if((b==="width"||b==="height")&&parseFloat(d)<0)d=w;var f=a.style||a,e=d!==w;if(!c.support.opacity&&b==="opacity"){if(e){f.zoom=1;b=parseInt(d,10)+""==="NaN"?"":"alpha(opacity="+d*100+")";a=f.filter||c.curCSS(a,"filter")||"";f.filter=
|
Na.test(a)?a.replace(Na,b):b}return f.filter&&f.filter.indexOf("opacity=")>=0?parseFloat(Oa.exec(f.filter)[1])/100+"":""}if(ha.test(b))b=Pa;b=b.replace(ia,ja);if(e)f[b]=d;return f[b]},css:function(a,b,d,f){if(b==="width"||b==="height"){var e,j=b==="width"?pb:qb;function i(){e=b==="width"?a.offsetWidth:a.offsetHeight;f!=="border"&&c.each(j,function(){f||(e-=parseFloat(c.curCSS(a,"padding"+this,true))||0);if(f==="margin")e+=parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a, "border"+this+"Width",true))||0})}a.offsetWidth!==0?i():c.swap(a,ob,i);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Oa.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ha.test(b))b=Pa;if(!d&&e&&e[b])f=e[b];else if(rb){if(ha.test(b))b="float";b=b.replace(lb,"-$1").toLowerCase();e=a.ownerDocument.defaultView;if(!e)return null;if(a=e.getComputedStyle(a,null))f=
|
b,d,true)});if(c.isFunction(l))return this.each(function(x){var r=c(this);a[0]=l.call(this,x,b?r.html():B);r.domManip(a,b,d)});if(this[0]){e=l&&l.parentNode;e=c.support.parentNode&&e&&e.nodeType===11&&e.childNodes.length===this.length?{fragment:e}:c.buildFragment(a,this,k);h=e.fragment;if(f=h.childNodes.length===1?h=h.firstChild:h.firstChild){b=b&&c.nodeName(f,"tr");f=0;for(var o=this.length;f<o;f++)d.call(b?c.nodeName(this[f],"table")?this[f].getElementsByTagName("tbody")[0]||this[f].appendChild(this[f].ownerDocument.createElement("tbody")):
|
Na.test(a)?a.replace(Na,b):b}return f.filter&&f.filter.indexOf("opacity=")>=0?parseFloat(Oa.exec(f.filter)[1])/100+"":""}if(ha.test(b))b=Pa;b=b.replace(ia,ja);if(e)f[b]=d;return f[b]},css:function(a,b,d,f){if(b==="width"||b==="height"){var e,j=b==="width"?pb:qb;function i(){e=b==="width"?a.offsetWidth:a.offsetHeight;f!=="border"&&c.each(j,function(){f||(e-=parseFloat(c.curCSS(a,"padding"+this,true))||0);if(f==="margin")e+=parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a,"border"+this+"Width",true))||0})}a.offsetWidth!==0?i():c.swap(a,ob,i);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Oa.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ha.test(b))b=Pa;if(!d&&e&&e[b])f=e[b];else if(rb){if(ha.test(b))b="float";b=b.replace(lb,"-$1").toLowerCase();e=a.ownerDocument.defaultView;if(!e)return null;if(a=e.getComputedStyle(a,null))f=
|
g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
(function(a){a.widget("ui.accordion",{_init:function(){var d=this.options,b=this;this.running=0;if(d.collapsible==a.ui.accordion.defaults.collapsible&&d.alwaysOpen!=a.ui.accordion.defaults.alwaysOpen){d.collapsible=!d.alwaysOpen}if(d.navigation){var c=this.element.find("a").filter(d.navigationFilter);if(c.length){if(c.filter(d.header).length){this.active=c}else{this.active=c.parent().parent().prev();c.addClass("ui-accordion-content-active")}}}this.element.addClass("ui-accordion ui-widget ui-helper-reset");if(this.element[0].nodeName=="UL"){this.element.children("li").addClass("ui-accordion-li-fix")}this.headers=this.element.find(d.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){a(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){a(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){a(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){a(this).removeClass("ui-state-focus")});this.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");this.active=this._findActive(this.active||d.active).toggleClass("ui-state-default").toggleClass("ui-state-active").toggleClass("ui-corner-all").toggleClass("ui-corner-top");this.active.next().addClass("ui-accordion-content-active");a("<span/>").addClass("ui-icon "+d.icons.header).prependTo(this.headers);this.active.find(".ui-icon").toggleClass(d.icons.header).toggleClass(d.icons.headerSelected);if(a.browser.msie){this.element.find("a").css("zoom","1")}this.resize();this.element.attr("role","tablist");this.headers.attr("role","tab").bind("keydown",function(e){return b._keydown(e)}).next().attr("role","tabpanel");this.headers.not(this.active||"").attr("aria-expanded","false").attr("tabIndex","-1").next().hide();if(!this.active.length){this.headers.eq(0).attr("tabIndex","0")}else{this.active.attr("aria-expanded","true").attr("tabIndex","0")}if(!a.browser.safari){this.headers.find("a").attr("tabIndex","-1")}if(d.event){this.headers.bind((d.event)+".accordion",function(e){return b._clickHandler.call(b,e,this)})}},destroy:function(){var c=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role").unbind(".accordion").removeData("accordion");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabindex");this.headers.find("a").removeAttr("tabindex");this.headers.children(".ui-icon").remove();var b=this.headers.next().css("display","").removeAttr("role").removeClass("ui-helper-reset ui-widget-content ui-corner-bottom ui-accordion-content ui-accordion-content-active");if(c.autoHeight||c.fillHeight){b.css("height","")}},_setData:function(b,c){if(b=="alwaysOpen"){b="collapsible";c=!c}a.widget.prototype._setData.apply(this,arguments)},_keydown:function(e){var g=this.options,f=a.ui.keyCode;if(g.disabled||e.altKey||e.ctrlKey){return}var d=this.headers.length;var b=this.headers.index(e.target);var c=false;switch(e.keyCode){case f.RIGHT:case f.DOWN:c=this.headers[(b+1)%d];break;case f.LEFT:case f.UP:c=this.headers[(b-1+d)%d];break;case f.SPACE:case f.ENTER:return this._clickHandler({target:e.target},e.target)}if(c){a(e.target).attr("tabIndex","-1");a(c).attr("tabIndex","0");c.focus();return false}return true},resize:function(){var e=this.options,d;if(e.fillSpace){if(a.browser.msie){var b=this.element.parent().css("overflow");this.element.parent().css("overflow","hidden")}d=this.element.parent().height();if(a.browser.msie){this.element.parent().css("overflow",b)}this.headers.each(function(){d-=a(this).outerHeight()});var c=0;this.headers.next().each(function(){c=Math.max(c,a(this).innerHeight()-a(this).height())}).height(Math.max(0,d-c)).css("overflow","auto")}else{if(e.autoHeight){d=0;this.headers.next().each(function(){d=Math.max(d,a(this).outerHeight())}).height(d)}}},activate:function(b){var c=this._findActive(b)[0];this._clickHandler({target:c},c)},_findActive:function(b){return b?typeof b=="number"?this.headers.filter(":eq("+b+")"):this.headers.not(this.headers.not(b)):b===false?a([]):this.headers.filter(":eq(0)")},_clickHandler:function(b,f){var d=this.options;if(d.disabled){return false}if(!b.target&&d.collapsible){this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").find(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);this.active.next().addClass("ui-accordion-content-active");var h=this.active.next(),e={options:d,newHeader:a([]),oldHeader:d.active,newContent:a([]),oldContent:h},c=(this.active=a([]));this._toggle(c,h,e);return false}var g=a(b.currentTarget||f);var i=g[0]==this.active[0];if(this.running||(!d.collapsible&&i)){return false}this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").find(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);this.active.next().addClass("ui-accordion-content-active");if(!i){g.removeClass("ui-state-default ui-corner-all").addClass("ui-state-active ui-corner-top").find(".ui-icon").removeClass(d.icons.header).addClass(d.icons.headerSelected);g.next().addClass("ui-accordion-content-active")}var c=g.next(),h=this.active.next(),e={options:d,newHeader:i&&d.collapsible?a([]):g,oldHeader:this.active,newContent:i&&d.collapsible?a([]):c.find("> *"),oldContent:h.find("> *")},j=this.headers.index(this.active[0])>this.headers.index(g[0]);this.active=i?a([]):g;this._toggle(c,h,e,i,j);return false},_toggle:function(b,i,g,j,k){var d=this.options,m=this;this.toShow=b;this.toHide=i;this.data=g;var c=function(){if(!m){return}return m._completed.apply(m,arguments)};this._trigger("changestart",null,this.data);this.running=i.size()===0?b.size():i.size();if(d.animated){var f={};if(d.collapsible&&j){f={toShow:a([]),toHide:i,complete:c,down:k,autoHeight:d.autoHeight||d.fillSpace}}else{f={toShow:b,toHide:i,complete:c,down:k,autoHeight:d.autoHeight||d.fillSpace}}if(!d.proxied){d.proxied=d.animated}if(!d.proxiedDuration){d.proxiedDuration=d.duration}d.animated=a.isFunction(d.proxied)?d.proxied(f):d.proxied;d.duration=a.isFunction(d.proxiedDuration)?d.proxiedDuration(f):d.proxiedDuration;var l=a.ui.accordion.animations,e=d.duration,h=d.animated;if(!l[h]){l[h]=function(n){this.slide(n,{easing:h,duration:e||700})}}l[h](f)}else{if(d.collapsible&&j){b.toggle()}else{i.hide();b.show()}c(true)}i.prev().attr("aria-expanded","false").attr("tabIndex","-1").blur();b.prev().attr("aria-expanded","true").attr("tabIndex","0").focus()},_completed:function(b){var c=this.options;this.running=b?0:--this.running;if(this.running){return}if(c.clearStyle){this.toShow.add(this.toHide).css({height:"",overflow:""})}this._trigger("change",null,this.data)}});a.extend(a.ui.accordion,{version:"1.7.2",defaults:{active:null,alwaysOpen:true,animated:"slide",autoHeight:true,clearStyle:false,collapsible:false,event:"click",fillSpace:false,header:"> li > :first-child,> :not(li):even",icons:{header:"ui-icon-triangle-1-e",headerSelected:"ui-icon-triangle-1-s"},navigation:false,navigationFilter:function(){return this.href.toLowerCase()==location.href.toLowerCase()}},animations:{slide:function(j,h){j=a.extend({easing:"swing",duration:300},j,h);if(!j.toHide.size()){j.toShow.animate({height:"show"},j);return}if(!j.toShow.size()){j.toHide.animate({height:"hide"},j);return}var c=j.toShow.css("overflow"),g,d={},f={},e=["height","paddingTop","paddingBottom"],b;var i=j.toShow;b=i[0].style.width;i.width(parseInt(i.parent().width(),10)-parseInt(i.css("paddingLeft"),10)-parseInt(i.css("paddingRight"),10)-(parseInt(i.css("borderLeftWidth"),10)||0)-(parseInt(i.css("borderRightWidth"),10)||0));a.each(e,function(k,m){f[m]="hide";var l=(""+a.css(j.toShow[0],m)).match(/^([\d+-.]+)(.*)$/);d[m]={value:l[1],unit:l[2]||"px"}});j.toShow.css({height:0,overflow:"hidden"}).show();j.toHide.filter(":hidden").each(j.complete).end().filter(":visible").animate(f,{step:function(k,l){if(l.prop=="height"){g=(l.now-l.start)/(l.end-l.start)}j.toShow[0].style[l.prop]=(g*d[l.prop].value)+d[l.prop].unit},duration:j.duration,easing:j.easing,complete:function(){if(!j.autoHeight){j.toShow.css("height","")}j.toShow.css("width",b);j.toShow.css({overflow:c});j.complete()}})},bounceslide:function(b){this.slide(b,{easing:b.down?"easeOutBounce":"swing",duration:b.down?1000:200})},easeslide:function(b){this.slide(b,{easing:"easeinout",duration:700})}}})})(jQuery);;/*
|
g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
|
prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var e=[];d=c(d);var f=this.length===1&&this[0].parentNode;if(f&&f.nodeType===11&&f.childNodes.length===1&&d.length===1){d[b](this[0]);return this}else{f=0;for(var h=d.length;f<h;f++){var l=(f>0?this.clone(true):this).get();c(d[f])[b](l);e=e.concat(l)}return this.pushStack(e,a,d.selector)}}});c.extend({clean:function(a,b,d,e){b=b||t;if(typeof b.createElement==="undefined")b=b.ownerDocument||
|
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
|
jQuery.effects||function(f,j){function l(c){var a;if(c&&c.constructor==Array&&c.length==3)return c;if(a=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(c))return[parseInt(a[1],10),parseInt(a[2],10),parseInt(a[3],10)];if(a=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(c))return[parseFloat(a[1])*2.55,parseFloat(a[2])*2.55,parseFloat(a[3])*2.55];if(a=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(c))return[parseInt(a[1], 16),parseInt(a[2],16),parseInt(a[3],16)];if(a=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(c))return[parseInt(a[1]+a[1],16),parseInt(a[2]+a[2],16),parseInt(a[3]+a[3],16)];if(/rgba\(0, 0, 0, 0\)/.exec(c))return m.transparent;return m[f.trim(c).toLowerCase()]}function r(c,a){var b;do{b=f.curCSS(c,a);if(b!=""&&b!="transparent"||f.nodeName(c,"body"))break;a="backgroundColor"}while(c=c.parentNode);return l(b)}function n(){var c=document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle, a={},b,d;if(c&&c.length&&c[0]&&c[c[0]])for(var e=c.length;e--;){b=c[e];if(typeof c[b]=="string"){d=b.replace(/\-(\w)/g,function(g,h){return h.toUpperCase()});a[d]=c[b]}}else for(b in c)if(typeof c[b]==="string")a[b]=c[b];return a}function o(c){var a,b;for(a in c){b=c[a];if(b==null||f.isFunction(b)||a in s||/scrollbar/.test(a)||!/color/i.test(a)&&isNaN(parseFloat(b)))delete c[a]}return c}function t(c,a){var b={_:0},d;for(d in a)if(c[d]!=a[d])b[d]=a[d];return b}function k(c,a,b,d){if(typeof c=="object"){d= a;b=null;a=c;c=a.effect}if(f.isFunction(a)){d=a;b=null;a={}}if(typeof a=="number"||f.fx.speeds[a]){d=b;b=a;a={}}if(f.isFunction(b)){d=b;b=null}a=a||{};b=b||a.duration;b=f.fx.off?0:typeof b=="number"?b:f.fx.speeds[b]||f.fx.speeds._default;d=d||a.complete;return[c,a,b,d]}f.effects={};f.each(["backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","color","outlineColor"],function(c,a){f.fx.step[a]=function(b){if(!b.colorInit){b.start=r(b.elem,a);b.end=l(b.end);b.colorInit= true}b.elem.style[a]="rgb("+Math.max(Math.min(parseInt(b.pos*(b.end[0]-b.start[0])+b.start[0],10),255),0)+","+Math.max(Math.min(parseInt(b.pos*(b.end[1]-b.start[1])+b.start[1],10),255),0)+","+Math.max(Math.min(parseInt(b.pos*(b.end[2]-b.start[2])+b.start[2],10),255),0)+")"}});var m={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189, 183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255, 165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0],transparent:[255,255,255]},p=["add","remove","toggle"],s={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};f.effects.animateClass=function(c,a,b,d){if(f.isFunction(b)){d=b;b=null}return this.each(function(){var e=f(this),g=e.attr("style")||" ",h=o(n.call(this)),q,u=e.attr("className");f.each(p,function(v, i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a? f.effects.animateClass.apply(this,[{remove:c},a,b,d]):this._removeClass(c)},_toggleClass:f.fn.toggleClass,toggleClass:function(c,a,b,d,e){return typeof a=="boolean"||a===j?b?f.effects.animateClass.apply(this,[a?{add:c}:{remove:c},b,d,e]):this._toggleClass(c,a):f.effects.animateClass.apply(this,[{toggle:c},a,b,d])},switchClass:function(c,a,b,d,e){return f.effects.animateClass.apply(this,[{add:a,remove:c},b,d,e])}});f.extend(f.effects,{version:"1.8.4",save:function(c,a){for(var b=0;b<a.length;b++)a[b]!== null&&c.data("ec.storage."+a[b],c[0].style[a[b]])},restore:function(c,a){for(var b=0;b<a.length;b++)a[b]!==null&&c.css(a[b],c.data("ec.storage."+a[b]))},setMode:function(c,a){if(a=="toggle")a=c.is(":hidden")?"show":"hide";return a},getBaseline:function(c,a){var b;switch(c[0]){case "top":b=0;break;case "middle":b=0.5;break;case "bottom":b=1;break;default:b=c[0]/a.height}switch(c[1]){case "left":c=0;break;case "center":c=0.5;break;case "right":c=1;break;default:c=c[1]/a.width}return{x:c,y:b}},createWrapper:function(c){if(c.parent().is(".ui-effects-wrapper"))return c.parent(); var a={width:c.outerWidth(true),height:c.outerHeight(true),"float":c.css("float")},b=f("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0});c.wrap(b);b=c.parent();if(c.css("position")=="static"){b.css({position:"relative"});c.css({position:"relative"})}else{f.extend(a,{position:c.css("position"),zIndex:c.css("z-index")});f.each(["top","left","bottom","right"],function(d,e){a[e]=c.css(e);if(isNaN(parseInt(a[e],10)))a[e]="auto"}); c.css({position:"relative",top:0,left:0})}return b.css(a).show()},removeWrapper:function(c){if(c.parent().is(".ui-effects-wrapper"))return c.parent().replaceWith(c);return c},setTransition:function(c,a,b,d){d=d||{};f.each(a,function(e,g){unit=c.cssUnit(g);if(unit[0]>0)d[g]=unit[0]*b+unit[1]});return d}});f.fn.extend({effect:function(c){var a=k.apply(this,arguments);a={options:a[1],duration:a[2],callback:a[3]};var b=f.effects[c];return b&&!f.fx.off?b.call(this,a):this},_show:f.fn.show,show:function(c){if(!c|| typeof c=="number"||f.fx.speeds[c])return this._show.apply(this,arguments);else{var a=k.apply(this,arguments);a[1].mode="show";return this.effect.apply(this,a)}},_hide:f.fn.hide,hide:function(c){if(!c||typeof c=="number"||f.fx.speeds[c])return this._hide.apply(this,arguments);else{var a=k.apply(this,arguments);a[1].mode="hide";return this.effect.apply(this,a)}},__toggle:f.fn.toggle,toggle:function(c){if(!c||typeof c=="number"||f.fx.speeds[c]||typeof c=="boolean"||f.isFunction(c))return this.__toggle.apply(this, arguments);else{var a=k.apply(this,arguments);a[1].mode="toggle";return this.effect.apply(this,a)}},cssUnit:function(c){var a=this.css(c),b=[];f.each(["em","px","%","pt"],function(d,e){if(a.indexOf(e)>0)b=[parseFloat(a),e]});return b}});f.easing.jswing=f.easing.swing;f.extend(f.easing,{def:"easeOutQuad",swing:function(c,a,b,d,e){return f.easing[f.easing.def](c,a,b,d,e)},easeInQuad:function(c,a,b,d,e){return d*(a/=e)*a+b},easeOutQuad:function(c,a,b,d,e){return-d*(a/=e)*(a-2)+b},easeInOutQuad:function(c, a,b,d,e){if((a/=e/2)<1)return d/2*a*a+b;return-d/2*(--a*(a-2)-1)+b},easeInCubic:function(c,a,b,d,e){return d*(a/=e)*a*a+b},easeOutCubic:function(c,a,b,d,e){return d*((a=a/e-1)*a*a+1)+b},easeInOutCubic:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a*a+b;return d/2*((a-=2)*a*a+2)+b},easeInQuart:function(c,a,b,d,e){return d*(a/=e)*a*a*a+b},easeOutQuart:function(c,a,b,d,e){return-d*((a=a/e-1)*a*a*a-1)+b},easeInOutQuart:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a*a*a+b;return-d/2*((a-=2)*a*a*a-2)+ b},easeInQuint:function(c,a,b,d,e){return d*(a/=e)*a*a*a*a+b},easeOutQuint:function(c,a,b,d,e){return d*((a=a/e-1)*a*a*a*a+1)+b},easeInOutQuint:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a*a*a*a+b;return d/2*((a-=2)*a*a*a*a+2)+b},easeInSine:function(c,a,b,d,e){return-d*Math.cos(a/e*(Math.PI/2))+d+b},easeOutSine:function(c,a,b,d,e){return d*Math.sin(a/e*(Math.PI/2))+b},easeInOutSine:function(c,a,b,d,e){return-d/2*(Math.cos(Math.PI*a/e)-1)+b},easeInExpo:function(c,a,b,d,e){return a==0?b:d*Math.pow(2, 10*(a/e-1))+b},easeOutExpo:function(c,a,b,d,e){return a==e?b+d:d*(-Math.pow(2,-10*a/e)+1)+b},easeInOutExpo:function(c,a,b,d,e){if(a==0)return b;if(a==e)return b+d;if((a/=e/2)<1)return d/2*Math.pow(2,10*(a-1))+b;return d/2*(-Math.pow(2,-10*--a)+2)+b},easeInCirc:function(c,a,b,d,e){return-d*(Math.sqrt(1-(a/=e)*a)-1)+b},easeOutCirc:function(c,a,b,d,e){return d*Math.sqrt(1-(a=a/e-1)*a)+b},easeInOutCirc:function(c,a,b,d,e){if((a/=e/2)<1)return-d/2*(Math.sqrt(1-a*a)-1)+b;return d/2*(Math.sqrt(1-(a-=2)* a)+1)+b},easeInElastic:function(c,a,b,d,e){c=1.70158;var g=0,h=d;if(a==0)return b;if((a/=e)==1)return b+d;g||(g=e*0.3);if(h<Math.abs(d)){h=d;c=g/4}else c=g/(2*Math.PI)*Math.asin(d/h);return-(h*Math.pow(2,10*(a-=1))*Math.sin((a*e-c)*2*Math.PI/g))+b},easeOutElastic:function(c,a,b,d,e){c=1.70158;var g=0,h=d;if(a==0)return b;if((a/=e)==1)return b+d;g||(g=e*0.3);if(h<Math.abs(d)){h=d;c=g/4}else c=g/(2*Math.PI)*Math.asin(d/h);return h*Math.pow(2,-10*a)*Math.sin((a*e-c)*2*Math.PI/g)+d+b},easeInOutElastic:function(c, a,b,d,e){c=1.70158;var g=0,h=d;if(a==0)return b;if((a/=e/2)==2)return b+d;g||(g=e*0.3*1.5);if(h<Math.abs(d)){h=d;c=g/4}else c=g/(2*Math.PI)*Math.asin(d/h);if(a<1)return-0.5*h*Math.pow(2,10*(a-=1))*Math.sin((a*e-c)*2*Math.PI/g)+b;return h*Math.pow(2,-10*(a-=1))*Math.sin((a*e-c)*2*Math.PI/g)*0.5+d+b},easeInBack:function(c,a,b,d,e,g){if(g==j)g=1.70158;return d*(a/=e)*a*((g+1)*a-g)+b},easeOutBack:function(c,a,b,d,e,g){if(g==j)g=1.70158;return d*((a=a/e-1)*a*((g+1)*a+g)+1)+b},easeInOutBack:function(c, a,b,d,e,g){if(g==j)g=1.70158;if((a/=e/2)<1)return d/2*a*a*(((g*=1.525)+1)*a-g)+b;return d/2*((a-=2)*a*(((g*=1.525)+1)*a+g)+2)+b},easeInBounce:function(c,a,b,d,e){return d-f.easing.easeOutBounce(c,e-a,0,d,e)+b},easeOutBounce:function(c,a,b,d,e){return(a/=e)<1/2.75?d*7.5625*a*a+b:a<2/2.75?d*(7.5625*(a-=1.5/2.75)*a+0.75)+b:a<2.5/2.75?d*(7.5625*(a-=2.25/2.75)*a+0.9375)+b:d*(7.5625*(a-=2.625/2.75)*a+0.984375)+b},easeInOutBounce:function(c,a,b,d,e){if(a<e/2)return f.easing.easeInBounce(c,a*2,0,d,e)*0.5+ b;return f.easing.easeOutBounce(c,a*2-e,0,d,e)*0.5+d*0.5+b}})}(jQuery);
|
f,this._uiHash(this.fromOutside))});if((this.fromOutside||this.domPosition.prev!=this.currentItem.prev().not(".ui-sortable-helper")[0]||this.domPosition.parent!=this.currentItem.parent()[0])&&!b)c.push(function(f){this._trigger("update",f,this._uiHash())});if(!d.ui.contains(this.element[0],this.currentItem[0])){b||c.push(function(f){this._trigger("remove",f,this._uiHash())});for(e=this.containers.length-1;e>=0;e--)if(d.ui.contains(this.containers[e].element[0],this.currentItem[0])&&!b){c.push(function(f){return function(g){f._trigger("receive", g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
jQuery.effects||function(f,j){function l(c){var a;if(c&&c.constructor==Array&&c.length==3)return c;if(a=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(c))return[parseInt(a[1],10),parseInt(a[2],10),parseInt(a[3],10)];if(a=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(c))return[parseFloat(a[1])*2.55,parseFloat(a[2])*2.55,parseFloat(a[3])*2.55];if(a=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(c))return[parseInt(a[1],16),parseInt(a[2],16),parseInt(a[3],16)];if(a=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(c))return[parseInt(a[1]+a[1],16),parseInt(a[2]+a[2],16),parseInt(a[3]+a[3],16)];if(/rgba\(0, 0, 0, 0\)/.exec(c))return m.transparent;return m[f.trim(c).toLowerCase()]}function r(c,a){var b;do{b=f.curCSS(c,a);if(b!=""&&b!="transparent"||f.nodeName(c,"body"))break;a="backgroundColor"}while(c=c.parentNode);return l(b)}function n(){var c=document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle,a={},b,d;if(c&&c.length&&c[0]&&c[c[0]])for(var e=c.length;e--;){b=c[e];if(typeof c[b]=="string"){d=b.replace(/\-(\w)/g,function(g,h){return h.toUpperCase()});a[d]=c[b]}}else for(b in c)if(typeof c[b]==="string")a[b]=c[b];return a}function o(c){var a,b;for(a in c){b=c[a];if(b==null||f.isFunction(b)||a in s||/scrollbar/.test(a)||!/color/i.test(a)&&isNaN(parseFloat(b)))delete c[a]}return c}function t(c,a){var b={_:0},d;for(d in a)if(c[d]!=a[d])b[d]=a[d];return b}function k(c,a,b,d){if(typeof c=="object"){d=a;b=null;a=c;c=a.effect}if(f.isFunction(a)){d=a;b=null;a={}}if(typeof a=="number"||f.fx.speeds[a]){d=b;b=a;a={}}if(f.isFunction(b)){d=b;b=null}a=a||{};b=b||a.duration;b=f.fx.off?0:typeof b=="number"?b:f.fx.speeds[b]||f.fx.speeds._default;d=d||a.complete;return[c,a,b,d]}f.effects={};f.each(["backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","color","outlineColor"],function(c,a){f.fx.step[a]=function(b){if(!b.colorInit){b.start=r(b.elem,a);b.end=l(b.end);b.colorInit=true}b.elem.style[a]="rgb("+Math.max(Math.min(parseInt(b.pos*(b.end[0]-b.start[0])+b.start[0],10),255),0)+","+Math.max(Math.min(parseInt(b.pos*(b.end[1]-b.start[1])+b.start[1],10),255),0)+","+Math.max(Math.min(parseInt(b.pos*(b.end[2]-b.start[2])+b.start[2],10),255),0)+")"}});var m={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0],transparent:[255,255,255]},p=["add","remove","toggle"],s={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};f.effects.animateClass=function(c,a,b,d){if(f.isFunction(b)){d=b;b=null}return this.each(function(){var e=f(this),g=e.attr("style")||" ",h=o(n.call(this)),q,u=e.attr("className");f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{remove:c},a,b,d]):this._removeClass(c)},_toggleClass:f.fn.toggleClass,toggleClass:function(c,a,b,d,e){return typeof a=="boolean"||a===j?b?f.effects.animateClass.apply(this,[a?{add:c}:{remove:c},b,d,e]):this._toggleClass(c,a):f.effects.animateClass.apply(this,[{toggle:c},a,b,d])},switchClass:function(c,a,b,d,e){return f.effects.animateClass.apply(this,[{add:a,remove:c},b,d,e])}});f.extend(f.effects,{version:"1.8.4",save:function(c,a){for(var b=0;b<a.length;b++)a[b]!==null&&c.data("ec.storage."+a[b],c[0].style[a[b]])},restore:function(c,a){for(var b=0;b<a.length;b++)a[b]!==null&&c.css(a[b],c.data("ec.storage."+a[b]))},setMode:function(c,a){if(a=="toggle")a=c.is(":hidden")?"show":"hide";return a},getBaseline:function(c,a){var b;switch(c[0]){case "top":b=0;break;case "middle":b=0.5;break;case "bottom":b=1;break;default:b=c[0]/a.height}switch(c[1]){case "left":c=0;break;case "center":c=0.5;break;case "right":c=1;break;default:c=c[1]/a.width}return{x:c,y:b}},createWrapper:function(c){if(c.parent().is(".ui-effects-wrapper"))return c.parent();var a={width:c.outerWidth(true),height:c.outerHeight(true),"float":c.css("float")},b=f("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0});c.wrap(b);b=c.parent();if(c.css("position")=="static"){b.css({position:"relative"});c.css({position:"relative"})}else{f.extend(a,{position:c.css("position"),zIndex:c.css("z-index")});f.each(["top","left","bottom","right"],function(d,e){a[e]=c.css(e);if(isNaN(parseInt(a[e],10)))a[e]="auto"});c.css({position:"relative",top:0,left:0})}return b.css(a).show()},removeWrapper:function(c){if(c.parent().is(".ui-effects-wrapper"))return c.parent().replaceWith(c);return c},setTransition:function(c,a,b,d){d=d||{};f.each(a,function(e,g){unit=c.cssUnit(g);if(unit[0]>0)d[g]=unit[0]*b+unit[1]});return d}});f.fn.extend({effect:function(c){var a=k.apply(this,arguments);a={options:a[1],duration:a[2],callback:a[3]};var b=f.effects[c];return b&&!f.fx.off?b.call(this,a):this},_show:f.fn.show,show:function(c){if(!c||typeof c=="number"||f.fx.speeds[c])return this._show.apply(this,arguments);else{var a=k.apply(this,arguments);a[1].mode="show";return this.effect.apply(this,a)}},_hide:f.fn.hide,hide:function(c){if(!c||typeof c=="number"||f.fx.speeds[c])return this._hide.apply(this,arguments);else{var a=k.apply(this,arguments);a[1].mode="hide";return this.effect.apply(this,a)}},__toggle:f.fn.toggle,toggle:function(c){if(!c||typeof c=="number"||f.fx.speeds[c]||typeof c=="boolean"||f.isFunction(c))return this.__toggle.apply(this,arguments);else{var a=k.apply(this,arguments);a[1].mode="toggle";return this.effect.apply(this,a)}},cssUnit:function(c){var a=this.css(c),b=[];f.each(["em","px","%","pt"],function(d,e){if(a.indexOf(e)>0)b=[parseFloat(a),e]});return b}});f.easing.jswing=f.easing.swing;f.extend(f.easing,{def:"easeOutQuad",swing:function(c,a,b,d,e){return f.easing[f.easing.def](c,a,b,d,e)},easeInQuad:function(c,a,b,d,e){return d*(a/=e)*a+b},easeOutQuad:function(c,a,b,d,e){return-d*(a/=e)*(a-2)+b},easeInOutQuad:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a+b;return-d/2*(--a*(a-2)-1)+b},easeInCubic:function(c,a,b,d,e){return d*(a/=e)*a*a+b},easeOutCubic:function(c,a,b,d,e){return d*((a=a/e-1)*a*a+1)+b},easeInOutCubic:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a*a+b;return d/2*((a-=2)*a*a+2)+b},easeInQuart:function(c,a,b,d,e){return d*(a/=e)*a*a*a+b},easeOutQuart:function(c,a,b,d,e){return-d*((a=a/e-1)*a*a*a-1)+b},easeInOutQuart:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a*a*a+b;return-d/2*((a-=2)*a*a*a-2)+b},easeInQuint:function(c,a,b,d,e){return d*(a/=e)*a*a*a*a+b},easeOutQuint:function(c,a,b,d,e){return d*((a=a/e-1)*a*a*a*a+1)+b},easeInOutQuint:function(c,a,b,d,e){if((a/=e/2)<1)return d/2*a*a*a*a*a+b;return d/2*((a-=2)*a*a*a*a+2)+b},easeInSine:function(c,a,b,d,e){return-d*Math.cos(a/e*(Math.PI/2))+d+b},easeOutSine:function(c,a,b,d,e){return d*Math.sin(a/e*(Math.PI/2))+b},easeInOutSine:function(c,a,b,d,e){return-d/2*(Math.cos(Math.PI*a/e)-1)+b},easeInExpo:function(c,a,b,d,e){return a==0?b:d*Math.pow(2,10*(a/e-1))+b},easeOutExpo:function(c,a,b,d,e){return a==e?b+d:d*(-Math.pow(2,-10*a/e)+1)+b},easeInOutExpo:function(c,a,b,d,e){if(a==0)return b;if(a==e)return b+d;if((a/=e/2)<1)return d/2*Math.pow(2,10*(a-1))+b;return d/2*(-Math.pow(2,-10*--a)+2)+b},easeInCirc:function(c,a,b,d,e){return-d*(Math.sqrt(1-(a/=e)*a)-1)+b},easeOutCirc:function(c,a,b,d,e){return d*Math.sqrt(1-(a=a/e-1)*a)+b},easeInOutCirc:function(c,a,b,d,e){if((a/=e/2)<1)return-d/2*(Math.sqrt(1-a*a)-1)+b;return d/2*(Math.sqrt(1-(a-=2)*a)+1)+b},easeInElastic:function(c,a,b,d,e){c=1.70158;var g=0,h=d;if(a==0)return b;if((a/=e)==1)return b+d;g||(g=e*0.3);if(h<Math.abs(d)){h=d;c=g/4}else c=g/(2*Math.PI)*Math.asin(d/h);return-(h*Math.pow(2,10*(a-=1))*Math.sin((a*e-c)*2*Math.PI/g))+b},easeOutElastic:function(c,a,b,d,e){c=1.70158;var g=0,h=d;if(a==0)return b;if((a/=e)==1)return b+d;g||(g=e*0.3);if(h<Math.abs(d)){h=d;c=g/4}else c=g/(2*Math.PI)*Math.asin(d/h);return h*Math.pow(2,-10*a)*Math.sin((a*e-c)*2*Math.PI/g)+d+b},easeInOutElastic:function(c,a,b,d,e){c=1.70158;var g=0,h=d;if(a==0)return b;if((a/=e/2)==2)return b+d;g||(g=e*0.3*1.5);if(h<Math.abs(d)){h=d;c=g/4}else c=g/(2*Math.PI)*Math.asin(d/h);if(a<1)return-0.5*h*Math.pow(2,10*(a-=1))*Math.sin((a*e-c)*2*Math.PI/g)+b;return h*Math.pow(2,-10*(a-=1))*Math.sin((a*e-c)*2*Math.PI/g)*0.5+d+b},easeInBack:function(c,a,b,d,e,g){if(g==j)g=1.70158;return d*(a/=e)*a*((g+1)*a-g)+b},easeOutBack:function(c,a,b,d,e,g){if(g==j)g=1.70158;return d*((a=a/e-1)*a*((g+1)*a+g)+1)+b},easeInOutBack:function(c,a,b,d,e,g){if(g==j)g=1.70158;if((a/=e/2)<1)return d/2*a*a*(((g*=1.525)+1)*a-g)+b;return d/2*((a-=2)*a*(((g*=1.525)+1)*a+g)+2)+b},easeInBounce:function(c,a,b,d,e){return d-f.easing.easeOutBounce(c,e-a,0,d,e)+b},easeOutBounce:function(c,a,b,d,e){return(a/=e)<1/2.75?d*7.5625*a*a+b:a<2/2.75?d*(7.5625*(a-=1.5/2.75)*a+0.75)+b:a<2.5/2.75?d*(7.5625*(a-=2.25/2.75)*a+0.9375)+b:d*(7.5625*(a-=2.625/2.75)*a+0.984375)+b},easeInOutBounce:function(c,a,b,d,e){if(a<e/2)return f.easing.easeInBounce(c,a*2,0,d,e)*0.5+b;return f.easing.easeOutBounce(c,a*2-e,0,d,e)*0.5+d*0.5+b}})}(jQuery);
|
if(E){J=E;}if(this.browser.ie){H="formatblock";}if(I=="none"){if((J&&J.tagName&&(J.tagName.toLowerCase().substring(0,1)=="h"))||(J&&J.parentNode&&J.parentNode.tagName&&(J.parentNode.tagName.toLowerCase().substring(0,1)=="h"))){if(J.parentNode.tagName.toLowerCase().substring(0,1)=="h"){J=J.parentNode;}if(this._isElement(J,"html")){return[false];}G=this._swapEl(E,"span",function(K){K.className="yui-non";});this._selectNode(G);this.currentElement[0]=G;}F=false;}else{if(this._isElement(E,"h1")||this._isElement(E,"h2")||this._isElement(E,"h3")||this._isElement(E,"h4")||this._isElement(E,"h5")||this._isElement(E,"h6")){G=this._swapEl(E,I);this._selectNode(G);this.currentElement[0]=G;}else{this._createCurrentElement(I);this._selectNode(this.currentElement[0]);}F=false;}return[F,H];},cmd_hiddenelements:function(E){if(this._showingHiddenElements){this._lastButton=null;this._showingHiddenElements=false;this.toolbar.deselectButton("hiddenelements");C.removeClass(this._getDoc().body,this.CLASS_HIDDEN);}else{this._showingHiddenElements=true;C.addClass(this._getDoc().body,this.CLASS_HIDDEN);this.toolbar.selectButton("hiddenelements");}return[false];},cmd_removeformat:function(H){var F=true;if(this.browser.webkit&&!this._getDoc().queryCommandEnabled("removeformat")){var E=this._getSelection()+"";this._createCurrentElement("span");this.currentElement[0].className="yui-non";this.currentElement[0].innerHTML=E;for(var G=1;G<this.currentElement.length;G++){this.currentElement[G].parentNode.removeChild(this.currentElement[G]);}F=false;}return[F];},cmd_script:function(K,J){var G=true,E=K.toLowerCase().substring(0,3),H=null,F=this._getSelectedElement();if(this.browser.webkit){if(this._isElement(F,E)){H=this._swapEl(this.currentElement[0],"span",function(L){L.className="yui-non";});this._selectNode(H);}else{this._createCurrentElement(E);var I=this._swapEl(this.currentElement[0],E);this._selectNode(I);this.currentElement[0]=I;}G=false;}return G;},cmd_superscript:function(E){return[this.cmd_script("superscript",E)];},cmd_subscript:function(E){return[this.cmd_script("subscript",E)];},cmd_indent:function(H){var E=true,G=this._getSelectedElement(),I=null;if(this.browser.ie){if(this._isElement(G,"blockquote")){I=this._getDoc().createElement("blockquote");I.innerHTML=G.innerHTML;G.innerHTML="";G.appendChild(I);this._selectNode(I);}else{I=this._getDoc().createElement("blockquote");var F=this._getRange().htmlText;I.innerHTML=F;this._createCurrentElement("blockquote");this.currentElement[0].parentNode.replaceChild(I,this.currentElement[0]);this.currentElement[0]=I;this._selectNode(this.currentElement[0]);}E=false;}else{H="blockquote";}return[E,"formatblock",H];},cmd_outdent:function(I){var E=true,H=this._getSelectedElement(),J=null,F=null;if(this.browser.webkit||this.browser.ie){H=this._getSelectedElement();if(this._isElement(H,"blockquote")){var G=H.parentNode;if(this._isElement(H.parentNode,"blockquote")){G.innerHTML=H.innerHTML;this._selectNode(G);}else{F=this._getDoc().createElement("span");F.innerHTML=H.innerHTML;YAHOO.util.Dom.addClass(F,"yui-non");G.replaceChild(F,H);this._selectNode(F);}}else{}E=false;}else{I=false;}return[E,"outdent",I];},cmd_justify:function(E){if(this.browser.ie){if(this._hasSelection()){this._createCurrentElement("span");this._swapEl(this.currentElement[0],"div",function(F){F.style.textAlign=E;});return[false];}}return[true,"justify"+E,""];},cmd_justifycenter:function(){return[this.cmd_justify("center")];},cmd_justifyleft:function(){return[this.cmd_justify("left")];},cmd_justifyright:function(){return[this.cmd_justify("right")];},toString:function(){var E="Editor";if(this.get&&this.get("element_cont")){E="Editor (#"+this.get("element_cont").get("id")+")"+((this.get("disabled")?" Disabled":""));}return E;}});YAHOO.widget.EditorWindow=function(F,E){this.name=F.replace(" ","_");this.attrs=E;};YAHOO.widget.EditorWindow.prototype={header:null,body:null,footer:null,setHeader:function(E){this.header=E;},setBody:function(E){this.body=E;},setFooter:function(E){this.footer=E;},toString:function(){return"Editor Window ("+this.name+")";}};})();YAHOO.register("editor",YAHOO.widget.Editor,{version:"2.6.0",build:"1321"});
|
(function(){var b=YAHOO.util.Dom,a=YAHOO.util.Event,c=YAHOO.lang;if(YAHOO.widget.Button){YAHOO.widget.ToolbarButtonAdvanced=YAHOO.widget.Button;YAHOO.widget.ToolbarButtonAdvanced.prototype.buttonType="rich";YAHOO.widget.ToolbarButtonAdvanced.prototype.checkValue=function(f){var e=this.getMenu().getItems();if(e.length===0){this.getMenu()._onBeforeShow();e=this.getMenu().getItems()}for(var d=0;d<e.length;d++){e[d].cfg.setProperty("checked",false);if(e[d].value==f){e[d].cfg.setProperty("checked",true)}}}}else{YAHOO.widget.ToolbarButtonAdvanced=function(){}}YAHOO.widget.ToolbarButton=function(e,d){if(c.isObject(arguments[0])&&!b.get(e).nodeType){d=e}var g=(d||{});var f={element:null,attributes:g};if(!f.attributes.type){f.attributes.type="push"}f.element=document.createElement("span");f.element.setAttribute("unselectable","on");f.element.className="yui-button yui-"+f.attributes.type+"-button";f.element.innerHTML='<span class="first-child"><a href="#">LABEL</a></span>';f.element.firstChild.firstChild.tabIndex="-1";f.attributes.id=b.generateId();YAHOO.widget.ToolbarButton.superclass.constructor.call(this,f.element,f.attributes)};YAHOO.extend(YAHOO.widget.ToolbarButton,YAHOO.util.Element,{buttonType:"normal",_handleMouseOver:function(){if(!this.get("disabled")){this.addClass("yui-button-hover");this.addClass("yui-"+this.get("type")+"-button-hover")}},_handleMouseOut:function(){this.removeClass("yui-button-hover");this.removeClass("yui-"+this.get("type")+"-button-hover")},checkValue:function(f){if(this.get("type")=="menu"){var e=this._button.options;for(var d=0;d<e.length;d++){if(e[d].value==f){e.selectedIndex=d}}}},init:function(e,d){YAHOO.widget.ToolbarButton.superclass.init.call(this,e,d);this.on("mouseover",this._handleMouseOver,this,true);this.on("mouseout",this._handleMouseOut,this,true)},initAttributes:function(d){YAHOO.widget.ToolbarButton.superclass.initAttributes.call(this,d);this.setAttributeConfig("value",{value:d.value});this.setAttributeConfig("menu",{value:d.menu||false});this.setAttributeConfig("type",{value:d.type,writeOnce:true,method:function(h){var g,f;if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}switch(h){case"select":case"menu":g=document.createElement("select");var j=this.get("menu");for(var e=0;e<j.length;e++){f=document.createElement("option");f.innerHTML=j[e].text;f.value=j[e].value;if(j[e].checked){f.selected=true}g.appendChild(f)}this._button.parentNode.replaceChild(g,this._button);a.on(g,"change",this._handleSelect,this,true);this._button=g;break}}});this.setAttributeConfig("disabled",{value:d.disabled||false,method:function(e){if(e){this.addClass("yui-button-disabled");this.addClass("yui-"+this.get("type")+"-button-disabled")}else{this.removeClass("yui-button-disabled");this.removeClass("yui-"+this.get("type")+"-button-disabled")}if(this.get("type")=="menu"){this._button.disabled=e}}});this.setAttributeConfig("label",{value:d.label,method:function(e){if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}if(this.get("type")=="push"){this._button.innerHTML=e}}});this.setAttributeConfig("title",{value:d.title});this.setAttributeConfig("container",{value:null,writeOnce:true,method:function(e){this.appendTo(e)}})},_handleSelect:function(e){var d=a.getTarget(e);var f=d.options[d.selectedIndex].value;this.fireEvent("change",{type:"change",value:f})},getMenu:function(){return this.get("menu")},destroy:function(){a.purgeElement(this.get("element"),true);this.get("element").parentNode.removeChild(this.get("element"));for(var d in this){if(c.hasOwnProperty(this,d)){this[d]=null}}},fireEvent:function(e,d){if(this.DOM_EVENTS[e]&&this.get("disabled")){return}YAHOO.widget.ToolbarButton.superclass.fireEvent.call(this,e,d)},toString:function(){return"ToolbarButton ("+this.get("id")+")"}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang;var b=function(f){var e=f;if(d.isString(f)){e=this.getButtonById(f)}if(d.isNumber(f)){e=this.getButtonByIndex(f)}if((!(e instanceof YAHOO.widget.ToolbarButton))&&(!(e instanceof YAHOO.widget.ToolbarButtonAdvanced))){e=this.getButtonByValue(f)}if((e instanceof YAHOO.widget.ToolbarButton)||(e instanceof YAHOO.widget.ToolbarButtonAdvanced)){return e}return false};YAHOO.widget.Toolbar=function(i,h){if(d.isObject(arguments[0])&&!c.get(i).nodeType){h=i}var k={};if(h){d.augmentObject(k,h)}var j={element:null,attributes:k};if(d.isString(i)&&c.get(i)){j.element=c.get(i)}else{if(d.isObject(i)&&c.get(i)&&c.get(i).nodeType){j.element=c.get(i)}}if(!j.element){j.element=document.createElement("DIV");j.element.id=c.generateId();if(k.container&&c.get(k.container)){c.get(k.container).appendChild(j.element)}}if(!j.element.id){j.element.id=((d.isString(i))?i:c.generateId())}var f=document.createElement("fieldset");var g=document.createElement("legend");g.innerHTML="Toolbar";f.appendChild(g);var e=document.createElement("DIV");j.attributes.cont=e;c.addClass(e,"yui-toolbar-subcont");f.appendChild(e);j.element.appendChild(f);j.element.tabIndex=-1;j.attributes.element=j.element;j.attributes.id=j.element.id;YAHOO.widget.Toolbar.superclass.constructor.call(this,j.element,j.attributes)};YAHOO.extend(YAHOO.widget.Toolbar,YAHOO.util.Element,{_addMenuClasses:function(h,e,j){c.addClass(this.element,"yui-toolbar-"+j.get("value")+"-menu");if(c.hasClass(j._button.parentNode.parentNode,"yui-toolbar-select")){c.addClass(this.element,"yui-toolbar-select-menu")}var f=this.getItems();for(var g=0;g<f.length;g++){c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-").toLowerCase():f[g]._oText.nodeValue.replace(/ /g,"-").toLowerCase()));c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-"):f[g]._oText.nodeValue.replace(/ /g,"-")))}},buttonType:YAHOO.widget.ToolbarButton,dd:null,_colorData:{"#111111":"Obsidian","#2D2D2D":"Dark Gray","#434343":"Shale","#5B5B5B":"Flint","#737373":"Gray","#8B8B8B":"Concrete","#A2A2A2":"Gray","#B9B9B9":"Titanium","#000000":"Black","#D0D0D0":"Light Gray","#E6E6E6":"Silver","#FFFFFF":"White","#BFBF00":"Pumpkin","#FFFF00":"Yellow","#FFFF40":"Banana","#FFFF80":"Pale Yellow","#FFFFBF":"Butter","#525330":"Raw Siena","#898A49":"Mildew","#AEA945":"Olive","#7F7F00":"Paprika","#C3BE71":"Earth","#E0DCAA":"Khaki","#FCFAE1":"Cream","#60BF00":"Cactus","#80FF00":"Chartreuse","#A0FF40":"Green","#C0FF80":"Pale Lime","#DFFFBF":"Light Mint","#3B5738":"Green","#668F5A":"Lime Gray","#7F9757":"Yellow","#407F00":"Clover","#8A9B55":"Pistachio","#B7C296":"Light Jade","#E6EBD5":"Breakwater","#00BF00":"Spring Frost","#00FF80":"Pastel Green","#40FFA0":"Light Emerald","#80FFC0":"Sea Foam","#BFFFDF":"Sea Mist","#033D21":"Dark Forrest","#438059":"Moss","#7FA37C":"Medium Green","#007F40":"Pine","#8DAE94":"Yellow Gray Green","#ACC6B5":"Aqua Lung","#DDEBE2":"Sea Vapor","#00BFBF":"Fog","#00FFFF":"Cyan","#40FFFF":"Turquoise Blue","#80FFFF":"Light Aqua","#BFFFFF":"Pale Cyan","#033D3D":"Dark Teal","#347D7E":"Gray Turquoise","#609A9F":"Green Blue","#007F7F":"Seaweed","#96BDC4":"Green Gray","#B5D1D7":"Soapstone","#E2F1F4":"Light Turquoise","#0060BF":"Summer Sky","#0080FF":"Sky Blue","#40A0FF":"Electric Blue","#80C0FF":"Light Azure","#BFDFFF":"Ice Blue","#1B2C48":"Navy","#385376":"Biscay","#57708F":"Dusty Blue","#00407F":"Sea Blue","#7792AC":"Sky Blue Gray","#A8BED1":"Morning Sky","#DEEBF6":"Vapor","#0000BF":"Deep Blue","#0000FF":"Blue","#4040FF":"Cerulean Blue","#8080FF":"Evening Blue","#BFBFFF":"Light Blue","#212143":"Deep Indigo","#373E68":"Sea Blue","#444F75":"Night Blue","#00007F":"Indigo Blue","#585E82":"Dockside","#8687A4":"Blue Gray","#D2D1E1":"Light Blue Gray","#6000BF":"Neon Violet","#8000FF":"Blue Violet","#A040FF":"Violet Purple","#C080FF":"Violet Dusk","#DFBFFF":"Pale Lavender","#302449":"Cool Shale","#54466F":"Dark Indigo","#655A7F":"Dark Violet","#40007F":"Violet","#726284":"Smoky Violet","#9E8FA9":"Slate Gray","#DCD1DF":"Violet White","#BF00BF":"Royal Violet","#FF00FF":"Fuchsia","#FF40FF":"Magenta","#FF80FF":"Orchid","#FFBFFF":"Pale Magenta","#4A234A":"Dark Purple","#794A72":"Medium Purple","#936386":"Cool Granite","#7F007F":"Purple","#9D7292":"Purple Moon","#C0A0B6":"Pale Purple","#ECDAE5":"Pink Cloud","#BF005F":"Hot Pink","#FF007F":"Deep Pink","#FF409F":"Grape","#FF80BF":"Electric Pink","#FFBFDF":"Pink","#451528":"Purple Red","#823857":"Purple Dino","#A94A76":"Purple Gray","#7F003F":"Rose","#BC6F95":"Antique Mauve","#D8A5BB":"Cool Marble","#F7DDE9":"Pink Granite","#C00000":"Apple","#FF0000":"Fire Truck","#FF4040":"Pale Red","#FF8080":"Salmon","#FFC0C0":"Warm Pink","#441415":"Sepia","#82393C":"Rust","#AA4D4E":"Brick","#800000":"Brick Red","#BC6E6E":"Mauve","#D8A3A4":"Shrimp Pink","#F8DDDD":"Shell Pink","#BF5F00":"Dark Orange","#FF7F00":"Orange","#FF9F40":"Grapefruit","#FFBF80":"Canteloupe","#FFDFBF":"Wax","#482C1B":"Dark Brick","#855A40":"Dirt","#B27C51":"Tan","#7F3F00":"Nutmeg","#C49B71":"Mustard","#E1C4A8":"Pale Tan","#FDEEE0":"Marble"},_colorPicker:null,STR_COLLAPSE:"Collapse Toolbar",STR_SPIN_LABEL:"Spin Button with value {VALUE}. Use Control Shift Up Arrow and Control Shift Down arrow keys to increase or decrease the value.",STR_SPIN_UP:"Click to increase the value of this input",STR_SPIN_DOWN:"Click to decrease the value of this input",_titlebar:null,browser:YAHOO.env.ua,_buttonList:null,_buttonGroupList:null,_sep:null,_sepCount:null,_dragHandle:null,_toolbarConfigs:{renderer:true},CLASS_CONTAINER:"yui-toolbar-container",CLASS_DRAGHANDLE:"yui-toolbar-draghandle",CLASS_SEPARATOR:"yui-toolbar-separator",CLASS_DISABLED:"yui-toolbar-disabled",CLASS_PREFIX:"yui-toolbar",init:function(f,e){YAHOO.widget.Toolbar.superclass.init.call(this,f,e)},initAttributes:function(e){YAHOO.widget.Toolbar.superclass.initAttributes.call(this,e);this.addClass(this.CLASS_CONTAINER);this.setAttributeConfig("buttonType",{value:e.buttonType||"basic",writeOnce:true,validator:function(f){switch(f){case"advanced":case"basic":return true}return false},method:function(f){if(f=="advanced"){if(YAHOO.widget.Button){this.buttonType=YAHOO.widget.ToolbarButtonAdvanced}else{this.buttonType=YAHOO.widget.ToolbarButton}}else{this.buttonType=YAHOO.widget.ToolbarButton}}});this.setAttributeConfig("buttons",{value:[],writeOnce:true,method:function(g){for(var f in g){if(d.hasOwnProperty(g,f)){if(g[f].type=="separator"){this.addSeparator()}else{if(g[f].group!==undefined){this.addButtonGroup(g[f])}else{this.addButton(g[f])}}}}}});this.setAttributeConfig("disabled",{value:false,method:function(f){if(this.get("disabled")===f){return false}if(f){this.addClass(this.CLASS_DISABLED);this.set("draggable",false);this.disableAllButtons()}else{this.removeClass(this.CLASS_DISABLED);if(this._configs.draggable._initialConfig.value){this.set("draggable",true)}this.resetAllButtons()}}});this.setAttributeConfig("cont",{value:e.cont,readOnly:true});this.setAttributeConfig("grouplabels",{value:((e.grouplabels===false)?false:true),method:function(f){if(f){c.removeClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}else{c.addClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}}});this.setAttributeConfig("titlebar",{value:false,method:function(g){if(g){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}this._titlebar=document.createElement("DIV");this._titlebar.tabIndex="-1";a.on(this._titlebar,"focus",function(){this._handleFocus()},this,true);c.addClass(this._titlebar,this.CLASS_PREFIX+"-titlebar");if(d.isString(g)){var f=document.createElement("h2");f.tabIndex="-1";f.innerHTML='<a href="#" tabIndex="0">'+g+"</a>";this._titlebar.appendChild(f);a.on(f.firstChild,"click",function(h){a.stopEvent(h)});a.on([f,f.firstChild],"focus",function(){this._handleFocus()},this,true)}if(this.get("firstChild")){this.insertBefore(this._titlebar,this.get("firstChild"))}else{this.appendChild(this._titlebar)}if(this.get("collapse")){this.set("collapse",true)}}else{if(this._titlebar){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}}}}});this.setAttributeConfig("collapse",{value:false,method:function(h){if(this._titlebar){var g=null;var f=c.getElementsByClassName("collapse","span",this._titlebar);if(h){if(f.length>0){return true}g=document.createElement("SPAN");g.innerHTML="X";g.title=this.STR_COLLAPSE;c.addClass(g,"collapse");this._titlebar.appendChild(g);a.addListener(g,"click",function(){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}else{this.collapse()}},this,true)}else{g=c.getElementsByClassName("collapse","span",this._titlebar);if(g[0]){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}g[0].parentNode.removeChild(g[0])}}}}});this.setAttributeConfig("draggable",{value:(e.draggable||false),method:function(f){if(f&&!this.get("titlebar")){if(!this._dragHandle){this._dragHandle=document.createElement("SPAN");this._dragHandle.innerHTML="|";this._dragHandle.setAttribute("title","Click to drag the toolbar");this._dragHandle.id=this.get("id")+"_draghandle";c.addClass(this._dragHandle,this.CLASS_DRAGHANDLE);if(this.get("cont").hasChildNodes()){this.get("cont").insertBefore(this._dragHandle,this.get("cont").firstChild)}else{this.get("cont").appendChild(this._dragHandle)}this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._dragHandle.id)}}else{if(this._dragHandle){this._dragHandle.parentNode.removeChild(this._dragHandle);this._dragHandle=null;this.dd=null}}if(this._titlebar){if(f){this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._titlebar);c.addClass(this._titlebar,"draggable")}else{c.removeClass(this._titlebar,"draggable");if(this.dd){this.dd.unreg();this.dd=null}}}},validator:function(g){var f=true;if(!YAHOO.util.DD){f=false}return f}})},addButtonGroup:function(j){if(!this.get("element")){this._queue[this._queue.length]=["addButtonGroup",arguments];return false}if(!this.hasClass(this.CLASS_PREFIX+"-grouped")){this.addClass(this.CLASS_PREFIX+"-grouped")}var k=document.createElement("DIV");c.addClass(k,this.CLASS_PREFIX+"-group");c.addClass(k,this.CLASS_PREFIX+"-group-"+j.group);if(j.label){var f=document.createElement("h3");f.innerHTML=j.label;k.appendChild(f)}if(!this.get("grouplabels")){c.addClass(this.get("cont"),this.CLASS_PREFIX,"-nogrouplabels")}this.get("cont").appendChild(k);var h=document.createElement("ul");k.appendChild(h);if(!this._buttonGroupList){this._buttonGroupList={}}this._buttonGroupList[j.group]=h;for(var g=0;g<j.buttons.length;g++){var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";h.appendChild(e);if((j.buttons[g].type!==undefined)&&j.buttons[g].type=="separator"){this.addSeparator(e)}else{j.buttons[g].container=e;this.addButton(j.buttons[g])}}},addButtonToGroup:function(g,h,i){var f=this._buttonGroupList[h];var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";g.container=e;this.addButton(g,i);f.appendChild(e)},addButton:function(k,j){if(!this.get("element")){this._queue[this._queue.length]=["addButton",arguments];return false}if(!this._buttonList){this._buttonList=[]}if(!k.container){k.container=this.get("cont")}if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){for(var s in k.menu){if(d.hasOwnProperty(k.menu,s)){var y={fn:function(o,i,m){if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue)},scope:this};k.menu[s].onclick=y}}}}var t={},q=false;for(var n in k){if(d.hasOwnProperty(k,n)){if(!this._toolbarConfigs[n]){t[n]=k[n]}}}if(k.type=="select"){t.type="menu"}if(k.type=="spin"){t.type="push"}if(t.type=="color"){if(YAHOO.widget.Overlay){t=this._makeColorButton(t)}else{q=true}}if(t.menu){if((YAHOO.widget.Overlay)&&(k.menu instanceof YAHOO.widget.Overlay)){k.menu.showEvent.subscribe(function(){this._button=t})}else{for(var r=0;r<t.menu.length;r++){if(!t.menu[r].value){t.menu[r].value=t.menu[r].text}}if(this.browser.webkit){t.focusmenu=false}}}if(q){k=false}else{this._configs.buttons.value[this._configs.buttons.value.length]=k;var w=new this.buttonType(t);w.get("element").tabIndex="-1";w.get("element").setAttribute("role","button");w._selected=true;if(this.get("disabled")){w.set("disabled",true)}if(!k.id){k.id=w.get("id")}if(j){var f=w.get("element");var p=null;if(j.get){p=j.get("element").nextSibling}else{if(j.nextSibling){p=j.nextSibling}}if(p){p.parentNode.insertBefore(f,p)}}w.addClass(this.CLASS_PREFIX+"-"+w.get("value"));var v=document.createElement("span");v.className=this.CLASS_PREFIX+"-icon";w.get("element").insertBefore(v,w.get("firstChild"));if(w._button.tagName.toLowerCase()=="button"){w.get("element").setAttribute("unselectable","on");var x=document.createElement("a");x.innerHTML=w._button.innerHTML;x.href="#";x.tabIndex="-1";a.on(x,"click",function(i){a.stopEvent(i)});w._button.parentNode.replaceChild(x,w._button);w._button=x}if(k.type=="select"){if(w._button.tagName.toLowerCase()=="select"){v.parentNode.removeChild(v);var g=w._button;var u=w.get("element");u.parentNode.replaceChild(g,u)}else{w.addClass(this.CLASS_PREFIX+"-select")}}if(k.type=="spin"){if(!d.isArray(k.range)){k.range=[10,100]}this._makeSpinButton(w,k)}w.get("element").setAttribute("title",w.get("label"));if(k.type!="spin"){if((YAHOO.widget.Overlay)&&(t.menu instanceof YAHOO.widget.Overlay)){var h=function(o){var i=true;if(o.keyCode&&(o.keyCode==9)){i=false}if(i){if(this._colorPicker){this._colorPicker._button=k.value}var m=w.getMenu().element;if(c.getStyle(m,"visibility")=="hidden"){w.getMenu().show()}else{w.getMenu().hide()}}YAHOO.util.Event.stopEvent(o)};w.on("mousedown",h,k,this);w.on("keydown",h,k,this)}else{if((k.type!="menu")&&(k.type!="select")){w.on("keypress",this._buttonClick,k,this);w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i);this._buttonClick(i,k)},k,this);w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)});w.on("change",function(i){if(!k.menucmd){k.menucmd=k.value}k.value=i.value;this._buttonClick(i,k)},this,true);var l=this;w.on("appendTo",function(){var i=this;if(i.getMenu()&&i.getMenu().mouseDownEvent){i.getMenu().mouseDownEvent.subscribe(function(z,o){var m=o[1];YAHOO.util.Event.stopEvent(o[0]);i._onMenuClick(o[0],i);if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue);l._buttonClick.call(l,o[1],k);i._hideMenu();return false});i.getMenu().clickEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])});i.getMenu().mouseUpEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])})}})}}}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}if(this.browser.ie){}if(this.browser.webkit){w.hasFocus=function(){return true}}this._buttonList[this._buttonList.length]=w;if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){var e=w.getMenu();if(e&&e.renderEvent){e.renderEvent.subscribe(this._addMenuClasses,w);if(k.renderer){e.renderEvent.subscribe(k.renderer,w)}}}}}return k},addSeparator:function(e,h){if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}var f=((e)?e:this.get("cont"));if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}if(this._sepCount===null){this._sepCount=0}if(!this._sep){this._sep=document.createElement("SPAN");c.addClass(this._sep,this.CLASS_SEPARATOR);this._sep.innerHTML="|"}var g=this._sep.cloneNode(true);this._sepCount++;c.addClass(g,this.CLASS_SEPARATOR+"-"+this._sepCount);if(h){var i=null;if(h.get){i=h.get("element").nextSibling}else{if(h.nextSibling){i=h.nextSibling}else{i=h}}if(i){if(i==h){i.parentNode.appendChild(g)}else{i.parentNode.insertBefore(g,i)}}}else{f.appendChild(g)}return g},_createColorPicker:function(h){if(c.get(h+"_colors")){c.get(h+"_colors").parentNode.removeChild(c.get(h+"_colors"))}var e=document.createElement("div");e.className="yui-toolbar-colors";e.id=h+"_colors";e.style.display="none";a.on(window,"load",function(){document.body.appendChild(e)},this,true);this._colorPicker=e;var g="";for(var f in this._colorData){if(d.hasOwnProperty(this._colorData,f)){g+='<a style="background-color: '+f+'" href="#">'+f.replace("#","")+"</a>"}}g+="<span><em>X</em><strong></strong></span>";window.setTimeout(function(){e.innerHTML=g},0);a.on(e,"mouseover",function(m){var k=this._colorPicker;var l=k.getElementsByTagName("em")[0];var j=k.getElementsByTagName("strong")[0];var i=a.getTarget(m);if(i.tagName.toLowerCase()=="a"){l.style.backgroundColor=i.style.backgroundColor;j.innerHTML=this._colorData["#"+i.innerHTML]+"<br>"+i.innerHTML}},this,true);a.on(e,"focus",function(i){a.stopEvent(i)});a.on(e,"click",function(i){a.stopEvent(i)});a.on(e,"mousedown",function(j){a.stopEvent(j);var i=a.getTarget(j);if(i.tagName.toLowerCase()=="a"){var l=this.fireEvent("colorPickerClicked",{type:"colorPickerClicked",target:this,button:this._colorPicker._button,color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML]});if(l!==false){var k={color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML],value:this._colorPicker._button};this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:k})}this.getButtonByValue(this._colorPicker._button).getMenu().hide()}},this,true)},_resetColorPicker:function(){var f=this._colorPicker.getElementsByTagName("em")[0];var e=this._colorPicker.getElementsByTagName("strong")[0];f.style.backgroundColor="transparent";e.innerHTML=""},_makeColorButton:function(e){if(!this._colorPicker){this._createColorPicker(this.get("id"))}e.type="color";e.menu=new YAHOO.widget.Overlay(this.get("id")+"_"+e.value+"_menu",{visible:false,position:"absolute",iframe:true});e.menu.setBody("");e.menu.render(this.get("cont"));c.addClass(e.menu.element,"yui-button-menu");c.addClass(e.menu.element,"yui-color-button-menu");e.menu.beforeShowEvent.subscribe(function(){e.menu.cfg.setProperty("zindex",5);e.menu.cfg.setProperty("context",[this.getButtonById(e.id).get("element"),"tl","bl"]);this._resetColorPicker();var f=this._colorPicker;if(f.parentNode){f.parentNode.removeChild(f)}e.menu.setBody("");e.menu.appendToBody(f);this._colorPicker.style.display="block"},this,true);return e},_makeSpinButton:function(r,l){r.addClass(this.CLASS_PREFIX+"-spinbutton");var s=this,n=r._button.parentNode.parentNode,i=l.range,h=document.createElement("a"),g=document.createElement("a");h.href="#";g.href="#";h.tabIndex="-1";g.tabIndex="-1";h.className="up";h.title=this.STR_SPIN_UP;h.innerHTML=this.STR_SPIN_UP;g.className="down";g.title=this.STR_SPIN_DOWN;g.innerHTML=this.STR_SPIN_DOWN;n.appendChild(h);n.appendChild(g);var m=YAHOO.lang.substitute(this.STR_SPIN_LABEL,{VALUE:r.get("label")});r.set("title",m);var q=function(t){t=((t<i[0])?i[0]:t);t=((t>i[1])?i[1]:t);return t};var p=this.browser;var f=false;var k=this.STR_SPIN_LABEL;if(this._titlebar&&this._titlebar.firstChild){f=this._titlebar.firstChild}var e=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v++;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var o=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v--;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var j=function(t){if(t.keyCode==38){e(t)}else{if(t.keyCode==40){o(t)}else{if(t.keyCode==107&&t.shiftKey){e(t)}else{if(t.keyCode==109&&t.shiftKey){o(t)}}}}};r.on("keydown",j,this,true);a.on(h,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(g,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(h,"click",e,this,true);a.on(g,"click",o,this,true)},_buttonClick:function(n,f){var e=true;if(n&&n.type=="keypress"){if(n.keyCode==9){e=false}else{if((n.keyCode===13)||(n.keyCode===0)||(n.keyCode===32)){}else{e=false}}}if(e){var p=true,h=false;f.isSelected=this.isSelected(f.id);if(f.value){h=this.fireEvent(f.value+"Click",{type:f.value+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(f.menucmd&&p){h=this.fireEvent(f.menucmd+"Click",{type:f.menucmd+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(p){this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:f})}if(f.type=="select"){var l=this.getButtonById(f.id);if(l.buttonType=="rich"){var k=f.value;for(var j=0;j<f.menu.length;j++){if(f.menu[j].value==f.value){k=f.menu[j].text;break}}l.set("label",'<span class="yui-toolbar-'+f.menucmd+"-"+(f.value).replace(/ /g,"-").toLowerCase()+'">'+k+"</span>");var o=l.getMenu().getItems();for(var g=0;g<o.length;g++){if(o[g].value.toLowerCase()==f.value.toLowerCase()){o[g].cfg.setProperty("checked",true)}else{o[g].cfg.setProperty("checked",false)}}}}if(n){a.stopEvent(n)}}},_keyNav:null,_navCounter:null,_navigateButtons:function(f){switch(f.keyCode){case 37:case 39:if(f.keyCode==37){this._navCounter--}else{this._navCounter++}if(this._navCounter>(this._buttonList.length-1)){this._navCounter=0}if(this._navCounter<0){this._navCounter=(this._buttonList.length-1)}if(this._buttonList[this._navCounter]){var e=this._buttonList[this._navCounter].get("element");if(this.browser.ie){e=this._buttonList[this._navCounter].get("element").getElementsByTagName("a")[0]}if(this._buttonList[this._navCounter].get("disabled")){this._navigateButtons(f)}else{e.focus()}}break}},_handleFocus:function(){if(!this._keyNav){var e="keypress";if(this.browser.ie){e="keydown"}a.on(this.get("element"),e,this._navigateButtons,this,true);this._keyNav=true;this._navCounter=-1}},getButtonById:function(g){var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==g){return this._buttonList[f]}}return false},getButtonByValue:function(n){var h=this.get("buttons");var f=h.length;for(var k=0;k<f;k++){if(h[k].group!==undefined){for(var e=0;e<h[k].buttons.length;e++){if((h[k].buttons[e].value==n)||(h[k].buttons[e].menucmd==n)){return this.getButtonById(h[k].buttons[e].id)}if(h[k].buttons[e].menu){for(var l=0;l<h[k].buttons[e].menu.length;l++){if(h[k].buttons[e].menu[l].value==n){return this.getButtonById(h[k].buttons[e].id)}}}}}else{if((h[k].value==n)||(h[k].menucmd==n)){return this.getButtonById(h[k].id)}if(h[k].menu){for(var g=0;g<h[k].menu.length;g++){if(h[k].menu[g].value==n){return this.getButtonById(h[k].id)}}}}}return false},getButtonByIndex:function(e){if(this._buttonList[e]){return this._buttonList[e]}else{return false}},getButtons:function(){return this._buttonList},disableButton:function(f){var e=b.call(this,f);if(e){e.set("disabled",true)}else{return false}},enableButton:function(f){if(this.get("disabled")){return false}var e=b.call(this,f);if(e){if(e.get("disabled")){e.set("disabled",false)}}else{return false}},isSelected:function(f){var e=b.call(this,f);if(e){return e._selected}return false},selectButton:function(i,g){var f=b.call(this,i);if(f){f.addClass("yui-button-selected");f.addClass("yui-button-"+f.get("value")+"-selected");f._selected=true;if(g){if(f.buttonType=="rich"){var h=f.getMenu().getItems();for(var e=0;e<h.length;e++){if(h[e].value==g){h[e].cfg.setProperty("checked",true);f.set("label",'<span class="yui-toolbar-'+f.get("value")+"-"+(g).replace(/ /g,"-").toLowerCase()+'">'+h[e]._oText.nodeValue+"</span>")}else{h[e].cfg.setProperty("checked",false)}}}}}else{return false}},deselectButton:function(f){var e=b.call(this,f);if(e){e.removeClass("yui-button-selected");e.removeClass("yui-button-"+e.get("value")+"-selected");e.removeClass("yui-button-hover");e._selected=false}else{return false}},deselectAllButtons:function(){var e=this._buttonList.length;for(var f=0;f<e;f++){this.deselectButton(this._buttonList[f])}},disableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.disableButton(this._buttonList[f])}},enableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.enableButton(this._buttonList[f])}},resetAllButtons:function(j){if(!d.isObject(j)){j={}}if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){var h=this._buttonList[f];if(h){var g=h._configs.disabled._initialConfig.value;if(j[h.get("id")]){this.enableButton(h);this.selectButton(h)}else{if(g){this.disableButton(h)}else{this.enableButton(h)}this.deselectButton(h)}}}},destroyButton:function(j){var g=b.call(this,j);if(g){var h=g.get("id");g.destroy();var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==h){this._buttonList[f]=null}}}else{return false}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var e in this){if(d.hasOwnProperty(this,e)){this[e]=null}}return true},collapse:function(f){var e=c.getElementsByClassName("collapse","span",this._titlebar);if(f===false){c.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(e[0]){c.removeClass(e[0],"collapsed")}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this})}else{if(e[0]){c.addClass(e[0],"collapsed")}c.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this})}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons."}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang,b=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(h,m){var g={};if(d.isObject(h)&&(!h.tagName)&&!m){d.augmentObject(g,h);h=document.createElement("textarea");this.DOMReady=true;if(g.container){var k=c.get(g.container);k.appendChild(h)}else{document.body.appendChild(h)}}else{if(m){d.augmentObject(g,m)}}var i={element:null,attributes:g},f=null;if(d.isString(h)){f=h}else{if(i.attributes.id){f=i.attributes.id}else{this.DOMReady=true;f=c.generateId(h)}}i.element=h;var j=document.createElement("DIV");i.attributes.element_cont=new YAHOO.util.Element(j,{id:f+"_container"});var e=document.createElement("div");c.addClass(e,"first-child");i.attributes.element_cont.appendChild(e);if(!i.attributes.toolbar_cont){i.attributes.toolbar_cont=document.createElement("DIV");i.attributes.toolbar_cont.id=f+"_toolbar";e.appendChild(i.attributes.toolbar_cont)}var l=document.createElement("DIV");e.appendChild(l);i.attributes.editor_wrapper=l;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,i.element,i.attributes)};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false}if(this.get("resize")){var e={};d.augmentObject(e,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),e);this.resize.on("resize",function(g){var l=this.get("animate");this.set("animate",false);this.set("width",g.width+"px");var i=g.height,j=(this.toolbar.get("element").clientHeight+2),k=0;if(this.dompath){k=(this.dompath.clientHeight+1)}var f=(i-j-k);this.set("height",f+"px");this.get("element_cont").setStyle("height","");this.set("animate",l)},this,true)}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false}if(this.get("drag")){var f=this.get("drag"),e=YAHOO.util.DD;if(f==="proxy"){e=YAHOO.util.DDProxy}this.dd=new e(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar)}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(f,j){var g=false;if((j.keyCode===f.key)){if(f.mods&&(f.mods.length>0)){var l=0;for(var h=0;h<f.mods.length;h++){if(this.browser.mac){if(f.mods[h]=="ctrl"){f.mods[h]="meta"}}if(j[f.mods[h]+"Key"]===true){l++}}if(l===f.mods.length){g=true}}else{g=true}}return g},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(e){return e.replace(/ /g,"-").toLowerCase()},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-
|
if(E){J=E;}if(this.browser.ie){H="formatblock";}if(I=="none"){if((J&&J.tagName&&(J.tagName.toLowerCase().substring(0,1)=="h"))||(J&&J.parentNode&&J.parentNode.tagName&&(J.parentNode.tagName.toLowerCase().substring(0,1)=="h"))){if(J.parentNode.tagName.toLowerCase().substring(0,1)=="h"){J=J.parentNode;}if(this._isElement(J,"html")){return[false];}G=this._swapEl(E,"span",function(K){K.className="yui-non";});this._selectNode(G);this.currentElement[0]=G;}F=false;}else{if(this._isElement(E,"h1")||this._isElement(E,"h2")||this._isElement(E,"h3")||this._isElement(E,"h4")||this._isElement(E,"h5")||this._isElement(E,"h6")){G=this._swapEl(E,I);this._selectNode(G);this.currentElement[0]=G;}else{this._createCurrentElement(I);this._selectNode(this.currentElement[0]);}F=false;}return[F,H];},cmd_hiddenelements:function(E){if(this._showingHiddenElements){this._lastButton=null;this._showingHiddenElements=false;this.toolbar.deselectButton("hiddenelements");C.removeClass(this._getDoc().body,this.CLASS_HIDDEN);}else{this._showingHiddenElements=true;C.addClass(this._getDoc().body,this.CLASS_HIDDEN);this.toolbar.selectButton("hiddenelements");}return[false];},cmd_removeformat:function(H){var F=true;if(this.browser.webkit&&!this._getDoc().queryCommandEnabled("removeformat")){var E=this._getSelection()+"";this._createCurrentElement("span");this.currentElement[0].className="yui-non";this.currentElement[0].innerHTML=E;for(var G=1;G<this.currentElement.length;G++){this.currentElement[G].parentNode.removeChild(this.currentElement[G]);}F=false;}return[F];},cmd_script:function(K,J){var G=true,E=K.toLowerCase().substring(0,3),H=null,F=this._getSelectedElement();if(this.browser.webkit){if(this._isElement(F,E)){H=this._swapEl(this.currentElement[0],"span",function(L){L.className="yui-non";});this._selectNode(H);}else{this._createCurrentElement(E);var I=this._swapEl(this.currentElement[0],E);this._selectNode(I);this.currentElement[0]=I;}G=false;}return G;},cmd_superscript:function(E){return[this.cmd_script("superscript",E)];},cmd_subscript:function(E){return[this.cmd_script("subscript",E)];},cmd_indent:function(H){var E=true,G=this._getSelectedElement(),I=null;if(this.browser.ie){if(this._isElement(G,"blockquote")){I=this._getDoc().createElement("blockquote");I.innerHTML=G.innerHTML;G.innerHTML="";G.appendChild(I);this._selectNode(I);}else{I=this._getDoc().createElement("blockquote");var F=this._getRange().htmlText;I.innerHTML=F;this._createCurrentElement("blockquote");this.currentElement[0].parentNode.replaceChild(I,this.currentElement[0]);this.currentElement[0]=I;this._selectNode(this.currentElement[0]);}E=false;}else{H="blockquote";}return[E,"formatblock",H];},cmd_outdent:function(I){var E=true,H=this._getSelectedElement(),J=null,F=null;if(this.browser.webkit||this.browser.ie){H=this._getSelectedElement();if(this._isElement(H,"blockquote")){var G=H.parentNode;if(this._isElement(H.parentNode,"blockquote")){G.innerHTML=H.innerHTML;this._selectNode(G);}else{F=this._getDoc().createElement("span");F.innerHTML=H.innerHTML;YAHOO.util.Dom.addClass(F,"yui-non");G.replaceChild(F,H);this._selectNode(F);}}else{}E=false;}else{I=false;}return[E,"outdent",I];},cmd_justify:function(E){if(this.browser.ie){if(this._hasSelection()){this._createCurrentElement("span");this._swapEl(this.currentElement[0],"div",function(F){F.style.textAlign=E;});return[false];}}return[true,"justify"+E,""];},cmd_justifycenter:function(){return[this.cmd_justify("center")];},cmd_justifyleft:function(){return[this.cmd_justify("left")];},cmd_justifyright:function(){return[this.cmd_justify("right")];},toString:function(){var E="Editor";if(this.get&&this.get("element_cont")){E="Editor (#"+this.get("element_cont").get("id")+")"+((this.get("disabled")?" Disabled":""));}return E;}});YAHOO.widget.EditorWindow=function(F,E){this.name=F.replace(" ","_");this.attrs=E;};YAHOO.widget.EditorWindow.prototype={header:null,body:null,footer:null,setHeader:function(E){this.header=E;},setBody:function(E){this.body=E;},setFooter:function(E){this.footer=E;},toString:function(){return"Editor Window ("+this.name+")";}};})();YAHOO.register("editor",YAHOO.widget.Editor,{version:"2.6.0",build:"1321"});
|
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
|
jb=/^-?\d/,kb={position:"absolute",visibility:"hidden",display:"block"},Pa=["Left","Right"],Qa=["Top","Bottom"],W,Ga,aa,lb=function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){if(arguments.length===2&&b===B)return this;return c.access(this,a,b,true,function(d,e,f){return f!==B?c.style(d,e,f):c.css(d,e)})};c.extend({cssHooks:{opacity:{get:function(a,b){if(b){var d=W(a,"opacity","opacity");return d===""?"1":d}else return a.style.opacity}}},cssNumber:{zIndex:true,fontWeight:true,opacity:true,
|
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
|
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
|
h=c.cssHooks[f];b=c.cssProps[f]||f;if(h&&"get"in h&&(e=h.get(a,true,d))!==B)return e;else if(W)return W(a,b,f)},swap:function(a,b,d){var e={},f;for(f in b){e[f]=a.style[f];a.style[f]=b[f]}d.call(a);for(f in b)a.style[f]=e[f]},camelCase:function(a){return a.replace(hb,lb)}});c.curCSS=c.css;c.each(["height","width"],function(a,b){c.cssHooks[b]={get:function(d,e,f){var h;if(e){if(d.offsetWidth!==0)h=oa(d,b,f);else c.swap(d,kb,function(){h=oa(d,b,f)});if(h<=0){h=W(d,b,b);if(h==="0px"&&aa)h=aa(d,b,b); if(h!=null)return h===""||h==="auto"?"0px":h}if(h<0||h==null){h=d.style[b];return h===""||h==="auto"?"0px":h}return typeof h==="string"?h:h+"px"}},set:function(d,e){if(Fa.test(e)){e=parseFloat(e);if(e>=0)return e+"px"}else return e}}});if(!c.support.opacity)c.cssHooks.opacity={get:function(a,b){return gb.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var d=a.style;d.zoom=1;var e=c.isNaN(b)?"":"alpha(opacity="+b*100+")",f=
|
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
|
function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,
|
h=c.cssHooks[f];b=c.cssProps[f]||f;if(h&&"get"in h&&(e=h.get(a,true,d))!==B)return e;else if(W)return W(a,b,f)},swap:function(a,b,d){var e={},f;for(f in b){e[f]=a.style[f];a.style[f]=b[f]}d.call(a);for(f in b)a.style[f]=e[f]},camelCase:function(a){return a.replace(hb,lb)}});c.curCSS=c.css;c.each(["height","width"],function(a,b){c.cssHooks[b]={get:function(d,e,f){var h;if(e){if(d.offsetWidth!==0)h=oa(d,b,f);else c.swap(d,kb,function(){h=oa(d,b,f)});if(h<=0){h=W(d,b,b);if(h==="0px"&&aa)h=aa(d,b,b);
|
function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,
|
165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0],transparent:[255,255,255]},p=["add","remove","toggle"],s={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};f.effects.animateClass=function(c,a,b,d){if(f.isFunction(b)){d=b;b=null}return this.each(function(){var e=f(this),g=e.attr("style")||" ",h=o(n.call(this)),q,u=e.attr("className");f.each(p,function(v, i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?
|
g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0],transparent:[255,255,255]},p=["add","remove","toggle"],s={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};f.effects.animateClass=function(c,a,b,d){if(f.isFunction(b)){d=b;b=null}return this.each(function(){var e=f(this),g=e.attr("style")||" ",h=o(n.call(this)),q,u=e.attr("className");f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?
|
function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,
|
"object"){b=c.param(b,c.ajaxSettings.traditional);e="POST"}var h=this;c.ajax({url:a,type:e,dataType:"html",data:b,complete:function(l,k){if(k==="success"||k==="notmodified")h.html(f?c("<div>").append(l.responseText.replace(nb,"")).find(f):l.responseText);d&&h.each(d,[l.responseText,k,l])}});return this},serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&
|
function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,
|
i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?
|
g,this._uiHash(this))}}.call(this,this.containers[e]));c.push(function(f){return function(g){f._trigger("update",g,this._uiHash(this))}}.call(this,this.containers[e]))}}for(e=this.containers.length-1;e>=0;e--){b||c.push(function(f){return function(g){f._trigger("deactivate",g,this._uiHash(this))}}.call(this,this.containers[e]));if(this.containers[e].containerCache.over){c.push(function(f){return function(g){f._trigger("out",g,this._uiHash(this))}}.call(this,this.containers[e]));this.containers[e].containerCache.over=
|
i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?
|
this.handleRequest('FIN_REQUEST_SUBSCRIBE_ITEMSET', bind(this, function(request) { var onMutated = bind(this, '_onItemSetMutated') this._itemSetSubs = this.server.subscribeToItemSetMutations(request.id, onMutated,
|
this.handleRequest('FIN_REQUEST_SUBSCRIBE_ITEMSET', bind(this, function(args) { var itemSetId = args.id onMutated = bind(this, '_onItemSetMutated') this._itemSetSubs[itemSetId] = this.server.subscribeToItemSetMutations(itemSetId, onMutated,
|
this.handleRequest('FIN_REQUEST_SUBSCRIBE_ITEMSET', bind(this, function(request) { var onMutated = bind(this, '_onItemSetMutated') this._itemSetSubs = this.server.subscribeToItemSetMutations(request.id, onMutated, bind(this, 'sendFrame', 'FIN_EVENT_ITEMSET_SNAPSHOT')) }))
|
var addTrigger = YAHOO.util.Dom.get("add-flavor" + XFORMS_SEPARATOR_1 + "1"); YAHOO.util.UserAction.click(addTrigger);
|
YAHOO.util.Assert.isTrue(inputField.disabled, "input field initially disabled because bound to a readonly node"); ORBEON.xforms.Document.setValue("relevant", "false");
|
ORBEON.util.Test.executeCausingAjaxRequest(this, function() { // Click on text field var addTrigger = YAHOO.util.Dom.get("add-flavor" + XFORMS_SEPARATOR_1 + "1"); YAHOO.util.UserAction.click(addTrigger); }, function() {
|
this._redisCommandClient[redisOp](this._queryKey, itemId, bind(this, function(err, opChangedSet) { if (err) { throw logger.error('Could not modify query set', redisOp, queryKey, err) } var mutation = { op: redisOp, id: this._queryChannel, args: [itemId] } this._redisCommandClient.publish(this._queryChannel, JSON.stringify(mutation))
|
this._redisCommandClient.sismember(this._queryKey, itemId, bind(this, function(err, isMember) { if (Boolean(isMember)) { return } this._mutate('sadd', itemId)
|
this._redisCommandClient[redisOp](this._queryKey, itemId, bind(this, function(err, opChangedSet) { if (err) { throw logger.error('Could not modify query set', redisOp, queryKey, err) } var mutation = { op: redisOp, id: this._queryChannel, args: [itemId] } this._redisCommandClient.publish(this._queryChannel, JSON.stringify(mutation)) }))
|
input.bind('keydown', 'return', function() {ok.click();});
|
callback:C.cbHandler(function(result){ var store = grid.getStore(); var f = Ext.getCmp("user_multiple_hidden" + options.name + pageId); var R = Ext.data.Record.create(grid.record_spec); store.add(result.rows.map(function(row){ return new R(row); })); f.setValue(value) })
|
input.bind('keydown', 'return', function() {ok.click();});
|
thiss.openAccordionCase(thiss, 'optional-scrollh', function() { var tbody = YAHOO.util.Dom.get('my-accordion$optional-scrollh-table$optional-scrollh-table-tbody'); var bodyContainer = tbody.parentNode.parentNode; thiss.checkHorizontalScrollbar(bodyContainer, false); thiss.closeAccordionCase(thiss, 'optional-scrollh'); });
|
thiss.openAccordionCase(thiss, 'optional-scrollh-v', function() { var tbody = YAHOO.util.Dom.get('my-accordion$optional-scrollh-v-table$optional-scrollh-v-table-tbody'); var bodyContainer = tbody.parentNode.parentNode; thiss.checkHorizontalScrollbar(bodyContainer, false); thiss.closeAccordionCase(thiss, 'optional-scrollh-v'); });
|
thiss.openAccordionCase(thiss, 'optional-scrollh', function() { var tbody = YAHOO.util.Dom.get('my-accordion$optional-scrollh-table$optional-scrollh-table-tbody'); var bodyContainer = tbody.parentNode.parentNode; thiss.checkHorizontalScrollbar(bodyContainer, false); thiss.closeAccordionCase(thiss, 'optional-scrollh'); });
|
x1Input.change( function() {
|
y1Input.change( function() {
|
x1Input.change( function() { if (isNaN(parseFloat(this.value)) || this.value < 0.0 || this.value > 1.0) { this.value = 0.0; } $this.paint.linearGradient.setAttribute('x1', this.value); beginStop.setAttribute('x', MARGINX + SIZEX*this.value - STOP_RADIUS); });
|
$this.paint.linearGradient.setAttribute('x1', this.value); beginStop.setAttribute('x', MARGINX + SIZEX*this.value - STOP_RADIUS);
|
$this.paint.linearGradient.setAttribute('y1', this.value); beginStop.setAttribute('y', MARGINY + SIZEY*this.value - STOP_RADIUS);
|
x1Input.change( function() { if (isNaN(parseFloat(this.value)) || this.value < 0.0 || this.value > 1.0) { this.value = 0.0; } $this.paint.linearGradient.setAttribute('x1', this.value); beginStop.setAttribute('x', MARGINX + SIZEX*this.value - STOP_RADIUS); });
|
var choices = items.map( context.get, context ); var val = choices[cnt]; cnt = (cnt + 1) % choices.length; return val;
|
var current = node_list.evaluate(context); if (current !== last) { last = current; return current; } else { return ''; }
|
return function (context) { var choices = items.map( context.get, context ); var val = choices[cnt]; cnt = (cnt + 1) % choices.length; return val; };
|
this._redisClient.incr(shared.keys.uniqueIdKey, bind(this, function(err, newItemId) { if (err) { throw logger.error('Could not increment unique item id counter', err) } var doCallback = blockCallback(bind(this, callback, newItemId)) for (var propName in itemProperties) { var value = JSON.stringify(itemProperties[propName]), mutation = { id: newItemId, op: 'set', prop: propName, args: [value] } this.mutateItem(mutation, origConnection, doCallback.addBlock()) } doCallback.tryNow()
|
this._redisClient.smembers(queryKey, bind(this, function(err, members) { if (err) { throw logger.error('could not retrieve set members', queryKey, err) } callback(members || [])
|
this._redisClient.incr(shared.keys.uniqueIdKey, bind(this, function(err, newItemId) { if (err) { throw logger.error('Could not increment unique item id counter', err) } var doCallback = blockCallback(bind(this, callback, newItemId)) for (var propName in itemProperties) { var value = JSON.stringify(itemProperties[propName]), mutation = { id: newItemId, op: 'set', prop: propName, args: [value] } this.mutateItem(mutation, origConnection, doCallback.addBlock()) } doCallback.tryNow() }))
|
ORBEON.util.Test.executeCausingAjaxRequest(this, function() { ORBEON.util.Dom.getElementByTagName(document.getElementById("second-input"), "input").focus(); }, function() {
|
}, function() { YA.areEqual(ORBEON.xforms.Globals.currentFocusControlElement, document.getElementById("focus-restore"), "focus is restored to first input box"); });
|
ORBEON.util.Test.executeCausingAjaxRequest(this, function() { ORBEON.util.Dom.getElementByTagName(document.getElementById("second-input"), "input").focus(); }, function() {
|
$.each(this._children, function(index, child) { var box = child.getBounds(); child.setPosition(box.left + offset.x, box.top + offset.y, immediately); });
|
setTimeout( function(){ var group = $(target).data("group"); if( group == null ){ var group = new Group(); group.create( [target, dragged] ); } else { group.add( dragged ) } }, 100);
|
$.each(this._children, function(index, child) { var box = child.getBounds(); child.setPosition(box.left + offset.x, box.top + offset.y, immediately); });
|
function (s) { return s["clickable"] != false; });
|
function (s) { return false; });
|
function (s) { return s["clickable"] != false; });
|
this.handleRequest('FIN_REQUEST_CREATE_ITEM', bind(this, function(request) { this.server.createItem(request.data, this, bind(this, function(itemData) { var response = { _requestId: request._requestId, data: itemData } this.sendFrame('FIN_RESPONSE', response) }))
|
this.handleRequest('FIN_REQUEST_MUTATE', bind(this, function(mutation){ this.server.mutateItem(mutation, this)
|
this.handleRequest('FIN_REQUEST_CREATE_ITEM', bind(this, function(request) { this.server.createItem(request.data, this, bind(this, function(itemData) { var response = { _requestId: request._requestId, data: itemData } this.sendFrame('FIN_RESPONSE', response) })) }))
|
} else if (else_node_list.length) {
|
} else if (else_node_list) {
|
return function (context, callback) { function not(x) { return !x; } function and(p,c) { return p && c; } function or(p,c) { return p || c; } var items = item_names.map( context.get, context ).concat( not_item_names.map( context.get, context ).map( not ) ); var isTrue = items.reduce( operator === 'or' ? or : and, true ); if (isTrue) { if_node_list.evaluate(context, function (error, result) { callback(error, result); }); } else if (else_node_list.length) { else_node_list.evaluate(context, function (error, result) { callback(error, result); }); } else { callback(false, ''); } };
|
this.handleRequest('FIN_REQUEST_SUBSCRIBE_ITEMSET', bind(this, function(args) { var itemSetId = args.id, onMutated = bind(this, '_onItemSetMutated') this._itemSetSubs[itemSetId] = this.server.subscribeToItemSet(itemSetId, onMutated) }))
|
this.server.createItem(request.data, bind(this, function(itemData) { var response = { _requestId: request._requestId, data: itemData } this.sendFrame('FIN_RESPONSE', response) }))
|
this.handleRequest('FIN_REQUEST_SUBSCRIBE_ITEMSET', bind(this, function(args) { var itemSetId = args.id, onMutated = bind(this, '_onItemSetMutated') this._itemSetSubs[itemSetId] = this.server.subscribeToItemSet(itemSetId, onMutated) }))
|
var formLoadingIntervalID = window.setInterval(function() { if (formLoadingComplete) { window.clearInterval(formLoadingIntervalID); ORBEON.xforms.Offline.loadFormInIframe(url, function(offlineIframe) { var takingFormOfflineIntervalID = window.setInterval(function() { if (! offlineIframe.contentWindow.ORBEON.xforms.Offline.isOnline) { window.clearInterval(takingFormOfflineIntervalID); if (formOfflineListener) formOfflineListener(offlineIframe.contentWindow); } }, 100); offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("#document", "xxforms-offline"); }); } }, 100);
|
(function(){ if (window.firebug) firebug.init(); else setTimeout(arguments.callee); })();
|
var formLoadingIntervalID = window.setInterval(function() { if (formLoadingComplete) { window.clearInterval(formLoadingIntervalID); // Load the form in the iframe ORBEON.xforms.Offline.loadFormInIframe(url, function(offlineIframe) { // Wait for the form to be marked as offline before we call the listener var takingFormOfflineIntervalID = window.setInterval(function() { if (! offlineIframe.contentWindow.ORBEON.xforms.Offline.isOnline) { window.clearInterval(takingFormOfflineIntervalID); // Calling listener to notify that the form is now completely offline if (formOfflineListener) formOfflineListener(offlineIframe.contentWindow); } }, 100); // Send offline event to the server offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("#document", "xxforms-offline"); }); } }, 100);
|
this.release(subID)
|
setTimeout(bind(this, function() { this.release(subID) }), 0)
|
var subID = this._observeChain(id, propertyChain, 0, bind(this, function() { callback(this._resolveCachedPropertyChain(id, prop)) this.release(subID) }), {})
|
this.checkSearchValue(staticDynamic, "Canada");
|
this.runForStaticDynamic(function(staticDynamic, continuation) { this.checkExternalValue(staticDynamic, "ca"); continuation.call(this); });
|
|
YA.areEqual(ORBEON.xforms.Globals.currentFocusControlElement,
|
YUA.areEqual(ORBEON.xforms.Globals.currentFocusControlElement,
|
}, function() { YA.areEqual(ORBEON.xforms.Globals.currentFocusControlElement, document.getElementById("focus-restore"), "focus is restored to first input box"); });
|
offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("$containing-document$", "xxforms-offline");
|
offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("#document", "xxforms-offline");
|
ORBEON.xforms.Offline.loadFormInIframe(url, function(offlineIframe) { // Wait for the form to be marked as offline before we call the listener var takingFormOfflineIntervalID = window.setInterval(function() { if (! offlineIframe.contentWindow.ORBEON.xforms.Offline.isOnline) { window.clearInterval(takingFormOfflineIntervalID); // Calling listener to notify that the form is now completely offline if (formOfflineListener) formOfflineListener(offlineIframe.contentWindow); } }, 100); // Send offline event to the server offlineIframe.contentWindow.ORBEON.xforms.Document.dispatchEvent("$containing-document$", "xxforms-offline"); });
|
$('input[type=text].datetime').each(function(index, element) { $(this).after('<input type="image" class="button datetime" id="' + element.id + '_datetime_button' + '" src="' + config['icon_path'] + 'calendar-img.gif" />'); Calendar.setup({ inputField: element.id, timeFormat: 24, showsTime: true, ifFormat: config['calendar_js_date_format'], button: element.id + '_datetime_button' });
|
$('input[type=button].stopwatch_reset').click(function() { stopwatch.reset(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']);
|
$('input[type=text].datetime').each(function(index, element) { $(this).after('<input type="image" class="button datetime" id="' + element.id + '_datetime_button' + '" src="' + config['icon_path'] + 'calendar-img.gif" />'); Calendar.setup({ inputField: element.id, timeFormat: 24, showsTime: true, ifFormat: config['calendar_js_date_format'], button: element.id + '_datetime_button' }); });
|
this.timerID = window.setTimeout(function() { self.tick(); }, 1000);
|
$('input[type=button].stopwatch_reset').click(function() { stopwatch.reset(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); });
|
this.timerID = window.setTimeout(function() { self.tick(); }, 1000);
|
});$("span",oSettings.nPaginate).bind("mousedown",function(){return false});$("span",oSettings.nPaginate).bind("selectstart",function(){return false });oSettings.nPaginateList=nList},fnUpdate:function(oSettings,fnCallbackDraw){var iPageCount=jQuery.fn.dataTableExt.oPagination.iFullNumbersShowPages;
|
}});$(nLast).click(function(){if(oSettings.oApi._fnPageChange(oSettings,"last")){fnCallbackDraw(oSettings) }});$("span",nPaging).bind("mousedown",function(){return false}).bind("selectstart",function(){return false
|
});$("span",oSettings.nPaginate).bind("mousedown",function(){return false});$("span",oSettings.nPaginate).bind("selectstart",function(){return false});oSettings.nPaginateList=nList},fnUpdate:function(oSettings,fnCallbackDraw){var iPageCount=jQuery.fn.dataTableExt.oPagination.iFullNumbersShowPages;
|
$('input[type=button].stopwatch_reset').click(function() { stopwatch.reset(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); });
|
this.timerID = window.setTimeout(function() { self.tick(); }, 1000);
|
$('input[type=button].stopwatch_reset').click(function() { stopwatch.reset(); $('input[type=button].stopwatch_toggle').attr('value', translations['time_tracking_stopwatch_start']); });
|
this._redisClient.smembers(queryKey, bind(this, function(err, members) { if (err) { throw logger.error('could not retrieve set members', queryKey, err) } callback(members || []) }))
|
this._redisClient.get(key, function(err, valueBytes) { if (err) { throw logger.error('could not retrieve BYTES for key', key, err) } callback((valueBytes ? valueBytes.toString() : "null")) })
|
this._redisClient.smembers(queryKey, bind(this, function(err, members) { if (err) { throw logger.error('could not retrieve set members', queryKey, err) } callback(members || []) }))
|
i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?
|
(function(c){c.widget("ui.accordion",{options:{active:0,animated:"slide",autoHeight:true,clearStyle:false,collapsible:false,event:"click",fillSpace:false,header:"> li > :first-child,> :not(li):even",icons:{header:"ui-icon-triangle-1-e",headerSelected:"ui-icon-triangle-1-s"},navigation:false,navigationFilter:function(){return this.href.toLowerCase()===location.href.toLowerCase()}},_create:function(){var a=this,b=a.options;a.running=0;a.element.addClass("ui-accordion ui-widget ui-helper-reset").children("li").addClass("ui-accordion-li-fix"); a.headers=a.element.find(b.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){b.disabled||c(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){b.disabled||c(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){b.disabled||c(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){b.disabled||c(this).removeClass("ui-state-focus")});a.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom"); if(b.navigation){var d=a.element.find("a").filter(b.navigationFilter).eq(0);if(d.length){var f=d.closest(".ui-accordion-header");a.active=f.length?f:d.closest(".ui-accordion-content").prev()}}a.active=a._findActive(a.active||b.active).addClass("ui-state-default ui-state-active").toggleClass("ui-corner-all").toggleClass("ui-corner-top");a.active.next().addClass("ui-accordion-content-active");a._createIcons();a.resize();a.element.attr("role","tablist");a.headers.attr("role","tab").bind("keydown.accordion", function(g){return a._keydown(g)}).next().attr("role","tabpanel");a.headers.not(a.active||"").attr({"aria-expanded":"false",tabIndex:-1}).next().hide();a.active.length?a.active.attr({"aria-expanded":"true",tabIndex:0}):a.headers.eq(0).attr("tabIndex",0);c.browser.safari||a.headers.find("a").attr("tabIndex",-1);b.event&&a.headers.bind(b.event.split(" ").join(".accordion ")+".accordion",function(g){a._clickHandler.call(a,g,this);g.preventDefault()})},_createIcons:function(){var a=this.options;if(a.icons){c("<span></span>").addClass("ui-icon "+ a.icons.header).prependTo(this.headers);this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex"); this.headers.find("a").removeAttr("tabIndex");this._destroyIcons();var b=this.headers.next().css("display","").removeAttr("role").removeClass("ui-helper-reset ui-widget-content ui-corner-bottom ui-accordion-content ui-accordion-content-active ui-accordion-disabled ui-state-disabled");if(a.autoHeight||a.fillHeight)b.css("height","");return c.Widget.prototype.destroy.call(this)},_setOption:function(a,b){c.Widget.prototype._setOption.apply(this,arguments);a=="active"&&this.activate(b);if(a=="icons"){this._destroyIcons(); b&&this._createIcons()}if(a=="disabled")this.headers.add(this.headers.next())[b?"addClass":"removeClass"]("ui-accordion-disabled ui-state-disabled")},_keydown:function(a){if(!(this.options.disabled||a.altKey||a.ctrlKey)){var b=c.ui.keyCode,d=this.headers.length,f=this.headers.index(a.target),g=false;switch(a.keyCode){case b.RIGHT:case b.DOWN:g=this.headers[(f+1)%d];break;case b.LEFT:case b.UP:g=this.headers[(f-1+d)%d];break;case b.SPACE:case b.ENTER:this._clickHandler({target:a.target},a.target); a.preventDefault()}if(g){c(a.target).attr("tabIndex",-1);c(g).attr("tabIndex",0);g.focus();return false}return true}},resize:function(){var a=this.options,b;if(a.fillSpace){if(c.browser.msie){var d=this.element.parent().css("overflow");this.element.parent().css("overflow","hidden")}b=this.element.parent().height();c.browser.msie&&this.element.parent().css("overflow",d);this.headers.each(function(){b-=c(this).outerHeight(true)});this.headers.next().each(function(){c(this).height(Math.max(0,b-c(this).innerHeight()+ c(this).height()))}).css("overflow","auto")}else if(a.autoHeight){b=0;this.headers.next().each(function(){b=Math.max(b,c(this).height("").height())}).height(b)}return this},activate:function(a){this.options.active=a;a=this._findActive(a)[0];this._clickHandler({target:a},a);return this},_findActive:function(a){return a?typeof a==="number"?this.headers.filter(":eq("+a+")"):this.headers.not(this.headers.not(a)):a===false?c([]):this.headers.filter(":eq(0)")},_clickHandler:function(a,b){var d=this.options; if(!d.disabled)if(a.target){a=c(a.currentTarget||b);b=a[0]===this.active[0];d.active=d.collapsible&&b?false:this.headers.index(a);if(!(this.running||!d.collapsible&&b)){this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").children(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);if(!b){a.removeClass("ui-state-default ui-corner-all").addClass("ui-state-active ui-corner-top").children(".ui-icon").removeClass(d.icons.header).addClass(d.icons.headerSelected); a.next().addClass("ui-accordion-content-active")}h=a.next();f=this.active.next();g={options:d,newHeader:b&&d.collapsible?c([]):a,oldHeader:this.active,newContent:b&&d.collapsible?c([]):h,oldContent:f};d=this.headers.index(this.active[0])>this.headers.index(a[0]);this.active=b?c([]):a;this._toggle(h,f,g,b,d)}}else if(d.collapsible){this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").children(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header); this.active.next().addClass("ui-accordion-content-active");var f=this.active.next(),g={options:d,newHeader:c([]),oldHeader:d.active,newContent:c([]),oldContent:f},h=this.active=c([]);this._toggle(h,f,g)}},_toggle:function(a,b,d,f,g){var h=this,e=h.options;h.toShow=a;h.toHide=b;h.data=d;var j=function(){if(h)return h._completed.apply(h,arguments)};h._trigger("changestart",null,h.data);h.running=b.size()===0?a.size():b.size();if(e.animated){d={};d=e.collapsible&&f?{toShow:c([]),toHide:b,complete:j, down:g,autoHeight:e.autoHeight||e.fillSpace}:{toShow:a,toHide:b,complete:j,down:g,autoHeight:e.autoHeight||e.fillSpace};if(!e.proxied)e.proxied=e.animated;if(!e.proxiedDuration)e.proxiedDuration=e.duration;e.animated=c.isFunction(e.proxied)?e.proxied(d):e.proxied;e.duration=c.isFunction(e.proxiedDuration)?e.proxiedDuration(d):e.proxiedDuration;f=c.ui.accordion.animations;var i=e.duration,k=e.animated;if(k&&!f[k]&&!c.easing[k])k="slide";f[k]||(f[k]=function(l){this.slide(l,{easing:k,duration:i||700})}); f[k](d)}else{if(e.collapsible&&f)a.toggle();else{b.hide();a.show()}j(true)}b.prev().attr({"aria-expanded":"false",tabIndex:-1}).blur();a.prev().attr({"aria-expanded":"true",tabIndex:0}).focus()},_completed:function(a){this.running=a?0:--this.running;if(!this.running){this.options.clearStyle&&this.toShow.add(this.toHide).css({height:"",overflow:""});this.toHide.removeClass("ui-accordion-content-active");this._trigger("change",null,this.data)}}});c.extend(c.ui.accordion,{version:"1.8.6",animations:{slide:function(a, b){a=c.extend({easing:"swing",duration:300},a,b);if(a.toHide.size())if(a.toShow.size()){var d=a.toShow.css("overflow"),f=0,g={},h={},e;b=a.toShow;e=b[0].style.width;b.width(parseInt(b.parent().width(),10)-parseInt(b.css("paddingLeft"),10)-parseInt(b.css("paddingRight"),10)-(parseInt(b.css("borderLeftWidth"),10)||0)-(parseInt(b.css("borderRightWidth"),10)||0));c.each(["height","paddingTop","paddingBottom"],function(j,i){h[i]="hide";j=(""+c.css(a.toShow[0],i)).match(/^([\d+-.]+)(.*)$/);g[i]={value:j[1], unit:j[2]||"px"}});a.toShow.css({height:0,overflow:"hidden"}).show();a.toHide.filter(":hidden").each(a.complete).end().filter(":visible").animate(h,{step:function(j,i){if(i.prop=="height")f=i.end-i.start===0?0:(i.now-i.start)/(i.end-i.start);a.toShow[0].style[i.prop]=f*g[i.prop].value+g[i.prop].unit},duration:a.duration,easing:a.easing,complete:function(){a.autoHeight||a.toShow.css("height","");a.toShow.css({width:e,overflow:d});a.complete()}})}else a.toHide.animate({height:"hide",paddingTop:"hide", paddingBottom:"hide"},a);else a.toShow.animate({height:"show",paddingTop:"show",paddingBottom:"show"},a)},bounceslide:function(a){this.slide(a,{easing:a.down?"easeOutBounce":"swing",duration:a.down?1E3:200})}}})})(jQuery);
|
i){c[i]&&e[i+"Class"](c[i])});q=o(n.call(this));e.attr("className",u);e.animate(t(h,q),a,b,function(){f.each(p,function(v,i){c[i]&&e[i+"Class"](c[i])});if(typeof e.attr("style")=="object"){e.attr("style").cssText="";e.attr("style").cssText=g}else e.attr("style",g);d&&d.apply(this,arguments)})})};f.fn.extend({_addClass:f.fn.addClass,addClass:function(c,a,b,d){return a?f.effects.animateClass.apply(this,[{add:c},a,b,d]):this._addClass(c)},_removeClass:f.fn.removeClass,removeClass:function(c,a,b,d){return a?
|
"&":"?")+(e.jsonp||"callback")+"=?");else if(!e.data||!N.test(e.data))e.data=(e.data?e.data+"&":"")+(e.jsonp||"callback")+"=?";e.dataType="json"}if(e.dataType==="json"&&(e.data&&N.test(e.data)||N.test(e.url))){j=e.jsonpCallback||"jsonp"+sb++;if(e.data)e.data=(e.data+"").replace(N,"="+j+"$1");e.url=e.url.replace(N,"="+j+"$1");e.dataType="script";A[j]=A[j]||function(q){o=q;b();d();A[j]=w;try{delete A[j]}catch(p){}z&&z.removeChild(C)}}if(e.dataType==="script"&&e.cache===null)e.cache=false;if(e.cache===
|
!this.disabled&&(this.checked||ob.test(this.nodeName)||pb.test(this.type))}).map(function(a,b){var d=c(this).val();return d==null?null:c.isArray(d)?c.map(d,function(e){return{name:b.name,value:e}}):{name:b.name,value:d}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,e){if(c.isFunction(b)){e=e||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:e})},
|
"&":"?")+(e.jsonp||"callback")+"=?");else if(!e.data||!N.test(e.data))e.data=(e.data?e.data+"&":"")+(e.jsonp||"callback")+"=?";e.dataType="json"}if(e.dataType==="json"&&(e.data&&N.test(e.data)||N.test(e.url))){j=e.jsonpCallback||"jsonp"+sb++;if(e.data)e.data=(e.data+"").replace(N,"="+j+"$1");e.url=e.url.replace(N,"="+j+"$1");e.dataType="script";A[j]=A[j]||function(q){o=q;b();d();A[j]=w;try{delete A[j]}catch(p){}z&&z.removeChild(C)}}if(e.dataType==="script"&&e.cache===null)e.cache=false;if(e.cache===
|
var a={width:c.outerWidth(true),height:c.outerHeight(true),"float":c.css("float")},b=f("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0});c.wrap(b);b=c.parent();if(c.css("position")=="static"){b.css({position:"relative"});c.css({position:"relative"})}else{f.extend(a,{position:c.css("position"),zIndex:c.css("z-index")});f.each(["top","left","bottom","right"],function(d,e){a[e]=c.css(e);if(isNaN(parseInt(a[e],10)))a[e]="auto"});
|
a.headers=a.element.find(b.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){b.disabled||c(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){b.disabled||c(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){b.disabled||c(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){b.disabled||c(this).removeClass("ui-state-focus")});a.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");
|
var a={width:c.outerWidth(true),height:c.outerHeight(true),"float":c.css("float")},b=f("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0});c.wrap(b);b=c.parent();if(c.css("position")=="static"){b.css({position:"relative"});c.css({position:"relative"})}else{f.extend(a,{position:c.css("position"),zIndex:c.css("z-index")});f.each(["top","left","bottom","right"],function(d,e){a[e]=c.css(e);if(isNaN(parseInt(a[e],10)))a[e]="auto"});
|
g("abort")}}catch(l){}e.async&&e.timeout>0&&setTimeout(function(){x&&!E&&g("timeout")},e.timeout);try{x.send(n==="POST"||n==="PUT"||n==="DELETE"?e.data:null)}catch(m){c.handleError(e,x,null,m);d()}e.async||g();return x}},handleError:function(a,b,d,f){if(a.error)a.error.call(a.context||a,b,d,f);if(a.global)(a.context?c(a.context):c.event).trigger("ajaxError",[b,a,f])},active:0,httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status===
|
!this.disabled&&(this.checked||ob.test(this.nodeName)||pb.test(this.type))}).map(function(a,b){var d=c(this).val();return d==null?null:c.isArray(d)?c.map(d,function(e){return{name:b.name,value:e}}):{name:b.name,value:d}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,e){if(c.isFunction(b)){e=e||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:e})},
|
g("abort")}}catch(l){}e.async&&e.timeout>0&&setTimeout(function(){x&&!E&&g("timeout")},e.timeout);try{x.send(n==="POST"||n==="PUT"||n==="DELETE"?e.data:null)}catch(m){c.handleError(e,x,null,m);d()}e.async||g();return x}},handleError:function(a,b,d,f){if(a.error)a.error.call(a.context||a,b,d,f);if(a.global)(a.context?c(a.context):c.event).trigger("ajaxError",[b,a,f])},active:0,httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status===
|
c.css({position:"relative",top:0,left:0})}return b.css(a).show()},removeWrapper:function(c){if(c.parent().is(".ui-effects-wrapper"))return c.parent().replaceWith(c);return c},setTransition:function(c,a,b,d){d=d||{};f.each(a,function(e,g){unit=c.cssUnit(g);if(unit[0]>0)d[g]=unit[0]*b+unit[1]});return d}});f.fn.extend({effect:function(c){var a=k.apply(this,arguments);a={options:a[1],duration:a[2],callback:a[3]};var b=f.effects[c];return b&&!f.fx.off?b.call(this,a):this},_show:f.fn.show,show:function(c){if(!c||
|
a.headers=a.element.find(b.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){b.disabled||c(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){b.disabled||c(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){b.disabled||c(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){b.disabled||c(this).removeClass("ui-state-focus")});a.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");
|
c.css({position:"relative",top:0,left:0})}return b.css(a).show()},removeWrapper:function(c){if(c.parent().is(".ui-effects-wrapper"))return c.parent().replaceWith(c);return c},setTransition:function(c,a,b,d){d=d||{};f.each(a,function(e,g){unit=c.cssUnit(g);if(unit[0]>0)d[g]=unit[0]*b+unit[1]});return d}});f.fn.extend({effect:function(c){var a=k.apply(this,arguments);a={options:a[1],duration:a[2],callback:a[3]};var b=f.effects[c];return b&&!f.fx.off?b.call(this,a):this},_show:f.fn.show,show:function(c){if(!c||
|
"json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional;
|
!this.disabled&&(this.checked||ob.test(this.nodeName)||pb.test(this.type))}).map(function(a,b){var d=c(this).val();return d==null?null:c.isArray(d)?c.map(d,function(e){return{name:b.name,value:e}}):{name:b.name,value:d}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,e){if(c.isFunction(b)){e=e||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:e})},
|
"json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional;
|
arguments);else{var a=k.apply(this,arguments);a[1].mode="toggle";return this.effect.apply(this,a)}},cssUnit:function(c){var a=this.css(c),b=[];f.each(["em","px","%","pt"],function(d,e){if(a.indexOf(e)>0)b=[parseFloat(a),e]});return b}});f.easing.jswing=f.easing.swing;f.extend(f.easing,{def:"easeOutQuad",swing:function(c,a,b,d,e){return f.easing[f.easing.def](c,a,b,d,e)},easeInQuad:function(c,a,b,d,e){return d*(a/=e)*a+b},easeOutQuad:function(c,a,b,d,e){return-d*(a/=e)*(a-2)+b},easeInOutQuad:function(c,
|
a.headers=a.element.find(b.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){b.disabled||c(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){b.disabled||c(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){b.disabled||c(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){b.disabled||c(this).removeClass("ui-state-focus")});a.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");
|
arguments);else{var a=k.apply(this,arguments);a[1].mode="toggle";return this.effect.apply(this,a)}},cssUnit:function(c){var a=this.css(c),b=[];f.each(["em","px","%","pt"],function(d,e){if(a.indexOf(e)>0)b=[parseFloat(a),e]});return b}});f.easing.jswing=f.easing.swing;f.extend(f.easing,{def:"easeOutQuad",swing:function(c,a,b,d,e){return f.easing[f.easing.def](c,a,b,d,e)},easeInQuad:function(c,a,b,d,e){return d*(a/=e)*a+b},easeOutQuad:function(c,a,b,d,e){return-d*(a/=e)*(a-2)+b},easeInOutQuad:function(c,
|
"json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional;
|
!T.test(b.data))b.data=(b.data?b.data+"&":"")+(b.jsonp||"callback")+"=?";b.dataType="json"}if(b.dataType==="json"&&(b.data&&T.test(b.data)||T.test(b.url))){d=b.jsonpCallback||"jsonp"+mb++;if(b.data)b.data=(b.data+"").replace(T,"="+d+"$1");b.url=b.url.replace(T,"="+d+"$1");b.dataType="script";var k=E[d];E[d]=function(m){if(c.isFunction(k))k(m);else{E[d]=B;try{delete E[d]}catch(p){}}f=m;c.handleSuccess(b,w,e,f);c.handleComplete(b,w,e,f);r&&r.removeChild(A)}}if(b.dataType==="script"&&b.cache===null)b.cache=
|
"json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional;
|
(function(b){b.effects.blind=function(c){return this.queue(function(){var a=b(this),g=["position","top","left"],f=b.effects.setMode(a,c.options.mode||"hide"),d=c.options.direction||"vertical";b.effects.save(a,g);a.show();var e=b.effects.createWrapper(a).css({overflow:"hidden"}),h=d=="vertical"?"height":"width";d=d=="vertical"?e.height():e.width();f=="show"&&e.css(h,0);var i={};i[h]=f=="show"?d:0;e.animate(i,c.duration,c.options.easing,function(){f=="hide"&&a.hide();b.effects.restore(a,g);b.effects.removeWrapper(a); c.callback&&c.callback.apply(a[0],arguments);a.dequeue()})})}})(jQuery);
|
a.headers=a.element.find(b.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){b.disabled||c(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){b.disabled||c(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){b.disabled||c(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){b.disabled||c(this).removeClass("ui-state-focus")});a.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");
|
(function(b){b.effects.blind=function(c){return this.queue(function(){var a=b(this),g=["position","top","left"],f=b.effects.setMode(a,c.options.mode||"hide"),d=c.options.direction||"vertical";b.effects.save(a,g);a.show();var e=b.effects.createWrapper(a).css({overflow:"hidden"}),h=d=="vertical"?"height":"width";d=d=="vertical"?e.height():e.width();f=="show"&&e.css(h,0);var i={};i[h]=f=="show"?d:0;e.animate(i,c.duration,c.options.easing,function(){f=="hide"&&a.hide();b.effects.restore(a,g);b.effects.removeWrapper(a);c.callback&&c.callback.apply(a[0],arguments);a.dequeue()})})}})(jQuery);
|
if(c.isArray(a)||a.jquery)c.each(a,function(){f(this.name,this.value)});else for(var j in a)d(j,a[j]);return e.join("&").replace(yb,"+")}});var la={},Ab=/toggle|show|hide/,Bb=/^([+-]=)?([\d+-.]+)(.*)$/,W,va=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b){if(a||a===0)return this.animate(K("show",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");
|
c.handleSuccess(b,w,e,f);else c.handleError(b,w,e,p);d||c.handleComplete(b,w,e,f);m==="timeout"&&w.abort();if(b.async)w=null}};try{var g=w.abort;w.abort=function(){w&&Function.prototype.call.call(g,w);L("abort")}}catch(i){}b.async&&b.timeout>0&&setTimeout(function(){w&&!J&&L("timeout")},b.timeout);try{w.send(l||b.data==null?null:b.data)}catch(n){c.handleError(b,w,null,n);c.handleComplete(b,w,e,f)}b.async||L();return w}},param:function(a,b){var d=[],e=function(h,l){l=c.isFunction(l)?l():l;d[d.length]=
|
if(c.isArray(a)||a.jquery)c.each(a,function(){f(this.name,this.value)});else for(var j in a)d(j,a[j]);return e.join("&").replace(yb,"+")}});var la={},Ab=/toggle|show|hide/,Bb=/^([+-]=)?([\d+-.]+)(.*)$/,W,va=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b){if(a||a===0)return this.animate(K("show",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");
|
(function(b){b.effects.blind=function(c){return this.queue(function(){var a=b(this),g=["position","top","left"],f=b.effects.setMode(a,c.options.mode||"hide"),d=c.options.direction||"vertical";b.effects.save(a,g);a.show();var e=b.effects.createWrapper(a).css({overflow:"hidden"}),h=d=="vertical"?"height":"width";d=d=="vertical"?e.height():e.width();f=="show"&&e.css(h,0);var i={};i[h]=f=="show"?d:0;e.animate(i,c.duration,c.options.easing,function(){f=="hide"&&a.hide();b.effects.restore(a,g);b.effects.removeWrapper(a); c.callback&&c.callback.apply(a[0],arguments);a.dequeue()})})}})(jQuery);
|
function(g){return a._keydown(g)}).next().attr("role","tabpanel");a.headers.not(a.active||"").attr({"aria-expanded":"false",tabIndex:-1}).next().hide();a.active.length?a.active.attr({"aria-expanded":"true",tabIndex:0}):a.headers.eq(0).attr("tabIndex",0);c.browser.safari||a.headers.find("a").attr("tabIndex",-1);b.event&&a.headers.bind(b.event.split(" ").join(".accordion ")+".accordion",function(g){a._clickHandler.call(a,g,this);g.preventDefault()})},_createIcons:function(){var a=this.options;if(a.icons){c("<span></span>").addClass("ui-icon "+
|
(function(b){b.effects.blind=function(c){return this.queue(function(){var a=b(this),g=["position","top","left"],f=b.effects.setMode(a,c.options.mode||"hide"),d=c.options.direction||"vertical";b.effects.save(a,g);a.show();var e=b.effects.createWrapper(a).css({overflow:"hidden"}),h=d=="vertical"?"height":"width";d=d=="vertical"?e.height():e.width();f=="show"&&e.css(h,0);var i={};i[h]=f=="show"?d:0;e.animate(i,c.duration,c.options.easing,function(){f=="hide"&&a.hide();b.effects.restore(a,g);b.effects.removeWrapper(a);c.callback&&c.callback.apply(a[0],arguments);a.dequeue()})})}})(jQuery);
|
"olddisplay",c.css(this[a],"display"))}a=0;for(b=this.length;a<b;a++)this[a].style.display="none";return this}},_toggle:c.fn.toggle,toggle:function(a,b){var d=typeof a==="boolean";if(c.isFunction(a)&&c.isFunction(b))this._toggle.apply(this,arguments);else a==null||d?this.each(function(){var f=d?a:c(this).is(":hidden");c(this)[f?"show":"hide"]()}):this.animate(K("toggle",3),a,b);return this},fadeTo:function(a,b,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,d)},
|
encodeURIComponent(h)+"="+encodeURIComponent(l)};if(b===B)b=c.ajaxSettings.traditional;if(c.isArray(a)||a.jquery)c.each(a,function(){e(this.name,this.value)});else for(var f in a)da(f,a[f],b,e);return d.join("&").replace(tb,"+")}});c.extend({active:0,lastModified:{},etag:{},handleError:function(a,b,d,e){a.error&&a.error.call(a.context,b,d,e);a.global&&c.triggerGlobal(a,"ajaxError",[b,a,e])},handleSuccess:function(a,b,d,e){a.success&&a.success.call(a.context,e,d,b);a.global&&c.triggerGlobal(a,"ajaxSuccess",
|
"olddisplay",c.css(this[a],"display"))}a=0;for(b=this.length;a<b;a++)this[a].style.display="none";return this}},_toggle:c.fn.toggle,toggle:function(a,b){var d=typeof a==="boolean";if(c.isFunction(a)&&c.isFunction(b))this._toggle.apply(this,arguments);else a==null||d?this.each(function(){var f=d?a:c(this).is(":hidden");c(this)[f?"show":"hide"]()}):this.animate(K("toggle",3),a,b);return this},fadeTo:function(a,b,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,d)},
|
animate:function(a,b,d,f){var e=c.speed(b,d,f);if(c.isEmptyObject(a))return this.each(e.complete);return this[e.queue===false?"each":"queue"](function(){var j=c.extend({},e),i,o=this.nodeType===1&&c(this).is(":hidden"),k=this;for(i in a){var n=i.replace(ia,ja);if(i!==n){a[n]=a[i];delete a[i];i=n}if(a[i]==="hide"&&o||a[i]==="show"&&!o)return j.complete.call(this);if((i==="height"||i==="width")&&this.style){j.display=c.css(this,"display");j.overflow=this.style.overflow}if(c.isArray(a[i])){(j.specialEasing= j.specialEasing||{})[i]=a[i][1];a[i]=a[i][0]}}if(j.overflow!=null)this.style.overflow="hidden";j.curAnim=c.extend({},a);c.each(a,function(r,u){var z=new c.fx(k,j,r);if(Ab.test(u))z[u==="toggle"?o?"show":"hide":u](a);else{var C=Bb.exec(u),B=z.cur(true)||0;if(C){u=parseFloat(C[2]);var E=C[3]||"px";if(E!=="px"){k.style[r]=(u||1)+E;B=(u||1)/z.cur(true)*B;k.style[r]=B+E}if(C[1])u=(C[1]==="-="?-1:1)*u+B;z.custom(B,u,E)}else z.custom(B,u,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);
|
d)}for(a=0;a<b;a++)this[a].style.display="none";return this}},_toggle:c.fn.toggle,toggle:function(a,b,d){var e=typeof a==="boolean";if(c.isFunction(a)&&c.isFunction(b))this._toggle.apply(this,arguments);else a==null||e?this.each(function(){var f=e?a:c(this).is(":hidden");c(this)[f?"show":"hide"]()}):this.animate(S("toggle",3),a,b,d);return this},fadeTo:function(a,b,d,e){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,d,e)},animate:function(a,b,d,e){var f=c.speed(b,
|
animate:function(a,b,d,f){var e=c.speed(b,d,f);if(c.isEmptyObject(a))return this.each(e.complete);return this[e.queue===false?"each":"queue"](function(){var j=c.extend({},e),i,o=this.nodeType===1&&c(this).is(":hidden"),k=this;for(i in a){var n=i.replace(ia,ja);if(i!==n){a[n]=a[i];delete a[i];i=n}if(a[i]==="hide"&&o||a[i]==="show"&&!o)return j.complete.call(this);if((i==="height"||i==="width")&&this.style){j.display=c.css(this,"display");j.overflow=this.style.overflow}if(c.isArray(a[i])){(j.specialEasing=j.specialEasing||{})[i]=a[i][1];a[i]=a[i][0]}}if(j.overflow!=null)this.style.overflow="hidden";j.curAnim=c.extend({},a);c.each(a,function(r,u){var z=new c.fx(k,j,r);if(Ab.test(u))z[u==="toggle"?o?"show":"hide":u](a);else{var C=Bb.exec(u),B=z.cur(true)||0;if(C){u=parseFloat(C[2]);var E=C[3]||"px";if(E!=="px"){k.style[r]=(u||1)+E;B=(u||1)/z.cur(true)*B;k.style[r]=B+E}if(C[1])u=(C[1]==="-="?-1:1)*u+B;z.custom(B,u,E)}else z.custom(B,u,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);
|
(function(e){e.effects.bounce=function(b){return this.queue(function(){var a=e(this),l=["position","top","left"],h=e.effects.setMode(a,b.options.mode||"effect"),d=b.options.direction||"up",c=b.options.distance||20,m=b.options.times||5,i=b.duration||250;/show|hide/.test(h)&&l.push("opacity");e.effects.save(a,l);a.show();e.effects.createWrapper(a);var f=d=="up"||d=="down"?"top":"left";d=d=="up"||d=="left"?"pos":"neg";c=b.options.distance||(f=="top"?a.outerHeight({margin:true})/3:a.outerWidth({margin:true})/ 3);if(h=="show")a.css("opacity",0).css(f,d=="pos"?-c:c);if(h=="hide")c/=m*2;h!="hide"&&m--;if(h=="show"){var g={opacity:1};g[f]=(d=="pos"?"+=":"-=")+c;a.animate(g,i/2,b.options.easing);c/=2;m--}for(g=0;g<m;g++){var j={},k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing);c=h=="hide"?c*2:c/2}if(h=="hide"){g={opacity:0};g[f]=(d=="pos"?"-=":"+=")+c;a.animate(g,i/2,b.options.easing,function(){a.hide();e.effects.restore(a,l);e.effects.removeWrapper(a); b.callback&&b.callback.apply(this,arguments)})}else{j={};k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing,function(){e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}a.queue("fx",function(){a.dequeue()});a.dequeue()})}})(jQuery);
|
{version:"1.8.2",animations:{slide:function(a,b){a=c.extend({easing:"swing",duration:300},a,b);if(a.toHide.size())if(a.toShow.size()){var d=a.toShow.css("overflow"),f=0,g={},e={},k;b=a.toShow;k=b[0].style.width;b.width(parseInt(b.parent().width(),10)-parseInt(b.css("paddingLeft"),10)-parseInt(b.css("paddingRight"),10)-(parseInt(b.css("borderLeftWidth"),10)||0)-(parseInt(b.css("borderRightWidth"),10)||0));c.each(["height","paddingTop","paddingBottom"],function(i,h){e[h]="hide";i=(""+c.css(a.toShow[0], h)).match(/^([\d+-.]+)(.*)$/);g[h]={value:i[1],unit:i[2]||"px"}});a.toShow.css({height:0,overflow:"hidden"}).show();a.toHide.filter(":hidden").each(a.complete).end().filter(":visible").animate(e,{step:function(i,h){if(h.prop=="height")f=h.end-h.start===0?0:(h.now-h.start)/(h.end-h.start);a.toShow[0].style[h.prop]=f*g[h.prop].value+g[h.prop].unit},duration:a.duration,easing:a.easing,complete:function(){a.autoHeight||a.toShow.css("height","");a.toShow.css("width",k);a.toShow.css({overflow:d});a.complete()}})}else a.toHide.animate({height:"hide"},
|
(function(e){e.effects.bounce=function(b){return this.queue(function(){var a=e(this),l=["position","top","left"],h=e.effects.setMode(a,b.options.mode||"effect"),d=b.options.direction||"up",c=b.options.distance||20,m=b.options.times||5,i=b.duration||250;/show|hide/.test(h)&&l.push("opacity");e.effects.save(a,l);a.show();e.effects.createWrapper(a);var f=d=="up"||d=="down"?"top":"left";d=d=="up"||d=="left"?"pos":"neg";c=b.options.distance||(f=="top"?a.outerHeight({margin:true})/3:a.outerWidth({margin:true})/3);if(h=="show")a.css("opacity",0).css(f,d=="pos"?-c:c);if(h=="hide")c/=m*2;h!="hide"&&m--;if(h=="show"){var g={opacity:1};g[f]=(d=="pos"?"+=":"-=")+c;a.animate(g,i/2,b.options.easing);c/=2;m--}for(g=0;g<m;g++){var j={},k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing);c=h=="hide"?c*2:c/2}if(h=="hide"){g={opacity:0};g[f]=(d=="pos"?"-=":"+=")+c;a.animate(g,i/2,b.options.easing,function(){a.hide();e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}else{j={};k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing,function(){e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}a.queue("fx",function(){a.dequeue()});a.dequeue()})}})(jQuery);
|
j.specialEasing||{})[i]=a[i][1];a[i]=a[i][0]}}if(j.overflow!=null)this.style.overflow="hidden";j.curAnim=c.extend({},a);c.each(a,function(r,u){var z=new c.fx(k,j,r);if(Ab.test(u))z[u==="toggle"?o?"show":"hide":u](a);else{var C=Bb.exec(u),B=z.cur(true)||0;if(C){u=parseFloat(C[2]);var E=C[3]||"px";if(E!=="px"){k.style[r]=(u||1)+E;B=(u||1)/z.cur(true)*B;k.style[r]=B+E}if(C[1])u=(C[1]==="-="?-1:1)*u+B;z.custom(B,u,E)}else z.custom(B,u,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);
|
d,e);if(c.isEmptyObject(a))return this.each(f.complete);return this[f.queue===false?"each":"queue"](function(){var h=c.extend({},f),l,k=this.nodeType===1,o=k&&c(this).is(":hidden"),x=this;for(l in a){var r=c.camelCase(l);if(l!==r){a[r]=a[l];delete a[l];l=r}if(a[l]==="hide"&&o||a[l]==="show"&&!o)return h.complete.call(this);if(k&&(l==="height"||l==="width")){h.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY];if(c.css(this,"display")==="inline"&&c.css(this,"float")==="none")if(c.support.inlineBlockNeedsLayout)if(qa(this.nodeName)=== "inline")this.style.display="inline-block";else{this.style.display="inline";this.style.zoom=1}else this.style.display="inline-block"}if(c.isArray(a[l])){(h.specialEasing=h.specialEasing||{})[l]=a[l][1];a[l]=a[l][0]}}if(h.overflow!=null)this.style.overflow="hidden";h.curAnim=c.extend({},a);c.each(a,function(A,C){var J=new c.fx(x,h,A);if(vb.test(C))J[C==="toggle"?o?"show":"hide":C](a);else{var w=wb.exec(C),I=J.cur()||0;if(w){var L=parseFloat(w[2]),g=w[3]||"px";if(g!=="px"){c.style(x,A,(L||1)+g);I=(L|| 1)/J.cur()*I;c.style(x,A,I+g)}if(w[1])L=(w[1]==="-="?-1:1)*L+I;J.custom(I,L,g)}else J.custom(I,C,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);this.each(function(){for(var e=d.length-1;e>=0;e--)if(d[e].elem===this){b&&d[e](true);d.splice(e,1)}});b||this.dequeue();return this}});c.each({slideDown:S("show",1),slideUp:S("hide",1),slideToggle:S("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){c.fn[a]=function(d,e,f){return this.animate(b,
|
j.specialEasing||{})[i]=a[i][1];a[i]=a[i][0]}}if(j.overflow!=null)this.style.overflow="hidden";j.curAnim=c.extend({},a);c.each(a,function(r,u){var z=new c.fx(k,j,r);if(Ab.test(u))z[u==="toggle"?o?"show":"hide":u](a);else{var C=Bb.exec(u),B=z.cur(true)||0;if(C){u=parseFloat(C[2]);var E=C[3]||"px";if(E!=="px"){k.style[r]=(u||1)+E;B=(u||1)/z.cur(true)*B;k.style[r]=B+E}if(C[1])u=(C[1]==="-="?-1:1)*u+B;z.custom(B,u,E)}else z.custom(B,u,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);
|
(function(e){e.effects.bounce=function(b){return this.queue(function(){var a=e(this),l=["position","top","left"],h=e.effects.setMode(a,b.options.mode||"effect"),d=b.options.direction||"up",c=b.options.distance||20,m=b.options.times||5,i=b.duration||250;/show|hide/.test(h)&&l.push("opacity");e.effects.save(a,l);a.show();e.effects.createWrapper(a);var f=d=="up"||d=="down"?"top":"left";d=d=="up"||d=="left"?"pos":"neg";c=b.options.distance||(f=="top"?a.outerHeight({margin:true})/3:a.outerWidth({margin:true})/ 3);if(h=="show")a.css("opacity",0).css(f,d=="pos"?-c:c);if(h=="hide")c/=m*2;h!="hide"&&m--;if(h=="show"){var g={opacity:1};g[f]=(d=="pos"?"+=":"-=")+c;a.animate(g,i/2,b.options.easing);c/=2;m--}for(g=0;g<m;g++){var j={},k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing);c=h=="hide"?c*2:c/2}if(h=="hide"){g={opacity:0};g[f]=(d=="pos"?"-=":"+=")+c;a.animate(g,i/2,b.options.easing,function(){a.hide();e.effects.restore(a,l);e.effects.removeWrapper(a); b.callback&&b.callback.apply(this,arguments)})}else{j={};k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing,function(){e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}a.queue("fx",function(){a.dequeue()});a.dequeue()})}})(jQuery);
|
a.preventDefault()}if(g){c(a.target).attr("tabIndex",-1);c(g).attr("tabIndex",0);g.focus();return false}return true}},resize:function(){var a=this.options,b;if(a.fillSpace){if(c.browser.msie){var d=this.element.parent().css("overflow");this.element.parent().css("overflow","hidden")}b=this.element.parent().height();c.browser.msie&&this.element.parent().css("overflow",d);this.headers.each(function(){b-=c(this).outerHeight(true)});this.headers.next().each(function(){c(this).height(Math.max(0,b-c(this).innerHeight()+ c(this).height()))}).css("overflow","auto")}else if(a.autoHeight){b=0;this.headers.next().each(function(){b=Math.max(b,c(this).height("").height())}).height(b)}return this},activate:function(a){this.options.active=a;a=this._findActive(a)[0];this._clickHandler({target:a},a);return this},_findActive:function(a){return a?typeof a==="number"?this.headers.filter(":eq("+a+")"):this.headers.not(this.headers.not(a)):a===false?c([]):this.headers.filter(":eq(0)")},_clickHandler:function(a,b){var d=this.options;
|
(function(e){e.effects.bounce=function(b){return this.queue(function(){var a=e(this),l=["position","top","left"],h=e.effects.setMode(a,b.options.mode||"effect"),d=b.options.direction||"up",c=b.options.distance||20,m=b.options.times||5,i=b.duration||250;/show|hide/.test(h)&&l.push("opacity");e.effects.save(a,l);a.show();e.effects.createWrapper(a);var f=d=="up"||d=="down"?"top":"left";d=d=="up"||d=="left"?"pos":"neg";c=b.options.distance||(f=="top"?a.outerHeight({margin:true})/3:a.outerWidth({margin:true})/3);if(h=="show")a.css("opacity",0).css(f,d=="pos"?-c:c);if(h=="hide")c/=m*2;h!="hide"&&m--;if(h=="show"){var g={opacity:1};g[f]=(d=="pos"?"+=":"-=")+c;a.animate(g,i/2,b.options.easing);c/=2;m--}for(g=0;g<m;g++){var j={},k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing);c=h=="hide"?c*2:c/2}if(h=="hide"){g={opacity:0};g[f]=(d=="pos"?"-=":"+=")+c;a.animate(g,i/2,b.options.easing,function(){a.hide();e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}else{j={};k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing,function(){e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}a.queue("fx",function(){a.dequeue()});a.dequeue()})}})(jQuery);
|
this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration===
|
"inline")this.style.display="inline-block";else{this.style.display="inline";this.style.zoom=1}else this.style.display="inline-block"}if(c.isArray(a[l])){(h.specialEasing=h.specialEasing||{})[l]=a[l][1];a[l]=a[l][0]}}if(h.overflow!=null)this.style.overflow="hidden";h.curAnim=c.extend({},a);c.each(a,function(A,C){var J=new c.fx(x,h,A);if(vb.test(C))J[C==="toggle"?o?"show":"hide":C](a);else{var w=wb.exec(C),I=J.cur()||0;if(w){var L=parseFloat(w[2]),g=w[3]||"px";if(g!=="px"){c.style(x,A,(L||1)+g);I=(L|| 1)/J.cur()*I;c.style(x,A,I+g)}if(w[1])L=(w[1]==="-="?-1:1)*L+I;J.custom(I,L,g)}else J.custom(I,C,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);this.each(function(){for(var e=d.length-1;e>=0;e--)if(d[e].elem===this){b&&d[e](true);d.splice(e,1)}});b||this.dequeue();return this}});c.each({slideDown:S("show",1),slideUp:S("hide",1),slideToggle:S("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){c.fn[a]=function(d,e,f){return this.animate(b,
|
this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration===
|
3);if(h=="show")a.css("opacity",0).css(f,d=="pos"?-c:c);if(h=="hide")c/=m*2;h!="hide"&&m--;if(h=="show"){var g={opacity:1};g[f]=(d=="pos"?"+=":"-=")+c;a.animate(g,i/2,b.options.easing);c/=2;m--}for(g=0;g<m;g++){var j={},k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing);c=h=="hide"?c*2:c/2}if(h=="hide"){g={opacity:0};g[f]=(d=="pos"?"-=":"+=")+c;a.animate(g,i/2,b.options.easing,function(){a.hide();e.effects.restore(a,l);e.effects.removeWrapper(a); b.callback&&b.callback.apply(this,arguments)})}else{j={};k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing,function(){e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}a.queue("fx",function(){a.dequeue()});a.dequeue()})}})(jQuery);
|
c(this).height()))}).css("overflow","auto")}else if(a.autoHeight){b=0;this.headers.next().each(function(){b=Math.max(b,c(this).height("").height())}).height(b)}return this},activate:function(a){this.options.active=a;a=this._findActive(a)[0];this._clickHandler({target:a},a);return this},_findActive:function(a){return a?typeof a==="number"?this.headers.filter(":eq("+a+")"):this.headers.not(this.headers.not(a)):a===false?c([]):this.headers.filter(":eq(0)")},_clickHandler:function(a,b){var d=this.options;
|
3);if(h=="show")a.css("opacity",0).css(f,d=="pos"?-c:c);if(h=="hide")c/=m*2;h!="hide"&&m--;if(h=="show"){var g={opacity:1};g[f]=(d=="pos"?"+=":"-=")+c;a.animate(g,i/2,b.options.easing);c/=2;m--}for(g=0;g<m;g++){var j={},k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing);c=h=="hide"?c*2:c/2}if(h=="hide"){g={opacity:0};g[f]=(d=="pos"?"-=":"+=")+c;a.animate(g,i/2,b.options.easing,function(){a.hide();e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}else{j={};k={};j[f]=(d=="pos"?"-=":"+=")+c;k[f]=(d=="pos"?"+=":"-=")+c;a.animate(j,i/2,b.options.easing).animate(k,i/2,b.options.easing,function(){e.effects.restore(a,l);e.effects.removeWrapper(a);b.callback&&b.callback.apply(this,arguments)})}a.queue("fx",function(){a.dequeue()});a.dequeue()})}})(jQuery);
|
this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration===
|
1)/J.cur()*I;c.style(x,A,I+g)}if(w[1])L=(w[1]==="-="?-1:1)*L+I;J.custom(I,L,g)}else J.custom(I,C,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);this.each(function(){for(var e=d.length-1;e>=0;e--)if(d[e].elem===this){b&&d[e](true);d.splice(e,1)}});b||this.dequeue();return this}});c.each({slideDown:S("show",1),slideUp:S("hide",1),slideToggle:S("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){c.fn[a]=function(d,e,f){return this.animate(b,
|
this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration===
|
if ( typeof translation == 'undefined' ) { alert ( "Translation Element Undefined For " + parentElement.id ); return ( false ); }
|
function __ ( pText, pData ) { var parentElement = arguments.callee.caller.arguments[0]; var translation = jTranslations[parentElement.id]; var translationElementId = 'appleseed-language-components-' + translation; var translationElement = document.getElementById ( translationElementId ); // @todo: Load global data first, then overwrite with local data. translationData = JSON.parse(translationElement.innerText); var text = sprintfn ( pText, pData ); return ( text );}
|
|
if (JX.Stratcom && JX.Stratcom.ready) {
|
if (JX['Stratcom'] && JX['Stratcom'].ready) {
|
JX.__rawEventQueue = function (what) { what = what || window.event; master_event_queue.push(what); if (JX.Stratcom && JX.Stratcom.ready) { // Empty the queue now so that exceptions don't cause us to repeatedly // try to handle events. var local_queue = master_event_queue; master_event_queue = []; for (var ii = 0; ii < local_queue.length; ++ii) { var evt = local_queue[ii]; // Sometimes IE gives us events which throw when ".type" is accessed; // just ignore them since we can't meaningfully dispatch them. TODO: // figure out where these are coming from. try { var test = evt.type; } catch (x) { continue; } if (!loaded && evt.type == 'domready') { document.body && (document.body.id = null); loaded = true; for (var ii = 0; ii < onload.length; ii++) { onload[ii](); } } JX.Stratcom.dispatch(evt); } } else { var t = what.srcElement || what.target; if (t && (what.type in {click:1, submit:1}) && (' '+t.className+' ').match(/ FI_CAPTURE /)) { what.returnValue = false; what.preventDefault && what.preventDefault(); document.body.id = 'event_capture'; return false; } } }
|
JX.Stratcom.dispatch(evt);
|
JX['Stratcom'].dispatch(evt);
|
JX.__rawEventQueue = function (what) { what = what || window.event; master_event_queue.push(what); if (JX.Stratcom && JX.Stratcom.ready) { // Empty the queue now so that exceptions don't cause us to repeatedly // try to handle events. var local_queue = master_event_queue; master_event_queue = []; for (var ii = 0; ii < local_queue.length; ++ii) { var evt = local_queue[ii]; // Sometimes IE gives us events which throw when ".type" is accessed; // just ignore them since we can't meaningfully dispatch them. TODO: // figure out where these are coming from. try { var test = evt.type; } catch (x) { continue; } if (!loaded && evt.type == 'domready') { document.body && (document.body.id = null); loaded = true; for (var ii = 0; ii < onload.length; ii++) { onload[ii](); } } JX.Stratcom.dispatch(evt); } } else { var t = what.srcElement || what.target; if (t && (what.type in {click:1, submit:1}) && (' '+t.className+' ').match(/ FI_CAPTURE /)) { what.returnValue = false; what.preventDefault && what.preventDefault(); document.body.id = 'event_capture'; return false; } } }
|
b);for(var c in b)if(b[c]==null||b[c]==G)a[c]=b[c];return a}d.extend(d.ui,{datepicker:{version:"1.8.4"}});var y=(new Date).getTime();d.extend(L.prototype,{markerClassName:"hasDatepicker",log:function(){this.debug&&console.log.apply("",arguments)},_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(a){E(this._defaults,a||{});return this},_attachDatepicker:function(a,b){var c=null;for(var e in this._defaults){var f=a.getAttribute("date:"+e);if(f){c=c||{};try{c[e]=eval(f)}catch(h){c[e]= f}}}e=a.nodeName.toLowerCase();f=e=="div"||e=="span";if(!a.id){this.uuid+=1;a.id="dp"+this.uuid}var i=this._newInst(d(a),f);i.settings=d.extend({},b||{},c||{});if(e=="input")this._connectDatepicker(a,i);else f&&this._inlineDatepicker(a,i)},_newInst:function(a,b){return{id:a[0].id.replace(/([^A-Za-z0-9_])/g,"\\\\$1"),input:a,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:b,dpDiv:!b?this.dpDiv:d('<div class="'+this._inlineClass+' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')}},
|
b);for(var c in b)if(b[c]==null||b[c]==G)a[c]=b[c];return a}d.extend(d.ui,{datepicker:{version:"1.8.6"}});var y=(new Date).getTime();d.extend(K.prototype,{markerClassName:"hasDatepicker",log:function(){this.debug&&console.log.apply("",arguments)},_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(a){E(this._defaults,a||{});return this},_attachDatepicker:function(a,b){var c=null;for(var e in this._defaults){var f=a.getAttribute("date:"+e);if(f){c=c||{};try{c[e]=eval(f)}catch(h){c[e]= f}}}e=a.nodeName.toLowerCase();f=e=="div"||e=="span";if(!a.id){this.uuid+=1;a.id="dp"+this.uuid}var i=this._newInst(d(a),f);i.settings=d.extend({},b||{},c||{});if(e=="input")this._connectDatepicker(a,i);else f&&this._inlineDatepicker(a,i)},_newInst:function(a,b){return{id:a[0].id.replace(/([^A-Za-z0-9_-])/g,"\\\\$1"),input:a,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:b,dpDiv:!b?this.dpDiv:d('<div class="'+this._inlineClass+' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')}},
|
b);for(var c in b)if(b[c]==null||b[c]==G)a[c]=b[c];return a}d.extend(d.ui,{datepicker:{version:"1.8.4"}});var y=(new Date).getTime();d.extend(L.prototype,{markerClassName:"hasDatepicker",log:function(){this.debug&&console.log.apply("",arguments)},_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(a){E(this._defaults,a||{});return this},_attachDatepicker:function(a,b){var c=null;for(var e in this._defaults){var f=a.getAttribute("date:"+e);if(f){c=c||{};try{c[e]=eval(f)}catch(h){c[e]=f}}}e=a.nodeName.toLowerCase();f=e=="div"||e=="span";if(!a.id){this.uuid+=1;a.id="dp"+this.uuid}var i=this._newInst(d(a),f);i.settings=d.extend({},b||{},c||{});if(e=="input")this._connectDatepicker(a,i);else f&&this._inlineDatepicker(a,i)},_newInst:function(a,b){return{id:a[0].id.replace(/([^A-Za-z0-9_])/g,"\\\\$1"),input:a,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:b,dpDiv:!b?this.dpDiv:d('<div class="'+this._inlineClass+' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')}},
|
var FCKeditorAPI;function InitializeAPI(){var A=window.parent;if (!(FCKeditorAPI=A.FCKeditorAPI)){var B='window.FCKeditorAPI = {Version : "2.6.5",VersionBuild : "23959",Instances : window.FCKeditorAPI && window.FCKeditorAPI.Instances || {},GetInstance : function( name ){return this.Instances[ name ];},_FormSubmit : function(){for ( var name in FCKeditorAPI.Instances ){var oEditor = FCKeditorAPI.Instances[ name ] ;if ( oEditor.GetParentForm && oEditor.GetParentForm() == this )oEditor.UpdateLinkedField() ;}this._FCKOriginalSubmit() ;},_FunctionQueue : window.FCKeditorAPI && window.FCKeditorAPI._FunctionQueue || {Functions : new Array(),IsRunning : false,Add : function( f ){this.Functions.push( f );if ( !this.IsRunning )this.StartNext();},StartNext : function(){var aQueue = this.Functions ;if ( aQueue.length > 0 ){this.IsRunning = true;aQueue[0].call();}else this.IsRunning = false;},Remove : function( f ){var aQueue = this.Functions;var i = 0, fFunc;while( (fFunc = aQueue[ i ]) ){if ( fFunc == f )aQueue.splice( i,1 );i++ ;}this.StartNext();}}}';if (A.execScript) A.execScript(B,'JavaScript');else{if (FCKBrowserInfo.IsGecko10){eval.call(A,B);}else if(FCKBrowserInfo.IsAIR){FCKAdobeAIR.FCKeditorAPI_Evaluate(A,B);}else if (FCKBrowserInfo.IsSafari){var C=A.document;var D=C.createElement('script');D.appendChild(C.createTextNode(B));C.documentElement.appendChild(D);}else A.eval(B);};FCKeditorAPI=A.FCKeditorAPI;FCKeditorAPI.__Instances=FCKeditorAPI.Instances;};FCKeditorAPI.Instances[FCK.Name]=FCK;};function _AttachFormSubmitToAPI(){var A=FCK.GetParentForm();if (A){FCKTools.AddEventListener(A,'submit',FCK.UpdateLinkedField);if (!A._FCKOriginalSubmit&&(typeof(A.submit)=='function'||(!A.submit.tagName&&!A.submit.length))){A._FCKOriginalSubmit=A.submit;A.submit=FCKeditorAPI._FormSubmit;}}};function FCKeditorAPI_Cleanup(){if (window.FCKConfig&&FCKConfig.MsWebBrowserControlCompat&&!window.FCKUnloadFlag) return;delete FCKeditorAPI.Instances[FCK.Name];};function FCKeditorAPI_ConfirmCleanup(){if (window.FCKConfig&&FCKConfig.MsWebBrowserControlCompat) window.FCKUnloadFlag=true;};FCKTools.AddEventListener(window,'unload',FCKeditorAPI_Cleanup);FCKTools.AddEventListener(window,'beforeunload',FCKeditorAPI_ConfirmCleanup);
|
var FCKeditorAPI;function InitializeAPI(){var A=window.parent;if (!(FCKeditorAPI=A.FCKeditorAPI)){var B='window.FCKeditorAPI = {Version : "2.6.6",VersionBuild : "25427",Instances : window.FCKeditorAPI && window.FCKeditorAPI.Instances || {},GetInstance : function( name ){return this.Instances[ name ];},_FormSubmit : function(){for ( var name in FCKeditorAPI.Instances ){var oEditor = FCKeditorAPI.Instances[ name ] ;if ( oEditor.GetParentForm && oEditor.GetParentForm() == this )oEditor.UpdateLinkedField() ;}this._FCKOriginalSubmit() ;},_FunctionQueue : window.FCKeditorAPI && window.FCKeditorAPI._FunctionQueue || {Functions : new Array(),IsRunning : false,Add : function( f ){this.Functions.push( f );if ( !this.IsRunning )this.StartNext();},StartNext : function(){var aQueue = this.Functions ;if ( aQueue.length > 0 ){this.IsRunning = true;aQueue[0].call();}else this.IsRunning = false;},Remove : function( f ){var aQueue = this.Functions;var i = 0, fFunc;while( (fFunc = aQueue[ i ]) ){if ( fFunc == f )aQueue.splice( i,1 );i++ ;}this.StartNext();}}}';if (A.execScript) A.execScript(B,'JavaScript');else{if (FCKBrowserInfo.IsGecko10){eval.call(A,B);}else if(FCKBrowserInfo.IsAIR){FCKAdobeAIR.FCKeditorAPI_Evaluate(A,B);}else if (FCKBrowserInfo.IsSafari){var C=A.document;var D=C.createElement('script');D.appendChild(C.createTextNode(B));C.documentElement.appendChild(D);}else A.eval(B);};FCKeditorAPI=A.FCKeditorAPI;FCKeditorAPI.__Instances=FCKeditorAPI.Instances;};FCKeditorAPI.Instances[FCK.Name]=FCK;};function _AttachFormSubmitToAPI(){var A=FCK.GetParentForm();if (A){FCKTools.AddEventListener(A,'submit',FCK.UpdateLinkedField);if (!A._FCKOriginalSubmit&&(typeof(A.submit)=='function'||(!A.submit.tagName&&!A.submit.length))){A._FCKOriginalSubmit=A.submit;A.submit=FCKeditorAPI._FormSubmit;}}};function FCKeditorAPI_Cleanup(){if (window.FCKConfig&&FCKConfig.MsWebBrowserControlCompat&&!window.FCKUnloadFlag) return;delete FCKeditorAPI.Instances[FCK.Name];};function FCKeditorAPI_ConfirmCleanup(){if (window.FCKConfig&&FCKConfig.MsWebBrowserControlCompat) window.FCKUnloadFlag=true;};FCKTools.AddEventListener(window,'unload',FCKeditorAPI_Cleanup);FCKTools.AddEventListener(window,'beforeunload',FCKeditorAPI_ConfirmCleanup);
|
var FCKeditorAPI;function InitializeAPI(){var A=window.parent;if (!(FCKeditorAPI=A.FCKeditorAPI)){var B='window.FCKeditorAPI = {Version : "2.6.5",VersionBuild : "23959",Instances : window.FCKeditorAPI && window.FCKeditorAPI.Instances || {},GetInstance : function( name ){return this.Instances[ name ];},_FormSubmit : function(){for ( var name in FCKeditorAPI.Instances ){var oEditor = FCKeditorAPI.Instances[ name ] ;if ( oEditor.GetParentForm && oEditor.GetParentForm() == this )oEditor.UpdateLinkedField() ;}this._FCKOriginalSubmit() ;},_FunctionQueue : window.FCKeditorAPI && window.FCKeditorAPI._FunctionQueue || {Functions : new Array(),IsRunning : false,Add : function( f ){this.Functions.push( f );if ( !this.IsRunning )this.StartNext();},StartNext : function(){var aQueue = this.Functions ;if ( aQueue.length > 0 ){this.IsRunning = true;aQueue[0].call();}else this.IsRunning = false;},Remove : function( f ){var aQueue = this.Functions;var i = 0, fFunc;while( (fFunc = aQueue[ i ]) ){if ( fFunc == f )aQueue.splice( i,1 );i++ ;}this.StartNext();}}}';if (A.execScript) A.execScript(B,'JavaScript');else{if (FCKBrowserInfo.IsGecko10){eval.call(A,B);}else if(FCKBrowserInfo.IsAIR){FCKAdobeAIR.FCKeditorAPI_Evaluate(A,B);}else if (FCKBrowserInfo.IsSafari){var C=A.document;var D=C.createElement('script');D.appendChild(C.createTextNode(B));C.documentElement.appendChild(D);}else A.eval(B);};FCKeditorAPI=A.FCKeditorAPI;FCKeditorAPI.__Instances=FCKeditorAPI.Instances;};FCKeditorAPI.Instances[FCK.Name]=FCK;};function _AttachFormSubmitToAPI(){var A=FCK.GetParentForm();if (A){FCKTools.AddEventListener(A,'submit',FCK.UpdateLinkedField);if (!A._FCKOriginalSubmit&&(typeof(A.submit)=='function'||(!A.submit.tagName&&!A.submit.length))){A._FCKOriginalSubmit=A.submit;A.submit=FCKeditorAPI._FormSubmit;}}};function FCKeditorAPI_Cleanup(){if (window.FCKConfig&&FCKConfig.MsWebBrowserControlCompat&&!window.FCKUnloadFlag) return;delete FCKeditorAPI.Instances[FCK.Name];};function FCKeditorAPI_ConfirmCleanup(){if (window.FCKConfig&&FCKConfig.MsWebBrowserControlCompat) window.FCKUnloadFlag=true;};FCKTools.AddEventListener(window,'unload',FCKeditorAPI_Cleanup);FCKTools.AddEventListener(window,'beforeunload',FCKeditorAPI_ConfirmCleanup);
|
var noFilter = ORBEON.util.Dom.hasClass(autoComplete, "xforms-select1-open-autocomplete-nofilter");
|
var noFilter = YAHOO.util.Dom.hasClass(autoComplete, "xforms-select1-open-autocomplete-nofilter");
|
_autoComplete: function(autoComplete) { var textfield = ORBEON.util.Dom.getChildElementByIndex(autoComplete, 0); var select = ORBEON.util.Dom.getChildElementByIndex(autoComplete, 1); // Get list of possible values from the select var values = new Array(); for (var optionIndex = 1; optionIndex < select.options.length; optionIndex++) values.push(select.options[optionIndex].value); // Initialize auto-complete input var noFilter = ORBEON.util.Dom.hasClass(autoComplete, "xforms-select1-open-autocomplete-nofilter"); ORBEON.xforms.Globals.autoCompleteOpen[autoComplete.id] = actb(textfield, values, noFilter); },
|
}}}}}else{return false;}},deselectButton:function(F){var E=B.call(this,F);if(E){E.removeClass("yui-button-selected");E.removeClass("yui-button-"+E.get("value")+"-selected");E.removeClass("yui-button-hover");E._selected=false;}else{return false;}},deselectAllButtons:function(){var E=this._buttonList.length;for(var F=0;F<E;F++){this.deselectButton(this._buttonList[F]);}},disableAllButtons:function(){if(this.get("disabled")){return false;}var E=this._buttonList.length;for(var F=0;F<E;F++){this.disableButton(this._buttonList[F]);}},enableAllButtons:function(){if(this.get("disabled")){return false;}var E=this._buttonList.length;for(var F=0;F<E;F++){this.enableButton(this._buttonList[F]);}},resetAllButtons:function(I){if(!D.isObject(I)){I={};}if(this.get("disabled")){return false;}var E=this._buttonList.length;for(var F=0;F<E;F++){var H=this._buttonList[F];if(H){var G=H._configs.disabled._initialConfig.value;if(I[H.get("id")]){this.enableButton(H);this.selectButton(H);}else{if(G){this.disableButton(H);}else{this.enableButton(H);}this.deselectButton(H);}}}},destroyButton:function(I){var G=B.call(this,I);if(G){var H=G.get("id");G.destroy();var E=this._buttonList.length;for(var F=0;F<E;F++){if(this._buttonList[F]&&this._buttonList[F].get("id")==H){this._buttonList[F]=null;}}}else{return false;}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var E in this){if(D.hasOwnProperty(this,E)){this[E]=null;}}return true;},collapse:function(F){var E=C.getElementsByClassName("collapse","span",this._titlebar);if(F===false){C.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(E[0]){C.removeClass(E[0],"collapsed");}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this});}else{if(E[0]){C.addClass(E[0],"collapsed");}C.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this});}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons.";}});})();(function(){var C=YAHOO.util.Dom,A=YAHOO.util.Event,D=YAHOO.lang,B=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(H,M){var G={};if(D.isObject(H)&&(!H.tagName)&&!M){D.augmentObject(G,H);H=document.createElement("textarea");this.DOMReady=true;if(G.container){var K=C.get(G.container);K.appendChild(H);}else{document.body.appendChild(H);}}else{if(M){D.augmentObject(G,M);}}var I={element:null,attributes:G},F=null;if(D.isString(H)){F=H;}else{if(I.attributes.id){F=I.attributes.id;}else{this.DOMReady=true;F=C.generateId(H);}}I.element=H;var J=document.createElement("DIV");I.attributes.element_cont=new YAHOO.util.Element(J,{id:F+"_container"});var E=document.createElement("div");C.addClass(E,"first-child");I.attributes.element_cont.appendChild(E);if(!I.attributes.toolbar_cont){I.attributes.toolbar_cont=document.createElement("DIV");I.attributes.toolbar_cont.id=F+"_toolbar";E.appendChild(I.attributes.toolbar_cont);}var L=document.createElement("DIV");E.appendChild(L);I.attributes.editor_wrapper=L;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,I.element,I.attributes);};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false;}if(this.get("resize")){var E={};D.augmentObject(E,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),E);this.resize.on("resize",function(G){var K=this.get("animate");this.set("animate",false);this.set("width",G.width+"px");var H=G.height,I=(this.toolbar.get("element").clientHeight+2),J=0;if(this.dompath){J=(this.dompath.clientHeight+1);}var F=(H-I-J);this.set("height",F+"px");this.get("element_cont").setStyle("height","");this.set("animate",K);},this,true);}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false;}if(this.get("drag")){var F=this.get("drag"),E=YAHOO.util.DD;if(F==="proxy"){E=YAHOO.util.DDProxy;}this.dd=new E(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar);}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(E,H){var F=false;if((H.keyCode===E.key)){if(E.mods&&(E.mods.length>0)){var I=0;for(var G=0;G<E.mods.length;G++){if(this.browser.mac){if(E.mods[G]=="ctrl"){E.mods[G]="meta";}}if(H[E.mods[G]+"Key"]===true){I++;}}if(I===E.mods.length){F=true;}}else{F=true;}}return F;},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(E){return E.replace(/ /g,"-").toLowerCase();},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-/'+"/W3C/"+"/DTD HTML 4.01/"+'/EN" "http:/'+'/www.w3.org/TR/html4/strict.dtd">',editorDirty:null,_defaultCSS:"html { height: 95%; } body { padding: 7px; background-color: #fff; font:13px/1.22 arial,helvetica,clean,sans-serif;*font-size:small;*font:x-small; } a, a:visited, a:hover { color: blue !important; text-decoration: underline !important; cursor: text !important; } .warning-localfile { border-bottom: 1px dashed red !important; } .yui-busy { cursor: wait !important; } img.selected { border: 2px dotted #808080; } img { cursor: pointer !important; border: none; } body.ptags.webkit div { margin: 11px 0; }",_defaultToolbar:null,_lastButton:null,_baseHREF:function(){var E=document.location.href;if(E.indexOf("?")!==-1){E=E.substring(0,E.indexOf("?"));}E=E.substring(0,E.lastIndexOf("/"))+"/";return E; }(),_lastImage:null,_blankImageLoaded:null,_fixNodesTimer:null,_nodeChangeTimer:null,_lastNodeChangeEvent:null,_lastNodeChange:0,_rendered:null,DOMReady:null,_selection:null,_mask:null,_showingHiddenElements:null,currentWindow:null,currentEvent:null,operaEvent:null,currentFont:null,currentElement:null,dompath:null,beforeElement:null,afterElement:null,invalidHTML:{form:true,input:true,button:true,select:true,link:true,html:true,body:true,iframe:true,script:true,style:true,textarea:true},toolbar:null,_contentTimer:null,_contentTimerCounter:0,_disabled:["createlink","fontname","fontsize","forecolor","backcolor"],_alwaysDisabled:{undo:true,redo:true},_alwaysEnabled:{},_semantic:{"bold":true,"italic":true,"underline":true},_tag2cmd:{"b":"bold","strong":"bold","i":"italic","em":"italic","u":"underline","sup":"superscript","sub":"subscript","img":"insertimage","a":"createlink","ul":"insertunorderedlist","ol":"insertorderedlist"},_createIframe:function(){var I=document.createElement("iframe");I.id=this.get("id")+"_editor";var G={border:"0",frameBorder:"0",marginWidth:"0",marginHeight:"0",leftMargin:"0",topMargin:"0",allowTransparency:"true",width:"100%"};if(this.get("autoHeight")){G.scrolling="no";}for(var H in G){if(D.hasOwnProperty(G,H)){I.setAttribute(H,G[H]);}}var F="javascript:;";if(this.browser.ie){F="javascript:false;";}I.setAttribute("src",F);var E=new YAHOO.util.Element(I);E.setStyle("visibility","hidden");return E;},_isElement:function(F,E){if(F&&F.tagName&&(F.tagName.toLowerCase()==E)){return true;}if(F&&F.getAttribute&&(F.getAttribute("tag")==E)){return true;}return false;},_hasParent:function(F,E){if(!F||!F.parentNode){return false;}while(F.parentNode){if(this._isElement(F,E)){return F;}if(F.parentNode){F=F.parentNode;}else{return false;}}return false;},_getDoc:function(){var E=false;if(this.get){if(this.get("iframe")){if(this.get("iframe").get){if(this.get("iframe").get("element")){try{if(this.get("iframe").get("element").contentWindow){if(this.get("iframe").get("element").contentWindow.document){E=this.get("iframe").get("element").contentWindow.document;return E;}}}catch(F){}}}}}return false;},_getWindow:function(){return this.get("iframe").get("element").contentWindow;},_focusWindow:function(E){if(this.browser.webkit){if(E){this._getSelection().setBaseAndExtent(this._getDoc().body.firstChild,0,this._getDoc().body.firstChild,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}else{this._getSelection().setBaseAndExtent(this._getDoc().body,1,this._getDoc().body,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}this._getWindow().focus();}else{this._getWindow().focus();}},_hasSelection:function(){var G=this._getSelection();var E=this._getRange();var F=false;if(!G||!E){return F;}if(this.browser.ie||this.browser.opera){if(E.text){F=true;}if(E.html){F=true;}}else{if(this.browser.webkit){if(G+""!==""){F=true;}}else{if(G&&(G.toString()!=="")&&(G!==undefined)){F=true;}}}return F;},_getSelection:function(){var E=null;if(this._getDoc()&&this._getWindow()){if(this._getDoc().selection){E=this._getDoc().selection;}else{E=this._getWindow().getSelection();}if(this.browser.webkit){if(E.baseNode){this._selection={};this._selection.baseNode=E.baseNode;this._selection.baseOffset=E.baseOffset;this._selection.extentNode=E.extentNode;this._selection.extentOffset=E.extentOffset;}else{if(this._selection!==null){E=this._getWindow().getSelection();E.setBaseAndExtent(this._selection.baseNode,this._selection.baseOffset,this._selection.extentNode,this._selection.extentOffset);this._selection=null;}}}}return E;},_selectNode:function(F,I){if(!F){return false;}var G=this._getSelection(),E=null;if(this.browser.ie){try{E=this._getDoc().body.createTextRange();E.moveToElementText(F);E.select();}catch(H){}}else{if(this.browser.webkit){if(I){G.setBaseAndExtent(F,1,F,F.innerText.length);}else{G.setBaseAndExtent(F,0,F,F.innerText.length);}}else{if(this.browser.opera){G=this._getWindow().getSelection();E=this._getDoc().createRange();E.selectNode(F);G.removeAllRanges();G.addRange(E);}else{E=this._getDoc().createRange();E.selectNodeContents(F);G.removeAllRanges();G.addRange(E);}}}this.nodeChange();},_getRange:function(){var E=this._getSelection();if(E===null){return null;}if(this.browser.webkit&&!E.getRangeAt){var H=this._getDoc().createRange();try{H.setStart(E.anchorNode,E.anchorOffset);H.setEnd(E.focusNode,E.focusOffset);}catch(G){H=this._getWindow().getSelection()+"";}return H;}if(this.browser.ie||this.browser.opera){try{return E.createRange();}catch(F){return null;}}if(E.rangeCount>0){return E.getRangeAt(0);}return null;},_setDesignMode:function(E){try{var G=true;if(this.browser.ie&&(E.toLowerCase()=="off")){G=false;}if(G){this._getDoc().designMode=E;}}catch(F){}},_toggleDesignMode:function(){var F=this._getDoc().designMode.toLowerCase(),E="on";if(F=="on"){E="off";}this._setDesignMode(E);return E;},_initEditorEvents:function(){var E=this._getDoc();A.on(E,"mouseup",this._handleMouseUp,this,true);A.on(E,"mousedown",this._handleMouseDown,this,true);A.on(E,"click",this._handleClick,this,true);A.on(E,"dblclick",this._handleDoubleClick,this,true);A.on(E,"keypress",this._handleKeyPress,this,true);A.on(E,"keyup",this._handleKeyUp,this,true);A.on(E,"keydown",this._handleKeyDown,this,true);},_removeEditorEvents:function(){var E=this._getDoc();A.removeListener(E,"mouseup",this._handleMouseUp,this,true);A.removeListener(E,"mousedown",this._handleMouseDown,this,true);A.removeListener(E,"click",this._handleClick,this,true);A.removeListener(E,"dblclick",this._handleDoubleClick,this,true);A.removeListener(E,"keypress",this._handleKeyPress,this,true);A.removeListener(E,"keyup",this._handleKeyUp,this,true);A.removeListener(E,"keydown",this._handleKeyDown,this,true);},_initEditor:function(){if(this.browser.ie){this._getDoc().body.style.margin="0";}if(!this.get("disabled")){if(this._getDoc().designMode.toLowerCase()!="on"){this._setDesignMode("on");
|
(function(){var b=YAHOO.util.Dom,a=YAHOO.util.Event,c=YAHOO.lang;if(YAHOO.widget.Button){YAHOO.widget.ToolbarButtonAdvanced=YAHOO.widget.Button;YAHOO.widget.ToolbarButtonAdvanced.prototype.buttonType="rich";YAHOO.widget.ToolbarButtonAdvanced.prototype.checkValue=function(f){var e=this.getMenu().getItems();if(e.length===0){this.getMenu()._onBeforeShow();e=this.getMenu().getItems()}for(var d=0;d<e.length;d++){e[d].cfg.setProperty("checked",false);if(e[d].value==f){e[d].cfg.setProperty("checked",true)}}}}else{YAHOO.widget.ToolbarButtonAdvanced=function(){}}YAHOO.widget.ToolbarButton=function(e,d){if(c.isObject(arguments[0])&&!b.get(e).nodeType){d=e}var g=(d||{});var f={element:null,attributes:g};if(!f.attributes.type){f.attributes.type="push"}f.element=document.createElement("span");f.element.setAttribute("unselectable","on");f.element.className="yui-button yui-"+f.attributes.type+"-button";f.element.innerHTML='<span class="first-child"><a href="#">LABEL</a></span>';f.element.firstChild.firstChild.tabIndex="-1";f.attributes.id=b.generateId();YAHOO.widget.ToolbarButton.superclass.constructor.call(this,f.element,f.attributes)};YAHOO.extend(YAHOO.widget.ToolbarButton,YAHOO.util.Element,{buttonType:"normal",_handleMouseOver:function(){if(!this.get("disabled")){this.addClass("yui-button-hover");this.addClass("yui-"+this.get("type")+"-button-hover")}},_handleMouseOut:function(){this.removeClass("yui-button-hover");this.removeClass("yui-"+this.get("type")+"-button-hover")},checkValue:function(f){if(this.get("type")=="menu"){var e=this._button.options;for(var d=0;d<e.length;d++){if(e[d].value==f){e.selectedIndex=d}}}},init:function(e,d){YAHOO.widget.ToolbarButton.superclass.init.call(this,e,d);this.on("mouseover",this._handleMouseOver,this,true);this.on("mouseout",this._handleMouseOut,this,true)},initAttributes:function(d){YAHOO.widget.ToolbarButton.superclass.initAttributes.call(this,d);this.setAttributeConfig("value",{value:d.value});this.setAttributeConfig("menu",{value:d.menu||false});this.setAttributeConfig("type",{value:d.type,writeOnce:true,method:function(h){var g,f;if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}switch(h){case"select":case"menu":g=document.createElement("select");var j=this.get("menu");for(var e=0;e<j.length;e++){f=document.createElement("option");f.innerHTML=j[e].text;f.value=j[e].value;if(j[e].checked){f.selected=true}g.appendChild(f)}this._button.parentNode.replaceChild(g,this._button);a.on(g,"change",this._handleSelect,this,true);this._button=g;break}}});this.setAttributeConfig("disabled",{value:d.disabled||false,method:function(e){if(e){this.addClass("yui-button-disabled");this.addClass("yui-"+this.get("type")+"-button-disabled")}else{this.removeClass("yui-button-disabled");this.removeClass("yui-"+this.get("type")+"-button-disabled")}if(this.get("type")=="menu"){this._button.disabled=e}}});this.setAttributeConfig("label",{value:d.label,method:function(e){if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}if(this.get("type")=="push"){this._button.innerHTML=e}}});this.setAttributeConfig("title",{value:d.title});this.setAttributeConfig("container",{value:null,writeOnce:true,method:function(e){this.appendTo(e)}})},_handleSelect:function(e){var d=a.getTarget(e);var f=d.options[d.selectedIndex].value;this.fireEvent("change",{type:"change",value:f})},getMenu:function(){return this.get("menu")},destroy:function(){a.purgeElement(this.get("element"),true);this.get("element").parentNode.removeChild(this.get("element"));for(var d in this){if(c.hasOwnProperty(this,d)){this[d]=null}}},fireEvent:function(e,d){if(this.DOM_EVENTS[e]&&this.get("disabled")){return}YAHOO.widget.ToolbarButton.superclass.fireEvent.call(this,e,d)},toString:function(){return"ToolbarButton ("+this.get("id")+")"}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang;var b=function(f){var e=f;if(d.isString(f)){e=this.getButtonById(f)}if(d.isNumber(f)){e=this.getButtonByIndex(f)}if((!(e instanceof YAHOO.widget.ToolbarButton))&&(!(e instanceof YAHOO.widget.ToolbarButtonAdvanced))){e=this.getButtonByValue(f)}if((e instanceof YAHOO.widget.ToolbarButton)||(e instanceof YAHOO.widget.ToolbarButtonAdvanced)){return e}return false};YAHOO.widget.Toolbar=function(i,h){if(d.isObject(arguments[0])&&!c.get(i).nodeType){h=i}var k={};if(h){d.augmentObject(k,h)}var j={element:null,attributes:k};if(d.isString(i)&&c.get(i)){j.element=c.get(i)}else{if(d.isObject(i)&&c.get(i)&&c.get(i).nodeType){j.element=c.get(i)}}if(!j.element){j.element=document.createElement("DIV");j.element.id=c.generateId();if(k.container&&c.get(k.container)){c.get(k.container).appendChild(j.element)}}if(!j.element.id){j.element.id=((d.isString(i))?i:c.generateId())}var f=document.createElement("fieldset");var g=document.createElement("legend");g.innerHTML="Toolbar";f.appendChild(g);var e=document.createElement("DIV");j.attributes.cont=e;c.addClass(e,"yui-toolbar-subcont");f.appendChild(e);j.element.appendChild(f);j.element.tabIndex=-1;j.attributes.element=j.element;j.attributes.id=j.element.id;YAHOO.widget.Toolbar.superclass.constructor.call(this,j.element,j.attributes)};YAHOO.extend(YAHOO.widget.Toolbar,YAHOO.util.Element,{_addMenuClasses:function(h,e,j){c.addClass(this.element,"yui-toolbar-"+j.get("value")+"-menu");if(c.hasClass(j._button.parentNode.parentNode,"yui-toolbar-select")){c.addClass(this.element,"yui-toolbar-select-menu")}var f=this.getItems();for(var g=0;g<f.length;g++){c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-").toLowerCase():f[g]._oText.nodeValue.replace(/ /g,"-").toLowerCase()));c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-"):f[g]._oText.nodeValue.replace(/ /g,"-")))}},buttonType:YAHOO.widget.ToolbarButton,dd:null,_colorData:{"#111111":"Obsidian","#2D2D2D":"Dark Gray","#434343":"Shale","#5B5B5B":"Flint","#737373":"Gray","#8B8B8B":"Concrete","#A2A2A2":"Gray","#B9B9B9":"Titanium","#000000":"Black","#D0D0D0":"Light Gray","#E6E6E6":"Silver","#FFFFFF":"White","#BFBF00":"Pumpkin","#FFFF00":"Yellow","#FFFF40":"Banana","#FFFF80":"Pale Yellow","#FFFFBF":"Butter","#525330":"Raw Siena","#898A49":"Mildew","#AEA945":"Olive","#7F7F00":"Paprika","#C3BE71":"Earth","#E0DCAA":"Khaki","#FCFAE1":"Cream","#60BF00":"Cactus","#80FF00":"Chartreuse","#A0FF40":"Green","#C0FF80":"Pale Lime","#DFFFBF":"Light Mint","#3B5738":"Green","#668F5A":"Lime Gray","#7F9757":"Yellow","#407F00":"Clover","#8A9B55":"Pistachio","#B7C296":"Light Jade","#E6EBD5":"Breakwater","#00BF00":"Spring Frost","#00FF80":"Pastel Green","#40FFA0":"Light Emerald","#80FFC0":"Sea Foam","#BFFFDF":"Sea Mist","#033D21":"Dark Forrest","#438059":"Moss","#7FA37C":"Medium Green","#007F40":"Pine","#8DAE94":"Yellow Gray Green","#ACC6B5":"Aqua Lung","#DDEBE2":"Sea Vapor","#00BFBF":"Fog","#00FFFF":"Cyan","#40FFFF":"Turquoise Blue","#80FFFF":"Light Aqua","#BFFFFF":"Pale Cyan","#033D3D":"Dark Teal","#347D7E":"Gray Turquoise","#609A9F":"Green Blue","#007F7F":"Seaweed","#96BDC4":"Green Gray","#B5D1D7":"Soapstone","#E2F1F4":"Light Turquoise","#0060BF":"Summer Sky","#0080FF":"Sky Blue","#40A0FF":"Electric Blue","#80C0FF":"Light Azure","#BFDFFF":"Ice Blue","#1B2C48":"Navy","#385376":"Biscay","#57708F":"Dusty Blue","#00407F":"Sea Blue","#7792AC":"Sky Blue Gray","#A8BED1":"Morning Sky","#DEEBF6":"Vapor","#0000BF":"Deep Blue","#0000FF":"Blue","#4040FF":"Cerulean Blue","#8080FF":"Evening Blue","#BFBFFF":"Light Blue","#212143":"Deep Indigo","#373E68":"Sea Blue","#444F75":"Night Blue","#00007F":"Indigo Blue","#585E82":"Dockside","#8687A4":"Blue Gray","#D2D1E1":"Light Blue Gray","#6000BF":"Neon Violet","#8000FF":"Blue Violet","#A040FF":"Violet Purple","#C080FF":"Violet Dusk","#DFBFFF":"Pale Lavender","#302449":"Cool Shale","#54466F":"Dark Indigo","#655A7F":"Dark Violet","#40007F":"Violet","#726284":"Smoky Violet","#9E8FA9":"Slate Gray","#DCD1DF":"Violet White","#BF00BF":"Royal Violet","#FF00FF":"Fuchsia","#FF40FF":"Magenta","#FF80FF":"Orchid","#FFBFFF":"Pale Magenta","#4A234A":"Dark Purple","#794A72":"Medium Purple","#936386":"Cool Granite","#7F007F":"Purple","#9D7292":"Purple Moon","#C0A0B6":"Pale Purple","#ECDAE5":"Pink Cloud","#BF005F":"Hot Pink","#FF007F":"Deep Pink","#FF409F":"Grape","#FF80BF":"Electric Pink","#FFBFDF":"Pink","#451528":"Purple Red","#823857":"Purple Dino","#A94A76":"Purple Gray","#7F003F":"Rose","#BC6F95":"Antique Mauve","#D8A5BB":"Cool Marble","#F7DDE9":"Pink Granite","#C00000":"Apple","#FF0000":"Fire Truck","#FF4040":"Pale Red","#FF8080":"Salmon","#FFC0C0":"Warm Pink","#441415":"Sepia","#82393C":"Rust","#AA4D4E":"Brick","#800000":"Brick Red","#BC6E6E":"Mauve","#D8A3A4":"Shrimp Pink","#F8DDDD":"Shell Pink","#BF5F00":"Dark Orange","#FF7F00":"Orange","#FF9F40":"Grapefruit","#FFBF80":"Canteloupe","#FFDFBF":"Wax","#482C1B":"Dark Brick","#855A40":"Dirt","#B27C51":"Tan","#7F3F00":"Nutmeg","#C49B71":"Mustard","#E1C4A8":"Pale Tan","#FDEEE0":"Marble"},_colorPicker:null,STR_COLLAPSE:"Collapse Toolbar",STR_SPIN_LABEL:"Spin Button with value {VALUE}. Use Control Shift Up Arrow and Control Shift Down arrow keys to increase or decrease the value.",STR_SPIN_UP:"Click to increase the value of this input",STR_SPIN_DOWN:"Click to decrease the value of this input",_titlebar:null,browser:YAHOO.env.ua,_buttonList:null,_buttonGroupList:null,_sep:null,_sepCount:null,_dragHandle:null,_toolbarConfigs:{renderer:true},CLASS_CONTAINER:"yui-toolbar-container",CLASS_DRAGHANDLE:"yui-toolbar-draghandle",CLASS_SEPARATOR:"yui-toolbar-separator",CLASS_DISABLED:"yui-toolbar-disabled",CLASS_PREFIX:"yui-toolbar",init:function(f,e){YAHOO.widget.Toolbar.superclass.init.call(this,f,e)},initAttributes:function(e){YAHOO.widget.Toolbar.superclass.initAttributes.call(this,e);this.addClass(this.CLASS_CONTAINER);this.setAttributeConfig("buttonType",{value:e.buttonType||"basic",writeOnce:true,validator:function(f){switch(f){case"advanced":case"basic":return true}return false},method:function(f){if(f=="advanced"){if(YAHOO.widget.Button){this.buttonType=YAHOO.widget.ToolbarButtonAdvanced}else{this.buttonType=YAHOO.widget.ToolbarButton}}else{this.buttonType=YAHOO.widget.ToolbarButton}}});this.setAttributeConfig("buttons",{value:[],writeOnce:true,method:function(g){for(var f in g){if(d.hasOwnProperty(g,f)){if(g[f].type=="separator"){this.addSeparator()}else{if(g[f].group!==undefined){this.addButtonGroup(g[f])}else{this.addButton(g[f])}}}}}});this.setAttributeConfig("disabled",{value:false,method:function(f){if(this.get("disabled")===f){return false}if(f){this.addClass(this.CLASS_DISABLED);this.set("draggable",false);this.disableAllButtons()}else{this.removeClass(this.CLASS_DISABLED);if(this._configs.draggable._initialConfig.value){this.set("draggable",true)}this.resetAllButtons()}}});this.setAttributeConfig("cont",{value:e.cont,readOnly:true});this.setAttributeConfig("grouplabels",{value:((e.grouplabels===false)?false:true),method:function(f){if(f){c.removeClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}else{c.addClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}}});this.setAttributeConfig("titlebar",{value:false,method:function(g){if(g){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}this._titlebar=document.createElement("DIV");this._titlebar.tabIndex="-1";a.on(this._titlebar,"focus",function(){this._handleFocus()},this,true);c.addClass(this._titlebar,this.CLASS_PREFIX+"-titlebar");if(d.isString(g)){var f=document.createElement("h2");f.tabIndex="-1";f.innerHTML='<a href="#" tabIndex="0">'+g+"</a>";this._titlebar.appendChild(f);a.on(f.firstChild,"click",function(h){a.stopEvent(h)});a.on([f,f.firstChild],"focus",function(){this._handleFocus()},this,true)}if(this.get("firstChild")){this.insertBefore(this._titlebar,this.get("firstChild"))}else{this.appendChild(this._titlebar)}if(this.get("collapse")){this.set("collapse",true)}}else{if(this._titlebar){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}}}}});this.setAttributeConfig("collapse",{value:false,method:function(h){if(this._titlebar){var g=null;var f=c.getElementsByClassName("collapse","span",this._titlebar);if(h){if(f.length>0){return true}g=document.createElement("SPAN");g.innerHTML="X";g.title=this.STR_COLLAPSE;c.addClass(g,"collapse");this._titlebar.appendChild(g);a.addListener(g,"click",function(){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}else{this.collapse()}},this,true)}else{g=c.getElementsByClassName("collapse","span",this._titlebar);if(g[0]){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}g[0].parentNode.removeChild(g[0])}}}}});this.setAttributeConfig("draggable",{value:(e.draggable||false),method:function(f){if(f&&!this.get("titlebar")){if(!this._dragHandle){this._dragHandle=document.createElement("SPAN");this._dragHandle.innerHTML="|";this._dragHandle.setAttribute("title","Click to drag the toolbar");this._dragHandle.id=this.get("id")+"_draghandle";c.addClass(this._dragHandle,this.CLASS_DRAGHANDLE);if(this.get("cont").hasChildNodes()){this.get("cont").insertBefore(this._dragHandle,this.get("cont").firstChild)}else{this.get("cont").appendChild(this._dragHandle)}this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._dragHandle.id)}}else{if(this._dragHandle){this._dragHandle.parentNode.removeChild(this._dragHandle);this._dragHandle=null;this.dd=null}}if(this._titlebar){if(f){this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._titlebar);c.addClass(this._titlebar,"draggable")}else{c.removeClass(this._titlebar,"draggable");if(this.dd){this.dd.unreg();this.dd=null}}}},validator:function(g){var f=true;if(!YAHOO.util.DD){f=false}return f}})},addButtonGroup:function(j){if(!this.get("element")){this._queue[this._queue.length]=["addButtonGroup",arguments];return false}if(!this.hasClass(this.CLASS_PREFIX+"-grouped")){this.addClass(this.CLASS_PREFIX+"-grouped")}var k=document.createElement("DIV");c.addClass(k,this.CLASS_PREFIX+"-group");c.addClass(k,this.CLASS_PREFIX+"-group-"+j.group);if(j.label){var f=document.createElement("h3");f.innerHTML=j.label;k.appendChild(f)}if(!this.get("grouplabels")){c.addClass(this.get("cont"),this.CLASS_PREFIX,"-nogrouplabels")}this.get("cont").appendChild(k);var h=document.createElement("ul");k.appendChild(h);if(!this._buttonGroupList){this._buttonGroupList={}}this._buttonGroupList[j.group]=h;for(var g=0;g<j.buttons.length;g++){var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";h.appendChild(e);if((j.buttons[g].type!==undefined)&&j.buttons[g].type=="separator"){this.addSeparator(e)}else{j.buttons[g].container=e;this.addButton(j.buttons[g])}}},addButtonToGroup:function(g,h,i){var f=this._buttonGroupList[h];var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";g.container=e;this.addButton(g,i);f.appendChild(e)},addButton:function(k,j){if(!this.get("element")){this._queue[this._queue.length]=["addButton",arguments];return false}if(!this._buttonList){this._buttonList=[]}if(!k.container){k.container=this.get("cont")}if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){for(var s in k.menu){if(d.hasOwnProperty(k.menu,s)){var y={fn:function(o,i,m){if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue)},scope:this};k.menu[s].onclick=y}}}}var t={},q=false;for(var n in k){if(d.hasOwnProperty(k,n)){if(!this._toolbarConfigs[n]){t[n]=k[n]}}}if(k.type=="select"){t.type="menu"}if(k.type=="spin"){t.type="push"}if(t.type=="color"){if(YAHOO.widget.Overlay){t=this._makeColorButton(t)}else{q=true}}if(t.menu){if((YAHOO.widget.Overlay)&&(k.menu instanceof YAHOO.widget.Overlay)){k.menu.showEvent.subscribe(function(){this._button=t})}else{for(var r=0;r<t.menu.length;r++){if(!t.menu[r].value){t.menu[r].value=t.menu[r].text}}if(this.browser.webkit){t.focusmenu=false}}}if(q){k=false}else{this._configs.buttons.value[this._configs.buttons.value.length]=k;var w=new this.buttonType(t);w.get("element").tabIndex="-1";w.get("element").setAttribute("role","button");w._selected=true;if(this.get("disabled")){w.set("disabled",true)}if(!k.id){k.id=w.get("id")}if(j){var f=w.get("element");var p=null;if(j.get){p=j.get("element").nextSibling}else{if(j.nextSibling){p=j.nextSibling}}if(p){p.parentNode.insertBefore(f,p)}}w.addClass(this.CLASS_PREFIX+"-"+w.get("value"));var v=document.createElement("span");v.className=this.CLASS_PREFIX+"-icon";w.get("element").insertBefore(v,w.get("firstChild"));if(w._button.tagName.toLowerCase()=="button"){w.get("element").setAttribute("unselectable","on");var x=document.createElement("a");x.innerHTML=w._button.innerHTML;x.href="#";x.tabIndex="-1";a.on(x,"click",function(i){a.stopEvent(i)});w._button.parentNode.replaceChild(x,w._button);w._button=x}if(k.type=="select"){if(w._button.tagName.toLowerCase()=="select"){v.parentNode.removeChild(v);var g=w._button;var u=w.get("element");u.parentNode.replaceChild(g,u)}else{w.addClass(this.CLASS_PREFIX+"-select")}}if(k.type=="spin"){if(!d.isArray(k.range)){k.range=[10,100]}this._makeSpinButton(w,k)}w.get("element").setAttribute("title",w.get("label"));if(k.type!="spin"){if((YAHOO.widget.Overlay)&&(t.menu instanceof YAHOO.widget.Overlay)){var h=function(o){var i=true;if(o.keyCode&&(o.keyCode==9)){i=false}if(i){if(this._colorPicker){this._colorPicker._button=k.value}var m=w.getMenu().element;if(c.getStyle(m,"visibility")=="hidden"){w.getMenu().show()}else{w.getMenu().hide()}}YAHOO.util.Event.stopEvent(o)};w.on("mousedown",h,k,this);w.on("keydown",h,k,this)}else{if((k.type!="menu")&&(k.type!="select")){w.on("keypress",this._buttonClick,k,this);w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i);this._buttonClick(i,k)},k,this);w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)});w.on("change",function(i){if(!k.menucmd){k.menucmd=k.value}k.value=i.value;this._buttonClick(i,k)},this,true);var l=this;w.on("appendTo",function(){var i=this;if(i.getMenu()&&i.getMenu().mouseDownEvent){i.getMenu().mouseDownEvent.subscribe(function(z,o){var m=o[1];YAHOO.util.Event.stopEvent(o[0]);i._onMenuClick(o[0],i);if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue);l._buttonClick.call(l,o[1],k);i._hideMenu();return false});i.getMenu().clickEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])});i.getMenu().mouseUpEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])})}})}}}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}if(this.browser.ie){}if(this.browser.webkit){w.hasFocus=function(){return true}}this._buttonList[this._buttonList.length]=w;if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){var e=w.getMenu();if(e&&e.renderEvent){e.renderEvent.subscribe(this._addMenuClasses,w);if(k.renderer){e.renderEvent.subscribe(k.renderer,w)}}}}}return k},addSeparator:function(e,h){if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}var f=((e)?e:this.get("cont"));if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}if(this._sepCount===null){this._sepCount=0}if(!this._sep){this._sep=document.createElement("SPAN");c.addClass(this._sep,this.CLASS_SEPARATOR);this._sep.innerHTML="|"}var g=this._sep.cloneNode(true);this._sepCount++;c.addClass(g,this.CLASS_SEPARATOR+"-"+this._sepCount);if(h){var i=null;if(h.get){i=h.get("element").nextSibling}else{if(h.nextSibling){i=h.nextSibling}else{i=h}}if(i){if(i==h){i.parentNode.appendChild(g)}else{i.parentNode.insertBefore(g,i)}}}else{f.appendChild(g)}return g},_createColorPicker:function(h){if(c.get(h+"_colors")){c.get(h+"_colors").parentNode.removeChild(c.get(h+"_colors"))}var e=document.createElement("div");e.className="yui-toolbar-colors";e.id=h+"_colors";e.style.display="none";a.on(window,"load",function(){document.body.appendChild(e)},this,true);this._colorPicker=e;var g="";for(var f in this._colorData){if(d.hasOwnProperty(this._colorData,f)){g+='<a style="background-color: '+f+'" href="#">'+f.replace("#","")+"</a>"}}g+="<span><em>X</em><strong></strong></span>";window.setTimeout(function(){e.innerHTML=g},0);a.on(e,"mouseover",function(m){var k=this._colorPicker;var l=k.getElementsByTagName("em")[0];var j=k.getElementsByTagName("strong")[0];var i=a.getTarget(m);if(i.tagName.toLowerCase()=="a"){l.style.backgroundColor=i.style.backgroundColor;j.innerHTML=this._colorData["#"+i.innerHTML]+"<br>"+i.innerHTML}},this,true);a.on(e,"focus",function(i){a.stopEvent(i)});a.on(e,"click",function(i){a.stopEvent(i)});a.on(e,"mousedown",function(j){a.stopEvent(j);var i=a.getTarget(j);if(i.tagName.toLowerCase()=="a"){var l=this.fireEvent("colorPickerClicked",{type:"colorPickerClicked",target:this,button:this._colorPicker._button,color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML]});if(l!==false){var k={color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML],value:this._colorPicker._button};this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:k})}this.getButtonByValue(this._colorPicker._button).getMenu().hide()}},this,true)},_resetColorPicker:function(){var f=this._colorPicker.getElementsByTagName("em")[0];var e=this._colorPicker.getElementsByTagName("strong")[0];f.style.backgroundColor="transparent";e.innerHTML=""},_makeColorButton:function(e){if(!this._colorPicker){this._createColorPicker(this.get("id"))}e.type="color";e.menu=new YAHOO.widget.Overlay(this.get("id")+"_"+e.value+"_menu",{visible:false,position:"absolute",iframe:true});e.menu.setBody("");e.menu.render(this.get("cont"));c.addClass(e.menu.element,"yui-button-menu");c.addClass(e.menu.element,"yui-color-button-menu");e.menu.beforeShowEvent.subscribe(function(){e.menu.cfg.setProperty("zindex",5);e.menu.cfg.setProperty("context",[this.getButtonById(e.id).get("element"),"tl","bl"]);this._resetColorPicker();var f=this._colorPicker;if(f.parentNode){f.parentNode.removeChild(f)}e.menu.setBody("");e.menu.appendToBody(f);this._colorPicker.style.display="block"},this,true);return e},_makeSpinButton:function(r,l){r.addClass(this.CLASS_PREFIX+"-spinbutton");var s=this,n=r._button.parentNode.parentNode,i=l.range,h=document.createElement("a"),g=document.createElement("a");h.href="#";g.href="#";h.tabIndex="-1";g.tabIndex="-1";h.className="up";h.title=this.STR_SPIN_UP;h.innerHTML=this.STR_SPIN_UP;g.className="down";g.title=this.STR_SPIN_DOWN;g.innerHTML=this.STR_SPIN_DOWN;n.appendChild(h);n.appendChild(g);var m=YAHOO.lang.substitute(this.STR_SPIN_LABEL,{VALUE:r.get("label")});r.set("title",m);var q=function(t){t=((t<i[0])?i[0]:t);t=((t>i[1])?i[1]:t);return t};var p=this.browser;var f=false;var k=this.STR_SPIN_LABEL;if(this._titlebar&&this._titlebar.firstChild){f=this._titlebar.firstChild}var e=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v++;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var o=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v--;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var j=function(t){if(t.keyCode==38){e(t)}else{if(t.keyCode==40){o(t)}else{if(t.keyCode==107&&t.shiftKey){e(t)}else{if(t.keyCode==109&&t.shiftKey){o(t)}}}}};r.on("keydown",j,this,true);a.on(h,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(g,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(h,"click",e,this,true);a.on(g,"click",o,this,true)},_buttonClick:function(n,f){var e=true;if(n&&n.type=="keypress"){if(n.keyCode==9){e=false}else{if((n.keyCode===13)||(n.keyCode===0)||(n.keyCode===32)){}else{e=false}}}if(e){var p=true,h=false;f.isSelected=this.isSelected(f.id);if(f.value){h=this.fireEvent(f.value+"Click",{type:f.value+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(f.menucmd&&p){h=this.fireEvent(f.menucmd+"Click",{type:f.menucmd+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(p){this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:f})}if(f.type=="select"){var l=this.getButtonById(f.id);if(l.buttonType=="rich"){var k=f.value;for(var j=0;j<f.menu.length;j++){if(f.menu[j].value==f.value){k=f.menu[j].text;break}}l.set("label",'<span class="yui-toolbar-'+f.menucmd+"-"+(f.value).replace(/ /g,"-").toLowerCase()+'">'+k+"</span>");var o=l.getMenu().getItems();for(var g=0;g<o.length;g++){if(o[g].value.toLowerCase()==f.value.toLowerCase()){o[g].cfg.setProperty("checked",true)}else{o[g].cfg.setProperty("checked",false)}}}}if(n){a.stopEvent(n)}}},_keyNav:null,_navCounter:null,_navigateButtons:function(f){switch(f.keyCode){case 37:case 39:if(f.keyCode==37){this._navCounter--}else{this._navCounter++}if(this._navCounter>(this._buttonList.length-1)){this._navCounter=0}if(this._navCounter<0){this._navCounter=(this._buttonList.length-1)}if(this._buttonList[this._navCounter]){var e=this._buttonList[this._navCounter].get("element");if(this.browser.ie){e=this._buttonList[this._navCounter].get("element").getElementsByTagName("a")[0]}if(this._buttonList[this._navCounter].get("disabled")){this._navigateButtons(f)}else{e.focus()}}break}},_handleFocus:function(){if(!this._keyNav){var e="keypress";if(this.browser.ie){e="keydown"}a.on(this.get("element"),e,this._navigateButtons,this,true);this._keyNav=true;this._navCounter=-1}},getButtonById:function(g){var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==g){return this._buttonList[f]}}return false},getButtonByValue:function(n){var h=this.get("buttons");var f=h.length;for(var k=0;k<f;k++){if(h[k].group!==undefined){for(var e=0;e<h[k].buttons.length;e++){if((h[k].buttons[e].value==n)||(h[k].buttons[e].menucmd==n)){return this.getButtonById(h[k].buttons[e].id)}if(h[k].buttons[e].menu){for(var l=0;l<h[k].buttons[e].menu.length;l++){if(h[k].buttons[e].menu[l].value==n){return this.getButtonById(h[k].buttons[e].id)}}}}}else{if((h[k].value==n)||(h[k].menucmd==n)){return this.getButtonById(h[k].id)}if(h[k].menu){for(var g=0;g<h[k].menu.length;g++){if(h[k].menu[g].value==n){return this.getButtonById(h[k].id)}}}}}return false},getButtonByIndex:function(e){if(this._buttonList[e]){return this._buttonList[e]}else{return false}},getButtons:function(){return this._buttonList},disableButton:function(f){var e=b.call(this,f);if(e){e.set("disabled",true)}else{return false}},enableButton:function(f){if(this.get("disabled")){return false}var e=b.call(this,f);if(e){if(e.get("disabled")){e.set("disabled",false)}}else{return false}},isSelected:function(f){var e=b.call(this,f);if(e){return e._selected}return false},selectButton:function(i,g){var f=b.call(this,i);if(f){f.addClass("yui-button-selected");f.addClass("yui-button-"+f.get("value")+"-selected");f._selected=true;if(g){if(f.buttonType=="rich"){var h=f.getMenu().getItems();for(var e=0;e<h.length;e++){if(h[e].value==g){h[e].cfg.setProperty("checked",true);f.set("label",'<span class="yui-toolbar-'+f.get("value")+"-"+(g).replace(/ /g,"-").toLowerCase()+'">'+h[e]._oText.nodeValue+"</span>")}else{h[e].cfg.setProperty("checked",false)}}}}}else{return false}},deselectButton:function(f){var e=b.call(this,f);if(e){e.removeClass("yui-button-selected");e.removeClass("yui-button-"+e.get("value")+"-selected");e.removeClass("yui-button-hover");e._selected=false}else{return false}},deselectAllButtons:function(){var e=this._buttonList.length;for(var f=0;f<e;f++){this.deselectButton(this._buttonList[f])}},disableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.disableButton(this._buttonList[f])}},enableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.enableButton(this._buttonList[f])}},resetAllButtons:function(j){if(!d.isObject(j)){j={}}if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){var h=this._buttonList[f];if(h){var g=h._configs.disabled._initialConfig.value;if(j[h.get("id")]){this.enableButton(h);this.selectButton(h)}else{if(g){this.disableButton(h)}else{this.enableButton(h)}this.deselectButton(h)}}}},destroyButton:function(j){var g=b.call(this,j);if(g){var h=g.get("id");g.destroy();var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==h){this._buttonList[f]=null}}}else{return false}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var e in this){if(d.hasOwnProperty(this,e)){this[e]=null}}return true},collapse:function(f){var e=c.getElementsByClassName("collapse","span",this._titlebar);if(f===false){c.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(e[0]){c.removeClass(e[0],"collapsed")}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this})}else{if(e[0]){c.addClass(e[0],"collapsed")}c.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this})}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons."}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang,b=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(h,m){var g={};if(d.isObject(h)&&(!h.tagName)&&!m){d.augmentObject(g,h);h=document.createElement("textarea");this.DOMReady=true;if(g.container){var k=c.get(g.container);k.appendChild(h)}else{document.body.appendChild(h)}}else{if(m){d.augmentObject(g,m)}}var i={element:null,attributes:g},f=null;if(d.isString(h)){f=h}else{if(i.attributes.id){f=i.attributes.id}else{this.DOMReady=true;f=c.generateId(h)}}i.element=h;var j=document.createElement("DIV");i.attributes.element_cont=new YAHOO.util.Element(j,{id:f+"_container"});var e=document.createElement("div");c.addClass(e,"first-child");i.attributes.element_cont.appendChild(e);if(!i.attributes.toolbar_cont){i.attributes.toolbar_cont=document.createElement("DIV");i.attributes.toolbar_cont.id=f+"_toolbar";e.appendChild(i.attributes.toolbar_cont)}var l=document.createElement("DIV");e.appendChild(l);i.attributes.editor_wrapper=l;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,i.element,i.attributes)};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false}if(this.get("resize")){var e={};d.augmentObject(e,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),e);this.resize.on("resize",function(g){var l=this.get("animate");this.set("animate",false);this.set("width",g.width+"px");var i=g.height,j=(this.toolbar.get("element").clientHeight+2),k=0;if(this.dompath){k=(this.dompath.clientHeight+1)}var f=(i-j-k);this.set("height",f+"px");this.get("element_cont").setStyle("height","");this.set("animate",l)},this,true)}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false}if(this.get("drag")){var f=this.get("drag"),e=YAHOO.util.DD;if(f==="proxy"){e=YAHOO.util.DDProxy}this.dd=new e(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar)}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(f,j){var g=false;if((j.keyCode===f.key)){if(f.mods&&(f.mods.length>0)){var l=0;for(var h=0;h<f.mods.length;h++){if(this.browser.mac){if(f.mods[h]=="ctrl"){f.mods[h]="meta"}}if(j[f.mods[h]+"Key"]===true){l++}}if(l===f.mods.length){g=true}}else{g=true}}return g},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(e){return e.replace(/ /g,"-").toLowerCase()},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-
|
}}}}}else{return false;}},deselectButton:function(F){var E=B.call(this,F);if(E){E.removeClass("yui-button-selected");E.removeClass("yui-button-"+E.get("value")+"-selected");E.removeClass("yui-button-hover");E._selected=false;}else{return false;}},deselectAllButtons:function(){var E=this._buttonList.length;for(var F=0;F<E;F++){this.deselectButton(this._buttonList[F]);}},disableAllButtons:function(){if(this.get("disabled")){return false;}var E=this._buttonList.length;for(var F=0;F<E;F++){this.disableButton(this._buttonList[F]);}},enableAllButtons:function(){if(this.get("disabled")){return false;}var E=this._buttonList.length;for(var F=0;F<E;F++){this.enableButton(this._buttonList[F]);}},resetAllButtons:function(I){if(!D.isObject(I)){I={};}if(this.get("disabled")){return false;}var E=this._buttonList.length;for(var F=0;F<E;F++){var H=this._buttonList[F];if(H){var G=H._configs.disabled._initialConfig.value;if(I[H.get("id")]){this.enableButton(H);this.selectButton(H);}else{if(G){this.disableButton(H);}else{this.enableButton(H);}this.deselectButton(H);}}}},destroyButton:function(I){var G=B.call(this,I);if(G){var H=G.get("id");G.destroy();var E=this._buttonList.length;for(var F=0;F<E;F++){if(this._buttonList[F]&&this._buttonList[F].get("id")==H){this._buttonList[F]=null;}}}else{return false;}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var E in this){if(D.hasOwnProperty(this,E)){this[E]=null;}}return true;},collapse:function(F){var E=C.getElementsByClassName("collapse","span",this._titlebar);if(F===false){C.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(E[0]){C.removeClass(E[0],"collapsed");}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this});}else{if(E[0]){C.addClass(E[0],"collapsed");}C.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this});}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons.";}});})();(function(){var C=YAHOO.util.Dom,A=YAHOO.util.Event,D=YAHOO.lang,B=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(H,M){var G={};if(D.isObject(H)&&(!H.tagName)&&!M){D.augmentObject(G,H);H=document.createElement("textarea");this.DOMReady=true;if(G.container){var K=C.get(G.container);K.appendChild(H);}else{document.body.appendChild(H);}}else{if(M){D.augmentObject(G,M);}}var I={element:null,attributes:G},F=null;if(D.isString(H)){F=H;}else{if(I.attributes.id){F=I.attributes.id;}else{this.DOMReady=true;F=C.generateId(H);}}I.element=H;var J=document.createElement("DIV");I.attributes.element_cont=new YAHOO.util.Element(J,{id:F+"_container"});var E=document.createElement("div");C.addClass(E,"first-child");I.attributes.element_cont.appendChild(E);if(!I.attributes.toolbar_cont){I.attributes.toolbar_cont=document.createElement("DIV");I.attributes.toolbar_cont.id=F+"_toolbar";E.appendChild(I.attributes.toolbar_cont);}var L=document.createElement("DIV");E.appendChild(L);I.attributes.editor_wrapper=L;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,I.element,I.attributes);};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false;}if(this.get("resize")){var E={};D.augmentObject(E,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),E);this.resize.on("resize",function(G){var K=this.get("animate");this.set("animate",false);this.set("width",G.width+"px");var H=G.height,I=(this.toolbar.get("element").clientHeight+2),J=0;if(this.dompath){J=(this.dompath.clientHeight+1);}var F=(H-I-J);this.set("height",F+"px");this.get("element_cont").setStyle("height","");this.set("animate",K);},this,true);}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false;}if(this.get("drag")){var F=this.get("drag"),E=YAHOO.util.DD;if(F==="proxy"){E=YAHOO.util.DDProxy;}this.dd=new E(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar);}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(E,H){var F=false;if((H.keyCode===E.key)){if(E.mods&&(E.mods.length>0)){var I=0;for(var G=0;G<E.mods.length;G++){if(this.browser.mac){if(E.mods[G]=="ctrl"){E.mods[G]="meta";}}if(H[E.mods[G]+"Key"]===true){I++;}}if(I===E.mods.length){F=true;}}else{F=true;}}return F;},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(E){return E.replace(/ /g,"-").toLowerCase();},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-/'+"/W3C/"+"/DTD HTML 4.01/"+'/EN" "http:/'+'/www.w3.org/TR/html4/strict.dtd">',editorDirty:null,_defaultCSS:"html { height: 95%; } body { padding: 7px; background-color: #fff; font:13px/1.22 arial,helvetica,clean,sans-serif;*font-size:small;*font:x-small; } a, a:visited, a:hover { color: blue !important; text-decoration: underline !important; cursor: text !important; } .warning-localfile { border-bottom: 1px dashed red !important; } .yui-busy { cursor: wait !important; } img.selected { border: 2px dotted #808080; } img { cursor: pointer !important; border: none; } body.ptags.webkit div { margin: 11px 0; }",_defaultToolbar:null,_lastButton:null,_baseHREF:function(){var E=document.location.href;if(E.indexOf("?")!==-1){E=E.substring(0,E.indexOf("?"));}E=E.substring(0,E.lastIndexOf("/"))+"/";return E;}(),_lastImage:null,_blankImageLoaded:null,_fixNodesTimer:null,_nodeChangeTimer:null,_lastNodeChangeEvent:null,_lastNodeChange:0,_rendered:null,DOMReady:null,_selection:null,_mask:null,_showingHiddenElements:null,currentWindow:null,currentEvent:null,operaEvent:null,currentFont:null,currentElement:null,dompath:null,beforeElement:null,afterElement:null,invalidHTML:{form:true,input:true,button:true,select:true,link:true,html:true,body:true,iframe:true,script:true,style:true,textarea:true},toolbar:null,_contentTimer:null,_contentTimerCounter:0,_disabled:["createlink","fontname","fontsize","forecolor","backcolor"],_alwaysDisabled:{undo:true,redo:true},_alwaysEnabled:{},_semantic:{"bold":true,"italic":true,"underline":true},_tag2cmd:{"b":"bold","strong":"bold","i":"italic","em":"italic","u":"underline","sup":"superscript","sub":"subscript","img":"insertimage","a":"createlink","ul":"insertunorderedlist","ol":"insertorderedlist"},_createIframe:function(){var I=document.createElement("iframe");I.id=this.get("id")+"_editor";var G={border:"0",frameBorder:"0",marginWidth:"0",marginHeight:"0",leftMargin:"0",topMargin:"0",allowTransparency:"true",width:"100%"};if(this.get("autoHeight")){G.scrolling="no";}for(var H in G){if(D.hasOwnProperty(G,H)){I.setAttribute(H,G[H]);}}var F="javascript:;";if(this.browser.ie){F="javascript:false;";}I.setAttribute("src",F);var E=new YAHOO.util.Element(I);E.setStyle("visibility","hidden");return E;},_isElement:function(F,E){if(F&&F.tagName&&(F.tagName.toLowerCase()==E)){return true;}if(F&&F.getAttribute&&(F.getAttribute("tag")==E)){return true;}return false;},_hasParent:function(F,E){if(!F||!F.parentNode){return false;}while(F.parentNode){if(this._isElement(F,E)){return F;}if(F.parentNode){F=F.parentNode;}else{return false;}}return false;},_getDoc:function(){var E=false;if(this.get){if(this.get("iframe")){if(this.get("iframe").get){if(this.get("iframe").get("element")){try{if(this.get("iframe").get("element").contentWindow){if(this.get("iframe").get("element").contentWindow.document){E=this.get("iframe").get("element").contentWindow.document;return E;}}}catch(F){}}}}}return false;},_getWindow:function(){return this.get("iframe").get("element").contentWindow;},_focusWindow:function(E){if(this.browser.webkit){if(E){this._getSelection().setBaseAndExtent(this._getDoc().body.firstChild,0,this._getDoc().body.firstChild,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}else{this._getSelection().setBaseAndExtent(this._getDoc().body,1,this._getDoc().body,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}this._getWindow().focus();}else{this._getWindow().focus();}},_hasSelection:function(){var G=this._getSelection();var E=this._getRange();var F=false;if(!G||!E){return F;}if(this.browser.ie||this.browser.opera){if(E.text){F=true;}if(E.html){F=true;}}else{if(this.browser.webkit){if(G+""!==""){F=true;}}else{if(G&&(G.toString()!=="")&&(G!==undefined)){F=true;}}}return F;},_getSelection:function(){var E=null;if(this._getDoc()&&this._getWindow()){if(this._getDoc().selection){E=this._getDoc().selection;}else{E=this._getWindow().getSelection();}if(this.browser.webkit){if(E.baseNode){this._selection={};this._selection.baseNode=E.baseNode;this._selection.baseOffset=E.baseOffset;this._selection.extentNode=E.extentNode;this._selection.extentOffset=E.extentOffset;}else{if(this._selection!==null){E=this._getWindow().getSelection();E.setBaseAndExtent(this._selection.baseNode,this._selection.baseOffset,this._selection.extentNode,this._selection.extentOffset);this._selection=null;}}}}return E;},_selectNode:function(F,I){if(!F){return false;}var G=this._getSelection(),E=null;if(this.browser.ie){try{E=this._getDoc().body.createTextRange();E.moveToElementText(F);E.select();}catch(H){}}else{if(this.browser.webkit){if(I){G.setBaseAndExtent(F,1,F,F.innerText.length);}else{G.setBaseAndExtent(F,0,F,F.innerText.length);}}else{if(this.browser.opera){G=this._getWindow().getSelection();E=this._getDoc().createRange();E.selectNode(F);G.removeAllRanges();G.addRange(E);}else{E=this._getDoc().createRange();E.selectNodeContents(F);G.removeAllRanges();G.addRange(E);}}}this.nodeChange();},_getRange:function(){var E=this._getSelection();if(E===null){return null;}if(this.browser.webkit&&!E.getRangeAt){var H=this._getDoc().createRange();try{H.setStart(E.anchorNode,E.anchorOffset);H.setEnd(E.focusNode,E.focusOffset);}catch(G){H=this._getWindow().getSelection()+"";}return H;}if(this.browser.ie||this.browser.opera){try{return E.createRange();}catch(F){return null;}}if(E.rangeCount>0){return E.getRangeAt(0);}return null;},_setDesignMode:function(E){try{var G=true;if(this.browser.ie&&(E.toLowerCase()=="off")){G=false;}if(G){this._getDoc().designMode=E;}}catch(F){}},_toggleDesignMode:function(){var F=this._getDoc().designMode.toLowerCase(),E="on";if(F=="on"){E="off";}this._setDesignMode(E);return E;},_initEditorEvents:function(){var E=this._getDoc();A.on(E,"mouseup",this._handleMouseUp,this,true);A.on(E,"mousedown",this._handleMouseDown,this,true);A.on(E,"click",this._handleClick,this,true);A.on(E,"dblclick",this._handleDoubleClick,this,true);A.on(E,"keypress",this._handleKeyPress,this,true);A.on(E,"keyup",this._handleKeyUp,this,true);A.on(E,"keydown",this._handleKeyDown,this,true);},_removeEditorEvents:function(){var E=this._getDoc();A.removeListener(E,"mouseup",this._handleMouseUp,this,true);A.removeListener(E,"mousedown",this._handleMouseDown,this,true);A.removeListener(E,"click",this._handleClick,this,true);A.removeListener(E,"dblclick",this._handleDoubleClick,this,true);A.removeListener(E,"keypress",this._handleKeyPress,this,true);A.removeListener(E,"keyup",this._handleKeyUp,this,true);A.removeListener(E,"keydown",this._handleKeyDown,this,true);},_initEditor:function(){if(this.browser.ie){this._getDoc().body.style.margin="0";}if(!this.get("disabled")){if(this._getDoc().designMode.toLowerCase()!="on"){this._setDesignMode("on");
|
delete this._focusIndex;
|
this._blurFocusedPanel = function() { if (!this._panelsByIndex[this._focusIndex]) { return; } this._panelsByIndex[this._focusIndex].blur(); delete this._focusIndex; }
|
|
return cachedMutation
|
return mutationCache[channel]
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return cachedMutation }
|
this._cacheMutation = function(mutation, channel) {
|
this._cacheMutation = function(mutation, key) {
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
cachedMutation = mutationCache[channel],
|
cachedMutation = mutationCache[key],
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
return mutationCache[channel] = mutation
|
return mutationCache[key] = mutation
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
mutationCache[channel] = mutation
|
mutationCache[key] = mutation
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
cachedMutation.args[0] = cachedArgs[0].concat(mutation.args)
|
cachedArgs[0] = cachedArgs[0].concat(mutation.args)
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
Array.prototype.splice.apply(cachedMutation.args, spliceArgs)
|
Array.prototype.splice.apply(cachedArgs, spliceArgs)
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
throw logger.error("Unkown operation "+ operation)
|
throw logger.error("Unknown operation for caching "+ operation)
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
return mutationCache[channel]
|
return mutationCache[key]
|
this._cacheMutation = function(mutation, channel) { var mutationCache = this._mutationCache, cachedMutation = mutationCache[channel], cachedArgs = cachedMutation && cachedMutation.args if (!cachedMutation) { return mutationCache[channel] = mutation } switch(mutation.op) { case 'set': mutationCache[channel] = mutation break case 'append': cachedMutation.args[0] = cachedArgs[0].concat(mutation.args) break case 'splice': var spliceArgs = [0, mutation.index].concat(mutation.args) Array.prototype.splice.apply(cachedMutation.args, spliceArgs) break case 'sadd': for (var i=0, itemId; itemId = mutation.args[i]; i++) { if (cachedArgs.indexOf(itemId) == -1) { cachedArgs.push(itemId) } } break case 'srem': for (var i=0, itemId; itemId = mutation.args[i]; i++) { cachedArgs.splice(cachedArgs.indexOf(itemId), 1) } break default: throw logger.error("Unkown operation "+ operation) } return mutationCache[channel] }
|
}};})();(function(){var C=YAHOO.util.Dom,A=YAHOO.util.Event,D=YAHOO.lang,B=YAHOO.widget.Toolbar;YAHOO.widget.Editor=function(F,E){YAHOO.widget.Editor.superclass.constructor.call(this,F,E);};YAHOO.extend(YAHOO.widget.Editor,YAHOO.widget.SimpleEditor,{_undoCache:null,_undoLevel:null,_hasUndoLevel:function(){return(this._undoCache.length&&this._undoLevel);},_undoNodeChange:function(){var E=this.toolbar.getButtonByValue("undo"),F=this.toolbar.getButtonByValue("redo");if(E&&F){if(this._hasUndoLevel()){this.toolbar.enableButton(E);}if(this._undoLevel<this._undoCache.length){this.toolbar.enableButton(F);}}},_checkUndo:function(){var E=this._undoCache.length,G=[];if(E>=this.get("maxUndo")){for(var F=(E-this.get("maxUndo"));F<E;F++){G.push(this._undoCache[F]);}this._undoCache=G;}},_putUndo:function(E){this._undoCache.push(E);},_getUndo:function(E){return this._undoCache[E];},_storeUndo:function(){if(this._lastCommand==="undo"||this._lastCommand==="redo"){return false;}if(!this._undoCache){this._undoCache=[];}this._checkUndo();var F=this.getEditorHTML();var E=this._undoCache[this._undoCache.length-1];if(E){if(F!==E){this._putUndo(F);}}else{this._putUndo(F);}this._undoLevel=this._undoCache.length;this._undoNodeChange();},STR_BEFORE_EDITOR:"This text field can contain stylized text and graphics. To cycle through all formatting options, use the keyboard shortcut Control + Shift + T to place focus on the toolbar and navigate between option heading names. <h4>Common formatting keyboard shortcuts:</h4><ul><li>Control Shift B sets text to bold</li> <li>Control Shift I sets text to italic</li> <li>Control Shift U underlines text</li> <li>Control Shift [ aligns text left</li> <li>Control Shift | centers text</li> <li>Control Shift ] aligns text right</li> <li>Control Shift L adds an HTML link</li> <li>To exit this text editor use the keyboard shortcut Control + Shift + ESC.</li></ul>",STR_CLOSE_WINDOW:"Close Window",STR_CLOSE_WINDOW_NOTE:"To close this window use the Control + Shift + W key",STR_IMAGE_PROP_TITLE:"Image Options",STR_IMAGE_URL:"Image URL",STR_IMAGE_TITLE:"Description",STR_IMAGE_SIZE:"Size",STR_IMAGE_ORIG_SIZE:"Original Size",STR_IMAGE_COPY:'<span class="tip"><span class="icon icon-info"></span><strong>Note:</strong>To move this image just highlight it, cut, and paste where ever you\'d like.</span>',STR_IMAGE_PADDING:"Padding",STR_IMAGE_BORDER:"Border",STR_IMAGE_BORDER_SIZE:"Border Size",STR_IMAGE_BORDER_TYPE:"Border Type",STR_IMAGE_TEXTFLOW:"Text Flow",STR_LOCAL_FILE_WARNING:'<span class="tip"><span class="icon icon-warn"></span><strong>Note:</strong>This image/link points to a file on your computer and will not be accessible to others on the internet.</span>',STR_LINK_PROP_TITLE:"Link Options",STR_LINK_PROP_REMOVE:"Remove link from text",STR_LINK_NEW_WINDOW:"Open in a new window.",STR_LINK_TITLE:"Description",CLASS_LOCAL_FILE:"warning-localfile",CLASS_HIDDEN:"yui-hidden",init:function(F,E){this._windows={};this._defaultToolbar={collapse:true,titlebar:"Text Editing Tools",draggable:false,buttonType:"advanced",buttons:[{group:"fontstyle",label:"Font Name and Size",buttons:[{type:"select",label:"Arial",value:"fontname",disabled:true,menu:[{text:"Arial",checked:true},{text:"Arial Black"},{text:"Comic Sans MS"},{text:"Courier New"},{text:"Lucida Console"},{text:"Tahoma"},{text:"Times New Roman"},{text:"Trebuchet MS"},{text:"Verdana"}]},{type:"spin",label:"13",value:"fontsize",range:[9,75],disabled:true}]},{type:"separator"},{group:"textstyle",label:"Font Style",buttons:[{type:"push",label:"Bold CTRL + SHIFT + B",value:"bold"},{type:"push",label:"Italic CTRL + SHIFT + I",value:"italic"},{type:"push",label:"Underline CTRL + SHIFT + U",value:"underline"},{type:"separator"},{type:"push",label:"Subscript",value:"subscript",disabled:true},{type:"push",label:"Superscript",value:"superscript",disabled:true}]},{type:"separator"},{group:"textstyle2",label:" ",buttons:[{type:"color",label:"Font Color",value:"forecolor",disabled:true},{type:"color",label:"Background Color",value:"backcolor",disabled:true},{type:"separator"},{type:"push",label:"Remove Formatting",value:"removeformat",disabled:true},{type:"push",label:"Show/Hide Hidden Elements",value:"hiddenelements"}]},{type:"separator"},{group:"undoredo",label:"Undo/Redo",buttons:[{type:"push",label:"Undo",value:"undo",disabled:true},{type:"push",label:"Redo",value:"redo",disabled:true}]},{type:"separator"},{group:"alignment",label:"Alignment",buttons:[{type:"push",label:"Align Left CTRL + SHIFT + [",value:"justifyleft"},{type:"push",label:"Align Center CTRL + SHIFT + |",value:"justifycenter"},{type:"push",label:"Align Right CTRL + SHIFT + ]",value:"justifyright"},{type:"push",label:"Justify",value:"justifyfull"}]},{type:"separator"},{group:"parastyle",label:"Paragraph Style",buttons:[{type:"select",label:"Normal",value:"heading",disabled:true,menu:[{text:"Normal",value:"none",checked:true},{text:"Header 1",value:"h1"},{text:"Header 2",value:"h2"},{text:"Header 3",value:"h3"},{text:"Header 4",value:"h4"},{text:"Header 5",value:"h5"},{text:"Header 6",value:"h6"}]}]},{type:"separator"},{group:"indentlist2",label:"Indenting and Lists",buttons:[{type:"push",label:"Indent",value:"indent",disabled:true},{type:"push",label:"Outdent",value:"outdent",disabled:true},{type:"push",label:"Create an Unordered List",value:"insertunorderedlist"},{type:"push",label:"Create an Ordered List",value:"insertorderedlist"}]},{type:"separator"},{group:"insertitem",label:"Insert Item",buttons:[{type:"push",label:"HTML Link CTRL + SHIFT + L",value:"createlink",disabled:true},{type:"push",label:"Insert Image",value:"insertimage"}]}]};this._defaultImageToolbarConfig={buttonType:this._defaultToolbar.buttonType,buttons:[{group:"textflow",label:this.STR_IMAGE_TEXTFLOW+":",buttons:[{type:"push",label:"Left",value:"left"},{type:"push",label:"Inline",value:"inline"},{type:"push",label:"Block",value:"block"},{type:"push",label:"Right",value:"right"}]},{type:"separator"},{group:"padding",label:this.STR_IMAGE_PADDING+":",buttons:[{type:"spin",label:"0",value:"padding",range:[0,50]}]},{type:"separator"},{group:"border",label:this.STR_IMAGE_BORDER+":",buttons:[{type:"select",label:this.STR_IMAGE_BORDER_SIZE,value:"bordersize",menu:[{text:"none",value:"0",checked:true},{text:"1px",value:"1"},{text:"2px",value:"2"},{text:"3px",value:"3"},{text:"4px",value:"4"},{text:"5px",value:"5"}]},{type:"select",label:this.STR_IMAGE_BORDER_TYPE,value:"bordertype",disabled:true,menu:[{text:"Solid",value:"solid",checked:true},{text:"Dashed",value:"dashed"},{text:"Dotted",value:"dotted"}]},{type:"color",label:"Border Color",value:"bordercolor",disabled:true}]}]};
|
(function(){var b=YAHOO.util.Dom,a=YAHOO.util.Event,c=YAHOO.lang;if(YAHOO.widget.Button){YAHOO.widget.ToolbarButtonAdvanced=YAHOO.widget.Button;YAHOO.widget.ToolbarButtonAdvanced.prototype.buttonType="rich";YAHOO.widget.ToolbarButtonAdvanced.prototype.checkValue=function(f){var e=this.getMenu().getItems();if(e.length===0){this.getMenu()._onBeforeShow();e=this.getMenu().getItems()}for(var d=0;d<e.length;d++){e[d].cfg.setProperty("checked",false);if(e[d].value==f){e[d].cfg.setProperty("checked",true)}}}}else{YAHOO.widget.ToolbarButtonAdvanced=function(){}}YAHOO.widget.ToolbarButton=function(e,d){if(c.isObject(arguments[0])&&!b.get(e).nodeType){d=e}var g=(d||{});var f={element:null,attributes:g};if(!f.attributes.type){f.attributes.type="push"}f.element=document.createElement("span");f.element.setAttribute("unselectable","on");f.element.className="yui-button yui-"+f.attributes.type+"-button";f.element.innerHTML='<span class="first-child"><a href="#">LABEL</a></span>';f.element.firstChild.firstChild.tabIndex="-1";f.attributes.id=b.generateId();YAHOO.widget.ToolbarButton.superclass.constructor.call(this,f.element,f.attributes)};YAHOO.extend(YAHOO.widget.ToolbarButton,YAHOO.util.Element,{buttonType:"normal",_handleMouseOver:function(){if(!this.get("disabled")){this.addClass("yui-button-hover");this.addClass("yui-"+this.get("type")+"-button-hover")}},_handleMouseOut:function(){this.removeClass("yui-button-hover");this.removeClass("yui-"+this.get("type")+"-button-hover")},checkValue:function(f){if(this.get("type")=="menu"){var e=this._button.options;for(var d=0;d<e.length;d++){if(e[d].value==f){e.selectedIndex=d}}}},init:function(e,d){YAHOO.widget.ToolbarButton.superclass.init.call(this,e,d);this.on("mouseover",this._handleMouseOver,this,true);this.on("mouseout",this._handleMouseOut,this,true)},initAttributes:function(d){YAHOO.widget.ToolbarButton.superclass.initAttributes.call(this,d);this.setAttributeConfig("value",{value:d.value});this.setAttributeConfig("menu",{value:d.menu||false});this.setAttributeConfig("type",{value:d.type,writeOnce:true,method:function(h){var g,f;if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}switch(h){case"select":case"menu":g=document.createElement("select");var j=this.get("menu");for(var e=0;e<j.length;e++){f=document.createElement("option");f.innerHTML=j[e].text;f.value=j[e].value;if(j[e].checked){f.selected=true}g.appendChild(f)}this._button.parentNode.replaceChild(g,this._button);a.on(g,"change",this._handleSelect,this,true);this._button=g;break}}});this.setAttributeConfig("disabled",{value:d.disabled||false,method:function(e){if(e){this.addClass("yui-button-disabled");this.addClass("yui-"+this.get("type")+"-button-disabled")}else{this.removeClass("yui-button-disabled");this.removeClass("yui-"+this.get("type")+"-button-disabled")}if(this.get("type")=="menu"){this._button.disabled=e}}});this.setAttributeConfig("label",{value:d.label,method:function(e){if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}if(this.get("type")=="push"){this._button.innerHTML=e}}});this.setAttributeConfig("title",{value:d.title});this.setAttributeConfig("container",{value:null,writeOnce:true,method:function(e){this.appendTo(e)}})},_handleSelect:function(e){var d=a.getTarget(e);var f=d.options[d.selectedIndex].value;this.fireEvent("change",{type:"change",value:f})},getMenu:function(){return this.get("menu")},destroy:function(){a.purgeElement(this.get("element"),true);this.get("element").parentNode.removeChild(this.get("element"));for(var d in this){if(c.hasOwnProperty(this,d)){this[d]=null}}},fireEvent:function(e,d){if(this.DOM_EVENTS[e]&&this.get("disabled")){return}YAHOO.widget.ToolbarButton.superclass.fireEvent.call(this,e,d)},toString:function(){return"ToolbarButton ("+this.get("id")+")"}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang;var b=function(f){var e=f;if(d.isString(f)){e=this.getButtonById(f)}if(d.isNumber(f)){e=this.getButtonByIndex(f)}if((!(e instanceof YAHOO.widget.ToolbarButton))&&(!(e instanceof YAHOO.widget.ToolbarButtonAdvanced))){e=this.getButtonByValue(f)}if((e instanceof YAHOO.widget.ToolbarButton)||(e instanceof YAHOO.widget.ToolbarButtonAdvanced)){return e}return false};YAHOO.widget.Toolbar=function(i,h){if(d.isObject(arguments[0])&&!c.get(i).nodeType){h=i}var k={};if(h){d.augmentObject(k,h)}var j={element:null,attributes:k};if(d.isString(i)&&c.get(i)){j.element=c.get(i)}else{if(d.isObject(i)&&c.get(i)&&c.get(i).nodeType){j.element=c.get(i)}}if(!j.element){j.element=document.createElement("DIV");j.element.id=c.generateId();if(k.container&&c.get(k.container)){c.get(k.container).appendChild(j.element)}}if(!j.element.id){j.element.id=((d.isString(i))?i:c.generateId())}var f=document.createElement("fieldset");var g=document.createElement("legend");g.innerHTML="Toolbar";f.appendChild(g);var e=document.createElement("DIV");j.attributes.cont=e;c.addClass(e,"yui-toolbar-subcont");f.appendChild(e);j.element.appendChild(f);j.element.tabIndex=-1;j.attributes.element=j.element;j.attributes.id=j.element.id;YAHOO.widget.Toolbar.superclass.constructor.call(this,j.element,j.attributes)};YAHOO.extend(YAHOO.widget.Toolbar,YAHOO.util.Element,{_addMenuClasses:function(h,e,j){c.addClass(this.element,"yui-toolbar-"+j.get("value")+"-menu");if(c.hasClass(j._button.parentNode.parentNode,"yui-toolbar-select")){c.addClass(this.element,"yui-toolbar-select-menu")}var f=this.getItems();for(var g=0;g<f.length;g++){c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-").toLowerCase():f[g]._oText.nodeValue.replace(/ /g,"-").toLowerCase()));c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-"):f[g]._oText.nodeValue.replace(/ /g,"-")))}},buttonType:YAHOO.widget.ToolbarButton,dd:null,_colorData:{"#111111":"Obsidian","#2D2D2D":"Dark Gray","#434343":"Shale","#5B5B5B":"Flint","#737373":"Gray","#8B8B8B":"Concrete","#A2A2A2":"Gray","#B9B9B9":"Titanium","#000000":"Black","#D0D0D0":"Light Gray","#E6E6E6":"Silver","#FFFFFF":"White","#BFBF00":"Pumpkin","#FFFF00":"Yellow","#FFFF40":"Banana","#FFFF80":"Pale Yellow","#FFFFBF":"Butter","#525330":"Raw Siena","#898A49":"Mildew","#AEA945":"Olive","#7F7F00":"Paprika","#C3BE71":"Earth","#E0DCAA":"Khaki","#FCFAE1":"Cream","#60BF00":"Cactus","#80FF00":"Chartreuse","#A0FF40":"Green","#C0FF80":"Pale Lime","#DFFFBF":"Light Mint","#3B5738":"Green","#668F5A":"Lime Gray","#7F9757":"Yellow","#407F00":"Clover","#8A9B55":"Pistachio","#B7C296":"Light Jade","#E6EBD5":"Breakwater","#00BF00":"Spring Frost","#00FF80":"Pastel Green","#40FFA0":"Light Emerald","#80FFC0":"Sea Foam","#BFFFDF":"Sea Mist","#033D21":"Dark Forrest","#438059":"Moss","#7FA37C":"Medium Green","#007F40":"Pine","#8DAE94":"Yellow Gray Green","#ACC6B5":"Aqua Lung","#DDEBE2":"Sea Vapor","#00BFBF":"Fog","#00FFFF":"Cyan","#40FFFF":"Turquoise Blue","#80FFFF":"Light Aqua","#BFFFFF":"Pale Cyan","#033D3D":"Dark Teal","#347D7E":"Gray Turquoise","#609A9F":"Green Blue","#007F7F":"Seaweed","#96BDC4":"Green Gray","#B5D1D7":"Soapstone","#E2F1F4":"Light Turquoise","#0060BF":"Summer Sky","#0080FF":"Sky Blue","#40A0FF":"Electric Blue","#80C0FF":"Light Azure","#BFDFFF":"Ice Blue","#1B2C48":"Navy","#385376":"Biscay","#57708F":"Dusty Blue","#00407F":"Sea Blue","#7792AC":"Sky Blue Gray","#A8BED1":"Morning Sky","#DEEBF6":"Vapor","#0000BF":"Deep Blue","#0000FF":"Blue","#4040FF":"Cerulean Blue","#8080FF":"Evening Blue","#BFBFFF":"Light Blue","#212143":"Deep Indigo","#373E68":"Sea Blue","#444F75":"Night Blue","#00007F":"Indigo Blue","#585E82":"Dockside","#8687A4":"Blue Gray","#D2D1E1":"Light Blue Gray","#6000BF":"Neon Violet","#8000FF":"Blue Violet","#A040FF":"Violet Purple","#C080FF":"Violet Dusk","#DFBFFF":"Pale Lavender","#302449":"Cool Shale","#54466F":"Dark Indigo","#655A7F":"Dark Violet","#40007F":"Violet","#726284":"Smoky Violet","#9E8FA9":"Slate Gray","#DCD1DF":"Violet White","#BF00BF":"Royal Violet","#FF00FF":"Fuchsia","#FF40FF":"Magenta","#FF80FF":"Orchid","#FFBFFF":"Pale Magenta","#4A234A":"Dark Purple","#794A72":"Medium Purple","#936386":"Cool Granite","#7F007F":"Purple","#9D7292":"Purple Moon","#C0A0B6":"Pale Purple","#ECDAE5":"Pink Cloud","#BF005F":"Hot Pink","#FF007F":"Deep Pink","#FF409F":"Grape","#FF80BF":"Electric Pink","#FFBFDF":"Pink","#451528":"Purple Red","#823857":"Purple Dino","#A94A76":"Purple Gray","#7F003F":"Rose","#BC6F95":"Antique Mauve","#D8A5BB":"Cool Marble","#F7DDE9":"Pink Granite","#C00000":"Apple","#FF0000":"Fire Truck","#FF4040":"Pale Red","#FF8080":"Salmon","#FFC0C0":"Warm Pink","#441415":"Sepia","#82393C":"Rust","#AA4D4E":"Brick","#800000":"Brick Red","#BC6E6E":"Mauve","#D8A3A4":"Shrimp Pink","#F8DDDD":"Shell Pink","#BF5F00":"Dark Orange","#FF7F00":"Orange","#FF9F40":"Grapefruit","#FFBF80":"Canteloupe","#FFDFBF":"Wax","#482C1B":"Dark Brick","#855A40":"Dirt","#B27C51":"Tan","#7F3F00":"Nutmeg","#C49B71":"Mustard","#E1C4A8":"Pale Tan","#FDEEE0":"Marble"},_colorPicker:null,STR_COLLAPSE:"Collapse Toolbar",STR_SPIN_LABEL:"Spin Button with value {VALUE}. Use Control Shift Up Arrow and Control Shift Down arrow keys to increase or decrease the value.",STR_SPIN_UP:"Click to increase the value of this input",STR_SPIN_DOWN:"Click to decrease the value of this input",_titlebar:null,browser:YAHOO.env.ua,_buttonList:null,_buttonGroupList:null,_sep:null,_sepCount:null,_dragHandle:null,_toolbarConfigs:{renderer:true},CLASS_CONTAINER:"yui-toolbar-container",CLASS_DRAGHANDLE:"yui-toolbar-draghandle",CLASS_SEPARATOR:"yui-toolbar-separator",CLASS_DISABLED:"yui-toolbar-disabled",CLASS_PREFIX:"yui-toolbar",init:function(f,e){YAHOO.widget.Toolbar.superclass.init.call(this,f,e)},initAttributes:function(e){YAHOO.widget.Toolbar.superclass.initAttributes.call(this,e);this.addClass(this.CLASS_CONTAINER);this.setAttributeConfig("buttonType",{value:e.buttonType||"basic",writeOnce:true,validator:function(f){switch(f){case"advanced":case"basic":return true}return false},method:function(f){if(f=="advanced"){if(YAHOO.widget.Button){this.buttonType=YAHOO.widget.ToolbarButtonAdvanced}else{this.buttonType=YAHOO.widget.ToolbarButton}}else{this.buttonType=YAHOO.widget.ToolbarButton}}});this.setAttributeConfig("buttons",{value:[],writeOnce:true,method:function(g){for(var f in g){if(d.hasOwnProperty(g,f)){if(g[f].type=="separator"){this.addSeparator()}else{if(g[f].group!==undefined){this.addButtonGroup(g[f])}else{this.addButton(g[f])}}}}}});this.setAttributeConfig("disabled",{value:false,method:function(f){if(this.get("disabled")===f){return false}if(f){this.addClass(this.CLASS_DISABLED);this.set("draggable",false);this.disableAllButtons()}else{this.removeClass(this.CLASS_DISABLED);if(this._configs.draggable._initialConfig.value){this.set("draggable",true)}this.resetAllButtons()}}});this.setAttributeConfig("cont",{value:e.cont,readOnly:true});this.setAttributeConfig("grouplabels",{value:((e.grouplabels===false)?false:true),method:function(f){if(f){c.removeClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}else{c.addClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}}});this.setAttributeConfig("titlebar",{value:false,method:function(g){if(g){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}this._titlebar=document.createElement("DIV");this._titlebar.tabIndex="-1";a.on(this._titlebar,"focus",function(){this._handleFocus()},this,true);c.addClass(this._titlebar,this.CLASS_PREFIX+"-titlebar");if(d.isString(g)){var f=document.createElement("h2");f.tabIndex="-1";f.innerHTML='<a href="#" tabIndex="0">'+g+"</a>";this._titlebar.appendChild(f);a.on(f.firstChild,"click",function(h){a.stopEvent(h)});a.on([f,f.firstChild],"focus",function(){this._handleFocus()},this,true)}if(this.get("firstChild")){this.insertBefore(this._titlebar,this.get("firstChild"))}else{this.appendChild(this._titlebar)}if(this.get("collapse")){this.set("collapse",true)}}else{if(this._titlebar){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}}}}});this.setAttributeConfig("collapse",{value:false,method:function(h){if(this._titlebar){var g=null;var f=c.getElementsByClassName("collapse","span",this._titlebar);if(h){if(f.length>0){return true}g=document.createElement("SPAN");g.innerHTML="X";g.title=this.STR_COLLAPSE;c.addClass(g,"collapse");this._titlebar.appendChild(g);a.addListener(g,"click",function(){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}else{this.collapse()}},this,true)}else{g=c.getElementsByClassName("collapse","span",this._titlebar);if(g[0]){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}g[0].parentNode.removeChild(g[0])}}}}});this.setAttributeConfig("draggable",{value:(e.draggable||false),method:function(f){if(f&&!this.get("titlebar")){if(!this._dragHandle){this._dragHandle=document.createElement("SPAN");this._dragHandle.innerHTML="|";this._dragHandle.setAttribute("title","Click to drag the toolbar");this._dragHandle.id=this.get("id")+"_draghandle";c.addClass(this._dragHandle,this.CLASS_DRAGHANDLE);if(this.get("cont").hasChildNodes()){this.get("cont").insertBefore(this._dragHandle,this.get("cont").firstChild)}else{this.get("cont").appendChild(this._dragHandle)}this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._dragHandle.id)}}else{if(this._dragHandle){this._dragHandle.parentNode.removeChild(this._dragHandle);this._dragHandle=null;this.dd=null}}if(this._titlebar){if(f){this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._titlebar);c.addClass(this._titlebar,"draggable")}else{c.removeClass(this._titlebar,"draggable");if(this.dd){this.dd.unreg();this.dd=null}}}},validator:function(g){var f=true;if(!YAHOO.util.DD){f=false}return f}})},addButtonGroup:function(j){if(!this.get("element")){this._queue[this._queue.length]=["addButtonGroup",arguments];return false}if(!this.hasClass(this.CLASS_PREFIX+"-grouped")){this.addClass(this.CLASS_PREFIX+"-grouped")}var k=document.createElement("DIV");c.addClass(k,this.CLASS_PREFIX+"-group");c.addClass(k,this.CLASS_PREFIX+"-group-"+j.group);if(j.label){var f=document.createElement("h3");f.innerHTML=j.label;k.appendChild(f)}if(!this.get("grouplabels")){c.addClass(this.get("cont"),this.CLASS_PREFIX,"-nogrouplabels")}this.get("cont").appendChild(k);var h=document.createElement("ul");k.appendChild(h);if(!this._buttonGroupList){this._buttonGroupList={}}this._buttonGroupList[j.group]=h;for(var g=0;g<j.buttons.length;g++){var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";h.appendChild(e);if((j.buttons[g].type!==undefined)&&j.buttons[g].type=="separator"){this.addSeparator(e)}else{j.buttons[g].container=e;this.addButton(j.buttons[g])}}},addButtonToGroup:function(g,h,i){var f=this._buttonGroupList[h];var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";g.container=e;this.addButton(g,i);f.appendChild(e)},addButton:function(k,j){if(!this.get("element")){this._queue[this._queue.length]=["addButton",arguments];return false}if(!this._buttonList){this._buttonList=[]}if(!k.container){k.container=this.get("cont")}if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){for(var s in k.menu){if(d.hasOwnProperty(k.menu,s)){var y={fn:function(o,i,m){if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue)},scope:this};k.menu[s].onclick=y}}}}var t={},q=false;for(var n in k){if(d.hasOwnProperty(k,n)){if(!this._toolbarConfigs[n]){t[n]=k[n]}}}if(k.type=="select"){t.type="menu"}if(k.type=="spin"){t.type="push"}if(t.type=="color"){if(YAHOO.widget.Overlay){t=this._makeColorButton(t)}else{q=true}}if(t.menu){if((YAHOO.widget.Overlay)&&(k.menu instanceof YAHOO.widget.Overlay)){k.menu.showEvent.subscribe(function(){this._button=t})}else{for(var r=0;r<t.menu.length;r++){if(!t.menu[r].value){t.menu[r].value=t.menu[r].text}}if(this.browser.webkit){t.focusmenu=false}}}if(q){k=false}else{this._configs.buttons.value[this._configs.buttons.value.length]=k;var w=new this.buttonType(t);w.get("element").tabIndex="-1";w.get("element").setAttribute("role","button");w._selected=true;if(this.get("disabled")){w.set("disabled",true)}if(!k.id){k.id=w.get("id")}if(j){var f=w.get("element");var p=null;if(j.get){p=j.get("element").nextSibling}else{if(j.nextSibling){p=j.nextSibling}}if(p){p.parentNode.insertBefore(f,p)}}w.addClass(this.CLASS_PREFIX+"-"+w.get("value"));var v=document.createElement("span");v.className=this.CLASS_PREFIX+"-icon";w.get("element").insertBefore(v,w.get("firstChild"));if(w._button.tagName.toLowerCase()=="button"){w.get("element").setAttribute("unselectable","on");var x=document.createElement("a");x.innerHTML=w._button.innerHTML;x.href="#";x.tabIndex="-1";a.on(x,"click",function(i){a.stopEvent(i)});w._button.parentNode.replaceChild(x,w._button);w._button=x}if(k.type=="select"){if(w._button.tagName.toLowerCase()=="select"){v.parentNode.removeChild(v);var g=w._button;var u=w.get("element");u.parentNode.replaceChild(g,u)}else{w.addClass(this.CLASS_PREFIX+"-select")}}if(k.type=="spin"){if(!d.isArray(k.range)){k.range=[10,100]}this._makeSpinButton(w,k)}w.get("element").setAttribute("title",w.get("label"));if(k.type!="spin"){if((YAHOO.widget.Overlay)&&(t.menu instanceof YAHOO.widget.Overlay)){var h=function(o){var i=true;if(o.keyCode&&(o.keyCode==9)){i=false}if(i){if(this._colorPicker){this._colorPicker._button=k.value}var m=w.getMenu().element;if(c.getStyle(m,"visibility")=="hidden"){w.getMenu().show()}else{w.getMenu().hide()}}YAHOO.util.Event.stopEvent(o)};w.on("mousedown",h,k,this);w.on("keydown",h,k,this)}else{if((k.type!="menu")&&(k.type!="select")){w.on("keypress",this._buttonClick,k,this);w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i);this._buttonClick(i,k)},k,this);w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)});w.on("change",function(i){if(!k.menucmd){k.menucmd=k.value}k.value=i.value;this._buttonClick(i,k)},this,true);var l=this;w.on("appendTo",function(){var i=this;if(i.getMenu()&&i.getMenu().mouseDownEvent){i.getMenu().mouseDownEvent.subscribe(function(z,o){var m=o[1];YAHOO.util.Event.stopEvent(o[0]);i._onMenuClick(o[0],i);if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue);l._buttonClick.call(l,o[1],k);i._hideMenu();return false});i.getMenu().clickEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])});i.getMenu().mouseUpEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])})}})}}}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}if(this.browser.ie){}if(this.browser.webkit){w.hasFocus=function(){return true}}this._buttonList[this._buttonList.length]=w;if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){var e=w.getMenu();if(e&&e.renderEvent){e.renderEvent.subscribe(this._addMenuClasses,w);if(k.renderer){e.renderEvent.subscribe(k.renderer,w)}}}}}return k},addSeparator:function(e,h){if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}var f=((e)?e:this.get("cont"));if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}if(this._sepCount===null){this._sepCount=0}if(!this._sep){this._sep=document.createElement("SPAN");c.addClass(this._sep,this.CLASS_SEPARATOR);this._sep.innerHTML="|"}var g=this._sep.cloneNode(true);this._sepCount++;c.addClass(g,this.CLASS_SEPARATOR+"-"+this._sepCount);if(h){var i=null;if(h.get){i=h.get("element").nextSibling}else{if(h.nextSibling){i=h.nextSibling}else{i=h}}if(i){if(i==h){i.parentNode.appendChild(g)}else{i.parentNode.insertBefore(g,i)}}}else{f.appendChild(g)}return g},_createColorPicker:function(h){if(c.get(h+"_colors")){c.get(h+"_colors").parentNode.removeChild(c.get(h+"_colors"))}var e=document.createElement("div");e.className="yui-toolbar-colors";e.id=h+"_colors";e.style.display="none";a.on(window,"load",function(){document.body.appendChild(e)},this,true);this._colorPicker=e;var g="";for(var f in this._colorData){if(d.hasOwnProperty(this._colorData,f)){g+='<a style="background-color: '+f+'" href="#">'+f.replace("#","")+"</a>"}}g+="<span><em>X</em><strong></strong></span>";window.setTimeout(function(){e.innerHTML=g},0);a.on(e,"mouseover",function(m){var k=this._colorPicker;var l=k.getElementsByTagName("em")[0];var j=k.getElementsByTagName("strong")[0];var i=a.getTarget(m);if(i.tagName.toLowerCase()=="a"){l.style.backgroundColor=i.style.backgroundColor;j.innerHTML=this._colorData["#"+i.innerHTML]+"<br>"+i.innerHTML}},this,true);a.on(e,"focus",function(i){a.stopEvent(i)});a.on(e,"click",function(i){a.stopEvent(i)});a.on(e,"mousedown",function(j){a.stopEvent(j);var i=a.getTarget(j);if(i.tagName.toLowerCase()=="a"){var l=this.fireEvent("colorPickerClicked",{type:"colorPickerClicked",target:this,button:this._colorPicker._button,color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML]});if(l!==false){var k={color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML],value:this._colorPicker._button};this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:k})}this.getButtonByValue(this._colorPicker._button).getMenu().hide()}},this,true)},_resetColorPicker:function(){var f=this._colorPicker.getElementsByTagName("em")[0];var e=this._colorPicker.getElementsByTagName("strong")[0];f.style.backgroundColor="transparent";e.innerHTML=""},_makeColorButton:function(e){if(!this._colorPicker){this._createColorPicker(this.get("id"))}e.type="color";e.menu=new YAHOO.widget.Overlay(this.get("id")+"_"+e.value+"_menu",{visible:false,position:"absolute",iframe:true});e.menu.setBody("");e.menu.render(this.get("cont"));c.addClass(e.menu.element,"yui-button-menu");c.addClass(e.menu.element,"yui-color-button-menu");e.menu.beforeShowEvent.subscribe(function(){e.menu.cfg.setProperty("zindex",5);e.menu.cfg.setProperty("context",[this.getButtonById(e.id).get("element"),"tl","bl"]);this._resetColorPicker();var f=this._colorPicker;if(f.parentNode){f.parentNode.removeChild(f)}e.menu.setBody("");e.menu.appendToBody(f);this._colorPicker.style.display="block"},this,true);return e},_makeSpinButton:function(r,l){r.addClass(this.CLASS_PREFIX+"-spinbutton");var s=this,n=r._button.parentNode.parentNode,i=l.range,h=document.createElement("a"),g=document.createElement("a");h.href="#";g.href="#";h.tabIndex="-1";g.tabIndex="-1";h.className="up";h.title=this.STR_SPIN_UP;h.innerHTML=this.STR_SPIN_UP;g.className="down";g.title=this.STR_SPIN_DOWN;g.innerHTML=this.STR_SPIN_DOWN;n.appendChild(h);n.appendChild(g);var m=YAHOO.lang.substitute(this.STR_SPIN_LABEL,{VALUE:r.get("label")});r.set("title",m);var q=function(t){t=((t<i[0])?i[0]:t);t=((t>i[1])?i[1]:t);return t};var p=this.browser;var f=false;var k=this.STR_SPIN_LABEL;if(this._titlebar&&this._titlebar.firstChild){f=this._titlebar.firstChild}var e=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v++;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var o=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v--;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var j=function(t){if(t.keyCode==38){e(t)}else{if(t.keyCode==40){o(t)}else{if(t.keyCode==107&&t.shiftKey){e(t)}else{if(t.keyCode==109&&t.shiftKey){o(t)}}}}};r.on("keydown",j,this,true);a.on(h,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(g,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(h,"click",e,this,true);a.on(g,"click",o,this,true)},_buttonClick:function(n,f){var e=true;if(n&&n.type=="keypress"){if(n.keyCode==9){e=false}else{if((n.keyCode===13)||(n.keyCode===0)||(n.keyCode===32)){}else{e=false}}}if(e){var p=true,h=false;f.isSelected=this.isSelected(f.id);if(f.value){h=this.fireEvent(f.value+"Click",{type:f.value+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(f.menucmd&&p){h=this.fireEvent(f.menucmd+"Click",{type:f.menucmd+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(p){this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:f})}if(f.type=="select"){var l=this.getButtonById(f.id);if(l.buttonType=="rich"){var k=f.value;for(var j=0;j<f.menu.length;j++){if(f.menu[j].value==f.value){k=f.menu[j].text;break}}l.set("label",'<span class="yui-toolbar-'+f.menucmd+"-"+(f.value).replace(/ /g,"-").toLowerCase()+'">'+k+"</span>");var o=l.getMenu().getItems();for(var g=0;g<o.length;g++){if(o[g].value.toLowerCase()==f.value.toLowerCase()){o[g].cfg.setProperty("checked",true)}else{o[g].cfg.setProperty("checked",false)}}}}if(n){a.stopEvent(n)}}},_keyNav:null,_navCounter:null,_navigateButtons:function(f){switch(f.keyCode){case 37:case 39:if(f.keyCode==37){this._navCounter--}else{this._navCounter++}if(this._navCounter>(this._buttonList.length-1)){this._navCounter=0}if(this._navCounter<0){this._navCounter=(this._buttonList.length-1)}if(this._buttonList[this._navCounter]){var e=this._buttonList[this._navCounter].get("element");if(this.browser.ie){e=this._buttonList[this._navCounter].get("element").getElementsByTagName("a")[0]}if(this._buttonList[this._navCounter].get("disabled")){this._navigateButtons(f)}else{e.focus()}}break}},_handleFocus:function(){if(!this._keyNav){var e="keypress";if(this.browser.ie){e="keydown"}a.on(this.get("element"),e,this._navigateButtons,this,true);this._keyNav=true;this._navCounter=-1}},getButtonById:function(g){var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==g){return this._buttonList[f]}}return false},getButtonByValue:function(n){var h=this.get("buttons");var f=h.length;for(var k=0;k<f;k++){if(h[k].group!==undefined){for(var e=0;e<h[k].buttons.length;e++){if((h[k].buttons[e].value==n)||(h[k].buttons[e].menucmd==n)){return this.getButtonById(h[k].buttons[e].id)}if(h[k].buttons[e].menu){for(var l=0;l<h[k].buttons[e].menu.length;l++){if(h[k].buttons[e].menu[l].value==n){return this.getButtonById(h[k].buttons[e].id)}}}}}else{if((h[k].value==n)||(h[k].menucmd==n)){return this.getButtonById(h[k].id)}if(h[k].menu){for(var g=0;g<h[k].menu.length;g++){if(h[k].menu[g].value==n){return this.getButtonById(h[k].id)}}}}}return false},getButtonByIndex:function(e){if(this._buttonList[e]){return this._buttonList[e]}else{return false}},getButtons:function(){return this._buttonList},disableButton:function(f){var e=b.call(this,f);if(e){e.set("disabled",true)}else{return false}},enableButton:function(f){if(this.get("disabled")){return false}var e=b.call(this,f);if(e){if(e.get("disabled")){e.set("disabled",false)}}else{return false}},isSelected:function(f){var e=b.call(this,f);if(e){return e._selected}return false},selectButton:function(i,g){var f=b.call(this,i);if(f){f.addClass("yui-button-selected");f.addClass("yui-button-"+f.get("value")+"-selected");f._selected=true;if(g){if(f.buttonType=="rich"){var h=f.getMenu().getItems();for(var e=0;e<h.length;e++){if(h[e].value==g){h[e].cfg.setProperty("checked",true);f.set("label",'<span class="yui-toolbar-'+f.get("value")+"-"+(g).replace(/ /g,"-").toLowerCase()+'">'+h[e]._oText.nodeValue+"</span>")}else{h[e].cfg.setProperty("checked",false)}}}}}else{return false}},deselectButton:function(f){var e=b.call(this,f);if(e){e.removeClass("yui-button-selected");e.removeClass("yui-button-"+e.get("value")+"-selected");e.removeClass("yui-button-hover");e._selected=false}else{return false}},deselectAllButtons:function(){var e=this._buttonList.length;for(var f=0;f<e;f++){this.deselectButton(this._buttonList[f])}},disableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.disableButton(this._buttonList[f])}},enableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.enableButton(this._buttonList[f])}},resetAllButtons:function(j){if(!d.isObject(j)){j={}}if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){var h=this._buttonList[f];if(h){var g=h._configs.disabled._initialConfig.value;if(j[h.get("id")]){this.enableButton(h);this.selectButton(h)}else{if(g){this.disableButton(h)}else{this.enableButton(h)}this.deselectButton(h)}}}},destroyButton:function(j){var g=b.call(this,j);if(g){var h=g.get("id");g.destroy();var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==h){this._buttonList[f]=null}}}else{return false}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var e in this){if(d.hasOwnProperty(this,e)){this[e]=null}}return true},collapse:function(f){var e=c.getElementsByClassName("collapse","span",this._titlebar);if(f===false){c.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(e[0]){c.removeClass(e[0],"collapsed")}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this})}else{if(e[0]){c.addClass(e[0],"collapsed")}c.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this})}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons."}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang,b=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(h,m){var g={};if(d.isObject(h)&&(!h.tagName)&&!m){d.augmentObject(g,h);h=document.createElement("textarea");this.DOMReady=true;if(g.container){var k=c.get(g.container);k.appendChild(h)}else{document.body.appendChild(h)}}else{if(m){d.augmentObject(g,m)}}var i={element:null,attributes:g},f=null;if(d.isString(h)){f=h}else{if(i.attributes.id){f=i.attributes.id}else{this.DOMReady=true;f=c.generateId(h)}}i.element=h;var j=document.createElement("DIV");i.attributes.element_cont=new YAHOO.util.Element(j,{id:f+"_container"});var e=document.createElement("div");c.addClass(e,"first-child");i.attributes.element_cont.appendChild(e);if(!i.attributes.toolbar_cont){i.attributes.toolbar_cont=document.createElement("DIV");i.attributes.toolbar_cont.id=f+"_toolbar";e.appendChild(i.attributes.toolbar_cont)}var l=document.createElement("DIV");e.appendChild(l);i.attributes.editor_wrapper=l;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,i.element,i.attributes)};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false}if(this.get("resize")){var e={};d.augmentObject(e,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),e);this.resize.on("resize",function(g){var l=this.get("animate");this.set("animate",false);this.set("width",g.width+"px");var i=g.height,j=(this.toolbar.get("element").clientHeight+2),k=0;if(this.dompath){k=(this.dompath.clientHeight+1)}var f=(i-j-k);this.set("height",f+"px");this.get("element_cont").setStyle("height","");this.set("animate",l)},this,true)}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false}if(this.get("drag")){var f=this.get("drag"),e=YAHOO.util.DD;if(f==="proxy"){e=YAHOO.util.DDProxy}this.dd=new e(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar)}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(f,j){var g=false;if((j.keyCode===f.key)){if(f.mods&&(f.mods.length>0)){var l=0;for(var h=0;h<f.mods.length;h++){if(this.browser.mac){if(f.mods[h]=="ctrl"){f.mods[h]="meta"}}if(j[f.mods[h]+"Key"]===true){l++}}if(l===f.mods.length){g=true}}else{g=true}}return g},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(e){return e.replace(/ /g,"-").toLowerCase()},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-
|
}};})();(function(){var C=YAHOO.util.Dom,A=YAHOO.util.Event,D=YAHOO.lang,B=YAHOO.widget.Toolbar;YAHOO.widget.Editor=function(F,E){YAHOO.widget.Editor.superclass.constructor.call(this,F,E);};YAHOO.extend(YAHOO.widget.Editor,YAHOO.widget.SimpleEditor,{_undoCache:null,_undoLevel:null,_hasUndoLevel:function(){return(this._undoCache.length&&this._undoLevel);},_undoNodeChange:function(){var E=this.toolbar.getButtonByValue("undo"),F=this.toolbar.getButtonByValue("redo");if(E&&F){if(this._hasUndoLevel()){this.toolbar.enableButton(E);}if(this._undoLevel<this._undoCache.length){this.toolbar.enableButton(F);}}},_checkUndo:function(){var E=this._undoCache.length,G=[];if(E>=this.get("maxUndo")){for(var F=(E-this.get("maxUndo"));F<E;F++){G.push(this._undoCache[F]);}this._undoCache=G;}},_putUndo:function(E){this._undoCache.push(E);},_getUndo:function(E){return this._undoCache[E];},_storeUndo:function(){if(this._lastCommand==="undo"||this._lastCommand==="redo"){return false;}if(!this._undoCache){this._undoCache=[];}this._checkUndo();var F=this.getEditorHTML();var E=this._undoCache[this._undoCache.length-1];if(E){if(F!==E){this._putUndo(F);}}else{this._putUndo(F);}this._undoLevel=this._undoCache.length;this._undoNodeChange();},STR_BEFORE_EDITOR:"This text field can contain stylized text and graphics. To cycle through all formatting options, use the keyboard shortcut Control + Shift + T to place focus on the toolbar and navigate between option heading names. <h4>Common formatting keyboard shortcuts:</h4><ul><li>Control Shift B sets text to bold</li> <li>Control Shift I sets text to italic</li> <li>Control Shift U underlines text</li> <li>Control Shift [ aligns text left</li> <li>Control Shift | centers text</li> <li>Control Shift ] aligns text right</li> <li>Control Shift L adds an HTML link</li> <li>To exit this text editor use the keyboard shortcut Control + Shift + ESC.</li></ul>",STR_CLOSE_WINDOW:"Close Window",STR_CLOSE_WINDOW_NOTE:"To close this window use the Control + Shift + W key",STR_IMAGE_PROP_TITLE:"Image Options",STR_IMAGE_URL:"Image URL",STR_IMAGE_TITLE:"Description",STR_IMAGE_SIZE:"Size",STR_IMAGE_ORIG_SIZE:"Original Size",STR_IMAGE_COPY:'<span class="tip"><span class="icon icon-info"></span><strong>Note:</strong>To move this image just highlight it, cut, and paste where ever you\'d like.</span>',STR_IMAGE_PADDING:"Padding",STR_IMAGE_BORDER:"Border",STR_IMAGE_BORDER_SIZE:"Border Size",STR_IMAGE_BORDER_TYPE:"Border Type",STR_IMAGE_TEXTFLOW:"Text Flow",STR_LOCAL_FILE_WARNING:'<span class="tip"><span class="icon icon-warn"></span><strong>Note:</strong>This image/link points to a file on your computer and will not be accessible to others on the internet.</span>',STR_LINK_PROP_TITLE:"Link Options",STR_LINK_PROP_REMOVE:"Remove link from text",STR_LINK_NEW_WINDOW:"Open in a new window.",STR_LINK_TITLE:"Description",CLASS_LOCAL_FILE:"warning-localfile",CLASS_HIDDEN:"yui-hidden",init:function(F,E){this._windows={};this._defaultToolbar={collapse:true,titlebar:"Text Editing Tools",draggable:false,buttonType:"advanced",buttons:[{group:"fontstyle",label:"Font Name and Size",buttons:[{type:"select",label:"Arial",value:"fontname",disabled:true,menu:[{text:"Arial",checked:true},{text:"Arial Black"},{text:"Comic Sans MS"},{text:"Courier New"},{text:"Lucida Console"},{text:"Tahoma"},{text:"Times New Roman"},{text:"Trebuchet MS"},{text:"Verdana"}]},{type:"spin",label:"13",value:"fontsize",range:[9,75],disabled:true}]},{type:"separator"},{group:"textstyle",label:"Font Style",buttons:[{type:"push",label:"Bold CTRL + SHIFT + B",value:"bold"},{type:"push",label:"Italic CTRL + SHIFT + I",value:"italic"},{type:"push",label:"Underline CTRL + SHIFT + U",value:"underline"},{type:"separator"},{type:"push",label:"Subscript",value:"subscript",disabled:true},{type:"push",label:"Superscript",value:"superscript",disabled:true}]},{type:"separator"},{group:"textstyle2",label:" ",buttons:[{type:"color",label:"Font Color",value:"forecolor",disabled:true},{type:"color",label:"Background Color",value:"backcolor",disabled:true},{type:"separator"},{type:"push",label:"Remove Formatting",value:"removeformat",disabled:true},{type:"push",label:"Show/Hide Hidden Elements",value:"hiddenelements"}]},{type:"separator"},{group:"undoredo",label:"Undo/Redo",buttons:[{type:"push",label:"Undo",value:"undo",disabled:true},{type:"push",label:"Redo",value:"redo",disabled:true}]},{type:"separator"},{group:"alignment",label:"Alignment",buttons:[{type:"push",label:"Align Left CTRL + SHIFT + [",value:"justifyleft"},{type:"push",label:"Align Center CTRL + SHIFT + |",value:"justifycenter"},{type:"push",label:"Align Right CTRL + SHIFT + ]",value:"justifyright"},{type:"push",label:"Justify",value:"justifyfull"}]},{type:"separator"},{group:"parastyle",label:"Paragraph Style",buttons:[{type:"select",label:"Normal",value:"heading",disabled:true,menu:[{text:"Normal",value:"none",checked:true},{text:"Header 1",value:"h1"},{text:"Header 2",value:"h2"},{text:"Header 3",value:"h3"},{text:"Header 4",value:"h4"},{text:"Header 5",value:"h5"},{text:"Header 6",value:"h6"}]}]},{type:"separator"},{group:"indentlist2",label:"Indenting and Lists",buttons:[{type:"push",label:"Indent",value:"indent",disabled:true},{type:"push",label:"Outdent",value:"outdent",disabled:true},{type:"push",label:"Create an Unordered List",value:"insertunorderedlist"},{type:"push",label:"Create an Ordered List",value:"insertorderedlist"}]},{type:"separator"},{group:"insertitem",label:"Insert Item",buttons:[{type:"push",label:"HTML Link CTRL + SHIFT + L",value:"createlink",disabled:true},{type:"push",label:"Insert Image",value:"insertimage"}]}]};this._defaultImageToolbarConfig={buttonType:this._defaultToolbar.buttonType,buttons:[{group:"textflow",label:this.STR_IMAGE_TEXTFLOW+":",buttons:[{type:"push",label:"Left",value:"left"},{type:"push",label:"Inline",value:"inline"},{type:"push",label:"Block",value:"block"},{type:"push",label:"Right",value:"right"}]},{type:"separator"},{group:"padding",label:this.STR_IMAGE_PADDING+":",buttons:[{type:"spin",label:"0",value:"padding",range:[0,50]}]},{type:"separator"},{group:"border",label:this.STR_IMAGE_BORDER+":",buttons:[{type:"select",label:this.STR_IMAGE_BORDER_SIZE,value:"bordersize",menu:[{text:"none",value:"0",checked:true},{text:"1px",value:"1"},{text:"2px",value:"2"},{text:"3px",value:"3"},{text:"4px",value:"4"},{text:"5px",value:"5"}]},{type:"select",label:this.STR_IMAGE_BORDER_TYPE,value:"bordertype",disabled:true,menu:[{text:"Solid",value:"solid",checked:true},{text:"Dashed",value:"dashed"},{text:"Dotted",value:"dotted"}]},{type:"color",label:"Border Color",value:"bordercolor",disabled:true}]}]};
|
f[k](d)}else{if(e.collapsible&&f)a.toggle();else{b.hide();a.show()}j(true)}b.prev().attr({"aria-expanded":"false",tabIndex:-1}).blur();a.prev().attr({"aria-expanded":"true",tabIndex:0}).focus()},_completed:function(a){this.running=a?0:--this.running;if(!this.running){this.options.clearStyle&&this.toShow.add(this.toHide).css({height:"",overflow:""});this.toHide.removeClass("ui-accordion-content-active");this._trigger("change",null,this.data)}}});c.extend(c.ui.accordion,{version:"1.8.4",animations:{slide:function(a,
|
f[k](d)}else{if(e.collapsible&&f)a.toggle();else{b.hide();a.show()}j(true)}b.prev().attr({"aria-expanded":"false",tabIndex:-1}).blur();a.prev().attr({"aria-expanded":"true",tabIndex:0}).focus()},_completed:function(a){this.running=a?0:--this.running;if(!this.running){this.options.clearStyle&&this.toShow.add(this.toHide).css({height:"",overflow:""});this.toHide.removeClass("ui-accordion-content-active");this._trigger("change",null,this.data)}}});c.extend(c.ui.accordion,{version:"1.8.6",animations:{slide:function(a,
|
f[k](d)}else{if(e.collapsible&&f)a.toggle();else{b.hide();a.show()}j(true)}b.prev().attr({"aria-expanded":"false",tabIndex:-1}).blur();a.prev().attr({"aria-expanded":"true",tabIndex:0}).focus()},_completed:function(a){this.running=a?0:--this.running;if(!this.running){this.options.clearStyle&&this.toShow.add(this.toHide).css({height:"",overflow:""});this.toHide.removeClass("ui-accordion-content-active");this._trigger("change",null,this.data)}}});c.extend(c.ui.accordion,{version:"1.8.4",animations:{slide:function(a,
|
(function(d){d.widget("ui.sortable",d.ui.mouse,{widgetEventPrefix:"sort",options:{appendTo:"parent",axis:false,connectWith:false,containment:false,cursor:"auto",cursorAt:false,dropOnEmpty:true,forcePlaceholderSize:false,forceHelperSize:false,grid:false,handle:false,helper:"original",items:"> *",opacity:false,placeholder:false,revert:false,scroll:true,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1E3},_create:function(){this.containerCache={};this.element.addClass("ui-sortable"); this.refresh();this.floating=this.items.length?/left|right/.test(this.items[0].item.css("float")):false;this.offset=this.element.offset();this._mouseInit()},destroy:function(){this.element.removeClass("ui-sortable ui-sortable-disabled").removeData("sortable").unbind(".sortable");this._mouseDestroy();for(var a=this.items.length-1;a>=0;a--)this.items[a].item.removeData("sortable-item");return this},_setOption:function(a,b){if(a==="disabled"){this.options[a]=b;this.widget()[b?"addClass":"removeClass"]("ui-sortable-disabled")}else d.Widget.prototype._setOption.apply(this,
|
(function(c){c.widget("ui.accordion",{options:{active:0,animated:"slide",autoHeight:true,clearStyle:false,collapsible:false,event:"click",fillSpace:false,header:"> li > :first-child,> :not(li):even",icons:{header:"ui-icon-triangle-1-e",headerSelected:"ui-icon-triangle-1-s"},navigation:false,navigationFilter:function(){return this.href.toLowerCase()===location.href.toLowerCase()}},_create:function(){var a=this,b=a.options;a.running=0;a.element.addClass("ui-accordion ui-widget ui-helper-reset").children("li").addClass("ui-accordion-li-fix"); a.headers=a.element.find(b.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){b.disabled||c(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){b.disabled||c(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){b.disabled||c(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){b.disabled||c(this).removeClass("ui-state-focus")});a.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom"); if(b.navigation){var d=a.element.find("a").filter(b.navigationFilter).eq(0);if(d.length){var f=d.closest(".ui-accordion-header");a.active=f.length?f:d.closest(".ui-accordion-content").prev()}}a.active=a._findActive(a.active||b.active).addClass("ui-state-default ui-state-active").toggleClass("ui-corner-all").toggleClass("ui-corner-top");a.active.next().addClass("ui-accordion-content-active");a._createIcons();a.resize();a.element.attr("role","tablist");a.headers.attr("role","tab").bind("keydown.accordion", function(g){return a._keydown(g)}).next().attr("role","tabpanel");a.headers.not(a.active||"").attr({"aria-expanded":"false",tabIndex:-1}).next().hide();a.active.length?a.active.attr({"aria-expanded":"true",tabIndex:0}):a.headers.eq(0).attr("tabIndex",0);c.browser.safari||a.headers.find("a").attr("tabIndex",-1);b.event&&a.headers.bind(b.event.split(" ").join(".accordion ")+".accordion",function(g){a._clickHandler.call(a,g,this);g.preventDefault()})},_createIcons:function(){var a=this.options;if(a.icons){c("<span></span>").addClass("ui-icon "+
|
(function(d){d.widget("ui.sortable",d.ui.mouse,{widgetEventPrefix:"sort",options:{appendTo:"parent",axis:false,connectWith:false,containment:false,cursor:"auto",cursorAt:false,dropOnEmpty:true,forcePlaceholderSize:false,forceHelperSize:false,grid:false,handle:false,helper:"original",items:"> *",opacity:false,placeholder:false,revert:false,scroll:true,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1E3},_create:function(){this.containerCache={};this.element.addClass("ui-sortable");this.refresh();this.floating=this.items.length?/left|right/.test(this.items[0].item.css("float")):false;this.offset=this.element.offset();this._mouseInit()},destroy:function(){this.element.removeClass("ui-sortable ui-sortable-disabled").removeData("sortable").unbind(".sortable");this._mouseDestroy();for(var a=this.items.length-1;a>=0;a--)this.items[a].item.removeData("sortable-item");return this},_setOption:function(a,b){if(a==="disabled"){this.options[a]=b;this.widget()[b?"addClass":"removeClass"]("ui-sortable-disabled")}else d.Widget.prototype._setOption.apply(this,
|
a.moveToTop(true);b.modal&&d.bind("keypress.ui-dialog",function(f){if(f.keyCode===c.ui.keyCode.TAB){var g=c(":tabbable",this),e=g.filter(":first");g=g.filter(":last");if(f.target===g[0]&&!f.shiftKey){e.focus(1);return false}else if(f.target===e[0]&&f.shiftKey){g.focus(1);return false}}});c(a.element.find(":tabbable").get().concat(d.find(".ui-dialog-buttonpane :tabbable").get().concat(d.get()))).eq(0).focus();a._trigger("open");a._isOpen=true;return a}},_createButtons:function(a){var b=this,d=false, f=c("<div></div>").addClass("ui-dialog-buttonpane ui-widget-content ui-helper-clearfix"),g=c("<div></div>").addClass("ui-dialog-buttonset").appendTo(f);b.uiDialog.find(".ui-dialog-buttonpane").remove();typeof a==="object"&&a!==null&&c.each(a,function(){return!(d=true)});if(d){c.each(a,function(e,h){e=c('<button type="button"></button>').text(e).click(function(){h.apply(b.element[0],arguments)}).appendTo(g);c.fn.button&&e.button()});f.appendTo(b.uiDialog)}},_makeDraggable:function(){function a(e){return{position:e.position,
|
a._isOpen=true;a._trigger("open");return a}},_createButtons:function(a){var b=this,d=false,e=c("<div></div>").addClass("ui-dialog-buttonpane ui-widget-content ui-helper-clearfix"),g=c("<div></div>").addClass("ui-dialog-buttonset").appendTo(e);b.uiDialog.find(".ui-dialog-buttonpane").remove();typeof a==="object"&&a!==null&&c.each(a,function(){return!(d=true)});if(d){c.each(a,function(f,h){h=c.isFunction(h)?{click:h,text:f}:h;f=c('<button type="button"></button>').attr(h,true).unbind("click").click(function(){h.click.apply(b.element[0], arguments)}).appendTo(g);c.fn.button&&f.button()});e.appendTo(b.uiDialog)}},_makeDraggable:function(){function a(f){return{position:f.position,offset:f.offset}}var b=this,d=b.options,e=c(document),g;b.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close",handle:".ui-dialog-titlebar",containment:"document",start:function(f,h){g=d.height==="auto"?"auto":c(this).height();c(this).height(c(this).height()).addClass("ui-dialog-dragging");b._trigger("dragStart",f,a(h))},drag:function(f,
|
a.moveToTop(true);b.modal&&d.bind("keypress.ui-dialog",function(f){if(f.keyCode===c.ui.keyCode.TAB){var g=c(":tabbable",this),e=g.filter(":first");g=g.filter(":last");if(f.target===g[0]&&!f.shiftKey){e.focus(1);return false}else if(f.target===e[0]&&f.shiftKey){g.focus(1);return false}}});c(a.element.find(":tabbable").get().concat(d.find(".ui-dialog-buttonpane :tabbable").get().concat(d.get()))).eq(0).focus();a._trigger("open");a._isOpen=true;return a}},_createButtons:function(a){var b=this,d=false,f=c("<div></div>").addClass("ui-dialog-buttonpane ui-widget-content ui-helper-clearfix"),g=c("<div></div>").addClass("ui-dialog-buttonset").appendTo(f);b.uiDialog.find(".ui-dialog-buttonpane").remove();typeof a==="object"&&a!==null&&c.each(a,function(){return!(d=true)});if(d){c.each(a,function(e,h){e=c('<button type="button"></button>').text(e).click(function(){h.apply(b.element[0],arguments)}).appendTo(g);c.fn.button&&e.button()});f.appendTo(b.uiDialog)}},_makeDraggable:function(){function a(e){return{position:e.position,
|
F.setAttribute("src",J);YAHOO.util.Dom.addClass(F,"yui-img");this.currentElement[0].parentNode.replaceChild(F,this.currentElement[0]);}this.currentElement[0]=F;E=false;}}return[E];},cmd_inserthtml:function(H){var E=true,G="inserthtml",F=null,I=null;if(this.browser.webkit&&!this._getDoc().queryCommandEnabled(G)){this._createCurrentElement("img");F=this._getDoc().createElement("span");F.innerHTML=H;this.currentElement[0].parentNode.replaceChild(F,this.currentElement[0]);E=false;}else{if(this.browser.ie){I=this._getRange();if(I.item){I.item(0).outerHTML=H;}else{I.pasteHTML(H);}E=false;}}return[E];},cmd_list:function(Y){var S=true,V=null,M=0,G=null,R="",W=this._getSelectedElement(),T="insertorderedlist";if(Y=="ul"){T="insertunorderedlist";}if(this.browser.webkit){if(this._isElement(W,"li")&&this._isElement(W.parentNode,Y)){G=W.parentNode;V=this._getDoc().createElement("span");YAHOO.util.Dom.addClass(V,"yui-non");R="";var F=G.getElementsByTagName("li");for(M=0;M<F.length;M++){R+="<div>"+F[M].innerHTML+"</div>";}V.innerHTML=R;this.currentElement[0]=G;this.currentElement[0].parentNode.replaceChild(V,this.currentElement[0]);}else{this._createCurrentElement(Y.toLowerCase());V=this._getDoc().createElement(Y);for(M=0;M<this.currentElement.length;M++){var J=this._getDoc().createElement("li");J.innerHTML=this.currentElement[M].innerHTML+'<span class="yui-non"> </span> ';V.appendChild(J);if(M>0){this.currentElement[M].parentNode.removeChild(this.currentElement[M]);}}this.currentElement[0].parentNode.replaceChild(V,this.currentElement[0]);this.currentElement[0]=V;var H=this.currentElement[0].firstChild;H=C.getElementsByClassName("yui-non","span",H)[0];this._getSelection().setBaseAndExtent(H,1,H,H.innerText.length);}S=false;}else{G=this._getSelectedElement();if(this._isElement(G,"li")&&this._isElement(G.parentNode,Y)||(this.browser.ie&&this._isElement(this._getRange().parentElement,"li"))||(this.browser.ie&&this._isElement(G,"ul"))||(this.browser.ie&&this._isElement(G,"ol"))){if(this.browser.ie){if((this.browser.ie&&this._isElement(G,"ul"))||(this.browser.ie&&this._isElement(G,"ol"))){G=G.getElementsByTagName("li")[0];}R="";var I=G.parentNode.getElementsByTagName("li");for(var U=0;U<I.length;U++){R+=I[U].innerHTML+"<br>";}var X=this._getDoc().createElement("span");X.innerHTML=R;G.parentNode.parentNode.replaceChild(X,G.parentNode);}else{this.nodeChange();this._getDoc().execCommand(T,"",G.parentNode);this.nodeChange();}S=false;}if(this.browser.opera){var Q=this;window.setTimeout(function(){var Z=Q._getDoc().getElementsByTagName("li");for(var a=0;a<Z.length;a++){if(Z[a].innerHTML.toLowerCase()=="<br>"){Z[a].parentNode.parentNode.removeChild(Z[a].parentNode);}}},30);}if(this.browser.ie&&S){var K="";if(this._getRange().html){K="<li>"+this._getRange().html+"</li>";}else{var L=this._getRange().text.split("\n");if(L.length>1){K="";for(var P=0;P<L.length;P++){K+="<li>"+L[P]+"</li>";}}else{var O=this._getRange().text;if(O===""){K='<li id="new_list_item">'+O+"</li>";}else{K="<li>"+O+"</li>";}}}this._getRange().pasteHTML("<"+Y+">"+K+"</"+Y+">");var E=this._getDoc().getElementById("new_list_item");if(E){var N=this._getDoc().body.createTextRange();N.moveToElementText(E);N.collapse(false);N.select();E.id="";}S=false;}}return S;},cmd_insertorderedlist:function(E){return[this.cmd_list("ol")];},cmd_insertunorderedlist:function(E){return[this.cmd_list("ul")];},cmd_fontname:function(H){var E=true,G=this._getSelectedElement();this.currentFont=H;if(G&&G.tagName&&!this._hasSelection()&&!this._isElement(G,"body")&&!this.get("insert")){YAHOO.util.Dom.setStyle(G,"font-family",H);E=false;}else{if(this.get("insert")&&!this._hasSelection()){var F=this._createInsertElement({fontFamily:H});E=false;}}return[E];},cmd_fontsize:function(G){var E=null;if(this.currentElement&&(this.currentElement.length>0)&&(!this._hasSelection())&&(!this.get("insert"))){YAHOO.util.Dom.setStyle(this.currentElement,"fontSize",G);}else{if(!this._isElement(this._getSelectedElement(),"body")){E=this._getSelectedElement();YAHOO.util.Dom.setStyle(E,"fontSize",G);if(this.get("insert")&&this.browser.ie){var F=this._getRange();F.collapse(false);F.select();}else{this._selectNode(E);}}else{if(this.get("insert")&&!this._hasSelection()){E=this._createInsertElement({fontSize:G});this.currentElement[0]=E;this._selectNode(this.currentElement[0]);}else{this._createCurrentElement("span",{"fontSize":G});this._selectNode(this.currentElement[0]);}}}return[false];},_swapEl:function(F,E,H){var G=this._getDoc().createElement(E);if(F){G.innerHTML=F.innerHTML;}if(typeof H=="function"){H.call(this,G);}if(F){F.parentNode.replaceChild(G,F);}return G;},_createInsertElement:function(E){this._createCurrentElement("span",E);var F=this.currentElement[0];if(this.browser.webkit){F.innerHTML='<span class="yui-non"> </span>';F=F.firstChild;this._getSelection().setBaseAndExtent(F,1,F,F.innerText.length);}else{if(this.browser.ie||this.browser.opera){F.innerHTML=" ";}}this._focusWindow();this._selectNode(F,true);return F;},_createCurrentElement:function(G,J){G=((G)?G:"a");var R=null,F=[],H=this._getDoc();if(this.currentFont){if(!J){J={};}J.fontFamily=this.currentFont;this.currentFont=null;}this.currentElement=[];var M=function(X,Z){var Y=null;X=((X)?X:"span");X=X.toLowerCase();switch(X){case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":Y=H.createElement(X);break;default:Y=H.createElement(X);if(X==="span"){YAHOO.util.Dom.addClass(Y,"yui-tag-"+X);YAHOO.util.Dom.addClass(Y,"yui-tag");Y.setAttribute("tag",X);}for(var W in Z){if(YAHOO.lang.hasOwnProperty(Z,W)){Y.style[W]=Z[W];}}break;}return Y;};if(!this._hasSelection()){if(this._getDoc().queryCommandEnabled("insertimage")){this._getDoc().execCommand("insertimage",false,"yui-tmp-img");var L=this._getDoc().getElementsByTagName("img");for(var Q=0;Q<L.length;Q++){if(L[Q].getAttribute("src",2)=="yui-tmp-img"){F=M(G,J);L[Q].parentNode.replaceChild(F,L[Q]);this.currentElement[this.currentElement.length]=F;}}}else{if(this.currentEvent){R=YAHOO.util.Event.getTarget(this.currentEvent); }else{R=this._getDoc().body;}}if(R){F=M(G,J);if(this._isElement(R,"body")||this._isElement(R,"html")){if(this._isElement(R,"html")){R=this._getDoc().body;}R.appendChild(F);}else{if(R.nextSibling){R.parentNode.insertBefore(F,R.nextSibling);}else{R.parentNode.appendChild(F);}}this.currentElement[this.currentElement.length]=F;this.currentEvent=null;if(this.browser.webkit){this._getSelection().setBaseAndExtent(F,0,F,0);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(true);}}}}else{this._setEditorStyle(true);this._getDoc().execCommand("fontname",false,"yui-tmp");var E=[],P,V=["font","span","i","b","u"];if(!this._isElement(this._getSelectedElement(),"body")){V[V.length]=this._getDoc().getElementsByTagName(this._getSelectedElement().tagName);V[V.length]=this._getDoc().getElementsByTagName(this._getSelectedElement().parentNode.tagName);}for(var K=0;K<V.length;K++){var I=this._getDoc().getElementsByTagName(V[K]);for(var U=0;U<I.length;U++){E[E.length]=I[U];}}for(var S=0;S<E.length;S++){if((YAHOO.util.Dom.getStyle(E[S],"font-family")=="yui-tmp")||(E[S].face&&(E[S].face=="yui-tmp"))){F=M(G,J);F.innerHTML=E[S].innerHTML;if(this._isElement(E[S],"ol")||(this._isElement(E[S],"ul"))){var N=E[S].getElementsByTagName("li")[0];E[S].style.fontFamily="inherit";N.style.fontFamily="inherit";F.innerHTML=N.innerHTML;N.innerHTML="";N.appendChild(F);this.currentElement[this.currentElement.length]=F;}else{if(this._isElement(E[S],"li")){E[S].innerHTML="";E[S].appendChild(F);E[S].style.fontFamily="inherit";this.currentElement[this.currentElement.length]=F;}else{if(E[S].parentNode){E[S].parentNode.replaceChild(F,E[S]);this.currentElement[this.currentElement.length]=F;this.currentEvent=null;if(this.browser.webkit){this._getSelection().setBaseAndExtent(F,0,F,0);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(true);}}if(this.browser.ie&&J&&J.fontSize){this._getSelection().empty();}if(this.browser.gecko){this._getSelection().collapseToStart();}}}}}}var T=this.currentElement.length;for(var O=0;O<T;O++){if((O+1)!=T){if(this.currentElement[O]&&this.currentElement[O].nextSibling){if(this._isElement(this.currentElement[O],"br")){this.currentElement[this.currentElement.length]=this.currentElement[O].nextSibling;}}}}}},saveHTML:function(){var F=this.cleanHTML();if(this._textarea){this.get("element").value=F;}else{this.get("element").innerHTML=F;}if(this.get("saveEl")!==this.get("element")){var E=this.get("saveEl");if(D.isString(E)){E=C.get(E);}if(E){if(E.tagName.toLowerCase()==="textarea"){E.value=F;}else{E.innerHTML=F;}}}return F;},setEditorHTML:function(F){var E=this._cleanIncomingHTML(F);this._getDoc().body.innerHTML=E;this.nodeChange();},getEditorHTML:function(){var E=this._getDoc().body;if(E===null){return null;}return this._getDoc().body.innerHTML;},show:function(){if(this.browser.gecko){this._setDesignMode("on");this._focusWindow();}if(this.browser.webkit){var E=this;window.setTimeout(function(){E._setInitialContent.call(E);},10);}if(this.currentWindow){this.closeWindow();}this.get("iframe").setStyle("position","static");this.get("iframe").setStyle("left","");},hide:function(){if(this.currentWindow){this.closeWindow();}if(this._fixNodesTimer){clearTimeout(this._fixNodesTimer);this._fixNodesTimer=null;}if(this._nodeChangeTimer){clearTimeout(this._nodeChangeTimer);this._nodeChangeTimer=null;}this._lastNodeChange=0;this.get("iframe").setStyle("position","absolute");this.get("iframe").setStyle("left","-9999px");},_cleanIncomingHTML:function(E){E=E.replace(/<strong([^>]*)>/gi,"<b$1>");E=E.replace(/<\/strong>/gi,"</b>");E=E.replace(/<embed([^>]*)>/gi,"<YUI_EMBED$1>");E=E.replace(/<\/embed>/gi,"</YUI_EMBED>");E=E.replace(/<em([^>]*)>/gi,"<i$1>");E=E.replace(/<\/em>/gi,"</i>");E=E.replace(/<YUI_EMBED([^>]*)>/gi,"<embed$1>");E=E.replace(/<\/YUI_EMBED>/gi,"</embed>");if(this.get("plainText")){E=E.replace(/\n/g,"<br>").replace(/\r/g,"<br>");E=E.replace(/ /gi," ");E=E.replace(/\t/gi," ");}E=E.replace(/<script([^>]*)>/gi,"<bad>");E=E.replace(/<\/script([^>]*)>/gi,"</bad>");E=E.replace(/<script([^>]*)>/gi,"<bad>");E=E.replace(/<\/script([^>]*)>/gi,"</bad>");E=E.replace(/\n/g,"<YUI_LF>").replace(/\r/g,"<YUI_LF>");E=E.replace(new RegExp("<bad([^>]*)>(.*?)</bad>","gi"),"");E=E.replace(/<YUI_LF>/g,"\n");return E;},cleanHTML:function(G){if(!G){G=this.getEditorHTML();}var F=this.get("markup");G=this.pre_filter_linebreaks(G,F);G=G.replace(/<img([^>]*)\/>/gi,"<YUI_IMG$1>");G=G.replace(/<img([^>]*)>/gi,"<YUI_IMG$1>");G=G.replace(/<input([^>]*)\/>/gi,"<YUI_INPUT$1>");G=G.replace(/<input([^>]*)>/gi,"<YUI_INPUT$1>");G=G.replace(/<ul([^>]*)>/gi,"<YUI_UL$1>");G=G.replace(/<\/ul>/gi,"</YUI_UL>");G=G.replace(/<blockquote([^>]*)>/gi,"<YUI_BQ$1>");G=G.replace(/<\/blockquote>/gi,"</YUI_BQ>");G=G.replace(/<embed([^>]*)>/gi,"<YUI_EMBED$1>");G=G.replace(/<\/embed>/gi,"</YUI_EMBED>");if((F=="semantic")||(F=="xhtml")){G=G.replace(/<i(\s+[^>]*)?>/gi,"<em$1>");G=G.replace(/<\/i>/gi,"</em>");G=G.replace(/<b(\s+[^>]*)?>/gi,"<strong$1>");G=G.replace(/<\/b>/gi,"</strong>");}G=G.replace(/<font/gi,"<font");G=G.replace(/<\/font>/gi,"</font>");G=G.replace(/<span/gi,"<span");G=G.replace(/<\/span>/gi,"</span>");if((F=="semantic")||(F=="xhtml")||(F=="css")){G=G.replace(new RegExp('<font([^>]*)face="([^>]*)">(.*?)</font>',"gi"),'<span $1 style="font-family: $2;">$3</span>');G=G.replace(/<u/gi,'<span style="text-decoration: underline;"');if(this.browser.webkit){G=G.replace(new RegExp('<span class="Apple-style-span" style="font-weight: bold;">([^>]*)</span>',"gi"),"<strong>$1</strong>");G=G.replace(new RegExp('<span class="Apple-style-span" style="font-style: italic;">([^>]*)</span>',"gi"),"<em>$1</em>");}G=G.replace(/\/u>/gi,"/span>");if(F=="css"){G=G.replace(/<em([^>]*)>/gi,"<i$1>");G=G.replace(/<\/em>/gi,"</i>");G=G.replace(/<strong([^>]*)>/gi,"<b$1>");G=G.replace(/<\/strong>/gi,"</b>");G=G.replace(/<b/gi,'<span style="font-weight: bold;"');
|
(function(){var b=YAHOO.util.Dom,a=YAHOO.util.Event,c=YAHOO.lang;if(YAHOO.widget.Button){YAHOO.widget.ToolbarButtonAdvanced=YAHOO.widget.Button;YAHOO.widget.ToolbarButtonAdvanced.prototype.buttonType="rich";YAHOO.widget.ToolbarButtonAdvanced.prototype.checkValue=function(f){var e=this.getMenu().getItems();if(e.length===0){this.getMenu()._onBeforeShow();e=this.getMenu().getItems()}for(var d=0;d<e.length;d++){e[d].cfg.setProperty("checked",false);if(e[d].value==f){e[d].cfg.setProperty("checked",true)}}}}else{YAHOO.widget.ToolbarButtonAdvanced=function(){}}YAHOO.widget.ToolbarButton=function(e,d){if(c.isObject(arguments[0])&&!b.get(e).nodeType){d=e}var g=(d||{});var f={element:null,attributes:g};if(!f.attributes.type){f.attributes.type="push"}f.element=document.createElement("span");f.element.setAttribute("unselectable","on");f.element.className="yui-button yui-"+f.attributes.type+"-button";f.element.innerHTML='<span class="first-child"><a href="#">LABEL</a></span>';f.element.firstChild.firstChild.tabIndex="-1";f.attributes.id=b.generateId();YAHOO.widget.ToolbarButton.superclass.constructor.call(this,f.element,f.attributes)};YAHOO.extend(YAHOO.widget.ToolbarButton,YAHOO.util.Element,{buttonType:"normal",_handleMouseOver:function(){if(!this.get("disabled")){this.addClass("yui-button-hover");this.addClass("yui-"+this.get("type")+"-button-hover")}},_handleMouseOut:function(){this.removeClass("yui-button-hover");this.removeClass("yui-"+this.get("type")+"-button-hover")},checkValue:function(f){if(this.get("type")=="menu"){var e=this._button.options;for(var d=0;d<e.length;d++){if(e[d].value==f){e.selectedIndex=d}}}},init:function(e,d){YAHOO.widget.ToolbarButton.superclass.init.call(this,e,d);this.on("mouseover",this._handleMouseOver,this,true);this.on("mouseout",this._handleMouseOut,this,true)},initAttributes:function(d){YAHOO.widget.ToolbarButton.superclass.initAttributes.call(this,d);this.setAttributeConfig("value",{value:d.value});this.setAttributeConfig("menu",{value:d.menu||false});this.setAttributeConfig("type",{value:d.type,writeOnce:true,method:function(h){var g,f;if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}switch(h){case"select":case"menu":g=document.createElement("select");var j=this.get("menu");for(var e=0;e<j.length;e++){f=document.createElement("option");f.innerHTML=j[e].text;f.value=j[e].value;if(j[e].checked){f.selected=true}g.appendChild(f)}this._button.parentNode.replaceChild(g,this._button);a.on(g,"change",this._handleSelect,this,true);this._button=g;break}}});this.setAttributeConfig("disabled",{value:d.disabled||false,method:function(e){if(e){this.addClass("yui-button-disabled");this.addClass("yui-"+this.get("type")+"-button-disabled")}else{this.removeClass("yui-button-disabled");this.removeClass("yui-"+this.get("type")+"-button-disabled")}if(this.get("type")=="menu"){this._button.disabled=e}}});this.setAttributeConfig("label",{value:d.label,method:function(e){if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}if(this.get("type")=="push"){this._button.innerHTML=e}}});this.setAttributeConfig("title",{value:d.title});this.setAttributeConfig("container",{value:null,writeOnce:true,method:function(e){this.appendTo(e)}})},_handleSelect:function(e){var d=a.getTarget(e);var f=d.options[d.selectedIndex].value;this.fireEvent("change",{type:"change",value:f})},getMenu:function(){return this.get("menu")},destroy:function(){a.purgeElement(this.get("element"),true);this.get("element").parentNode.removeChild(this.get("element"));for(var d in this){if(c.hasOwnProperty(this,d)){this[d]=null}}},fireEvent:function(e,d){if(this.DOM_EVENTS[e]&&this.get("disabled")){return}YAHOO.widget.ToolbarButton.superclass.fireEvent.call(this,e,d)},toString:function(){return"ToolbarButton ("+this.get("id")+")"}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang;var b=function(f){var e=f;if(d.isString(f)){e=this.getButtonById(f)}if(d.isNumber(f)){e=this.getButtonByIndex(f)}if((!(e instanceof YAHOO.widget.ToolbarButton))&&(!(e instanceof YAHOO.widget.ToolbarButtonAdvanced))){e=this.getButtonByValue(f)}if((e instanceof YAHOO.widget.ToolbarButton)||(e instanceof YAHOO.widget.ToolbarButtonAdvanced)){return e}return false};YAHOO.widget.Toolbar=function(i,h){if(d.isObject(arguments[0])&&!c.get(i).nodeType){h=i}var k={};if(h){d.augmentObject(k,h)}var j={element:null,attributes:k};if(d.isString(i)&&c.get(i)){j.element=c.get(i)}else{if(d.isObject(i)&&c.get(i)&&c.get(i).nodeType){j.element=c.get(i)}}if(!j.element){j.element=document.createElement("DIV");j.element.id=c.generateId();if(k.container&&c.get(k.container)){c.get(k.container).appendChild(j.element)}}if(!j.element.id){j.element.id=((d.isString(i))?i:c.generateId())}var f=document.createElement("fieldset");var g=document.createElement("legend");g.innerHTML="Toolbar";f.appendChild(g);var e=document.createElement("DIV");j.attributes.cont=e;c.addClass(e,"yui-toolbar-subcont");f.appendChild(e);j.element.appendChild(f);j.element.tabIndex=-1;j.attributes.element=j.element;j.attributes.id=j.element.id;YAHOO.widget.Toolbar.superclass.constructor.call(this,j.element,j.attributes)};YAHOO.extend(YAHOO.widget.Toolbar,YAHOO.util.Element,{_addMenuClasses:function(h,e,j){c.addClass(this.element,"yui-toolbar-"+j.get("value")+"-menu");if(c.hasClass(j._button.parentNode.parentNode,"yui-toolbar-select")){c.addClass(this.element,"yui-toolbar-select-menu")}var f=this.getItems();for(var g=0;g<f.length;g++){c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-").toLowerCase():f[g]._oText.nodeValue.replace(/ /g,"-").toLowerCase()));c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-"):f[g]._oText.nodeValue.replace(/ /g,"-")))}},buttonType:YAHOO.widget.ToolbarButton,dd:null,_colorData:{"#111111":"Obsidian","#2D2D2D":"Dark Gray","#434343":"Shale","#5B5B5B":"Flint","#737373":"Gray","#8B8B8B":"Concrete","#A2A2A2":"Gray","#B9B9B9":"Titanium","#000000":"Black","#D0D0D0":"Light Gray","#E6E6E6":"Silver","#FFFFFF":"White","#BFBF00":"Pumpkin","#FFFF00":"Yellow","#FFFF40":"Banana","#FFFF80":"Pale Yellow","#FFFFBF":"Butter","#525330":"Raw Siena","#898A49":"Mildew","#AEA945":"Olive","#7F7F00":"Paprika","#C3BE71":"Earth","#E0DCAA":"Khaki","#FCFAE1":"Cream","#60BF00":"Cactus","#80FF00":"Chartreuse","#A0FF40":"Green","#C0FF80":"Pale Lime","#DFFFBF":"Light Mint","#3B5738":"Green","#668F5A":"Lime Gray","#7F9757":"Yellow","#407F00":"Clover","#8A9B55":"Pistachio","#B7C296":"Light Jade","#E6EBD5":"Breakwater","#00BF00":"Spring Frost","#00FF80":"Pastel Green","#40FFA0":"Light Emerald","#80FFC0":"Sea Foam","#BFFFDF":"Sea Mist","#033D21":"Dark Forrest","#438059":"Moss","#7FA37C":"Medium Green","#007F40":"Pine","#8DAE94":"Yellow Gray Green","#ACC6B5":"Aqua Lung","#DDEBE2":"Sea Vapor","#00BFBF":"Fog","#00FFFF":"Cyan","#40FFFF":"Turquoise Blue","#80FFFF":"Light Aqua","#BFFFFF":"Pale Cyan","#033D3D":"Dark Teal","#347D7E":"Gray Turquoise","#609A9F":"Green Blue","#007F7F":"Seaweed","#96BDC4":"Green Gray","#B5D1D7":"Soapstone","#E2F1F4":"Light Turquoise","#0060BF":"Summer Sky","#0080FF":"Sky Blue","#40A0FF":"Electric Blue","#80C0FF":"Light Azure","#BFDFFF":"Ice Blue","#1B2C48":"Navy","#385376":"Biscay","#57708F":"Dusty Blue","#00407F":"Sea Blue","#7792AC":"Sky Blue Gray","#A8BED1":"Morning Sky","#DEEBF6":"Vapor","#0000BF":"Deep Blue","#0000FF":"Blue","#4040FF":"Cerulean Blue","#8080FF":"Evening Blue","#BFBFFF":"Light Blue","#212143":"Deep Indigo","#373E68":"Sea Blue","#444F75":"Night Blue","#00007F":"Indigo Blue","#585E82":"Dockside","#8687A4":"Blue Gray","#D2D1E1":"Light Blue Gray","#6000BF":"Neon Violet","#8000FF":"Blue Violet","#A040FF":"Violet Purple","#C080FF":"Violet Dusk","#DFBFFF":"Pale Lavender","#302449":"Cool Shale","#54466F":"Dark Indigo","#655A7F":"Dark Violet","#40007F":"Violet","#726284":"Smoky Violet","#9E8FA9":"Slate Gray","#DCD1DF":"Violet White","#BF00BF":"Royal Violet","#FF00FF":"Fuchsia","#FF40FF":"Magenta","#FF80FF":"Orchid","#FFBFFF":"Pale Magenta","#4A234A":"Dark Purple","#794A72":"Medium Purple","#936386":"Cool Granite","#7F007F":"Purple","#9D7292":"Purple Moon","#C0A0B6":"Pale Purple","#ECDAE5":"Pink Cloud","#BF005F":"Hot Pink","#FF007F":"Deep Pink","#FF409F":"Grape","#FF80BF":"Electric Pink","#FFBFDF":"Pink","#451528":"Purple Red","#823857":"Purple Dino","#A94A76":"Purple Gray","#7F003F":"Rose","#BC6F95":"Antique Mauve","#D8A5BB":"Cool Marble","#F7DDE9":"Pink Granite","#C00000":"Apple","#FF0000":"Fire Truck","#FF4040":"Pale Red","#FF8080":"Salmon","#FFC0C0":"Warm Pink","#441415":"Sepia","#82393C":"Rust","#AA4D4E":"Brick","#800000":"Brick Red","#BC6E6E":"Mauve","#D8A3A4":"Shrimp Pink","#F8DDDD":"Shell Pink","#BF5F00":"Dark Orange","#FF7F00":"Orange","#FF9F40":"Grapefruit","#FFBF80":"Canteloupe","#FFDFBF":"Wax","#482C1B":"Dark Brick","#855A40":"Dirt","#B27C51":"Tan","#7F3F00":"Nutmeg","#C49B71":"Mustard","#E1C4A8":"Pale Tan","#FDEEE0":"Marble"},_colorPicker:null,STR_COLLAPSE:"Collapse Toolbar",STR_SPIN_LABEL:"Spin Button with value {VALUE}. Use Control Shift Up Arrow and Control Shift Down arrow keys to increase or decrease the value.",STR_SPIN_UP:"Click to increase the value of this input",STR_SPIN_DOWN:"Click to decrease the value of this input",_titlebar:null,browser:YAHOO.env.ua,_buttonList:null,_buttonGroupList:null,_sep:null,_sepCount:null,_dragHandle:null,_toolbarConfigs:{renderer:true},CLASS_CONTAINER:"yui-toolbar-container",CLASS_DRAGHANDLE:"yui-toolbar-draghandle",CLASS_SEPARATOR:"yui-toolbar-separator",CLASS_DISABLED:"yui-toolbar-disabled",CLASS_PREFIX:"yui-toolbar",init:function(f,e){YAHOO.widget.Toolbar.superclass.init.call(this,f,e)},initAttributes:function(e){YAHOO.widget.Toolbar.superclass.initAttributes.call(this,e);this.addClass(this.CLASS_CONTAINER);this.setAttributeConfig("buttonType",{value:e.buttonType||"basic",writeOnce:true,validator:function(f){switch(f){case"advanced":case"basic":return true}return false},method:function(f){if(f=="advanced"){if(YAHOO.widget.Button){this.buttonType=YAHOO.widget.ToolbarButtonAdvanced}else{this.buttonType=YAHOO.widget.ToolbarButton}}else{this.buttonType=YAHOO.widget.ToolbarButton}}});this.setAttributeConfig("buttons",{value:[],writeOnce:true,method:function(g){for(var f in g){if(d.hasOwnProperty(g,f)){if(g[f].type=="separator"){this.addSeparator()}else{if(g[f].group!==undefined){this.addButtonGroup(g[f])}else{this.addButton(g[f])}}}}}});this.setAttributeConfig("disabled",{value:false,method:function(f){if(this.get("disabled")===f){return false}if(f){this.addClass(this.CLASS_DISABLED);this.set("draggable",false);this.disableAllButtons()}else{this.removeClass(this.CLASS_DISABLED);if(this._configs.draggable._initialConfig.value){this.set("draggable",true)}this.resetAllButtons()}}});this.setAttributeConfig("cont",{value:e.cont,readOnly:true});this.setAttributeConfig("grouplabels",{value:((e.grouplabels===false)?false:true),method:function(f){if(f){c.removeClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}else{c.addClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}}});this.setAttributeConfig("titlebar",{value:false,method:function(g){if(g){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}this._titlebar=document.createElement("DIV");this._titlebar.tabIndex="-1";a.on(this._titlebar,"focus",function(){this._handleFocus()},this,true);c.addClass(this._titlebar,this.CLASS_PREFIX+"-titlebar");if(d.isString(g)){var f=document.createElement("h2");f.tabIndex="-1";f.innerHTML='<a href="#" tabIndex="0">'+g+"</a>";this._titlebar.appendChild(f);a.on(f.firstChild,"click",function(h){a.stopEvent(h)});a.on([f,f.firstChild],"focus",function(){this._handleFocus()},this,true)}if(this.get("firstChild")){this.insertBefore(this._titlebar,this.get("firstChild"))}else{this.appendChild(this._titlebar)}if(this.get("collapse")){this.set("collapse",true)}}else{if(this._titlebar){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}}}}});this.setAttributeConfig("collapse",{value:false,method:function(h){if(this._titlebar){var g=null;var f=c.getElementsByClassName("collapse","span",this._titlebar);if(h){if(f.length>0){return true}g=document.createElement("SPAN");g.innerHTML="X";g.title=this.STR_COLLAPSE;c.addClass(g,"collapse");this._titlebar.appendChild(g);a.addListener(g,"click",function(){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}else{this.collapse()}},this,true)}else{g=c.getElementsByClassName("collapse","span",this._titlebar);if(g[0]){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}g[0].parentNode.removeChild(g[0])}}}}});this.setAttributeConfig("draggable",{value:(e.draggable||false),method:function(f){if(f&&!this.get("titlebar")){if(!this._dragHandle){this._dragHandle=document.createElement("SPAN");this._dragHandle.innerHTML="|";this._dragHandle.setAttribute("title","Click to drag the toolbar");this._dragHandle.id=this.get("id")+"_draghandle";c.addClass(this._dragHandle,this.CLASS_DRAGHANDLE);if(this.get("cont").hasChildNodes()){this.get("cont").insertBefore(this._dragHandle,this.get("cont").firstChild)}else{this.get("cont").appendChild(this._dragHandle)}this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._dragHandle.id)}}else{if(this._dragHandle){this._dragHandle.parentNode.removeChild(this._dragHandle);this._dragHandle=null;this.dd=null}}if(this._titlebar){if(f){this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._titlebar);c.addClass(this._titlebar,"draggable")}else{c.removeClass(this._titlebar,"draggable");if(this.dd){this.dd.unreg();this.dd=null}}}},validator:function(g){var f=true;if(!YAHOO.util.DD){f=false}return f}})},addButtonGroup:function(j){if(!this.get("element")){this._queue[this._queue.length]=["addButtonGroup",arguments];return false}if(!this.hasClass(this.CLASS_PREFIX+"-grouped")){this.addClass(this.CLASS_PREFIX+"-grouped")}var k=document.createElement("DIV");c.addClass(k,this.CLASS_PREFIX+"-group");c.addClass(k,this.CLASS_PREFIX+"-group-"+j.group);if(j.label){var f=document.createElement("h3");f.innerHTML=j.label;k.appendChild(f)}if(!this.get("grouplabels")){c.addClass(this.get("cont"),this.CLASS_PREFIX,"-nogrouplabels")}this.get("cont").appendChild(k);var h=document.createElement("ul");k.appendChild(h);if(!this._buttonGroupList){this._buttonGroupList={}}this._buttonGroupList[j.group]=h;for(var g=0;g<j.buttons.length;g++){var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";h.appendChild(e);if((j.buttons[g].type!==undefined)&&j.buttons[g].type=="separator"){this.addSeparator(e)}else{j.buttons[g].container=e;this.addButton(j.buttons[g])}}},addButtonToGroup:function(g,h,i){var f=this._buttonGroupList[h];var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";g.container=e;this.addButton(g,i);f.appendChild(e)},addButton:function(k,j){if(!this.get("element")){this._queue[this._queue.length]=["addButton",arguments];return false}if(!this._buttonList){this._buttonList=[]}if(!k.container){k.container=this.get("cont")}if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){for(var s in k.menu){if(d.hasOwnProperty(k.menu,s)){var y={fn:function(o,i,m){if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue)},scope:this};k.menu[s].onclick=y}}}}var t={},q=false;for(var n in k){if(d.hasOwnProperty(k,n)){if(!this._toolbarConfigs[n]){t[n]=k[n]}}}if(k.type=="select"){t.type="menu"}if(k.type=="spin"){t.type="push"}if(t.type=="color"){if(YAHOO.widget.Overlay){t=this._makeColorButton(t)}else{q=true}}if(t.menu){if((YAHOO.widget.Overlay)&&(k.menu instanceof YAHOO.widget.Overlay)){k.menu.showEvent.subscribe(function(){this._button=t})}else{for(var r=0;r<t.menu.length;r++){if(!t.menu[r].value){t.menu[r].value=t.menu[r].text}}if(this.browser.webkit){t.focusmenu=false}}}if(q){k=false}else{this._configs.buttons.value[this._configs.buttons.value.length]=k;var w=new this.buttonType(t);w.get("element").tabIndex="-1";w.get("element").setAttribute("role","button");w._selected=true;if(this.get("disabled")){w.set("disabled",true)}if(!k.id){k.id=w.get("id")}if(j){var f=w.get("element");var p=null;if(j.get){p=j.get("element").nextSibling}else{if(j.nextSibling){p=j.nextSibling}}if(p){p.parentNode.insertBefore(f,p)}}w.addClass(this.CLASS_PREFIX+"-"+w.get("value"));var v=document.createElement("span");v.className=this.CLASS_PREFIX+"-icon";w.get("element").insertBefore(v,w.get("firstChild"));if(w._button.tagName.toLowerCase()=="button"){w.get("element").setAttribute("unselectable","on");var x=document.createElement("a");x.innerHTML=w._button.innerHTML;x.href="#";x.tabIndex="-1";a.on(x,"click",function(i){a.stopEvent(i)});w._button.parentNode.replaceChild(x,w._button);w._button=x}if(k.type=="select"){if(w._button.tagName.toLowerCase()=="select"){v.parentNode.removeChild(v);var g=w._button;var u=w.get("element");u.parentNode.replaceChild(g,u)}else{w.addClass(this.CLASS_PREFIX+"-select")}}if(k.type=="spin"){if(!d.isArray(k.range)){k.range=[10,100]}this._makeSpinButton(w,k)}w.get("element").setAttribute("title",w.get("label"));if(k.type!="spin"){if((YAHOO.widget.Overlay)&&(t.menu instanceof YAHOO.widget.Overlay)){var h=function(o){var i=true;if(o.keyCode&&(o.keyCode==9)){i=false}if(i){if(this._colorPicker){this._colorPicker._button=k.value}var m=w.getMenu().element;if(c.getStyle(m,"visibility")=="hidden"){w.getMenu().show()}else{w.getMenu().hide()}}YAHOO.util.Event.stopEvent(o)};w.on("mousedown",h,k,this);w.on("keydown",h,k,this)}else{if((k.type!="menu")&&(k.type!="select")){w.on("keypress",this._buttonClick,k,this);w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i);this._buttonClick(i,k)},k,this);w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)});w.on("change",function(i){if(!k.menucmd){k.menucmd=k.value}k.value=i.value;this._buttonClick(i,k)},this,true);var l=this;w.on("appendTo",function(){var i=this;if(i.getMenu()&&i.getMenu().mouseDownEvent){i.getMenu().mouseDownEvent.subscribe(function(z,o){var m=o[1];YAHOO.util.Event.stopEvent(o[0]);i._onMenuClick(o[0],i);if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue);l._buttonClick.call(l,o[1],k);i._hideMenu();return false});i.getMenu().clickEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])});i.getMenu().mouseUpEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])})}})}}}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}if(this.browser.ie){}if(this.browser.webkit){w.hasFocus=function(){return true}}this._buttonList[this._buttonList.length]=w;if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){var e=w.getMenu();if(e&&e.renderEvent){e.renderEvent.subscribe(this._addMenuClasses,w);if(k.renderer){e.renderEvent.subscribe(k.renderer,w)}}}}}return k},addSeparator:function(e,h){if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}var f=((e)?e:this.get("cont"));if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}if(this._sepCount===null){this._sepCount=0}if(!this._sep){this._sep=document.createElement("SPAN");c.addClass(this._sep,this.CLASS_SEPARATOR);this._sep.innerHTML="|"}var g=this._sep.cloneNode(true);this._sepCount++;c.addClass(g,this.CLASS_SEPARATOR+"-"+this._sepCount);if(h){var i=null;if(h.get){i=h.get("element").nextSibling}else{if(h.nextSibling){i=h.nextSibling}else{i=h}}if(i){if(i==h){i.parentNode.appendChild(g)}else{i.parentNode.insertBefore(g,i)}}}else{f.appendChild(g)}return g},_createColorPicker:function(h){if(c.get(h+"_colors")){c.get(h+"_colors").parentNode.removeChild(c.get(h+"_colors"))}var e=document.createElement("div");e.className="yui-toolbar-colors";e.id=h+"_colors";e.style.display="none";a.on(window,"load",function(){document.body.appendChild(e)},this,true);this._colorPicker=e;var g="";for(var f in this._colorData){if(d.hasOwnProperty(this._colorData,f)){g+='<a style="background-color: '+f+'" href="#">'+f.replace("#","")+"</a>"}}g+="<span><em>X</em><strong></strong></span>";window.setTimeout(function(){e.innerHTML=g},0);a.on(e,"mouseover",function(m){var k=this._colorPicker;var l=k.getElementsByTagName("em")[0];var j=k.getElementsByTagName("strong")[0];var i=a.getTarget(m);if(i.tagName.toLowerCase()=="a"){l.style.backgroundColor=i.style.backgroundColor;j.innerHTML=this._colorData["#"+i.innerHTML]+"<br>"+i.innerHTML}},this,true);a.on(e,"focus",function(i){a.stopEvent(i)});a.on(e,"click",function(i){a.stopEvent(i)});a.on(e,"mousedown",function(j){a.stopEvent(j);var i=a.getTarget(j);if(i.tagName.toLowerCase()=="a"){var l=this.fireEvent("colorPickerClicked",{type:"colorPickerClicked",target:this,button:this._colorPicker._button,color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML]});if(l!==false){var k={color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML],value:this._colorPicker._button};this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:k})}this.getButtonByValue(this._colorPicker._button).getMenu().hide()}},this,true)},_resetColorPicker:function(){var f=this._colorPicker.getElementsByTagName("em")[0];var e=this._colorPicker.getElementsByTagName("strong")[0];f.style.backgroundColor="transparent";e.innerHTML=""},_makeColorButton:function(e){if(!this._colorPicker){this._createColorPicker(this.get("id"))}e.type="color";e.menu=new YAHOO.widget.Overlay(this.get("id")+"_"+e.value+"_menu",{visible:false,position:"absolute",iframe:true});e.menu.setBody("");e.menu.render(this.get("cont"));c.addClass(e.menu.element,"yui-button-menu");c.addClass(e.menu.element,"yui-color-button-menu");e.menu.beforeShowEvent.subscribe(function(){e.menu.cfg.setProperty("zindex",5);e.menu.cfg.setProperty("context",[this.getButtonById(e.id).get("element"),"tl","bl"]);this._resetColorPicker();var f=this._colorPicker;if(f.parentNode){f.parentNode.removeChild(f)}e.menu.setBody("");e.menu.appendToBody(f);this._colorPicker.style.display="block"},this,true);return e},_makeSpinButton:function(r,l){r.addClass(this.CLASS_PREFIX+"-spinbutton");var s=this,n=r._button.parentNode.parentNode,i=l.range,h=document.createElement("a"),g=document.createElement("a");h.href="#";g.href="#";h.tabIndex="-1";g.tabIndex="-1";h.className="up";h.title=this.STR_SPIN_UP;h.innerHTML=this.STR_SPIN_UP;g.className="down";g.title=this.STR_SPIN_DOWN;g.innerHTML=this.STR_SPIN_DOWN;n.appendChild(h);n.appendChild(g);var m=YAHOO.lang.substitute(this.STR_SPIN_LABEL,{VALUE:r.get("label")});r.set("title",m);var q=function(t){t=((t<i[0])?i[0]:t);t=((t>i[1])?i[1]:t);return t};var p=this.browser;var f=false;var k=this.STR_SPIN_LABEL;if(this._titlebar&&this._titlebar.firstChild){f=this._titlebar.firstChild}var e=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v++;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var o=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v--;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var j=function(t){if(t.keyCode==38){e(t)}else{if(t.keyCode==40){o(t)}else{if(t.keyCode==107&&t.shiftKey){e(t)}else{if(t.keyCode==109&&t.shiftKey){o(t)}}}}};r.on("keydown",j,this,true);a.on(h,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(g,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(h,"click",e,this,true);a.on(g,"click",o,this,true)},_buttonClick:function(n,f){var e=true;if(n&&n.type=="keypress"){if(n.keyCode==9){e=false}else{if((n.keyCode===13)||(n.keyCode===0)||(n.keyCode===32)){}else{e=false}}}if(e){var p=true,h=false;f.isSelected=this.isSelected(f.id);if(f.value){h=this.fireEvent(f.value+"Click",{type:f.value+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(f.menucmd&&p){h=this.fireEvent(f.menucmd+"Click",{type:f.menucmd+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(p){this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:f})}if(f.type=="select"){var l=this.getButtonById(f.id);if(l.buttonType=="rich"){var k=f.value;for(var j=0;j<f.menu.length;j++){if(f.menu[j].value==f.value){k=f.menu[j].text;break}}l.set("label",'<span class="yui-toolbar-'+f.menucmd+"-"+(f.value).replace(/ /g,"-").toLowerCase()+'">'+k+"</span>");var o=l.getMenu().getItems();for(var g=0;g<o.length;g++){if(o[g].value.toLowerCase()==f.value.toLowerCase()){o[g].cfg.setProperty("checked",true)}else{o[g].cfg.setProperty("checked",false)}}}}if(n){a.stopEvent(n)}}},_keyNav:null,_navCounter:null,_navigateButtons:function(f){switch(f.keyCode){case 37:case 39:if(f.keyCode==37){this._navCounter--}else{this._navCounter++}if(this._navCounter>(this._buttonList.length-1)){this._navCounter=0}if(this._navCounter<0){this._navCounter=(this._buttonList.length-1)}if(this._buttonList[this._navCounter]){var e=this._buttonList[this._navCounter].get("element");if(this.browser.ie){e=this._buttonList[this._navCounter].get("element").getElementsByTagName("a")[0]}if(this._buttonList[this._navCounter].get("disabled")){this._navigateButtons(f)}else{e.focus()}}break}},_handleFocus:function(){if(!this._keyNav){var e="keypress";if(this.browser.ie){e="keydown"}a.on(this.get("element"),e,this._navigateButtons,this,true);this._keyNav=true;this._navCounter=-1}},getButtonById:function(g){var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==g){return this._buttonList[f]}}return false},getButtonByValue:function(n){var h=this.get("buttons");var f=h.length;for(var k=0;k<f;k++){if(h[k].group!==undefined){for(var e=0;e<h[k].buttons.length;e++){if((h[k].buttons[e].value==n)||(h[k].buttons[e].menucmd==n)){return this.getButtonById(h[k].buttons[e].id)}if(h[k].buttons[e].menu){for(var l=0;l<h[k].buttons[e].menu.length;l++){if(h[k].buttons[e].menu[l].value==n){return this.getButtonById(h[k].buttons[e].id)}}}}}else{if((h[k].value==n)||(h[k].menucmd==n)){return this.getButtonById(h[k].id)}if(h[k].menu){for(var g=0;g<h[k].menu.length;g++){if(h[k].menu[g].value==n){return this.getButtonById(h[k].id)}}}}}return false},getButtonByIndex:function(e){if(this._buttonList[e]){return this._buttonList[e]}else{return false}},getButtons:function(){return this._buttonList},disableButton:function(f){var e=b.call(this,f);if(e){e.set("disabled",true)}else{return false}},enableButton:function(f){if(this.get("disabled")){return false}var e=b.call(this,f);if(e){if(e.get("disabled")){e.set("disabled",false)}}else{return false}},isSelected:function(f){var e=b.call(this,f);if(e){return e._selected}return false},selectButton:function(i,g){var f=b.call(this,i);if(f){f.addClass("yui-button-selected");f.addClass("yui-button-"+f.get("value")+"-selected");f._selected=true;if(g){if(f.buttonType=="rich"){var h=f.getMenu().getItems();for(var e=0;e<h.length;e++){if(h[e].value==g){h[e].cfg.setProperty("checked",true);f.set("label",'<span class="yui-toolbar-'+f.get("value")+"-"+(g).replace(/ /g,"-").toLowerCase()+'">'+h[e]._oText.nodeValue+"</span>")}else{h[e].cfg.setProperty("checked",false)}}}}}else{return false}},deselectButton:function(f){var e=b.call(this,f);if(e){e.removeClass("yui-button-selected");e.removeClass("yui-button-"+e.get("value")+"-selected");e.removeClass("yui-button-hover");e._selected=false}else{return false}},deselectAllButtons:function(){var e=this._buttonList.length;for(var f=0;f<e;f++){this.deselectButton(this._buttonList[f])}},disableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.disableButton(this._buttonList[f])}},enableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.enableButton(this._buttonList[f])}},resetAllButtons:function(j){if(!d.isObject(j)){j={}}if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){var h=this._buttonList[f];if(h){var g=h._configs.disabled._initialConfig.value;if(j[h.get("id")]){this.enableButton(h);this.selectButton(h)}else{if(g){this.disableButton(h)}else{this.enableButton(h)}this.deselectButton(h)}}}},destroyButton:function(j){var g=b.call(this,j);if(g){var h=g.get("id");g.destroy();var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==h){this._buttonList[f]=null}}}else{return false}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var e in this){if(d.hasOwnProperty(this,e)){this[e]=null}}return true},collapse:function(f){var e=c.getElementsByClassName("collapse","span",this._titlebar);if(f===false){c.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(e[0]){c.removeClass(e[0],"collapsed")}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this})}else{if(e[0]){c.addClass(e[0],"collapsed")}c.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this})}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons."}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang,b=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(h,m){var g={};if(d.isObject(h)&&(!h.tagName)&&!m){d.augmentObject(g,h);h=document.createElement("textarea");this.DOMReady=true;if(g.container){var k=c.get(g.container);k.appendChild(h)}else{document.body.appendChild(h)}}else{if(m){d.augmentObject(g,m)}}var i={element:null,attributes:g},f=null;if(d.isString(h)){f=h}else{if(i.attributes.id){f=i.attributes.id}else{this.DOMReady=true;f=c.generateId(h)}}i.element=h;var j=document.createElement("DIV");i.attributes.element_cont=new YAHOO.util.Element(j,{id:f+"_container"});var e=document.createElement("div");c.addClass(e,"first-child");i.attributes.element_cont.appendChild(e);if(!i.attributes.toolbar_cont){i.attributes.toolbar_cont=document.createElement("DIV");i.attributes.toolbar_cont.id=f+"_toolbar";e.appendChild(i.attributes.toolbar_cont)}var l=document.createElement("DIV");e.appendChild(l);i.attributes.editor_wrapper=l;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,i.element,i.attributes)};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false}if(this.get("resize")){var e={};d.augmentObject(e,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),e);this.resize.on("resize",function(g){var l=this.get("animate");this.set("animate",false);this.set("width",g.width+"px");var i=g.height,j=(this.toolbar.get("element").clientHeight+2),k=0;if(this.dompath){k=(this.dompath.clientHeight+1)}var f=(i-j-k);this.set("height",f+"px");this.get("element_cont").setStyle("height","");this.set("animate",l)},this,true)}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false}if(this.get("drag")){var f=this.get("drag"),e=YAHOO.util.DD;if(f==="proxy"){e=YAHOO.util.DDProxy}this.dd=new e(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar)}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(f,j){var g=false;if((j.keyCode===f.key)){if(f.mods&&(f.mods.length>0)){var l=0;for(var h=0;h<f.mods.length;h++){if(this.browser.mac){if(f.mods[h]=="ctrl"){f.mods[h]="meta"}}if(j[f.mods[h]+"Key"]===true){l++}}if(l===f.mods.length){g=true}}else{g=true}}return g},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(e){return e.replace(/ /g,"-").toLowerCase()},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-
|
F.setAttribute("src",J);YAHOO.util.Dom.addClass(F,"yui-img");this.currentElement[0].parentNode.replaceChild(F,this.currentElement[0]);}this.currentElement[0]=F;E=false;}}return[E];},cmd_inserthtml:function(H){var E=true,G="inserthtml",F=null,I=null;if(this.browser.webkit&&!this._getDoc().queryCommandEnabled(G)){this._createCurrentElement("img");F=this._getDoc().createElement("span");F.innerHTML=H;this.currentElement[0].parentNode.replaceChild(F,this.currentElement[0]);E=false;}else{if(this.browser.ie){I=this._getRange();if(I.item){I.item(0).outerHTML=H;}else{I.pasteHTML(H);}E=false;}}return[E];},cmd_list:function(Y){var S=true,V=null,M=0,G=null,R="",W=this._getSelectedElement(),T="insertorderedlist";if(Y=="ul"){T="insertunorderedlist";}if(this.browser.webkit){if(this._isElement(W,"li")&&this._isElement(W.parentNode,Y)){G=W.parentNode;V=this._getDoc().createElement("span");YAHOO.util.Dom.addClass(V,"yui-non");R="";var F=G.getElementsByTagName("li");for(M=0;M<F.length;M++){R+="<div>"+F[M].innerHTML+"</div>";}V.innerHTML=R;this.currentElement[0]=G;this.currentElement[0].parentNode.replaceChild(V,this.currentElement[0]);}else{this._createCurrentElement(Y.toLowerCase());V=this._getDoc().createElement(Y);for(M=0;M<this.currentElement.length;M++){var J=this._getDoc().createElement("li");J.innerHTML=this.currentElement[M].innerHTML+'<span class="yui-non"> </span> ';V.appendChild(J);if(M>0){this.currentElement[M].parentNode.removeChild(this.currentElement[M]);}}this.currentElement[0].parentNode.replaceChild(V,this.currentElement[0]);this.currentElement[0]=V;var H=this.currentElement[0].firstChild;H=C.getElementsByClassName("yui-non","span",H)[0];this._getSelection().setBaseAndExtent(H,1,H,H.innerText.length);}S=false;}else{G=this._getSelectedElement();if(this._isElement(G,"li")&&this._isElement(G.parentNode,Y)||(this.browser.ie&&this._isElement(this._getRange().parentElement,"li"))||(this.browser.ie&&this._isElement(G,"ul"))||(this.browser.ie&&this._isElement(G,"ol"))){if(this.browser.ie){if((this.browser.ie&&this._isElement(G,"ul"))||(this.browser.ie&&this._isElement(G,"ol"))){G=G.getElementsByTagName("li")[0];}R="";var I=G.parentNode.getElementsByTagName("li");for(var U=0;U<I.length;U++){R+=I[U].innerHTML+"<br>";}var X=this._getDoc().createElement("span");X.innerHTML=R;G.parentNode.parentNode.replaceChild(X,G.parentNode);}else{this.nodeChange();this._getDoc().execCommand(T,"",G.parentNode);this.nodeChange();}S=false;}if(this.browser.opera){var Q=this;window.setTimeout(function(){var Z=Q._getDoc().getElementsByTagName("li");for(var a=0;a<Z.length;a++){if(Z[a].innerHTML.toLowerCase()=="<br>"){Z[a].parentNode.parentNode.removeChild(Z[a].parentNode);}}},30);}if(this.browser.ie&&S){var K="";if(this._getRange().html){K="<li>"+this._getRange().html+"</li>";}else{var L=this._getRange().text.split("\n");if(L.length>1){K="";for(var P=0;P<L.length;P++){K+="<li>"+L[P]+"</li>";}}else{var O=this._getRange().text;if(O===""){K='<li id="new_list_item">'+O+"</li>";}else{K="<li>"+O+"</li>";}}}this._getRange().pasteHTML("<"+Y+">"+K+"</"+Y+">");var E=this._getDoc().getElementById("new_list_item");if(E){var N=this._getDoc().body.createTextRange();N.moveToElementText(E);N.collapse(false);N.select();E.id="";}S=false;}}return S;},cmd_insertorderedlist:function(E){return[this.cmd_list("ol")];},cmd_insertunorderedlist:function(E){return[this.cmd_list("ul")];},cmd_fontname:function(H){var E=true,G=this._getSelectedElement();this.currentFont=H;if(G&&G.tagName&&!this._hasSelection()&&!this._isElement(G,"body")&&!this.get("insert")){YAHOO.util.Dom.setStyle(G,"font-family",H);E=false;}else{if(this.get("insert")&&!this._hasSelection()){var F=this._createInsertElement({fontFamily:H});E=false;}}return[E];},cmd_fontsize:function(G){var E=null;if(this.currentElement&&(this.currentElement.length>0)&&(!this._hasSelection())&&(!this.get("insert"))){YAHOO.util.Dom.setStyle(this.currentElement,"fontSize",G);}else{if(!this._isElement(this._getSelectedElement(),"body")){E=this._getSelectedElement();YAHOO.util.Dom.setStyle(E,"fontSize",G);if(this.get("insert")&&this.browser.ie){var F=this._getRange();F.collapse(false);F.select();}else{this._selectNode(E);}}else{if(this.get("insert")&&!this._hasSelection()){E=this._createInsertElement({fontSize:G});this.currentElement[0]=E;this._selectNode(this.currentElement[0]);}else{this._createCurrentElement("span",{"fontSize":G});this._selectNode(this.currentElement[0]);}}}return[false];},_swapEl:function(F,E,H){var G=this._getDoc().createElement(E);if(F){G.innerHTML=F.innerHTML;}if(typeof H=="function"){H.call(this,G);}if(F){F.parentNode.replaceChild(G,F);}return G;},_createInsertElement:function(E){this._createCurrentElement("span",E);var F=this.currentElement[0];if(this.browser.webkit){F.innerHTML='<span class="yui-non"> </span>';F=F.firstChild;this._getSelection().setBaseAndExtent(F,1,F,F.innerText.length);}else{if(this.browser.ie||this.browser.opera){F.innerHTML=" ";}}this._focusWindow();this._selectNode(F,true);return F;},_createCurrentElement:function(G,J){G=((G)?G:"a");var R=null,F=[],H=this._getDoc();if(this.currentFont){if(!J){J={};}J.fontFamily=this.currentFont;this.currentFont=null;}this.currentElement=[];var M=function(X,Z){var Y=null;X=((X)?X:"span");X=X.toLowerCase();switch(X){case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":Y=H.createElement(X);break;default:Y=H.createElement(X);if(X==="span"){YAHOO.util.Dom.addClass(Y,"yui-tag-"+X);YAHOO.util.Dom.addClass(Y,"yui-tag");Y.setAttribute("tag",X);}for(var W in Z){if(YAHOO.lang.hasOwnProperty(Z,W)){Y.style[W]=Z[W];}}break;}return Y;};if(!this._hasSelection()){if(this._getDoc().queryCommandEnabled("insertimage")){this._getDoc().execCommand("insertimage",false,"yui-tmp-img");var L=this._getDoc().getElementsByTagName("img");for(var Q=0;Q<L.length;Q++){if(L[Q].getAttribute("src",2)=="yui-tmp-img"){F=M(G,J);L[Q].parentNode.replaceChild(F,L[Q]);this.currentElement[this.currentElement.length]=F;}}}else{if(this.currentEvent){R=YAHOO.util.Event.getTarget(this.currentEvent);}else{R=this._getDoc().body;}}if(R){F=M(G,J);if(this._isElement(R,"body")||this._isElement(R,"html")){if(this._isElement(R,"html")){R=this._getDoc().body;}R.appendChild(F);}else{if(R.nextSibling){R.parentNode.insertBefore(F,R.nextSibling);}else{R.parentNode.appendChild(F);}}this.currentElement[this.currentElement.length]=F;this.currentEvent=null;if(this.browser.webkit){this._getSelection().setBaseAndExtent(F,0,F,0);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(true);}}}}else{this._setEditorStyle(true);this._getDoc().execCommand("fontname",false,"yui-tmp");var E=[],P,V=["font","span","i","b","u"];if(!this._isElement(this._getSelectedElement(),"body")){V[V.length]=this._getDoc().getElementsByTagName(this._getSelectedElement().tagName);V[V.length]=this._getDoc().getElementsByTagName(this._getSelectedElement().parentNode.tagName);}for(var K=0;K<V.length;K++){var I=this._getDoc().getElementsByTagName(V[K]);for(var U=0;U<I.length;U++){E[E.length]=I[U];}}for(var S=0;S<E.length;S++){if((YAHOO.util.Dom.getStyle(E[S],"font-family")=="yui-tmp")||(E[S].face&&(E[S].face=="yui-tmp"))){F=M(G,J);F.innerHTML=E[S].innerHTML;if(this._isElement(E[S],"ol")||(this._isElement(E[S],"ul"))){var N=E[S].getElementsByTagName("li")[0];E[S].style.fontFamily="inherit";N.style.fontFamily="inherit";F.innerHTML=N.innerHTML;N.innerHTML="";N.appendChild(F);this.currentElement[this.currentElement.length]=F;}else{if(this._isElement(E[S],"li")){E[S].innerHTML="";E[S].appendChild(F);E[S].style.fontFamily="inherit";this.currentElement[this.currentElement.length]=F;}else{if(E[S].parentNode){E[S].parentNode.replaceChild(F,E[S]);this.currentElement[this.currentElement.length]=F;this.currentEvent=null;if(this.browser.webkit){this._getSelection().setBaseAndExtent(F,0,F,0);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(true);}}if(this.browser.ie&&J&&J.fontSize){this._getSelection().empty();}if(this.browser.gecko){this._getSelection().collapseToStart();}}}}}}var T=this.currentElement.length;for(var O=0;O<T;O++){if((O+1)!=T){if(this.currentElement[O]&&this.currentElement[O].nextSibling){if(this._isElement(this.currentElement[O],"br")){this.currentElement[this.currentElement.length]=this.currentElement[O].nextSibling;}}}}}},saveHTML:function(){var F=this.cleanHTML();if(this._textarea){this.get("element").value=F;}else{this.get("element").innerHTML=F;}if(this.get("saveEl")!==this.get("element")){var E=this.get("saveEl");if(D.isString(E)){E=C.get(E);}if(E){if(E.tagName.toLowerCase()==="textarea"){E.value=F;}else{E.innerHTML=F;}}}return F;},setEditorHTML:function(F){var E=this._cleanIncomingHTML(F);this._getDoc().body.innerHTML=E;this.nodeChange();},getEditorHTML:function(){var E=this._getDoc().body;if(E===null){return null;}return this._getDoc().body.innerHTML;},show:function(){if(this.browser.gecko){this._setDesignMode("on");this._focusWindow();}if(this.browser.webkit){var E=this;window.setTimeout(function(){E._setInitialContent.call(E);},10);}if(this.currentWindow){this.closeWindow();}this.get("iframe").setStyle("position","static");this.get("iframe").setStyle("left","");},hide:function(){if(this.currentWindow){this.closeWindow();}if(this._fixNodesTimer){clearTimeout(this._fixNodesTimer);this._fixNodesTimer=null;}if(this._nodeChangeTimer){clearTimeout(this._nodeChangeTimer);this._nodeChangeTimer=null;}this._lastNodeChange=0;this.get("iframe").setStyle("position","absolute");this.get("iframe").setStyle("left","-9999px");},_cleanIncomingHTML:function(E){E=E.replace(/<strong([^>]*)>/gi,"<b$1>");E=E.replace(/<\/strong>/gi,"</b>");E=E.replace(/<embed([^>]*)>/gi,"<YUI_EMBED$1>");E=E.replace(/<\/embed>/gi,"</YUI_EMBED>");E=E.replace(/<em([^>]*)>/gi,"<i$1>");E=E.replace(/<\/em>/gi,"</i>");E=E.replace(/<YUI_EMBED([^>]*)>/gi,"<embed$1>");E=E.replace(/<\/YUI_EMBED>/gi,"</embed>");if(this.get("plainText")){E=E.replace(/\n/g,"<br>").replace(/\r/g,"<br>");E=E.replace(/ /gi," ");E=E.replace(/\t/gi," ");}E=E.replace(/<script([^>]*)>/gi,"<bad>");E=E.replace(/<\/script([^>]*)>/gi,"</bad>");E=E.replace(/<script([^>]*)>/gi,"<bad>");E=E.replace(/<\/script([^>]*)>/gi,"</bad>");E=E.replace(/\n/g,"<YUI_LF>").replace(/\r/g,"<YUI_LF>");E=E.replace(new RegExp("<bad([^>]*)>(.*?)</bad>","gi"),"");E=E.replace(/<YUI_LF>/g,"\n");return E;},cleanHTML:function(G){if(!G){G=this.getEditorHTML();}var F=this.get("markup");G=this.pre_filter_linebreaks(G,F);G=G.replace(/<img([^>]*)\/>/gi,"<YUI_IMG$1>");G=G.replace(/<img([^>]*)>/gi,"<YUI_IMG$1>");G=G.replace(/<input([^>]*)\/>/gi,"<YUI_INPUT$1>");G=G.replace(/<input([^>]*)>/gi,"<YUI_INPUT$1>");G=G.replace(/<ul([^>]*)>/gi,"<YUI_UL$1>");G=G.replace(/<\/ul>/gi,"</YUI_UL>");G=G.replace(/<blockquote([^>]*)>/gi,"<YUI_BQ$1>");G=G.replace(/<\/blockquote>/gi,"</YUI_BQ>");G=G.replace(/<embed([^>]*)>/gi,"<YUI_EMBED$1>");G=G.replace(/<\/embed>/gi,"</YUI_EMBED>");if((F=="semantic")||(F=="xhtml")){G=G.replace(/<i(\s+[^>]*)?>/gi,"<em$1>");G=G.replace(/<\/i>/gi,"</em>");G=G.replace(/<b(\s+[^>]*)?>/gi,"<strong$1>");G=G.replace(/<\/b>/gi,"</strong>");}G=G.replace(/<font/gi,"<font");G=G.replace(/<\/font>/gi,"</font>");G=G.replace(/<span/gi,"<span");G=G.replace(/<\/span>/gi,"</span>");if((F=="semantic")||(F=="xhtml")||(F=="css")){G=G.replace(new RegExp('<font([^>]*)face="([^>]*)">(.*?)</font>',"gi"),'<span $1 style="font-family: $2;">$3</span>');G=G.replace(/<u/gi,'<span style="text-decoration: underline;"');if(this.browser.webkit){G=G.replace(new RegExp('<span class="Apple-style-span" style="font-weight: bold;">([^>]*)</span>',"gi"),"<strong>$1</strong>");G=G.replace(new RegExp('<span class="Apple-style-span" style="font-style: italic;">([^>]*)</span>',"gi"),"<em>$1</em>");}G=G.replace(/\/u>/gi,"/span>");if(F=="css"){G=G.replace(/<em([^>]*)>/gi,"<i$1>");G=G.replace(/<\/em>/gi,"</i>");G=G.replace(/<strong([^>]*)>/gi,"<b$1>");G=G.replace(/<\/strong>/gi,"</b>");G=G.replace(/<b/gi,'<span style="font-weight: bold;"');
|
var matches = this.getPropertyMatches(itemType, '_all');
|
var matches = this.findViewsInTemplate(itemType, '_all');
|
this._createFragment = function(itemType) { this._fmlFragments[itemType] = document.createElement('div'); var matches = this.getPropertyMatches(itemType, '_all'); var templateHTML = this._fmlTemplates[itemType]; for (var i=0, match; match = matches[i]; i++) { while (templateHTML.match(match._str)) { templateHTML = templateHTML.replace(match._str, '<span class="' + this.getPlaceholderClassName(match.name) + '"></span>'); } } this._fmlFragments[itemType].innerHTML = templateHTML; }
|
'<span class="' + this.getPlaceholderClassName(match.name) + '"></span>');
|
'<span class="' + this.getViewClassName(match.name) + '"></span>');
|
this._createFragment = function(itemType) { this._fmlFragments[itemType] = document.createElement('div'); var matches = this.getPropertyMatches(itemType, '_all'); var templateHTML = this._fmlTemplates[itemType]; for (var i=0, match; match = matches[i]; i++) { while (templateHTML.match(match._str)) { templateHTML = templateHTML.replace(match._str, '<span class="' + this.getPlaceholderClassName(match.name) + '"></span>'); } } this._fmlFragments[itemType].innerHTML = templateHTML; }
|
"tabpanel");a.headers.not(a.active||"").attr({"aria-expanded":"false",tabIndex:-1}).next().hide();a.active.length?a.active.attr({"aria-expanded":"true",tabIndex:0}):a.headers.eq(0).attr("tabIndex",0);c.browser.safari||a.headers.find("a").attr("tabIndex",-1);b.event&&a.headers.bind(b.event.split(" ").join(".accordion ")+".accordion",function(g){a._clickHandler.call(a,g,this);g.preventDefault()})},_createIcons:function(){var a=this.options;if(a.icons){c("<span></span>").addClass("ui-icon "+a.icons.header).prependTo(this.headers); this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex");
|
function(g){return a._keydown(g)}).next().attr("role","tabpanel");a.headers.not(a.active||"").attr({"aria-expanded":"false",tabIndex:-1}).next().hide();a.active.length?a.active.attr({"aria-expanded":"true",tabIndex:0}):a.headers.eq(0).attr("tabIndex",0);c.browser.safari||a.headers.find("a").attr("tabIndex",-1);b.event&&a.headers.bind(b.event.split(" ").join(".accordion ")+".accordion",function(g){a._clickHandler.call(a,g,this);g.preventDefault()})},_createIcons:function(){var a=this.options;if(a.icons){c("<span></span>").addClass("ui-icon "+ a.icons.header).prependTo(this.headers);this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex");
|
"tabpanel");a.headers.not(a.active||"").attr({"aria-expanded":"false",tabIndex:-1}).next().hide();a.active.length?a.active.attr({"aria-expanded":"true",tabIndex:0}):a.headers.eq(0).attr("tabIndex",0);c.browser.safari||a.headers.find("a").attr("tabIndex",-1);b.event&&a.headers.bind(b.event.split(" ").join(".accordion ")+".accordion",function(g){a._clickHandler.call(a,g,this);g.preventDefault()})},_createIcons:function(){var a=this.options;if(a.icons){c("<span></span>").addClass("ui-icon "+a.icons.header).prependTo(this.headers);this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex");
|
}(),_lastImage:null,_blankImageLoaded:null,_fixNodesTimer:null,_nodeChangeTimer:null,_lastNodeChangeEvent:null,_lastNodeChange:0,_rendered:null,DOMReady:null,_selection:null,_mask:null,_showingHiddenElements:null,currentWindow:null,currentEvent:null,operaEvent:null,currentFont:null,currentElement:null,dompath:null,beforeElement:null,afterElement:null,invalidHTML:{form:true,input:true,button:true,select:true,link:true,html:true,body:true,iframe:true,script:true,style:true,textarea:true},toolbar:null,_contentTimer:null,_contentTimerCounter:0,_disabled:["createlink","fontname","fontsize","forecolor","backcolor"],_alwaysDisabled:{undo:true,redo:true},_alwaysEnabled:{},_semantic:{"bold":true,"italic":true,"underline":true},_tag2cmd:{"b":"bold","strong":"bold","i":"italic","em":"italic","u":"underline","sup":"superscript","sub":"subscript","img":"insertimage","a":"createlink","ul":"insertunorderedlist","ol":"insertorderedlist"},_createIframe:function(){var I=document.createElement("iframe");I.id=this.get("id")+"_editor";var G={border:"0",frameBorder:"0",marginWidth:"0",marginHeight:"0",leftMargin:"0",topMargin:"0",allowTransparency:"true",width:"100%"};if(this.get("autoHeight")){G.scrolling="no";}for(var H in G){if(D.hasOwnProperty(G,H)){I.setAttribute(H,G[H]);}}var F="javascript:;";if(this.browser.ie){F="javascript:false;";}I.setAttribute("src",F);var E=new YAHOO.util.Element(I);E.setStyle("visibility","hidden");return E;},_isElement:function(F,E){if(F&&F.tagName&&(F.tagName.toLowerCase()==E)){return true;}if(F&&F.getAttribute&&(F.getAttribute("tag")==E)){return true;}return false;},_hasParent:function(F,E){if(!F||!F.parentNode){return false;}while(F.parentNode){if(this._isElement(F,E)){return F;}if(F.parentNode){F=F.parentNode;}else{return false;}}return false;},_getDoc:function(){var E=false;if(this.get){if(this.get("iframe")){if(this.get("iframe").get){if(this.get("iframe").get("element")){try{if(this.get("iframe").get("element").contentWindow){if(this.get("iframe").get("element").contentWindow.document){E=this.get("iframe").get("element").contentWindow.document;return E;}}}catch(F){}}}}}return false;},_getWindow:function(){return this.get("iframe").get("element").contentWindow;},_focusWindow:function(E){if(this.browser.webkit){if(E){this._getSelection().setBaseAndExtent(this._getDoc().body.firstChild,0,this._getDoc().body.firstChild,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}else{this._getSelection().setBaseAndExtent(this._getDoc().body,1,this._getDoc().body,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}this._getWindow().focus();}else{this._getWindow().focus();}},_hasSelection:function(){var G=this._getSelection();var E=this._getRange();var F=false;if(!G||!E){return F;}if(this.browser.ie||this.browser.opera){if(E.text){F=true;}if(E.html){F=true;}}else{if(this.browser.webkit){if(G+""!==""){F=true;}}else{if(G&&(G.toString()!=="")&&(G!==undefined)){F=true;}}}return F;},_getSelection:function(){var E=null;if(this._getDoc()&&this._getWindow()){if(this._getDoc().selection){E=this._getDoc().selection;}else{E=this._getWindow().getSelection();}if(this.browser.webkit){if(E.baseNode){this._selection={};this._selection.baseNode=E.baseNode;this._selection.baseOffset=E.baseOffset;this._selection.extentNode=E.extentNode;this._selection.extentOffset=E.extentOffset;}else{if(this._selection!==null){E=this._getWindow().getSelection();E.setBaseAndExtent(this._selection.baseNode,this._selection.baseOffset,this._selection.extentNode,this._selection.extentOffset);this._selection=null;}}}}return E;},_selectNode:function(F,I){if(!F){return false;}var G=this._getSelection(),E=null;if(this.browser.ie){try{E=this._getDoc().body.createTextRange();E.moveToElementText(F);E.select();}catch(H){}}else{if(this.browser.webkit){if(I){G.setBaseAndExtent(F,1,F,F.innerText.length);}else{G.setBaseAndExtent(F,0,F,F.innerText.length);}}else{if(this.browser.opera){G=this._getWindow().getSelection();E=this._getDoc().createRange();E.selectNode(F);G.removeAllRanges();G.addRange(E);}else{E=this._getDoc().createRange();E.selectNodeContents(F);G.removeAllRanges();G.addRange(E);}}}this.nodeChange();},_getRange:function(){var E=this._getSelection();if(E===null){return null;}if(this.browser.webkit&&!E.getRangeAt){var H=this._getDoc().createRange();try{H.setStart(E.anchorNode,E.anchorOffset);H.setEnd(E.focusNode,E.focusOffset);}catch(G){H=this._getWindow().getSelection()+"";}return H;}if(this.browser.ie||this.browser.opera){try{return E.createRange();}catch(F){return null;}}if(E.rangeCount>0){return E.getRangeAt(0);}return null;},_setDesignMode:function(E){try{var G=true;if(this.browser.ie&&(E.toLowerCase()=="off")){G=false;}if(G){this._getDoc().designMode=E;}}catch(F){}},_toggleDesignMode:function(){var F=this._getDoc().designMode.toLowerCase(),E="on";if(F=="on"){E="off";}this._setDesignMode(E);return E;},_initEditorEvents:function(){var E=this._getDoc();A.on(E,"mouseup",this._handleMouseUp,this,true);A.on(E,"mousedown",this._handleMouseDown,this,true);A.on(E,"click",this._handleClick,this,true);A.on(E,"dblclick",this._handleDoubleClick,this,true);A.on(E,"keypress",this._handleKeyPress,this,true);A.on(E,"keyup",this._handleKeyUp,this,true);A.on(E,"keydown",this._handleKeyDown,this,true);},_removeEditorEvents:function(){var E=this._getDoc();A.removeListener(E,"mouseup",this._handleMouseUp,this,true);A.removeListener(E,"mousedown",this._handleMouseDown,this,true);A.removeListener(E,"click",this._handleClick,this,true);A.removeListener(E,"dblclick",this._handleDoubleClick,this,true);A.removeListener(E,"keypress",this._handleKeyPress,this,true);A.removeListener(E,"keyup",this._handleKeyUp,this,true);A.removeListener(E,"keydown",this._handleKeyDown,this,true);},_initEditor:function(){if(this.browser.ie){this._getDoc().body.style.margin="0";}if(!this.get("disabled")){if(this._getDoc().designMode.toLowerCase()!="on"){this._setDesignMode("on");
|
(function(){var b=YAHOO.util.Dom,a=YAHOO.util.Event,c=YAHOO.lang;if(YAHOO.widget.Button){YAHOO.widget.ToolbarButtonAdvanced=YAHOO.widget.Button;YAHOO.widget.ToolbarButtonAdvanced.prototype.buttonType="rich";YAHOO.widget.ToolbarButtonAdvanced.prototype.checkValue=function(f){var e=this.getMenu().getItems();if(e.length===0){this.getMenu()._onBeforeShow();e=this.getMenu().getItems()}for(var d=0;d<e.length;d++){e[d].cfg.setProperty("checked",false);if(e[d].value==f){e[d].cfg.setProperty("checked",true)}}}}else{YAHOO.widget.ToolbarButtonAdvanced=function(){}}YAHOO.widget.ToolbarButton=function(e,d){if(c.isObject(arguments[0])&&!b.get(e).nodeType){d=e}var g=(d||{});var f={element:null,attributes:g};if(!f.attributes.type){f.attributes.type="push"}f.element=document.createElement("span");f.element.setAttribute("unselectable","on");f.element.className="yui-button yui-"+f.attributes.type+"-button";f.element.innerHTML='<span class="first-child"><a href="#">LABEL</a></span>';f.element.firstChild.firstChild.tabIndex="-1";f.attributes.id=b.generateId();YAHOO.widget.ToolbarButton.superclass.constructor.call(this,f.element,f.attributes)};YAHOO.extend(YAHOO.widget.ToolbarButton,YAHOO.util.Element,{buttonType:"normal",_handleMouseOver:function(){if(!this.get("disabled")){this.addClass("yui-button-hover");this.addClass("yui-"+this.get("type")+"-button-hover")}},_handleMouseOut:function(){this.removeClass("yui-button-hover");this.removeClass("yui-"+this.get("type")+"-button-hover")},checkValue:function(f){if(this.get("type")=="menu"){var e=this._button.options;for(var d=0;d<e.length;d++){if(e[d].value==f){e.selectedIndex=d}}}},init:function(e,d){YAHOO.widget.ToolbarButton.superclass.init.call(this,e,d);this.on("mouseover",this._handleMouseOver,this,true);this.on("mouseout",this._handleMouseOut,this,true)},initAttributes:function(d){YAHOO.widget.ToolbarButton.superclass.initAttributes.call(this,d);this.setAttributeConfig("value",{value:d.value});this.setAttributeConfig("menu",{value:d.menu||false});this.setAttributeConfig("type",{value:d.type,writeOnce:true,method:function(h){var g,f;if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}switch(h){case"select":case"menu":g=document.createElement("select");var j=this.get("menu");for(var e=0;e<j.length;e++){f=document.createElement("option");f.innerHTML=j[e].text;f.value=j[e].value;if(j[e].checked){f.selected=true}g.appendChild(f)}this._button.parentNode.replaceChild(g,this._button);a.on(g,"change",this._handleSelect,this,true);this._button=g;break}}});this.setAttributeConfig("disabled",{value:d.disabled||false,method:function(e){if(e){this.addClass("yui-button-disabled");this.addClass("yui-"+this.get("type")+"-button-disabled")}else{this.removeClass("yui-button-disabled");this.removeClass("yui-"+this.get("type")+"-button-disabled")}if(this.get("type")=="menu"){this._button.disabled=e}}});this.setAttributeConfig("label",{value:d.label,method:function(e){if(!this._button){this._button=this.get("element").getElementsByTagName("a")[0]}if(this.get("type")=="push"){this._button.innerHTML=e}}});this.setAttributeConfig("title",{value:d.title});this.setAttributeConfig("container",{value:null,writeOnce:true,method:function(e){this.appendTo(e)}})},_handleSelect:function(e){var d=a.getTarget(e);var f=d.options[d.selectedIndex].value;this.fireEvent("change",{type:"change",value:f})},getMenu:function(){return this.get("menu")},destroy:function(){a.purgeElement(this.get("element"),true);this.get("element").parentNode.removeChild(this.get("element"));for(var d in this){if(c.hasOwnProperty(this,d)){this[d]=null}}},fireEvent:function(e,d){if(this.DOM_EVENTS[e]&&this.get("disabled")){return}YAHOO.widget.ToolbarButton.superclass.fireEvent.call(this,e,d)},toString:function(){return"ToolbarButton ("+this.get("id")+")"}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang;var b=function(f){var e=f;if(d.isString(f)){e=this.getButtonById(f)}if(d.isNumber(f)){e=this.getButtonByIndex(f)}if((!(e instanceof YAHOO.widget.ToolbarButton))&&(!(e instanceof YAHOO.widget.ToolbarButtonAdvanced))){e=this.getButtonByValue(f)}if((e instanceof YAHOO.widget.ToolbarButton)||(e instanceof YAHOO.widget.ToolbarButtonAdvanced)){return e}return false};YAHOO.widget.Toolbar=function(i,h){if(d.isObject(arguments[0])&&!c.get(i).nodeType){h=i}var k={};if(h){d.augmentObject(k,h)}var j={element:null,attributes:k};if(d.isString(i)&&c.get(i)){j.element=c.get(i)}else{if(d.isObject(i)&&c.get(i)&&c.get(i).nodeType){j.element=c.get(i)}}if(!j.element){j.element=document.createElement("DIV");j.element.id=c.generateId();if(k.container&&c.get(k.container)){c.get(k.container).appendChild(j.element)}}if(!j.element.id){j.element.id=((d.isString(i))?i:c.generateId())}var f=document.createElement("fieldset");var g=document.createElement("legend");g.innerHTML="Toolbar";f.appendChild(g);var e=document.createElement("DIV");j.attributes.cont=e;c.addClass(e,"yui-toolbar-subcont");f.appendChild(e);j.element.appendChild(f);j.element.tabIndex=-1;j.attributes.element=j.element;j.attributes.id=j.element.id;YAHOO.widget.Toolbar.superclass.constructor.call(this,j.element,j.attributes)};YAHOO.extend(YAHOO.widget.Toolbar,YAHOO.util.Element,{_addMenuClasses:function(h,e,j){c.addClass(this.element,"yui-toolbar-"+j.get("value")+"-menu");if(c.hasClass(j._button.parentNode.parentNode,"yui-toolbar-select")){c.addClass(this.element,"yui-toolbar-select-menu")}var f=this.getItems();for(var g=0;g<f.length;g++){c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-").toLowerCase():f[g]._oText.nodeValue.replace(/ /g,"-").toLowerCase()));c.addClass(f[g].element,"yui-toolbar-"+j.get("value")+"-"+((f[g].value)?f[g].value.replace(/ /g,"-"):f[g]._oText.nodeValue.replace(/ /g,"-")))}},buttonType:YAHOO.widget.ToolbarButton,dd:null,_colorData:{"#111111":"Obsidian","#2D2D2D":"Dark Gray","#434343":"Shale","#5B5B5B":"Flint","#737373":"Gray","#8B8B8B":"Concrete","#A2A2A2":"Gray","#B9B9B9":"Titanium","#000000":"Black","#D0D0D0":"Light Gray","#E6E6E6":"Silver","#FFFFFF":"White","#BFBF00":"Pumpkin","#FFFF00":"Yellow","#FFFF40":"Banana","#FFFF80":"Pale Yellow","#FFFFBF":"Butter","#525330":"Raw Siena","#898A49":"Mildew","#AEA945":"Olive","#7F7F00":"Paprika","#C3BE71":"Earth","#E0DCAA":"Khaki","#FCFAE1":"Cream","#60BF00":"Cactus","#80FF00":"Chartreuse","#A0FF40":"Green","#C0FF80":"Pale Lime","#DFFFBF":"Light Mint","#3B5738":"Green","#668F5A":"Lime Gray","#7F9757":"Yellow","#407F00":"Clover","#8A9B55":"Pistachio","#B7C296":"Light Jade","#E6EBD5":"Breakwater","#00BF00":"Spring Frost","#00FF80":"Pastel Green","#40FFA0":"Light Emerald","#80FFC0":"Sea Foam","#BFFFDF":"Sea Mist","#033D21":"Dark Forrest","#438059":"Moss","#7FA37C":"Medium Green","#007F40":"Pine","#8DAE94":"Yellow Gray Green","#ACC6B5":"Aqua Lung","#DDEBE2":"Sea Vapor","#00BFBF":"Fog","#00FFFF":"Cyan","#40FFFF":"Turquoise Blue","#80FFFF":"Light Aqua","#BFFFFF":"Pale Cyan","#033D3D":"Dark Teal","#347D7E":"Gray Turquoise","#609A9F":"Green Blue","#007F7F":"Seaweed","#96BDC4":"Green Gray","#B5D1D7":"Soapstone","#E2F1F4":"Light Turquoise","#0060BF":"Summer Sky","#0080FF":"Sky Blue","#40A0FF":"Electric Blue","#80C0FF":"Light Azure","#BFDFFF":"Ice Blue","#1B2C48":"Navy","#385376":"Biscay","#57708F":"Dusty Blue","#00407F":"Sea Blue","#7792AC":"Sky Blue Gray","#A8BED1":"Morning Sky","#DEEBF6":"Vapor","#0000BF":"Deep Blue","#0000FF":"Blue","#4040FF":"Cerulean Blue","#8080FF":"Evening Blue","#BFBFFF":"Light Blue","#212143":"Deep Indigo","#373E68":"Sea Blue","#444F75":"Night Blue","#00007F":"Indigo Blue","#585E82":"Dockside","#8687A4":"Blue Gray","#D2D1E1":"Light Blue Gray","#6000BF":"Neon Violet","#8000FF":"Blue Violet","#A040FF":"Violet Purple","#C080FF":"Violet Dusk","#DFBFFF":"Pale Lavender","#302449":"Cool Shale","#54466F":"Dark Indigo","#655A7F":"Dark Violet","#40007F":"Violet","#726284":"Smoky Violet","#9E8FA9":"Slate Gray","#DCD1DF":"Violet White","#BF00BF":"Royal Violet","#FF00FF":"Fuchsia","#FF40FF":"Magenta","#FF80FF":"Orchid","#FFBFFF":"Pale Magenta","#4A234A":"Dark Purple","#794A72":"Medium Purple","#936386":"Cool Granite","#7F007F":"Purple","#9D7292":"Purple Moon","#C0A0B6":"Pale Purple","#ECDAE5":"Pink Cloud","#BF005F":"Hot Pink","#FF007F":"Deep Pink","#FF409F":"Grape","#FF80BF":"Electric Pink","#FFBFDF":"Pink","#451528":"Purple Red","#823857":"Purple Dino","#A94A76":"Purple Gray","#7F003F":"Rose","#BC6F95":"Antique Mauve","#D8A5BB":"Cool Marble","#F7DDE9":"Pink Granite","#C00000":"Apple","#FF0000":"Fire Truck","#FF4040":"Pale Red","#FF8080":"Salmon","#FFC0C0":"Warm Pink","#441415":"Sepia","#82393C":"Rust","#AA4D4E":"Brick","#800000":"Brick Red","#BC6E6E":"Mauve","#D8A3A4":"Shrimp Pink","#F8DDDD":"Shell Pink","#BF5F00":"Dark Orange","#FF7F00":"Orange","#FF9F40":"Grapefruit","#FFBF80":"Canteloupe","#FFDFBF":"Wax","#482C1B":"Dark Brick","#855A40":"Dirt","#B27C51":"Tan","#7F3F00":"Nutmeg","#C49B71":"Mustard","#E1C4A8":"Pale Tan","#FDEEE0":"Marble"},_colorPicker:null,STR_COLLAPSE:"Collapse Toolbar",STR_SPIN_LABEL:"Spin Button with value {VALUE}. Use Control Shift Up Arrow and Control Shift Down arrow keys to increase or decrease the value.",STR_SPIN_UP:"Click to increase the value of this input",STR_SPIN_DOWN:"Click to decrease the value of this input",_titlebar:null,browser:YAHOO.env.ua,_buttonList:null,_buttonGroupList:null,_sep:null,_sepCount:null,_dragHandle:null,_toolbarConfigs:{renderer:true},CLASS_CONTAINER:"yui-toolbar-container",CLASS_DRAGHANDLE:"yui-toolbar-draghandle",CLASS_SEPARATOR:"yui-toolbar-separator",CLASS_DISABLED:"yui-toolbar-disabled",CLASS_PREFIX:"yui-toolbar",init:function(f,e){YAHOO.widget.Toolbar.superclass.init.call(this,f,e)},initAttributes:function(e){YAHOO.widget.Toolbar.superclass.initAttributes.call(this,e);this.addClass(this.CLASS_CONTAINER);this.setAttributeConfig("buttonType",{value:e.buttonType||"basic",writeOnce:true,validator:function(f){switch(f){case"advanced":case"basic":return true}return false},method:function(f){if(f=="advanced"){if(YAHOO.widget.Button){this.buttonType=YAHOO.widget.ToolbarButtonAdvanced}else{this.buttonType=YAHOO.widget.ToolbarButton}}else{this.buttonType=YAHOO.widget.ToolbarButton}}});this.setAttributeConfig("buttons",{value:[],writeOnce:true,method:function(g){for(var f in g){if(d.hasOwnProperty(g,f)){if(g[f].type=="separator"){this.addSeparator()}else{if(g[f].group!==undefined){this.addButtonGroup(g[f])}else{this.addButton(g[f])}}}}}});this.setAttributeConfig("disabled",{value:false,method:function(f){if(this.get("disabled")===f){return false}if(f){this.addClass(this.CLASS_DISABLED);this.set("draggable",false);this.disableAllButtons()}else{this.removeClass(this.CLASS_DISABLED);if(this._configs.draggable._initialConfig.value){this.set("draggable",true)}this.resetAllButtons()}}});this.setAttributeConfig("cont",{value:e.cont,readOnly:true});this.setAttributeConfig("grouplabels",{value:((e.grouplabels===false)?false:true),method:function(f){if(f){c.removeClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}else{c.addClass(this.get("cont"),(this.CLASS_PREFIX+"-nogrouplabels"))}}});this.setAttributeConfig("titlebar",{value:false,method:function(g){if(g){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}this._titlebar=document.createElement("DIV");this._titlebar.tabIndex="-1";a.on(this._titlebar,"focus",function(){this._handleFocus()},this,true);c.addClass(this._titlebar,this.CLASS_PREFIX+"-titlebar");if(d.isString(g)){var f=document.createElement("h2");f.tabIndex="-1";f.innerHTML='<a href="#" tabIndex="0">'+g+"</a>";this._titlebar.appendChild(f);a.on(f.firstChild,"click",function(h){a.stopEvent(h)});a.on([f,f.firstChild],"focus",function(){this._handleFocus()},this,true)}if(this.get("firstChild")){this.insertBefore(this._titlebar,this.get("firstChild"))}else{this.appendChild(this._titlebar)}if(this.get("collapse")){this.set("collapse",true)}}else{if(this._titlebar){if(this._titlebar&&this._titlebar.parentNode){this._titlebar.parentNode.removeChild(this._titlebar)}}}}});this.setAttributeConfig("collapse",{value:false,method:function(h){if(this._titlebar){var g=null;var f=c.getElementsByClassName("collapse","span",this._titlebar);if(h){if(f.length>0){return true}g=document.createElement("SPAN");g.innerHTML="X";g.title=this.STR_COLLAPSE;c.addClass(g,"collapse");this._titlebar.appendChild(g);a.addListener(g,"click",function(){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}else{this.collapse()}},this,true)}else{g=c.getElementsByClassName("collapse","span",this._titlebar);if(g[0]){if(c.hasClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed")){this.collapse(false)}g[0].parentNode.removeChild(g[0])}}}}});this.setAttributeConfig("draggable",{value:(e.draggable||false),method:function(f){if(f&&!this.get("titlebar")){if(!this._dragHandle){this._dragHandle=document.createElement("SPAN");this._dragHandle.innerHTML="|";this._dragHandle.setAttribute("title","Click to drag the toolbar");this._dragHandle.id=this.get("id")+"_draghandle";c.addClass(this._dragHandle,this.CLASS_DRAGHANDLE);if(this.get("cont").hasChildNodes()){this.get("cont").insertBefore(this._dragHandle,this.get("cont").firstChild)}else{this.get("cont").appendChild(this._dragHandle)}this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._dragHandle.id)}}else{if(this._dragHandle){this._dragHandle.parentNode.removeChild(this._dragHandle);this._dragHandle=null;this.dd=null}}if(this._titlebar){if(f){this.dd=new YAHOO.util.DD(this.get("id"));this.dd.setHandleElId(this._titlebar);c.addClass(this._titlebar,"draggable")}else{c.removeClass(this._titlebar,"draggable");if(this.dd){this.dd.unreg();this.dd=null}}}},validator:function(g){var f=true;if(!YAHOO.util.DD){f=false}return f}})},addButtonGroup:function(j){if(!this.get("element")){this._queue[this._queue.length]=["addButtonGroup",arguments];return false}if(!this.hasClass(this.CLASS_PREFIX+"-grouped")){this.addClass(this.CLASS_PREFIX+"-grouped")}var k=document.createElement("DIV");c.addClass(k,this.CLASS_PREFIX+"-group");c.addClass(k,this.CLASS_PREFIX+"-group-"+j.group);if(j.label){var f=document.createElement("h3");f.innerHTML=j.label;k.appendChild(f)}if(!this.get("grouplabels")){c.addClass(this.get("cont"),this.CLASS_PREFIX,"-nogrouplabels")}this.get("cont").appendChild(k);var h=document.createElement("ul");k.appendChild(h);if(!this._buttonGroupList){this._buttonGroupList={}}this._buttonGroupList[j.group]=h;for(var g=0;g<j.buttons.length;g++){var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";h.appendChild(e);if((j.buttons[g].type!==undefined)&&j.buttons[g].type=="separator"){this.addSeparator(e)}else{j.buttons[g].container=e;this.addButton(j.buttons[g])}}},addButtonToGroup:function(g,h,i){var f=this._buttonGroupList[h];var e=document.createElement("li");e.className=this.CLASS_PREFIX+"-groupitem";g.container=e;this.addButton(g,i);f.appendChild(e)},addButton:function(k,j){if(!this.get("element")){this._queue[this._queue.length]=["addButton",arguments];return false}if(!this._buttonList){this._buttonList=[]}if(!k.container){k.container=this.get("cont")}if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){for(var s in k.menu){if(d.hasOwnProperty(k.menu,s)){var y={fn:function(o,i,m){if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue)},scope:this};k.menu[s].onclick=y}}}}var t={},q=false;for(var n in k){if(d.hasOwnProperty(k,n)){if(!this._toolbarConfigs[n]){t[n]=k[n]}}}if(k.type=="select"){t.type="menu"}if(k.type=="spin"){t.type="push"}if(t.type=="color"){if(YAHOO.widget.Overlay){t=this._makeColorButton(t)}else{q=true}}if(t.menu){if((YAHOO.widget.Overlay)&&(k.menu instanceof YAHOO.widget.Overlay)){k.menu.showEvent.subscribe(function(){this._button=t})}else{for(var r=0;r<t.menu.length;r++){if(!t.menu[r].value){t.menu[r].value=t.menu[r].text}}if(this.browser.webkit){t.focusmenu=false}}}if(q){k=false}else{this._configs.buttons.value[this._configs.buttons.value.length]=k;var w=new this.buttonType(t);w.get("element").tabIndex="-1";w.get("element").setAttribute("role","button");w._selected=true;if(this.get("disabled")){w.set("disabled",true)}if(!k.id){k.id=w.get("id")}if(j){var f=w.get("element");var p=null;if(j.get){p=j.get("element").nextSibling}else{if(j.nextSibling){p=j.nextSibling}}if(p){p.parentNode.insertBefore(f,p)}}w.addClass(this.CLASS_PREFIX+"-"+w.get("value"));var v=document.createElement("span");v.className=this.CLASS_PREFIX+"-icon";w.get("element").insertBefore(v,w.get("firstChild"));if(w._button.tagName.toLowerCase()=="button"){w.get("element").setAttribute("unselectable","on");var x=document.createElement("a");x.innerHTML=w._button.innerHTML;x.href="#";x.tabIndex="-1";a.on(x,"click",function(i){a.stopEvent(i)});w._button.parentNode.replaceChild(x,w._button);w._button=x}if(k.type=="select"){if(w._button.tagName.toLowerCase()=="select"){v.parentNode.removeChild(v);var g=w._button;var u=w.get("element");u.parentNode.replaceChild(g,u)}else{w.addClass(this.CLASS_PREFIX+"-select")}}if(k.type=="spin"){if(!d.isArray(k.range)){k.range=[10,100]}this._makeSpinButton(w,k)}w.get("element").setAttribute("title",w.get("label"));if(k.type!="spin"){if((YAHOO.widget.Overlay)&&(t.menu instanceof YAHOO.widget.Overlay)){var h=function(o){var i=true;if(o.keyCode&&(o.keyCode==9)){i=false}if(i){if(this._colorPicker){this._colorPicker._button=k.value}var m=w.getMenu().element;if(c.getStyle(m,"visibility")=="hidden"){w.getMenu().show()}else{w.getMenu().hide()}}YAHOO.util.Event.stopEvent(o)};w.on("mousedown",h,k,this);w.on("keydown",h,k,this)}else{if((k.type!="menu")&&(k.type!="select")){w.on("keypress",this._buttonClick,k,this);w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i);this._buttonClick(i,k)},k,this);w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)});w.on("change",function(i){if(!k.menucmd){k.menucmd=k.value}k.value=i.value;this._buttonClick(i,k)},this,true);var l=this;w.on("appendTo",function(){var i=this;if(i.getMenu()&&i.getMenu().mouseDownEvent){i.getMenu().mouseDownEvent.subscribe(function(z,o){var m=o[1];YAHOO.util.Event.stopEvent(o[0]);i._onMenuClick(o[0],i);if(!k.menucmd){k.menucmd=k.value}k.value=((m.value)?m.value:m._oText.nodeValue);l._buttonClick.call(l,o[1],k);i._hideMenu();return false});i.getMenu().clickEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])});i.getMenu().mouseUpEvent.subscribe(function(o,m){YAHOO.util.Event.stopEvent(m[0])})}})}}}else{w.on("mousedown",function(i){YAHOO.util.Event.stopEvent(i)});w.on("click",function(i){YAHOO.util.Event.stopEvent(i)})}if(this.browser.ie){}if(this.browser.webkit){w.hasFocus=function(){return true}}this._buttonList[this._buttonList.length]=w;if((k.type=="menu")||(k.type=="split")||(k.type=="select")){if(d.isArray(k.menu)){var e=w.getMenu();if(e&&e.renderEvent){e.renderEvent.subscribe(this._addMenuClasses,w);if(k.renderer){e.renderEvent.subscribe(k.renderer,w)}}}}}return k},addSeparator:function(e,h){if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}var f=((e)?e:this.get("cont"));if(!this.get("element")){this._queue[this._queue.length]=["addSeparator",arguments];return false}if(this._sepCount===null){this._sepCount=0}if(!this._sep){this._sep=document.createElement("SPAN");c.addClass(this._sep,this.CLASS_SEPARATOR);this._sep.innerHTML="|"}var g=this._sep.cloneNode(true);this._sepCount++;c.addClass(g,this.CLASS_SEPARATOR+"-"+this._sepCount);if(h){var i=null;if(h.get){i=h.get("element").nextSibling}else{if(h.nextSibling){i=h.nextSibling}else{i=h}}if(i){if(i==h){i.parentNode.appendChild(g)}else{i.parentNode.insertBefore(g,i)}}}else{f.appendChild(g)}return g},_createColorPicker:function(h){if(c.get(h+"_colors")){c.get(h+"_colors").parentNode.removeChild(c.get(h+"_colors"))}var e=document.createElement("div");e.className="yui-toolbar-colors";e.id=h+"_colors";e.style.display="none";a.on(window,"load",function(){document.body.appendChild(e)},this,true);this._colorPicker=e;var g="";for(var f in this._colorData){if(d.hasOwnProperty(this._colorData,f)){g+='<a style="background-color: '+f+'" href="#">'+f.replace("#","")+"</a>"}}g+="<span><em>X</em><strong></strong></span>";window.setTimeout(function(){e.innerHTML=g},0);a.on(e,"mouseover",function(m){var k=this._colorPicker;var l=k.getElementsByTagName("em")[0];var j=k.getElementsByTagName("strong")[0];var i=a.getTarget(m);if(i.tagName.toLowerCase()=="a"){l.style.backgroundColor=i.style.backgroundColor;j.innerHTML=this._colorData["#"+i.innerHTML]+"<br>"+i.innerHTML}},this,true);a.on(e,"focus",function(i){a.stopEvent(i)});a.on(e,"click",function(i){a.stopEvent(i)});a.on(e,"mousedown",function(j){a.stopEvent(j);var i=a.getTarget(j);if(i.tagName.toLowerCase()=="a"){var l=this.fireEvent("colorPickerClicked",{type:"colorPickerClicked",target:this,button:this._colorPicker._button,color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML]});if(l!==false){var k={color:i.innerHTML,colorName:this._colorData["#"+i.innerHTML],value:this._colorPicker._button};this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:k})}this.getButtonByValue(this._colorPicker._button).getMenu().hide()}},this,true)},_resetColorPicker:function(){var f=this._colorPicker.getElementsByTagName("em")[0];var e=this._colorPicker.getElementsByTagName("strong")[0];f.style.backgroundColor="transparent";e.innerHTML=""},_makeColorButton:function(e){if(!this._colorPicker){this._createColorPicker(this.get("id"))}e.type="color";e.menu=new YAHOO.widget.Overlay(this.get("id")+"_"+e.value+"_menu",{visible:false,position:"absolute",iframe:true});e.menu.setBody("");e.menu.render(this.get("cont"));c.addClass(e.menu.element,"yui-button-menu");c.addClass(e.menu.element,"yui-color-button-menu");e.menu.beforeShowEvent.subscribe(function(){e.menu.cfg.setProperty("zindex",5);e.menu.cfg.setProperty("context",[this.getButtonById(e.id).get("element"),"tl","bl"]);this._resetColorPicker();var f=this._colorPicker;if(f.parentNode){f.parentNode.removeChild(f)}e.menu.setBody("");e.menu.appendToBody(f);this._colorPicker.style.display="block"},this,true);return e},_makeSpinButton:function(r,l){r.addClass(this.CLASS_PREFIX+"-spinbutton");var s=this,n=r._button.parentNode.parentNode,i=l.range,h=document.createElement("a"),g=document.createElement("a");h.href="#";g.href="#";h.tabIndex="-1";g.tabIndex="-1";h.className="up";h.title=this.STR_SPIN_UP;h.innerHTML=this.STR_SPIN_UP;g.className="down";g.title=this.STR_SPIN_DOWN;g.innerHTML=this.STR_SPIN_DOWN;n.appendChild(h);n.appendChild(g);var m=YAHOO.lang.substitute(this.STR_SPIN_LABEL,{VALUE:r.get("label")});r.set("title",m);var q=function(t){t=((t<i[0])?i[0]:t);t=((t>i[1])?i[1]:t);return t};var p=this.browser;var f=false;var k=this.STR_SPIN_LABEL;if(this._titlebar&&this._titlebar.firstChild){f=this._titlebar.firstChild}var e=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v++;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var o=function(u){YAHOO.util.Event.stopEvent(u);if(!r.get("disabled")&&(u.keyCode!=9)){var v=parseInt(r.get("label"),10);v--;v=q(v);r.set("label",""+v);var t=YAHOO.lang.substitute(k,{VALUE:r.get("label")});r.set("title",t);if(!p.webkit&&f){}s._buttonClick(u,l)}};var j=function(t){if(t.keyCode==38){e(t)}else{if(t.keyCode==40){o(t)}else{if(t.keyCode==107&&t.shiftKey){e(t)}else{if(t.keyCode==109&&t.shiftKey){o(t)}}}}};r.on("keydown",j,this,true);a.on(h,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(g,"mousedown",function(t){a.stopEvent(t)},this,true);a.on(h,"click",e,this,true);a.on(g,"click",o,this,true)},_buttonClick:function(n,f){var e=true;if(n&&n.type=="keypress"){if(n.keyCode==9){e=false}else{if((n.keyCode===13)||(n.keyCode===0)||(n.keyCode===32)){}else{e=false}}}if(e){var p=true,h=false;f.isSelected=this.isSelected(f.id);if(f.value){h=this.fireEvent(f.value+"Click",{type:f.value+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(f.menucmd&&p){h=this.fireEvent(f.menucmd+"Click",{type:f.menucmd+"Click",target:this.get("element"),button:f});if(h===false){p=false}}if(p){this.fireEvent("buttonClick",{type:"buttonClick",target:this.get("element"),button:f})}if(f.type=="select"){var l=this.getButtonById(f.id);if(l.buttonType=="rich"){var k=f.value;for(var j=0;j<f.menu.length;j++){if(f.menu[j].value==f.value){k=f.menu[j].text;break}}l.set("label",'<span class="yui-toolbar-'+f.menucmd+"-"+(f.value).replace(/ /g,"-").toLowerCase()+'">'+k+"</span>");var o=l.getMenu().getItems();for(var g=0;g<o.length;g++){if(o[g].value.toLowerCase()==f.value.toLowerCase()){o[g].cfg.setProperty("checked",true)}else{o[g].cfg.setProperty("checked",false)}}}}if(n){a.stopEvent(n)}}},_keyNav:null,_navCounter:null,_navigateButtons:function(f){switch(f.keyCode){case 37:case 39:if(f.keyCode==37){this._navCounter--}else{this._navCounter++}if(this._navCounter>(this._buttonList.length-1)){this._navCounter=0}if(this._navCounter<0){this._navCounter=(this._buttonList.length-1)}if(this._buttonList[this._navCounter]){var e=this._buttonList[this._navCounter].get("element");if(this.browser.ie){e=this._buttonList[this._navCounter].get("element").getElementsByTagName("a")[0]}if(this._buttonList[this._navCounter].get("disabled")){this._navigateButtons(f)}else{e.focus()}}break}},_handleFocus:function(){if(!this._keyNav){var e="keypress";if(this.browser.ie){e="keydown"}a.on(this.get("element"),e,this._navigateButtons,this,true);this._keyNav=true;this._navCounter=-1}},getButtonById:function(g){var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==g){return this._buttonList[f]}}return false},getButtonByValue:function(n){var h=this.get("buttons");var f=h.length;for(var k=0;k<f;k++){if(h[k].group!==undefined){for(var e=0;e<h[k].buttons.length;e++){if((h[k].buttons[e].value==n)||(h[k].buttons[e].menucmd==n)){return this.getButtonById(h[k].buttons[e].id)}if(h[k].buttons[e].menu){for(var l=0;l<h[k].buttons[e].menu.length;l++){if(h[k].buttons[e].menu[l].value==n){return this.getButtonById(h[k].buttons[e].id)}}}}}else{if((h[k].value==n)||(h[k].menucmd==n)){return this.getButtonById(h[k].id)}if(h[k].menu){for(var g=0;g<h[k].menu.length;g++){if(h[k].menu[g].value==n){return this.getButtonById(h[k].id)}}}}}return false},getButtonByIndex:function(e){if(this._buttonList[e]){return this._buttonList[e]}else{return false}},getButtons:function(){return this._buttonList},disableButton:function(f){var e=b.call(this,f);if(e){e.set("disabled",true)}else{return false}},enableButton:function(f){if(this.get("disabled")){return false}var e=b.call(this,f);if(e){if(e.get("disabled")){e.set("disabled",false)}}else{return false}},isSelected:function(f){var e=b.call(this,f);if(e){return e._selected}return false},selectButton:function(i,g){var f=b.call(this,i);if(f){f.addClass("yui-button-selected");f.addClass("yui-button-"+f.get("value")+"-selected");f._selected=true;if(g){if(f.buttonType=="rich"){var h=f.getMenu().getItems();for(var e=0;e<h.length;e++){if(h[e].value==g){h[e].cfg.setProperty("checked",true);f.set("label",'<span class="yui-toolbar-'+f.get("value")+"-"+(g).replace(/ /g,"-").toLowerCase()+'">'+h[e]._oText.nodeValue+"</span>")}else{h[e].cfg.setProperty("checked",false)}}}}}else{return false}},deselectButton:function(f){var e=b.call(this,f);if(e){e.removeClass("yui-button-selected");e.removeClass("yui-button-"+e.get("value")+"-selected");e.removeClass("yui-button-hover");e._selected=false}else{return false}},deselectAllButtons:function(){var e=this._buttonList.length;for(var f=0;f<e;f++){this.deselectButton(this._buttonList[f])}},disableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.disableButton(this._buttonList[f])}},enableAllButtons:function(){if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){this.enableButton(this._buttonList[f])}},resetAllButtons:function(j){if(!d.isObject(j)){j={}}if(this.get("disabled")){return false}var e=this._buttonList.length;for(var f=0;f<e;f++){var h=this._buttonList[f];if(h){var g=h._configs.disabled._initialConfig.value;if(j[h.get("id")]){this.enableButton(h);this.selectButton(h)}else{if(g){this.disableButton(h)}else{this.enableButton(h)}this.deselectButton(h)}}}},destroyButton:function(j){var g=b.call(this,j);if(g){var h=g.get("id");g.destroy();var e=this._buttonList.length;for(var f=0;f<e;f++){if(this._buttonList[f]&&this._buttonList[f].get("id")==h){this._buttonList[f]=null}}}else{return false}},destroy:function(){this.get("element").innerHTML="";this.get("element").className="";for(var e in this){if(d.hasOwnProperty(this,e)){this[e]=null}}return true},collapse:function(f){var e=c.getElementsByClassName("collapse","span",this._titlebar);if(f===false){c.removeClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");if(e[0]){c.removeClass(e[0],"collapsed")}this.fireEvent("toolbarExpanded",{type:"toolbarExpanded",target:this})}else{if(e[0]){c.addClass(e[0],"collapsed")}c.addClass(this.get("cont").parentNode,"yui-toolbar-container-collapsed");this.fireEvent("toolbarCollapsed",{type:"toolbarCollapsed",target:this})}},toString:function(){return"Toolbar (#"+this.get("element").id+") with "+this._buttonList.length+" buttons."}})})();(function(){var c=YAHOO.util.Dom,a=YAHOO.util.Event,d=YAHOO.lang,b=YAHOO.widget.Toolbar;YAHOO.widget.SimpleEditor=function(h,m){var g={};if(d.isObject(h)&&(!h.tagName)&&!m){d.augmentObject(g,h);h=document.createElement("textarea");this.DOMReady=true;if(g.container){var k=c.get(g.container);k.appendChild(h)}else{document.body.appendChild(h)}}else{if(m){d.augmentObject(g,m)}}var i={element:null,attributes:g},f=null;if(d.isString(h)){f=h}else{if(i.attributes.id){f=i.attributes.id}else{this.DOMReady=true;f=c.generateId(h)}}i.element=h;var j=document.createElement("DIV");i.attributes.element_cont=new YAHOO.util.Element(j,{id:f+"_container"});var e=document.createElement("div");c.addClass(e,"first-child");i.attributes.element_cont.appendChild(e);if(!i.attributes.toolbar_cont){i.attributes.toolbar_cont=document.createElement("DIV");i.attributes.toolbar_cont.id=f+"_toolbar";e.appendChild(i.attributes.toolbar_cont)}var l=document.createElement("DIV");e.appendChild(l);i.attributes.editor_wrapper=l;YAHOO.widget.SimpleEditor.superclass.constructor.call(this,i.element,i.attributes)};YAHOO.extend(YAHOO.widget.SimpleEditor,YAHOO.util.Element,{_resizeConfig:{handles:["br"],autoRatio:true,status:true,proxy:true,useShim:true,setSize:false},_setupResize:function(){if(!YAHOO.util.DD||!YAHOO.util.Resize){return false}if(this.get("resize")){var e={};d.augmentObject(e,this._resizeConfig);this.resize=new YAHOO.util.Resize(this.get("element_cont").get("element"),e);this.resize.on("resize",function(g){var l=this.get("animate");this.set("animate",false);this.set("width",g.width+"px");var i=g.height,j=(this.toolbar.get("element").clientHeight+2),k=0;if(this.dompath){k=(this.dompath.clientHeight+1)}var f=(i-j-k);this.set("height",f+"px");this.get("element_cont").setStyle("height","");this.set("animate",l)},this,true)}},resize:null,_setupDD:function(){if(!YAHOO.util.DD){return false}if(this.get("drag")){var f=this.get("drag"),e=YAHOO.util.DD;if(f==="proxy"){e=YAHOO.util.DDProxy}this.dd=new e(this.get("element_cont").get("element"));this.toolbar.addClass("draggable");this.dd.setHandleElId(this.toolbar._titlebar)}},dd:null,_lastCommand:null,_undoNodeChange:function(){},_storeUndo:function(){},_checkKey:function(f,j){var g=false;if((j.keyCode===f.key)){if(f.mods&&(f.mods.length>0)){var l=0;for(var h=0;h<f.mods.length;h++){if(this.browser.mac){if(f.mods[h]=="ctrl"){f.mods[h]="meta"}}if(j[f.mods[h]+"Key"]===true){l++}}if(l===f.mods.length){g=true}}else{g=true}}return g},_keyMap:{SELECT_ALL:{key:65,mods:["ctrl"]},CLOSE_WINDOW:{key:87,mods:["shift","ctrl"]},FOCUS_TOOLBAR:{key:27,mods:["shift"]},FOCUS_AFTER:{key:27},CREATE_LINK:{key:76,mods:["shift","ctrl"]},BOLD:{key:66,mods:["shift","ctrl"]},ITALIC:{key:73,mods:["shift","ctrl"]},UNDERLINE:{key:85,mods:["shift","ctrl"]},UNDO:{key:90,mods:["ctrl"]},REDO:{key:90,mods:["shift","ctrl"]},JUSTIFY_LEFT:{key:219,mods:["shift","ctrl"]},JUSTIFY_CENTER:{key:220,mods:["shift","ctrl"]},JUSTIFY_RIGHT:{key:221,mods:["shift","ctrl"]}},_cleanClassName:function(e){return e.replace(/ /g,"-").toLowerCase()},_textarea:null,_docType:'<!DOCTYPE HTML PUBLIC "-
|
}(),_lastImage:null,_blankImageLoaded:null,_fixNodesTimer:null,_nodeChangeTimer:null,_lastNodeChangeEvent:null,_lastNodeChange:0,_rendered:null,DOMReady:null,_selection:null,_mask:null,_showingHiddenElements:null,currentWindow:null,currentEvent:null,operaEvent:null,currentFont:null,currentElement:null,dompath:null,beforeElement:null,afterElement:null,invalidHTML:{form:true,input:true,button:true,select:true,link:true,html:true,body:true,iframe:true,script:true,style:true,textarea:true},toolbar:null,_contentTimer:null,_contentTimerCounter:0,_disabled:["createlink","fontname","fontsize","forecolor","backcolor"],_alwaysDisabled:{undo:true,redo:true},_alwaysEnabled:{},_semantic:{"bold":true,"italic":true,"underline":true},_tag2cmd:{"b":"bold","strong":"bold","i":"italic","em":"italic","u":"underline","sup":"superscript","sub":"subscript","img":"insertimage","a":"createlink","ul":"insertunorderedlist","ol":"insertorderedlist"},_createIframe:function(){var I=document.createElement("iframe");I.id=this.get("id")+"_editor";var G={border:"0",frameBorder:"0",marginWidth:"0",marginHeight:"0",leftMargin:"0",topMargin:"0",allowTransparency:"true",width:"100%"};if(this.get("autoHeight")){G.scrolling="no";}for(var H in G){if(D.hasOwnProperty(G,H)){I.setAttribute(H,G[H]);}}var F="javascript:;";if(this.browser.ie){F="javascript:false;";}I.setAttribute("src",F);var E=new YAHOO.util.Element(I);E.setStyle("visibility","hidden");return E;},_isElement:function(F,E){if(F&&F.tagName&&(F.tagName.toLowerCase()==E)){return true;}if(F&&F.getAttribute&&(F.getAttribute("tag")==E)){return true;}return false;},_hasParent:function(F,E){if(!F||!F.parentNode){return false;}while(F.parentNode){if(this._isElement(F,E)){return F;}if(F.parentNode){F=F.parentNode;}else{return false;}}return false;},_getDoc:function(){var E=false;if(this.get){if(this.get("iframe")){if(this.get("iframe").get){if(this.get("iframe").get("element")){try{if(this.get("iframe").get("element").contentWindow){if(this.get("iframe").get("element").contentWindow.document){E=this.get("iframe").get("element").contentWindow.document;return E;}}}catch(F){}}}}}return false;},_getWindow:function(){return this.get("iframe").get("element").contentWindow;},_focusWindow:function(E){if(this.browser.webkit){if(E){this._getSelection().setBaseAndExtent(this._getDoc().body.firstChild,0,this._getDoc().body.firstChild,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}else{this._getSelection().setBaseAndExtent(this._getDoc().body,1,this._getDoc().body,1);if(this.browser.webkit3){this._getSelection().collapseToStart();}else{this._getSelection().collapse(false);}}this._getWindow().focus();}else{this._getWindow().focus();}},_hasSelection:function(){var G=this._getSelection();var E=this._getRange();var F=false;if(!G||!E){return F;}if(this.browser.ie||this.browser.opera){if(E.text){F=true;}if(E.html){F=true;}}else{if(this.browser.webkit){if(G+""!==""){F=true;}}else{if(G&&(G.toString()!=="")&&(G!==undefined)){F=true;}}}return F;},_getSelection:function(){var E=null;if(this._getDoc()&&this._getWindow()){if(this._getDoc().selection){E=this._getDoc().selection;}else{E=this._getWindow().getSelection();}if(this.browser.webkit){if(E.baseNode){this._selection={};this._selection.baseNode=E.baseNode;this._selection.baseOffset=E.baseOffset;this._selection.extentNode=E.extentNode;this._selection.extentOffset=E.extentOffset;}else{if(this._selection!==null){E=this._getWindow().getSelection();E.setBaseAndExtent(this._selection.baseNode,this._selection.baseOffset,this._selection.extentNode,this._selection.extentOffset);this._selection=null;}}}}return E;},_selectNode:function(F,I){if(!F){return false;}var G=this._getSelection(),E=null;if(this.browser.ie){try{E=this._getDoc().body.createTextRange();E.moveToElementText(F);E.select();}catch(H){}}else{if(this.browser.webkit){if(I){G.setBaseAndExtent(F,1,F,F.innerText.length);}else{G.setBaseAndExtent(F,0,F,F.innerText.length);}}else{if(this.browser.opera){G=this._getWindow().getSelection();E=this._getDoc().createRange();E.selectNode(F);G.removeAllRanges();G.addRange(E);}else{E=this._getDoc().createRange();E.selectNodeContents(F);G.removeAllRanges();G.addRange(E);}}}this.nodeChange();},_getRange:function(){var E=this._getSelection();if(E===null){return null;}if(this.browser.webkit&&!E.getRangeAt){var H=this._getDoc().createRange();try{H.setStart(E.anchorNode,E.anchorOffset);H.setEnd(E.focusNode,E.focusOffset);}catch(G){H=this._getWindow().getSelection()+"";}return H;}if(this.browser.ie||this.browser.opera){try{return E.createRange();}catch(F){return null;}}if(E.rangeCount>0){return E.getRangeAt(0);}return null;},_setDesignMode:function(E){try{var G=true;if(this.browser.ie&&(E.toLowerCase()=="off")){G=false;}if(G){this._getDoc().designMode=E;}}catch(F){}},_toggleDesignMode:function(){var F=this._getDoc().designMode.toLowerCase(),E="on";if(F=="on"){E="off";}this._setDesignMode(E);return E;},_initEditorEvents:function(){var E=this._getDoc();A.on(E,"mouseup",this._handleMouseUp,this,true);A.on(E,"mousedown",this._handleMouseDown,this,true);A.on(E,"click",this._handleClick,this,true);A.on(E,"dblclick",this._handleDoubleClick,this,true);A.on(E,"keypress",this._handleKeyPress,this,true);A.on(E,"keyup",this._handleKeyUp,this,true);A.on(E,"keydown",this._handleKeyDown,this,true);},_removeEditorEvents:function(){var E=this._getDoc();A.removeListener(E,"mouseup",this._handleMouseUp,this,true);A.removeListener(E,"mousedown",this._handleMouseDown,this,true);A.removeListener(E,"click",this._handleClick,this,true);A.removeListener(E,"dblclick",this._handleDoubleClick,this,true);A.removeListener(E,"keypress",this._handleKeyPress,this,true);A.removeListener(E,"keyup",this._handleKeyUp,this,true);A.removeListener(E,"keydown",this._handleKeyDown,this,true);},_initEditor:function(){if(this.browser.ie){this._getDoc().body.style.margin="0";}if(!this.get("disabled")){if(this._getDoc().designMode.toLowerCase()!="on"){this._setDesignMode("on");
|
this._createView = function(property, placeholderElement) { var view; if (property.type) { var itemReference = new common.ItemReference(this._item, property.type, property.name); view = new browser.ItemReferenceView(itemReference, property.type); } else { view = new browser.ItemValueView(this._item, property.name); }
|
this._createView = function(viewProperties, placeholderElement) { var view = browser.views.viewFactory.getView(this._item, viewProperties.name, viewProperties.args);
|
this._createView = function(property, placeholderElement) { var view; if (property.type) { // the property is an item reference var itemReference = new common.ItemReference(this._item, property.type, property.name); view = new browser.ItemReferenceView(itemReference, property.type); } else { view = new browser.ItemValueView(this._item, property.name); } dom.replace(placeholderElement, view.getElement()); this._propertyViews.push(view); }
|
default: throw logger.error("Unkown operation "+ operation)
|
default: throw logger.error("Unknown operation for deserialization " + operation)
|
this._deserializeMutation = function(mutation) { var args = mutation.args, operation = mutation.op switch(operation) { case 'set': case 'append': for (var i=0; i < args.length; i++) { args[i] = JSON.parse(args[i]) } break case 'splice': var items = args[0] for (var i=0; i < items.length; i++) { items[i] = JSON.parse(items[i]) } break default: throw logger.error("Unkown operation "+ operation) } }
|
this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex");
|
a.icons.header).prependTo(this.headers);this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex");
|
this.active.children(".ui-icon").toggleClass(a.icons.header).toggleClass(a.icons.headerSelected);this.element.addClass("ui-accordion-icons")}},_destroyIcons:function(){this.headers.children(".ui-icon").remove();this.element.removeClass("ui-accordion-icons")},destroy:function(){var a=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-accordion-disabled ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabIndex");
|
var isModal = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-modal"); var hasClose = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-close-true"); var isDraggable = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-draggable-true"); var isVisible = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-visible-true"); var isMinimal = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-appearance-minimal");
|
var isModal = YAHOO.util.Dom.hasClass(dialog, "xforms-dialog-modal"); var hasClose = YAHOO.util.Dom.hasClass(dialog, "xforms-dialog-close-true"); var isDraggable = YAHOO.util.Dom.hasClass(dialog, "xforms-dialog-draggable-true"); var isVisible = YAHOO.util.Dom.hasClass(dialog, "xforms-dialog-visible-true"); var isMinimal = YAHOO.util.Dom.hasClass(dialog, "xforms-dialog-appearance-minimal");
|
_dialog: function(dialog) { var isModal = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-modal"); var hasClose = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-close-true"); var isDraggable = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-draggable-true"); var isVisible = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-visible-true"); var isMinimal = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-appearance-minimal"); // If we already have a dialog for the same id, first destroy it, as this is an object left behind // by a deleted repeat iteration if (ORBEON.xforms.Globals.dialogs[dialog.id]) ORBEON.xforms.Globals.dialogs[dialog.id].destroy(); // Create dialog object var yuiDialog; if (isMinimal) { // Create minimal dialog yuiDialog = new YAHOO.widget.Dialog(dialog.id, { modal: isModal, close: false, visible: false, draggable: false, fixedcenter: false, constraintoviewport: true, underlay: "none", usearia: true, role: "alertdialog" }); // Close the dialog when users click on document YAHOO.util.Event.addListener(document.body, "click", ORBEON.xforms.Events.dialogMinimalBodyClick, yuiDialog); } else { // Create full dialog yuiDialog = new YAHOO.widget.Dialog(dialog.id, { modal: isModal, close: hasClose, visible: false, draggable: isDraggable, fixedcenter: false, constraintoviewport: true, underlay: "none", // Similarly, setting the underlay to "shadow" conflicts with the CSS used to limit the width and height of the dialog on IE6 usearia: true, role: "alertdialog" }); yuiDialog.showEvent.subscribe(ORBEON.xforms.Events.dialogShow, dialog.id); // Register listener for when the dialog is closed by a click on the "x" yuiDialog.beforeHideEvent.subscribe(ORBEON.xforms.Events.dialogClose, dialog.id); } // Move the dialog under the form element, as if the dialog is inside another absolute block it can be cropped // (can't escape that block), and in some cases the mask can show on top of the dialog (even if the z-index // for the dialog is higher than the z-index for the mask). See: // http://forge.ow2.org/tracker/index.php?func=detail&aid=314943&group_id=168&atid=350207 var form = ORBEON.xforms.Controls.getForm(yuiDialog.element); if (yuiDialog.element.parentNode != form) form.appendChild(yuiDialog.element); ORBEON.xforms.Globals.dialogs[dialog.id] = yuiDialog; if (isVisible) ORBEON.xforms.Controls.showDialog(dialog.id, null); }
|
if (ORBEON.xforms.Globals.dialogs[dialog.id]) ORBEON.xforms.Globals.dialogs[dialog.id].destroy();
|
_dialog: function(dialog) { var isModal = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-modal"); var hasClose = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-close-true"); var isDraggable = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-draggable-true"); var isVisible = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-visible-true"); var isMinimal = ORBEON.util.Dom.hasClass(dialog, "xforms-dialog-appearance-minimal"); // Create dialog object var yuiDialog; if (isMinimal) { // Create minimal dialog yuiDialog = new YAHOO.widget.Dialog(dialog.id, { modal: isModal, close: false, visible: false, draggable: false, fixedcenter: false, constraintoviewport: true, underlay: "none" }); // Close the dialog when users click on document YAHOO.util.Event.addListener(document.body, "click", ORBEON.xforms.Events.dialogMinimalBodyClick, yuiDialog); } else { // Create full dialog yuiDialog = new YAHOO.widget.Dialog(dialog.id, { modal: isModal, close: hasClose, visible: false, draggable: isDraggable, fixedcenter: false, constraintoviewport: true, underlay: "none" // Similarly, setting the underlay to "shadow" conflicts with the CSS used to limit the width and height of the dialog on IE6 }); yuiDialog.showEvent.subscribe(ORBEON.xforms.Events.dialogShow, dialog.id); // Register listener for when the dialog is closed by a click on the "x" yuiDialog.beforeHideEvent.subscribe(ORBEON.xforms.Events.dialogClose, dialog.id); } // Move the dialog under the form element, as if the dialog is inside another absolute block it can be cropped // (can't escape that block), and in some cases the mask can show on top of the dialog (even if the z-index // for the dialog is higher than the z-index for the mask). See: // http://forge.ow2.org/tracker/index.php?func=detail&aid=314943&group_id=168&atid=350207 var form = ORBEON.xforms.Controls.getForm(yuiDialog.element); if (yuiDialog.element.parentNode != form) form.appendChild(yuiDialog.element); ORBEON.xforms.Globals.dialogs[dialog.id] = yuiDialog; if (isVisible) ORBEON.xforms.Controls.showDialog(dialog.id, null); }
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.