[jboss-svn-commits] JBoss PortletSwap SVN: r192 - in portlets/src/framework/RichFacesPortlet/src/main/webapp: css and 3 other directories.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Wed Jan 9 17:53:32 EST 2008


Author: wesleyhales
Date: 2008-01-09 17:53:31 -0500 (Wed, 09 Jan 2008)
New Revision: 192

Added:
   portlets/src/framework/RichFacesPortlet/src/main/webapp/css/temp.css
   portlets/src/framework/RichFacesPortlet/src/main/webapp/js/framework.pack.js
   portlets/src/framework/RichFacesPortlet/src/main/webapp/js/ui.pack.js
Modified:
   portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/jboss-portlet.xml
   portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/web.xml
   portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/include/header.xhtml
   portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/main.xhtml
Log:
ui cleanup and temporary js fix

Modified: portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/jboss-portlet.xml
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/jboss-portlet.xml	2008-01-09 18:08:25 UTC (rev 191)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/jboss-portlet.xml	2008-01-09 22:53:31 UTC (rev 192)
@@ -5,5 +5,10 @@
    "http://www.jboss.org/portal/dtd/jboss-portlet_2_6.dtd"><portlet-app>
     <portlet>
          <portlet-name>ajaxPortlet</portlet-name>
+        <header-content>
+            <script src="/js/framework.pack.js" type="text/javascript"/>
+            <script src="/js/ui.pack.js" type="text/javascript"/>
+            <link rel="stylesheet" type="text/css" href="/css/temp.css" media="screen" />
+    </header-content>
     </portlet>
 </portlet-app> 
\ No newline at end of file

Modified: portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/web.xml
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/web.xml	2008-01-09 18:08:25 UTC (rev 191)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/WEB-INF/web.xml	2008-01-09 22:53:31 UTC (rev 192)
@@ -22,7 +22,7 @@
 	</context-param>
 	<context-param>
 		<param-name>org.richfaces.LoadScriptStrategy</param-name>
-		<param-value>ALL</param-value>
+		<param-value>NONE</param-value>
 	</context-param>
 
 
@@ -93,6 +93,10 @@
       <servlet-name>FacesServlet</servlet-name>
       <url-pattern>/faces/*</url-pattern>
    </servlet-mapping>
+   <servlet-mapping>
+      <servlet-name>FacesServlet</servlet-name>
+      <url-pattern>*.jsf</url-pattern>
+   </servlet-mapping>
    <mime-mapping>
       <extension>svg</extension>
       <mime-type>image/svg+xml</mime-type>

Added: portlets/src/framework/RichFacesPortlet/src/main/webapp/css/temp.css
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/css/temp.css	                        (rev 0)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/css/temp.css	2008-01-09 22:53:31 UTC (rev 192)
@@ -0,0 +1 @@
+.drgind_fly{z-index:1000;top:40;left:40;position:absolute;}.drgind_internal{opacity:.93;filter:alpha(opacity=93);position:absolute;}.drgind_wordcut{padding:0 0 0 3px;width:200px;overflow:hidden;float:left;white-space:nowrap;}.drgind_text{border-top-width:1px;border-top-style:solid;border-bottom-width:2px;border-bottom-style:solid;border-right-width:2px;border-right-style:solid;}.drgind_marker{border-top-width:1px;border-top-style:solid;border-bottom-width:2px;border-bottom-style:solid;border-left-width:1px;border-left-style:solid;vertical-align:top;}.rich-dragindicator-iframe{position:absolute;display:block;z-index:1;top:0;left:0;}.drgind_reject .drgind_marker{background-color:#EF6771;border-top-color:#96000B;border-left-color:#96000B;border-bottom-color:#96000B;vertical-align:top;}.drgind_accept .drgind_marker,.drgind_default .drgind_marker{background-color:#9CDC48;border-top-color:#589900;border-left-color:#589900;border-bottom-color:#589900;vertical-align:top;}.drgind_te!
 xt{border-top-color:#BED6F8;border-bottom-color:#BED6F8;border-right-color:#BED6F8;background-color:#F2F7FF;color:#000;}.drgind_text_content{color:#000;font-weight:bold;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-pnl{border-width:1px;border-style:solid;padding:1px;}.dr-pnl-h{padding:2px;border-width:1px;border-style:solid;background-position:top left;background-repeat:repeat-x;}.dr-pnl-b{padding:10px;}.dr-pnl{background-color:#FFF;border-color:#BED6F8;}.dr-pnl-h{background-color:#BED6F8;border-color:#BED6F8;font-size:11px;color:#000;font-weight:bold;font-family:Arial,Verdana,sans-serif;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-pnl-b{font-size:11px;color:#000;font-family:Arial,Verdana,sans-serif;}.dr-pnlbar{border:1px solid;padding:1px;}.dr-pnlbar-ext{border-bottom:0!important;}.dr-pnlbar-h{border:0 solid red;padding:0 1px 1px 5px;cursor:pointer;}.dr-pnlbar-h-act{border:0 sol!
 id red;padding:0 1px 1px 5px;cursor:pointer;}.dr-pnlbar-c{padding:10px
;text-align:left;vertical-align:top;}.dr-pnlbar-b{border-top-width:0!important;border-left-width:0!important;border-right-width:0!important;padding:0;}.dr-pnlbar{border-color:#BED6F8;}.dr-pnlbar-h{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);background-position:top left;background-repeat:repeat-x;vertical-align:middle;color:#000;background-color:#BED6F8;font-size:11px;font-weight:bold;font-family:Arial,Verdana,sans-serif;}.dr-pnlbar-h-act{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);background-position:top left;background-repeat:repeat-x;vertical-align:middle;color:#000;background-color:#BED6F8;font-size:11px;font-weight:bold;font-family:Arial,Verdana,sans-serif;}.dr-pnlbar-c{color:#000;}.dr-pnlbar-ext{background-color:#FFF;}.slider-container{background-color:transparent;width:100%;position:relative;}.range{background!
 -color:transparent;height:10px;overflow:hidden;float:left;border-width:1px;border-style:solid;}.range-decor{height:100%;width:100%;border-width:1px;border-style:solid;}.trailer{background-color:transparent;background-position:top right;background-repeat:repeat-x;height:10px;}.track{background-color:transparent;height:8px;overflow:hidden;position:absolute;}.handle{position:absolute;width:10px;height:8px;background-color:transparent;line-height:1px;font-size:1px;}.slider-input-field{border:1px solid;background:left top repeat-x;padding:0 0 0 3px;width:40px;margin:0 0 0 10px;float:left;}.range{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SliderTrackGradient/DATB/eAH7f-.Y....ARNoBaE_.jsf);border-color:#BED6F8;}.range{border-color:#fff;}.trailer{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg/richfaces/renderkit/html/images/sldr_trailer3_bg.gif.jsf);}.slider-input-field{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSH!
 OTorg.richfaces.renderkit.html.images.SliderFieldGradient/DATB/eAH79-X
N....ARRoBdw_.jsf);background-color:#fff;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;border-color:#BED6F8;border-bottom-color:#fff;border-right-color:#fff;}.dr-gmap{width:400px;height:400px;}.dr-ve{width:400px;height:400px;}.rich-tabpanel{width:100%;}.dr-tbpnl-cntnt{border-bottom-width:1px;border-bottom-style:solid;border-left-width:1px;border-left-style:solid;border-right-width:1px;border-right-style:solid;vertical-align:top;}.dr-tbpnl-tbtopbrdr{border-top-width:1px;border-top-style:solid;}.dr-tbpnl-tb{padding:2px 10px 2px 10px;text-align:center;}.dr-tbpnl-tbbrdr{background-repeat:no-repeat;background-position:top;}.dr-tbpnl-tb-act{border-width:1px;border-style:solid;padding:3px 10px 4px 10px;background-repeat:repeat-x;background-position:top;border-bottom-width:0;cursor:default;}.dr-tbpnl-tb-dsbld{border-width:1px;border-style:solid;background-repeat:repeat-x;background-position:top;cursor:default;}.dr-tbpnl-tbcell-dsbld,.dr-tbpnl-tbcell-inact{padding-to!
 p:2px;}.dr-tbpnl-tb{color:#000;font-size:11px;font-family:Arial,Verdana,sans-serif;}.dr-tbpnl-tb-act{color:#000;border-color:#fff;}.dr-tbpnl-tb-dsbl{border-color:#fff;color:#8DB7F3;}.dr-tbpnl-tb-sel{border-width:1px;border-style:solid;border-bottom:0;background-repeat:repeat-x;background-position:top;cursor:default;}.dr-tbpnl-tb-dsbl{background-repeat:repeat-x;background-position:center top;}.dr-tbpnl-cntnt-pstn{height:100%;}.dr-tbpnl-tb-sel{border-color:#E79A00;}.dr-tbpnl-tbtopbrdr{border-top-color:#BED6F8;}.dr-tbpnl-cntnt{background-color:#FFF;color:#000;border-bottom-color:#BED6F8;border-right-color:#BED6F8;border-left-color:#BED6F8;font-size:11px;font-family:Arial,Verdana,sans-serif;}.dr-tbpnl-tb-dsbl{background-color:#C6DEFF;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.images.TabGradientB/DATB/eAH7.....3vHABR2BaE_.jsf);}.dr-tbpnl-tb-inact{background-color:#C6DEFF;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.rend!
 erkit.images.TabGradientB/DATB/eAH7.....3vHABR2BaE_.jsf);border-color:
#fff;border-width:1px;border-style:solid;background-repeat:repeat-x;background-position:top;border-bottom-width:0;cursor:default;}.dr-bottom-line{border-bottom-color:#BED6F8;border-bottom-style:solid;border-bottom-width:1px;}.dr-tbpnl-tb-act{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.images.TabGradientA/DATB/eAH7f-.Y....ARNoBaE_.jsf);background-color:#FFF;}.dr-tbpnl-tbbrdr{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.images.TabStripeImage/DATB/eAH7cW0fAAVVAo0_.jsf);}.dr-tbpnl-tb-sel{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.images.TabGradientB/DATB/eAH7.....3vHABR2BaE_.jsf);border-color:#E79A00;}.dr-stglpnl{border-width:1px;border-style:solid;padding:1px;background-position:top right;background-repeat:no-repeat;}.dr-stglpnl-m{padding-right:3px;}.dr-stglpnl-h{border-width:1px;border-style:solid;cursor:pointer;padding:2px;background-position:top left;background-repeat:rep!
 eat-x;}.dr-stglpnl-b{padding:10px;text-align:left;vertical-align:top;}.dr-stglpanel-marker{float:right;}.dr-stglpnl{background-color:#FFF;border-color:#BED6F8;}.dr-stglpnl-h{background-color:#BED6F8;border-color:#BED6F8;font-size:11px;color:#000;font-weight:bold;font-family:Arial,Verdana,sans-serif;}.dr-stglpnl-b{background-color:#FFF;font-size:11px;font-family:Arial,Verdana,sans-serif;}.dr-stglpnl-h{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-toolbar-ext{border:1px solid;border-color:#BED6F8;padding:0;background-color:#BED6F8;background-position:top left;background-repeat:repeat-x;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-toolbar-int{font-size:11px;color:#000;font-weight:bold;font-family:Arial,Verdana,sans-serif;padding:2px 10px 2px 10px;white-space:nowrap;}.dr-insldr{width:200px;height:20px;}.dr-insld!
 r-tip{position:absolute;white-space:nowrap;padding:0 2px 0 2px;border:
1px solid;}.dr-insldr-size{width:100%;}.dr-insldr-left-num{text-align:left;border-left:1px solid;padding:0 3px 0 3px;}.dr-insldr-right-num{text-align:right;border-right:1px solid;padding:0 3px 0 3px;}.dr-insldr-vert-spacer{padding-top:3px;}.dr-insldr-handler{background-color:transparent;width:7px;height:8px;font-size:1px;position:absolute;text-align:center;z-index:1;}.dr-insldr-handler-sel{background-color:transparent;width:7px;height:8px;font-size:1px;position:absolute;text-align:center;z-index:1;}.dr-insldr-track{background-position:left top;background-repeat:repeat-x;height:8px;font-size:1px;}.dr-insldr-track-decor-1{height:100%;width:100%;border:1px solid;}.dr-insldr-track-decor-2{border:1px solid white;}.dr-insldr-field{border:1px solid;padding:0 0 0 3px;margin-top:0;margin-bottom:0;background-position:left top;background-repeat:repeat-x;}.dr-insldr-field-left{margin-right:10px;}.dr-insldr-field-right{margin-left:10px;}.dr-insldr-tip{background-color:#FAE6B0;border-colo!
 r:#E5973E;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-insldr-left-num{font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;border-color:#BED6F8;line-height:11px;}.dr-insldr-right-num{font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;border-color:#BED6F8;line-height:11px;}.dr-insldr-track{background-color:#fff;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SliderTrackGradient/DATB/eAH7f-.Y....ARNoBaE_.jsf);}.dr-insldr-track-decor-1{border-color:#BED6F8;}.dr-insldr-handler{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SliderArrowImage/DATB/eAH7z8DAAAAEAAEA.jsf);}.dr-insldr-handler-sel{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SliderArrowSelectedImage/DATA/eAFb85aBtbiIQTArsSxRLycxL13PM68kNT21SOjRgiXfG9stmBgYPRlYyxJzSlMrihgEEOr8SnOTUova1kyV5Z7yoJuJgaGi4P.T6XYAt6AedA__.jsf);}.dr-insldr-track-decor-2{border-c!
 olor:#fff;}.dr-insldr-field{background-image:url(/richfaces-demo/a4j_3
_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SliderFieldGradient/DATB/eAH79-XN....ARRoBdw_.jsf);background-color:#fff;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;border-color:#BED6F8;border-bottom-color:#fff;border-right-color:#fff;}.dr-spnr-e{padding:0;margin:0;background-position:left top;background-repeat:repeat-x;border-style:solid;border-width:1px 0 1px 1px;}.dr-spnr-i{border:0;padding:0 0 0 3px;background:none transparent scroll repeat 0 0;margin:0;}.dr-spnr-b{border-width:1px;border-style:solid;padding:0;margin:0;background-position:left top;background-repeat:repeat-x;font-size:0;}.dr-spnr-bn{margin:0 1px 1px 0;display:block;}.dr-spnr-bp{margin:1px 0 0 1px;display:block;}.dr-spnr-b{background-color:#BED6F8;border-color:#BED6F8;}.dr-spnr-i{font-size:11;font-family:Arial,Verdana,sans-serif;}.dr-spnr-e{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SpinnerFieldGradient/DATB/eAH79-XN....ARRoBdw_.jsf);backg!
 round-color:#fff;border-color:#BED6F8;border-bottom-color:#fff;border-right-color:#fff;}.dr-spnr-b{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SpinnerButtonGradient/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-tree-full-width{width:100%;}.dr-tree-layout-on{zoom:1;}.dr-tree-h-input{display:none;}.dr-tree-h-ic-div{margin-left:8px;padding-left:10px;}.dr-tree-h-ic{width:16px;padding:1px;}.dr-tree-h-ic-img{width:16px;height:16px;}.dr-tree-h-ic-img-md{margin:0;display:block;}.dr-tree-h-ic-facets{overflow:hidden;}.dr-tree-h-ic-line{background-position:left;background-repeat:repeat-y;}.dr-tree-h-ic-line-node,.dr-tree-h-ic-line-last,.dr-tree-h-ic-line-exp,.dr-tree-h-ic-line-clp{background-position:center;background-repeat:no-repeat;}.dr-tree-h-text{width:100%;cursor:default;padding:1px 4px 1px 4px;white-space:nowrap;}.dr-tree-h-text-span{white-space:nowrap;}.dr-tree-i-sel{padding:0 3px 0 3px;border:1px solid;background-color:transparent;backgrou!
 nd-position:top left;background-repeat:repeat-x;}.dr-tree-i-hl{text-de
coration:underline;}.dr-tree-pointer-cursor{cursor:pointer;}.dr-tree-last-node-marker{display:none;}.dr-tree-i-hl{color:#E79A00;}.dr-tree-i-sel{border-color:#BED6F8;}.dr-tree-h-ic-line{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.TreeLineImage/DATB/eAH7....72fXGBgYACWpBbU_.jsf);}.dr-tree-h-ic-line-node{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.TreeLineNodeImage/DATB/eAH7....72fXGBgYACWpBbU_.jsf);}.dr-tree-h-ic-line-last{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.TreeLineLastImage/DATB/eAH7....72fXGBgYACWpBbU_.jsf);}p.dr-tree-last-node-marker+* .dr-tree-h-ic-line-node{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.TreeLineLastImage/DATB/eAH7....72fXGBgYACWpBbU_.jsf);}p.dr-tree-last-node-marker+*+div.dr-tree-h-ic-line{background-image:none;}.dr-tree-h-ic-line-exp{background-image:url(/richface!
 s-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.TreeLineExpandedImage/DATB/eAH7....72fXGBgYACWpBbU_.jsf);}.dr-tree-h-ic-line-clp{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.TreeLineCollapsedImage/DATB/eAH7....72fXGBgYACWpBbU_.jsf);}.dr-tree-i-sel .dr-tree-i-hl{color:#E79A00;}.dr-sb-common-container{position:absolute;text-align:left;background-color:inherit;}.dr-sb-ext-decor-1{position:absolute;height:100%;width:100%;z-index:2;}.dr-sb-ext-decor-2{border:1px solid;height:100%;width:100%;}.dr-sb-ext-decor-3{height:100%;width:100%;}.dr-sb-overflow{overflow-y:auto;overflow-x:auto;}.dr-sb-int-decor-table{width:100%;}.dr-sb-shadow{position:absolute;height:100%;width:100%;border:1px solid;z-index:1;}.dr-sb-int-sel{cursor:default;background-position:left top;background-repeat:repeat-x;}.dr-sb-cell-padding{padding:1px 3px 1px 5px;}.dr-sb-ext-decor-2{border-color:#BED6F8;background-color:#ECF4FE;}.dr-sb-shadow{background-colo!
 r:#000;border-color:#000;opacity:1;}.dr-sb-int{font-size:11px;font-fam
ily:Arial,Verdana,sans-serif;color:#000;}.dr-sb-int-sel{background-color:#BED6F8;font-size:11px;font-family:Arial,Verdana,sans-serif;color:#000;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-table{border-top:solid 1px #C0C0C0;border-left:solid 1px #C0C0C0;background-color:#FFF;empty-cells:show;border-collapse:collapse;}.dr-table-cell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;font-size:11px;color:#000;font-family:Arial,Verdana,sans-serif;}.dr-subtable-cell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;font-size:11px;color:#000;font-family:Arial,Verdana,sans-serif;}.dr-table-header{background-color:#BED6F8;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);background-position:top left;background-repeat:repeat-x;}.dr-table-header-continue{!
 background-color:#BED6F8;}.dr-table-headercell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;color:#000;text-align:center;font-weight:bold;font-size:11px;font-family:Arial,Verdana,sans-serif;}.dr-table-subheader{background-color:#ECF4FE;}.dr-table-subheadercell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;text-align:center;font-size:11px;color:#000;font-family:Arial,Verdana,sans-serif;}.dr-table-footer{background-color:#ccc;}.dr-table-footer-continue{background-color:#ccc;}.dr-table-footercell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;color:#000;text-align:left;font-weight:bold;font-size:11px;font-family:Arial,Verdana,sans-serif;}.dr-table-subfooter{background-color:#f1f1f1;}.dr-table-subfootercell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;text-align:left;font-size:11px;color:#000;font-family:Arial,Verda!
 na,sans-serif;}.dr-subtable-header{background-color:#ECF4FE;}.dr-subta
ble-headercell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;text-align:center;font-size:11px;color:#000;font-family:Arial,Verdana,sans-serif;}.dr-subtable-footer{background-color:#f1f1f1;}.dr-subtable-footercell{border-right:solid 1px #C0C0C0;border-bottom:solid 1px #C0C0C0;padding:4px 4px 4px 4px;text-align:left;}.dr-mpnl-mask-div{position:fixed;top:0;left:0;border:0;margin:0;padding:0;width:100%;height:100%;border-style:none;background-color:#d0d0d0;filter:alpha(opacity=50);opacity:.5;}.dr-mpnl-panel{position:fixed;margin:0;padding:0;background-color:inherit;}.dr-mpnl-resizer{line-height:1px;font-size:1px;position:absolute;}.dr-mpnl-header{height:20px;}.dr-mpnl-pnl-a{position:absolute;left:-32000px;}.dr-mpnl-spacer,.dr-mpnl-resizer{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg/richfaces/renderkit/html/images/spacer.gif.jsf);}.dr-mpnl-pnl{border-width:1px;border-style:solid;padding:1px;background-color:inherit;}.dr-mpnl!
 -pnl-h{padding:2px;border-width:1px;border-style:solid;background-position:top left;background-repeat:repeat-x;}.dr-mpnl-pnl-b{padding:10px;}.dr-mpnl-shadow{position:absolute;height:100%;width:100%;border:1px solid;z-index:1;}.dr-mpnl-pnl{background-color:#FFF;border-color:#BED6F8;}.dr-mpnl-pnl-h{background-color:#BED6F8;border-color:#BED6F8;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-mpnl-pnl-text{font-size:11px;color:#000;font-weight:bold;font-family:Arial,Verdana,sans-serif;}.dr-mpnl-pnl-b{font-size:11px;color:#000;font-family:Arial,Verdana,sans-serif;}.dr-mpnl-shadow{background-color:#000;border-color:#000;opacity:1;}.dr-dscr-t{border-width:1px;border-style:solid;}.dr-dscr-button,.dr-dscr-sepctrl{border-width:1px;border-style:solid;width:25px;cursor:pointer;text-align:center;}.dr-dscr-act{border-top-width:2px;border-top-style:solid;width:25px;text-align:center;}.dr-dscr-inact{border-to!
 p-width:2px;border-top-style:solid;width:25px;cursor:pointer;text-alig
n:center;}.dr-stglpnl{background-color:#FFF;border-color:#BED6F8;}.dr-dscr-button,.dr-dscr-sepctrl{background-color:#ECF4FE;border-color:#BED6F8;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-dscr-button-dsbld{color:#BED6F8;}.dr-dscr-act{border-top-color:#000;color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-dscr-inact{border-top-color:#BED6F8;color:#BED6F8;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-dscr-t{border-color:#BED6F8;background-color:#FFF;}.dr-menu-separator{font-size:0;border-top:1px solid;margin:2px 0 2px 24px;}.dr-menu-item{padding:1px 35px 1px 1px;white-space:nowrap;position:relative;}.dr-menu-item-enabled{border:0 solid transparent;padding:2px 36px 2px 2px;}.dr-menu-item-hover{border:1px solid;cursor:pointer;}.dr-menu-item-disabled{border:0 solid transparent;cursor:default;}.dr-menu-icon{margin-right:10px;}.dr-menu-icon img{vertical-align:middle;}.dr-menu-item a{text-decoration:none;}.dr-menu-node{position:absolute;wid!
 th:16px;height:16px;font-size:1px;top:1px;right:1px;}.dr-menu-item-disabled .dr-menu-node{background-position:bottom;}.dr-menu-list-border{border:1px solid;float:left;position:absolute;}.dr-menu-list-bg{border-top-style:solid;border-left-style:solid;border-right-style:solid;border-top-width:1px;border-left-width:1px;border-right-width:1px;background:repeat-y left;}.dr-menu-label{left:0;top:0;padding:2px 5px 2px 5px;white-space:nowrap;width:auto;height:auto;}.dr-menu-label-unselect{border:0 solid transparent;padding:3px 6px;}.dr-menu-label-select{border:1px solid;cursor:pointer;}.dr-menu-list-strut{font-size:0;border:0;margin:0;position:relative;}.underneath_iframe{position:absolute;z-index:90;visibility:hidden;left:0;top:0;height:1px;width:1px;}.dr-menu-separator{border-top-color:#BED6F8;}.dr-menu-item,.dr-menu-item a{color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-menu-item-disabled{color:#8DB7F3;}.dr-menu-item-hover{background-position:top left;backgro!
 und-repeat:repeat-x;border-color:#E5973E;background-color:#FAE6B0;}.dr
-menu-node-icon{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.MenuNodeImage/DATB/eAFjYGD4vL0XAATaAjg_.jsf);}.dr-label-text-decor{font-weight:bold;}.dr-menu-list-border{border-color:#BED6F8;background-color:#ECF4FE;}.dr-menu-list-bg{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.background.MenuListBackground/DATB/eAH79-XN.3vHABPtBYI_.jsf);border-top-color:#ECF4FE;border-left-color:#ECF4FE;border-right-color:#ECF4FE;}.dr-menu-label{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-menu-label-select{border-color:#BED6F8;background-color:#fff;color:#000;}.dr-menu-list-border{border:1px solid;float:left;position:absolute;}.dr-menu-list-bg{border-top-style:solid;border-left-style:solid;border-right-style:solid;border-top-width:1px;border-left-width:1px;border-right-width:1px;background:repeat-y left;}.dr-menu-label{left:0;top:0;padding:2px 5px 2px 5px;white-space:nowrap;width:auto;heigh!
 t:auto;}.dr-menu-label-unselect{border:0 solid transparent;padding:3px 6px;}.dr-menu-label-select{border:1px solid;cursor:pointer;}.dr-menu-list-strut{font-size:0;border:0;margin:0;position:relative;}.underneath_iframe{position:absolute;z-index:90;visibility:hidden;left:0;top:0;height:1px;width:1px;}.dr-label-text-decor{font-weight:bold;}.dr-menu-list-border{border-color:#BED6F8;background-color:#ECF4FE;}.dr-menu-list-bg{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.background.MenuListBackground/DATB/eAH79-XN.3vHABPtBYI_.jsf);border-top-color:#ECF4FE;border-left-color:#ECF4FE;border-right-color:#ECF4FE;}.dr-menu-label{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-menu-label-select{border-color:#BED6F8;background-color:#fff;color:#000;}.dr-ddmenu-label-disabled{color:#8DB7F3;}.dr-rich-tool-tip{background-color:#FAE6B0;padding:7px;border:1px solid;border-color:#E5973E;font-size:11px;font-family:Arial,Verdana,sans-serif;f!
 loat:left;}.dr-pmenu-top-group{height:20px;width:100%;background-repea
t:repeat-x;background-position:left top;padding:2px 1px 2px 2px;cursor:pointer;}.dr-pmenu-group{padding:2px 1px 1px;margin-top:1px;cursor:pointer;border-top:1px solid;}.dr-pmenu-item{border-top:1px solid;cursor:pointer;padding:2px 1px 1px;margin-top:1px;}.dr-pmenu-top-group-div{border:1px solid;margin-bottom:3px;padding:1px;}.dr-pmenu-group-self-label{padding-left:5px;width:100%;}.dr-pmenu-nowrap{white-space:nowrap;}.dr-pmenu-top-group{font-weight:bold;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;background-color:#BED6F8;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.PanelMenuGroupGradient/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.dr-pmenu-group{font-weight:bold;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;border-top-color:#C0C0C0;}.dr-pmenu-item{font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;border-top-color:#BED6F8;}.dr-pmenu-top-group-div{border-color:#BED6F8;}.dr-pmenu-disabled!
 -element{color:#8DB7F3;}.dr-pmenu-hovered-element{background-color:#ECF4FE;}.dr-pmenu-disabled-element{cursor:default;}.dr-pmenu-selected-item{font-style:italic;}.rich-calendar-exterior{border:1px solid;}.rich-calendar-btn{cursor:pointer;}.rich-calendar-header-optional{border-bottom:1px solid;padding:7px;height:22px;font-weight:bold;}.rich-calendar-header{border-right:0 solid;border-bottom:1px solid;}.rich-calendar-cell-size{width:25px;height:22px;}.rich-calendar-cell-div{overflow:hidden;}.rich-calendar-cell{border-bottom:1px solid;border-right:1px solid;padding:0;vertical-align:middle;text-align:center;}.rich-calendar-tool{vertical-align:middle;text-align:center;width:20px;height:22px;}.rich-calendar-month{vertical-align:middle;text-align:center;}.rich-calendar-days{border-bottom:1px solid;border-right:0 solid;vertical-align:middle;text-align:center;height:22px;}.rich-calendar-week{border-bottom:1px solid;border-right:1px solid;vertical-align:middle;text-align:center;width!
 :25px;}.rich-right-cell{border-right:0;}.rich-bottom-cell{border-botto
m:0;}.rich-calendar-toolfooter{height:22px;padding:1px 2px 1px 1px;}.rich-calendar-footer-optional{border-top:1px solid;border-right:0 solid;padding:7px;height:22px;font-weight:bold;}.rich-calendar-footer{border-top:1px solid;border-right:0 solid;}.rich-calendar-spinner-input{border:0;padding:0 0 0 3px;background:none transparent scroll repeat 0 0;}.rich-calendar-spinner-input-container{background-position:left top;background-repeat:repeat-x;border:1px solid;}.rich-calendar-spinner-buttons{border-width:1px;border-style:solid;background-position:left top;background-repeat:repeat-x;font-size:0;}.rich-calendar-exterior{border-color:#BED6F8;}.rich-calendar-header-optional{border-bottom-color:#BED6F8;background-color:#ECF4FE;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-header{border-bottom-color:#BED6F8;background-color:#ECF4FE;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-cell{border-bottom-color:#BED6F8;border-right-color:#BED6F8;bac!
 kground-color:#FFF;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-tool{background-color:#BED6F8;font-size:11px;font-family:Arial,Verdana,sans-serif;font-weight:bold;color:#000;}.rich-calendar-month{background-color:#BED6F8;font-size:11px;font-family:Arial,Verdana,sans-serif;font-weight:bold;color:#000;white-space:nowrap;}.rich-calendar-days{border-bottom-color:#BED6F8;border-right-color:#BED6F8;background:#ECF4FE;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-weekends{color:red;}.rich-calendar-week{background:#ECF4FE;border-bottom-color:#BED6F8;background-color:#F5F5F5;border-right-color:#BED6F8;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-holly{background-color:#FFEBDA;color:#FF7800;}.rich-calendar-boundary-dates{color:#a0a0a0;}.rich-calendar-today{background-color:#FF7800;color:#FFEBDA;font-weight:bold;}.rich-calendar-select{background-color:#BED6F8;color:#000;font-weight:bold;}.rich-calendar-hover{backgroun!
 d-color:#E4F5E2;color:#000;}.rich-calendar-toolfooter{background:#ECF4
FE;font-size:11px;font-family:Arial,Verdana,sans-serif;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.iconimages.CalendarSeparator/DATB/eAFjYGAAAAADAAE_.jsf);background-repeat:no-repeat;background-position:right center;}.rich-calendar-tool-btn{cursor:pointer;padding:2px 3px 2px 3px;white-space:nowrap;}.rich-calendar-tool-btn-hover{background-color:#F5F5F5;color:#000;border:1px solid;border-color:#FFF;border-right-color:#BED6F8;border-bottom-color:#BED6F8;padding:1px 2px 1px 2px;}.rich-calendar-tool-btn-press{border-color:#BED6F8;border-right-color:#FFF;border-bottom-color:#FFF;}.rich-calendar-footer-optional{border-top-color:#BED6F8;border-right-color:#BED6F8;background:#ECF4FE;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-footer{border-top-color:#BED6F8;border-right-color:#BED6F8;background:#ECF4FE;font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-tool-close{padding:2px 2px 2px 4px;background-image!
 :url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.iconimages.CalendarSeparator/DATB/eAFjYGAAAAADAAE_.jsf);background-repeat:no-repeat;background-position:left center;}.rich-calendar-button{cursor:pointer;vertical-align:middle;}.rich-calendar-editor-shadow{background:#FFF;opacity:.5;filter:alpha(opacity=50);}.rich-calendar-time-layout{background:#ECF4FE;border:1px solid;border-color:#BED6F8;position:relative;}.rich-calendar-time-layout,.rich-calendar-time-layout input{font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-calendar-time-layout-fields{padding:7px 7px 5px 7px;white-space:nowrap;}.rich-calendar-time-layout-cancel{padding:0 7px 7px 1px;}.rich-calendar-time-layout-ok{padding:0 1px 7px 7px;}.rich-calendar-time-btn{width:45px;border:1px solid;border-color:#FFF;border-right-color:#BED6F8;border-bottom-color:#BED6F8;text-align:center;padding:2px;white-space:nowrap;text-align:center;cursor:pointer;}.rich-calendar-time-btn-press{border:1px solid;bo!
 rder-color:#BED6F8;border-right-color:#FFF;border-bottom-color:#FFF;ba
ckground-color:#F5F5F5;}.rich-calendar-time-input{width:22px;margin:0 2px;}.rich-calendar-spinner-up{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SpinnerButtonUp/DATB/eAFjYGAAAAADAAE_.jsf);height:7px;width:14px;margin:0 1px 1px 0;}.rich-calendar-spinner-down{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SpinnerButtonDown/DATB/eAFjYGAAAAADAAE_.jsf);height:7px;width:14px;margin:0 1px 1px 0;}.rich-calendar-spinner-pressed{margin:1px 0 0 1px;}.rich-calendar-spinner-buttons{background-color:#BED6F8;border-color:#BED6F8;background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SpinnerButtonGradient/DATB/eAH7..3Tj2v7ABPtBXU_.jsf);}.rich-calendar-spinner-input{font-size:11;font-family:Arial,Verdana,sans-serif;width:18px;}.rich-calendar-spinner-input-container{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.images.SpinnerField!
 Gradient/DATB/eAH79-XN....ARRoBdw_.jsf);background-color:#fff;border-color:#BED6F8;border-bottom-color:#fff;border-right-color:#fff;}.rich-calendar-editor-layout-shadow{background-color:#000;opacity:.3;filter:alpha(opacity=30);position:absolute;}.rich-calendar-editor-btn{width:40px;padding:2px;text-align:center;}.rich-calendar-editor-btn-over{padding:1px;border:1px solid;border-color:#BED6F8;cursor:pointer;}.rich-calendar-editor-btn-selected{background-color:#FF7800;color:#FFEBDA;font-weight:bold;}.dr-sdt-sort-asc,.dr-sdt-sort-desc{width:16px;height:6px;background-position:50% 50%;background-repeat:no-repeat;}.dr-sdt-sort-icon{position:absolute;visibility:hidden;}.dr-sdt{padding:0;margin:0;z-index:0;border-style:solid;}.dr-sdt-hr{z-index:2;}.dr-sdt-hc{-o-text-overflow:ellipsis;text-overflow:ellipsis;overflow:hidden;font-weight:normal;cursor:default;box-sizing:border-box;-moz-box-sizing:border-box;-moz-outline:none;-moz-user-focus:normal;padding:0;white-space:nowrap;border-b!
 ottom-style:solid;border-right-style:solid;}.dr-sdt-hc .sort-asc,.dr-s
dt-hc .sort-desc{background-position:right;background-repeat:no-repeat;width:16px!important;;position:absolute;}.dr-sdt-hsep{background-position:center;background-repeat:repeat-y;cursor:e-resize;font-size:1px;top:15%;width:6px;height:13px;overflow:hidden;position:absolute;display:block;white-space:nowrap;z-index:60;}.dr-sdt-hsplit{width:1px;border-right:1px dashed;cursor:col-resize;z-index:100;}.dr-sdt-hcbody{white-space:nowrap;overflow:hidden;width:100%;font-weight:normal;}.dr-sdt-fb{z-index:50;}.dr-sdt-nb{z-index:20;}.dr-sdt-fr{font-weight:normal;height:22px;border-top:1px solid #cbc7b8;}.dr-sdt-fc{-o-text-overflow:ellipsis;text-overflow:ellipsis;overflow:hidden;font-weight:normal;cursor:default;box-sizing:border-box;-moz-box-sizing:border-box;-moz-outline:none;-moz-user-focus:normal;border-right:1px solid;height:21px!important;padding:0;white-space:nowrap;}.dr-sdt-fcbody{cursor:default;font-weight:normal;padding:3px 5px;white-space:nowrap;overflow:hidden;}.dr-sdt-fcbody1{!
 cursor:default;font-weight:normal;padding:0;white-space:nowrap;overflow:hidden;width:100%;}.dr-sdt-bc{box-sizing:border-box;-moz-box-sizing:border-box;-moz-outline:none;-moz-user-focus:normal;cursor:default;border-right:1px solid;border-bottom:1px solid;}.dr-sdt-ho{position:absolute;height:10px;width:10px;}.dr-sdt-rb{font-weight:normal;white-space:nowrap;box-sizing:border-box;-moz-box-sizing:border-box;}.dr-sdt-bcbody{cursor:default;font-weight:normal;white-space:nowrap;overflow:hidden;-o-text-overflow:ellipsis;text-overflow:ellipsis;-moz-box-sizing:border-box;-moz-outline:none;width:100%;height:20px;}.dr-sdt-substrate{z-index:48;filter:Alpha(opacity=0);position:absolute;top:0;left:0;display:block;}.dr-sdt-tmplbox{display:block;float:left;}.dr-sdt-inlinebox{position:relative;display:block;overflow:hidden;}.dr-sdt{background-color:#FFF;border-color:#C0C0C0;border-width:1px;}.dr-sdt-hr{background-color:#BED6F8;}.dr-sdt-hc{color:#000;font-family:Arial,Verdana,sans-serif;font-s!
 ize:11px;border-bottom-width:1px;border-bottom-color:#C0C0C0;border-ri
ght-width:1px;border-right-color:#C0C0C0;}.dr-sdt-hsplit{border-right-color:#E5973E;}.dr-sdt-hcbody{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-fr{background-color:#f1f1f1;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-fc{border-right-color:#C0C0C0;font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-fcbody{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-fcbody1{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-bc{border-right-color:#C0C0C0;border-bottom-color:#C0C0C0;}.dr-sdt-rb{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-row-selected{background-color:#ECF4FE;}.dr-sdt-row-active{color:#8DB7F3;}.dr-sdt-bcbody{font-family:Arial,Verdana,sans-serif;font-size:11px;}.dr-sdt-sort-asc{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.iconimages.ScrollableDataTableIconSortAsc/DATB/eAFjYGD4cW0fAAVYAo0_.jsf);}.dr-sdt-sort-desc{background-image:url(/richfaces-demo/a4j_3_2_0!
 -SNAPSHOTorg.richfaces.renderkit.html.iconimages.ScrollableDataTableIconSortDesc/DATB/eAFjYGD4cW0fAAVYAo0_.jsf);}.dr-sdt-hsep{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.iconimages.ScrollableDataTableIconSplit/DATB/eAFjYGD4cW0fAAVYAo0_.jsf);}.rich-ordering-control-disabled{border:1px solid;margin-bottom:3px;}.rich-ordering-control-top{border:1px solid;margin-bottom:3px;}.rich-ordering-control-bottom{border:1px solid;margin-bottom:3px;}.rich-ordering-control-up{border:1px solid;margin-bottom:3px;}.rich-ordering-control-down{border:1px solid;margin-bottom:3px;}.rich-ordering-list-button{background:top left repeat-x;cursor:pointer;padding:2px;}.rich-ordering-list-button-disabled{background:top left repeat-x;padding:2px;}.rich-ordering-list-button-light{background:top left repeat-x;border-style:solid;cursor:pointer;padding:1px;}.rich-ordering-list-button-press{background:top left repeat-x;border-style:solid;padding:2px 0 0 2px;}.rich-orde!
 ring-list-button-valign{vertical-align:middle;}.rich-ordering-list-but
ton-layout{padding:15px 8px 15px 0;}.rich-ordering-list-button-content{padding:0 4px 0 1px;text-align:left;white-space:nowrap;}.rich-ordering-list-button-content img{margin-right:2px;vertical-align:middle;}a.rich-ordering-list-button-selection:visited,a.rich-ordering-list-button-selection:link,a.rich-ordering-list-button-a-disabled:visited,a.rich-ordering-list-button-a-disabled:link{color:inherit;}.rich-ordering-list-button-a-disabled{cursor:default;text-decoration:none;}.rich-ordering-list-caption{text-align:left;height:8px;padding:3px 3px 3px 8px;}.rich-ordering-list-body{border:0 solid;}.rich-ordering-list-output{border:1px solid;margin:0 8px 8px 8px;background:none repeat scroll 0 50%;}.rich-ordering-list-content{overflow:auto;}.rich-ordering-list-header{overflow:hidden;}.rich-ordering-list-items{width:100%;}.rich-ordering-list-active{background:repeat scroll left top;width:100%;}.rich-ordering-list-disabled{background:repeat scroll left top;width:100%;}.rich-ordering-li!
 st-row-active{background:transparent none repeat-x scroll left top;width:100%;}.rich-ordering-list-row-selected{background:transparent none repeat-x scroll left top;width:100%;}.rich-ordering-list-table-header-cell,.rich-ordering-list-table-header-cell-last{white-space:nowrap;background-repeat:repeat-x;border-style:solid;padding:2px;font-weight:normal;border-top:0;border-left:0;}.rich-ordering-list-cell{padding:2px;white-space:nowrap;}.rich-ordering-list-cell-selected{padding:2px 2px;white-space:nowrap;}.rich-ordering-list-cell-active{padding:1px 2px;white-space:nowrap;border-top:1px dotted;border-bottom:1px dotted;}.rich-ordering-list-ds{-moz-user-select:-moz-none;}.rich-ordering-list-ds input{-moz-user-select:text;}.rich-ordering-list-button{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListButtonGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;color:#000;font-family:Arial,Verdana,sans-serif;font!
 -size:11px;}.rich-ordering-list-button-disabled{background-image:url(/
richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListButtonGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;color:#8DB7F3;font-family:Arial,Verdana,sans-serif;font-size:11px;}.rich-ordering-list-button-light{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListButtonGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;border-color:#E79A00;border-width:1px;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;}.rich-ordering-list-button-press{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListClickedGradient/DATB/eAH7f-.Y....ARNoBaE_.jsf);background-color:#C6DEFF;border-color:#C0C0C0;border-width:1px;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;}.rich-ordering-list-table-header-cell,.rich-ordering-list-table-header-cell-last{background-image:url(/richfaces-demo/a4j_3_2_0!
 -SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListHeaderGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;border-right-width:1px;border-bottom-width:1px;border-right-color:#C0C0C0;border-bottom-color:#C0C0C0;}.rich-ordering-list-table-header-cell-last{border-right-width:0;}.rich-ordering-list-output{background-color:#FFF;border-color:#C0C0C0;border-width:1px;}.rich-ordering-list-cell,.rich-ordering-list-cell *{color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;}.rich-ordering-list-cell-selected,.rich-ordering-list-cell-selected *{color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;}.rich-ordering-list-cell-active *{font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-ordering-list-cell-active{font-size:11px;font-family:Arial,Verdana,sans-serif;border-top-color:#000;border-bottom-color:#000;}.rich-ordering-control-disabled,.rich-ordering-control-top,.rich!
 -ordering-control-bottom,.rich-ordering-control-up,.rich-ordering-cont
rol-down{border-color:#C0C0C0;}.rich-ordering-list-button-content{font-family:Arial,Verdana,sans-serif;font-size:11px;}.rich-ordering-list-button-selection{color:#000;text-decoration:none;display:block;}.rich-ordering-list-caption{font-family:Arial,Verdana,sans-serif;font-size:11px;font-weight:bold;}.rich-ordering-list-row-selected{background-color:#ECF4FE;}.rich-shuttle-controls{padding:0 8px 5px 8px;}.rich-shuttle-list-content{overflow:auto;}.rich-shuttle-list-header{overflow:hidden;}.rich-shuttle-header-tab-cell,.rich-shuttle-header-tab-cell-last{padding:2px;border-style:solid;font-weight:normal;white-space:nowrap;background-repeat:repeat-x;border-top:0;border-left:0;}.rich-shuttle-internal-tab{width:100%;}.body{-moz-user-select:none;}.rich-shuttle-list{background-color:#FFF;border-width:0;border-style:none;}.rich-shuttle-source-cell,.rich-shuttle-target-cell,.rich-shuttle-source-cell *,.rich-shuttle-target-cell *{color:#000;font-size:11px;font-family:Arial,Verdana,sans-s!
 erif;white-space:nowrap;}.rich-shuttle-control-disabled,.rich-shuttle-control-top,.rich-shuttle-control-bottom,.rich-shuttle-control-up,.rich-shuttle-control-down,.rich-shuttle-control-copyall,.rich-shuttle-control-copy,.rich-shuttle-control-remove,.rich-shuttle-control-removeall{border:1px solid;margin-bottom:3px;}.rich-list-shuttle-button,.rich-list-shuttle-button-disabled{background:top left repeat-x;padding:2px;}.rich-list-shuttle-button{cursor:pointer;}.rich-list-shuttle-button-light{background:top left repeat-x;border-style:solid;cursor:pointer;padding:1px;}.rich-list-shuttle-button-press{background:top left repeat-x;border-style:solid;padding:2px 0 0 2px;}.rich-list-shuttle-button-valign{vertical-align:middle;}.rich-list-shuttle-button-layout{padding:15px 8px 15px 0;}.rich-list-shuttle-button-content{padding:0 4px 0 1px;text-align:left;white-space:nowrap;}.rich-list-shuttle-button-content img{margin-right:2px;vertical-align:middle;}a.rich-list-shuttle-button-selectio!
 n:visited,a.rich-list-shuttle-button-selection:link{color:inherit;}.ri
ch-list-shuttle-button-a-disabled{cursor:default;text-decoration:none;}.rich-list-shuttle-caption{text-align:left;padding:1px;}.rich-shuttle-source-caption{padding:3px 3px 3px 8px;}.rich-shuttle-target-caption{padding:3px 3px 3px 0;}.rich-shuttle-source-items{margin:0 0 8px 8px;}.rich-shuttle-target-items{margin:0 0 8px 0;}.rich-shuttle-source-row-active,.rich-shuttle-target-row-active{background:transparent none repeat-x scroll left top;}.rich-shuttle-source-row-selected,.rich-shuttle-target-row-selected{background:transparent none repeat-x scroll left top;}.rich-shuttle-source-cell,.rich-shuttle-target-cell{padding:2px;white-space:nowrap;border:0;}.rich-shuttle-source-cell-selected,.rich-shuttle-target-cell-selected{padding:2px;white-space:nowrap;}.rich-shuttle-source-cell-active,.rich-shuttle-target-cell-active{padding:1px 2px;white-space:nowrap;border-top:1px dotted;border-bottom:1px dotted;}.rich-list-shuttle{-moz-user-select:-moz-none;}.rich-shuttle-header-tab-cell,.ri!
 ch-shuttle-header-tab-cell-last{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListHeaderGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;border-right-width:1px;border-bottom-width:1px;border-right-color:#C0C0C0;border-bottom-color:#C0C0C0;}.rich-shuttle-header-tab-cell-last{border-right-width:0;}.rich-list-shuttle-button{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListButtonGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;color:#000;font-family:Arial,Verdana,sans-serif;font-size:11px;}.rich-list-shuttle-button-disabled{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListButtonGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;color:#8DB7F3;font-family:Arial,Verdana,sans-serif;font-size:1!
 1px;}.rich-list-shuttle-button-light{background-image:url(/richfaces-d
emo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListButtonGradient/DATB/eAH7.....3vHABR2BaE_.jsf);background-color:#C6DEFF;border-color:#E79A00;border-width:1px;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;}.rich-list-shuttle-button-press{background-image:url(/richfaces-demo/a4j_3_2_0-SNAPSHOTorg.richfaces.renderkit.html.gradientimages.OrderingListClickedGradient/DATB/eAH7f-.Y....ARNoBaE_.jsf);background-color:#C6DEFF;border-color:#C0C0C0;border-width:1px;font-family:Arial,Verdana,sans-serif;font-size:11px;color:#000;}.rich-shuttle-source-cell-last,.rich-shuttle-target-cell-last{border-right-color:#E79A00;}.rich-shuttle-source-items,.rich-shuttle-target-items{background-color:#FFF;border-color:#C0C0C0;border-width:1px;border-style:solid;}.rich-shuttle-source-cell-selected,.rich-shuttle-target-cell-selected,.rich-shuttle-source-cell-selected *,.rich-shuttle-target-cell-selected *{color:#000;font-family:Arial,Verdana,sans-serif;font-!
 size:11px;}.rich-shuttle-source-cell-active,.rich-shuttle-target-cell-active,.rich-shuttle-source-cell-active *,.rich-shuttle-target-cell-active *{font-size:11px;font-family:Arial,Verdana,sans-serif;}.rich-shuttle-source-cell-active,.rich-shuttle-target-cell-active{border-top-color:#000;border-bottom-color:#000;}.rich-shuttle-control-disabled,.rich-shuttle-control-top,.rich-shuttle-control-bottom,.rich-shuttle-control-up,.rich-shuttle-control-down,.rich-shuttle-control-copyall,.rich-shuttle-control-copy,.rich-shuttle-control-remove,.rich-shuttle-control-removeall{border-color:#C0C0C0;}.rich-list-shuttle-button-content{font-family:Arial,Verdana,sans-serif;font-size:11px;}.rich-list-shuttle-button-selection{color:#000;text-decoration:none;display:block;}a.rich-list-shuttle-button-a-disabled a{color:#8DB7F3;}.rich-shuttle-source-caption,.rich-shuttle-target-caption{font-family:Arial,Verdana,sans-serif;font-size:11px;font-weight:bold;}.rich-shuttle-source-row-selected,.rich-shu!
 ttle-target-row-selected{background-color:#ECF4FE;}
\ No newline at end of file

Added: portlets/src/framework/RichFacesPortlet/src/main/webapp/js/framework.pack.js
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/js/framework.pack.js	                        (rev 0)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/js/framework.pack.js	2008-01-09 22:53:31 UTC (rev 192)
@@ -0,0 +1,5846 @@
+var Prototype={Version:"1.6.0",Browser:{IE:!!(window.attachEvent&&!window.opera),Opera:!!window.opera,WebKit:navigator.userAgent.indexOf("AppleWebKit/")>-1,Gecko:navigator.userAgent.indexOf("Gecko")>-1&&navigator.userAgent.indexOf("KHTML")==-1,MobileSafari:!!navigator.userAgent.match(/Apple.*Mobile.*Safari/)},BrowserFeatures:{XPath:!!document.evaluate,ElementExtensions:!!window.HTMLElement,SpecificElementExtensions:document.createElement("div").__proto__&&document.createElement("div").__proto__!==document.createElement("form").__proto__},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(A){return A
+}};
+if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false
+}if(Prototype.Browser.WebKit){Prototype.BrowserFeatures.XPath=false
+}var Class={create:function(){var E=null,D=$A(arguments);
+if(Object.isFunction(D[0])){E=D.shift()
+}function A(){this.initialize.apply(this,arguments)
+}Object.extend(A,Class.Methods);
+A.superclass=E;
+A.subclasses=[];
+if(E){var B=function(){};
+B.prototype=E.prototype;
+A.prototype=new B;
+E.subclasses.push(A)
+}for(var C=0;
+C<D.length;
+C++){A.addMethods(D[C])
+}if(!A.prototype.initialize){A.prototype.initialize=Prototype.emptyFunction
+}A.prototype.constructor=A;
+return A
+}};
+Class.Methods={addMethods:function(G){var C=this.superclass&&this.superclass.prototype;
+var B=Object.keys(G);
+if(!Object.keys({toString:true}).length){B.push("toString","valueOf")
+}for(var A=0,D=B.length;
+A<D;
+A++){var F=B[A],E=G[F];
+if(C&&Object.isFunction(E)&&E.argumentNames().first()=="$super"){var H=E,E=Object.extend((function(I){return function(){return C[I].apply(this,arguments)
+}
+})(F).wrap(H),{valueOf:function(){return H
+},toString:function(){return H.toString()
+}})
+}this.prototype[F]=E
+}return this
+}};
+var Abstract={};
+Object.extend=function(A,C){for(var B in C){A[B]=C[B]
+}return A
+};
+Object.extend(Object,{inspect:function(A){try{if(A===undefined){return"undefined"
+}if(A===null){return"null"
+}return A.inspect?A.inspect():A.toString()
+}catch(B){if(B instanceof RangeError){return"..."
+}throw B
+}},toJSON:function(A){var C=typeof A;
+switch(C){case"undefined":case"function":case"unknown":return ;
+case"boolean":return A.toString()
+}if(A===null){return"null"
+}if(A.toJSON){return A.toJSON()
+}if(Object.isElement(A)){return 
+}var B=[];
+for(var E in A){var D=Object.toJSON(A[E]);
+if(D!==undefined){B.push(E.toJSON()+": "+D)
+}}return"{"+B.join(", ")+"}"
+},toQueryString:function(A){return $H(A).toQueryString()
+},toHTML:function(A){return A&&A.toHTML?A.toHTML():String.interpret(A)
+},keys:function(A){var B=[];
+for(var C in A){B.push(C)
+}return B
+},values:function(B){var A=[];
+for(var C in B){A.push(B[C])
+}return A
+},clone:function(A){return Object.extend({},A)
+},isElement:function(A){return A&&A.nodeType==1
+},isArray:function(A){return A&&A.constructor===Array
+},isHash:function(A){return A instanceof Hash
+},isFunction:function(A){return typeof A=="function"
+},isString:function(A){return typeof A=="string"
+},isNumber:function(A){return typeof A=="number"
+},isUndefined:function(A){return typeof A=="undefined"
+}});
+Object.extend(Function.prototype,{argumentNames:function(){var A=this.toString().match(/^[\s\(]*function[^(]*\((.*?)\)/)[1].split(",").invoke("strip");
+return A.length==1&&!A[0]?[]:A
+},bind:function(){if(arguments.length<2&&arguments[0]===undefined){return this
+}var A=this,C=$A(arguments),B=C.shift();
+return function(){return A.apply(B,C.concat($A(arguments)))
+}
+},bindAsEventListener:function(){var A=this,C=$A(arguments),B=C.shift();
+return function(D){return A.apply(B,[D||window.event].concat(C))
+}
+},curry:function(){if(!arguments.length){return this
+}var A=this,B=$A(arguments);
+return function(){return A.apply(this,B.concat($A(arguments)))
+}
+},delay:function(){var A=this,B=$A(arguments),C=B.shift()*1000;
+return window.setTimeout(function(){return A.apply(A,B)
+},C)
+},wrap:function(B){var A=this;
+return function(){return B.apply(this,[A.bind(this)].concat($A(arguments)))
+}
+},methodize:function(){if(this._methodized){return this._methodized
+}var A=this;
+return this._methodized=function(){return A.apply(null,[this].concat($A(arguments)))
+}
+}});
+Function.prototype.defer=Function.prototype.delay.curry(0.01);
+Date.prototype.toJSON=function(){return'"'+this.getUTCFullYear()+"-"+(this.getUTCMonth()+1).toPaddedString(2)+"-"+this.getUTCDate().toPaddedString(2)+"T"+this.getUTCHours().toPaddedString(2)+":"+this.getUTCMinutes().toPaddedString(2)+":"+this.getUTCSeconds().toPaddedString(2)+'Z"'
+};
+var Try={these:function(){var C;
+for(var B=0,D=arguments.length;
+B<D;
+B++){var A=arguments[B];
+try{C=A();
+break
+}catch(E){}}return C
+}};
+RegExp.prototype.match=RegExp.prototype.test;
+RegExp.escape=function(A){return String(A).replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")
+};
+var PeriodicalExecuter=Class.create({initialize:function(B,A){this.callback=B;
+this.frequency=A;
+this.currentlyExecuting=false;
+this.registerCallback()
+},registerCallback:function(){this.timer=setInterval(this.onTimerEvent.bind(this),this.frequency*1000)
+},execute:function(){this.callback(this)
+},stop:function(){if(!this.timer){return 
+}clearInterval(this.timer);
+this.timer=null
+},onTimerEvent:function(){if(!this.currentlyExecuting){try{this.currentlyExecuting=true;
+this.execute()
+}finally{this.currentlyExecuting=false
+}}}});
+Object.extend(String,{interpret:function(A){return A==null?"":String(A)
+},specialChar:{"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r","\\":"\\\\"}});
+Object.extend(String.prototype,{gsub:function(E,C){var A="",D=this,B;
+C=arguments.callee.prepareReplacement(C);
+while(D.length>0){if(B=D.match(E)){A+=D.slice(0,B.index);
+A+=String.interpret(C(B));
+D=D.slice(B.index+B[0].length)
+}else{A+=D,D=""
+}}return A
+},sub:function(C,A,B){A=this.gsub.prepareReplacement(A);
+B=B===undefined?1:B;
+return this.gsub(C,function(D){if(--B<0){return D[0]
+}return A(D)
+})
+},scan:function(B,A){this.gsub(B,A);
+return String(this)
+},truncate:function(B,A){B=B||30;
+A=A===undefined?"...":A;
+return this.length>B?this.slice(0,B-A.length)+A:String(this)
+},strip:function(){return this.replace(/^\s+/,"").replace(/\s+$/,"")
+},stripTags:function(){return this.replace(/<\/?[^>]+>/gi,"")
+},stripScripts:function(){return this.replace(new RegExp(Prototype.ScriptFragment,"img"),"")
+},extractScripts:function(){var B=new RegExp(Prototype.ScriptFragment,"img");
+var A=new RegExp(Prototype.ScriptFragment,"im");
+return(this.match(B)||[]).map(function(C){return(C.match(A)||["",""])[1]
+})
+},evalScripts:function(){return this.extractScripts().map(function(script){return eval(script)
+})
+},escapeHTML:function(){var A=arguments.callee;
+A.text.data=this;
+return A.div.innerHTML
+},unescapeHTML:function(){var A=new Element("div");
+A.innerHTML=this.stripTags();
+return A.childNodes[0]?(A.childNodes.length>1?$A(A.childNodes).inject("",function(B,C){return B+C.nodeValue
+}):A.childNodes[0].nodeValue):""
+},toQueryParams:function(B){var A=this.strip().match(/([^?#]*)(#.*)?$/);
+if(!A){return{}
+}return A[1].split(B||"&").inject({},function(E,F){if((F=F.split("="))[0]){var C=decodeURIComponent(F.shift());
+var D=F.length>1?F.join("="):F[0];
+if(D!=undefined){D=decodeURIComponent(D)
+}if(C in E){if(!Object.isArray(E[C])){E[C]=[E[C]]
+}E[C].push(D)
+}else{E[C]=D
+}}return E
+})
+},toArray:function(){return this.split("")
+},succ:function(){return this.slice(0,this.length-1)+String.fromCharCode(this.charCodeAt(this.length-1)+1)
+},times:function(A){return A<1?"":new Array(A+1).join(this)
+},camelize:function(){var D=this.split("-"),A=D.length;
+if(A==1){return D[0]
+}var C=this.charAt(0)=="-"?D[0].charAt(0).toUpperCase()+D[0].substring(1):D[0];
+for(var B=1;
+B<A;
+B++){C+=D[B].charAt(0).toUpperCase()+D[B].substring(1)
+}return C
+},capitalize:function(){return this.charAt(0).toUpperCase()+this.substring(1).toLowerCase()
+},underscore:function(){return this.gsub(/::/,"/").gsub(/([A-Z]+)([A-Z][a-z])/,"#{1}_#{2}").gsub(/([a-z\d])([A-Z])/,"#{1}_#{2}").gsub(/-/,"_").toLowerCase()
+},dasherize:function(){return this.gsub(/_/,"-")
+},inspect:function(B){var A=this.gsub(/[\x00-\x1f\\]/,function(C){var D=String.specialChar[C[0]];
+return D?D:"\\u00"+C[0].charCodeAt().toPaddedString(2,16)
+});
+if(B){return'"'+A.replace(/"/g,'\\"')+'"'
+}return"'"+A.replace(/'/g,"\\'")+"'"
+},toJSON:function(){return this.inspect(true)
+},unfilterJSON:function(A){return this.sub(A||Prototype.JSONFilter,"#{1}")
+},isJSON:function(){var A=this.replace(/\\./g,"@").replace(/"[^"\\\n\r]*"/g,"");
+return(/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(A)
+},evalJSON:function(sanitize){var json=this.unfilterJSON();
+try{if(!sanitize||json.isJSON()){return eval("("+json+")")
+}}catch(e){}throw new SyntaxError("Badly formed JSON string: "+this.inspect())
+},include:function(A){return this.indexOf(A)>-1
+},startsWith:function(A){return this.indexOf(A)===0
+},endsWith:function(A){var B=this.length-A.length;
+return B>=0&&this.lastIndexOf(A)===B
+},empty:function(){return this==""
+},blank:function(){return/^\s*$/.test(this)
+},interpolate:function(A,B){return new Template(this,B).evaluate(A)
+}});
+if(Prototype.Browser.WebKit||Prototype.Browser.IE){Object.extend(String.prototype,{escapeHTML:function(){return this.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")
+},unescapeHTML:function(){return this.replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">")
+}})
+}String.prototype.gsub.prepareReplacement=function(B){if(Object.isFunction(B)){return B
+}var A=new Template(B);
+return function(C){return A.evaluate(C)
+}
+};
+String.prototype.parseQuery=String.prototype.toQueryParams;
+Object.extend(String.prototype.escapeHTML,{div:document.createElement("div"),text:document.createTextNode("")});
+with(String.prototype.escapeHTML){div.appendChild(text)
+}var Template=Class.create({initialize:function(A,B){this.template=A.toString();
+this.pattern=B||Template.Pattern
+},evaluate:function(A){if(Object.isFunction(A.toTemplateReplacements)){A=A.toTemplateReplacements()
+}return this.template.gsub(this.pattern,function(D){if(A==null){return""
+}var F=D[1]||"";
+if(F=="\\"){return D[2]
+}var B=A,G=D[3];
+var E=/^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/,D=E.exec(G);
+if(D==null){return F
+}while(D!=null){var C=D[1].startsWith("[")?D[2].gsub("\\\\]","]"):D[1];
+B=B[C];
+if(null==B||""==D[3]){break
+}G=G.substring("["==D[3]?D[1].length:D[0].length);
+D=E.exec(G)
+}return F+String.interpret(B)
+}.bind(this))
+}});
+Template.Pattern=/(^|.|\r|\n)(#\{(.*?)\})/;
+var $break={};
+var Enumerable={each:function(C,B){var A=0;
+C=C.bind(B);
+try{this._each(function(E){C(E,A++)
+})
+}catch(D){if(D!=$break){throw D
+}}return this
+},eachSlice:function(D,C,B){C=C?C.bind(B):Prototype.K;
+var A=-D,E=[],F=this.toArray();
+while((A+=D)<F.length){E.push(F.slice(A,A+D))
+}return E.collect(C,B)
+},all:function(C,B){C=C?C.bind(B):Prototype.K;
+var A=true;
+this.each(function(E,D){A=A&&!!C(E,D);
+if(!A){throw $break
+}});
+return A
+},any:function(C,B){C=C?C.bind(B):Prototype.K;
+var A=false;
+this.each(function(E,D){if(A=!!C(E,D)){throw $break
+}});
+return A
+},collect:function(C,B){C=C?C.bind(B):Prototype.K;
+var A=[];
+this.each(function(E,D){A.push(C(E,D))
+});
+return A
+},detect:function(C,B){C=C.bind(B);
+var A;
+this.each(function(E,D){if(C(E,D)){A=E;
+throw $break
+}});
+return A
+},findAll:function(C,B){C=C.bind(B);
+var A=[];
+this.each(function(E,D){if(C(E,D)){A.push(E)
+}});
+return A
+},grep:function(D,C,B){C=C?C.bind(B):Prototype.K;
+var A=[];
+if(Object.isString(D)){D=new RegExp(D)
+}this.each(function(F,E){if(D.match(F)){A.push(C(F,E))
+}});
+return A
+},include:function(A){if(Object.isFunction(this.indexOf)){if(this.indexOf(A)!=-1){return true
+}}var B=false;
+this.each(function(C){if(C==A){B=true;
+throw $break
+}});
+return B
+},inGroupsOf:function(B,A){A=A===undefined?null:A;
+return this.eachSlice(B,function(C){while(C.length<B){C.push(A)
+}return C
+})
+},inject:function(A,C,B){C=C.bind(B);
+this.each(function(E,D){A=C(A,E,D)
+});
+return A
+},invoke:function(B){var A=$A(arguments).slice(1);
+return this.map(function(C){return C[B].apply(C,A)
+})
+},max:function(C,B){C=C?C.bind(B):Prototype.K;
+var A;
+this.each(function(E,D){E=C(E,D);
+if(A==undefined||E>=A){A=E
+}});
+return A
+},min:function(C,B){C=C?C.bind(B):Prototype.K;
+var A;
+this.each(function(E,D){E=C(E,D);
+if(A==undefined||E<A){A=E
+}});
+return A
+},partition:function(D,B){D=D?D.bind(B):Prototype.K;
+var C=[],A=[];
+this.each(function(F,E){(D(F,E)?C:A).push(F)
+});
+return[C,A]
+},pluck:function(B){var A=[];
+this.each(function(C){A.push(C[B])
+});
+return A
+},reject:function(C,B){C=C.bind(B);
+var A=[];
+this.each(function(E,D){if(!C(E,D)){A.push(E)
+}});
+return A
+},sortBy:function(B,A){B=B.bind(A);
+return this.map(function(D,C){return{value:D,criteria:B(D,C)}
+}).sort(function(F,E){var D=F.criteria,C=E.criteria;
+return D<C?-1:D>C?1:0
+}).pluck("value")
+},toArray:function(){return this.map()
+},zip:function(){var B=Prototype.K,A=$A(arguments);
+if(Object.isFunction(A.last())){B=A.pop()
+}var C=[this].concat(A).map($A);
+return this.map(function(E,D){return B(C.pluck(D))
+})
+},size:function(){return this.toArray().length
+},inspect:function(){return"#<Enumerable:"+this.toArray().inspect()+">"
+}};
+Object.extend(Enumerable,{map:Enumerable.collect,find:Enumerable.detect,select:Enumerable.findAll,filter:Enumerable.findAll,member:Enumerable.include,entries:Enumerable.toArray,every:Enumerable.all,some:Enumerable.any});
+function $A(C){if(!C){return[]
+}if(C.toArray){return C.toArray()
+}var B=C.length,A=new Array(B);
+while(B--){A[B]=C[B]
+}return A
+}if(Prototype.Browser.WebKit){function $A(C){if(!C){return[]
+}if(!(Object.isFunction(C)&&C=="[object NodeList]")&&C.toArray){return C.toArray()
+}var B=C.length,A=new Array(B);
+while(B--){A[B]=C[B]
+}return A
+}}Array.from=$A;
+Object.extend(Array.prototype,Enumerable);
+if(!Array.prototype._reverse){Array.prototype._reverse=Array.prototype.reverse
+}Object.extend(Array.prototype,{_each:function(B){for(var A=0,C=this.length;
+A<C;
+A++){B(this[A])
+}},clear:function(){this.length=0;
+return this
+},first:function(){return this[0]
+},last:function(){return this[this.length-1]
+},compact:function(){return this.select(function(A){return A!=null
+})
+},flatten:function(){return this.inject([],function(B,A){return B.concat(Object.isArray(A)?A.flatten():[A])
+})
+},without:function(){var A=$A(arguments);
+return this.select(function(B){return !A.include(B)
+})
+},reverse:function(A){return(A!==false?this:this.toArray())._reverse()
+},reduce:function(){return this.length>1?this:this[0]
+},uniq:function(A){return this.inject([],function(D,C,B){if(0==B||(A?D.last()!=C:!D.include(C))){D.push(C)
+}return D
+})
+},intersect:function(A){return this.uniq().findAll(function(B){return A.detect(function(C){return B===C
+})
+})
+},clone:function(){return[].concat(this)
+},size:function(){return this.length
+},inspect:function(){return"["+this.map(Object.inspect).join(", ")+"]"
+},toJSON:function(){var A=[];
+this.each(function(B){var C=Object.toJSON(B);
+if(C!==undefined){A.push(C)
+}});
+return"["+A.join(", ")+"]"
+}});
+if(Object.isFunction(Array.prototype.forEach)){Array.prototype._each=Array.prototype.forEach
+}if(!Array.prototype.indexOf){Array.prototype.indexOf=function(C,A){A||(A=0);
+var B=this.length;
+if(A<0){A=B+A
+}for(;
+A<B;
+A++){if(this[A]===C){return A
+}}return -1
+}
+}if(!Array.prototype.lastIndexOf){Array.prototype.lastIndexOf=function(B,A){A=isNaN(A)?this.length:(A<0?this.length+A:A)+1;
+var C=this.slice(0,A).reverse().indexOf(B);
+return(C<0)?C:A-C-1
+}
+}Array.prototype.toArray=Array.prototype.clone;
+function $w(A){if(!Object.isString(A)){return[]
+}A=A.strip();
+return A?A.split(/\s+/):[]
+}if(Prototype.Browser.Opera){Array.prototype.concat=function(){var E=[];
+for(var B=0,C=this.length;
+B<C;
+B++){E.push(this[B])
+}for(var B=0,C=arguments.length;
+B<C;
+B++){if(Object.isArray(arguments[B])){for(var A=0,D=arguments[B].length;
+A<D;
+A++){E.push(arguments[B][A])
+}}else{E.push(arguments[B])
+}}return E
+}
+}Object.extend(Number.prototype,{toColorPart:function(){return this.toPaddedString(2,16)
+},succ:function(){return this+1
+},times:function(A){$R(0,this,true).each(A);
+return this
+},toPaddedString:function(C,B){var A=this.toString(B||10);
+return"0".times(C-A.length)+A
+},toJSON:function(){return isFinite(this)?this.toString():"null"
+}});
+$w("abs round ceil floor").each(function(A){Number.prototype[A]=Math[A].methodize()
+});
+function $H(A){return new Hash(A)
+}var Hash=Class.create(Enumerable,(function(){if(function(){var C=0,E=function(F){this.key=F
+};
+E.prototype.key="foo";
+for(var D in new E("bar")){C++
+}return C>1
+}()){function B(E){var C=[];
+for(var D in this._object){var F=this._object[D];
+if(C.include(D)){continue
+}C.push(D);
+var G=[D,F];
+G.key=D;
+G.value=F;
+E(G)
+}}}else{function B(D){for(var C in this._object){var E=this._object[C],F=[C,E];
+F.key=C;
+F.value=E;
+D(F)
+}}}function A(C,D){if(Object.isUndefined(D)){return C
+}return C+"="+encodeURIComponent(String.interpret(D))
+}return{initialize:function(C){this._object=Object.isHash(C)?C.toObject():Object.clone(C)
+},_each:B,set:function(C,D){return this._object[C]=D
+},get:function(C){return this._object[C]
+},unset:function(C){var D=this._object[C];
+delete this._object[C];
+return D
+},toObject:function(){return Object.clone(this._object)
+},keys:function(){return this.pluck("key")
+},values:function(){return this.pluck("value")
+},index:function(D){var C=this.detect(function(E){return E.value===D
+});
+return C&&C.key
+},merge:function(C){return this.clone().update(C)
+},update:function(C){return new Hash(C).inject(this,function(D,E){D.set(E.key,E.value);
+return D
+})
+},toQueryString:function(){return this.map(function(E){var D=encodeURIComponent(E.key),C=E.value;
+if(C&&typeof C=="object"){if(Object.isArray(C)){return C.map(A.curry(D)).join("&")
+}}return A(D,C)
+}).join("&")
+},inspect:function(){return"#<Hash:{"+this.map(function(C){return C.map(Object.inspect).join(": ")
+}).join(", ")+"}>"
+},toJSON:function(){return Object.toJSON(this.toObject())
+},clone:function(){return new Hash(this)
+}}
+})());
+Hash.prototype.toTemplateReplacements=Hash.prototype.toObject;
+Hash.from=$H;
+var ObjectRange=Class.create(Enumerable,{initialize:function(C,A,B){this.start=C;
+this.end=A;
+this.exclusive=B
+},_each:function(A){var B=this.start;
+while(this.include(B)){A(B);
+B=B.succ()
+}},include:function(A){if(A<this.start){return false
+}if(this.exclusive){return A<this.end
+}return A<=this.end
+}});
+var $R=function(C,A,B){return new ObjectRange(C,A,B)
+};
+var Ajax={getTransport:function(){return Try.these(function(){return new XMLHttpRequest()
+},function(){return new ActiveXObject("Msxml2.XMLHTTP")
+},function(){return new ActiveXObject("Microsoft.XMLHTTP")
+})||false
+},activeRequestCount:0};
+Ajax.Responders={responders:[],_each:function(A){this.responders._each(A)
+},register:function(A){if(!this.include(A)){this.responders.push(A)
+}},unregister:function(A){this.responders=this.responders.without(A)
+},dispatch:function(D,B,C,A){this.each(function(E){if(Object.isFunction(E[D])){try{E[D].apply(E,[B,C,A])
+}catch(F){}}})
+}};
+Object.extend(Ajax.Responders,Enumerable);
+Ajax.Responders.register({onCreate:function(){Ajax.activeRequestCount++
+},onComplete:function(){Ajax.activeRequestCount--
+}});
+Ajax.Base=Class.create({initialize:function(A){this.options={method:"post",asynchronous:true,contentType:"application/x-www-form-urlencoded",encoding:"UTF-8",parameters:"",evalJSON:true,evalJS:true};
+Object.extend(this.options,A||{});
+this.options.method=this.options.method.toLowerCase();
+if(Object.isString(this.options.parameters)){this.options.parameters=this.options.parameters.toQueryParams()
+}}});
+Ajax.Request=Class.create(Ajax.Base,{_complete:false,initialize:function($super,B,A){$super(A);
+this.transport=Ajax.getTransport();
+this.request(B)
+},request:function(B){this.url=B;
+this.method=this.options.method;
+var D=Object.clone(this.options.parameters);
+if(!["get","post"].include(this.method)){D["_method"]=this.method;
+this.method="post"
+}this.parameters=D;
+if(D=Object.toQueryString(D)){if(this.method=="get"){this.url+=(this.url.include("?")?"&":"?")+D
+}else{if(/Konqueror|Safari|KHTML/.test(navigator.userAgent)){D+="&_="
+}}}try{var A=new Ajax.Response(this);
+if(this.options.onCreate){this.options.onCreate(A)
+}Ajax.Responders.dispatch("onCreate",this,A);
+this.transport.open(this.method.toUpperCase(),this.url,this.options.asynchronous);
+if(this.options.asynchronous){this.respondToReadyState.bind(this).defer(1)
+}this.transport.onreadystatechange=this.onStateChange.bind(this);
+this.setRequestHeaders();
+this.body=this.method=="post"?(this.options.postBody||D):null;
+this.transport.send(this.body);
+if(!this.options.asynchronous&&this.transport.overrideMimeType){this.onStateChange()
+}}catch(C){this.dispatchException(C)
+}},onStateChange:function(){var A=this.transport.readyState;
+if(A>1&&!((A==4)&&this._complete)){this.respondToReadyState(this.transport.readyState)
+}},setRequestHeaders:function(){var E={"X-Requested-With":"XMLHttpRequest","X-Prototype-Version":Prototype.Version,"Accept":"text/javascript, text/html, application/xml, text/xml, */*"};
+if(this.method=="post"){E["Content-type"]=this.options.contentType+(this.options.encoding?"; charset="+this.options.encoding:"");
+if(this.transport.overrideMimeType&&(navigator.userAgent.match(/Gecko\/(\d{4})/)||[0,2005])[1]<2005){E["Connection"]="close"
+}}if(typeof this.options.requestHeaders=="object"){var C=this.options.requestHeaders;
+if(Object.isFunction(C.push)){for(var B=0,D=C.length;
+B<D;
+B+=2){E[C[B]]=C[B+1]
+}}else{$H(C).each(function(F){E[F.key]=F.value
+})
+}}for(var A in E){this.transport.setRequestHeader(A,E[A])
+}},success:function(){var A=this.getStatus();
+return !A||(A>=200&&A<300)
+},getStatus:function(){try{return this.transport.status||0
+}catch(A){return 0
+}},respondToReadyState:function(A){var C=Ajax.Request.Events[A],B=new Ajax.Response(this);
+if(C=="Complete"){try{this._complete=true;
+(this.options["on"+B.status]||this.options["on"+(this.success()?"Success":"Failure")]||Prototype.emptyFunction)(B,B.headerJSON)
+}catch(D){this.dispatchException(D)
+}var E=B.getHeader("Content-type");
+if(this.options.evalJS=="force"||(this.options.evalJS&&E&&E.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s*$/i))){this.evalResponse()
+}}try{(this.options["on"+C]||Prototype.emptyFunction)(B,B.headerJSON);
+Ajax.Responders.dispatch("on"+C,this,B,B.headerJSON)
+}catch(D){this.dispatchException(D)
+}if(C=="Complete"){this.transport.onreadystatechange=Prototype.emptyFunction
+}},getHeader:function(A){try{return this.transport.getResponseHeader(A)
+}catch(B){return null
+}},evalResponse:function(){try{return eval((this.transport.responseText||"").unfilterJSON())
+}catch(e){this.dispatchException(e)
+}},dispatchException:function(A){(this.options.onException||Prototype.emptyFunction)(this,A);
+Ajax.Responders.dispatch("onException",this,A)
+}});
+Ajax.Request.Events=["Uninitialized","Loading","Loaded","Interactive","Complete"];
+Ajax.Response=Class.create({initialize:function(C){this.request=C;
+var D=this.transport=C.transport,A=this.readyState=D.readyState;
+if((A>2&&!Prototype.Browser.IE)||A==4){this.status=this.getStatus();
+this.statusText=this.getStatusText();
+this.responseText=String.interpret(D.responseText);
+this.headerJSON=this._getHeaderJSON()
+}if(A==4){var B=D.responseXML;
+this.responseXML=B===undefined?null:B;
+this.responseJSON=this._getResponseJSON()
+}},status:0,statusText:"",getStatus:Ajax.Request.prototype.getStatus,getStatusText:function(){try{return this.transport.statusText||""
+}catch(A){return""
+}},getHeader:Ajax.Request.prototype.getHeader,getAllHeaders:function(){try{return this.getAllResponseHeaders()
+}catch(A){return null
+}},getResponseHeader:function(A){return this.transport.getResponseHeader(A)
+},getAllResponseHeaders:function(){return this.transport.getAllResponseHeaders()
+},_getHeaderJSON:function(){var A=this.getHeader("X-JSON");
+if(!A){return null
+}A=decodeURIComponent(escape(A));
+try{return A.evalJSON(this.request.options.sanitizeJSON)
+}catch(B){this.request.dispatchException(B)
+}},_getResponseJSON:function(){var A=this.request.options;
+if(!A.evalJSON||(A.evalJSON!="force"&&!(this.getHeader("Content-type")||"").include("application/json"))){return null
+}try{return this.transport.responseText.evalJSON(A.sanitizeJSON)
+}catch(B){this.request.dispatchException(B)
+}}});
+Ajax.Updater=Class.create(Ajax.Request,{initialize:function($super,A,C,B){this.container={success:(A.success||A),failure:(A.failure||(A.success?null:A))};
+B=B||{};
+var D=B.onComplete;
+B.onComplete=(function(E,F){this.updateContent(E.responseText);
+if(Object.isFunction(D)){D(E,F)
+}}).bind(this);
+$super(C,B)
+},updateContent:function(D){var C=this.container[this.success()?"success":"failure"],A=this.options;
+if(!A.evalScripts){D=D.stripScripts()
+}if(C=$(C)){if(A.insertion){if(Object.isString(A.insertion)){var B={};
+B[A.insertion]=D;
+C.insert(B)
+}else{A.insertion(C,D)
+}}else{C.update(D)
+}}if(this.success()){if(this.onComplete){this.onComplete.bind(this).defer()
+}}}});
+Ajax.PeriodicalUpdater=Class.create(Ajax.Base,{initialize:function($super,A,C,B){$super(B);
+this.onComplete=this.options.onComplete;
+this.frequency=(this.options.frequency||2);
+this.decay=(this.options.decay||1);
+this.updater={};
+this.container=A;
+this.url=C;
+this.start()
+},start:function(){this.options.onComplete=this.updateComplete.bind(this);
+this.onTimerEvent()
+},stop:function(){this.updater.options.onComplete=undefined;
+clearTimeout(this.timer);
+(this.onComplete||Prototype.emptyFunction).apply(this,arguments)
+},updateComplete:function(A){if(this.options.decay){this.decay=(A.responseText==this.lastText?this.decay*this.options.decay:1);
+this.lastText=A.responseText
+}this.timer=this.onTimerEvent.bind(this).delay(this.decay*this.frequency)
+},onTimerEvent:function(){this.updater=new Ajax.Updater(this.container,this.url,this.options)
+}});
+function $(B){if(arguments.length>1){for(var A=0,D=[],C=arguments.length;
+A<C;
+A++){D.push($(arguments[A]))
+}return D
+}if(Object.isString(B)){B=document.getElementById(B)
+}return Element.extend(B)
+}if(Prototype.BrowserFeatures.XPath){document._getElementsByXPath=function(F,A){var C=[];
+var E=document.evaluate(F,$(A)||document,null,XPathResult.ORDERED_NODE_SNAPSHOT_TYPE,null);
+for(var B=0,D=E.snapshotLength;
+B<D;
+B++){C.push(Element.extend(E.snapshotItem(B)))
+}return C
+}
+}if(!window.Node){var Node={}
+}if(!Node.ELEMENT_NODE){Object.extend(Node,{ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12})
+}(function(){var A=this.Element;
+this.Element=function(D,C){C=C||{};
+D=D.toLowerCase();
+var B=Element.cache;
+if(Prototype.Browser.IE&&C.name){D="<"+D+' name="'+C.name+'">';
+delete C.name;
+return Element.writeAttribute(document.createElement(D),C)
+}if(!B[D]){B[D]=Element.extend(document.createElement(D))
+}return Element.writeAttribute(B[D].cloneNode(false),C)
+};
+Object.extend(this.Element,A||{})
+}).call(window);
+Element.cache={};
+Element.Methods={visible:function(A){return $(A).style.display!="none"
+},toggle:function(A){A=$(A);
+Element[Element.visible(A)?"hide":"show"](A);
+return A
+},hide:function(A){$(A).style.display="none";
+return A
+},show:function(A){$(A).style.display="";
+return A
+},remove:function(A){A=$(A);
+A.parentNode.removeChild(A);
+return A
+},update:function(A,B){A=$(A);
+if(B&&B.toElement){B=B.toElement()
+}if(Object.isElement(B)){return A.update().insert(B)
+}B=Object.toHTML(B);
+A.innerHTML=B.stripScripts();
+B.evalScripts.bind(B).defer();
+return A
+},replace:function(B,C){B=$(B);
+if(C&&C.toElement){C=C.toElement()
+}else{if(!Object.isElement(C)){C=Object.toHTML(C);
+var A=B.ownerDocument.createRange();
+A.selectNode(B);
+C.evalScripts.bind(C).defer();
+C=A.createContextualFragment(C.stripScripts())
+}}B.parentNode.replaceChild(C,B);
+return B
+},insert:function(C,E){C=$(C);
+if(Object.isString(E)||Object.isNumber(E)||Object.isElement(E)||(E&&(E.toElement||E.toHTML))){E={bottom:E}
+}var D,B,A;
+for(position in E){D=E[position];
+position=position.toLowerCase();
+B=Element._insertionTranslations[position];
+if(D&&D.toElement){D=D.toElement()
+}if(Object.isElement(D)){B.insert(C,D);
+continue
+}D=Object.toHTML(D);
+A=C.ownerDocument.createRange();
+B.initializeRange(C,A);
+B.insert(C,A.createContextualFragment(D.stripScripts()));
+D.evalScripts.bind(D).defer()
+}return C
+},wrap:function(B,C,A){B=$(B);
+if(Object.isElement(C)){$(C).writeAttribute(A||{})
+}else{if(Object.isString(C)){C=new Element(C,A)
+}else{C=new Element("div",C)
+}}if(B.parentNode){B.parentNode.replaceChild(C,B)
+}C.appendChild(B);
+return C
+},inspect:function(B){B=$(B);
+var A="<"+B.tagName.toLowerCase();
+$H({"id":"id","className":"class"}).each(function(F){var E=F.first(),C=F.last();
+var D=(B[E]||"").toString();
+if(D){A+=" "+C+"="+D.inspect(true)
+}});
+return A+">"
+},recursivelyCollect:function(A,C){A=$(A);
+var B=[];
+while(A=A[C]){if(A.nodeType==1){B.push(Element.extend(A))
+}}return B
+},ancestors:function(A){return $(A).recursivelyCollect("parentNode")
+},descendants:function(A){return $A($(A).getElementsByTagName("*")).each(Element.extend)
+},firstDescendant:function(A){A=$(A).firstChild;
+while(A&&A.nodeType!=1){A=A.nextSibling
+}return $(A)
+},immediateDescendants:function(A){if(!(A=$(A).firstChild)){return[]
+}while(A&&A.nodeType!=1){A=A.nextSibling
+}if(A){return[A].concat($(A).nextSiblings())
+}return[]
+},previousSiblings:function(A){return $(A).recursivelyCollect("previousSibling")
+},nextSiblings:function(A){return $(A).recursivelyCollect("nextSibling")
+},siblings:function(A){A=$(A);
+return A.previousSiblings().reverse().concat(A.nextSiblings())
+},match:function(B,A){if(Object.isString(A)){A=new Selector(A)
+}return A.match($(B))
+},up:function(B,D,A){B=$(B);
+if(arguments.length==1){return $(B.parentNode)
+}var C=B.ancestors();
+return D?Selector.findElement(C,D,A):C[A||0]
+},down:function(B,C,A){B=$(B);
+if(arguments.length==1){return B.firstDescendant()
+}var D=B.descendants();
+return C?Selector.findElement(D,C,A):D[A||0]
+},previous:function(B,D,A){B=$(B);
+if(arguments.length==1){return $(Selector.handlers.previousElementSibling(B))
+}var C=B.previousSiblings();
+return D?Selector.findElement(C,D,A):C[A||0]
+},next:function(C,D,B){C=$(C);
+if(arguments.length==1){return $(Selector.handlers.nextElementSibling(C))
+}var A=C.nextSiblings();
+return D?Selector.findElement(A,D,B):A[B||0]
+},select:function(){var A=$A(arguments),B=$(A.shift());
+return Selector.findChildElements(B,A)
+},adjacent:function(){var A=$A(arguments),B=$(A.shift());
+return Selector.findChildElements(B.parentNode,A).without(B)
+},identify:function(B){B=$(B);
+var C=B.readAttribute("id"),A=arguments.callee;
+if(C){return C
+}do{C="anonymous_element_"+A.counter++
+}while($(C));
+B.writeAttribute("id",C);
+return C
+},readAttribute:function(C,A){C=$(C);
+if(Prototype.Browser.IE){var B=Element._attributeTranslations.read;
+if(B.values[A]){return B.values[A](C,A)
+}if(B.names[A]){A=B.names[A]
+}if(A.include(":")){return(!C.attributes||!C.attributes[A])?null:C.attributes[A].value
+}}return C.getAttribute(A)
+},writeAttribute:function(E,C,F){E=$(E);
+var B={},D=Element._attributeTranslations.write;
+if(typeof C=="object"){B=C
+}else{B[C]=F===undefined?true:F
+}for(var A in B){var C=D.names[A]||A,F=B[A];
+if(D.values[A]){C=D.values[A](E,F)
+}if(F===false||F===null){E.removeAttribute(C)
+}else{if(F===true){E.setAttribute(C,C)
+}else{E.setAttribute(C,F)
+}}}return E
+},getHeight:function(A){return $(A).getDimensions().height
+},getWidth:function(A){return $(A).getDimensions().width
+},classNames:function(A){return new Element.ClassNames(A)
+},hasClassName:function(A,B){if(!(A=$(A))){return 
+}var C=A.className;
+return(C.length>0&&(C==B||new RegExp("(^|\\s)"+B+"(\\s|$)").test(C)))
+},addClassName:function(A,B){if(!(A=$(A))){return 
+}if(!A.hasClassName(B)){A.className+=(A.className?" ":"")+B
+}return A
+},removeClassName:function(A,B){if(!(A=$(A))){return 
+}A.className=A.className.replace(new RegExp("(^|\\s+)"+B+"(\\s+|$)")," ").strip();
+return A
+},toggleClassName:function(A,B){if(!(A=$(A))){return 
+}return A[A.hasClassName(B)?"removeClassName":"addClassName"](B)
+},cleanWhitespace:function(B){B=$(B);
+var C=B.firstChild;
+while(C){var A=C.nextSibling;
+if(C.nodeType==3&&!/\S/.test(C.nodeValue)){B.removeChild(C)
+}C=A
+}return B
+},empty:function(A){return $(A).innerHTML.blank()
+},descendantOf:function(D,C){D=$(D),C=$(C);
+if(D.compareDocumentPosition){return(D.compareDocumentPosition(C)&8)===8
+}if(D.sourceIndex&&!Prototype.Browser.Opera){var E=D.sourceIndex,B=C.sourceIndex,A=C.nextSibling;
+if(!A){do{C=C.parentNode
+}while(!(A=C.nextSibling)&&C.parentNode)
+}if(A){return(E>B&&E<A.sourceIndex)
+}}while(D=D.parentNode){if(D==C){return true
+}}return false
+},scrollTo:function(A){A=$(A);
+var B=A.cumulativeOffset();
+window.scrollTo(B[0],B[1]);
+return A
+},getStyle:function(B,C){B=$(B);
+C=C=="float"?"cssFloat":C.camelize();
+var D=B.style[C];
+if(!D){var A=document.defaultView.getComputedStyle(B,null);
+D=A?A[C]:null
+}if(C=="opacity"){return D?parseFloat(D):1
+}return D=="auto"?null:D
+},getOpacity:function(A){return $(A).getStyle("opacity")
+},setStyle:function(B,C){B=$(B);
+var E=B.style,A;
+if(Object.isString(C)){B.style.cssText+=";"+C;
+return C.include("opacity")?B.setOpacity(C.match(/opacity:\s*(\d?\.?\d*)/)[1]):B
+}for(var D in C){if(D=="opacity"){B.setOpacity(C[D])
+}else{E[(D=="float"||D=="cssFloat")?(E.styleFloat===undefined?"cssFloat":"styleFloat"):D]=C[D]
+}}return B
+},setOpacity:function(A,B){A=$(A);
+A.style.opacity=(B==1||B==="")?"":(B<0.00001)?0:B;
+return A
+},getDimensions:function(C){C=$(C);
+var G=$(C).getStyle("display");
+if(G!="none"&&G!=null){return{width:C.offsetWidth,height:C.offsetHeight}
+}var B=C.style;
+var F=B.visibility;
+var D=B.position;
+var A=B.display;
+B.visibility="hidden";
+B.position="absolute";
+B.display="block";
+var H=C.clientWidth;
+var E=C.clientHeight;
+B.display=A;
+B.position=D;
+B.visibility=F;
+return{width:H,height:E}
+},makePositioned:function(A){A=$(A);
+var B=Element.getStyle(A,"position");
+if(B=="static"||!B){A._madePositioned=true;
+A.style.position="relative";
+if(window.opera){A.style.top=0;
+A.style.left=0
+}}return A
+},undoPositioned:function(A){A=$(A);
+if(A._madePositioned){A._madePositioned=undefined;
+A.style.position=A.style.top=A.style.left=A.style.bottom=A.style.right=""
+}return A
+},makeClipping:function(A){A=$(A);
+if(A._overflow){return A
+}A._overflow=Element.getStyle(A,"overflow")||"auto";
+if(A._overflow!=="hidden"){A.style.overflow="hidden"
+}return A
+},undoClipping:function(A){A=$(A);
+if(!A._overflow){return A
+}A.style.overflow=A._overflow=="auto"?"":A._overflow;
+A._overflow=null;
+return A
+},cumulativeOffset:function(B){var A=0,C=0;
+do{A+=B.offsetTop||0;
+C+=B.offsetLeft||0;
+B=B.offsetParent
+}while(B);
+return Element._returnOffset(C,A)
+},positionedOffset:function(B){var A=0,D=0;
+do{A+=B.offsetTop||0;
+D+=B.offsetLeft||0;
+B=B.offsetParent;
+if(B){if(B.tagName=="BODY"){break
+}var C=Element.getStyle(B,"position");
+if(C=="relative"||C=="absolute"){break
+}}}while(B);
+return Element._returnOffset(D,A)
+},absolutize:function(B){B=$(B);
+if(B.getStyle("position")=="absolute"){return 
+}var D=B.positionedOffset();
+var F=D[1];
+var E=D[0];
+var C=B.clientWidth;
+var A=B.clientHeight;
+B._originalLeft=E-parseFloat(B.style.left||0);
+B._originalTop=F-parseFloat(B.style.top||0);
+B._originalWidth=B.style.width;
+B._originalHeight=B.style.height;
+B.style.position="absolute";
+B.style.top=F+"px";
+B.style.left=E+"px";
+B.style.width=C+"px";
+B.style.height=A+"px";
+return B
+},relativize:function(A){A=$(A);
+if(A.getStyle("position")=="relative"){return 
+}A.style.position="relative";
+var C=parseFloat(A.style.top||0)-(A._originalTop||0);
+var B=parseFloat(A.style.left||0)-(A._originalLeft||0);
+A.style.top=C+"px";
+A.style.left=B+"px";
+A.style.height=A._originalHeight;
+A.style.width=A._originalWidth;
+return A
+},cumulativeScrollOffset:function(B){var A=0,C=0;
+do{A+=B.scrollTop||0;
+C+=B.scrollLeft||0;
+B=B.parentNode
+}while(B);
+return Element._returnOffset(C,A)
+},getOffsetParent:function(A){if(A.offsetParent){return $(A.offsetParent)
+}if(A==document.body){return $(A)
+}while((A=A.parentNode)&&A!=document.body){if(Element.getStyle(A,"position")!="static"){return $(A)
+}}return $(document.body)
+},viewportOffset:function(D){var A=0,C=0;
+var B=D;
+do{A+=B.offsetTop||0;
+C+=B.offsetLeft||0;
+if(B.offsetParent==document.body&&Element.getStyle(B,"position")=="absolute"){break
+}}while(B=B.offsetParent);
+B=D;
+do{if(!Prototype.Browser.Opera||B.tagName=="BODY"){A-=B.scrollTop||0;
+C-=B.scrollLeft||0
+}}while(B=B.parentNode);
+return Element._returnOffset(C,A)
+},clonePosition:function(B,D){var A=Object.extend({setLeft:true,setTop:true,setWidth:true,setHeight:true,offsetTop:0,offsetLeft:0},arguments[2]||{});
+D=$(D);
+var E=D.viewportOffset();
+B=$(B);
+var F=[0,0];
+var C=null;
+if(Element.getStyle(B,"position")=="absolute"){C=B.getOffsetParent();
+F=C.viewportOffset()
+}if(C==document.body){F[0]-=document.body.offsetLeft;
+F[1]-=document.body.offsetTop
+}if(A.setLeft){B.style.left=(E[0]-F[0]+A.offsetLeft)+"px"
+}if(A.setTop){B.style.top=(E[1]-F[1]+A.offsetTop)+"px"
+}if(A.setWidth){B.style.width=D.offsetWidth+"px"
+}if(A.setHeight){B.style.height=D.offsetHeight+"px"
+}return B
+}};
+Element.Methods.identify.counter=1;
+Object.extend(Element.Methods,{getElementsBySelector:Element.Methods.select,childElements:Element.Methods.immediateDescendants});
+Element._attributeTranslations={write:{names:{className:"class",htmlFor:"for"},values:{}}};
+if(!document.createRange||Prototype.Browser.Opera){Element.Methods.insert=function(E,G){E=$(E);
+if(Object.isString(G)||Object.isNumber(G)||Object.isElement(G)||(G&&(G.toElement||G.toHTML))){G={bottom:G}
+}var D=Element._insertionTranslations,F,B,H,C;
+for(B in G){F=G[B];
+B=B.toLowerCase();
+H=D[B];
+if(F&&F.toElement){F=F.toElement()
+}if(Object.isElement(F)){H.insert(E,F);
+continue
+}F=Object.toHTML(F);
+C=((B=="before"||B=="after")?E.parentNode:E).tagName.toUpperCase();
+if(D.tags[C]){var A=Element._getContentFromAnonymousElement(C,F.stripScripts());
+if(B=="top"||B=="after"){A.reverse()
+}A.each(H.insert.curry(E))
+}else{E.insertAdjacentHTML(H.adjacency,F.stripScripts())
+}F.evalScripts.bind(F).defer()
+}return E
+}
+}if(Prototype.Browser.Opera){Element.Methods._getStyle=Element.Methods.getStyle;
+Element.Methods.getStyle=function(A,B){switch(B){case"left":case"top":case"right":case"bottom":if(Element._getStyle(A,"position")=="static"){return null
+}default:return Element._getStyle(A,B)
+}};
+Element.Methods._readAttribute=Element.Methods.readAttribute;
+Element.Methods.readAttribute=function(A,B){if(B=="title"){return A.title
+}return Element._readAttribute(A,B)
+}
+}else{if(Prototype.Browser.IE){$w("positionedOffset getOffsetParent viewportOffset").each(function(A){Element.Methods[A]=Element.Methods[A].wrap(function(D,C){C=$(C);
+var B=C.getStyle("position");
+if(B!="static"){return D(C)
+}C.setStyle({position:"relative"});
+var E=D(C);
+C.setStyle({position:B});
+return E
+})
+});
+Element.Methods.getStyle=function(A,B){A=$(A);
+B=(B=="float"||B=="cssFloat")?"styleFloat":B.camelize();
+var C=A.style[B];
+if(!C&&A.currentStyle){C=A.currentStyle[B]
+}if(B=="opacity"){if(C=(A.getStyle("filter")||"").match(/alpha\(opacity=(.*)\)/)){if(C[1]){return parseFloat(C[1])/100
+}}return 1
+}if(C=="auto"){if((B=="width"||B=="height")&&(A.getStyle("display")!="none")){return A["offset"+B.capitalize()]+"px"
+}return null
+}return C
+};
+Element.Methods.setOpacity=function(B,E){function F(G){return G.replace(/alpha\([^\)]*\)/gi,"")
+}B=$(B);
+var A=B.currentStyle;
+if((A&&!A.hasLayout)||(!A&&B.style.zoom=="normal")){B.style.zoom=1
+}var D=B.getStyle("filter"),C=B.style;
+if(E==1||E===""){(D=F(D))?C.filter=D:C.removeAttribute("filter");
+return B
+}else{if(E<0.00001){E=0
+}}C.filter=F(D)+"alpha(opacity="+(E*100)+")";
+return B
+};
+Element._attributeTranslations={read:{names:{"class":"className","for":"htmlFor"},values:{_getAttr:function(A,B){return A.getAttribute(B,2)
+},_getAttrNode:function(A,C){var B=A.getAttributeNode(C);
+return B?B.value:""
+},_getEv:function(A,B){var B=A.getAttribute(B);
+return B?B.toString().slice(23,-2):null
+},_flag:function(A,B){return $(A).hasAttribute(B)?B:null
+},style:function(A){return A.style.cssText.toLowerCase()
+},title:function(A){return A.title
+}}}};
+Element._attributeTranslations.write={names:Object.clone(Element._attributeTranslations.read.names),values:{checked:function(A,B){A.checked=!!B
+},style:function(A,B){A.style.cssText=B?B:""
+}}};
+Element._attributeTranslations.has={};
+$w("colSpan rowSpan vAlign dateTime accessKey tabIndex encType maxLength readOnly longDesc").each(function(A){Element._attributeTranslations.write.names[A.toLowerCase()]=A;
+Element._attributeTranslations.has[A.toLowerCase()]=A
+});
+(function(A){Object.extend(A,{href:A._getAttr,src:A._getAttr,type:A._getAttr,action:A._getAttrNode,disabled:A._flag,checked:A._flag,readonly:A._flag,multiple:A._flag,onload:A._getEv,onunload:A._getEv,onclick:A._getEv,ondblclick:A._getEv,onmousedown:A._getEv,onmouseup:A._getEv,onmouseover:A._getEv,onmousemove:A._getEv,onmouseout:A._getEv,onfocus:A._getEv,onblur:A._getEv,onkeypress:A._getEv,onkeydown:A._getEv,onkeyup:A._getEv,onsubmit:A._getEv,onreset:A._getEv,onselect:A._getEv,onchange:A._getEv})
+})(Element._attributeTranslations.read.values)
+}else{if(Prototype.Browser.Gecko&&/rv:1\.8\.0/.test(navigator.userAgent)){Element.Methods.setOpacity=function(A,B){A=$(A);
+A.style.opacity=(B==1)?0.999999:(B==="")?"":(B<0.00001)?0:B;
+return A
+}
+}else{if(Prototype.Browser.WebKit){Element.Methods.setOpacity=function(A,B){A=$(A);
+A.style.opacity=(B==1||B==="")?"":(B<0.00001)?0:B;
+if(B==1){if(A.tagName=="IMG"&&A.width){A.width++;
+A.width--
+}else{try{var D=document.createTextNode(" ");
+A.appendChild(D);
+A.removeChild(D)
+}catch(C){}}}return A
+};
+Element.Methods.cumulativeOffset=function(B){var A=0,C=0;
+do{A+=B.offsetTop||0;
+C+=B.offsetLeft||0;
+if(B.offsetParent==document.body){if(Element.getStyle(B,"position")=="absolute"){break
+}}B=B.offsetParent
+}while(B);
+return Element._returnOffset(C,A)
+}
+}}}}if(Prototype.Browser.IE||Prototype.Browser.Opera){Element.Methods.update=function(B,C){B=$(B);
+if(C&&C.toElement){C=C.toElement()
+}if(Object.isElement(C)){return B.update().insert(C)
+}C=Object.toHTML(C);
+var A=B.tagName.toUpperCase();
+if(A in Element._insertionTranslations.tags){$A(B.childNodes).each(function(D){B.removeChild(D)
+});
+Element._getContentFromAnonymousElement(A,C.stripScripts()).each(function(D){B.appendChild(D)
+})
+}else{B.innerHTML=C.stripScripts()
+}C.evalScripts.bind(C).defer();
+return B
+}
+}if(document.createElement("div").outerHTML){Element.Methods.replace=function(C,E){C=$(C);
+if(E&&E.toElement){E=E.toElement()
+}if(Object.isElement(E)){C.parentNode.replaceChild(E,C);
+return C
+}E=Object.toHTML(E);
+var D=C.parentNode,B=D.tagName.toUpperCase();
+if(Element._insertionTranslations.tags[B]){var F=C.next();
+var A=Element._getContentFromAnonymousElement(B,E.stripScripts());
+D.removeChild(C);
+if(F){A.each(function(G){D.insertBefore(G,F)
+})
+}else{A.each(function(G){D.appendChild(G)
+})
+}}else{C.outerHTML=E.stripScripts()
+}E.evalScripts.bind(E).defer();
+return C
+}
+}Element._returnOffset=function(B,C){var A=[B,C];
+A.left=B;
+A.top=C;
+return A
+};
+Element._getContentFromAnonymousElement=function(C,B){var D=new Element("div"),A=Element._insertionTranslations.tags[C];
+D.innerHTML=A[0]+B+A[1];
+A[2].times(function(){D=D.firstChild
+});
+return $A(D.childNodes)
+};
+Element._insertionTranslations={before:{adjacency:"beforeBegin",insert:function(A,B){A.parentNode.insertBefore(B,A)
+},initializeRange:function(B,A){A.setStartBefore(B)
+}},top:{adjacency:"afterBegin",insert:function(A,B){A.insertBefore(B,A.firstChild)
+},initializeRange:function(B,A){A.selectNodeContents(B);
+A.collapse(true)
+}},bottom:{adjacency:"beforeEnd",insert:function(A,B){A.appendChild(B)
+}},after:{adjacency:"afterEnd",insert:function(A,B){A.parentNode.insertBefore(B,A.nextSibling)
+},initializeRange:function(B,A){A.setStartAfter(B)
+}},tags:{TABLE:["<table>","</table>",1],TBODY:["<table><tbody>","</tbody></table>",2],TR:["<table><tbody><tr>","</tr></tbody></table>",3],TD:["<table><tbody><tr><td>","</td></tr></tbody></table>",4],SELECT:["<select>","</select>",1]}};
+(function(){this.bottom.initializeRange=this.top.initializeRange;
+Object.extend(this.tags,{THEAD:this.tags.TBODY,TFOOT:this.tags.TBODY,TH:this.tags.TD})
+}).call(Element._insertionTranslations);
+Element.Methods.Simulated={hasAttribute:function(A,C){C=Element._attributeTranslations.has[C]||C;
+var B=$(A).getAttributeNode(C);
+return B&&B.specified
+}};
+Element.Methods.ByTag={};
+Object.extend(Element,Element.Methods);
+if(!Prototype.BrowserFeatures.ElementExtensions&&document.createElement("div").__proto__){window.HTMLElement={};
+window.HTMLElement.prototype=document.createElement("div").__proto__;
+Prototype.BrowserFeatures.ElementExtensions=true
+}Element.extend=(function(){if(Prototype.BrowserFeatures.SpecificElementExtensions){return Prototype.K
+}var A={},B=Element.Methods.ByTag;
+var C=Object.extend(function(F){if(!F||F._extendedByPrototype||F.nodeType!=1||F==window){return F
+}var D=Object.clone(A),E=F.tagName,H,G;
+if(B[E]){Object.extend(D,B[E])
+}for(H in D){G=D[H];
+if(Object.isFunction(G)&&!(H in F)){F[H]=G.methodize()
+}}F._extendedByPrototype=Prototype.emptyFunction;
+return F
+},{refresh:function(){if(!Prototype.BrowserFeatures.ElementExtensions){Object.extend(A,Element.Methods);
+Object.extend(A,Element.Methods.Simulated)
+}}});
+C.refresh();
+return C
+})();
+Element.hasAttribute=function(A,B){if(A.hasAttribute){return A.hasAttribute(B)
+}return Element.Methods.Simulated.hasAttribute(A,B)
+};
+Element.addMethods=function(C){var I=Prototype.BrowserFeatures,D=Element.Methods.ByTag;
+if(!C){Object.extend(Form,Form.Methods);
+Object.extend(Form.Element,Form.Element.Methods);
+Object.extend(Element.Methods.ByTag,{"FORM":Object.clone(Form.Methods),"INPUT":Object.clone(Form.Element.Methods),"SELECT":Object.clone(Form.Element.Methods),"TEXTAREA":Object.clone(Form.Element.Methods)})
+}if(arguments.length==2){var B=C;
+C=arguments[1]
+}if(!B){Object.extend(Element.Methods,C||{})
+}else{if(Object.isArray(B)){B.each(H)
+}else{H(B)
+}}function H(F){F=F.toUpperCase();
+if(!Element.Methods.ByTag[F]){Element.Methods.ByTag[F]={}
+}Object.extend(Element.Methods.ByTag[F],C)
+}function A(L,K,F){F=F||false;
+for(var N in L){var M=L[N];
+if(!Object.isFunction(M)){continue
+}if(!F||!(N in K)){K[N]=M.methodize()
+}}}function E(L){var F;
+var K={"OPTGROUP":"OptGroup","TEXTAREA":"TextArea","P":"Paragraph","FIELDSET":"FieldSet","UL":"UList","OL":"OList","DL":"DList","DIR":"Directory","H1":"Heading","H2":"Heading","H3":"Heading","H4":"Heading","H5":"Heading","H6":"Heading","Q":"Quote","INS":"Mod","DEL":"Mod","A":"Anchor","IMG":"Image","CAPTION":"TableCaption","COL":"TableCol","COLGROUP":"TableCol","THEAD":"TableSection","TFOOT":"TableSection","TBODY":"TableSection","TR":"TableRow","TH":"TableCell","TD":"TableCell","FRAMESET":"FrameSet","IFRAME":"IFrame"};
+if(K[L]){F="HTML"+K[L]+"Element"
+}if(window[F]){return window[F]
+}F="HTML"+L+"Element";
+if(window[F]){return window[F]
+}F="HTML"+L.capitalize()+"Element";
+if(window[F]){return window[F]
+}window[F]={};
+window[F].prototype=document.createElement(L).__proto__;
+return window[F]
+}if(I.ElementExtensions){A(Element.Methods,HTMLElement.prototype);
+A(Element.Methods.Simulated,HTMLElement.prototype,true)
+}if(I.SpecificElementExtensions){for(var J in Element.Methods.ByTag){var G=E(J);
+if(Object.isUndefined(G)){continue
+}A(D[J],G.prototype)
+}}Object.extend(Element,Element.Methods);
+delete Element.ByTag;
+if(Element.extend.refresh){Element.extend.refresh()
+}Element.cache={}
+};
+document.viewport={getDimensions:function(){var A={};
+$w("width height").each(function(C){var B=C.capitalize();
+A[C]=self["inner"+B]||(document.documentElement["client"+B]||document.body["client"+B])
+});
+return A
+},getWidth:function(){return this.getDimensions().width
+},getHeight:function(){return this.getDimensions().height
+},getScrollOffsets:function(){return Element._returnOffset(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft,window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop)
+}};
+var Selector=Class.create({initialize:function(A){this.expression=A.strip();
+this.compileMatcher()
+},compileMatcher:function(){if(Prototype.BrowserFeatures.XPath&&!(/(\[[\w-]*?:|:checked)/).test(this.expression)){return this.compileXPathMatcher()
+}var e=this.expression,ps=Selector.patterns,h=Selector.handlers,c=Selector.criteria,le,p,m;
+if(Selector._cache[e]){this.matcher=Selector._cache[e];
+return 
+}this.matcher=["this.matcher = function(root) {","var r = root, h = Selector.handlers, c = false, n;"];
+while(e&&le!=e&&(/\S/).test(e)){le=e;
+for(var i in ps){p=ps[i];
+if(m=e.match(p)){this.matcher.push(Object.isFunction(c[i])?c[i](m):new Template(c[i]).evaluate(m));
+e=e.replace(m[0],"");
+break
+}}}this.matcher.push("return h.unique(n);\n}");
+eval(this.matcher.join("\n"));
+Selector._cache[this.expression]=this.matcher
+},compileXPathMatcher:function(){var E=this.expression,F=Selector.patterns,B=Selector.xpath,D,A;
+if(Selector._cache[E]){this.xpath=Selector._cache[E];
+return 
+}this.matcher=[".//*"];
+while(E&&D!=E&&(/\S/).test(E)){D=E;
+for(var C in F){if(A=E.match(F[C])){this.matcher.push(Object.isFunction(B[C])?B[C](A):new Template(B[C]).evaluate(A));
+E=E.replace(A[0],"");
+break
+}}}this.xpath=this.matcher.join("");
+Selector._cache[this.expression]=this.xpath
+},findElements:function(A){A=A||document;
+if(this.xpath){return document._getElementsByXPath(this.xpath,A)
+}return this.matcher(A)
+},match:function(H){this.tokens=[];
+var L=this.expression,A=Selector.patterns,E=Selector.assertions;
+var B,D,F;
+while(L&&B!==L&&(/\S/).test(L)){B=L;
+for(var I in A){D=A[I];
+if(F=L.match(D)){if(E[I]){this.tokens.push([I,Object.clone(F)]);
+L=L.replace(F[0],"")
+}else{return this.findElements(document).include(H)
+}}}}var K=true,C,J;
+for(var I=0,G;
+G=this.tokens[I];
+I++){C=G[0],J=G[1];
+if(!Selector.assertions[C](H,J)){K=false;
+break
+}}return K
+},toString:function(){return this.expression
+},inspect:function(){return"#<Selector:"+this.expression.inspect()+">"
+}});
+Object.extend(Selector,{_cache:{},xpath:{descendant:"//*",child:"/*",adjacent:"/following-sibling::*[1]",laterSibling:"/following-sibling::*",tagName:function(A){if(A[1]=="*"){return""
+}return"[local-name()='"+A[1].toLowerCase()+"' or local-name()='"+A[1].toUpperCase()+"']"
+},className:"[contains(concat(' ', @class, ' '), ' #{1} ')]",id:"[@id='#{1}']",attrPresence:"[@#{1}]",attr:function(A){A[3]=A[5]||A[6];
+return new Template(Selector.xpath.operators[A[2]]).evaluate(A)
+},pseudo:function(A){var B=Selector.xpath.pseudos[A[1]];
+if(!B){return""
+}if(Object.isFunction(B)){return B(A)
+}return new Template(Selector.xpath.pseudos[A[1]]).evaluate(A)
+},operators:{"=":"[@#{1}='#{3}']","!=":"[@#{1}!='#{3}']","^=":"[starts-with(@#{1}, '#{3}')]","$=":"[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']","*=":"[contains(@#{1}, '#{3}')]","~=":"[contains(concat(' ', @#{1}, ' '), ' #{3} ')]","|=":"[contains(concat('-', @#{1}, '-'), '-#{3}-')]"},pseudos:{"first-child":"[not(preceding-sibling::*)]","last-child":"[not(following-sibling::*)]","only-child":"[not(preceding-sibling::* or following-sibling::*)]","empty":"[count(*) = 0 and (count(text()) = 0 or translate(text(), ' \t\r\n', '') = '')]","checked":"[@checked]","disabled":"[@disabled]","enabled":"[not(@disabled)]","not":function(B){var H=B[6],G=Selector.patterns,A=Selector.xpath,E,B,C;
+var F=[];
+while(H&&E!=H&&(/\S/).test(H)){E=H;
+for(var D in G){if(B=H.match(G[D])){C=Object.isFunction(A[D])?A[D](B):new Template(A[D]).evaluate(B);
+F.push("("+C.substring(1,C.length-1)+")");
+H=H.replace(B[0],"");
+break
+}}}return"[not("+F.join(" and ")+")]"
+},"nth-child":function(A){return Selector.xpath.pseudos.nth("(count(./preceding-sibling::*) + 1) ",A)
+},"nth-last-child":function(A){return Selector.xpath.pseudos.nth("(count(./following-sibling::*) + 1) ",A)
+},"nth-of-type":function(A){return Selector.xpath.pseudos.nth("position() ",A)
+},"nth-last-of-type":function(A){return Selector.xpath.pseudos.nth("(last() + 1 - position()) ",A)
+},"first-of-type":function(A){A[6]="1";
+return Selector.xpath.pseudos["nth-of-type"](A)
+},"last-of-type":function(A){A[6]="1";
+return Selector.xpath.pseudos["nth-last-of-type"](A)
+},"only-of-type":function(A){var B=Selector.xpath.pseudos;
+return B["first-of-type"](A)+B["last-of-type"](A)
+},nth:function(E,C){var F,G=C[6],B;
+if(G=="even"){G="2n+0"
+}if(G=="odd"){G="2n+1"
+}if(F=G.match(/^(\d+)$/)){return"["+E+"= "+F[1]+"]"
+}if(F=G.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(F[1]=="-"){F[1]=-1
+}var D=F[1]?Number(F[1]):1;
+var A=F[2]?Number(F[2]):0;
+B="[((#{fragment} - #{b}) mod #{a} = 0) and ((#{fragment} - #{b}) div #{a} >= 0)]";
+return new Template(B).evaluate({fragment:E,a:D,b:A})
+}}}},criteria:{tagName:'n = h.tagName(n, r, "#{1}", c);   c = false;',className:'n = h.className(n, r, "#{1}", c); c = false;',id:'n = h.id(n, r, "#{1}", c);        c = false;',attrPresence:'n = h.attrPresence(n, r, "#{1}"); c = false;',attr:function(A){A[3]=(A[5]||A[6]);
+return new Template('n = h.attr(n, r, "#{1}", "#{3}", "#{2}"); c = false;').evaluate(A)
+},pseudo:function(A){if(A[6]){A[6]=A[6].replace(/"/g,'\\"')
+}return new Template('n = h.pseudo(n, "#{1}", "#{6}", r, c); c = false;').evaluate(A)
+},descendant:'c = "descendant";',child:'c = "child";',adjacent:'c = "adjacent";',laterSibling:'c = "laterSibling";'},patterns:{laterSibling:/^\s*~\s*/,child:/^\s*>\s*/,adjacent:/^\s*\+\s*/,descendant:/^\s/,tagName:/^\s*(\*|[\w\-]+)(\b|$)?/,id:/^#([\w\-\*]+)(\b|$)/,className:/^\.([\w\-\*]+)(\b|$)/,pseudo:/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|(?=\s)|(?=:))/,attrPresence:/^\[([\w]+)\]/,attr:/\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['"])([^\4]*?)\4|([^'"][^\]]*?)))?\]/},assertions:{tagName:function(A,B){return B[1].toUpperCase()==A.tagName.toUpperCase()
+},className:function(A,B){return Element.hasClassName(A,B[1])
+},id:function(A,B){return A.id===B[1]
+},attrPresence:function(A,B){return Element.hasAttribute(A,B[1])
+},attr:function(B,C){var A=Element.readAttribute(B,C[1]);
+return Selector.operators[C[2]](A,C[3])
+}},handlers:{concat:function(B,A){for(var C=0,D;
+D=A[C];
+C++){B.push(D)
+}return B
+},mark:function(A){for(var B=0,C;
+C=A[B];
+B++){C._counted=true
+}return A
+},unmark:function(A){for(var B=0,C;
+C=A[B];
+B++){C._counted=undefined
+}return A
+},index:function(A,D,G){A._counted=true;
+if(D){for(var B=A.childNodes,E=B.length-1,C=1;
+E>=0;
+E--){var F=B[E];
+if(F.nodeType==1&&(!G||F._counted)){F.nodeIndex=C++
+}}}else{for(var E=0,C=1,B=A.childNodes;
+F=B[E];
+E++){if(F.nodeType==1&&(!G||F._counted)){F.nodeIndex=C++
+}}}},unique:function(B){if(B.length==0){return B
+}var D=[],E;
+for(var C=0,A=B.length;
+C<A;
+C++){if(!(E=B[C])._counted){E._counted=true;
+D.push(Element.extend(E))
+}}return Selector.handlers.unmark(D)
+},descendant:function(A){var D=Selector.handlers;
+for(var C=0,B=[],E;
+E=A[C];
+C++){D.concat(B,E.getElementsByTagName("*"))
+}return B
+},child:function(A){var F=Selector.handlers;
+for(var E=0,D=[],G;
+G=A[E];
+E++){for(var B=0,C=[],H;
+H=G.childNodes[B];
+B++){if(H.nodeType==1&&H.tagName!="!"){D.push(H)
+}}}return D
+},adjacent:function(A){for(var C=0,B=[],E;
+E=A[C];
+C++){var D=this.nextElementSibling(E);
+if(D){B.push(D)
+}}return B
+},laterSibling:function(A){var D=Selector.handlers;
+for(var C=0,B=[],E;
+E=A[C];
+C++){D.concat(B,Element.nextSiblings(E))
+}return B
+},nextElementSibling:function(A){while(A=A.nextSibling){if(A.nodeType==1){return A
+}}return null
+},previousElementSibling:function(A){while(A=A.previousSibling){if(A.nodeType==1){return A
+}}return null
+},tagName:function(B,A,E,H){E=E.toUpperCase();
+var D=[],F=Selector.handlers;
+if(B){if(H){if(H=="descendant"){for(var C=0,G;
+G=B[C];
+C++){F.concat(D,G.getElementsByTagName(E))
+}return D
+}else{B=this[H](B)
+}if(E=="*"){return B
+}}for(var C=0,G;
+G=B[C];
+C++){if(G.tagName.toUpperCase()==E){D.push(G)
+}}return D
+}else{return A.getElementsByTagName(E)
+}},id:function(B,A,H,F){var G=$(H),D=Selector.handlers;
+if(!G){return[]
+}if(!B&&A==document){return[G]
+}if(B){if(F){if(F=="child"){for(var C=0,E;
+E=B[C];
+C++){if(G.parentNode==E){return[G]
+}}}else{if(F=="descendant"){for(var C=0,E;
+E=B[C];
+C++){if(Element.descendantOf(G,E)){return[G]
+}}}else{if(F=="adjacent"){for(var C=0,E;
+E=B[C];
+C++){if(Selector.handlers.previousElementSibling(G)==E){return[G]
+}}}else{B=D[F](B)
+}}}}for(var C=0,E;
+E=B[C];
+C++){if(E==G){return[G]
+}}return[]
+}return(G&&Element.descendantOf(G,A))?[G]:[]
+},className:function(B,A,C,D){if(B&&D){B=this[D](B)
+}return Selector.handlers.byClassName(B,A,C)
+},byClassName:function(C,B,F){if(!C){C=Selector.handlers.descendant([B])
+}var H=" "+F+" ";
+for(var E=0,D=[],G,A;
+G=C[E];
+E++){A=G.className;
+if(A.length==0){continue
+}if(A==F||(" "+A+" ").include(H)){D.push(G)
+}}return D
+},attrPresence:function(C,B,A){if(!C){C=B.getElementsByTagName("*")
+}var E=[];
+for(var D=0,F;
+F=C[D];
+D++){if(Element.hasAttribute(F,A)){E.push(F)
+}}return E
+},attr:function(A,H,G,I,B){if(!A){A=H.getElementsByTagName("*")
+}var J=Selector.operators[B],D=[];
+for(var E=0,C;
+C=A[E];
+E++){var F=Element.readAttribute(C,G);
+if(F===null){continue
+}if(J(F,I)){D.push(C)
+}}return D
+},pseudo:function(B,C,E,A,D){if(B&&D){B=this[D](B)
+}if(!B){B=A.getElementsByTagName("*")
+}return Selector.pseudos[C](B,E,A)
+}},pseudos:{"first-child":function(B,F,A){for(var D=0,C=[],E;
+E=B[D];
+D++){if(Selector.handlers.previousElementSibling(E)){continue
+}C.push(E)
+}return C
+},"last-child":function(B,F,A){for(var D=0,C=[],E;
+E=B[D];
+D++){if(Selector.handlers.nextElementSibling(E)){continue
+}C.push(E)
+}return C
+},"only-child":function(B,G,A){var E=Selector.handlers;
+for(var D=0,C=[],F;
+F=B[D];
+D++){if(!E.previousElementSibling(F)&&!E.nextElementSibling(F)){C.push(F)
+}}return C
+},"nth-child":function(B,C,A){return Selector.pseudos.nth(B,C,A)
+},"nth-last-child":function(B,C,A){return Selector.pseudos.nth(B,C,A,true)
+},"nth-of-type":function(B,C,A){return Selector.pseudos.nth(B,C,A,false,true)
+},"nth-last-of-type":function(B,C,A){return Selector.pseudos.nth(B,C,A,true,true)
+},"first-of-type":function(B,C,A){return Selector.pseudos.nth(B,"1",A,false,true)
+},"last-of-type":function(B,C,A){return Selector.pseudos.nth(B,"1",A,true,true)
+},"only-of-type":function(B,D,A){var C=Selector.pseudos;
+return C["last-of-type"](C["first-of-type"](B,D,A),D,A)
+},getIndices:function(B,A,C){if(B==0){return A>0?[A]:[]
+}return $R(1,C).inject([],function(D,E){if(0==(E-A)%B&&(E-A)/B>=0){D.push(E)
+}return D
+})
+},nth:function(A,L,N,K,C){if(A.length==0){return[]
+}if(L=="even"){L="2n+0"
+}if(L=="odd"){L="2n+1"
+}var J=Selector.handlers,I=[],B=[],E;
+J.mark(A);
+for(var H=0,D;
+D=A[H];
+H++){if(!D.parentNode._counted){J.index(D.parentNode,K,C);
+B.push(D.parentNode)
+}}if(L.match(/^\d+$/)){L=Number(L);
+for(var H=0,D;
+D=A[H];
+H++){if(D.nodeIndex==L){I.push(D)
+}}}else{if(E=L.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(E[1]=="-"){E[1]=-1
+}var O=E[1]?Number(E[1]):1;
+var M=E[2]?Number(E[2]):0;
+var P=Selector.pseudos.getIndices(O,M,A.length);
+for(var H=0,D,F=P.length;
+D=A[H];
+H++){for(var G=0;
+G<F;
+G++){if(D.nodeIndex==P[G]){I.push(D)
+}}}}}J.unmark(A);
+J.unmark(B);
+return I
+},"empty":function(B,F,A){for(var D=0,C=[],E;
+E=B[D];
+D++){if(E.tagName=="!"||(E.firstChild&&!E.innerHTML.match(/^\s*$/))){continue
+}C.push(E)
+}return C
+},"not":function(A,D,I){var G=Selector.handlers,J,C;
+var H=new Selector(D).findElements(I);
+G.mark(H);
+for(var F=0,E=[],B;
+B=A[F];
+F++){if(!B._counted){E.push(B)
+}}G.unmark(H);
+return E
+},"enabled":function(B,F,A){for(var D=0,C=[],E;
+E=B[D];
+D++){if(!E.disabled){C.push(E)
+}}return C
+},"disabled":function(B,F,A){for(var D=0,C=[],E;
+E=B[D];
+D++){if(E.disabled){C.push(E)
+}}return C
+},"checked":function(B,F,A){for(var D=0,C=[],E;
+E=B[D];
+D++){if(E.checked){C.push(E)
+}}return C
+}},operators:{"=":function(B,A){return B==A
+},"!=":function(B,A){return B!=A
+},"^=":function(B,A){return B.startsWith(A)
+},"$=":function(B,A){return B.endsWith(A)
+},"*=":function(B,A){return B.include(A)
+},"~=":function(B,A){return(" "+B+" ").include(" "+A+" ")
+},"|=":function(B,A){return("-"+B.toUpperCase()+"-").include("-"+A.toUpperCase()+"-")
+}},matchElements:function(F,G){var E=new Selector(G).findElements(),D=Selector.handlers;
+D.mark(E);
+for(var C=0,B=[],A;
+A=F[C];
+C++){if(A._counted){B.push(A)
+}}D.unmark(E);
+return B
+},findElement:function(B,C,A){if(Object.isNumber(C)){A=C;
+C=false
+}return Selector.matchElements(B,C||"*")[A||0]
+},findChildElements:function(E,G){var H=G.join(","),G=[];
+H.scan(/(([\w#:.~>+()\s-]+|\*|\[.*?\])+)\s*(,|$)/,function(I){G.push(I[1].strip())
+});
+var D=[],F=Selector.handlers;
+for(var C=0,B=G.length,A;
+C<B;
+C++){A=new Selector(G[C].strip());
+F.concat(D,A.findElements(E))
+}return(B>1)?F.unique(D):D
+}});
+function $$(){return Selector.findChildElements(document,$A(arguments))
+}var Form={reset:function(A){$(A).reset();
+return A
+},serializeElements:function(G,B){if(typeof B!="object"){B={hash:!!B}
+}else{if(B.hash===undefined){B.hash=true
+}}var C,F,A=false,E=B.submit;
+var D=G.inject({},function(H,I){if(!I.disabled&&I.name){C=I.name;
+F=$(I).getValue();
+if(F!=null&&(I.type!="submit"||(!A&&E!==false&&(!E||C==E)&&(A=true)))){if(C in H){if(!Object.isArray(H[C])){H[C]=[H[C]]
+}H[C].push(F)
+}else{H[C]=F
+}}}return H
+});
+return B.hash?D:Object.toQueryString(D)
+}};
+Form.Methods={serialize:function(B,A){return Form.serializeElements(Form.getElements(B),A)
+},getElements:function(A){return $A($(A).getElementsByTagName("*")).inject([],function(B,C){if(Form.Element.Serializers[C.tagName.toLowerCase()]){B.push(Element.extend(C))
+}return B
+})
+},getInputs:function(G,C,D){G=$(G);
+var A=G.getElementsByTagName("input");
+if(!C&&!D){return $A(A).map(Element.extend)
+}for(var E=0,H=[],F=A.length;
+E<F;
+E++){var B=A[E];
+if((C&&B.type!=C)||(D&&B.name!=D)){continue
+}H.push(Element.extend(B))
+}return H
+},disable:function(A){A=$(A);
+Form.getElements(A).invoke("disable");
+return A
+},enable:function(A){A=$(A);
+Form.getElements(A).invoke("enable");
+return A
+},findFirstElement:function(B){var C=$(B).getElements().findAll(function(D){return"hidden"!=D.type&&!D.disabled
+});
+var A=C.findAll(function(D){return D.hasAttribute("tabIndex")&&D.tabIndex>=0
+}).sortBy(function(D){return D.tabIndex
+}).first();
+return A?A:C.find(function(D){return["input","select","textarea"].include(D.tagName.toLowerCase())
+})
+},focusFirstElement:function(A){A=$(A);
+A.findFirstElement().activate();
+return A
+},request:function(B,A){B=$(B),A=Object.clone(A||{});
+var D=A.parameters,C=B.readAttribute("action")||"";
+if(C.blank()){C=window.location.href
+}A.parameters=B.serialize(true);
+if(D){if(Object.isString(D)){D=D.toQueryParams()
+}Object.extend(A.parameters,D)
+}if(B.hasAttribute("method")&&!A.method){A.method=B.method
+}return new Ajax.Request(C,A)
+}};
+Form.Element={focus:function(A){$(A).focus();
+return A
+},select:function(A){$(A).select();
+return A
+}};
+Form.Element.Methods={serialize:function(A){A=$(A);
+if(!A.disabled&&A.name){var B=A.getValue();
+if(B!=undefined){var C={};
+C[A.name]=B;
+return Object.toQueryString(C)
+}}return""
+},getValue:function(A){A=$(A);
+var B=A.tagName.toLowerCase();
+return Form.Element.Serializers[B](A)
+},setValue:function(A,B){A=$(A);
+var C=A.tagName.toLowerCase();
+Form.Element.Serializers[C](A,B);
+return A
+},clear:function(A){$(A).value="";
+return A
+},present:function(A){return $(A).value!=""
+},activate:function(A){A=$(A);
+try{A.focus();
+if(A.select&&(A.tagName.toLowerCase()!="input"||!["button","reset","submit"].include(A.type))){A.select()
+}}catch(B){}return A
+},disable:function(A){A=$(A);
+A.blur();
+A.disabled=true;
+return A
+},enable:function(A){A=$(A);
+A.disabled=false;
+return A
+}};
+var Field=Form.Element;
+var $F=Form.Element.Methods.getValue;
+Form.Element.Serializers={input:function(A,B){switch(A.type.toLowerCase()){case"checkbox":case"radio":return Form.Element.Serializers.inputSelector(A,B);
+default:return Form.Element.Serializers.textarea(A,B)
+}},inputSelector:function(A,B){if(B===undefined){return A.checked?A.value:null
+}else{A.checked=!!B
+}},textarea:function(A,B){if(B===undefined){return A.value
+}else{A.value=B
+}},select:function(D,A){if(A===undefined){return this[D.type=="select-one"?"selectOne":"selectMany"](D)
+}else{var C,F,G=!Object.isArray(A);
+for(var B=0,E=D.length;
+B<E;
+B++){C=D.options[B];
+F=this.optionValue(C);
+if(G){if(F==A){C.selected=true;
+return 
+}}else{C.selected=A.include(F)
+}}}},selectOne:function(B){var A=B.selectedIndex;
+return A>=0?this.optionValue(B.options[A]):null
+},selectMany:function(D){var A,E=D.length;
+if(!E){return null
+}for(var C=0,A=[];
+C<E;
+C++){var B=D.options[C];
+if(B.selected){A.push(this.optionValue(B))
+}}return A
+},optionValue:function(A){return Element.extend(A).hasAttribute("value")?A.value:A.text
+}};
+Abstract.TimedObserver=Class.create(PeriodicalExecuter,{initialize:function($super,A,B,C){$super(C,B);
+this.element=$(A);
+this.lastValue=this.getValue()
+},execute:function(){var A=this.getValue();
+if(Object.isString(this.lastValue)&&Object.isString(A)?this.lastValue!=A:String(this.lastValue)!=String(A)){this.callback(this.element,A);
+this.lastValue=A
+}}});
+Form.Element.Observer=Class.create(Abstract.TimedObserver,{getValue:function(){return Form.Element.getValue(this.element)
+}});
+Form.Observer=Class.create(Abstract.TimedObserver,{getValue:function(){return Form.serialize(this.element)
+}});
+Abstract.EventObserver=Class.create({initialize:function(A,B){this.element=$(A);
+this.callback=B;
+this.lastValue=this.getValue();
+if(this.element.tagName.toLowerCase()=="form"){this.registerFormCallbacks()
+}else{this.registerCallback(this.element)
+}},onElementEvent:function(){var A=this.getValue();
+if(this.lastValue!=A){this.callback(this.element,A);
+this.lastValue=A
+}},registerFormCallbacks:function(){Form.getElements(this.element).each(this.registerCallback,this)
+},registerCallback:function(A){if(A.type){switch(A.type.toLowerCase()){case"checkbox":case"radio":Event.observe(A,"click",this.onElementEvent.bind(this));
+break;
+default:Event.observe(A,"change",this.onElementEvent.bind(this));
+break
+}}}});
+Form.Element.EventObserver=Class.create(Abstract.EventObserver,{getValue:function(){return Form.Element.getValue(this.element)
+}});
+Form.EventObserver=Class.create(Abstract.EventObserver,{getValue:function(){return Form.serialize(this.element)
+}});
+if(!window.Event){var Event={}
+}Object.extend(Event,{KEY_BACKSPACE:8,KEY_TAB:9,KEY_RETURN:13,KEY_ESC:27,KEY_LEFT:37,KEY_UP:38,KEY_RIGHT:39,KEY_DOWN:40,KEY_DELETE:46,KEY_HOME:36,KEY_END:35,KEY_PAGEUP:33,KEY_PAGEDOWN:34,KEY_INSERT:45,cache:{},relatedTarget:function(B){var A;
+switch(B.type){case"mouseover":A=B.fromElement;
+break;
+case"mouseout":A=B.toElement;
+break;
+default:return null
+}return Element.extend(A)
+}});
+Event.Methods=(function(){var A;
+if(Prototype.Browser.IE){var B={0:1,1:4,2:2};
+A=function(D,C){return D.button==B[C]
+}
+}else{if(Prototype.Browser.WebKit){A=function(D,C){switch(C){case 0:return D.which==1&&!D.metaKey;
+case 1:return D.which==1&&D.metaKey;
+default:return false
+}}
+}else{A=function(D,C){return D.which?(D.which===C+1):(D.button===C)
+}
+}}return{isLeftClick:function(C){return A(C,0)
+},isMiddleClick:function(C){return A(C,1)
+},isRightClick:function(C){return A(C,2)
+},element:function(D){var C=Event.extend(D).target;
+return Element.extend(C.nodeType==Node.TEXT_NODE?C.parentNode:C)
+},findElement:function(D,E){var C=Event.element(D);
+return C.match(E)?C:C.up(E)
+},pointer:function(C){return{x:C.pageX||(C.clientX+(document.documentElement.scrollLeft||document.body.scrollLeft)),y:C.pageY||(C.clientY+(document.documentElement.scrollTop||document.body.scrollTop))}
+},pointerX:function(C){return Event.pointer(C).x
+},pointerY:function(C){return Event.pointer(C).y
+},stop:function(C){Event.extend(C);
+C.preventDefault();
+C.stopPropagation();
+C.stopped=true
+}}
+})();
+Event.extend=(function(){var A=Object.keys(Event.Methods).inject({},function(B,C){B[C]=Event.Methods[C].methodize();
+return B
+});
+if(Prototype.Browser.IE){Object.extend(A,{stopPropagation:function(){this.cancelBubble=true
+},preventDefault:function(){this.returnValue=false
+},inspect:function(){return"[object Event]"
+}});
+return function(B){if(!B){return false
+}if(B._extendedByPrototype){return B
+}B._extendedByPrototype=Prototype.emptyFunction;
+var C=Event.pointer(B);
+Object.extend(B,{target:B.srcElement,relatedTarget:Event.relatedTarget(B),pageX:C.x,pageY:C.y});
+return Object.extend(B,A)
+}
+}else{Event.prototype=Event.prototype||document.createEvent("HTMLEvents").__proto__;
+Object.extend(Event.prototype,A);
+return Prototype.K
+}})();
+Object.extend(Event,(function(){var D=Event.cache;
+function E(I){if(I._eventID){return I._eventID
+}arguments.callee.id=arguments.callee.id||1;
+return I._eventID=++arguments.callee.id
+}function B(I){if(I&&I.include(":")){return"dataavailable"
+}return I
+}function F(I){return D[I]=D[I]||{}
+}function G(K,I){var J=F(K);
+return J[I]=J[I]||[]
+}function A(J,I,K){var N=E(J);
+var M=G(N,I);
+if(M.pluck("handler").include(K)){return false
+}var L=function(O){if(!Event||!Event.extend||(O.eventName&&O.eventName!=I)){return false
+}Event.extend(O);
+K.call(J,O)
+};
+L.handler=K;
+M.push(L);
+return L
+}function C(L,I,J){var K=G(L,I);
+return K.find(function(M){return M.handler==J
+})
+}function H(L,I,J){var K=F(L);
+if(!K[I]){return false
+}K[I]=K[I].without(C(L,I,J))
+}return{observe:function(K,I,L){K=$(K);
+var J=B(I);
+var M=A(K,I,L);
+if(!M){return K
+}if(K.addEventListener){K.addEventListener(J,M,false)
+}else{K.attachEvent("on"+J,M)
+}return K
+},stopObserving:function(K,I,L){K=$(K);
+var N=E(K),J=B(I);
+if(!L&&I){G(N,I).each(function(O){K.stopObserving(I,O.handler)
+});
+return K
+}else{if(!I){Object.keys(F(N)).each(function(O){K.stopObserving(O)
+});
+return K
+}}var M=C(N,I,L);
+if(!M){return K
+}if(K.removeEventListener){K.removeEventListener(J,M,false)
+}else{K.detachEvent("on"+J,M)
+}H(N,I,L);
+return K
+},fire:function(K,J,I){K=$(K);
+if(K==document&&document.createEvent&&!K.dispatchEvent){K=document.documentElement
+}if(document.createEvent){var L=document.createEvent("HTMLEvents");
+L.initEvent("dataavailable",true,true)
+}else{var L=document.createEventObject();
+L.eventType="ondataavailable"
+}L.eventName=J;
+L.memo=I||{};
+if(document.createEvent){K.dispatchEvent(L)
+}else{K.fireEvent(L.eventType,L)
+}return L
+}}
+})());
+Object.extend(Event,Event.Methods);
+Element.addMethods({fire:Event.fire,observe:Event.observe,stopObserving:Event.stopObserving});
+Object.extend(document,{fire:Element.Methods.fire.methodize(),observe:Element.Methods.observe.methodize(),stopObserving:Element.Methods.stopObserving.methodize()});
+(function(){var C,B=false;
+function A(){if(B){return 
+}if(C){window.clearInterval(C)
+}document.fire("dom:loaded");
+B=true
+}if(document.addEventListener){if(Prototype.Browser.WebKit){C=window.setInterval(function(){if(/loaded|complete/.test(document.readyState)){A()
+}},0);
+Event.observe(window,"load",A)
+}else{document.addEventListener("DOMContentLoaded",A,false)
+}}else{document.write("<script id=__onDOMContentLoaded defer src=//:><\/script>");
+$("__onDOMContentLoaded").onreadystatechange=function(){if(this.readyState=="complete"){this.onreadystatechange=null;
+A()
+}}
+}})();
+Hash.toQueryString=Object.toQueryString;
+var Toggle={display:Element.toggle};
+Element.Methods.childOf=Element.Methods.descendantOf;
+var Insertion={Before:function(A,B){return Element.insert(A,{before:B})
+},Top:function(A,B){return Element.insert(A,{top:B})
+},Bottom:function(A,B){return Element.insert(A,{bottom:B})
+},After:function(A,B){return Element.insert(A,{after:B})
+}};
+var $continue=new Error('"throw $continue" is deprecated, use "return" instead');
+var Position={includeScrollOffsets:false,prepare:function(){this.deltaX=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;
+this.deltaY=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0
+},within:function(B,A,C){if(this.includeScrollOffsets){return this.withinIncludingScrolloffsets(B,A,C)
+}this.xcomp=A;
+this.ycomp=C;
+this.offset=Element.cumulativeOffset(B);
+return(C>=this.offset[1]&&C<this.offset[1]+B.offsetHeight&&A>=this.offset[0]&&A<this.offset[0]+B.offsetWidth)
+},withinIncludingScrolloffsets:function(B,A,D){var C=Element.cumulativeScrollOffset(B);
+this.xcomp=A+C[0]-this.deltaX;
+this.ycomp=D+C[1]-this.deltaY;
+this.offset=Element.cumulativeOffset(B);
+return(this.ycomp>=this.offset[1]&&this.ycomp<this.offset[1]+B.offsetHeight&&this.xcomp>=this.offset[0]&&this.xcomp<this.offset[0]+B.offsetWidth)
+},overlap:function(B,A){if(!B){return 0
+}if(B=="vertical"){return((this.offset[1]+A.offsetHeight)-this.ycomp)/A.offsetHeight
+}if(B=="horizontal"){return((this.offset[0]+A.offsetWidth)-this.xcomp)/A.offsetWidth
+}},cumulativeOffset:Element.Methods.cumulativeOffset,positionedOffset:Element.Methods.positionedOffset,absolutize:function(A){Position.prepare();
+return Element.absolutize(A)
+},relativize:function(A){Position.prepare();
+return Element.relativize(A)
+},realOffset:Element.Methods.cumulativeScrollOffset,offsetParent:Element.Methods.getOffsetParent,page:Element.Methods.viewportOffset,clone:function(B,C,A){A=A||{};
+return Element.clonePosition(C,B,A)
+}};
+if(!document.getElementsByClassName){document.getElementsByClassName=function(B){function A(C){return C.blank()?null:"[contains(concat(' ', @class, ' '), ' "+C+" ')]"
+}B.getElementsByClassName=Prototype.BrowserFeatures.XPath?function(C,E){E=E.toString().strip();
+var D=/\s/.test(E)?$w(E).map(A).join(""):A(E);
+return D?document._getElementsByXPath(".//*"+D,C):[]
+}:function(E,F){F=F.toString().strip();
+var G=[],H=(/\s/.test(F)?$w(F):null);
+if(!H&&!F){return G
+}var C=$(E).getElementsByTagName("*");
+F=" "+F+" ";
+for(var D=0,J,I;
+J=C[D];
+D++){if(J.className&&(I=" "+J.className+" ")&&(I.include(F)||(H&&H.all(function(K){return !K.toString().blank()&&I.include(" "+K+" ")
+})))){G.push(Element.extend(J))
+}}return G
+};
+return function(D,C){return $(C||document.body).getElementsByClassName(D)
+}
+}(Element.Methods)
+}Element.ClassNames=Class.create();
+Element.ClassNames.prototype={initialize:function(A){this.element=$(A)
+},_each:function(A){this.element.className.split(/\s+/).select(function(B){return B.length>0
+})._each(A)
+},set:function(A){this.element.className=A
+},add:function(A){if(this.include(A)){return 
+}this.set($A(this).concat(A).join(" "))
+},remove:function(A){if(!this.include(A)){return 
+}this.set($A(this).without(A).join(" "))
+},toString:function(){return $A(this).join(" ")
+}};
+Object.extend(Element.ClassNames.prototype,Enumerable);
+Element.addMethods();
+Function.prototype.indexOf=function(){return -1
+};
+Element.clearChildren=function(A){A=$(A);
+while(A.firstChild){A.removeChild(A.firstChild)
+}return A
+};
+Element.isChildOf=function(B,A){while(B&&A!=B){B=B.parentNode
+}return A==B
+};
+if(typeof Node=="undefined"){Node={ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12}
+}Element.isUninitialized=function(A){if(A){if(A.nodeType==Node.ELEMENT_NODE){if(!A.parentNode||A.document&&A.document.readyState=="uninitialized"){return true
+}else{return !Element.descendantOf(A,document.documentElement)
+}return false
+}}};
+if(window.attachEvent){window.attachEvent("onunload",function(){Event.unloadElementsCache(document);
+Event.unloadElementsCache(window)
+})
+}Event.destroyEventCache=function(D){var C=D._eventID;
+if(C){var B=Event.cache[C];
+for(var A in B){var E=B[A];
+E.each(function(F){if(D.removeEventListener){D.removeEventListener(A,F,false)
+}else{D.detachEvent("on"+A,F)
+}});
+B[A]=null
+}delete Event.cache[C]
+}};
+Event.unloadElementsCache=function(E){if(E){Event.destroyEventCache(E);
+var B=E.all;
+if(B){var A=0;
+var D=B.length;
+for(var A=0;
+A<D;
+A++){Event.destroyEventCache(B[A])
+}}else{var C=E.firstChild;
+while(C){Event.unloadElementsCache(C);
+C=C.nextSibling
+}}}}
+
+if(!window.A4J){window.A4J={}
+}function Sarissa(){}Sarissa.VERSION="${project.version}";
+Sarissa.PARSED_OK="Document contains no parsing errors";
+Sarissa.PARSED_EMPTY="Document is empty";
+Sarissa.PARSED_UNKNOWN_ERROR="Not well-formed or other error";
+Sarissa.IS_ENABLED_TRANSFORM_NODE=false;
+var _sarissa_iNsCounter=0;
+var _SARISSA_IEPREFIX4XSLPARAM="";
+var _SARISSA_HAS_DOM_IMPLEMENTATION=document.implementation&&true;
+var _SARISSA_HAS_DOM_CREATE_DOCUMENT=_SARISSA_HAS_DOM_IMPLEMENTATION&&document.implementation.createDocument;
+var _SARISSA_HAS_DOM_FEATURE=_SARISSA_HAS_DOM_IMPLEMENTATION&&document.implementation.hasFeature;
+var _SARISSA_IS_MOZ=_SARISSA_HAS_DOM_CREATE_DOCUMENT&&_SARISSA_HAS_DOM_FEATURE;
+var _SARISSA_IS_SAFARI=(navigator.userAgent&&navigator.vendor&&(navigator.userAgent.toLowerCase().indexOf("applewebkit")!=-1||navigator.vendor.indexOf("Apple")!=-1));
+var _SARISSA_IS_IE=document.all&&window.ActiveXObject&&navigator.userAgent.toLowerCase().indexOf("msie")>-1&&navigator.userAgent.toLowerCase().indexOf("opera")==-1;
+if(!window.Node||!Node.ELEMENT_NODE){Node={ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12}
+}if(typeof XMLDocument=="undefined"&&typeof Document!="undefined"){XMLDocument=Document
+}if(_SARISSA_IS_IE){_SARISSA_IEPREFIX4XSLPARAM="xsl:";
+var _SARISSA_DOM_PROGID="";
+var _SARISSA_XMLHTTP_PROGID="";
+var _SARISSA_DOM_XMLWRITER="";
+Sarissa.pickRecentProgID=function(E){var D=false;
+for(var B=0;
+B<E.length&&!D;
+B++){try{var A=new ActiveXObject(E[B]);
+o2Store=E[B];
+D=true
+}catch(C){}}if(!D){throw"Could not retreive a valid progID of Class: "+E[E.length-1]+". (original exception: "+e+")"
+}E=null;
+return o2Store
+};
+_SARISSA_DOM_PROGID=null;
+_SARISSA_THREADEDDOM_PROGID=null;
+_SARISSA_XSLTEMPLATE_PROGID=null;
+_SARISSA_XMLHTTP_PROGID=null;
+if(!window.XMLHttpRequest){XMLHttpRequest=function(){if(!_SARISSA_XMLHTTP_PROGID){_SARISSA_XMLHTTP_PROGID=Sarissa.pickRecentProgID(["Msxml2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"])
+}return new ActiveXObject(_SARISSA_XMLHTTP_PROGID)
+}
+}Sarissa.getDomDocument=function(D,C){if(!_SARISSA_DOM_PROGID){_SARISSA_DOM_PROGID=Sarissa.pickRecentProgID(["Msxml2.DOMDocument.6.0","Msxml2.DOMDocument.3.0","MSXML2.DOMDocument","MSXML.DOMDocument","Microsoft.XMLDOM"])
+}var A=new ActiveXObject(_SARISSA_DOM_PROGID);
+if(C){var B="";
+if(D){if(C.indexOf(":")>1){B=C.substring(0,C.indexOf(":"));
+C=C.substring(C.indexOf(":")+1)
+}else{B="a"+(_sarissa_iNsCounter++)
+}}if(D){A.loadXML("<"+B+":"+C+" xmlns:"+B+'="'+D+'" />')
+}else{A.loadXML("<"+C+" />")
+}}return A
+};
+Sarissa.getParseErrorText=function(A){var C=Sarissa.PARSED_OK;
+if(A&&A.parseError&&A.parseError.errorCode&&A.parseError.errorCode!=0){C="XML Parsing Error: "+A.parseError.reason+"\nLocation: "+A.parseError.url+"\nLine Number "+A.parseError.line+", Column "+A.parseError.linepos+":\n"+A.parseError.srcText+"\n";
+for(var B=0;
+B<A.parseError.linepos;
+B++){C+="-"
+}C+="^\n"
+}else{if(A.documentElement==null){C=Sarissa.PARSED_EMPTY
+}}return C
+};
+Sarissa.setXpathNamespaces=function(A,B){A.setProperty("SelectionLanguage","XPath");
+A.setProperty("SelectionNamespaces",B)
+};
+XSLTProcessor=function(){if(!_SARISSA_XSLTEMPLATE_PROGID){_SARISSA_XSLTEMPLATE_PROGID=Sarissa.pickRecentProgID(["Msxml2.XSLTemplate.6.0","MSXML2.XSLTemplate.3.0"])
+}this.template=new ActiveXObject(_SARISSA_XSLTEMPLATE_PROGID);
+this.processor=null
+};
+XSLTProcessor.prototype.importStylesheet=function(C){if(!_SARISSA_THREADEDDOM_PROGID){_SARISSA_THREADEDDOM_PROGID=Sarissa.pickRecentProgID(["MSXML2.FreeThreadedDOMDocument.6.0","MSXML2.FreeThreadedDOMDocument.3.0"])
+}C.setProperty("SelectionLanguage","XPath");
+C.setProperty("SelectionNamespaces","xmlns:xsl='http://www.w3.org/1999/XSL/Transform'");
+var B=new ActiveXObject(_SARISSA_THREADEDDOM_PROGID);
+if(C.url&&C.selectSingleNode("//xsl:*[local-name() = 'import' or local-name() = 'include']")!=null){B.async=false;
+if(_SARISSA_THREADEDDOM_PROGID=="MSXML2.FreeThreadedDOMDocument.6.0"){B.setProperty("AllowDocumentFunction",true);
+B.resolveExternals=true
+}B.load(C.url)
+}else{B.loadXML(C.xml)
+}B.setProperty("SelectionNamespaces","xmlns:xsl='http://www.w3.org/1999/XSL/Transform'");
+var A=B.selectSingleNode("//xsl:output");
+this.outputMethod=A?A.getAttribute("method"):"html";
+this.template.stylesheet=B;
+this.processor=this.template.createProcessor();
+this.paramsSet=new Array()
+};
+XSLTProcessor.prototype.transformToDocument=function(C){if(_SARISSA_THREADEDDOM_PROGID){this.processor.input=C;
+var B=new ActiveXObject(_SARISSA_DOM_PROGID);
+this.processor.output=B;
+this.processor.transform();
+return B
+}else{if(!_SARISSA_DOM_XMLWRITER){_SARISSA_DOM_XMLWRITER=Sarissa.pickRecentProgID(["Msxml2.MXXMLWriter.6.0","Msxml2.MXXMLWriter.3.0","MSXML2.MXXMLWriter","MSXML.MXXMLWriter","Microsoft.XMLDOM"])
+}this.processor.input=C;
+var B=new ActiveXObject(_SARISSA_DOM_XMLWRITER);
+this.processor.output=B;
+this.processor.transform();
+var A=new ActiveXObject(_SARISSA_DOM_PROGID);
+A.loadXML(B.output+"");
+return A
+}};
+XSLTProcessor.prototype.transformToFragment=function(G,D){this.processor.input=G;
+this.processor.transform();
+var E=this.processor.output;
+var F=D.createDocumentFragment();
+if(this.outputMethod=="text"){F.appendChild(D.createTextNode(E))
+}else{if(D.body&&D.body.innerHTML){var B=D.createElement("div");
+B.innerHTML=E;
+while(B.hasChildNodes()){F.appendChild(B.firstChild)
+}}else{var A=new ActiveXObject(_SARISSA_DOM_PROGID);
+if(E.substring(0,5)=="<?xml"){E=E.substring(E.indexOf("?>")+2)
+}var C="".concat("<my>",E,"</my>");
+A.loadXML(C);
+var B=A.documentElement;
+while(B.hasChildNodes()){F.appendChild(B.firstChild)
+}}}return F
+};
+XSLTProcessor.prototype.setParameter=function(C,A,B){B=B?B:"";
+if(C){this.processor.addParameter(A,B,C)
+}else{this.processor.addParameter(A,B)
+}if(!this.paramsSet[""+C]){this.paramsSet[""+C]=new Array()
+}this.paramsSet[""+C][A]=B
+};
+XSLTProcessor.prototype.getParameter=function(B,A){B=""+B;
+if(this.paramsSet[B]&&this.paramsSet[B][A]){return this.paramsSet[B][A]
+}else{return null
+}};
+XSLTProcessor.prototype.clearParameters=function(){for(var B in this.paramsSet){for(var A in this.paramsSet[B]){if(B){this.processor.addParameter(A,"",B)
+}else{this.processor.addParameter(A,"")
+}}}this.paramsSet=new Array()
+}
+}else{if(_SARISSA_HAS_DOM_CREATE_DOCUMENT){Sarissa.__handleLoad__=function(A){Sarissa.__setReadyState__(A,4)
+};
+_sarissa_XMLDocument_onload=function(){Sarissa.__handleLoad__(this)
+};
+Sarissa.__setReadyState__=function(A,B){A.readyState=B;
+A.readystate=B;
+if(A.onreadystatechange!=null&&typeof A.onreadystatechange=="function"){A.onreadystatechange()
+}};
+Sarissa.getDomDocument=function(C,B){var A=document.implementation.createDocument(C?C:null,B?B:null,null);
+if(!A.onreadystatechange){A.onreadystatechange=null
+}if(!A.readyState){A.readyState=0
+}A.addEventListener("load",_sarissa_XMLDocument_onload,false);
+return A
+};
+if(window.XMLDocument){}else{if(_SARISSA_HAS_DOM_FEATURE&&window.Document&&!Document.prototype.load&&document.implementation.hasFeature("LS","3.0")){Sarissa.getDomDocument=function(C,B){var A=document.implementation.createDocument(C?C:null,B?B:null,null);
+return A
+}
+}else{Sarissa.getDomDocument=function(C,B){var A=document.implementation.createDocument(C?C:null,B?B:null,null);
+if(A&&(C||B)&&!A.documentElement){A.appendChild(A.createElementNS(C,B))
+}return A
+}
+}}}}if(!window.DOMParser){if(_SARISSA_IS_SAFARI){DOMParser=function(){};
+DOMParser.prototype.parseFromString=function(B,C){var A=new XMLHttpRequest();
+A.open("GET","data:text/xml;charset=utf-8,"+encodeURIComponent(B),false);
+A.send(null);
+return A.responseXML
+}
+}else{if(Sarissa.getDomDocument&&Sarissa.getDomDocument()&&Sarissa.getDomDocument(null,"bar").xml){DOMParser=function(){};
+DOMParser.prototype.parseFromString=function(A,C){var B=Sarissa.getDomDocument();
+B.loadXML(A);
+return B
+}
+}}}if((typeof (document.importNode)=="undefined")&&_SARISSA_IS_IE){try{document.importNode=function(C,B){var A;
+if(C.nodeName=="#text"){return document.createTextElement(C.data)
+}else{if(C.nodeName=="tbody"||C.nodeName=="tr"){A=document.createElement("table")
+}else{if(C.nodeName=="td"){A=document.createElement("tr")
+}else{if(C.nodeName=="option"){A=document.createElement("select")
+}else{A=document.createElement("div")
+}}}if(B){A.innerHTML=C.xml?C.xml:C.outerHTML
+}else{A.innerHTML=C.xml?C.cloneNode(false).xml:C.cloneNode(false).outerHTML
+}return A.getElementsByTagName("*")[0]
+}}
+}catch(e){}}if(!Sarissa.getParseErrorText){Sarissa.getParseErrorText=function(A){var C=Sarissa.PARSED_OK;
+if(!A.documentElement){C=Sarissa.PARSED_EMPTY
+}else{if(A.documentElement.tagName=="parsererror"){C=A.documentElement.firstChild.data;
+C+="\n"+A.documentElement.firstChild.nextSibling.firstChild.data
+}else{if(A.getElementsByTagName("parsererror").length>0){var B=A.getElementsByTagName("parsererror")[0];
+C=Sarissa.getText(B,true)+"\n"
+}else{if(A.parseError&&A.parseError.errorCode!=0){C=Sarissa.PARSED_UNKNOWN_ERROR
+}}}}return C
+}
+}Sarissa.getText=function(G,B){var E="";
+var C=G.childNodes;
+for(var D=0;
+D<C.length;
+D++){var F=C[D];
+var A=F.nodeType;
+if(A==Node.TEXT_NODE||A==Node.CDATA_SECTION_NODE){E+=F.data
+}else{if(B==true&&(A==Node.ELEMENT_NODE||A==Node.DOCUMENT_NODE||A==Node.DOCUMENT_FRAGMENT_NODE)){E+=Sarissa.getText(F,true)
+}}}return E
+};
+if(!window.XMLSerializer&&Sarissa.getDomDocument&&Sarissa.getDomDocument("","foo",null).xml){XMLSerializer=function(){};
+XMLSerializer.prototype.serializeToString=function(A){return A.xml
+}
+}Sarissa.stripTags=function(A){return A.replace(/<[^>]+>/g,"")
+};
+Sarissa.clearChildNodes=function(A){while(A.firstChild){A.removeChild(A.firstChild)
+}};
+Sarissa.copyChildNodes=function(D,E,F){if((!D)||(!E)){throw"Both source and destination nodes must be provided"
+}if(!F){Sarissa.clearChildNodes(E)
+}var B=E.nodeType==Node.DOCUMENT_NODE?E:E.ownerDocument;
+var A=D.childNodes;
+if(typeof (B.importNode)!="undefined"){for(var C=0;
+C<A.length;
+C++){E.appendChild(B.importNode(A[C],true))
+}}else{for(var C=0;
+C<A.length;
+C++){E.appendChild(A[C].cloneNode(true))
+}}};
+Sarissa.moveChildNodes=function(D,E,F){if((!D)||(!E)){throw"Both source and destination nodes must be provided"
+}if(!F){Sarissa.clearChildNodes(E)
+}var A=D.childNodes;
+if(D.ownerDocument==E.ownerDocument){while(D.firstChild){E.appendChild(D.firstChild)
+}}else{var B=E.nodeType==Node.DOCUMENT_NODE?E:E.ownerDocument;
+if(typeof (B.importNode)!="undefined"){for(var C=0;
+C<A.length;
+C++){E.appendChild(B.importNode(A[C],true))
+}}else{for(var C=0;
+C<A.length;
+C++){E.appendChild(A[C].cloneNode(true))
+}}Sarissa.clearChildNodes(D)
+}};
+Sarissa.xmlize=function(E,H,D){D=D?D:"";
+var F=D+"<"+H+">";
+var B=false;
+if(!(E instanceof Object)||E instanceof Number||E instanceof String||E instanceof Boolean||E instanceof Date){F+=Sarissa.escape(""+E);
+B=true
+}else{F+="\n";
+var G="";
+var A=E instanceof Array;
+for(var C in E){F+=Sarissa.xmlize(E[C],(A?'array-item key="'+C+'"':C),D+"   ")
+}F+=D
+}return F+=(H.indexOf(" ")!=-1?"</array-item>\n":"</"+H+">\n")
+};
+Sarissa.escape=function(A){return A.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")
+};
+Sarissa.unescape=function(A){return A.replace(/&apos;/g,"'").replace(/&quot;/g,'"').replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/&amp;/g,"&")
+};
+A4J.AJAX={};
+A4J.AJAX.XMLHttpRequest=function(A){this._query=A;
+this._documentElement=window.document.documentElement
+};
+A4J.AJAX.XMLHttpRequest.prototype={_query:null,_timeout:0,_timeoutID:null,onready:null,_parsingStatus:Sarissa.PARSED_EMPTY,_errorMessage:"XML Response object not set",_contentType:null,_onerror:function(C,A,B){if(A!=599&&C.getResponseText()){A4J.AJAX.replacePage(C)
+}},onfinish:null,options:{},domEvt:null,form:null,_request:null,_aborted:false,_documentElement:null,setRequestTimeout:function(A){this._timeout=A
+},send:function(){this._request=new XMLHttpRequest();
+var C=this;
+this._request.onreadystatechange=function(){if(window.document.documentElement!=C._documentElement){LOG.warn("Page for current request have been unloaded - abort processing");
+C.abort();
+return 
+}if(C._aborted){return 
+}LOG.debug("Reqest state : "+C._request.readyState);
+if(C._request.readyState==4){LOG.debug("Reqest end with state 4");
+if(C._timeoutID){window.clearTimeout(C._timeoutID)
+}var F;
+var D;
+try{F=C._request.status;
+D=C._request.statusText
+}catch(E){LOG.error("request don't have status code - network problem, "+E.message);
+F=599;
+D="Network error"
+}if(F==200){try{LOG.debug("Response  with content-type: "+C.getResponseHeader("Content-Type"));
+LOG.debug("Full response content: ",C.getResponseText())
+}catch(E){}if(C._request.responseXML){C._parsingStatus=Sarissa.getParseErrorText(C._request.responseXML);
+if(C._parsingStatus==Sarissa.PARSED_OK&&Sarissa.setXpathNamespaces){Sarissa.setXpathNamespaces(C._request.responseXML,"xmlns='http://www.w3.org/1999/xhtml'")
+}}if(C.onready){C.onready(C)
+}}else{C._errorMessage="Reqest error, status : "+F+" "+D;
+LOG.error(C._errorMessage);
+if(typeof (C._onerror)=="function"){C._onerror(C,F,C._errorMessage)
+}}if(C.onfinish){C.onfinish(C)
+}C=undefined
+}};
+try{LOG.debug("Start XmlHttpRequest");
+this._request.open("POST",this._query.getActionUrl(""),true);
+var B="application/x-www-form-urlencoded; charset=UTF-8";
+this._request.setRequestHeader("Content-Type",B)
+}catch(A){LOG.debug("XmlHttpRequest not support setRequestHeader - use GET instead of POST");
+this._request.open("GET",this._query.getActionUrl("")+"?"+this._query.getQueryString(),true)
+}this._request.send(this._query.getQueryString());
+if(this._timeout>0){this._timeoutID=window.setTimeout(function(){LOG.warn("request stopped due to timeout");
+if(!C._aborted){A4J.AJAX.status(C.containerId,C.options.status,false);
+if(typeof (A4J.AJAX.onAbort)=="function"){A4J.AJAX.onAbort(C)
+}}C._aborted=true;
+C._request.abort();
+if(C._onerror){C._errorMessage="Request timeout";
+C._onerror(C,500,C._errorMessage)
+}if(C.onfinish){C.onfinish(C)
+}C._request=undefined;
+C=undefined
+},this._timeout)
+}},abort:function(){if(!this._aborted){A4J.AJAX.status(this.containerId,this.options.status,false);
+if(typeof (A4J.AJAX.onAbort)=="function"){A4J.AJAX.onAbort(this)
+}}this._aborted=true;
+if(this._request){try{if(this._timeoutID){window.clearTimeout(this._timeoutID)
+}}catch(A){LOG.warn("Exception for abort current request "+A.Message)
+}}},getResponseText:function(){try{return this._request.responseText
+}catch(A){return null
+}},getError:function(){return this._errorMessage
+},getParserStatus:function(){return this._parsingStatus
+},getContentType:function(){if(!this._contentType){var B=this.getResponseHeader("Content-Type");
+if(B){var A=B.indexOf(";");
+if(A>=0){this._contentType=B.substring(0,A)
+}else{this._contentType=B
+}}else{this._contentType="text/html"
+}}return this._contentType
+},getResponseHeader:function(B){var A;
+try{A=this._request.getResponseHeader(B);
+if(A===""){A=undefined
+}}catch(E){}if(!A){LOG.debug("Header "+B+" not found, search in <meta>");
+if(this._parsingStatus==Sarissa.PARSED_OK){var F=this.getElementsByTagName("meta");
+for(var C=0;
+C<F.length;
+C++){var D=F[C];
+LOG.debug("Find <meta name='"+D.getAttribute("name")+"' content='"+D.getAttribute("content")+"'>");
+if(D.getAttribute("name")==B){A=D.getAttribute("content");
+break
+}}}}return A
+},getElementsByTagName:function(A,C){if(!C){C=this._request.responseXML
+}LOG.debug("search for elements by name '"+A+"'  in element "+C.nodeName);
+var E;
+try{E=C.selectNodes('.//*[local-name()="'+A+'"]');
+LOG.debug("selectNodes found "+E.length)
+}catch(B){try{E=C.getElementsByTagName(A);
+LOG.debug("getElementsByTagName found "+E.length)
+}catch(D){LOG.debug("getElementsByTagName found no elements, "+D.Message)
+}}return E
+},getElementById:function(B){var A=this._request.responseXML;
+if(A){if(typeof (A.getElementById)!="undefined"){LOG.debug("call getElementById for id= "+B);
+return A.getElementById(B)
+}else{if(typeof (A.selectSingleNode)!="undefined"){LOG.debug("call selectSingleNode for id= "+B);
+return A.selectSingleNode("//*[@id='"+B+"']")
+}else{if(typeof (A.nodeFromID)!="undefined"){LOG.debug("call nodeFromID for id= "+B);
+return A.nodeFromID(B)
+}}}LOG.error("No functions for getElementById found ")
+}else{LOG.debug("No parsed XML document in response")
+}return null
+},getJSON:function(id){var data;
+var dataElement=this.getElementById(id);
+if(dataElement){try{data=Sarissa.getText(dataElement,true);
+data=window.eval("("+data+")")
+}catch(e){LOG.error("Error on parsing JSON data "+e.message,data)
+}}return data
+},evalScripts:function(node,isLast){var newscripts=this.getElementsByTagName("script",node);
+LOG.debug("Scripts in updated part count : "+newscripts.length);
+if(newscripts.length>0){var _this=this;
+window.setTimeout(function(){for(var i=0;
+i<newscripts.length;
+i++){var newscript=Sarissa.getText(newscripts[i],true);
+try{LOG.debug("Evaluate script replaced area in document: ",newscript);
+if(window.execScript){window.execScript(newscript)
+}else{window.eval(newscript)
+}}catch(e){LOG.error("ERROR Evaluate script:  Error name: "+e.name+e.message?". Error message: "+e.message:"")
+}}newscripts=null;
+if(isLast){if(_this.onfinish){_this.onfinish(_this);
+_this=undefined
+}}},50)
+}else{if(isLast){if(this.onfinish){this.onfinish(this)
+}}}},beforeUpdatePagePart:function(B){var A=window.document.getElementById(B);
+if(A){}},updatePagePart:function(G,D){var C=this.getElementById(G);
+if(!C){LOG.error("New node for ID "+G+" is not present in response");
+return 
+}var A=window.document.getElementById(G);
+if(A){if((typeof Event!="undefined")&&(typeof Event.unloadElementsCache=="function")){Event.unloadElementsCache(A)
+}var B=A.parentNode;
+if(!window.opera&&A.outerHTML&&!A.tagName.match(/(tbody|thead|tfoot|tr|th|td)/i)){LOG.debug("Replace content of node by outerHTML()");
+try{A.innerHTML=""
+}catch(F){LOG.error("Error to clear node content by innerHTML "+F.message);
+Sarissa.clearChildNodes(A)
+}A.outerHTML=new XMLSerializer().serializeToString(C)
+}else{var E;
+Sarissa.clearChildNodes(A);
+E=window.document.importNode(C,true);
+LOG.debug("Replace content of node by replaceChild()");
+B.replaceChild(E,A)
+}if(!A4J.AJAX._scriptEvaluated){this.evalScripts(C,D)
+}LOG.debug("Update part of page for Id: "+G+" successful")
+}else{LOG.warn("Node for replace by response with id "+G+" not found in document")
+}if(A4J.AJAX._scriptEvaluated&&D){if(this.onfinish){this.onfinish(this)
+}}},appendNewHeadElements:function(){this._appendNewElements("script","src",["type","language","charset"]);
+this._appendNewElements("link","href",["type","rel","rev","media"])
+},_appendNewElements:function(L,B,D){var K=this.getElementsByTagName(L);
+var H=document.getElementsByTagName(L);
+var J=document.getElementsByTagName("head")[0]||document.documentElement;
+for(var E=0;
+E<K.length;
+E++){var F=K[E];
+var A=F.getAttribute(B);
+if(A){var G=false;
+LOG.debug("<"+L+"> in response with src="+A);
+for(var C=0;
+C<H.length;
+C++){if(this._noSessionHref(A)==this._noSessionHref(H[C].getAttribute(B))){LOG.debug("Such element exist in document");
+G=true;
+break
+}}if(!G){var I=document.createElement(L);
+I.setAttribute(B,A);
+for(var C=0;
+C<D.length;
+C++){this._copyAttribute(F,I,D[C])
+}LOG.debug("append element to document");
+J.appendChild(I)
+}}}},_noSessionHref:function(A){var B=A;
+if(A){var C=A.lastIndexOf(";jsessionid=");
+if(C>0){B=A.substring(0,C);
+var D=A.lastIndexOf("?");
+if(D>C){B=B+A.substring(D)
+}}}return B
+},_copyAttribute:function(C,D,A){var B=C.getAttribute(A);
+if(B){D.setAttribute(A,B)
+}}};
+A4J.AJAX._eventsQueues={};
+A4J.AJAX.Listener=function(A){this.onafterajax=A
+};
+A4J.AJAX._listeners=[];
+A4J.AJAX.AddListener=function(A){A4J.AJAX._listeners.push(A)
+};
+A4J.AJAX.removeListeners=function(A){A4J.AJAX._listeners=[]
+};
+A4J.AJAX._pollers={};
+A4J.AJAX.Poll=function(A,C,B){A4J.AJAX.StopPoll(B.pollId);
+if(!B.onerror){B.onerror=function(F,D,E){if(typeof (A4J.AJAX.onError)=="function"){A4J.AJAX.onError(F,D,E)
+}A4J.AJAX.Poll(A,C,B)
+}
+}A4J.AJAX._pollers[B.pollId]=window.setTimeout(function(){A4J.AJAX._pollers[B.pollId]=undefined;
+if((typeof (B.onsubmit)=="function")&&(B.onsubmit()==false)){A4J.AJAX.Poll(A,C,B)
+}else{A4J.AJAX.SubmitRequest(A,C,null,B)
+}},B.pollinterval)
+};
+A4J.AJAX.StopPoll=function(A){if(A4J.AJAX._pollers[A]){window.clearTimeout(A4J.AJAX._pollers[A]);
+A4J.AJAX._pollers[A]=undefined
+}};
+A4J.AJAX.Push=function(A,C,B){A4J.AJAX.StopPush(B.pushId);
+B.onerror=function(){A4J.AJAX.Push(A,C,B)
+};
+A4J.AJAX._pollers[B.pushId]=window.setTimeout(function(){var D=new XMLHttpRequest();
+D.onreadystatechange=function(){if(D.readyState==4){try{if(D.status==200){A4J.AJAX.SubmitRequest(A,C||B.dummyForm,null,B)
+}}catch(E){}D=null;
+A4J.AJAX._pollers[B.pushId]=null;
+A4J.AJAX.Push(A,C,B)
+}};
+A4J.AJAX.SendPush(D,B)
+},B.pushinterval)
+};
+A4J.AJAX.SendPush=function(C,B){var A=B.pushUrl||B.actionUrl;
+C.open("HEAD",A,true);
+C.setRequestHeader("Ajax-Push-Key",B.pushId);
+if(B.timeout){C.setRequestHeader("Timeout",B.timeout)
+}C.send(null)
+};
+A4J.AJAX.StopPush=function(A){if(A4J.AJAX._pollers[A]){window.clearTimeout(A4J.AJAX._pollers[A]);
+A4J.AJAX._pollers[A]=null
+}};
+A4J.AJAX.CloneObject=function(C,B){var A={};
+for(var D in C){if(B&&typeof (evt[prop])=="function"){continue
+}A[D]=C[D]
+}return A
+};
+A4J.AJAX.SubmitForm=function(A,D,B){var C=A4J.AJAX.CloneObject(B);
+if(A4J._formInput){LOG.debug("Form submitted by button "+A4J._formInput.id);
+C.control=A4J._formInput;
+A4J._formInput=null;
+C.submitByForm=true
+}A4J.AJAX.Submit(A,D,null,C)
+};
+A4J.AJAX.Submit=function(E,A,H,I){var C;
+H=H||window.event||null;
+if(H){try{C=A4J.AJAX.CloneObject(H,false)
+}catch(G){LOG.warn("Exception on clone event "+G.name+":"+G.message)
+}LOG.debug("Have Event "+C+" with properties: target: "+C.target+", srcElement: "+C.srcElement+", type: "+C.type)
+}if(I.eventsQueue){var D=A4J.AJAX._eventsQueues[I.eventsQueue];
+if(D){var F=D.options.eventsCount||1;
+D.wait=true;
+D.containerId=E;
+D.form=A;
+D.domEvt=C;
+D.options=I;
+D.options.eventsCount=F+1;
+if(I.ignoreDupResponses&&D.request){LOG.debug("Abort uncompleted request in queue "+I.eventsQueue);
+D.request.abort();
+D.request=false;
+D.wait=false;
+if(I.requestDelay){window.setTimeout(function(){LOG.debug("End delay waiting, make request in queue "+I.eventsQueue);
+A4J.AJAX.SubmiteventsQueue(A4J.AJAX._eventsQueues[I.eventsQueue])
+},I.requestDelay);
+LOG.debug("Create new waiting for request in queue "+I.eventsQueue);
+return 
+}}else{LOG.debug("Put new event to queue "+I.eventsQueue);
+return 
+}}else{var B={wait:false,containerId:E,form:A,domEvt:C,options:I};
+A4J.AJAX._eventsQueues[I.eventsQueue]=B;
+if(I.requestDelay){window.setTimeout(function(){LOG.debug("End delay waiting, make request in queue "+I.eventsQueue);
+A4J.AJAX.SubmiteventsQueue(A4J.AJAX._eventsQueues[I.eventsQueue])
+},I.requestDelay);
+LOG.debug("Event occurs, create waiting for request in queue "+I.eventsQueue);
+return 
+}}}A4J.AJAX.SubmitRequest(E,A,C,I)
+};
+A4J.AJAX.SubmiteventsQueue=function(A){A.wait=false;
+A4J.AJAX.SubmitRequest(A.containerId,A.form,A.domEvt,A.options)
+};
+A4J.AJAX.SubmitRequest=function(E,H,D,I){LOG.debug("NEW AJAX REQUEST !!! with form :"+H);
+var A=window.document.getElementById(H);
+if((!A||A.nodeName.toUpperCase()!="FORM")&&D){var F=D.target||D.srcElement||null;
+if(F){A=A4J.AJAX.locateForm(F)
+}}if(!I.submitByForm&&A&&A.onsubmit){LOG.debug("Form have onsubmit function, call it");
+if(A.onsubmit()==false){return false
+}}var B=new A4J.Query(E,A);
+B.appendFormControls(I.single);
+if(I.control){B.appendControl(I.control,true)
+}if(I.parameters){B.appendParameters(I.parameters)
+}if(I.eventsCount){B.appendParameter("AJAX:EVENTS_COUNT",I.eventsCount)
+}if(I.actionUrl){B.setActionUrl(I.actionUrl)
+}var G=new A4J.AJAX.XMLHttpRequest(B);
+G.options=I;
+G.containerId=E;
+G.domEvt=D;
+G.form=A;
+if(I.timeout){G.setRequestTimeout(I.timeout)
+}G.onready=A4J.AJAX.processResponse;
+if(I.onerror){G._onerror=I.onerror
+}else{if(typeof (A4J.AJAX.onError)=="function"){G._onerror=A4J.AJAX.onError
+}}G.onfinish=A4J.AJAX.finishRequest;
+A4J.AJAX.status(E,I.status,true);
+G.send();
+if(I.eventsQueue){var C=A4J.AJAX._eventsQueues[I.eventsQueue];
+if(C){C.request=G
+}}return false
+};
+A4J.AJAX.processResponse=function(A){var E=A.options;
+var T=A.getResponseHeader("Ajax-Response");
+var R=A.getResponseHeader("Ajax-Expired");
+if(R&&typeof (A4J.AJAX.onExpired)=="function"){var I=A4J.AJAX.onExpired(window.location,R);
+if(I){window.location=I;
+return 
+}}if(T!="true"){LOG.warn("No ajax response header ");
+var I=A.getResponseHeader("Location");
+try{if(T=="redirect"&&I){window.location=I
+}else{if(T=="reload"){window.location.reload(true)
+}else{A4J.AJAX.replacePage(A)
+}}}catch(O){LOG.error("Error redirect to new location ")
+}}else{if(A.getParserStatus()==Sarissa.PARSED_OK){if(E.onbeforedomupdate){LOG.debug("Call request onbeforedomupdate function before replacing elemements");
+E.onbeforedomupdate(A,A.domEvt,A.getJSON("_ajax:data"))
+}var B=A.getResponseHeader("Ajax-Update-Ids");
+if(E.affected){A.appendNewHeadElements();
+for(var M=0;
+M<E.affected.length;
+M++){LOG.debug("Update page part from call parameter for ID "+E.affected[M]);
+A.updatePagePart(E.affected[M],M==G.length-1)
+}}else{if(B!=""){LOG.debug("Update page by list of rendered areas from response "+B);
+A.appendNewHeadElements();
+var G=B.split(",");
+for(var M=0;
+M<G.length;
+M++){var L=G[M];
+LOG.debug("Attempt to update part of page for Id: "+L);
+if(L){A.updatePagePart(L,M==G.length-1)
+}}}else{LOG.warn("No information in response about elements to replace")
+}}var Q=A.getElementById("ajax-view-state");
+LOG.debug("Hidden JSF state fields: "+Q);
+if(Q!=null){var J=E.parameters["org.ajax4jsf.portlet.NAMESPACE"];
+LOG.debug("Namespace for hidden view-state input fields is "+J);
+var H=J?window.document.getElementById(J):window.document;
+var C=H.getElementsByTagName("input");
+var N=A.getElementsByTagName("input",Q);
+A4J.AJAX.replaceViewState(C,N);
+N=A.getElementsByTagName("INPUT",Q);
+A4J.AJAX.replaceViewState(C,N)
+}for(var K=0;
+K<A4J.AJAX._listeners.length;
+K++){var F=A4J.AJAX._listeners[K];
+if(F.onafterajax){var S=A.getJSON("_ajax:data");
+F.onafterajax(A,A.domEvt,S)
+}}var P=A.getJSON("_A4J.AJAX.focus");
+if(P){LOG.debug("focus must be set to control "+P);
+var D=false;
+if(A.form){D=A.form.elements[P]
+}if(!D){LOG.debug("No control element "+P+" in submitted form");
+D=document.getElementById(P)
+}if(D){LOG.debug("Set focus to control ");
+D.focus()
+}else{LOG.warn("Element for set focus not found")
+}}else{LOG.debug("No focus information in response")
+}}else{LOG.error("Error parsing XML");
+LOG.error("Parse Error: "+A.getParserStatus())
+}}};
+A4J.AJAX.replacePage=function(B){if(!B.getResponseText()){LOG.warn("No content in response for replace current page");
+return 
+}LOG.debug("replace all page content with response");
+var A=_SARISSA_IS_IE;
+var C=window.document.open;
+if(A){LOG.debug("setup custom document.open method");
+window.document.open=function(){C.apply(this,arguments)
+}
+}window.setTimeout(function(){var E=false;
+try{window.document.open(B.getContentType(),true);
+LOG.debug("window.document has opened for writing");
+E=true;
+window.document.write(B.getResponseText());
+LOG.debug("window.document has been writed");
+window.document.close();
+LOG.debug("window.document has been closed for writing");
+if(A){window.location.reload(false)
+}}catch(I){LOG.debug("exception during write page content "+I.Message);
+if(E){window.document.close()
+}var H=(new DOMParser()).parseFromString(B.getResponseText(),"text/xml");
+if(Sarissa.getParseErrorText(H)==Sarissa.PARSED_OK){LOG.debug("response has parsed as DOM documnet.");
+Sarissa.clearChildNodes(window.document.documentElement);
+var D=H.documentElement.childNodes;
+for(var F=0;
+F<D.length;
+F++){if(D[F].nodeType==1){LOG.debug("append new node in document");
+var G=window.document.importNode(D[F],true);
+window.document.documentElement.appendChild(G)
+}}}else{LOG.error("Error parsing response",Sarissa.getParseErrorText(H))
+}}finally{window.document.open=C
+}LOG.debug("page content has been replaced")
+},30)
+};
+A4J.AJAX.replaceViewState=function(A,E){LOG.debug("Replace value for inputs: "+A.length+" by new values: "+E.length);
+if((E.length>0)&&(A.length>0)){for(var D=0;
+D<E.length;
+D++){var F=E[D];
+LOG.debug("Input in response: "+F.getAttribute("name"));
+for(var C=0;
+C<A.length;
+C++){var B=A[C];
+if(B.name==F.getAttribute("name")){LOG.debug("Found same input on page with type: "+B.type);
+B.value=F.getAttribute("value")
+}}}}};
+A4J.AJAX.finishRequest=function(request){var options=request.options;
+var oncomplete=request.getElementById("org.ajax4jsf.oncomplete");
+if(oncomplete){LOG.debug("Call request oncomplete function after processing updates");
+window.setTimeout(function(){var event=request.domEvt;
+var data=request.getJSON("_ajax:data");
+try{var newscript=Sarissa.getText(oncomplete,true);
+if(event){var target=event.target?event.target:event.srcElement;
+if(!window.data){window.data=data
+}else{Object.extend(window.data,data)
+}new Function(newscript).apply(target)
+}else{window.eval(newscript)
+}}catch(e){LOG.error("Error evaluate oncomplete function "+e.Message)
+}A4J.AJAX.status(request.containerId,options.status,false)
+},10)
+}else{if(options.oncomplete){LOG.debug("Call component oncomplete function after processing updates");
+window.setTimeout(function(){options.oncomplete(request,request.domEvt,request.getJSON("_ajax:data"));
+A4J.AJAX.status(request.containerId,options.status,false)
+},10)
+}else{A4J.AJAX.status(request.containerId,options.status,false)
+}}if(options.eventsQueue){var eventsQueue=A4J.AJAX._eventsQueues[options.eventsQueue];
+if(eventsQueue){A4J.AJAX._eventsQueues[options.eventsQueue]=false;
+if(eventsQueue.wait){LOG.debug("Queue not empty, execute next request in queue "+options.eventsQueue);
+A4J.AJAX.SubmiteventsQueue(eventsQueue)
+}}}};
+A4J.AJAX.getCursorPos=function(D){if(D.selectionEnd!=null){return D.selectionEnd
+}var C=document.selection.createRange();
+var B=C.compareEndPoints("StartToEnd",C)==0;
+if(!B){C.collapse(false)
+}var A=C.getBookmark();
+return A.charCodeAt(2)-2
+};
+A4J.AJAX.locateForm=function(B){var A=B;
+while(A&&A.nodeName.toLowerCase()!="form"){A=A.parentNode
+}return A
+};
+A4J.AJAX.getElementById=function(E,B){var D=B["org.ajax4jsf.portlet.NAMESPACE"];
+var A=D?window.document.getElementById(D):window.document;
+var C;
+if(A){C=A.getElementById(E)
+}else{LOG.error("No root element for portlet namespace "+D+" on page")
+}return C
+};
+A4J.AJAX._requestsCounts={};
+A4J.AJAX.status=function(D,A,E){try{var B;
+A=A||D+":status";
+A4J.AJAX._requestsCounts[A]=(A4J.AJAX._requestsCounts[A]||0)+(E?1:-1);
+if(A4J.AJAX._requestsCounts[A]>0){B=document.getElementById(A+".stop");
+if(B){B.style.display="none"
+}B=document.getElementById(A+".start");
+if(B){B.style.display="";
+if(typeof (B.onstart)=="function"){B.onstart()
+}}}else{B=document.getElementById(A+".start");
+if(B){B.style.display="none"
+}B=document.getElementById(A+".stop");
+if(B){B.style.display="";
+if(typeof (B.onstop)=="function"){B.onstop()
+}}}}catch(C){LOG.error("Exception on status change: ")
+}};
+A4J.Query=function(A,B){this._query={AJAXREQUEST:A};
+this._oldSubmit=null;
+this._form=B;
+this._actionUrl=(this._form.action)?this._form.action:this._form
+};
+A4J.Query.prototype={_form:null,_actionUrl:null,_ext:"",_query:{},_oldSubmit:null,_pageBase:window.location.protocol+"//"+window.location.host,hidden:function(A){this._value_query(A);
+if((A.name.length>4)&&(A.name.lastIndexOf("_idcl")==(A.name.length-5))){A.value=""
+}else{if((A.name.length>12)&&(A.name.lastIndexOf("_link_hidden_")==(A.name.length-13))){A.value=""
+}}},text:function(A){this._value_query(A)
+},textarea:function(A){this._value_query(A)
+},"select-one":function(A){if(A.selectedIndex!=-1){this._value_query(A)
+}},password:function(A){this._value_query(A)
+},file:function(A){this._value_query(A)
+},radio:function(A){this._check_query(A)
+},checkbox:function(A){this._check_query(A)
+},"select-multiple":function(F){var C=F.name;
+var E=F.childNodes;
+for(var D=0;
+D<E.length;
+D++){var G=E[D];
+if(G.tagName=="OPTGROUP"){var B=G.childNodes;
+for(var A=0;
+A<B.length;
+A++){this._addOption(C,B[A])
+}}else{this._addOption(C,G)
+}}},_addOption:function(A,B){if(B.selected){if(!this._query[A]){this._query[A]=[]
+}this._query[A][this._query[A].length]=B.value
+}},image:function(B,A){if(A){this._value_query(B)
+}},button:function(B,A){if(A){this._value_query(B)
+}},submit:function(B,A){if(A){this._value_query(B)
+}},link:function(B,A){if(A){this._value_query(B);
+if(B.parameters){this.appendParameters(B.parameters)
+}}},input:function(B,A){if(A){this.link(B,A);
+if(B.control){this.appendControl(B.control,A)
+}}},appendControl:function(B,A){if(this[B.type]){this[B.type](B,A)
+}else{this._appendById(B.id||B)
+}},appendFormControls:function(E){try{var C=this._form.elements;
+if(C){var B=0;
+for(B=0;
+B<C.length;
+B++){var D=C[B];
+try{if(!E||D.type=="hidden"){this.appendControl(D,false)
+}}catch(A){LOG.error("exception in building query ( append form control ) "+A)
+}}}}catch(F){LOG.warn("Error with append form controls to query "+F)
+}},appendParameters:function(A){for(k in A){if(typeof Object.prototype[k]=="undefined"){LOG.debug("parameter "+k+" with value "+A[k]);
+this.appendParameter(k,A[k])
+}}},setActionUrl:function(A){this._actionUrl=A
+},getActionUrl:function(A){var B=this._actionUrl;
+var C=B.indexOf("?");
+if(B.substring(0,1)=="/"){B=this._pageBase+B
+}if(!A){A=this._ext
+}if(C>=0){return B.substring(0,C)+A+B.substring(C)
+}else{return B+A
+}},getQueryString:function(){var A="";
+var D;
+for(var C in this._query){if(typeof Object.prototype[C]=="undefined"){D=this._query[C];
+if(D instanceof Object){for(var B=0;
+B<D.length;
+B++){A+=this._encode(C)+"="+this._encode(D[B])+"&"
+}}else{A+=this._encode(C)+"="+this._encode(D)+"&"
+}}}LOG.debug("QueryString: "+A);
+return A
+},_appendById:function(A){this.appendParameter(this._form.id+"_link_hidden_",A)
+},_value_query:function(A){LOG.debug("Append "+A.type+" control "+A.name+" with value ["+A.value+"] and value attribute ["+A.getAttribute("value")+"]");
+if(null!=A.value){this.appendParameter(A.name,A.value)
+}},_check_query:function(A){if(A.checked){this.appendParameter(A.name,A.value?A.value:"on")
+}},appendParameter:function(A,B){if(!this._query[A]){this._query[A]=B;
+return 
+}else{if(!(this._query[A] instanceof Object)){this._query[A]=[this._query[A]]
+}}this._query[A][this._query[A].length]=B
+},_encode:function(A){try{return encodeURIComponent(A)
+}catch(B){var C=escape(A);
+return C.split("+").join("%2B")
+}}};
+A4J.AJAX._scriptEvaluated=false;
+if(!document.all||window.opera){setTimeout(function(){try{var C=Sarissa.getDomDocument();
+var A=document.createElement("span");
+document.documentElement.appendChild(A);
+var F="<html xmlns='http://www.w3.org/1999/xhtml'><script>A4J.AJAX._scriptEvaluated=true;<\/script></html>";
+C=(new DOMParser()).parseFromString(F,"text/xml");
+var B=C.getElementsByTagName("script")[0];
+if(A.outerHTML){A.outerHTML=new XMLSerializer().serializeToString(B)
+}else{var E;
+E=window.document.importNode(B,true);
+document.documentElement.replaceChild(E,A)
+}}catch(D){}},50)
+}if(!window.LOG){window.LOG={}
+}LOG.Level=function(B,C,A){this.name=B;
+this.priority=C;
+if(A){this.color=A
+}};
+LOG.OFF=new LOG.Level("off",1000);
+LOG.FATAL=new LOG.Level("fatal",900,"red");
+LOG.ERROR=new LOG.Level("error",800,"red");
+LOG.WARN=new LOG.Level("warn",500,"yellow");
+LOG.INFO=new LOG.Level("info",400,"blue");
+LOG.DEBUG=new LOG.Level("debug",300,"darkblue");
+LOG.ALL=new LOG.Level("all",100);
+LOG.A4J_DEBUG=new LOG.Level("a4j_debug",0,"green");
+LOG.LEVEL=LOG.OFF;
+LOG._window=null;
+LOG.transmitToServer=true;
+LOG.consoleDivId="logConsole";
+LOG.styles={a4j_debug:"green",debug:"darkblue",info:"blue",warn:"yellow",error:"red",fatal:"red"};
+LOG.a4j_debug=function(B,A){LOG._log(B,LOG.A4J_DEBUG,A)
+};
+LOG.debug=function(B,A){LOG._log(B,LOG.DEBUG,A)
+};
+LOG.info=function(B,A){LOG._log(B,LOG.INFO,A)
+};
+LOG.warn=function(B,A){LOG._log(B,LOG.WARN,A)
+};
+LOG.error=function(B,A){LOG._log(B,LOG.ERROR,A)
+};
+LOG.fatal=function(B,A){LOG._log(B,LOG.FATAL,A)
+};
+LOG.registerPopup=function(B,C,E,A,F){if(!LOG._onkeydown){LOG._onkeydown=document.onkeydown
+}var D=B.toUpperCase();
+document.onkeydown=function(G){if(window.event){G=window.event
+}if(String.fromCharCode(G.keyCode)==D&G.shiftKey&G.ctrlKey){LOG.LEVEL=F;
+LOG.openWindow(C,"width="+E+",height="+A+",toolbar=no,scrollbars=yes,location=no,statusbar=no,menubar=no,resizable=yes,left = "+((screen.width-E)/2)+",top ="+((screen.height-A)/2))
+}else{if(LOG._onkeydown){LOG._onkeydown(G)
+}}}
+};
+LOG.openWindow=function(B,C){if(LOG._window){LOG._window.focus()
+}else{LOG._window=window.open("",B,C);
+var A=LOG;
+LOG._window.onunload=function(){A._window=null;
+A.LEVEL=A.OFF;
+A=undefined
+}
+}};
+LOG._log=function(C,A,B){if(A.priority>=LOG.LEVEL.priority){LOG._logToConsole(C,A,B);
+if(LOG.transmitToServer){LOG._logToServer(C,A)
+}}};
+LOG._time=function(){var D=new Date();
+var A=D.getHours();
+var C=D.getMinutes();
+if(C<10){C="0"+C
+}var E=D.getSeconds();
+if(E<10){E="0"+E
+}var B=D.getTime()%1000;
+if(B<100){B="0"+B
+}if(B<10){B="0"+B
+}return A+":"+C+":"+E+","+B
+};
+LOG._logToConsole=function(C,B,E){var F;
+var G;
+if(LOG._window&&LOG._window.document){G=LOG._window.document;
+F=LOG._window.document.body
+}else{G=window.document;
+F=window.document.getElementById(LOG.consoleDivId)
+}if(F){var H=G.createElement("span");
+H.style.color=B.color;
+H.appendChild(G.createTextNode(B.name+"["+LOG._time()+"]: "));
+var A=G.createElement("div");
+var I=G.createTextNode(C);
+A.appendChild(H);
+A.appendChild(I);
+if(E){var D=G.createElement("span");
+I=G.createTextNode(E);
+D.appendChild(I);
+A.appendChild(D)
+}F.appendChild(A)
+}else{}};
+LOG._logToServer=function(C,A){var B=A.name.substring(0,1)+C
+};
+LOG._requestCallBack=function(){}
+
+var Builder={NODEMAP:{AREA:"map",CAPTION:"table",COL:"table",COLGROUP:"table",LEGEND:"fieldset",OPTGROUP:"select",OPTION:"select",PARAM:"object",TBODY:"table",TD:"table",TFOOT:"table",TH:"table",THEAD:"table",TR:"table"},node:function(A){A=A.toUpperCase();
+var F=this.NODEMAP[A]||"div";
+var B=document.createElement(F);
+try{B.innerHTML="<"+A+"></"+A+">"
+}catch(E){}var D=B.firstChild||null;
+if(D&&(D.tagName.toUpperCase()!=A)){D=D.getElementsByTagName(A)[0]
+}if(!D){D=document.createElement(A)
+}if(!D){return 
+}if(arguments[1]){if(this._isStringOrNumber(arguments[1])||(arguments[1] instanceof Array)||arguments[1].tagName){this._children(D,arguments[1])
+}else{var C=this._attributes(arguments[1]);
+if(C.length){try{B.innerHTML="<"+A+" "+C+"></"+A+">"
+}catch(E){}D=B.firstChild||null;
+if(!D){D=document.createElement(A);
+for(attr in arguments[1]){D[attr=="class"?"className":attr]=arguments[1][attr]
+}}if(D.tagName.toUpperCase()!=A){D=B.getElementsByTagName(A)[0]
+}}}}if(arguments[2]){this._children(D,arguments[2])
+}return D
+},_text:function(A){return document.createTextNode(A)
+},ATTR_MAP:{"className":"class","htmlFor":"for"},_attributes:function(A){var B=[];
+for(attribute in A){B.push((attribute in this.ATTR_MAP?this.ATTR_MAP[attribute]:attribute)+'="'+A[attribute].toString().escapeHTML().gsub(/"/,"&quot;")+'"')
+}return B.join(" ")
+},_children:function(B,A){if(A.tagName){B.appendChild(A);
+return 
+}if(typeof A=="object"){A.flatten().each(function(C){if(typeof C=="object"){B.appendChild(C)
+}else{if(Builder._isStringOrNumber(C)){B.appendChild(Builder._text(C))
+}}})
+}else{if(Builder._isStringOrNumber(A)){B.appendChild(Builder._text(A))
+}}},_isStringOrNumber:function(A){return(typeof A=="string"||typeof A=="number")
+},build:function(B){var A=this.node("div");
+$(A).update(B.strip());
+return A.down()
+},dump:function(B){if(typeof B!="object"&&typeof B!="function"){B=window
+}var A=("A ABBR ACRONYM ADDRESS APPLET AREA B BASE BASEFONT BDO BIG BLOCKQUOTE BODY BR BUTTON CAPTION CENTER CITE CODE COL COLGROUP DD DEL DFN DIR DIV DL DT EM FIELDSET FONT FORM FRAME FRAMESET H1 H2 H3 H4 H5 H6 HEAD HR HTML I IFRAME IMG INPUT INS ISINDEX KBD LABEL LEGEND LI LINK MAP MENU META NOFRAMES NOSCRIPT OBJECT OL OPTGROUP OPTION P PARAM PRE Q S SAMP SCRIPT SELECT SMALL SPAN STRIKE STRONG STYLE SUB SUP TABLE TBODY TD TEXTAREA TFOOT TH THEAD TITLE TR TT U UL VAR").split(/\s+/);
+A.each(function(C){B[C]=function(){return Builder.node.apply(Builder,[C].concat($A(arguments)))
+}
+})
+}};
+String.prototype.parseColor=function(){var A="#";
+if(this.slice(0,4)=="rgb("){var C=this.slice(4,this.length-1).split(",");
+var B=0;
+do{A+=parseInt(C[B]).toColorPart()
+}while(++B<3)
+}else{if(this.slice(0,1)=="#"){if(this.length==4){for(var B=1;
+B<4;
+B++){A+=(this.charAt(B)+this.charAt(B)).toLowerCase()
+}}if(this.length==7){A=this.toLowerCase()
+}}}return(A.length==7?A:(arguments[0]||this))
+};
+Element.collectTextNodes=function(A){return $A($(A).childNodes).collect(function(B){return(B.nodeType==3?B.nodeValue:(B.hasChildNodes()?Element.collectTextNodes(B):""))
+}).flatten().join("")
+};
+Element.collectTextNodesIgnoreClass=function(A,B){return $A($(A).childNodes).collect(function(C){return(C.nodeType==3?C.nodeValue:((C.hasChildNodes()&&!Element.hasClassName(C,B))?Element.collectTextNodesIgnoreClass(C,B):""))
+}).flatten().join("")
+};
+Element.setContentZoom=function(A,B){A=$(A);
+A.setStyle({fontSize:(B/100)+"em"});
+if(Prototype.Browser.WebKit){window.scrollBy(0,0)
+}return A
+};
+Element.getInlineOpacity=function(A){return $(A).style.opacity||""
+};
+Element.forceRerendering=function(A){try{A=$(A);
+var C=document.createTextNode(" ");
+A.appendChild(C);
+A.removeChild(C)
+}catch(B){}};
+var Effect={_elementDoesNotExistError:{name:"ElementDoesNotExistError",message:"The specified DOM element does not exist, but is required for this effect to operate"},Transitions:{linear:Prototype.K,sinoidal:function(A){return(-Math.cos(A*Math.PI)/2)+0.5
+},reverse:function(A){return 1-A
+},flicker:function(A){var A=((-Math.cos(A*Math.PI)/4)+0.75)+Math.random()/4;
+return A>1?1:A
+},wobble:function(A){return(-Math.cos(A*Math.PI*(9*A))/2)+0.5
+},pulse:function(B,A){A=A||5;
+return(((B%(1/A))*A).round()==0?((B*A*2)-(B*A*2).floor()):1-((B*A*2)-(B*A*2).floor()))
+},spring:function(A){return 1-(Math.cos(A*4.5*Math.PI)*Math.exp(-A*6))
+},none:function(A){return 0
+},full:function(A){return 1
+}},DefaultOptions:{duration:1,fps:100,sync:false,from:0,to:1,delay:0,queue:"parallel"},tagifyText:function(A){var B="position:relative";
+if(Prototype.Browser.IE){B+=";zoom:1"
+}A=$(A);
+$A(A.childNodes).each(function(C){if(C.nodeType==3){C.nodeValue.toArray().each(function(D){A.insertBefore(new Element("span",{style:B}).update(D==" "?String.fromCharCode(160):D),C)
+});
+Element.remove(C)
+}})
+},multiple:function(B,C){var E;
+if(((typeof B=="object")||Object.isFunction(B))&&(B.length)){E=B
+}else{E=$(B).childNodes
+}var A=Object.extend({speed:0.1,delay:0},arguments[2]||{});
+var D=A.delay;
+$A(E).each(function(G,F){new C(G,Object.extend(A,{delay:F*A.speed+D}))
+})
+},PAIRS:{"slide":["SlideDown","SlideUp"],"blind":["BlindDown","BlindUp"],"appear":["Appear","Fade"]},toggle:function(B,C){B=$(B);
+C=(C||"appear").toLowerCase();
+var A=Object.extend({queue:{position:"end",scope:(B.id||"global"),limit:1}},arguments[2]||{});
+Effect[B.visible()?Effect.PAIRS[C][1]:Effect.PAIRS[C][0]](B,A)
+}};
+Effect.DefaultOptions.transition=Effect.Transitions.sinoidal;
+Effect.ScopedQueue=Class.create(Enumerable,{initialize:function(){this.effects=[];
+this.interval=null
+},_each:function(A){this.effects._each(A)
+},add:function(B){var C=new Date().getTime();
+var A=Object.isString(B.options.queue)?B.options.queue:B.options.queue.position;
+switch(A){case"front":this.effects.findAll(function(D){return D.state=="idle"
+}).each(function(D){D.startOn+=B.finishOn;
+D.finishOn+=B.finishOn
+});
+break;
+case"with-last":C=this.effects.pluck("startOn").max()||C;
+break;
+case"end":C=this.effects.pluck("finishOn").max()||C;
+break
+}B.startOn+=C;
+B.finishOn+=C;
+if(!B.options.queue.limit||(this.effects.length<B.options.queue.limit)){this.effects.push(B)
+}if(!this.interval){this.interval=setInterval(this.loop.bind(this),15)
+}},remove:function(A){this.effects=this.effects.reject(function(B){return B==A
+});
+if(this.effects.length==0){clearInterval(this.interval);
+this.interval=null
+}},loop:function(){var C=new Date().getTime();
+for(var B=0,A=this.effects.length;
+B<A;
+B++){this.effects[B]&&this.effects[B].loop(C)
+}}});
+Effect.Queues={instances:$H(),get:function(A){if(!Object.isString(A)){return A
+}return this.instances.get(A)||this.instances.set(A,new Effect.ScopedQueue())
+}};
+Effect.Queue=Effect.Queues.get("global");
+Effect.Base=Class.create({position:null,start:function(options){function codeForEvent(options,eventName){return((options[eventName+"Internal"]?"this.options."+eventName+"Internal(this);":"")+(options[eventName]?"this.options."+eventName+"(this);":""))
+}if(options&&options.transition===false){options.transition=Effect.Transitions.linear
+}this.options=Object.extend(Object.extend({},Effect.DefaultOptions),options||{});
+this.currentFrame=0;
+this.state="idle";
+this.startOn=this.options.delay*1000;
+this.finishOn=this.startOn+(this.options.duration*1000);
+this.fromToDelta=this.options.to-this.options.from;
+this.totalTime=this.finishOn-this.startOn;
+this.totalFrames=this.options.fps*this.options.duration;
+eval('this.render = function(pos){ if (this.state=="idle"){this.state="running";'+codeForEvent(this.options,"beforeSetup")+(this.setup?"this.setup();":"")+codeForEvent(this.options,"afterSetup")+'};if (this.state=="running"){pos=this.options.transition(pos)*'+this.fromToDelta+"+"+this.options.from+";this.position=pos;"+codeForEvent(this.options,"beforeUpdate")+(this.update?"this.update(pos);":"")+codeForEvent(this.options,"afterUpdate")+"}}");
+this.event("beforeStart");
+if(!this.options.sync){Effect.Queues.get(Object.isString(this.options.queue)?"global":this.options.queue.scope).add(this)
+}},loop:function(C){if(C>=this.startOn){if(C>=this.finishOn){this.render(1);
+this.cancel();
+this.event("beforeFinish");
+if(this.finish){this.finish()
+}this.event("afterFinish");
+return 
+}var B=(C-this.startOn)/this.totalTime,A=(B*this.totalFrames).round();
+if(A>this.currentFrame){this.render(B);
+this.currentFrame=A
+}}},cancel:function(){if(!this.options.sync){Effect.Queues.get(Object.isString(this.options.queue)?"global":this.options.queue.scope).remove(this)
+}this.state="finished"
+},event:function(A){if(this.options[A+"Internal"]){this.options[A+"Internal"](this)
+}if(this.options[A]){this.options[A](this)
+}},inspect:function(){var A=$H();
+for(property in this){if(!Object.isFunction(this[property])){A.set(property,this[property])
+}}return"#<Effect:"+A.inspect()+",options:"+$H(this.options).inspect()+">"
+}});
+Effect.Parallel=Class.create(Effect.Base,{initialize:function(A){this.effects=A||[];
+this.start(arguments[1])
+},update:function(A){this.effects.invoke("render",A)
+},finish:function(A){this.effects.each(function(B){B.render(1);
+B.cancel();
+B.event("beforeFinish");
+if(B.finish){B.finish(A)
+}B.event("afterFinish")
+})
+}});
+Effect.Tween=Class.create(Effect.Base,{initialize:function(C,F,E){C=Object.isString(C)?$(C):C;
+var B=$A(arguments),D=B.last(),A=B.length==5?B[3]:null;
+this.method=Object.isFunction(D)?D.bind(C):Object.isFunction(C[D])?C[D].bind(C):function(G){C[D]=G
+};
+this.start(Object.extend({from:F,to:E},A||{}))
+},update:function(A){this.method(A)
+}});
+Effect.Event=Class.create(Effect.Base,{initialize:function(){this.start(Object.extend({duration:0},arguments[0]||{}))
+},update:Prototype.emptyFunction});
+Effect.Opacity=Class.create(Effect.Base,{initialize:function(B){this.element=$(B);
+if(!this.element){throw (Effect._elementDoesNotExistError)
+}if(Prototype.Browser.IE&&(!this.element.currentStyle.hasLayout)){this.element.setStyle({zoom:1})
+}var A=Object.extend({from:this.element.getOpacity()||0,to:1},arguments[1]||{});
+this.start(A)
+},update:function(A){this.element.setOpacity(A)
+}});
+Effect.Move=Class.create(Effect.Base,{initialize:function(B){this.element=$(B);
+if(!this.element){throw (Effect._elementDoesNotExistError)
+}var A=Object.extend({x:0,y:0,mode:"relative"},arguments[1]||{});
+this.start(A)
+},setup:function(){this.element.makePositioned();
+this.originalLeft=parseFloat(this.element.getStyle("left")||"0");
+this.originalTop=parseFloat(this.element.getStyle("top")||"0");
+if(this.options.mode=="absolute"){this.options.x=this.options.x-this.originalLeft;
+this.options.y=this.options.y-this.originalTop
+}},update:function(A){this.element.setStyle({left:(this.options.x*A+this.originalLeft).round()+"px",top:(this.options.y*A+this.originalTop).round()+"px"})
+}});
+Effect.MoveBy=function(B,A,C){return new Effect.Move(B,Object.extend({x:C,y:A},arguments[3]||{}))
+};
+Effect.Scale=Class.create(Effect.Base,{initialize:function(B,C){this.element=$(B);
+if(!this.element){throw (Effect._elementDoesNotExistError)
+}var A=Object.extend({scaleX:true,scaleY:true,scaleContent:true,scaleFromCenter:false,scaleMode:"box",scaleFrom:100,scaleTo:C},arguments[2]||{});
+this.start(A)
+},setup:function(){this.restoreAfterFinish=this.options.restoreAfterFinish||false;
+this.elementPositioning=this.element.getStyle("position");
+this.originalStyle={};
+["top","left","width","height","fontSize"].each(function(B){this.originalStyle[B]=this.element.style[B]
+}.bind(this));
+this.originalTop=this.element.offsetTop;
+this.originalLeft=this.element.offsetLeft;
+var A=this.element.getStyle("font-size")||"100%";
+["em","px","%","pt"].each(function(B){if(A.indexOf(B)>0){this.fontSize=parseFloat(A);
+this.fontSizeType=B
+}}.bind(this));
+this.factor=(this.options.scaleTo-this.options.scaleFrom)/100;
+this.dims=null;
+if(this.options.scaleMode=="box"){this.dims=[this.element.offsetHeight,this.element.offsetWidth]
+}if(/^content/.test(this.options.scaleMode)){this.dims=[this.element.scrollHeight,this.element.scrollWidth]
+}if(!this.dims){this.dims=[this.options.scaleMode.originalHeight,this.options.scaleMode.originalWidth]
+}},update:function(A){var B=(this.options.scaleFrom/100)+(this.factor*A);
+if(this.options.scaleContent&&this.fontSize){this.element.setStyle({fontSize:this.fontSize*B+this.fontSizeType})
+}this.setDimensions(this.dims[0]*B,this.dims[1]*B)
+},finish:function(A){if(this.restoreAfterFinish){this.element.setStyle(this.originalStyle)
+}},setDimensions:function(A,D){var E={};
+if(this.options.scaleX){E.width=D.round()+"px"
+}if(this.options.scaleY){E.height=A.round()+"px"
+}if(this.options.scaleFromCenter){var C=(A-this.dims[0])/2;
+var B=(D-this.dims[1])/2;
+if(this.elementPositioning=="absolute"){if(this.options.scaleY){E.top=this.originalTop-C+"px"
+}if(this.options.scaleX){E.left=this.originalLeft-B+"px"
+}}else{if(this.options.scaleY){E.top=-C+"px"
+}if(this.options.scaleX){E.left=-B+"px"
+}}}this.element.setStyle(E)
+}});
+Effect.Highlight=Class.create(Effect.Base,{initialize:function(B){this.element=$(B);
+if(!this.element){throw (Effect._elementDoesNotExistError)
+}var A=Object.extend({startcolor:"#ffff99"},arguments[1]||{});
+this.start(A)
+},setup:function(){if(this.element.getStyle("display")=="none"){this.cancel();
+return 
+}this.oldStyle={};
+if(!this.options.keepBackgroundImage){this.oldStyle.backgroundImage=this.element.getStyle("background-image");
+this.element.setStyle({backgroundImage:"none"})
+}if(!this.options.endcolor){this.options.endcolor=this.element.getStyle("background-color").parseColor("#ffffff")
+}if(!this.options.restorecolor){this.options.restorecolor=this.element.getStyle("background-color")
+}this._base=$R(0,2).map(function(A){return parseInt(this.options.startcolor.slice(A*2+1,A*2+3),16)
+}.bind(this));
+this._delta=$R(0,2).map(function(A){return parseInt(this.options.endcolor.slice(A*2+1,A*2+3),16)-this._base[A]
+}.bind(this))
+},update:function(A){this.element.setStyle({backgroundColor:$R(0,2).inject("#",function(B,C,D){return B+((this._base[D]+(this._delta[D]*A)).round().toColorPart())
+}.bind(this))})
+},finish:function(){this.element.setStyle(Object.extend(this.oldStyle,{backgroundColor:this.options.restorecolor}))
+}});
+Effect.ScrollTo=function(D){var C=arguments[1]||{},B=document.viewport.getScrollOffsets(),E=$(D).cumulativeOffset(),A=(window.height||document.body.scrollHeight)-document.viewport.getHeight();
+if(C.offset){E[1]+=C.offset
+}return new Effect.Tween(null,B.top,E[1]>A?A:E[1],C,function(F){scrollTo(B.left,F.round())
+})
+};
+Effect.Fade=function(C){C=$(C);
+var A=C.getInlineOpacity();
+var B=Object.extend({from:C.getOpacity()||1,to:0,afterFinishInternal:function(D){if(D.options.to!=0){return 
+}D.element.hide().setStyle({opacity:A})
+}},arguments[1]||{});
+return new Effect.Opacity(C,B)
+};
+Effect.Appear=function(B){B=$(B);
+var A=Object.extend({from:(B.getStyle("display")=="none"?0:B.getOpacity()||0),to:1,afterFinishInternal:function(C){C.element.forceRerendering()
+},beforeSetup:function(C){C.element.setOpacity(C.options.from).show()
+}},arguments[1]||{});
+return new Effect.Opacity(B,A)
+};
+Effect.Puff=function(B){B=$(B);
+var A={opacity:B.getInlineOpacity(),position:B.getStyle("position"),top:B.style.top,left:B.style.left,width:B.style.width,height:B.style.height};
+return new Effect.Parallel([new Effect.Scale(B,200,{sync:true,scaleFromCenter:true,scaleContent:true,restoreAfterFinish:true}),new Effect.Opacity(B,{sync:true,to:0})],Object.extend({duration:1,beforeSetupInternal:function(C){Position.absolutize(C.effects[0].element)
+},afterFinishInternal:function(C){C.effects[0].element.hide().setStyle(A)
+}},arguments[1]||{}))
+};
+Effect.BlindUp=function(A){A=$(A);
+A.makeClipping();
+return new Effect.Scale(A,0,Object.extend({scaleContent:false,scaleX:false,restoreAfterFinish:true,afterFinishInternal:function(B){B.element.hide().undoClipping()
+}},arguments[1]||{}))
+};
+Effect.BlindDown=function(B){B=$(B);
+var A=B.getDimensions();
+return new Effect.Scale(B,100,Object.extend({scaleContent:false,scaleX:false,scaleFrom:0,scaleMode:{originalHeight:A.height,originalWidth:A.width},restoreAfterFinish:true,afterSetup:function(C){C.element.makeClipping().setStyle({height:"0px"}).show()
+},afterFinishInternal:function(C){C.element.undoClipping()
+}},arguments[1]||{}))
+};
+Effect.SwitchOff=function(B){B=$(B);
+var A=B.getInlineOpacity();
+return new Effect.Appear(B,Object.extend({duration:0.4,from:0,transition:Effect.Transitions.flicker,afterFinishInternal:function(C){new Effect.Scale(C.element,1,{duration:0.3,scaleFromCenter:true,scaleX:false,scaleContent:false,restoreAfterFinish:true,beforeSetup:function(D){D.element.makePositioned().makeClipping()
+},afterFinishInternal:function(D){D.element.hide().undoClipping().undoPositioned().setStyle({opacity:A})
+}})
+}},arguments[1]||{}))
+};
+Effect.DropOut=function(B){B=$(B);
+var A={top:B.getStyle("top"),left:B.getStyle("left"),opacity:B.getInlineOpacity()};
+return new Effect.Parallel([new Effect.Move(B,{x:0,y:100,sync:true}),new Effect.Opacity(B,{sync:true,to:0})],Object.extend({duration:0.5,beforeSetup:function(C){C.effects[0].element.makePositioned()
+},afterFinishInternal:function(C){C.effects[0].element.hide().undoPositioned().setStyle(A)
+}},arguments[1]||{}))
+};
+Effect.Shake=function(D){D=$(D);
+var B=Object.extend({distance:20,duration:0.5},arguments[1]||{});
+var E=parseFloat(B.distance);
+var C=parseFloat(B.duration)/10;
+var A={top:D.getStyle("top"),left:D.getStyle("left")};
+return new Effect.Move(D,{x:E,y:0,duration:C,afterFinishInternal:function(F){new Effect.Move(F.element,{x:-E*2,y:0,duration:C*2,afterFinishInternal:function(G){new Effect.Move(G.element,{x:E*2,y:0,duration:C*2,afterFinishInternal:function(H){new Effect.Move(H.element,{x:-E*2,y:0,duration:C*2,afterFinishInternal:function(I){new Effect.Move(I.element,{x:E*2,y:0,duration:C*2,afterFinishInternal:function(J){new Effect.Move(J.element,{x:-E,y:0,duration:C,afterFinishInternal:function(K){K.element.undoPositioned().setStyle(A)
+}})
+}})
+}})
+}})
+}})
+}})
+};
+Effect.SlideDown=function(C){C=$(C).cleanWhitespace();
+var A=C.down().getStyle("bottom");
+var B=C.getDimensions();
+return new Effect.Scale(C,100,Object.extend({scaleContent:false,scaleX:false,scaleFrom:window.opera?0:1,scaleMode:{originalHeight:B.height,originalWidth:B.width},restoreAfterFinish:true,afterSetup:function(D){D.element.makePositioned();
+D.element.down().makePositioned();
+if(window.opera){D.element.setStyle({top:""})
+}D.element.makeClipping().setStyle({height:"0px"}).show()
+},afterUpdateInternal:function(D){D.element.down().setStyle({bottom:(D.dims[0]-D.element.clientHeight)+"px"})
+},afterFinishInternal:function(D){D.element.undoClipping().undoPositioned();
+D.element.down().undoPositioned().setStyle({bottom:A})
+}},arguments[1]||{}))
+};
+Effect.SlideUp=function(C){C=$(C).cleanWhitespace();
+var A=C.down().getStyle("bottom");
+var B=C.getDimensions();
+return new Effect.Scale(C,window.opera?0:1,Object.extend({scaleContent:false,scaleX:false,scaleMode:"box",scaleFrom:100,scaleMode:{originalHeight:B.height,originalWidth:B.width},restoreAfterFinish:true,afterSetup:function(D){D.element.makePositioned();
+D.element.down().makePositioned();
+if(window.opera){D.element.setStyle({top:""})
+}D.element.makeClipping().show()
+},afterUpdateInternal:function(D){D.element.down().setStyle({bottom:(D.dims[0]-D.element.clientHeight)+"px"})
+},afterFinishInternal:function(D){D.element.hide().undoClipping().undoPositioned();
+D.element.down().undoPositioned().setStyle({bottom:A})
+}},arguments[1]||{}))
+};
+Effect.Squish=function(A){return new Effect.Scale(A,window.opera?1:0,{restoreAfterFinish:true,beforeSetup:function(B){B.element.makeClipping()
+},afterFinishInternal:function(B){B.element.hide().undoClipping()
+}})
+};
+Effect.Grow=function(C){C=$(C);
+var B=Object.extend({direction:"center",moveTransition:Effect.Transitions.sinoidal,scaleTransition:Effect.Transitions.sinoidal,opacityTransition:Effect.Transitions.full},arguments[1]||{});
+var A={top:C.style.top,left:C.style.left,height:C.style.height,width:C.style.width,opacity:C.getInlineOpacity()};
+var G=C.getDimensions();
+var H,F;
+var E,D;
+switch(B.direction){case"top-left":H=F=E=D=0;
+break;
+case"top-right":H=G.width;
+F=D=0;
+E=-G.width;
+break;
+case"bottom-left":H=E=0;
+F=G.height;
+D=-G.height;
+break;
+case"bottom-right":H=G.width;
+F=G.height;
+E=-G.width;
+D=-G.height;
+break;
+case"center":H=G.width/2;
+F=G.height/2;
+E=-G.width/2;
+D=-G.height/2;
+break
+}return new Effect.Move(C,{x:H,y:F,duration:0.01,beforeSetup:function(I){I.element.hide().makeClipping().makePositioned()
+},afterFinishInternal:function(I){new Effect.Parallel([new Effect.Opacity(I.element,{sync:true,to:1,from:0,transition:B.opacityTransition}),new Effect.Move(I.element,{x:E,y:D,sync:true,transition:B.moveTransition}),new Effect.Scale(I.element,100,{scaleMode:{originalHeight:G.height,originalWidth:G.width},sync:true,scaleFrom:window.opera?1:0,transition:B.scaleTransition,restoreAfterFinish:true})],Object.extend({beforeSetup:function(J){J.effects[0].element.setStyle({height:"0px"}).show()
+},afterFinishInternal:function(J){J.effects[0].element.undoClipping().undoPositioned().setStyle(A)
+}},B))
+}})
+};
+Effect.Shrink=function(C){C=$(C);
+var B=Object.extend({direction:"center",moveTransition:Effect.Transitions.sinoidal,scaleTransition:Effect.Transitions.sinoidal,opacityTransition:Effect.Transitions.none},arguments[1]||{});
+var A={top:C.style.top,left:C.style.left,height:C.style.height,width:C.style.width,opacity:C.getInlineOpacity()};
+var F=C.getDimensions();
+var E,D;
+switch(B.direction){case"top-left":E=D=0;
+break;
+case"top-right":E=F.width;
+D=0;
+break;
+case"bottom-left":E=0;
+D=F.height;
+break;
+case"bottom-right":E=F.width;
+D=F.height;
+break;
+case"center":E=F.width/2;
+D=F.height/2;
+break
+}return new Effect.Parallel([new Effect.Opacity(C,{sync:true,to:0,from:1,transition:B.opacityTransition}),new Effect.Scale(C,window.opera?1:0,{sync:true,transition:B.scaleTransition,restoreAfterFinish:true}),new Effect.Move(C,{x:E,y:D,sync:true,transition:B.moveTransition})],Object.extend({beforeStartInternal:function(G){G.effects[0].element.makePositioned().makeClipping()
+},afterFinishInternal:function(G){G.effects[0].element.hide().undoClipping().undoPositioned().setStyle(A)
+}},B))
+};
+Effect.Pulsate=function(C){C=$(C);
+var B=arguments[1]||{};
+var A=C.getInlineOpacity();
+var E=B.transition||Effect.Transitions.sinoidal;
+var D=function(F){return E(1-Effect.Transitions.pulse(F,B.pulses))
+};
+D.bind(E);
+return new Effect.Opacity(C,Object.extend(Object.extend({duration:2,from:0,afterFinishInternal:function(F){F.element.setStyle({opacity:A})
+}},B),{transition:D}))
+};
+Effect.Fold=function(B){B=$(B);
+var A={top:B.style.top,left:B.style.left,width:B.style.width,height:B.style.height};
+B.makeClipping();
+return new Effect.Scale(B,5,Object.extend({scaleContent:false,scaleX:false,afterFinishInternal:function(C){new Effect.Scale(B,1,{scaleContent:false,scaleY:false,afterFinishInternal:function(D){D.element.hide().undoClipping().setStyle(A)
+}})
+}},arguments[1]||{}))
+};
+Effect.Morph=Class.create(Effect.Base,{initialize:function(C){this.element=$(C);
+if(!this.element){throw (Effect._elementDoesNotExistError)
+}var A=Object.extend({style:{}},arguments[1]||{});
+if(!Object.isString(A.style)){this.style=$H(A.style)
+}else{if(A.style.include(":")){this.style=A.style.parseStyle()
+}else{this.element.addClassName(A.style);
+this.style=$H(this.element.getStyles());
+this.element.removeClassName(A.style);
+var B=this.element.getStyles();
+this.style=this.style.reject(function(D){return D.value==B[D.key]
+});
+A.afterFinishInternal=function(D){D.element.addClassName(D.options.style);
+D.transforms.each(function(E){D.element.style[E.style]=""
+})
+}
+}}this.start(A)
+},setup:function(){function A(B){if(!B||["rgba(0, 0, 0, 0)","transparent"].include(B)){B="#ffffff"
+}B=B.parseColor();
+return $R(0,2).map(function(C){return parseInt(B.slice(C*2+1,C*2+3),16)
+})
+}this.transforms=this.style.map(function(G){var F=G[0],E=G[1],D=null;
+if(E.parseColor("#zzzzzz")!="#zzzzzz"){E=E.parseColor();
+D="color"
+}else{if(F=="opacity"){E=parseFloat(E);
+if(Prototype.Browser.IE&&(!this.element.currentStyle.hasLayout)){this.element.setStyle({zoom:1})
+}}else{if(Element.CSS_LENGTH.test(E)){var C=E.match(/^([\+\-]?[0-9\.]+)(.*)$/);
+E=parseFloat(C[1]);
+D=(C.length==3)?C[2]:null
+}}}var B=this.element.getStyle(F);
+return{style:F.camelize(),originalValue:D=="color"?A(B):parseFloat(B||0),targetValue:D=="color"?A(E):E,unit:D}
+}.bind(this)).reject(function(B){return((B.originalValue==B.targetValue)||(B.unit!="color"&&(isNaN(B.originalValue)||isNaN(B.targetValue))))
+})
+},update:function(A){var D={},B,C=this.transforms.length;
+while(C--){D[(B=this.transforms[C]).style]=B.unit=="color"?"#"+(Math.round(B.originalValue[0]+(B.targetValue[0]-B.originalValue[0])*A)).toColorPart()+(Math.round(B.originalValue[1]+(B.targetValue[1]-B.originalValue[1])*A)).toColorPart()+(Math.round(B.originalValue[2]+(B.targetValue[2]-B.originalValue[2])*A)).toColorPart():(B.originalValue+(B.targetValue-B.originalValue)*A).toFixed(3)+(B.unit===null?"":B.unit)
+}this.element.setStyle(D,true)
+}});
+Effect.Transform=Class.create({initialize:function(A){this.tracks=[];
+this.options=arguments[1]||{};
+this.addTracks(A)
+},addTracks:function(A){A.each(function(B){B=$H(B);
+var C=B.values().first();
+this.tracks.push($H({ids:B.keys().first(),effect:Effect.Morph,options:{style:C}}))
+}.bind(this));
+return this
+},play:function(){return new Effect.Parallel(this.tracks.map(function(A){var D=A.get("ids"),C=A.get("effect"),B=A.get("options");
+var E=[$(D)||$$(D)].flatten();
+return E.map(function(F){return new C(F,Object.extend({sync:true},B))
+})
+}).flatten(),this.options)
+}});
+Element.CSS_PROPERTIES=$w("backgroundColor backgroundPosition borderBottomColor borderBottomStyle borderBottomWidth borderLeftColor borderLeftStyle borderLeftWidth borderRightColor borderRightStyle borderRightWidth borderSpacing borderTopColor borderTopStyle borderTopWidth bottom clip color fontSize fontWeight height left letterSpacing lineHeight marginBottom marginLeft marginRight marginTop markerOffset maxHeight maxWidth minHeight minWidth opacity outlineColor outlineOffset outlineWidth paddingBottom paddingLeft paddingRight paddingTop right textIndent top width wordSpacing zIndex");
+Element.CSS_LENGTH=/^(([\+\-]?[0-9\.]+)(em|ex|px|in|cm|mm|pt|pc|\%))|0$/;
+String.__parseStyleElement=document.createElement("div");
+String.prototype.parseStyle=function(){var B,A=$H();
+if(Prototype.Browser.WebKit){B=new Element("div",{style:this}).style
+}else{String.__parseStyleElement.innerHTML='<div style="'+this+'"></div>';
+B=String.__parseStyleElement.childNodes[0].style
+}Element.CSS_PROPERTIES.each(function(C){if(B[C]){A.set(C,B[C])
+}});
+if(Prototype.Browser.IE&&this.include("opacity")){A.set("opacity",this.match(/opacity:\s*((?:0|1)?(?:\.\d*)?)/)[1])
+}return A
+};
+if(document.defaultView&&document.defaultView.getComputedStyle){Element.getStyles=function(B){var A=document.defaultView.getComputedStyle($(B),null);
+return Element.CSS_PROPERTIES.inject({},function(C,D){C[D]=A[D];
+return C
+})
+}
+}else{Element.getStyles=function(B){B=$(B);
+var A=B.currentStyle,C;
+C=Element.CSS_PROPERTIES.inject({},function(E,D){E.set(D,A[D]);
+return E
+});
+if(!C.opacity){C.set("opacity",B.getOpacity())
+}return C
+}
+}Effect.Methods={morph:function(A,B){A=$(A);
+new Effect.Morph(A,Object.extend({style:B},arguments[2]||{}));
+return A
+},visualEffect:function(C,E,B){C=$(C);
+var D=E.dasherize().camelize(),A=D.charAt(0).toUpperCase()+D.substring(1);
+new Effect[A](C,B);
+return C
+},highlight:function(B,A){B=$(B);
+new Effect.Highlight(B,A);
+return B
+}};
+$w("fade appear grow shrink fold blindUp blindDown slideUp slideDown pulsate shake puff squish switchOff dropOut").each(function(A){Effect.Methods[A]=function(C,B){C=$(C);
+Effect[A.charAt(0).toUpperCase()+A.substring(1)](C,B);
+return C
+}
+});
+$w("getInlineOpacity forceRerendering setContentZoom collectTextNodes collectTextNodesIgnoreClass getStyles").each(function(A){Effect.Methods[A]=Element[A]
+});
+Element.addMethods(Effect.Methods);
+if(Object.isUndefined(Effect)){throw ("dragdrop.js requires including script.aculo.us' effects.js library")
+}var Droppables={drops:[],remove:function(A){this.drops=this.drops.reject(function(B){return B.element==$(A)
+})
+},add:function(B){B=$(B);
+var A=Object.extend({greedy:true,hoverclass:null,tree:false},arguments[1]||{});
+if(A.containment){A._containers=[];
+var C=A.containment;
+if(Object.isArray(C)){C.each(function(D){A._containers.push($(D))
+})
+}else{A._containers.push($(C))
+}}if(A.accept){A.accept=[A.accept].flatten()
+}Element.makePositioned(B);
+A.element=B;
+this.drops.push(A)
+},findDeepestChild:function(A){deepest=A[0];
+for(i=1;
+i<A.length;
+++i){if(Element.isParent(A[i].element,deepest.element)){deepest=A[i]
+}}return deepest
+},isContained:function(B,A){var C;
+if(A.tree){C=B.treeNode
+}else{C=B.parentNode
+}return A._containers.detect(function(D){return C==D
+})
+},isAffected:function(A,C,B){return((B.element!=C)&&((!B._containers)||this.isContained(C,B))&&((!B.accept)||(Element.classNames(C).detect(function(D){return B.accept.include(D)
+})))&&Position.within(B.element,A[0],A[1]))
+},deactivate:function(A){if(A.hoverclass){Element.removeClassName(A.element,A.hoverclass)
+}this.last_active=null
+},activate:function(A){if(A.hoverclass){Element.addClassName(A.element,A.hoverclass)
+}this.last_active=A
+},show:function(A,C){if(!this.drops.length){return 
+}var B,D=[];
+this.drops.each(function(E){if(Droppables.isAffected(A,C,E)){D.push(E)
+}});
+if(D.length>0){B=Droppables.findDeepestChild(D)
+}if(this.last_active&&this.last_active!=B){this.deactivate(this.last_active)
+}if(B){Position.within(B.element,A[0],A[1]);
+if(B.onHover){B.onHover(C,B.element,Position.overlap(B.overlap,B.element))
+}if(B!=this.last_active){Droppables.activate(B)
+}}},fire:function(B,A){if(!this.last_active){return 
+}Position.prepare();
+if(this.isAffected([Event.pointerX(B),Event.pointerY(B)],A,this.last_active)){if(this.last_active.onDrop){this.last_active.onDrop(A,this.last_active.element,B);
+return true
+}}},reset:function(){if(this.last_active){this.deactivate(this.last_active)
+}}};
+var Draggables={drags:[],observers:[],register:function(A){if(this.drags.length==0){this.eventMouseUp=this.endDrag.bindAsEventListener(this);
+this.eventMouseMove=this.updateDrag.bindAsEventListener(this);
+this.eventKeypress=this.keyPress.bindAsEventListener(this);
+Event.observe(document,"mouseup",this.eventMouseUp);
+Event.observe(document,"mousemove",this.eventMouseMove);
+Event.observe(document,"keypress",this.eventKeypress)
+}this.drags.push(A)
+},unregister:function(A){this.drags=this.drags.reject(function(B){return B==A
+});
+if(this.drags.length==0){Event.stopObserving(document,"mouseup",this.eventMouseUp);
+Event.stopObserving(document,"mousemove",this.eventMouseMove);
+Event.stopObserving(document,"keypress",this.eventKeypress)
+}},activate:function(A){if(A.options.delay){this._timeout=setTimeout(function(){Draggables._timeout=null;
+window.focus();
+Draggables.activeDraggable=A
+}.bind(this),A.options.delay)
+}else{window.focus();
+this.activeDraggable=A
+}},deactivate:function(){this.activeDraggable=null
+},updateDrag:function(A){if(!this.activeDraggable){return 
+}var B=[Event.pointerX(A),Event.pointerY(A)];
+if(this._lastPointer&&(this._lastPointer.inspect()==B.inspect())){return 
+}this._lastPointer=B;
+this.activeDraggable.updateDrag(A,B)
+},endDrag:function(A){if(this._timeout){clearTimeout(this._timeout);
+this._timeout=null
+}if(!this.activeDraggable){return 
+}this._lastPointer=null;
+this.activeDraggable.endDrag(A);
+this.activeDraggable=null
+},keyPress:function(A){if(this.activeDraggable){this.activeDraggable.keyPress(A)
+}},addObserver:function(A){this.observers.push(A);
+this._cacheObserverCallbacks()
+},removeObserver:function(A){this.observers=this.observers.reject(function(B){return B.element==A
+});
+this._cacheObserverCallbacks()
+},notify:function(B,A,C){if(this[B+"Count"]>0){this.observers.each(function(D){if(D[B]){D[B](B,A,C)
+}})
+}if(A.options[B]){A.options[B](A,C)
+}},_cacheObserverCallbacks:function(){["onStart","onEnd","onDrag"].each(function(A){Draggables[A+"Count"]=Draggables.observers.select(function(B){return B[A]
+}).length
+})
+}};
+var Draggable=Class.create({initialize:function(B){var C={handle:false,reverteffect:function(F,E,D){var G=Math.sqrt(Math.abs(E^2)+Math.abs(D^2))*0.02;
+new Effect.Move(F,{x:-D,y:-E,duration:G,queue:{scope:"_draggable",position:"end"}})
+},endeffect:function(E){var D=Object.isNumber(E._opacity)?E._opacity:1;
+new Effect.Opacity(E,{duration:0.2,from:0.7,to:D,queue:{scope:"_draggable",position:"end"},afterFinish:function(){Draggable._dragging[E]=false
+}})
+},zindex:1000,revert:false,quiet:false,scroll:false,scrollSensitivity:20,scrollSpeed:15,snap:false,delay:0};
+if(!arguments[1]||Object.isUndefined(arguments[1].endeffect)){Object.extend(C,{starteffect:function(D){D._opacity=Element.getOpacity(D);
+Draggable._dragging[D]=true;
+new Effect.Opacity(D,{duration:0.2,from:D._opacity,to:0.7})
+}})
+}var A=Object.extend(C,arguments[1]||{});
+this.element=$(B);
+if(A.handle&&Object.isString(A.handle)){this.handle=this.element.down("."+A.handle,0)
+}if(!this.handle){this.handle=$(A.handle)
+}if(!this.handle){this.handle=this.element
+}if(A.scroll&&!A.scroll.scrollTo&&!A.scroll.outerHTML){A.scroll=$(A.scroll);
+this._isScrollChild=Element.childOf(this.element,A.scroll)
+}Element.makePositioned(this.element);
+this.options=A;
+this.dragging=false;
+this.eventMouseDown=this.initDrag.bindAsEventListener(this);
+Event.observe(this.handle,"mousedown",this.eventMouseDown);
+Draggables.register(this)
+},destroy:function(){Event.stopObserving(this.handle,"mousedown",this.eventMouseDown);
+Draggables.unregister(this)
+},currentDelta:function(){return([parseInt(Element.getStyle(this.element,"left")||"0"),parseInt(Element.getStyle(this.element,"top")||"0")])
+},initDrag:function(A){if(!Object.isUndefined(Draggable._dragging[this.element])&&Draggable._dragging[this.element]){return 
+}if(Event.isLeftClick(A)){var C=Event.element(A);
+if((tag_name=C.tagName.toUpperCase())&&(tag_name=="INPUT"||tag_name=="SELECT"||tag_name=="OPTION"||tag_name=="BUTTON"||tag_name=="TEXTAREA")){return 
+}var B=[Event.pointerX(A),Event.pointerY(A)];
+var D=Position.cumulativeOffset(this.element);
+this.offset=[0,1].map(function(E){return(B[E]-D[E])
+});
+Draggables.activate(this);
+Event.stop(A)
+}},startDrag:function(B){this.dragging=true;
+if(!this.delta){this.delta=this.currentDelta()
+}if(this.options.zindex){this.originalZ=parseInt(Element.getStyle(this.element,"z-index")||0);
+this.element.style.zIndex=this.options.zindex
+}if(this.options.ghosting){this._clone=this.element.cloneNode(true);
+this.element._originallyAbsolute=(this.element.getStyle("position")=="absolute");
+if(!this.element._originallyAbsolute){Position.absolutize(this.element)
+}this.element.parentNode.insertBefore(this._clone,this.element)
+}if(this.options.scroll){if(this.options.scroll==window){var A=this._getWindowScroll(this.options.scroll);
+this.originalScrollLeft=A.left;
+this.originalScrollTop=A.top
+}else{this.originalScrollLeft=this.options.scroll.scrollLeft;
+this.originalScrollTop=this.options.scroll.scrollTop
+}}Draggables.notify("onStart",this,B);
+if(this.options.starteffect){this.options.starteffect(this.element)
+}},updateDrag:function(event,pointer){if(!this.dragging){this.startDrag(event)
+}if(!this.options.quiet){Position.prepare();
+Droppables.show(pointer,this.element)
+}Draggables.notify("onDrag",this,event);
+this.draw(pointer);
+if(this.options.change){this.options.change(this)
+}if(this.options.scroll){this.stopScrolling();
+var p;
+if(this.options.scroll==window){with(this._getWindowScroll(this.options.scroll)){p=[left,top,left+width,top+height]
+}}else{p=Position.page(this.options.scroll);
+p[0]+=this.options.scroll.scrollLeft+Position.deltaX;
+p[1]+=this.options.scroll.scrollTop+Position.deltaY;
+p.push(p[0]+this.options.scroll.offsetWidth);
+p.push(p[1]+this.options.scroll.offsetHeight)
+}var speed=[0,0];
+if(pointer[0]<(p[0]+this.options.scrollSensitivity)){speed[0]=pointer[0]-(p[0]+this.options.scrollSensitivity)
+}if(pointer[1]<(p[1]+this.options.scrollSensitivity)){speed[1]=pointer[1]-(p[1]+this.options.scrollSensitivity)
+}if(pointer[0]>(p[2]-this.options.scrollSensitivity)){speed[0]=pointer[0]-(p[2]-this.options.scrollSensitivity)
+}if(pointer[1]>(p[3]-this.options.scrollSensitivity)){speed[1]=pointer[1]-(p[3]-this.options.scrollSensitivity)
+}this.startScrolling(speed)
+}if(Prototype.Browser.WebKit){window.scrollBy(0,0)
+}Event.stop(event)
+},finishDrag:function(B,E){this.dragging=false;
+if(this.options.quiet){Position.prepare();
+var D=[Event.pointerX(B),Event.pointerY(B)];
+Droppables.show(D,this.element)
+}if(this.options.ghosting){if(!this.element._originallyAbsolute){Position.relativize(this.element)
+}delete this.element._originallyAbsolute;
+Element.remove(this._clone);
+this._clone=null
+}var F=false;
+if(E){F=Droppables.fire(B,this.element);
+if(!F){F=false
+}}if(F&&this.options.onDropped){this.options.onDropped(this.element)
+}Draggables.notify("onEnd",this,B);
+var A=this.options.revert;
+if(A&&Object.isFunction(A)){A=A(this.element)
+}var C=this.currentDelta();
+if(A&&this.options.reverteffect){if(F==0||A!="failure"){this.options.reverteffect(this.element,C[1]-this.delta[1],C[0]-this.delta[0])
+}}else{this.delta=C
+}if(this.options.zindex){this.element.style.zIndex=this.originalZ
+}if(this.options.endeffect){this.options.endeffect(this.element)
+}Draggables.deactivate(this);
+Droppables.reset()
+},keyPress:function(A){if(A.keyCode!=Event.KEY_ESC){return 
+}this.finishDrag(A,false);
+Event.stop(A)
+},endDrag:function(A){if(!this.dragging){return 
+}this.stopScrolling();
+this.finishDrag(A,true);
+Event.stop(A)
+},draw:function(A){var F=Position.cumulativeOffset(this.element);
+if(this.options.ghosting){var C=Position.realOffset(this.element);
+F[0]+=C[0]-Position.deltaX;
+F[1]+=C[1]-Position.deltaY
+}var E=this.currentDelta();
+F[0]-=E[0];
+F[1]-=E[1];
+if(this.options.scroll&&(this.options.scroll!=window&&this._isScrollChild)){F[0]-=this.options.scroll.scrollLeft-this.originalScrollLeft;
+F[1]-=this.options.scroll.scrollTop-this.originalScrollTop
+}var D=[0,1].map(function(G){return(A[G]-F[G]-this.offset[G])
+}.bind(this));
+if(this.options.snap){if(Object.isFunction(this.options.snap)){D=this.options.snap(D[0],D[1],this)
+}else{if(Object.isArray(this.options.snap)){D=D.map(function(G,H){return(G/this.options.snap[H]).round()*this.options.snap[H]
+}.bind(this))
+}else{D=D.map(function(G){return(G/this.options.snap).round()*this.options.snap
+}.bind(this))
+}}}var B=this.element.style;
+if((!this.options.constraint)||(this.options.constraint=="horizontal")){B.left=D[0]+"px"
+}if((!this.options.constraint)||(this.options.constraint=="vertical")){B.top=D[1]+"px"
+}if(B.visibility=="hidden"){B.visibility=""
+}},stopScrolling:function(){if(this.scrollInterval){clearInterval(this.scrollInterval);
+this.scrollInterval=null;
+Draggables._lastScrollPointer=null
+}},startScrolling:function(A){if(!(A[0]||A[1])){return 
+}this.scrollSpeed=[A[0]*this.options.scrollSpeed,A[1]*this.options.scrollSpeed];
+this.lastScrolled=new Date();
+this.scrollInterval=setInterval(this.scroll.bind(this),10)
+},scroll:function(){var current=new Date();
+var delta=current-this.lastScrolled;
+this.lastScrolled=current;
+if(this.options.scroll==window){with(this._getWindowScroll(this.options.scroll)){if(this.scrollSpeed[0]||this.scrollSpeed[1]){var d=delta/1000;
+this.options.scroll.scrollTo(left+d*this.scrollSpeed[0],top+d*this.scrollSpeed[1])
+}}}else{this.options.scroll.scrollLeft+=this.scrollSpeed[0]*delta/1000;
+this.options.scroll.scrollTop+=this.scrollSpeed[1]*delta/1000
+}Position.prepare();
+Droppables.show(Draggables._lastPointer,this.element);
+Draggables.notify("onDrag",this);
+if(this._isScrollChild){Draggables._lastScrollPointer=Draggables._lastScrollPointer||$A(Draggables._lastPointer);
+Draggables._lastScrollPointer[0]+=this.scrollSpeed[0]*delta/1000;
+Draggables._lastScrollPointer[1]+=this.scrollSpeed[1]*delta/1000;
+if(Draggables._lastScrollPointer[0]<0){Draggables._lastScrollPointer[0]=0
+}if(Draggables._lastScrollPointer[1]<0){Draggables._lastScrollPointer[1]=0
+}this.draw(Draggables._lastScrollPointer)
+}if(this.options.change){this.options.change(this)
+}},_getWindowScroll:function(w){var T,L,W,H;
+with(w.document){if(w.document.documentElement&&documentElement.scrollTop){T=documentElement.scrollTop;
+L=documentElement.scrollLeft
+}else{if(w.document.body){T=body.scrollTop;
+L=body.scrollLeft
+}}if(w.innerWidth){W=w.innerWidth;
+H=w.innerHeight
+}else{if(w.document.documentElement&&documentElement.clientWidth){W=documentElement.clientWidth;
+H=documentElement.clientHeight
+}else{W=body.offsetWidth;
+H=body.offsetHeight
+}}}return{top:T,left:L,width:W,height:H}
+}});
+Draggable._dragging={};
+var SortableObserver=Class.create({initialize:function(B,A){this.element=$(B);
+this.observer=A;
+this.lastValue=Sortable.serialize(this.element)
+},onStart:function(){this.lastValue=Sortable.serialize(this.element)
+},onEnd:function(){Sortable.unmark();
+if(this.lastValue!=Sortable.serialize(this.element)){this.observer(this.element)
+}}});
+var Sortable={SERIALIZE_RULE:/^[^_\-](?:[A-Za-z0-9\-\_]*)[_](.*)$/,sortables:{},_findRootElement:function(A){while(A.tagName.toUpperCase()!="BODY"){if(A.id&&Sortable.sortables[A.id]){return A
+}A=A.parentNode
+}},options:function(A){A=Sortable._findRootElement($(A));
+if(!A){return 
+}return Sortable.sortables[A.id]
+},destroy:function(A){var B=Sortable.options(A);
+if(B){Draggables.removeObserver(B.element);
+B.droppables.each(function(C){Droppables.remove(C)
+});
+B.draggables.invoke("destroy");
+delete Sortable.sortables[B.element.id]
+}},create:function(C){C=$(C);
+var B=Object.extend({element:C,tag:"li",dropOnEmpty:false,tree:false,treeTag:"ul",overlap:"vertical",constraint:"vertical",containment:C,handle:false,only:false,delay:0,hoverclass:null,ghosting:false,quiet:false,scroll:false,scrollSensitivity:20,scrollSpeed:15,format:this.SERIALIZE_RULE,elements:false,handles:false,onChange:Prototype.emptyFunction,onUpdate:Prototype.emptyFunction},arguments[1]||{});
+this.destroy(C);
+var A={revert:true,quiet:B.quiet,scroll:B.scroll,scrollSpeed:B.scrollSpeed,scrollSensitivity:B.scrollSensitivity,delay:B.delay,ghosting:B.ghosting,constraint:B.constraint,handle:B.handle};
+if(B.starteffect){A.starteffect=B.starteffect
+}if(B.reverteffect){A.reverteffect=B.reverteffect
+}else{if(B.ghosting){A.reverteffect=function(F){F.style.top=0;
+F.style.left=0
+}
+}}if(B.endeffect){A.endeffect=B.endeffect
+}if(B.zindex){A.zindex=B.zindex
+}var D={overlap:B.overlap,containment:B.containment,tree:B.tree,hoverclass:B.hoverclass,onHover:Sortable.onHover};
+var E={onHover:Sortable.onEmptyHover,overlap:B.overlap,containment:B.containment,hoverclass:B.hoverclass};
+Element.cleanWhitespace(C);
+B.draggables=[];
+B.droppables=[];
+if(B.dropOnEmpty||B.tree){Droppables.add(C,E);
+B.droppables.push(C)
+}(B.elements||this.findElements(C,B)||[]).each(function(H,F){var G=B.handles?$(B.handles[F]):(B.handle?$(H).select("."+B.handle)[0]:H);
+B.draggables.push(new Draggable(H,Object.extend(A,{handle:G})));
+Droppables.add(H,D);
+if(B.tree){H.treeNode=C
+}B.droppables.push(H)
+});
+if(B.tree){(Sortable.findTreeElements(C,B)||[]).each(function(F){Droppables.add(F,E);
+F.treeNode=C;
+B.droppables.push(F)
+})
+}this.sortables[C.id]=B;
+Draggables.addObserver(new SortableObserver(C,B.onUpdate))
+},findElements:function(B,A){return Element.findChildren(B,A.only,A.tree?true:false,A.tag)
+},findTreeElements:function(B,A){return Element.findChildren(B,A.only,A.tree?true:false,A.treeTag)
+},onHover:function(E,D,A){if(Element.isParent(D,E)){return 
+}if(A>0.33&&A<0.66&&Sortable.options(D).tree){return 
+}else{if(A>0.5){Sortable.mark(D,"before");
+if(D.previousSibling!=E){var B=E.parentNode;
+E.style.visibility="hidden";
+D.parentNode.insertBefore(E,D);
+if(D.parentNode!=B){Sortable.options(B).onChange(E)
+}Sortable.options(D.parentNode).onChange(E)
+}}else{Sortable.mark(D,"after");
+var C=D.nextSibling||null;
+if(C!=E){var B=E.parentNode;
+E.style.visibility="hidden";
+D.parentNode.insertBefore(E,C);
+if(D.parentNode!=B){Sortable.options(B).onChange(E)
+}Sortable.options(D.parentNode).onChange(E)
+}}}},onEmptyHover:function(E,G,H){var I=E.parentNode;
+var A=Sortable.options(G);
+if(!Element.isParent(G,E)){var F;
+var C=Sortable.findElements(G,{tag:A.tag,only:A.only});
+var B=null;
+if(C){var D=Element.offsetSize(G,A.overlap)*(1-H);
+for(F=0;
+F<C.length;
+F+=1){if(D-Element.offsetSize(C[F],A.overlap)>=0){D-=Element.offsetSize(C[F],A.overlap)
+}else{if(D-(Element.offsetSize(C[F],A.overlap)/2)>=0){B=F+1<C.length?C[F+1]:null;
+break
+}else{B=C[F];
+break
+}}}}G.insertBefore(E,B);
+Sortable.options(I).onChange(E);
+A.onChange(E)
+}},unmark:function(){if(Sortable._marker){Sortable._marker.hide()
+}},mark:function(B,A){var D=Sortable.options(B.parentNode);
+if(D&&!D.ghosting){return 
+}if(!Sortable._marker){Sortable._marker=($("dropmarker")||Element.extend(document.createElement("DIV"))).hide().addClassName("dropmarker").setStyle({position:"absolute"});
+document.getElementsByTagName("body").item(0).appendChild(Sortable._marker)
+}var C=Position.cumulativeOffset(B);
+Sortable._marker.setStyle({left:C[0]+"px",top:C[1]+"px"});
+if(A=="after"){if(D.overlap=="horizontal"){Sortable._marker.setStyle({left:(C[0]+B.clientWidth)+"px"})
+}else{Sortable._marker.setStyle({top:(C[1]+B.clientHeight)+"px"})
+}}Sortable._marker.show()
+},_tree:function(E,B,F){var D=Sortable.findElements(E,B)||[];
+for(var C=0;
+C<D.length;
+++C){var A=D[C].id.match(B.format);
+if(!A){continue
+}var G={id:encodeURIComponent(A?A[1]:null),element:E,parent:F,children:[],position:F.children.length,container:$(D[C]).down(B.treeTag)};
+if(G.container){this._tree(G.container,B,G)
+}F.children.push(G)
+}return F
+},tree:function(D){D=$(D);
+var C=this.options(D);
+var B=Object.extend({tag:C.tag,treeTag:C.treeTag,only:C.only,name:D.id,format:C.format},arguments[1]||{});
+var A={id:null,parent:null,children:[],container:D,position:0};
+return Sortable._tree(D,B,A)
+},_constructIndex:function(B){var A="";
+do{if(B.id){A="["+B.position+"]"+A
+}}while((B=B.parent)!=null);
+return A
+},sequence:function(B){B=$(B);
+var A=Object.extend(this.options(B),arguments[1]||{});
+return $(this.findElements(B,A)||[]).map(function(C){return C.id.match(A.format)?C.id.match(A.format)[1]:""
+})
+},setSequence:function(B,C){B=$(B);
+var A=Object.extend(this.options(B),arguments[2]||{});
+var D={};
+this.findElements(B,A).each(function(E){if(E.id.match(A.format)){D[E.id.match(A.format)[1]]=[E,E.parentNode]
+}E.parentNode.removeChild(E)
+});
+C.each(function(E){var F=D[E];
+if(F){F[1].appendChild(F[0]);
+delete D[E]
+}})
+},serialize:function(C){C=$(C);
+var B=Object.extend(Sortable.options(C),arguments[1]||{});
+var A=encodeURIComponent((arguments[1]&&arguments[1].name)?arguments[1].name:C.id);
+if(B.tree){return Sortable.tree(C,arguments[1]).children.map(function(D){return[A+Sortable._constructIndex(D)+"[id]="+encodeURIComponent(D.id)].concat(D.children.map(arguments.callee))
+}).flatten().join("&")
+}else{return Sortable.sequence(C,arguments[1]).map(function(D){return A+"[]="+encodeURIComponent(D)
+}).join("&")
+}}};
+Element.isParent=function(B,A){if(!B.parentNode||B==A){return false
+}if(B.parentNode==A){return true
+}return Element.isParent(B.parentNode,A)
+};
+Element.findChildren=function(D,B,A,C){if(!D.hasChildNodes()){return null
+}C=C.toUpperCase();
+if(B){B=[B].flatten()
+}var E=[];
+$A(D.childNodes).each(function(G){if(G.tagName&&G.tagName.toUpperCase()==C&&(!B||(Element.classNames(G).detect(function(H){return B.include(H)
+})))){E.push(G)
+}if(A){var F=Element.findChildren(G,B,A,C);
+if(F){E.push(F)
+}}});
+return(E.length>0?E.flatten():[])
+};
+Element.offsetSize=function(A,B){return A["offset"+((B=="vertical"||B=="height")?"Height":"Width")]
+};
+if(typeof Effect=="undefined"){throw ("controls.js requires including script.aculo.us' effects.js library")
+}var Autocompleter={};
+Autocompleter.Base=Class.create({baseInitialize:function(B,C,A){B=$(B);
+this.element=B;
+this.update=$(C);
+this.hasFocus=false;
+this.changed=false;
+this.active=false;
+this.index=0;
+this.entryCount=0;
+this.oldElementValue=this.element.value;
+if(this.setOptions){this.setOptions(A)
+}else{this.options=A||{}
+}this.options.paramName=this.options.paramName||this.element.name;
+this.options.tokens=this.options.tokens||[];
+this.options.frequency=this.options.frequency||0.4;
+this.options.minChars=this.options.minChars||1;
+this.options.onShow=this.options.onShow||function(D,E){if(!E.style.position||E.style.position=="absolute"){E.style.position="absolute";
+Position.clone(D,E,{setHeight:false,offsetTop:D.offsetHeight})
+}Effect.Appear(E,{duration:0.15})
+};
+this.options.onHide=this.options.onHide||function(D,E){new Effect.Fade(E,{duration:0.15})
+};
+if(typeof (this.options.tokens)=="string"){this.options.tokens=new Array(this.options.tokens)
+}if(!this.options.tokens.include("\n")){this.options.tokens.push("\n")
+}this.observer=null;
+this.element.setAttribute("autocomplete","off");
+Element.hide(this.update);
+Event.observe(this.element,"blur",this.onBlur.bindAsEventListener(this));
+Event.observe(this.element,"keypress",this.onKeyPress.bindAsEventListener(this))
+},show:function(){if(Element.getStyle(this.update,"display")=="none"){this.options.onShow(this.element,this.update)
+}if(!this.iefix&&(Prototype.Browser.IE)&&(Element.getStyle(this.update,"position")=="absolute")){new Insertion.After(this.update,'<iframe id="'+this.update.id+'_iefix" style="display:none;position:absolute;filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0);" src="javascript:false;" frameborder="0" scrolling="no"></iframe>');
+this.iefix=$(this.update.id+"_iefix")
+}if(this.iefix){setTimeout(this.fixIEOverlapping.bind(this),50)
+}},fixIEOverlapping:function(){Position.clone(this.update,this.iefix,{setTop:(!this.update.style.height)});
+this.iefix.style.zIndex=1;
+this.update.style.zIndex=2;
+Element.show(this.iefix)
+},hide:function(){this.stopIndicator();
+if(Element.getStyle(this.update,"display")!="none"){this.options.onHide(this.element,this.update)
+}if(this.iefix){Element.hide(this.iefix)
+}},startIndicator:function(){if(this.options.indicator){Element.show(this.options.indicator)
+}},stopIndicator:function(){if(this.options.indicator){Element.hide(this.options.indicator)
+}},onKeyPress:function(A){if(this.active){switch(A.keyCode){case Event.KEY_TAB:case Event.KEY_RETURN:this.selectEntry();
+Event.stop(A);
+case Event.KEY_ESC:this.hide();
+this.active=false;
+Event.stop(A);
+return ;
+case Event.KEY_LEFT:case Event.KEY_RIGHT:return ;
+case Event.KEY_UP:this.markPrevious();
+this.render();
+if(Prototype.Browser.WebKit){Event.stop(A)
+}return ;
+case Event.KEY_DOWN:this.markNext();
+this.render();
+if(Prototype.Browser.WebKit){Event.stop(A)
+}return 
+}}else{if(A.keyCode==Event.KEY_TAB||A.keyCode==Event.KEY_RETURN||(Prototype.Browser.WebKit>0&&A.keyCode==0)){return 
+}}this.changed=true;
+this.hasFocus=true;
+if(this.observer){clearTimeout(this.observer)
+}this.observer=setTimeout(this.onObserverEvent.bind(this),this.options.frequency*1000)
+},activate:function(){this.changed=false;
+this.hasFocus=true;
+this.getUpdatedChoices()
+},onHover:function(B){var A=Event.findElement(B,"LI");
+if(this.index!=A.autocompleteIndex){this.index=A.autocompleteIndex;
+this.render()
+}Event.stop(B)
+},onClick:function(B){var A=Event.findElement(B,"LI");
+this.index=A.autocompleteIndex;
+this.selectEntry();
+this.hide()
+},onBlur:function(A){setTimeout(this.hide.bind(this),250);
+this.hasFocus=false;
+this.active=false
+},render:function(){if(this.entryCount>0){for(var A=0;
+A<this.entryCount;
+A++){this.index==A?Element.addClassName(this.getEntry(A),"selected"):Element.removeClassName(this.getEntry(A),"selected")
+}if(this.hasFocus){this.show();
+this.active=true
+}}else{this.active=false;
+this.hide()
+}},markPrevious:function(){if(this.index>0){this.index--
+}else{this.index=this.entryCount-1
+}this.getEntry(this.index).scrollIntoView(true)
+},markNext:function(){if(this.index<this.entryCount-1){this.index++
+}else{this.index=0
+}this.getEntry(this.index).scrollIntoView(false)
+},getEntry:function(A){return this.update.firstChild.childNodes[A]
+},getCurrentEntry:function(){return this.getEntry(this.index)
+},selectEntry:function(){this.active=false;
+this.updateElement(this.getCurrentEntry())
+},updateElement:function(F){if(this.options.updateElement){this.options.updateElement(F);
+return 
+}var D="";
+if(this.options.select){var A=$(F).select("."+this.options.select)||[];
+if(A.length>0){D=Element.collectTextNodes(A[0],this.options.select)
+}}else{D=Element.collectTextNodesIgnoreClass(F,"informal")
+}var C=this.getTokenBounds();
+if(C[0]!=-1){var E=this.element.value.substr(0,C[0]);
+var B=this.element.value.substr(C[0]).match(/^\s+/);
+if(B){E+=B[0]
+}this.element.value=E+D+this.element.value.substr(C[1])
+}else{this.element.value=D
+}this.oldElementValue=this.element.value;
+this.element.focus();
+if(this.options.afterUpdateElement){this.options.afterUpdateElement(this.element,F)
+}},updateChoices:function(C){if(!this.changed&&this.hasFocus){this.update.innerHTML=C;
+Element.cleanWhitespace(this.update);
+Element.cleanWhitespace(this.update.down());
+if(this.update.firstChild&&this.update.down().childNodes){this.entryCount=this.update.down().childNodes.length;
+for(var A=0;
+A<this.entryCount;
+A++){var B=this.getEntry(A);
+B.autocompleteIndex=A;
+this.addObservers(B)
+}}else{this.entryCount=0
+}this.stopIndicator();
+this.index=0;
+if(this.entryCount==1&&this.options.autoSelect){this.selectEntry();
+this.hide()
+}else{this.render()
+}}},addObservers:function(A){Event.observe(A,"mouseover",this.onHover.bindAsEventListener(this));
+Event.observe(A,"click",this.onClick.bindAsEventListener(this))
+},onObserverEvent:function(){this.changed=false;
+this.tokenBounds=null;
+if(this.getToken().length>=this.options.minChars){this.getUpdatedChoices()
+}else{this.active=false;
+this.hide()
+}this.oldElementValue=this.element.value
+},getToken:function(){var A=this.getTokenBounds();
+return this.element.value.substring(A[0],A[1]).strip()
+},getTokenBounds:function(){if(null!=this.tokenBounds){return this.tokenBounds
+}var E=this.element.value;
+if(E.strip().empty()){return[-1,0]
+}var F=arguments.callee.getFirstDifferencePos(E,this.oldElementValue);
+var H=(F==this.oldElementValue.length?1:0);
+var D=-1,C=E.length;
+var G;
+for(var B=0,A=this.options.tokens.length;
+B<A;
+++B){G=E.lastIndexOf(this.options.tokens[B],F+H-1);
+if(G>D){D=G
+}G=E.indexOf(this.options.tokens[B],F+H);
+if(-1!=G&&G<C){C=G
+}}return(this.tokenBounds=[D+1,C])
+}});
+Autocompleter.Base.prototype.getTokenBounds.getFirstDifferencePos=function(C,A){var D=Math.min(C.length,A.length);
+for(var B=0;
+B<D;
+++B){if(C[B]!=A[B]){return B
+}}return D
+};
+Ajax.Autocompleter=Class.create(Autocompleter.Base,{initialize:function(C,D,B,A){this.baseInitialize(C,D,A);
+this.options.asynchronous=true;
+this.options.onComplete=this.onComplete.bind(this);
+this.options.defaultParams=this.options.parameters||null;
+this.url=B
+},getUpdatedChoices:function(){this.startIndicator();
+var A=encodeURIComponent(this.options.paramName)+"="+encodeURIComponent(this.getToken());
+this.options.parameters=this.options.callback?this.options.callback(this.element,A):A;
+if(this.options.defaultParams){this.options.parameters+="&"+this.options.defaultParams
+}new Ajax.Request(this.url,this.options)
+},onComplete:function(A){this.updateChoices(A.responseText)
+}});
+Autocompleter.Local=Class.create(Autocompleter.Base,{initialize:function(B,D,C,A){this.baseInitialize(B,D,A);
+this.options.array=C
+},getUpdatedChoices:function(){this.updateChoices(this.options.selector(this))
+},setOptions:function(A){this.options=Object.extend({choices:10,partialSearch:true,partialChars:2,ignoreCase:true,fullSearch:false,selector:function(B){var D=[];
+var C=[];
+var H=B.getToken();
+var G=0;
+for(var E=0;
+E<B.options.array.length&&D.length<B.options.choices;
+E++){var F=B.options.array[E];
+var I=B.options.ignoreCase?F.toLowerCase().indexOf(H.toLowerCase()):F.indexOf(H);
+while(I!=-1){if(I==0&&F.length!=H.length){D.push("<li><strong>"+F.substr(0,H.length)+"</strong>"+F.substr(H.length)+"</li>");
+break
+}else{if(H.length>=B.options.partialChars&&B.options.partialSearch&&I!=-1){if(B.options.fullSearch||/\s/.test(F.substr(I-1,1))){C.push("<li>"+F.substr(0,I)+"<strong>"+F.substr(I,H.length)+"</strong>"+F.substr(I+H.length)+"</li>");
+break
+}}}I=B.options.ignoreCase?F.toLowerCase().indexOf(H.toLowerCase(),I+1):F.indexOf(H,I+1)
+}}if(C.length){D=D.concat(C.slice(0,B.options.choices-D.length))
+}return"<ul>"+D.join("")+"</ul>"
+}},A||{})
+}});
+Field.scrollFreeActivate=function(A){setTimeout(function(){Field.activate(A)
+},1)
+};
+Ajax.InPlaceEditor=Class.create({initialize:function(C,B,A){this.url=B;
+this.element=C=$(C);
+this.prepareOptions();
+this._controls={};
+arguments.callee.dealWithDeprecatedOptions(A);
+Object.extend(this.options,A||{});
+if(!this.options.formId&&this.element.id){this.options.formId=this.element.id+"-inplaceeditor";
+if($(this.options.formId)){this.options.formId=""
+}}if(this.options.externalControl){this.options.externalControl=$(this.options.externalControl)
+}if(!this.options.externalControl){this.options.externalControlOnly=false
+}this._originalBackground=this.element.getStyle("background-color")||"transparent";
+this.element.title=this.options.clickToEditText;
+this._boundCancelHandler=this.handleFormCancellation.bind(this);
+this._boundComplete=(this.options.onComplete||Prototype.emptyFunction).bind(this);
+this._boundFailureHandler=this.handleAJAXFailure.bind(this);
+this._boundSubmitHandler=this.handleFormSubmission.bind(this);
+this._boundWrapperHandler=this.wrapUp.bind(this);
+this.registerListeners()
+},checkForEscapeOrReturn:function(A){if(!this._editing||A.ctrlKey||A.altKey||A.shiftKey){return 
+}if(Event.KEY_ESC==A.keyCode){this.handleFormCancellation(A)
+}else{if(Event.KEY_RETURN==A.keyCode){this.handleFormSubmission(A)
+}}},createControl:function(G,C,B){var E=this.options[G+"Control"];
+var F=this.options[G+"Text"];
+if("button"==E){var A=document.createElement("input");
+A.type="submit";
+A.value=F;
+A.className="editor_"+G+"_button";
+if("cancel"==G){A.onclick=this._boundCancelHandler
+}this._form.appendChild(A);
+this._controls[G]=A
+}else{if("link"==E){var D=document.createElement("a");
+D.href="#";
+D.appendChild(document.createTextNode(F));
+D.onclick="cancel"==G?this._boundCancelHandler:this._boundSubmitHandler;
+D.className="editor_"+G+"_link";
+if(B){D.className+=" "+B
+}this._form.appendChild(D);
+this._controls[G]=D
+}}},createEditField:function(){var C=(this.options.loadTextURL?this.options.loadingText:this.getText());
+var B;
+if(1>=this.options.rows&&!/\r|\n/.test(this.getText())){B=document.createElement("input");
+B.type="text";
+var A=this.options.size||this.options.cols||0;
+if(0<A){B.size=A
+}}else{B=document.createElement("textarea");
+B.rows=(1>=this.options.rows?this.options.autoRows:this.options.rows);
+B.cols=this.options.cols||40
+}B.name=this.options.paramName;
+B.value=C;
+B.className="editor_field";
+if(this.options.submitOnBlur){B.onblur=this._boundSubmitHandler
+}this._controls.editor=B;
+if(this.options.loadTextURL){this.loadExternalText()
+}this._form.appendChild(this._controls.editor)
+},createForm:function(){var B=this;
+function A(D,E){var C=B.options["text"+D+"Controls"];
+if(!C||E===false){return 
+}B._form.appendChild(document.createTextNode(C))
+}this._form=$(document.createElement("form"));
+this._form.id=this.options.formId;
+this._form.addClassName(this.options.formClassName);
+this._form.onsubmit=this._boundSubmitHandler;
+this.createEditField();
+if("textarea"==this._controls.editor.tagName.toLowerCase()){this._form.appendChild(document.createElement("br"))
+}if(this.options.onFormCustomization){this.options.onFormCustomization(this,this._form)
+}A("Before",this.options.okControl||this.options.cancelControl);
+this.createControl("ok",this._boundSubmitHandler);
+A("Between",this.options.okControl&&this.options.cancelControl);
+this.createControl("cancel",this._boundCancelHandler,"editor_cancel");
+A("After",this.options.okControl||this.options.cancelControl)
+},destroy:function(){if(this._oldInnerHTML){this.element.innerHTML=this._oldInnerHTML
+}this.leaveEditMode();
+this.unregisterListeners()
+},enterEditMode:function(A){if(this._saving||this._editing){return 
+}this._editing=true;
+this.triggerCallback("onEnterEditMode");
+if(this.options.externalControl){this.options.externalControl.hide()
+}this.element.hide();
+this.createForm();
+this.element.parentNode.insertBefore(this._form,this.element);
+if(!this.options.loadTextURL){this.postProcessEditField()
+}if(A){Event.stop(A)
+}},enterHover:function(A){if(this.options.hoverClassName){this.element.addClassName(this.options.hoverClassName)
+}if(this._saving){return 
+}this.triggerCallback("onEnterHover")
+},getText:function(){return this.element.innerHTML
+},handleAJAXFailure:function(A){this.triggerCallback("onFailure",A);
+if(this._oldInnerHTML){this.element.innerHTML=this._oldInnerHTML;
+this._oldInnerHTML=null
+}},handleFormCancellation:function(A){this.wrapUp();
+if(A){Event.stop(A)
+}},handleFormSubmission:function(D){var B=this._form;
+var C=$F(this._controls.editor);
+this.prepareSubmission();
+var E=this.options.callback(B,C)||"";
+if(Object.isString(E)){E=E.toQueryParams()
+}E.editorId=this.element.id;
+if(this.options.htmlResponse){var A=Object.extend({evalScripts:true},this.options.ajaxOptions);
+Object.extend(A,{parameters:E,onComplete:this._boundWrapperHandler,onFailure:this._boundFailureHandler});
+new Ajax.Updater({success:this.element},this.url,A)
+}else{var A=Object.extend({method:"get"},this.options.ajaxOptions);
+Object.extend(A,{parameters:E,onComplete:this._boundWrapperHandler,onFailure:this._boundFailureHandler});
+new Ajax.Request(this.url,A)
+}if(D){Event.stop(D)
+}},leaveEditMode:function(){this.element.removeClassName(this.options.savingClassName);
+this.removeForm();
+this.leaveHover();
+this.element.style.backgroundColor=this._originalBackground;
+this.element.show();
+if(this.options.externalControl){this.options.externalControl.show()
+}this._saving=false;
+this._editing=false;
+this._oldInnerHTML=null;
+this.triggerCallback("onLeaveEditMode")
+},leaveHover:function(A){if(this.options.hoverClassName){this.element.removeClassName(this.options.hoverClassName)
+}if(this._saving){return 
+}this.triggerCallback("onLeaveHover")
+},loadExternalText:function(){this._form.addClassName(this.options.loadingClassName);
+this._controls.editor.disabled=true;
+var A=Object.extend({method:"get"},this.options.ajaxOptions);
+Object.extend(A,{parameters:"editorId="+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(C){this._form.removeClassName(this.options.loadingClassName);
+var B=C.responseText;
+if(this.options.stripLoadedTextTags){B=B.stripTags()
+}this._controls.editor.value=B;
+this._controls.editor.disabled=false;
+this.postProcessEditField()
+}.bind(this),onFailure:this._boundFailureHandler});
+new Ajax.Request(this.options.loadTextURL,A)
+},postProcessEditField:function(){var A=this.options.fieldPostCreation;
+if(A){$(this._controls.editor)["focus"==A?"focus":"activate"]()
+}},prepareOptions:function(){this.options=Object.clone(Ajax.InPlaceEditor.DefaultOptions);
+Object.extend(this.options,Ajax.InPlaceEditor.DefaultCallbacks);
+[this._extraDefaultOptions].flatten().compact().each(function(A){Object.extend(this.options,A)
+}.bind(this))
+},prepareSubmission:function(){this._saving=true;
+this.removeForm();
+this.leaveHover();
+this.showSaving()
+},registerListeners:function(){this._listeners={};
+var A;
+$H(Ajax.InPlaceEditor.Listeners).each(function(B){A=this[B.value].bind(this);
+this._listeners[B.key]=A;
+if(!this.options.externalControlOnly){this.element.observe(B.key,A)
+}if(this.options.externalControl){this.options.externalControl.observe(B.key,A)
+}}.bind(this))
+},removeForm:function(){if(!this._form){return 
+}this._form.remove();
+this._form=null;
+this._controls={}
+},showSaving:function(){this._oldInnerHTML=this.element.innerHTML;
+this.element.innerHTML=this.options.savingText;
+this.element.addClassName(this.options.savingClassName);
+this.element.style.backgroundColor=this._originalBackground;
+this.element.show()
+},triggerCallback:function(B,A){if("function"==typeof this.options[B]){this.options[B](this,A)
+}},unregisterListeners:function(){$H(this._listeners).each(function(A){if(!this.options.externalControlOnly){this.element.stopObserving(A.key,A.value)
+}if(this.options.externalControl){this.options.externalControl.stopObserving(A.key,A.value)
+}}.bind(this))
+},wrapUp:function(A){this.leaveEditMode();
+this._boundComplete(A,this.element)
+}});
+Object.extend(Ajax.InPlaceEditor.prototype,{dispose:Ajax.InPlaceEditor.prototype.destroy});
+Ajax.InPlaceCollectionEditor=Class.create(Ajax.InPlaceEditor,{initialize:function($super,C,B,A){this._extraDefaultOptions=Ajax.InPlaceCollectionEditor.DefaultOptions;
+$super(C,B,A)
+},createEditField:function(){var A=document.createElement("select");
+A.name=this.options.paramName;
+A.size=1;
+this._controls.editor=A;
+this._collection=this.options.collection||[];
+if(this.options.loadCollectionURL){this.loadCollection()
+}else{this.checkForExternalText()
+}this._form.appendChild(this._controls.editor)
+},loadCollection:function(){this._form.addClassName(this.options.loadingClassName);
+this.showLoadingText(this.options.loadingCollectionText);
+var options=Object.extend({method:"get"},this.options.ajaxOptions);
+Object.extend(options,{parameters:"editorId="+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){var js=transport.responseText.strip();
+if(!/^\[.*\]$/.test(js)){throw"Server returned an invalid collection representation."
+}this._collection=eval(js);
+this.checkForExternalText()
+}.bind(this),onFailure:this.onFailure});
+new Ajax.Request(this.options.loadCollectionURL,options)
+},showLoadingText:function(B){this._controls.editor.disabled=true;
+var A=this._controls.editor.firstChild;
+if(!A){A=document.createElement("option");
+A.value="";
+this._controls.editor.appendChild(A);
+A.selected=true
+}A.update((B||"").stripScripts().stripTags())
+},checkForExternalText:function(){this._text=this.getText();
+if(this.options.loadTextURL){this.loadExternalText()
+}else{this.buildOptionList()
+}},loadExternalText:function(){this.showLoadingText(this.options.loadingText);
+var A=Object.extend({method:"get"},this.options.ajaxOptions);
+Object.extend(A,{parameters:"editorId="+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(B){this._text=B.responseText.strip();
+this.buildOptionList()
+}.bind(this),onFailure:this.onFailure});
+new Ajax.Request(this.options.loadTextURL,A)
+},buildOptionList:function(){this._form.removeClassName(this.options.loadingClassName);
+this._collection=this._collection.map(function(D){return 2===D.length?D:[D,D].flatten()
+});
+var B=("value" in this.options)?this.options.value:this._text;
+var A=this._collection.any(function(D){return D[0]==B
+}.bind(this));
+this._controls.editor.update("");
+var C;
+this._collection.each(function(E,D){C=document.createElement("option");
+C.value=E[0];
+C.selected=A?E[0]==B:0==D;
+C.appendChild(document.createTextNode(E[1]));
+this._controls.editor.appendChild(C)
+}.bind(this));
+this._controls.editor.disabled=false;
+Field.scrollFreeActivate(this._controls.editor)
+}});
+Ajax.InPlaceEditor.prototype.initialize.dealWithDeprecatedOptions=function(A){if(!A){return 
+}function B(C,D){if(C in A||D===undefined){return 
+}A[C]=D
+}B("cancelControl",(A.cancelLink?"link":(A.cancelButton?"button":A.cancelLink==A.cancelButton==false?false:undefined)));
+B("okControl",(A.okLink?"link":(A.okButton?"button":A.okLink==A.okButton==false?false:undefined)));
+B("highlightColor",A.highlightcolor);
+B("highlightEndColor",A.highlightendcolor)
+};
+Object.extend(Ajax.InPlaceEditor,{DefaultOptions:{ajaxOptions:{},autoRows:3,cancelControl:"link",cancelText:"cancel",clickToEditText:"Click to edit",externalControl:null,externalControlOnly:false,fieldPostCreation:"activate",formClassName:"inplaceeditor-form",formId:null,highlightColor:"#ffff99",highlightEndColor:"#ffffff",hoverClassName:"",htmlResponse:true,loadingClassName:"inplaceeditor-loading",loadingText:"Loading...",okControl:"button",okText:"ok",paramName:"value",rows:1,savingClassName:"inplaceeditor-saving",savingText:"Saving...",size:0,stripLoadedTextTags:false,submitOnBlur:false,textAfterControls:"",textBeforeControls:"",textBetweenControls:""},DefaultCallbacks:{callback:function(A){return Form.serialize(A)
+},onComplete:function(B,A){new Effect.Highlight(A,{startcolor:this.options.highlightColor,keepBackgroundImage:true})
+},onEnterEditMode:null,onEnterHover:function(A){A.element.style.backgroundColor=A.options.highlightColor;
+if(A._effect){A._effect.cancel()
+}},onFailure:function(B,A){alert("Error communication with the server: "+B.responseText.stripTags())
+},onFormCustomization:null,onLeaveEditMode:null,onLeaveHover:function(A){A._effect=new Effect.Highlight(A.element,{startcolor:A.options.highlightColor,endcolor:A.options.highlightEndColor,restorecolor:A._originalBackground,keepBackgroundImage:true})
+}},Listeners:{click:"enterEditMode",keydown:"checkForEscapeOrReturn",mouseover:"enterHover",mouseout:"leaveHover"}});
+Ajax.InPlaceCollectionEditor.DefaultOptions={loadingCollectionText:"Loading options..."};
+Form.Element.DelayedObserver=Class.create({initialize:function(B,A,C){this.delay=A||0.5;
+this.element=$(B);
+this.callback=C;
+this.timer=null;
+this.lastValue=$F(this.element);
+Event.observe(this.element,"keyup",this.delayedListener.bindAsEventListener(this))
+},delayedListener:function(A){if(this.lastValue==$F(this.element)){return 
+}if(this.timer){clearTimeout(this.timer)
+}this.timer=setTimeout(this.onTimerEvent.bind(this),this.delay*1000);
+this.lastValue=$F(this.element)
+},onTimerEvent:function(){this.timer=null;
+this.callback(this.element,$F(this.element))
+}});
+if(!Control){var Control={}
+}Control.Slider=Class.create({initialize:function(D,A,B){var C=this;
+if(Object.isArray(D)){this.handles=D.collect(function(E){return $(E)
+})
+}else{this.handles=[$(D)]
+}this.track=$(A);
+this.options=B||{};
+this.axis=this.options.axis||"horizontal";
+this.increment=this.options.increment||1;
+this.step=parseInt(this.options.step||"1");
+this.range=this.options.range||$R(0,1);
+this.value=0;
+this.values=this.handles.map(function(){return 0
+});
+this.spans=this.options.spans?this.options.spans.map(function(E){return $(E)
+}):false;
+this.options.startSpan=$(this.options.startSpan||null);
+this.options.endSpan=$(this.options.endSpan||null);
+this.restricted=this.options.restricted||false;
+this.maximum=this.options.maximum||this.range.end;
+this.minimum=this.options.minimum||this.range.start;
+this.alignX=parseInt(this.options.alignX||"0");
+this.alignY=parseInt(this.options.alignY||"0");
+this.trackLength=this.maximumOffset()-this.minimumOffset();
+this.handleLength=this.isVertical()?(this.handles[0].offsetHeight!=0?this.handles[0].offsetHeight:this.handles[0].style.height.replace(/px$/,"")):(this.handles[0].offsetWidth!=0?this.handles[0].offsetWidth:this.handles[0].style.width.replace(/px$/,""));
+this.active=false;
+this.dragging=false;
+this.disabled=false;
+if(this.options.disabled){this.setDisabled()
+}this.allowedValues=this.options.values?this.options.values.sortBy(Prototype.K):false;
+if(this.allowedValues){this.minimum=this.allowedValues.min();
+this.maximum=this.allowedValues.max()
+}this.eventMouseDown=this.startDrag.bindAsEventListener(this);
+this.eventMouseUp=this.endDrag.bindAsEventListener(this);
+this.eventMouseMove=this.update.bindAsEventListener(this);
+this.handles.each(function(F,E){E=C.handles.length-1-E;
+C.setValue(parseFloat((Object.isArray(C.options.sliderValue)?C.options.sliderValue[E]:C.options.sliderValue)||C.range.start),E);
+F.makePositioned().observe("mousedown",C.eventMouseDown)
+});
+this.track.observe("mousedown",this.eventMouseDown);
+document.observe("mouseup",this.eventMouseUp);
+document.observe("mousemove",this.eventMouseMove);
+this.initialized=true
+},dispose:function(){var A=this;
+Event.stopObserving(this.track,"mousedown",this.eventMouseDown);
+Event.stopObserving(document,"mouseup",this.eventMouseUp);
+Event.stopObserving(document,"mousemove",this.eventMouseMove);
+this.handles.each(function(B){Event.stopObserving(B,"mousedown",A.eventMouseDown)
+})
+},setDisabled:function(){this.disabled=true
+},setEnabled:function(){this.disabled=false
+},getNearestValue:function(A){if(this.allowedValues){if(A>=this.allowedValues.max()){return(this.allowedValues.max())
+}if(A<=this.allowedValues.min()){return(this.allowedValues.min())
+}var C=Math.abs(this.allowedValues[0]-A);
+var B=this.allowedValues[0];
+this.allowedValues.each(function(D){var E=Math.abs(D-A);
+if(E<=C){B=D;
+C=E
+}});
+return B
+}if(A>this.range.end){return this.range.end
+}if(A<this.range.start){return this.range.start
+}return A
+},setValue:function(B,A){if(!this.active){this.activeHandleIdx=A||0;
+this.activeHandle=this.handles[this.activeHandleIdx];
+this.updateStyles()
+}A=A||this.activeHandleIdx||0;
+if(this.initialized&&this.restricted){if((A>0)&&(B<this.values[A-1])){B=this.values[A-1]
+}if((A<(this.handles.length-1))&&(B>this.values[A+1])){B=this.values[A+1]
+}}B=this.getNearestValue(B);
+this.values[A]=B;
+this.value=this.values[0];
+this.handles[A].style[this.isVertical()?"top":"left"]=this.translateToPx(B);
+this.drawSpans();
+if(!this.dragging||!this.event){this.updateFinished()
+}},setValueBy:function(B,A){this.setValue(this.values[A||this.activeHandleIdx||0]+B,A||this.activeHandleIdx||0)
+},translateToPx:function(A){return Math.round(((this.trackLength-this.handleLength)/(this.range.end-this.range.start))*(A-this.range.start))+"px"
+},translateToValue:function(A){return((A/(this.trackLength-this.handleLength)*(this.range.end-this.range.start))+this.range.start)
+},getRange:function(B){var A=this.values.sortBy(Prototype.K);
+B=B||0;
+return $R(A[B],A[B+1])
+},minimumOffset:function(){return(this.isVertical()?this.alignY:this.alignX)
+},maximumOffset:function(){return(this.isVertical()?(this.track.offsetHeight!=0?this.track.offsetHeight:this.track.style.height.replace(/px$/,""))-this.alignY:(this.track.offsetWidth!=0?this.track.offsetWidth:this.track.style.width.replace(/px$/,""))-this.alignX)
+},isVertical:function(){return(this.axis=="vertical")
+},drawSpans:function(){var A=this;
+if(this.spans){$R(0,this.spans.length-1).each(function(B){A.setSpan(A.spans[B],A.getRange(B))
+})
+}if(this.options.startSpan){this.setSpan(this.options.startSpan,$R(0,this.values.length>1?this.getRange(0).min():this.value))
+}if(this.options.endSpan){this.setSpan(this.options.endSpan,$R(this.values.length>1?this.getRange(this.spans.length-1).max():this.value,this.maximum))
+}},setSpan:function(B,A){if(this.isVertical()){B.style.top=this.translateToPx(A.start);
+B.style.height=this.translateToPx(A.end-A.start+this.range.start)
+}else{B.style.left=this.translateToPx(A.start);
+B.style.width=this.translateToPx(A.end-A.start+this.range.start)
+}},updateStyles:function(){this.handles.each(function(A){Element.removeClassName(A,"selected")
+});
+Element.addClassName(this.activeHandle,"selected")
+},startDrag:function(C){if(Event.isLeftClick(C)){if(!this.disabled){this.active=true;
+var D=Event.element(C);
+var E=[Event.pointerX(C),Event.pointerY(C)];
+var A=D;
+if(A==this.track){var B=Position.cumulativeOffset(this.track);
+this.event=C;
+this.setValue(this.translateToValue((this.isVertical()?E[1]-B[1]:E[0]-B[0])-(this.handleLength/2)));
+var B=Position.cumulativeOffset(this.activeHandle);
+this.offsetX=(E[0]-B[0]);
+this.offsetY=(E[1]-B[1])
+}else{while((this.handles.indexOf(D)==-1)&&D.parentNode){D=D.parentNode
+}if(this.handles.indexOf(D)!=-1){this.activeHandle=D;
+this.activeHandleIdx=this.handles.indexOf(this.activeHandle);
+this.updateStyles();
+var B=Position.cumulativeOffset(this.activeHandle);
+this.offsetX=(E[0]-B[0]);
+this.offsetY=(E[1]-B[1])
+}}}Event.stop(C)
+}},update:function(A){if(this.active){if(!this.dragging){this.dragging=true
+}this.draw(A);
+if(Prototype.Browser.WebKit){window.scrollBy(0,0)
+}Event.stop(A)
+}},draw:function(B){var C=[Event.pointerX(B),Event.pointerY(B)];
+var A=Position.cumulativeOffset(this.track);
+C[0]-=this.offsetX+A[0];
+C[1]-=this.offsetY+A[1];
+this.event=B;
+this.setValue(this.translateToValue(this.isVertical()?C[1]:C[0]));
+if(this.initialized&&this.options.onSlide){this.options.onSlide(this.values.length>1?this.values:this.value,this)
+}},endDrag:function(A){if(this.active&&this.dragging){this.finishDrag(A,true);
+Event.stop(A)
+}this.active=false;
+this.dragging=false
+},finishDrag:function(A,B){this.active=false;
+this.dragging=false;
+this.updateFinished()
+},updateFinished:function(){if(this.initialized&&this.options.onChange){this.options.onChange(this.values.length>1?this.values:this.value,this)
+}this.event=null
+}});
+Sound={tracks:{},_enabled:true,template:new Template('<embed style="height:0" id="sound_#{track}_#{id}" src="#{url}" loop="false" autostart="true" hidden="true"/>'),enable:function(){Sound._enabled=true
+},disable:function(){Sound._enabled=false
+},play:function(B){if(!Sound._enabled){return 
+}var A=Object.extend({track:"global",url:B,replace:false},arguments[1]||{});
+if(A.replace&&this.tracks[A.track]){$R(0,this.tracks[A.track].id).each(function(D){var C=$("sound_"+A.track+"_"+D);
+C.Stop&&C.Stop();
+C.remove()
+});
+this.tracks[A.track]=null
+}if(!this.tracks[A.track]){this.tracks[A.track]={id:0}
+}else{this.tracks[A.track].id++
+}A.id=this.tracks[A.track].id;
+$$("body")[0].insert(Prototype.Browser.IE?new Element("bgsound",{id:"sound_"+A.track+"_"+A.id,src:A.url,loop:1,autostart:true}):Sound.template.evaluate(A))
+}};
+if(Prototype.Browser.Gecko&&navigator.userAgent.indexOf("Win")>0){if(navigator.plugins&&$A(navigator.plugins).detect(function(A){return A.name.indexOf("QuickTime")!=-1
+})){Sound.template=new Template('<object id="sound_#{track}_#{id}" width="0" height="0" type="audio/mpeg" data="#{url}"/>')
+}else{Sound.play=function(){}
+}}
+(function(){if(typeof jQuery!="undefined"){var _jQuery=jQuery
+}var jQuery=window.jQuery=function(selector,context){return this instanceof jQuery?this.init(selector,context):new jQuery(selector,context)
+};
+if(typeof $!="undefined"){var _$=$
+}window.$=jQuery;
+var quickExpr=/^[^<]*(<(.|\s)+>)[^>]*$|^#(\w+)$/;
+jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;
+if(typeof selector=="string"){var m=quickExpr.exec(selector);
+if(m&&(m[1]||!context)){if(m[1]){selector=jQuery.clean([m[1]],context)
+}else{var tmp=document.getElementById(m[3]);
+if(tmp){if(tmp.id!=m[3]){return jQuery().find(selector)
+}else{this[0]=tmp;
+this.length=1;
+return this
+}}else{selector=[]
+}}}else{return new jQuery(context).find(selector)
+}}else{if(jQuery.isFunction(selector)){return new jQuery(document)[jQuery.fn.ready?"ready":"load"](selector)
+}}return this.setArray(selector.constructor==Array&&selector||(selector.jquery||selector.length&&selector!=window&&!selector.nodeType&&selector[0]!=undefined&&selector[0].nodeType)&&jQuery.makeArray(selector)||[selector])
+},jquery:"1.2.1",size:function(){return this.length
+},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num]
+},pushStack:function(a){var ret=jQuery(a);
+ret.prevObject=this;
+return ret
+},setArray:function(a){this.length=0;
+Array.prototype.push.apply(this,a);
+return this
+},each:function(fn,args){return jQuery.each(this,fn,args)
+},index:function(obj){var pos=-1;
+this.each(function(i){if(this==obj){pos=i
+}});
+return pos
+},attr:function(key,value,type){var obj=key;
+if(key.constructor==String){if(value==undefined){return this.length&&jQuery[type||"attr"](this[0],key)||undefined
+}else{obj={};
+obj[key]=value
+}}return this.each(function(index){for(var prop in obj){jQuery.attr(type?this.style:this,prop,jQuery.prop(this,obj[prop],type,index,prop))
+}})
+},css:function(key,value){return this.attr(key,value,"curCSS")
+},text:function(e){if(typeof e!="object"&&e!=null){return this.empty().append(document.createTextNode(e))
+}var t="";
+jQuery.each(e||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8){t+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this])
+}})
+});
+return t
+},wrapAll:function(html){if(this[0]){jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;
+while(elem.firstChild){elem=elem.firstChild
+}return elem
+}).append(this)
+}return this
+},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html)
+})
+},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html)
+})
+},append:function(){return this.domManip(arguments,true,1,function(a){this.appendChild(a)
+})
+},prepend:function(){return this.domManip(arguments,true,-1,function(a){this.insertBefore(a,this.firstChild)
+})
+},before:function(){return this.domManip(arguments,false,1,function(a){this.parentNode.insertBefore(a,this)
+})
+},after:function(){return this.domManip(arguments,false,-1,function(a){this.parentNode.insertBefore(a,this.nextSibling)
+})
+},end:function(){return this.prevObject||jQuery([])
+},find:function(t){var data=jQuery.map(this,function(a){return jQuery.find(t,a)
+});
+return this.pushStack(/[^+>] [^+>]/.test(t)||t.indexOf("..")>-1?jQuery.unique(data):data)
+},clone:function(events){var ret=this.map(function(){return this.outerHTML?jQuery(this.outerHTML)[0]:this.cloneNode(true)
+});
+var clone=ret.find("*").andSelf().each(function(){if(this[expando]!=undefined){this[expando]=null
+}});
+if(events===true){this.find("*").andSelf().each(function(i){var events=jQuery.data(this,"events");
+for(var type in events){for(var handler in events[type]){jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data)
+}}})
+}return ret
+},filter:function(t){return this.pushStack(jQuery.isFunction(t)&&jQuery.grep(this,function(el,index){return t.apply(el,[index])
+})||jQuery.multiFilter(t,this))
+},not:function(t){return this.pushStack(t.constructor==String&&jQuery.multiFilter(t,this,true)||jQuery.grep(this,function(a){return(t.constructor==Array||t.jquery)?jQuery.inArray(a,t)<0:a!=t
+}))
+},add:function(t){return this.pushStack(jQuery.merge(this.get(),t.constructor==String?jQuery(t).get():t.length!=undefined&&(!t.nodeName||jQuery.nodeName(t,"form"))?t:[t]))
+},is:function(expr){return expr?jQuery.multiFilter(expr,this).length>0:false
+},hasClass:function(expr){return this.is("."+expr)
+},val:function(val){if(val==undefined){if(this.length){var elem=this[0];
+if(jQuery.nodeName(elem,"select")){var index=elem.selectedIndex,a=[],options=elem.options,one=elem.type=="select-one";
+if(index<0){return null
+}for(var i=one?index:0,max=one?index+1:options.length;
+i<max;
+i++){var option=options[i];
+if(option.selected){var val=jQuery.browser.msie&&!option.attributes["value"].specified?option.text:option.value;
+if(one){return val
+}a.push(val)
+}}return a
+}else{return this[0].value.replace(/\r/g,"")
+}}}else{return this.each(function(){if(val.constructor==Array&&/radio|checkbox/.test(this.type)){this.checked=(jQuery.inArray(this.value,val)>=0||jQuery.inArray(this.name,val)>=0)
+}else{if(jQuery.nodeName(this,"select")){var tmp=val.constructor==Array?val:[val];
+jQuery("option",this).each(function(){this.selected=(jQuery.inArray(this.value,tmp)>=0||jQuery.inArray(this.text,tmp)>=0)
+});
+if(!tmp.length){this.selectedIndex=-1
+}}else{this.value=val
+}}})
+}},html:function(val){return val==undefined?(this.length?this[0].innerHTML:null):this.empty().append(val)
+},replaceWith:function(val){return this.after(val).remove()
+},eq:function(i){return this.slice(i,i+1)
+},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments))
+},map:function(fn){return this.pushStack(jQuery.map(this,function(elem,i){return fn.call(elem,i,elem)
+}))
+},andSelf:function(){return this.add(this.prevObject)
+},domManip:function(args,table,dir,fn){var clone=this.length>1,a;
+return this.each(function(){if(!a){a=jQuery.clean(args,this.ownerDocument);
+if(dir<0){a.reverse()
+}}var obj=this;
+if(table&&jQuery.nodeName(this,"table")&&jQuery.nodeName(a[0],"tr")){obj=this.getElementsByTagName("tbody")[0]||this.appendChild(document.createElement("tbody"))
+}jQuery.each(a,function(){var elem=clone?this.cloneNode(true):this;
+if(!evalScript(0,elem)){fn.call(obj,elem)
+}})
+})
+}};
+function evalScript(i,elem){var script=jQuery.nodeName(elem,"script");
+if(script){if(elem.src){jQuery.ajax({url:elem.src,async:false,dataType:"script"})
+}else{jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||"")
+}if(elem.parentNode){elem.parentNode.removeChild(elem)
+}}else{if(elem.nodeType==1){jQuery("script",elem).each(evalScript)
+}}return script
+}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},a=1,al=arguments.length,deep=false;
+if(target.constructor==Boolean){deep=target;
+target=arguments[1]||{}
+}if(al==1){target=this;
+a=0
+}var prop;
+for(;
+a<al;
+a++){if((prop=arguments[a])!=null){for(var i in prop){if(target==prop[i]){continue
+}if(deep&&typeof prop[i]=="object"&&target[i]){jQuery.extend(target[i],prop[i])
+}else{if(prop[i]!=undefined){target[i]=prop[i]
+}}}}}return target
+};
+var expando="jQuery"+(new Date()).getTime(),uuid=0,win={};
+jQuery.extend({noConflict:function(deep){window.$=_$;
+if(deep){window.jQuery=_jQuery
+}return jQuery
+},isFunction:function(fn){return !!fn&&typeof fn!="string"&&!fn.nodeName&&fn.constructor!=Array&&/function/i.test(fn+"")
+},isXMLDoc:function(elem){return elem.documentElement&&!elem.body||elem.tagName&&elem.ownerDocument&&!elem.ownerDocument.body
+},globalEval:function(data){data=jQuery.trim(data);
+if(data){if(window.execScript){window.execScript(data)
+}else{if(jQuery.browser.safari){window.setTimeout(data,0)
+}else{eval.call(window,data)
+}}}},nodeName:function(elem,name){return elem.nodeName&&elem.nodeName.toUpperCase()==name.toUpperCase()
+},cache:{},data:function(elem,name,data){elem=elem==window?win:elem;
+var id=elem[expando];
+if(!id){id=elem[expando]=++uuid
+}if(name&&!jQuery.cache[id]){jQuery.cache[id]={}
+}if(data!=undefined){jQuery.cache[id][name]=data
+}return name?jQuery.cache[id][name]:id
+},removeData:function(elem,name){elem=elem==window?win:elem;
+var id=elem[expando];
+if(name){if(jQuery.cache[id]){delete jQuery.cache[id][name];
+name="";
+for(name in jQuery.cache[id]){break
+}if(!name){jQuery.removeData(elem)
+}}}else{try{delete elem[expando]
+}catch(e){if(elem.removeAttribute){elem.removeAttribute(expando)
+}}delete jQuery.cache[id]
+}},each:function(obj,fn,args){if(args){if(obj.length==undefined){for(var i in obj){fn.apply(obj[i],args)
+}}else{for(var i=0,ol=obj.length;
+i<ol;
+i++){if(fn.apply(obj[i],args)===false){break
+}}}}else{if(obj.length==undefined){for(var i in obj){fn.call(obj[i],i,obj[i])
+}}else{for(var i=0,ol=obj.length,val=obj[0];
+i<ol&&fn.call(val,i,val)!==false;
+val=obj[++i]){}}}return obj
+},prop:function(elem,value,type,index,prop){if(jQuery.isFunction(value)){value=value.call(elem,[index])
+}var exclude=/z-?index|font-?weight|opacity|zoom|line-?height/i;
+return value&&value.constructor==Number&&type=="curCSS"&&!exclude.test(prop)?value+"px":value
+},className:{add:function(elem,c){jQuery.each((c||"").split(/\s+/),function(i,cur){if(!jQuery.className.has(elem.className,cur)){elem.className+=(elem.className?" ":"")+cur
+}})
+},remove:function(elem,c){elem.className=c!=undefined?jQuery.grep(elem.className.split(/\s+/),function(cur){return !jQuery.className.has(c,cur)
+}).join(" "):""
+},has:function(t,c){return jQuery.inArray(c,(t.className||t).toString().split(/\s+/))>-1
+}},swap:function(e,o,f){for(var i in o){e.style["old"+i]=e.style[i];
+e.style[i]=o[i]
+}f.apply(e,[]);
+for(var i in o){e.style[i]=e.style["old"+i]
+}},css:function(e,p){if(p=="height"||p=="width"){var old={},oHeight,oWidth,d=["Top","Bottom","Right","Left"];
+jQuery.each(d,function(){old["padding"+this]=0;
+old["border"+this+"Width"]=0
+});
+jQuery.swap(e,old,function(){if(jQuery(e).is(":visible")){oHeight=e.offsetHeight;
+oWidth=e.offsetWidth
+}else{e=jQuery(e.cloneNode(true)).find(":radio").removeAttr("checked").end().css({visibility:"hidden",position:"absolute",display:"block",right:"0",left:"0"}).appendTo(e.parentNode)[0];
+var parPos=jQuery.css(e.parentNode,"position")||"static";
+if(parPos=="static"){e.parentNode.style.position="relative"
+}oHeight=e.clientHeight;
+oWidth=e.clientWidth;
+if(parPos=="static"){e.parentNode.style.position="static"
+}e.parentNode.removeChild(e)
+}});
+return p=="height"?oHeight:oWidth
+}return jQuery.curCSS(e,p)
+},curCSS:function(elem,prop,force){var ret,stack=[],swap=[];
+function color(a){if(!jQuery.browser.safari){return false
+}var ret=document.defaultView.getComputedStyle(a,null);
+return !ret||ret.getPropertyValue("color")==""
+}if(prop=="opacity"&&jQuery.browser.msie){ret=jQuery.attr(elem.style,"opacity");
+return ret==""?"1":ret
+}if(prop.match(/float/i)){prop=styleFloat
+}if(!force&&elem.style[prop]){ret=elem.style[prop]
+}else{if(document.defaultView&&document.defaultView.getComputedStyle){if(prop.match(/float/i)){prop="float"
+}prop=prop.replace(/([A-Z])/g,"-$1").toLowerCase();
+var cur=document.defaultView.getComputedStyle(elem,null);
+if(cur&&!color(elem)){ret=cur.getPropertyValue(prop)
+}else{for(var a=elem;
+a&&color(a);
+a=a.parentNode){stack.unshift(a)
+}for(a=0;
+a<stack.length;
+a++){if(color(stack[a])){swap[a]=stack[a].style.display;
+stack[a].style.display="block"
+}}ret=prop=="display"&&swap[stack.length-1]!=null?"none":document.defaultView.getComputedStyle(elem,null).getPropertyValue(prop)||"";
+for(a=0;
+a<swap.length;
+a++){if(swap[a]!=null){stack[a].style.display=swap[a]
+}}}if(prop=="opacity"&&ret==""){ret="1"
+}}else{if(elem.currentStyle){var newProp=prop.replace(/\-(\w)/g,function(m,c){return c.toUpperCase()
+});
+ret=elem.currentStyle[prop]||elem.currentStyle[newProp];
+if(!/^\d+(px)?$/i.test(ret)&&/^\d/.test(ret)){var style=elem.style.left;
+var runtimeStyle=elem.runtimeStyle.left;
+elem.runtimeStyle.left=elem.currentStyle.left;
+elem.style.left=ret||0;
+ret=elem.style.pixelLeft+"px";
+elem.style.left=style;
+elem.runtimeStyle.left=runtimeStyle
+}}}}return ret
+},clean:function(a,doc){var r=[];
+doc=doc||document;
+jQuery.each(a,function(i,arg){if(!arg){return 
+}if(arg.constructor==Number){arg=arg.toString()
+}if(typeof arg=="string"){arg=arg.replace(/(<(\w+)[^>]*?)\/>/g,function(m,all,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area)$/i)?m:all+"></"+tag+">"
+});
+var s=jQuery.trim(arg).toLowerCase(),div=doc.createElement("div"),tb=[];
+var wrap=!s.indexOf("<opt")&&[1,"<select>","</select>"]||!s.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||s.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!s.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!s.indexOf("<td")||!s.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!s.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||jQuery.browser.msie&&[1,"div<div>","</div>"]||[0,"",""];
+div.innerHTML=wrap[1]+arg+wrap[2];
+while(wrap[0]--){div=div.lastChild
+}if(jQuery.browser.msie){if(!s.indexOf("<table")&&s.indexOf("<tbody")<0){tb=div.firstChild&&div.firstChild.childNodes
+}else{if(wrap[1]=="<table>"&&s.indexOf("<tbody")<0){tb=div.childNodes
+}}for(var n=tb.length-1;
+n>=0;
+--n){if(jQuery.nodeName(tb[n],"tbody")&&!tb[n].childNodes.length){tb[n].parentNode.removeChild(tb[n])
+}}if(/^\s/.test(arg)){div.insertBefore(doc.createTextNode(arg.match(/^\s*/)[0]),div.firstChild)
+}}arg=jQuery.makeArray(div.childNodes)
+}if(0===arg.length&&(!jQuery.nodeName(arg,"form")&&!jQuery.nodeName(arg,"select"))){return 
+}if(arg[0]==undefined||jQuery.nodeName(arg,"form")||arg.options){r.push(arg)
+}else{r=jQuery.merge(r,arg)
+}});
+return r
+},attr:function(elem,name,value){var fix=jQuery.isXMLDoc(elem)?{}:jQuery.props;
+if(name=="selected"&&jQuery.browser.safari){elem.parentNode.selectedIndex
+}if(fix[name]){if(value!=undefined){elem[fix[name]]=value
+}return elem[fix[name]]
+}else{if(jQuery.browser.msie&&name=="style"){return jQuery.attr(elem.style,"cssText",value)
+}else{if(value==undefined&&jQuery.browser.msie&&jQuery.nodeName(elem,"form")&&(name=="action"||name=="method")){return elem.getAttributeNode(name).nodeValue
+}else{if(elem.tagName){if(value!=undefined){if(name=="type"&&jQuery.nodeName(elem,"input")&&elem.parentNode){throw"type property can't be changed"
+}elem.setAttribute(name,value)
+}if(jQuery.browser.msie&&/href|src/.test(name)&&!jQuery.isXMLDoc(elem)){return elem.getAttribute(name,2)
+}return elem.getAttribute(name)
+}else{if(name=="opacity"&&jQuery.browser.msie){if(value!=undefined){elem.zoom=1;
+elem.filter=(elem.filter||"").replace(/alpha\([^)]*\)/,"")+(parseFloat(value).toString()=="NaN"?"":"alpha(opacity="+value*100+")")
+}return elem.filter?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100).toString():""
+}name=name.replace(/-([a-z])/ig,function(z,b){return b.toUpperCase()
+});
+if(value!=undefined){elem[name]=value
+}return elem[name]
+}}}}},trim:function(t){return(t||"").replace(/^\s+|\s+$/g,"")
+},makeArray:function(a){var r=[];
+if(typeof a!="array"){for(var i=0,al=a.length;
+i<al;
+i++){r.push(a[i])
+}}else{r=a.slice(0)
+}return r
+},inArray:function(b,a){for(var i=0,al=a.length;
+i<al;
+i++){if(a[i]==b){return i
+}}return -1
+},merge:function(first,second){if(jQuery.browser.msie){for(var i=0;
+second[i];
+i++){if(second[i].nodeType!=8){first.push(second[i])
+}}}else{for(var i=0;
+second[i];
+i++){first.push(second[i])
+}}return first
+},unique:function(first){var r=[],done={};
+try{for(var i=0,fl=first.length;
+i<fl;
+i++){var id=jQuery.data(first[i]);
+if(!done[id]){done[id]=true;
+r.push(first[i])
+}}}catch(e){r=first
+}return r
+},grep:function(elems,fn,inv){if(typeof fn=="string"){fn=eval("false||function(a,i){return "+fn+"}")
+}var result=[];
+for(var i=0,el=elems.length;
+i<el;
+i++){if(!inv&&fn(elems[i],i)||inv&&!fn(elems[i],i)){result.push(elems[i])
+}}return result
+},map:function(elems,fn){if(typeof fn=="string"){fn=eval("false||function(a){return "+fn+"}")
+}var result=[];
+for(var i=0,el=elems.length;
+i<el;
+i++){var val=fn(elems[i],i);
+if(val!==null&&val!=undefined){if(val.constructor!=Array){val=[val]
+}result=result.concat(val)
+}}return result
+}});
+var userAgent=navigator.userAgent.toLowerCase();
+jQuery.browser={version:(userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1],safari:/webkit/.test(userAgent),opera:/opera/.test(userAgent),msie:/msie/.test(userAgent)&&!/opera/.test(userAgent),mozilla:/mozilla/.test(userAgent)&&!/(compatible|webkit)/.test(userAgent)};
+var styleFloat=jQuery.browser.msie?"styleFloat":"cssFloat";
+jQuery.extend({boxModel:!jQuery.browser.msie||document.compatMode=="CSS1Compat",styleFloat:jQuery.browser.msie?"styleFloat":"cssFloat",props:{"for":"htmlFor","class":"className","float":styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,innerHTML:"innerHTML",className:"className",value:"value",disabled:"disabled",checked:"checked",readonly:"readOnly",selected:"selected",maxlength:"maxLength"}});
+jQuery.each({parent:"a.parentNode",parents:"jQuery.dir(a,'parentNode')",next:"jQuery.nth(a,2,'nextSibling')",prev:"jQuery.nth(a,2,'previousSibling')",nextAll:"jQuery.dir(a,'nextSibling')",prevAll:"jQuery.dir(a,'previousSibling')",siblings:"jQuery.sibling(a.parentNode.firstChild,a)",children:"jQuery.sibling(a.firstChild)",contents:"jQuery.nodeName(a,'iframe')?a.contentDocument||a.contentWindow.document:jQuery.makeArray(a.childNodes)"},function(i,n){jQuery.fn[i]=function(a){var ret=jQuery.map(this,n);
+if(a&&typeof a=="string"){ret=jQuery.multiFilter(a,ret)
+}return this.pushStack(jQuery.unique(ret))
+}
+});
+jQuery.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(i,n){jQuery.fn[i]=function(){var a=arguments;
+return this.each(function(){for(var j=0,al=a.length;
+j<al;
+j++){jQuery(a[j])[n](this)
+}})
+}
+});
+jQuery.each({removeAttr:function(key){jQuery.attr(this,key,"");
+this.removeAttribute(key)
+},addClass:function(c){jQuery.className.add(this,c)
+},removeClass:function(c){jQuery.className.remove(this,c)
+},toggleClass:function(c){jQuery.className[jQuery.className.has(this,c)?"remove":"add"](this,c)
+},remove:function(a){if(!a||jQuery.filter(a,[this]).r.length){jQuery.removeData(this);
+this.parentNode.removeChild(this)
+}},empty:function(){jQuery("*",this).each(function(){jQuery.removeData(this)
+});
+while(this.firstChild){this.removeChild(this.firstChild)
+}}},function(i,n){jQuery.fn[i]=function(){return this.each(n,arguments)
+}
+});
+jQuery.each(["Height","Width"],function(i,name){var n=name.toLowerCase();
+jQuery.fn[n]=function(h){return this[0]==window?jQuery.browser.safari&&self["inner"+name]||jQuery.boxModel&&Math.max(document.documentElement["client"+name],document.body["client"+name])||document.body["client"+name]:this[0]==document?Math.max(document.body["scroll"+name],document.body["offset"+name]):h==undefined?(this.length?jQuery.css(this[0],n):null):this.css(n,h.constructor==String?h:h+"px")
+}
+});
+var chars=jQuery.browser.safari&&parseInt(jQuery.browser.version)<417?"(?:[\\w*_-]|\\\\.)":"(?:[\\w\u0128-\uFFFF*_-]|\\\\.)",quickChild=new RegExp("^>\\s*("+chars+"+)"),quickID=new RegExp("^("+chars+"+)(#)("+chars+"+)"),quickClass=new RegExp("^([#.]?)("+chars+"*)");
+jQuery.extend({expr:{"":"m[2]=='*'||jQuery.nodeName(a,m[2])","#":"a.getAttribute('id')==m[2]",":":{lt:"i<m[3]-0",gt:"i>m[3]-0",nth:"m[3]-0==i",eq:"m[3]-0==i",first:"i==0",last:"i==r.length-1",even:"i%2==0",odd:"i%2","first-child":"a.parentNode.getElementsByTagName('*')[0]==a","last-child":"jQuery.nth(a.parentNode.lastChild,1,'previousSibling')==a","only-child":"!jQuery.nth(a.parentNode.lastChild,2,'previousSibling')",parent:"a.firstChild",empty:"!a.firstChild",contains:"(a.textContent||a.innerText||jQuery(a).text()||'').indexOf(m[3])>=0",visible:'"hidden"!=a.type&&jQuery.css(a,"display")!="none"&&jQuery.css(a,"visibility")!="hidden"',hidden:'"hidden"==a.type||jQuery.css(a,"display")=="none"||jQuery.css(a,"visibility")=="hidden"',enabled:"!a.disabled",disabled:"a.disabled",checked:"a.checked",selected:"a.selected||jQuery.attr(a,'selected')",text:"'text'==a.type",radio:"'radio'==a.type",checkbox:"'checkbox'==a.type",file:"'file'==a.type",password:"'password'==a.type",submit:"!
 'submit'==a.type",image:"'image'==a.type",reset:"'reset'==a.type",button:'"button"==a.type||jQuery.nodeName(a,"button")',input:"/input|select|textarea|button/i.test(a.nodeName)",has:"jQuery.find(m[3],a).length",header:"/h\\d/i.test(a.nodeName)",animated:"jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length"}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?"?)(.*?)\4 *\]/,/^(:)([\w-]+)\("?'?(.*?(\(.*?\))?[^(]*?)"?'?\)/,new RegExp("^([:.#]*)("+chars+"+)")],multiFilter:function(expr,elems,not){var old,cur=[];
+while(expr&&expr!=old){old=expr;
+var f=jQuery.filter(expr,elems,not);
+expr=f.t.replace(/^\s*,\s*/,"");
+cur=not?elems=f.r:jQuery.merge(cur,f.r)
+}return cur
+},find:function(t,context){if(typeof t!="string"){return[t]
+}if(context&&!context.nodeType){context=null
+}context=context||document;
+var ret=[context],done=[],last;
+while(t&&last!=t){var r=[];
+last=t;
+t=jQuery.trim(t);
+var foundToken=false;
+var re=quickChild;
+var m=re.exec(t);
+if(m){var nodeName=m[1].toUpperCase();
+for(var i=0;
+ret[i];
+i++){for(var c=ret[i].firstChild;
+c;
+c=c.nextSibling){if(c.nodeType==1&&(nodeName=="*"||c.nodeName.toUpperCase()==nodeName.toUpperCase())){r.push(c)
+}}}ret=r;
+t=t.replace(re,"");
+if(t.indexOf(" ")==0){continue
+}foundToken=true
+}else{re=/^([>+~])\s*(\w*)/i;
+if((m=re.exec(t))!=null){r=[];
+var nodeName=m[2],merge={};
+m=m[1];
+for(var j=0,rl=ret.length;
+j<rl;
+j++){var n=m=="~"||m=="+"?ret[j].nextSibling:ret[j].firstChild;
+for(;
+n;
+n=n.nextSibling){if(n.nodeType==1){var id=jQuery.data(n);
+if(m=="~"&&merge[id]){break
+}if(!nodeName||n.nodeName.toUpperCase()==nodeName.toUpperCase()){if(m=="~"){merge[id]=true
+}r.push(n)
+}if(m=="+"){break
+}}}}ret=r;
+t=jQuery.trim(t.replace(re,""));
+foundToken=true
+}}if(t&&!foundToken){if(!t.indexOf(",")){if(context==ret[0]){ret.shift()
+}done=jQuery.merge(done,ret);
+r=ret=[context];
+t=" "+t.substr(1,t.length)
+}else{var re2=quickID;
+var m=re2.exec(t);
+if(m){m=[0,m[2],m[3],m[1]]
+}else{re2=quickClass;
+m=re2.exec(t)
+}m[2]=m[2].replace(/\\/g,"");
+var elem=ret[ret.length-1];
+if(m[1]=="#"&&elem&&elem.getElementById&&!jQuery.isXMLDoc(elem)){var oid=elem.getElementById(m[2]);
+if((jQuery.browser.msie||jQuery.browser.opera)&&oid&&typeof oid.id=="string"&&oid.id!=m[2]){oid=jQuery('[@id="'+m[2]+'"]',elem)[0]
+}ret=r=oid&&(!m[3]||jQuery.nodeName(oid,m[3]))?[oid]:[]
+}else{for(var i=0;
+ret[i];
+i++){var tag=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];
+if(tag=="*"&&ret[i].nodeName.toLowerCase()=="object"){tag="param"
+}r=jQuery.merge(r,ret[i].getElementsByTagName(tag))
+}if(m[1]=="."){r=jQuery.classFilter(r,m[2])
+}if(m[1]=="#"){var tmp=[];
+for(var i=0;
+r[i];
+i++){if(r[i].getAttribute("id")==m[2]){tmp=[r[i]];
+break
+}}r=tmp
+}ret=r
+}t=t.replace(re2,"")
+}}if(t){var val=jQuery.filter(t,r);
+ret=r=val.r;
+t=jQuery.trim(val.t)
+}}if(t){ret=[]
+}if(ret&&context==ret[0]){ret.shift()
+}done=jQuery.merge(done,ret);
+return done
+},classFilter:function(r,m,not){m=" "+m+" ";
+var tmp=[];
+for(var i=0;
+r[i];
+i++){var pass=(" "+r[i].className+" ").indexOf(m)>=0;
+if(!not&&pass||not&&!pass){tmp.push(r[i])
+}}return tmp
+},filter:function(t,r,not){var last;
+while(t&&t!=last){last=t;
+var p=jQuery.parse,m;
+for(var i=0;
+p[i];
+i++){m=p[i].exec(t);
+if(m){t=t.substring(m[0].length);
+m[2]=m[2].replace(/\\/g,"");
+break
+}}if(!m){break
+}if(m[1]==":"&&m[2]=="not"){r=jQuery.filter(m[3],r,true).r
+}else{if(m[1]=="."){r=jQuery.classFilter(r,m[2],not)
+}else{if(m[1]=="["){var tmp=[],type=m[3];
+for(var i=0,rl=r.length;
+i<rl;
+i++){var a=r[i],z=a[jQuery.props[m[2]]||m[2]];
+if(z==null||/href|src|selected/.test(m[2])){z=jQuery.attr(a,m[2])||""
+}if((type==""&&!!z||type=="="&&z==m[5]||type=="!="&&z!=m[5]||type=="^="&&z&&!z.indexOf(m[5])||type=="$="&&z.substr(z.length-m[5].length)==m[5]||(type=="*="||type=="~=")&&z.indexOf(m[5])>=0)^not){tmp.push(a)
+}}r=tmp
+}else{if(m[1]==":"&&m[2]=="nth-child"){var merge={},tmp=[],test=/(\d*)n\+?(\d*)/.exec(m[3]=="even"&&"2n"||m[3]=="odd"&&"2n+1"||!/\D/.test(m[3])&&"n+"+m[3]||m[3]),first=(test[1]||1)-0,last=test[2]-0;
+for(var i=0,rl=r.length;
+i<rl;
+i++){var node=r[i],parentNode=node.parentNode,id=jQuery.data(parentNode);
+if(!merge[id]){var c=1;
+for(var n=parentNode.firstChild;
+n;
+n=n.nextSibling){if(n.nodeType==1){n.nodeIndex=c++
+}}merge[id]=true
+}var add=false;
+if(first==1){if(last==0||node.nodeIndex==last){add=true
+}}else{if((node.nodeIndex+last)%first==0){add=true
+}}if(add^not){tmp.push(node)
+}}r=tmp
+}else{var f=jQuery.expr[m[1]];
+if(typeof f!="string"){f=jQuery.expr[m[1]][m[2]]
+}f=eval("false||function(a,i){return "+f+"}");
+r=jQuery.grep(r,f,not)
+}}}}}return{r:r,t:t}
+},dir:function(elem,dir){var matched=[];
+var cur=elem[dir];
+while(cur&&cur!=document){if(cur.nodeType==1){matched.push(cur)
+}cur=cur[dir]
+}return matched
+},nth:function(cur,result,dir,elem){result=result||1;
+var num=0;
+for(;
+cur;
+cur=cur[dir]){if(cur.nodeType==1&&++num==result){break
+}}return cur
+},sibling:function(n,elem){var r=[];
+for(;
+n;
+n=n.nextSibling){if(n.nodeType==1&&(!elem||n!=elem)){r.push(n)
+}}return r
+}});
+jQuery.event={add:function(element,type,handler,data){if(jQuery.browser.msie&&element.setInterval!=undefined){element=window
+}if(!handler.guid){handler.guid=this.guid++
+}if(data!=undefined){var fn=handler;
+handler=function(){return fn.apply(this,arguments)
+};
+handler.data=data;
+handler.guid=fn.guid
+}var parts=type.split(".");
+type=parts[0];
+handler.type=parts[1];
+var events=jQuery.data(element,"events")||jQuery.data(element,"events",{});
+var handle=jQuery.data(element,"handle",function(){var val;
+if(typeof jQuery=="undefined"||jQuery.event.triggered){return val
+}val=jQuery.event.handle.apply(element,arguments);
+return val
+});
+var handlers=events[type];
+if(!handlers){handlers=events[type]={};
+if(element.addEventListener){element.addEventListener(type,handle,false)
+}else{element.attachEvent("on"+type,handle)
+}}handlers[handler.guid]=handler;
+this.global[type]=true
+},guid:1,global:{},remove:function(element,type,handler){var events=jQuery.data(element,"events"),ret,index;
+if(typeof type=="string"){var parts=type.split(".");
+type=parts[0]
+}if(events){if(type&&type.type){handler=type.handler;
+type=type.type
+}if(!type){for(type in events){this.remove(element,type)
+}}else{if(events[type]){if(handler){delete events[type][handler.guid]
+}else{for(handler in events[type]){if(!parts[1]||events[type][handler].type==parts[1]){delete events[type][handler]
+}}}for(ret in events[type]){break
+}if(!ret){if(element.removeEventListener){element.removeEventListener(type,jQuery.data(element,"handle"),false)
+}else{element.detachEvent("on"+type,jQuery.data(element,"handle"))
+}ret=null;
+delete events[type]
+}}}for(ret in events){break
+}if(!ret){jQuery.removeData(element,"events");
+jQuery.removeData(element,"handle")
+}}},trigger:function(type,data,element,donative,extra){data=jQuery.makeArray(data||[]);
+if(!element){if(this.global[type]){jQuery("*").add([window,document]).trigger(type,data)
+}}else{var val,ret,fn=jQuery.isFunction(element[type]||null),evt=!data[0]||!data[0].preventDefault;
+if(evt){data.unshift(this.fix({type:type,target:element}))
+}data[0].type=type;
+if(jQuery.isFunction(jQuery.data(element,"handle"))){val=jQuery.data(element,"handle").apply(element,data)
+}if(!fn&&element["on"+type]&&element["on"+type].apply(element,data)===false){val=false
+}if(evt){data.shift()
+}if(extra&&extra.apply(element,data)===false){val=false
+}if(fn&&donative!==false&&val!==false&&!(jQuery.nodeName(element,"a")&&type=="click")){this.triggered=true;
+element[type]()
+}this.triggered=false
+}return val
+},handle:function(event){var val;
+event=jQuery.event.fix(event||window.event||{});
+var parts=event.type.split(".");
+event.type=parts[0];
+var c=jQuery.data(this,"events")&&jQuery.data(this,"events")[event.type],args=Array.prototype.slice.call(arguments,1);
+args.unshift(event);
+for(var j in c){args[0].handler=c[j];
+args[0].data=c[j].data;
+if(!parts[1]||c[j].type==parts[1]){var tmp=c[j].apply(this,args);
+if(val!==false){val=tmp
+}if(tmp===false){event.preventDefault();
+event.stopPropagation()
+}}}if(jQuery.browser.msie){event.target=event.preventDefault=event.stopPropagation=event.handler=event.data=null
+}return val
+},fix:function(event){var originalEvent=event;
+event=jQuery.extend({},originalEvent);
+event.preventDefault=function(){if(originalEvent.preventDefault){originalEvent.preventDefault()
+}originalEvent.returnValue=false
+};
+event.stopPropagation=function(){if(originalEvent.stopPropagation){originalEvent.stopPropagation()
+}originalEvent.cancelBubble=true
+};
+if(!event.target&&event.srcElement){event.target=event.srcElement
+}if(jQuery.browser.safari&&event.target.nodeType==3){event.target=originalEvent.target.parentNode
+}if(!event.relatedTarget&&event.fromElement){event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement
+}if(event.pageX==null&&event.clientX!=null){var e=document.documentElement,b=document.body;
+event.pageX=event.clientX+(e&&e.scrollLeft||b.scrollLeft||0);
+event.pageY=event.clientY+(e&&e.scrollTop||b.scrollTop||0)
+}if(!event.which&&(event.charCode||event.keyCode)){event.which=event.charCode||event.keyCode
+}if(!event.metaKey&&event.ctrlKey){event.metaKey=event.ctrlKey
+}if(!event.which&&event.button){event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)))
+}return event
+}};
+jQuery.fn.extend({bind:function(type,data,fn){return type=="unload"?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data)
+})
+},one:function(type,data,fn){return this.each(function(){jQuery.event.add(this,type,function(event){jQuery(this).unbind(event);
+return(fn||data).apply(this,arguments)
+},fn&&data)
+})
+},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn)
+})
+},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn)
+})
+},triggerHandler:function(type,data,fn){if(this[0]){return jQuery.event.trigger(type,data,this[0],false,fn)
+}},toggle:function(){var a=arguments;
+return this.click(function(e){this.lastToggle=0==this.lastToggle?1:0;
+e.preventDefault();
+return a[this.lastToggle].apply(this,[e])||false
+})
+},hover:function(f,g){function handleHover(e){var p=e.relatedTarget;
+while(p&&p!=this){try{p=p.parentNode
+}catch(e){p=this
+}}if(p==this){return false
+}return(e.type=="mouseover"?f:g).apply(this,[e])
+}return this.mouseover(handleHover).mouseout(handleHover)
+},ready:function(f){bindReady();
+if(jQuery.isReady){f.apply(document,[jQuery])
+}else{jQuery.readyList.push(function(){return f.apply(this,[jQuery])
+})
+}return this
+}});
+jQuery.extend({isReady:false,readyList:[],ready:function(){if(!jQuery.isReady){jQuery.isReady=true;
+if(jQuery.readyList){jQuery.each(jQuery.readyList,function(){this.apply(document)
+});
+jQuery.readyList=null
+}if(jQuery.browser.mozilla||jQuery.browser.opera){document.removeEventListener("DOMContentLoaded",jQuery.ready,false)
+}if(!window.frames.length){jQuery(window).load(function(){jQuery("#__ie_init").remove()
+})
+}}}});
+jQuery.each(("blur,focus,load,resize,scroll,unload,click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,change,select,submit,keydown,keypress,keyup,error").split(","),function(i,o){jQuery.fn[o]=function(f){return f?this.bind(o,f):this.trigger(o)
+}
+});
+var readyBound=false;
+function bindReady(){if(readyBound){return 
+}readyBound=true;
+if(jQuery.browser.mozilla||jQuery.browser.opera){document.addEventListener("DOMContentLoaded",jQuery.ready,false)
+}else{if(jQuery.browser.msie){document.write("<script id=__ie_init defer=true src=//:><\/script>");
+var script=document.getElementById("__ie_init");
+if(script){script.onreadystatechange=function(){if(this.readyState!="complete"){return 
+}jQuery.ready()
+}
+}script=null
+}else{if(jQuery.browser.safari){jQuery.safariTimer=setInterval(function(){if(document.readyState=="loaded"||document.readyState=="complete"){clearInterval(jQuery.safariTimer);
+jQuery.safariTimer=null;
+jQuery.ready()
+}},10)
+}}}jQuery.event.add(window,"load",jQuery.ready)
+}jQuery.fn.extend({load:function(url,params,callback){if(jQuery.isFunction(url)){return this.bind("load",url)
+}var off=url.indexOf(" ");
+if(off>=0){var selector=url.slice(off,url.length);
+url=url.slice(0,off)
+}callback=callback||function(){};
+var type="GET";
+if(params){if(jQuery.isFunction(params)){callback=params;
+params=null
+}else{params=jQuery.param(params);
+type="POST"
+}}var self=this;
+jQuery.ajax({url:url,type:type,data:params,complete:function(res,status){if(status=="success"||status=="notmodified"){self.html(selector?jQuery("<div/>").append(res.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(selector):res.responseText)
+}setTimeout(function(){self.each(callback,[res.responseText,status,res])
+},13)
+}});
+return this
+},serialize:function(){return jQuery.param(this.serializeArray())
+},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,"form")?jQuery.makeArray(this.elements):this
+}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type))
+}).map(function(i,elem){var val=jQuery(this).val();
+return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val}
+}):{name:elem.name,value:val}
+}).get()
+}});
+jQuery.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f)
+}
+});
+var jsc=(new Date).getTime();
+jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;
+data=null
+}return jQuery.ajax({type:"GET",url:url,data:data,success:callback,dataType:type})
+},getScript:function(url,callback){return jQuery.get(url,null,callback,"script")
+},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,"json")
+},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;
+data={}
+}return jQuery.ajax({type:"POST",url:url,data:data,success:callback,dataType:type})
+},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings)
+},ajaxSettings:{global:true,type:"GET",timeout:0,contentType:"application/x-www-form-urlencoded",processData:true,async:true,data:null},lastModified:{},ajax:function(s){var jsonp,jsre=/=(\?|%3F)/g,status,data;
+s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));
+if(s.data&&s.processData&&typeof s.data!="string"){s.data=jQuery.param(s.data)
+}if(s.dataType=="jsonp"){if(s.type.toLowerCase()=="get"){if(!s.url.match(jsre)){s.url+=(s.url.match(/\?/)?"&":"?")+(s.jsonp||"callback")+"=?"
+}}else{if(!s.data||!s.data.match(jsre)){s.data=(s.data?s.data+"&":"")+(s.jsonp||"callback")+"=?"
+}}s.dataType="json"
+}if(s.dataType=="json"&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp="jsonp"+jsc++;
+if(s.data){s.data=s.data.replace(jsre,"="+jsonp)
+}s.url=s.url.replace(jsre,"="+jsonp);
+s.dataType="script";
+window[jsonp]=function(tmp){data=tmp;
+success();
+complete();
+window[jsonp]=undefined;
+try{delete window[jsonp]
+}catch(e){}}
+}if(s.dataType=="script"&&s.cache==null){s.cache=false
+}if(s.cache===false&&s.type.toLowerCase()=="get"){s.url+=(s.url.match(/\?/)?"&":"?")+"_="+(new Date()).getTime()
+}if(s.data&&s.type.toLowerCase()=="get"){s.url+=(s.url.match(/\?/)?"&":"?")+s.data;
+s.data=null
+}if(s.global&&!jQuery.active++){jQuery.event.trigger("ajaxStart")
+}if(!s.url.indexOf("http")&&s.dataType=="script"){var head=document.getElementsByTagName("head")[0];
+var script=document.createElement("script");
+script.src=s.url;
+if(!jsonp&&(s.success||s.complete)){var done=false;
+script.onload=script.onreadystatechange=function(){if(!done&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){done=true;
+success();
+complete();
+head.removeChild(script)
+}}
+}head.appendChild(script);
+return 
+}var requestDone=false;
+var xml=window.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest();
+xml.open(s.type,s.url,s.async);
+if(s.data){xml.setRequestHeader("Content-Type",s.contentType)
+}if(s.ifModified){xml.setRequestHeader("If-Modified-Since",jQuery.lastModified[s.url]||"Thu, 01 Jan 1970 00:00:00 GMT")
+}xml.setRequestHeader("X-Requested-With","XMLHttpRequest");
+if(s.beforeSend){s.beforeSend(xml)
+}if(s.global){jQuery.event.trigger("ajaxSend",[xml,s])
+}var onreadystatechange=function(isTimeout){if(!requestDone&&xml&&(xml.readyState==4||isTimeout=="timeout")){requestDone=true;
+if(ival){clearInterval(ival);
+ival=null
+}status=isTimeout=="timeout"&&"timeout"||!jQuery.httpSuccess(xml)&&"error"||s.ifModified&&jQuery.httpNotModified(xml,s.url)&&"notmodified"||"success";
+if(status=="success"){try{data=jQuery.httpData(xml,s.dataType)
+}catch(e){status="parsererror"
+}}if(status=="success"){var modRes;
+try{modRes=xml.getResponseHeader("Last-Modified")
+}catch(e){}if(s.ifModified&&modRes){jQuery.lastModified[s.url]=modRes
+}if(!jsonp){success()
+}}else{jQuery.handleError(s,xml,status)
+}complete();
+if(s.async){xml=null
+}}};
+if(s.async){var ival=setInterval(onreadystatechange,13);
+if(s.timeout>0){setTimeout(function(){if(xml){xml.abort();
+if(!requestDone){onreadystatechange("timeout")
+}}},s.timeout)
+}}try{xml.send(s.data)
+}catch(e){jQuery.handleError(s,xml,null,e)
+}if(!s.async){onreadystatechange()
+}return xml;
+function success(){if(s.success){s.success(data,status)
+}if(s.global){jQuery.event.trigger("ajaxSuccess",[xml,s])
+}}function complete(){if(s.complete){s.complete(xml,status)
+}if(s.global){jQuery.event.trigger("ajaxComplete",[xml,s])
+}if(s.global&&!--jQuery.active){jQuery.event.trigger("ajaxStop")
+}}},handleError:function(s,xml,status,e){if(s.error){s.error(xml,status,e)
+}if(s.global){jQuery.event.trigger("ajaxError",[xml,s,e])
+}},active:0,httpSuccess:function(r){try{return !r.status&&location.protocol=="file:"||(r.status>=200&&r.status<300)||r.status==304||jQuery.browser.safari&&r.status==undefined
+}catch(e){}return false
+},httpNotModified:function(xml,url){try{var xmlRes=xml.getResponseHeader("Last-Modified");
+return xml.status==304||xmlRes==jQuery.lastModified[url]||jQuery.browser.safari&&xml.status==undefined
+}catch(e){}return false
+},httpData:function(r,type){var ct=r.getResponseHeader("content-type");
+var xml=type=="xml"||!type&&ct&&ct.indexOf("xml")>=0;
+var data=xml?r.responseXML:r.responseText;
+if(xml&&data.documentElement.tagName=="parsererror"){throw"parsererror"
+}if(type=="script"){jQuery.globalEval(data)
+}if(type=="json"){data=eval("("+data+")")
+}return data
+},param:function(a){var s=[];
+if(a.constructor==Array||a.jquery){jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+"="+encodeURIComponent(this.value))
+})
+}else{for(var j in a){if(a[j]&&a[j].constructor==Array){jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+"="+encodeURIComponent(this))
+})
+}else{s.push(encodeURIComponent(j)+"="+encodeURIComponent(a[j]))
+}}}return s.join("&").replace(/%20/g,"+")
+}});
+jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:"show",width:"show",opacity:"show"},speed,callback):this.filter(":hidden").each(function(){this.style.display=this.oldblock?this.oldblock:"";
+if(jQuery.css(this,"display")=="none"){this.style.display="block"
+}}).end()
+},hide:function(speed,callback){return speed?this.animate({height:"hide",width:"hide",opacity:"hide"},speed,callback):this.filter(":visible").each(function(){this.oldblock=this.oldblock||jQuery.css(this,"display");
+if(this.oldblock=="none"){this.oldblock="block"
+}this.style.display="none"
+}).end()
+},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle(fn,fn2):fn?this.animate({height:"toggle",width:"toggle",opacity:"toggle"},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(":hidden")?"show":"hide"]()
+})
+},slideDown:function(speed,callback){return this.animate({height:"show"},speed,callback)
+},slideUp:function(speed,callback){return this.animate({height:"hide"},speed,callback)
+},slideToggle:function(speed,callback){return this.animate({height:"toggle"},speed,callback)
+},fadeIn:function(speed,callback){return this.animate({opacity:"show"},speed,callback)
+},fadeOut:function(speed,callback){return this.animate({opacity:"hide"},speed,callback)
+},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback)
+},animate:function(prop,speed,easing,callback){var opt=jQuery.speed(speed,easing,callback);
+return this[opt.queue===false?"each":"queue"](function(){opt=jQuery.extend({},opt);
+var hidden=jQuery(this).is(":hidden"),self=this;
+for(var p in prop){if(prop[p]=="hide"&&hidden||prop[p]=="show"&&!hidden){return jQuery.isFunction(opt.complete)&&opt.complete.apply(this)
+}if(p=="height"||p=="width"){opt.display=jQuery.css(this,"display");
+opt.overflow=this.style.overflow
+}}if(opt.overflow!=null){this.style.overflow="hidden"
+}opt.curAnim=jQuery.extend({},prop);
+jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);
+if(/toggle|show|hide/.test(val)){e[val=="toggle"?hidden?"show":"hide":val](prop)
+}else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;
+if(parts){var end=parseFloat(parts[2]),unit=parts[3]||"px";
+if(unit!="px"){self.style[name]=(end||1)+unit;
+start=((end||1)/e.cur(true))*start;
+self.style[name]=start+unit
+}if(parts[1]){end=((parts[1]=="-="?-1:1)*end)+start
+}e.custom(start,end,unit)
+}else{e.custom(start,val,"")
+}}});
+return true
+})
+},queue:function(type,fn){if(jQuery.isFunction(type)){fn=type;
+type="fx"
+}if(!type||(typeof type=="string"&&!fn)){return queue(this[0],type)
+}return this.each(function(){if(fn.constructor==Array){queue(this,type,fn)
+}else{queue(this,type).push(fn);
+if(queue(this,type).length==1){fn.apply(this)
+}}})
+},stop:function(){var timers=jQuery.timers;
+return this.each(function(){for(var i=0;
+i<timers.length;
+i++){if(timers[i].elem==this){timers.splice(i--,1)
+}}}).dequeue()
+}});
+var queue=function(elem,type,array){if(!elem){return 
+}var q=jQuery.data(elem,type+"queue");
+if(!q||array){q=jQuery.data(elem,type+"queue",array?jQuery.makeArray(array):[])
+}return q
+};
+jQuery.fn.dequeue=function(type){type=type||"fx";
+return this.each(function(){var q=queue(this,type);
+q.shift();
+if(q.length){q[0].apply(this)
+}})
+};
+jQuery.extend({speed:function(speed,easing,fn){var opt=speed&&speed.constructor==Object?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&easing.constructor!=Function&&easing};
+opt.duration=(opt.duration&&opt.duration.constructor==Number?opt.duration:{slow:600,fast:200}[opt.duration])||400;
+opt.old=opt.complete;
+opt.complete=function(){jQuery(this).dequeue();
+if(jQuery.isFunction(opt.old)){opt.old.apply(this)
+}};
+return opt
+},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p
+},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum
+}},timers:[],fx:function(elem,options,prop){this.options=options;
+this.elem=elem;
+this.prop=prop;
+if(!options.orig){options.orig={}
+}}});
+jQuery.fx.prototype={update:function(){if(this.options.step){this.options.step.apply(this.elem,[this.now,this])
+}(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);
+if(this.prop=="height"||this.prop=="width"){this.elem.style.display="block"
+}},cur:function(force){if(this.elem[this.prop]!=null&&this.elem.style[this.prop]==null){return this.elem[this.prop]
+}var r=parseFloat(jQuery.curCSS(this.elem,this.prop,force));
+return r&&r>-10000?r:parseFloat(jQuery.css(this.elem,this.prop))||0
+},custom:function(from,to,unit){this.startTime=(new Date()).getTime();
+this.start=from;
+this.end=to;
+this.unit=unit||this.unit||"px";
+this.now=this.start;
+this.pos=this.state=0;
+this.update();
+var self=this;
+function t(){return self.step()
+}t.elem=this.elem;
+jQuery.timers.push(t);
+if(jQuery.timers.length==1){var timer=setInterval(function(){var timers=jQuery.timers;
+for(var i=0;
+i<timers.length;
+i++){if(!timers[i]()){timers.splice(i--,1)
+}}if(!timers.length){clearInterval(timer)
+}},13)
+}},show:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);
+this.options.show=true;
+this.custom(0,this.cur());
+if(this.prop=="width"||this.prop=="height"){this.elem.style[this.prop]="1px"
+}jQuery(this.elem).show()
+},hide:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);
+this.options.hide=true;
+this.custom(this.cur(),0)
+},step:function(){var t=(new Date()).getTime();
+if(t>this.options.duration+this.startTime){this.now=this.end;
+this.pos=this.state=1;
+this.update();
+this.options.curAnim[this.prop]=true;
+var done=true;
+for(var i in this.options.curAnim){if(this.options.curAnim[i]!==true){done=false
+}}if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;
+this.elem.style.display=this.options.display;
+if(jQuery.css(this.elem,"display")=="none"){this.elem.style.display="block"
+}}if(this.options.hide){this.elem.style.display="none"
+}if(this.options.hide||this.options.show){for(var p in this.options.curAnim){jQuery.attr(this.elem.style,p,this.options.orig[p])
+}}}if(done&&jQuery.isFunction(this.options.complete)){this.options.complete.apply(this.elem)
+}return false
+}else{var n=t-this.startTime;
+this.state=n/this.options.duration;
+this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?"swing":"linear")](this.state,n,0,1,this.options.duration);
+this.now=this.start+((this.end-this.start)*this.pos);
+this.update()
+}return true
+}};
+jQuery.fx.step={scrollLeft:function(fx){fx.elem.scrollLeft=fx.now
+},scrollTop:function(fx){fx.elem.scrollTop=fx.now
+},opacity:function(fx){jQuery.attr(fx.elem.style,"opacity",fx.now)
+},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit
+}};
+jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;
+if(elem){with(jQuery.browser){var absolute=jQuery.css(elem,"position")=="absolute",parent=elem.parentNode,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&&parseInt(version)<522;
+if(elem.getBoundingClientRect){box=elem.getBoundingClientRect();
+add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));
+if(msie){var border=jQuery("html").css("borderWidth");
+border=(border=="medium"||jQuery.boxModel&&parseInt(version)>=7)&&2||border;
+add(-border,-border)
+}}else{add(elem.offsetLeft,elem.offsetTop);
+while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);
+if(mozilla&&/^t[d|h]$/i.test(parent.tagName)||!safari2){border(offsetParent)
+}if(safari2&&!absolute&&jQuery.css(offsetParent,"position")=="absolute"){absolute=true
+}offsetParent=offsetParent.offsetParent
+}while(parent.tagName&&!/^body|html$/i.test(parent.tagName)){if(!/^inline|table-row.*$/i.test(jQuery.css(parent,"display"))){add(-parent.scrollLeft,-parent.scrollTop)
+}if(mozilla&&jQuery.css(parent,"overflow")!="visible"){border(parent)
+}parent=parent.parentNode
+}if(safari2&&absolute){add(-doc.body.offsetLeft,-doc.body.offsetTop)
+}}results={top:top,left:left}
+}}return results;
+function border(elem){add(jQuery.css(elem,"borderLeftWidth"),jQuery.css(elem,"borderTopWidth"))
+}function add(l,t){left+=parseInt(l)||0;
+top+=parseInt(t)||0
+}}
+})();
+jQuery.noConflict();
+if(jQuery(jQuery)!=jQuery){var oldJQuery=jQuery;
+jQuery=function(){if(arguments[0]==arguments.callee){return arguments.callee
+}else{return oldJQuery.apply(this,arguments)
+}}
+}
+var DnD={CODE_ACCEPT:"accept",CODE_DEFAULT:"default",CODE_REJECT:"reject",startDrag:function(A){if(!window.drag){this.init();
+window.drag=A;
+Event.observe(document,"mousemove",this.mousemove);
+Event.observe(document,"mouseup",this.mouseup)
+}else{alert("drag in progress")
+}},endDrag:function(C){Event.stopObserving(document,"mousemove",this.mousemove);
+Event.stopObserving(document,"mouseup",this.mouseup);
+var B=window.drag;
+if(B){window.drag=null;
+var A=B.dropzone;
+B.source.endDrag(C,B);
+if(A){A.onbeforedrag(C,B);
+if(A.accept(B)){A.drop(C,B)
+}A.onafterdrag(C)
+}}},updateDrag:function(C){var B=window.drag;
+if(!B.source.onupdatedrag||(B.source.onupdatedrag(C)!=false)){var A=Event.pointerX(C);
+var D=Event.pointerY(C);
+B.indicator.position(A+5,D+14);
+Event.stop(C)
+}},initialized:false,init:function(){if(!this.initialized){this.mousemove=this.updateDrag.bindAsEventListener(this);
+this.mouseup=this.endDrag.bindAsEventListener(this);
+this.initialized=true
+}}};
+DnD.Drag=Class.create();
+DnD.Drag.prototype={initialize:function(C,A,B){this.source=C;
+this.indicator=A;
+this.type=B
+},params:{},dragged:false,dropzone:null,getParameters:function(){var A={};
+Object.extend(A,this.params);
+return A
+}}
+
+DnD.getDnDDefaultParams=function(B){var A=Richfaces.getNSAttribute("defaultdndparams",B);
+if(A){var C=A.parseJSON(EventHandlersWalk);
+if(C){return C
+}}return{}
+};
+DnD.getDnDMergedParams=function(C,B){var E=DnD.getDnDDefaultParams(C);
+var A=Richfaces.getNSAttribute(B,C);
+if(A){var D=A.parseJSON(EventHandlersWalk);
+if(E){if(D){Object.extend(E,D)
+}}else{E=D
+}}return E
+};
+DnD.getDnDDragParams=function(A){return DnD.getDnDMergedParams(A,"dragdndparams")
+};
+DnD.getDnDDropParams=function(A){return DnD.getDnDMergedParams(A,"dropdndparams")
+};
+DnD.setDefaultDnDParams=function(B){if(B){if(drag&&drag.source&&drag.source.getDraggableItems&&drag.source.getDraggableItems()>1){var A=drag.source.getDraggableItems();
+B["count"]=A;
+if(!B["label"]){B["label"]=B["count"]+" "+(B["units"]?B["units"]:"items")
+}}}}
+
+DnD.Draggable=function(){};
+DnD.ieReleaseCapture=function(){if(document.releaseCapture){document.releaseCapture()
+}};
+DnD.DragEndListener=Class.create();
+DnD.DragEndListener.prototype={initialize:function(A){this.callback=A;
+this.onmoveBound=this.onmove.bindAsEventListener(this);
+this.onupBound=this.onup.bindAsEventListener(this)
+},activate:function(A){Event.observe(document,"mousemove",this.onmoveBound);
+Event.observe(document,"mouseup",this.onupBound);
+if(A.type=="mousemove"){this.onmoveBound(A)
+}},onmove:function(A){if("mousemove"==A.type){if(!this.mouseMoveProvidesButtonChecked){this.mouseMoveProvidesButtonChecked=true;
+if(!this.mouseMoveProvidesButton){this.mouseMoveProvidesButton=A.button!=0
+}}if(this.mouseMoveProvidesButton&&!Event.isLeftClick(A)&&RichFaces.getIEVersion()!=6){this.endDrag(A)
+}}},onup:function(A){this.endDrag(A)
+},endDrag:function(A){this.deactivate();
+this.callback(A)
+},deactivate:function(){Event.stopObserving(document,"mousemove",this.onmoveBound);
+Event.stopObserving(document,"mouseup",this.onupBound)
+}};
+DnD.Cursor=Class.create();
+DnD.Cursor.prototype={initialize:function(A,B){this.element=A;
+this.cursor=B;
+this.visible=false;
+if(this.element.style.cursor&&this.element.style.cursor!=""){this.oldcursor=this.element.style.cursor
+}},showCursor:function(){var A=this.element;
+this.element.style.cursor=this.cursor;
+this.visible=true
+},hideCursor:function(){var A=this.element;
+A.style.cursor="";
+this.visible=false;
+if(this.oldcursor){this.element.style.cursor=this.oldcursor
+}}};
+DnD.Draggable.prototype={getElement:function(){return $(this.id)
+},getDraggableOptions:function(){return null
+},getDnDDefaultParams:function(){return DnD.getDnDDefaultParams(this.getElement())
+},getDnDDragParams:function(){return DnD.getDnDDragParams(this.getElement())
+},getContentType:function(){return null
+},getIndicator:function(){return null
+},getOrCreateDefaultIndicator:function(){var A=$("_rfDefaultDragIndicator");
+if(!A){A=document.createElement("div");
+A.id="_rfDefaultDragIndicatorLeft";
+document.body.appendChild(A);
+A=document.createElement("div");
+A.id="_rfDefaultDragIndicatorRight";
+document.body.appendChild(A);
+A=document.createElement("div");
+A.id="_rfDefaultDragIndicatorBottom";
+Element.setStyle(A,{"font-size":"0px"});
+document.body.appendChild(A);
+A=document.createElement("div");
+A.id="_rfDefaultDragIndicator";
+Element.setStyle(A,{"font-size":"0px"});
+Object.extend(A,DefaultDragIndicator);
+document.body.appendChild(A)
+}DefaultDragIndicator.changeIndicatorColor(A,"black");
+return A
+},setIndicator:function(C){var A=this.getIndicator();
+if(A){var B=this.getDnDDragParams();
+DnD.setDefaultDnDParams(B);
+if(this.getDraggableItems&&this.getDraggableItems()>1){A.setContent("default",false,B)
+}else{A.setContent("default",true,B)
+}}},moveDrag:function(B){var A=Event.pointerX(B);
+var C=Event.pointerY(B);
+if(!window.drag&&(Math.abs(this.lastDragX-A)+Math.abs(this.lastDragY-C))>2){this.updateDrag(B)
+}},startDrag:function(A){var B=this.getContentType();
+if(this.grabbingCursor){if(this.grabCursor&&this.grabCursor.visible){this.grabCursor.hideCursor()
+}this.grabbingCursor.showCursor()
+}if(B){if(!this.endDragListener){this.dragTrigger=this.moveDrag.bindAsEventListener(this);
+this.endDragListener=new DnD.DragEndListener(function(C){Event.stopObserving(document,"mousemove",this.dragTrigger);
+DnD.endDrag(C,window.drag)
+}.bind(this))
+}this.endDragListener.activate(A);
+Event.observe(document,"mousemove",this.dragTrigger);
+this.lastDragX=Event.pointerX(A);
+this.lastDragY=Event.pointerY(A);
+this.onSelectStartHandler=document.onselectstart;
+this.onDragStartHandler=document.ondragstart;
+document.onselectstart=function(){return false
+};
+document.ondragstart=function(){DnD.ieReleaseCapture();
+return false
+};
+if(document.releaseCapture){Event.observe(document,"mousemove",DnD.ieReleaseCapture)
+}}},updateDrag:function(F){var E=this.getContentType();
+var A=this.getIndicator();
+var D=new DnD.Drag(this,A,E);
+if(A.id.indexOf("_rfDefaultDragIndicator")!=-1){var G=D.source.getElement();
+var C=Position.cumulativeOffset(G);
+A.indicatorWidth=Element.getWidth(G);
+A.indicatorHeight=Element.getHeight(G);
+A.position(C[0],C[1]);
+A.removalX=Event.pointerX(F)-C[0];
+A.removalY=Event.pointerY(F)-C[1]
+}DnD.startDrag(D);
+DnD.updateDrag(F);
+this.ondragstart(F,D);
+if(A){A.show()
+}var B=this.getDraggableOptions();
+if(B&&B.ondragstart){B.ondragstart(F)
+}},endDrag:function(E,D){DnD.endDrag(E);
+this.lastDragX=undefined;
+this.lastDragY=undefined;
+document.onselectstart=this.onSelectStartHandler;
+document.ondragstart=this.onDragStartHandler;
+if(document.releaseCapture){Event.stopObserving(document,"mousemove",DnD.ieReleaseCapture)
+}if(this.endDragListener){this.endDragListener.deactivate()
+}if(D){var A=D.indicator;
+if(A){A.hide()
+}this.ondragend(E,D)
+}var C=this.getCurrentGrabbingCursor();
+if(C){if(C.visible){C.hideCursor()
+}}var B=this.getDraggableOptions();
+if(B&&B.ondragend){B.ondragend(E)
+}},attachCursor:function(){this.cursor=new DnD.Cursor()
+},ondragstart:function(B,A){},ondragend:function(B,A){},ondragover:function(B){var A=this.getCurrentGrabCursor();
+if(!document.body.style.cursor){if(A){if(!A.visible){A.showCursor()
+}}}},ondragout:function(B){var A=this.getCurrentGrabCursor();
+if(A){if(A.visible){A.hideCursor()
+}}},getCurrentGrabbingCursor:function(){var B=window.drag;
+var A=this.grabbingCursor;
+if(B){A=B.source.grabbingCursor
+}return A
+},getCurrentGrabCursor:function(){var B=window.drag;
+var A=this.grabCursor;
+if(B){A=B.source.grabCursor
+}return A
+},onmouseup:function(C){var B=this.getCurrentGrabbingCursor();
+var A=this.grabCursor;
+if(B&&B.visible){B.hideCursor()
+}if(A){A.showCursor()
+}},ondropover:function(C,B){var A=this.getDraggableOptions();
+if(A&&A.ondropover){C.drag=B;
+A.ondropover(C)
+}},ondropout:function(C,B){var A=this.getDraggableOptions();
+if(A&&A.ondropout){C.drag=B;
+A.ondropout(C)
+}},enableDraggableCursors:function(A,B){var C=this.getElement();
+if(A){this.dragOutBound=this.ondragout.bindAsEventListener(this);
+this.dragOverBound=this.ondragover.bindAsEventListener(this);
+this.dragUpBound=this.onmouseup.bindAsEventListener(this);
+Event.observe(C,"mouseout",this.dragOutBound);
+Event.observe(C,"mouseover",this.dragOverBound);
+Event.observe(C,"mouseup",this.dragUpBound);
+this.grabCursor=new DnD.Cursor(C,A)
+}if(B){this.grabbingCursor=new DnD.Cursor(document.body,B)
+}},disableDraggableCursors:function(){var A=this.getElement();
+if(this.dragOutBound&&this.dragOverBound){Event.stopObserving(A,"mouseover",this.dragOutBound);
+Event.stopObserving(A,"mouseout",this.dragOverBound)
+}else{return false
+}return true
+},isDraggableCursorsEnabled:function(){if(this.isCursorsEnabled){this.isCursorsEnabled=true
+}else{this.isCursorsEnabled=false
+}return this.isCursorsEnabled
+}};
+DefaultDragIndicator={setContent:function(A,C,B){},show:function(){if(window.drag&&window.drag.source){var B=window.drag.source.getElement();
+Element.setStyle(this,{"width":Element.getWidth(B)+"px","height":"1px"});
+Element.show(this);
+this.style.position="absolute";
+var A=$("_rfDefaultDragIndicatorLeft");
+if(A){Element.setStyle(A,{"width":"1px","height":Element.getHeight(B)+"px"});
+Element.show(A);
+A.style.position="absolute"
+}A=$("_rfDefaultDragIndicatorRight");
+if(A){Element.setStyle(A,{"width":"1px","height":Element.getHeight(B)+"px"});
+Element.show(A);
+A.style.position="absolute"
+}A=$("_rfDefaultDragIndicatorBottom");
+if(A){Element.setStyle(A,{"width":Element.getWidth(B)+"px","height":"1px"});
+Element.show(A);
+A.style.position="absolute"
+}}},hide:function(){Element.hide(this);
+this.style.position="";
+var A=$("_rfDefaultDragIndicatorLeft");
+if(A){Element.hide(A);
+A.style.position=""
+}A=$("_rfDefaultDragIndicatorRight");
+if(A){Element.hide(A);
+A.style.position=""
+}A=$("_rfDefaultDragIndicatorBottom");
+if(A){Element.hide(A);
+A.style.position=""
+}},position:function(A,C){if(this.removalX&&this.removalY){A-=(this.removalX+5);
+C-=(this.removalY+14)
+}Element.setStyle(this,{"left":A+"px","top":C+"px"});
+var B=$("_rfDefaultDragIndicatorLeft");
+if(B){Element.setStyle(B,{"left":A+"px","top":C+"px"})
+}A+=this.indicatorWidth;
+B=$("_rfDefaultDragIndicatorRight");
+if(B){Element.setStyle(B,{"left":A+"px","top":C+"px"})
+}A-=this.indicatorWidth;
+C+=this.indicatorHeight;
+B=$("_rfDefaultDragIndicatorBottom");
+if(B){Element.setStyle(B,{"left":A+"px","top":C+"px"})
+}},accept:function(){this.changeIndicatorColor(this,"green")
+},reject:function(){this.changeIndicatorColor(this,"red")
+},leave:function(){this.changeIndicatorColor(this,"black")
+},changeIndicatorColor:function(A,B){Element.setStyle(A,{"border-top":"1px dashed "+B});
+var C=$("_rfDefaultDragIndicatorLeft");
+if(C){Element.setStyle(C,{"border-left":"1px dashed "+B})
+}C=$("_rfDefaultDragIndicatorRight");
+if(C){Element.setStyle(C,{"border-right":"1px dashed "+B})
+}C=$("_rfDefaultDragIndicatorBottom");
+if(C){Element.setStyle(C,{"border-bottom":"1px dashed "+B})
+}}}
+
+DnD.Dropzone=function(){};
+DnD.Dropzone.DROP_TARGET_ID="dropTargetId";
+DnD.Dropzone.prototype={getElement:function(){return $(this.id)
+},getDropzoneOptions:function(){return null
+},getDnDDefaultParams:function(){return DnD.getDnDDefaultParams(this.getElement())
+},getDnDDropParams:function(){return DnD.getDnDDropParams(this.getElement())
+},accept:function(A){return DnD.CLIENT_VALIDATION_OFF||this.getAcceptedTypes().indexOf(A.type)>-1
+},getAcceptedTypes:function(){return[]
+},getTypeMapping:function(){return{}
+},getCursorTypeMapping:function(){return{}
+},drop:function(B,A){},getIconCodeForType:function(B){var A=this.getTypeMapping();
+if(B&&A){return A[B]
+}return null
+},getCursorForType:function(B){var A=this.getCursorTypeMapping();
+if(B&&A){return A[B]
+}},dragEnter:function(C){var F=window.drag;
+F.dropzone=this;
+F.source.ondropover(C,F);
+var H=F.indicator;
+var B=this.accept(F);
+if(B){var I=this.getCursorForType(F.type);
+if(I){this.acceptMappingCursor=new DnD.Cursor(this.getElement(),I);
+this.acceptMappingCursor.showCursor()
+}else{if(this.acceptCursor){this.acceptCursor.showCursor()
+}}}else{if(this.rejectCursor){this.rejectCursor.showCursor()
+}}if(H){var G=this.getIconCodeForType(F.type);
+var D=F.source.getDnDDragParams();
+if(D){Object.extend(D,this.getDnDDropParams())
+}else{D=this.getDnDDropParams()
+}if(D){if(G){D["marker"]=D[G]
+}else{D["marker"]=null
+}}var E=B?"accept":"reject";
+DnD.setDefaultDnDParams(D);
+if(F.source.getDraggableItems&&F.source.getDraggableItems()>1){H.setContent(E,false,D)
+}else{H.setContent(E,true,D)
+}if(B){H.accept()
+}else{H.reject()
+}}var A=this.getDropzoneOptions();
+if(A&&A.ondragenter){A.ondragenter.call(C)
+}},dragLeave:function(D){var B=window.drag;
+B.dropzone=null;
+B.source.ondropout(D,B);
+B.source.setIndicator(D);
+var A=B.indicator;
+if(A){A.leave()
+}var C=this.getDropzoneOptions();
+if(C&&C.ondragexit){C.ondragexit(D)
+}if(this.acceptCursor){if(this.acceptCursor.visible){this.acceptCursor.hideCursor()
+}}if(this.rejectCursor){if(this.rejectCursor.visible){this.rejectCursor.hideCursor()
+}}if(this.acceptMappingCursor){if(this.acceptMappingCursor.visible){this.acceptMappingCursor.hideCursor()
+}}},dragUp:function(B){this.ondropend(B);
+if(this.acceptCursor){if(this.acceptCursor.visible){this.acceptCursor.hideCursor()
+}}if(this.rejectCursor){if(this.rejectCursor.visible){this.rejectCursor.hideCursor()
+}}if(this.acceptMappingCursor){if(this.acceptMappingCursor.visible){this.acceptMappingCursor.hideCursor()
+}}var A=this.getDropzoneOptions();
+if(A&&A.ondropend){A.ondropend()
+}},enableDropzoneCursors:function(B,A){if(B){this.acceptCursor=new DnD.Cursor(this.getElement(),B)
+}if(A){this.rejectCursor=new DnD.Cursor(this.getElement(),A)
+}},ondropend:function(A){},onafterdrag:function(A){},onbeforedrag:function(B,A){},ondragenter:function(A){},ondragexit:function(A){}}
+
+JSNode=function(){};
+JSNode.prototype={tag:null,attrs:{},childs:[],value:"",_symbols:{"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&apos;","\u00A0":"&nbsp;"},getInnerHTML:function(F){var B="";
+for(var A=0;
+A<this.childs.length;
+A++){B+=this.childs[A].getContent(F)
+}return B
+},xmlEscape:function(A){var B=A?A.toString():"";
+return B.escapeHTML()
+}};
+E=function(F,A,B){this.tag=F;
+if(A){this.attrs=A
+}if(B){this.childs=B
+}};
+E.prototype=new JSNode();
+E.prototype.getContent=function(G){var F="<"+this.tag;
+var A=this.getInnerHTML(G);
+if(A==""){this.isEmpty=true
+}else{this.isEmpty=false
+}for(var B in this.attrs){if(!this.attrs.hasOwnProperty(B)){continue
+}var H=this.attrs[B];
+if(typeof H=="function"){H=H.call(this,G)
+}if(H){F+=" "+(B=="className"?"class":B)+'="'+this.xmlEscape(H)+'"'
+}}F+=">"+A+"</"+this.tag+">";
+return F
+};
+ET=function(A){this.value=A
+};
+ET.prototype.getContent=function(A){var B=this.value;
+if(typeof B=="function"){B=B(A)
+}if(B&&B.getContent){B=B.getContent(A)
+}if(B){return B
+}return""
+};
+T=function(A){this.value=A
+};
+T.prototype=new JSNode();
+T.prototype.getContent=function(A){var B=this.value;
+if(typeof B=="function"){B=B(A)
+}if(B){return this.xmlEscape(B)
+}return""
+};
+C=function(A){this.value=A
+};
+C.prototype.getContent=function(A){return"<!--"+this.value+"-->"
+};
+D=function(A){this.value=A
+};
+D.prototype.getContent=function(A){return"<![CDATA["+this.value+"]]>"
+}
+
+if(!String.prototype.parseJSON){String.prototype.parseJSON=function(hook){try{if(!/[^,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]/.test(this.replace(/("(\\.|[^"\\])*")|('(\\.|[^'\\])*')/g,""))){var j=eval("("+this+")");
+if(typeof hook==="function"){function walk(v){if(v&&typeof v==="object"){for(var i in v){if(v.hasOwnProperty(i)){v[i]=walk(v[i])
+}}}return hook(v)
+}return walk(j)
+}return j
+}}catch(e){}throw new SyntaxError("parseJSON")
+}
+}EventHandlersWalk=function(v){if(v&&typeof v=="object"){var names=new Array();
+for(var i in v){if(v.hasOwnProperty(i)){if(i.length>2&&i.substring(0,2)=="on"){names.push(i)
+}}}for(var i=0;
+i<names.length;
+i++){var name=names[i];
+var value=v[name];
+if(value&&typeof value!="function"){var f=eval("(["+v[name]+"])")[0];
+if(typeof f=="function"){v[name]=f
+}}}}return v
+}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.SYNTHETIC_EVENT="Richfaces.SYNTHETIC_EVENT";
+Richfaces.createEvent=function(F,D,C,E){var G;
+if(document.createEventObject){if(C){G=document.createEventObject(C)
+}else{G=document.createEventObject()
+}}else{var B=C&&C.bubbles||false;
+var A=C&&C.cancelable||true;
+switch(F){case"abort":case"blur":case"change":case"error":case"focus":case"load":case"reset":case"resize":case"scroll":case"select":case"submit":case"unload":G=document.createEvent("HTMLEvents");
+G.initEvent(F,B,A);
+break;
+case"DOMActivate":case"DOMFocusIn":case"DOMFocusOut":case"keydown":case"keypress":case"keyup":G=document.createEvent("UIEvents");
+if(C){G.initUIEvent(F,B,A,C.windowObject,C.detail)
+}else{G.initEvent(F,B,A)
+}break;
+case"click":case"mousedown":case"mousemove":case"mouseout":case"mouseover":case"mouseup":G=document.createEvent("MouseEvents");
+if(C){G.initMouseEvent(F,B,A,C.windowObject,C.detail,C.screenX,C.screenY,C.clientX,C.clientY,C.ctrlKey,C.altKey,C.shiftKey,C.metaKey,C.button,C.relatedTarget)
+}else{G.initEvent(F,B,A)
+}break;
+case"DOMAttrModified":case"DOMNodeInserted":case"DOMNodeRemoved":case"DOMCharacterDataModified":case"DOMNodeInsertedIntoDocument":case"DOMNodeRemovedFromDocument":case"DOMSubtreeModified":G=document.createEvent("MutationEvents");
+if(C){G.initMutationEvent(F,B,A,C.relatedNode,C.prevValue,C.newValue,C.attrName,C.attrChange)
+}else{G.initEvent(F,B,A)
+}break;
+default:G=document.createEvent("Events");
+G.initEvent(F,B,A)
+}}if(E){Object.extend(G,E)
+}G[Richfaces.SYNTHETIC_EVENT]=true;
+return{event:G,fire:function(){if(D.fireEvent){D.fireEvent("on"+F,this.event)
+}else{D.dispatchEvent(this.event)
+}}}
+};
+Richfaces.eventIsSynthetic=function(A){if(A){return new Boolean(A[Richfaces.SYNTHETIC_EVENT]).valueOf()
+}return false
+}
+
+if(!window.RichFaces){window.RichFaces={}
+}RichFaces.MSIE=0;
+RichFaces.FF=1;
+RichFaces.OPERA=2;
+RichFaces.NETSCAPE=3;
+RichFaces.SAFARI=4;
+RichFaces.KONQ=5;
+RichFaces.navigatorType=function(){var A=navigator.userAgent.toLowerCase();
+if(A.indexOf("msie")>=0||A.indexOf("explorer")>=0){return RichFaces.MSIE
+}if(A.indexOf("firefox")>=0||A.indexOf("iceweasel")>=0){return RichFaces.FF
+}if(A.indexOf("opera")>=0){return RichFaces.OPERA
+}if(A.indexOf("netscape")>=0){return RichFaces.NETSCAPE
+}if(A.indexOf("safari")>=0){return RichFaces.SAFARI
+}if(A.indexOf("konqueror")>=0){return RichFaces.KONQ
+}return"OTHER"
+};
+RichFaces.getOperaVersion=function(){var B=navigator.userAgent.toLowerCase();
+var A=B.indexOf("opera");
+if(A==-1){return 
+}return parseFloat(B.substring(A+6))
+};
+RichFaces.getIEVersion=function(){var C="msie";
+var D=navigator.userAgent.toLowerCase();
+var A=D.indexOf(C);
+if(A!=-1){var E=D.indexOf(";",A);
+var B;
+if(E!=-1){B=D.substring(A+C.length,E)
+}else{B=D.substring(A+C.length)
+}return parseFloat(B)
+}else{return undefined
+}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.getComputedStyle=function(C,A){var B=$(C);
+if(B.currentStyle){return B.currentStyle[A]
+}if(document.defaultView&&document.defaultView.getComputedStyle&&document.defaultView.getComputedStyle(B,null)){return document.defaultView.getComputedStyle(B,null).getPropertyValue(A)
+}return""
+};
+Richfaces.getComputedStyleSize=function(B,A){var C=Richfaces.getComputedStyle(B,A);
+if(C){C=C.strip();
+C=C.replace(/px$/,"");
+return parseFloat(C)
+}return 0
+};
+Richfaces.getWindowSize=function(){var B=0,A=0;
+if(typeof (window.innerWidth)=="number"){B=window.innerWidth;
+A=window.innerHeight
+}else{if(document.documentElement&&(document.documentElement.clientWidth||document.documentElement.clientHeight)){B=document.documentElement.clientWidth;
+A=document.documentElement.clientHeight
+}else{if(document.body&&(document.body.clientWidth||document.body.clientHeight)){B=document.body.clientWidth;
+A=document.body.clientHeight
+}}}return{"width":B,"height":A}
+};
+Richfaces.removePX=function(B){var A=B.indexOf("px");
+if(A==-1){return B
+}return B.substr(0,A)
+};
+Richfaces.visitTree=function(A,E){var D=A;
+if(!D){D=document
+}E.call(this,D);
+var C=D.childNodes;
+for(var B=0;
+B<C.length;
+B++){Richfaces.visitTree(C[B],E)
+}};
+Richfaces.getNSAttribute=function(C,F){if(F.getAttributeNS){var A=F.getAttributeNS("http://richfaces.ajax4jsf.org/rich",C);
+if(A){return A
+}}var E="rich:"+C;
+var A=F.attributes[E];
+if(A){return A.nodeValue
+}var B=F.attributes;
+for(var D=0;
+D<B.length;
+D++){A=B[D];
+if(A&&E==A.nodeName){return A.nodeValue
+}}return null
+};
+Richfaces.VARIABLE_NAME_PATTERN=/^\s*[_,A-Z,a-z][\w,_\.]*\s*$/;
+Richfaces.getObjectValue=function(D,B){var A=D.split(".");
+var C=B[A[0]];
+var E=1;
+while(C&&E<A.length){C=C[A[E++]]
+}return(C?C:"")
+};
+Richfaces.evalMacro=function(template,object){var value="";
+if(Richfaces.VARIABLE_NAME_PATTERN.test(template)){if(template.indexOf(".")==-1){value=object[template];
+if(!value){value=window[template]
+}}else{value=Richfaces.getObjectValue(template,object);
+if(!value){value=Richfaces.getObjectValue(template,window)
+}}if(value&&typeof value=="function"){value=value(object)
+}if(!value){value=""
+}}else{try{if(Richfaces.browser.isObjectEval){value=object.eval(template)
+}else{with(object){value=eval(template)
+}}if(typeof value=="function"){value=value(object)
+}}catch(e){LOG.warn("Exception: "+e.Message+"\n["+template+"]")
+}}return value
+};
+Richfaces.evalSimpleMacro=function(B,A){var C=A[B];
+if(!C){C=window[B];
+if(!C){C=""
+}}return C
+};
+Richfaces.getComponent=function(A,B){var D="richfacesComponent";
+var C="richfaces:"+A;
+while(B.parentNode){if(B[D]&&B[D]==C){return B.component
+}else{B=B.parentNode
+}}};
+Richfaces.browser={isIE:(!window.opera&&/MSIE/.test(navigator.userAgent)),isIE6:(!window.opera&&/MSIE\s*[6][\d,\.]+;/.test(navigator.userAgent)),isSafari:/Safari/.test(navigator.userAgent),isObjectEval:(Richfaces.eval!=undefined)};
+Richfaces.eval=function(template,object){var value="";
+try{with(object){value=eval(template)
+}}catch(e){LOG.warn("Exception: "+e.message+"\n["+template+"]")
+}return value
+};
+Richfaces.interpolate=function(A,D){for(var C in D){var B=D[C];
+var E=new RegExp("\\{"+C+"\\}","g");
+A=A.replace(E,B)
+}return A
+};
+if(!Richfaces.position){Richfaces.Position={}
+}Richfaces.Position.setElementPosition=function(D,M,H,K,C){var P=Richfaces.Position.getOffsetDimensions(D);
+var L=Richfaces.Position.getOffsetDimensions(M);
+var F=Richfaces.Position.getWindowViewport();
+var N=Position.cumulativeOffset(M);
+var B=N[0];
+var A=N[1];
+var O=/^(top|bottom)-(left|right)$/;
+var E;
+if(typeof H=="object"){B=H.x;
+A=H.y
+}else{if(H&&(E=H.toLowerCase().match(O))!=null){if(E[2]=="right"){B+=L.width
+}if(E[1]=="bottom"){A+=L.height
+}}else{}}if(K&&(E=K.toLowerCase().match(O))!=null){var G=K.toLowerCase().split("-");
+if(E[2]=="left"){B-=P.width+C.x
+}else{B+=C.x
+}if(E[1]=="top"){A-=P.height+C.y
+}else{A+=C.y
+}}else{var J={square:0};
+var I={right:N[0]+L.width,top:N[1]+L.height};
+I.left=I.right-P.width;
+I.bottom=I.top+P.height;
+B=I.left;
+A=I.top;
+var Q=Richfaces.Position.checkCollision(I,F);
+if(Q!=0){if(B>=0&&A>=0&&J.square<Q){J={x:B,y:A,square:Q}
+}I={right:N[0]+L.width,bottom:N[1]};
+I.left=I.right-P.width;
+I.top=I.bottom-P.height;
+B=I.left;
+A=I.top;
+Q=Richfaces.Position.checkCollision(I,F);
+if(Q!=0){if(B>=0&&A>=0&&J.square<Q){J={x:B,y:A,square:Q}
+}I={left:N[0],top:N[1]+L.height};
+I.right=I.left+P.width;
+I.bottom=I.top+P.height;
+B=I.left;
+A=I.top;
+Q=Richfaces.Position.checkCollision(I,F);
+if(Q!=0){if(B>=0&&A>=0&&J.square<Q){J={x:B,y:A,square:Q}
+}I={left:N[0],bottom:N[1]};
+I.right=I.left+P.width;
+I.top=I.bottom-P.height;
+B=I.left;
+A=I.top;
+Q=Richfaces.Position.checkCollision(I,F);
+if(Q!=0){if(B<0||A<0||J.square>Q){B=J.x;
+A=J.y
+}}}}}}D.style.left=B+"px";
+D.style.top=A+"px"
+};
+Richfaces.Position.getOffsetDimensions=function(C){C=$(C);
+var G=$(C).getStyle("display");
+if(G!="none"&&G!=null){return{width:C.offsetWidth,height:C.offsetHeight}
+}var B=C.style;
+var F=B.visibility;
+var D=B.position;
+var A=B.display;
+B.visibility="hidden";
+B.position="absolute";
+B.display="block";
+var H=C.offsetWidth;
+var E=C.offsetHeight;
+B.display=A;
+B.position=D;
+B.visibility=F;
+return{width:H,height:E}
+};
+Richfaces.Position.checkCollision=function(A,B,D){if(A.left>=B.left&&A.top>=B.top&&A.right<=B.right&&A.bottom<=B.bottom){return 0
+}var C={left:(A.left>B.left?A.left:B.left),top:(A.top>B.top?A.top:B.top),right:(A.right<B.right?A.right:B.right),bottom:(A.bottom<B.bottom?A.bottom:B.bottom)};
+return(C.right-C.left)*(C.bottom-C.top)
+};
+Richfaces.Position.getWindowDimensions=function(){var A=self.innerWidth||document.documentElement.clientWidth||document.body.clientWidth||0;
+var B=self.innerHeight||document.documentElement.clientHeight||document.body.clientHeight||0;
+return{width:A,height:B}
+};
+Richfaces.Position.getWindowScrollOffset=function(){var B=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;
+var A=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;
+return{left:B,top:A}
+};
+Richfaces.Position.getWindowViewport=function(){var B=Richfaces.Position.getWindowDimensions();
+var A=Richfaces.Position.getWindowScrollOffset();
+return{left:A.left,top:A.top,right:B.width+A.left,bottom:B.height+A.top}
+}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.jsFormSubmit=function(F,B,D,E){var C=document.getElementById(B);
+if(C){var A=C.target;
+var H=new Array();
+if(E){for(var G in E){H.push(G)
+}}_JSFFormSubmit(F,B,D,E);
+_clearJSFFormParameters(B,A,H)
+}}
+
+A4J_Command=Class.create();
+A4J_Command.prototype={initialize:function(B,C,A){this.form=Event.findElement(B,"form");
+this.target=A;
+this.objectsCreated=new Array();
+this.oldValuesOfExistingInputs={};
+this.appendParameters(C);
+this.processClick();
+this.cleanUp()
+},processClick:function(){var B=this.form;
+var A=B.target;
+$A(this.objectsCreated).each(function(C){B.appendChild(C)
+});
+if(this.target){B.target=this.target
+}B.submit();
+B.target=A
+},appendParameters:function(B){var A=this;
+$H(B).each(function(C){A.createOrInitHiddenInput(C.key,C.value)
+})
+},cleanUp:function(){var A=this.form;
+$H(this.oldValuesOfExistingInputs).each(function(B){($(B.key)||A[B.key]).value=B.value
+});
+$A(this.objectsCreated).each(function(B){A.removeChild(B)
+});
+delete (this.objectsCreated)
+},createOrInitHiddenInput:function(B,C){var A=$(B)||this.form[B];
+if(!A){A=document.createElement("input");
+A.setAttribute("type","hidden");
+A.setAttribute("name",B);
+A.setAttribute("id",B);
+this.objectsCreated.push(A)
+}else{this.oldValuesOfExistingInputs[B]=A.value
+}A.value=C
+}}
+
+if(!window.A4J){window.A4J={}
+}if(!A4J.findForm){function _JSFFormSubmit(G,B,E,D){var C=document.getElementById(B);
+if(C){var H=[];
+if(E){C.target=E
+}if(D){for(var F in D){H.push(F);
+if(C.elements[F]){C.elements[F].value=D[F]
+}else{var A=document.createElement("input");
+A.type="hidden";
+A.name=F;
+A.value=D[F];
+C.appendChild(A)
+}}}C.submit();
+_clearJSFFormParameters(B,E,H)
+}else{alert("Form "+B+" not found in document")
+}return false
+}function _clearJSFFormParameters(C,F,A){var D=document.getElementById(C);
+if(D){if(F){D.target=F
+}else{D.target=""
+}if(A){for(var B=0;
+B<A.length;
+B++){var E=D.elements[A[B]];
+if(E){E.value=""
+}}}}}function clearFormHiddenParams(B,C,A){_clearJSFFormParameters(B,C,A)
+}A4J.findForm=function(A){var B=A;
+do{B=B.parentNode
+}while(B&&B.nodeName.toLowerCase()!="form");
+if(!B){B={reset:function(){},submit:function(){}}
+}return B
+};
+A4J._formInput=null;
+A4J.setupForm=function(C){var B=window.document.getElementById(C);
+var A="click";
+if(B.addEventListener){B.addEventListener(A,A4J._observer,false)
+}else{if(B.attachEvent){B.attachEvent("on"+A,A4J._observer)
+}}};
+A4J._observer=function(A){var B=A.target||A.srcElement;
+if(B&&B.nodeName.toUpperCase()=="INPUT"&&B.type.toUpperCase()=="SUBMIT"){A4J._formInput=B
+}else{A4J._formInput=null
+}}
+}
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.setImages=function(B,A){B=$(B);
+if(!B){return 
+}for(imageSrc in A){if(typeof imageSrc!="function"){B[imageSrc]=new Image();
+B[imageSrc].src=A[imageSrc]
+}}}
+
+if(!window.Richfaces){window.Richfaces={}
+}if(!Richfaces.SmartPosition){Richfaces.SmartPosition={options:$H({"positionX":["right","left","center"],"positionY":["bottom","top"],positionFloat:true}),getBase:function(){return(document.compatMode&&document.compatMode.toLowerCase()=="css1compat"&&!/Netscape|Opera/.test(navigator.userAgent))?document.documentElement:(document.body||null)
+},screenOffset:function(G,A){G=$(G);
+var B=this.getBase();
+var C=/Opera/.test(navigator.userAgent);
+var D=0,H=0;
+var I="";
+var E=G;
+do{I+="element: "+E.tagName+", offsetTop = "+E.offsetTop+", offsetLeft = "+E.offsetLeft+"\n";
+D+=E.offsetTop||0;
+H+=E.offsetLeft||0;
+I+="valueT = "+D+", valueL = "+H+"\n";
+if(E.offsetParent==B&&Element.getStyle(E,"position")=="absolute"){break
+}}while(E=E.offsetParent);
+I+="\n\n";
+E=G;
+do{I+="element: "+E.tagName+", scrollTop = "+E.scrollTop+", scrollLeft = "+E.scrollLeft+"\n";
+if(!C||(E.tagName!=undefined&&(E.tagName.toLowerCase()!="tr"&&E!=G&&E!=G.parentNode))){D-=E.scrollTop||0;
+H-=E.scrollLeft||0
+}I+="valueT = "+D+", valueL = "+H+"\n";
+if(E==B){break
+}}while(E=E.parentNode);
+var F=[H,D];
+if(arguments.length>1&&A){alert(I+"\n\noffset = "+F)
+}G=$(G);
+if(!C&&G.tagName.toLowerCase()=="input"){F[0]+=G.scrollLeft
+}return F
+},getVSpaces:function(B){var D=this.getBase();
+if(this.isElement(B)){var F=this.screenOffset(B);
+var C=Element.getDimensions(B);
+var E=F[1];
+var A=D.clientHeight-F[1]-C.height
+}else{var E=B[1]-D.scrollTop;
+var A=D.clientHeight-(B[1]-D.scrollTop)
+}return{top:E,bottom:A}
+},getHSpaces:function(B){var D=this.getBase();
+if(this.isElement(B)){var F=this.screenOffset(B);
+var C=Element.getDimensions(B);
+var E=F[0]+C.width;
+var A=D.clientWidth-F[0]
+}else{var E=B[0]-D.scrollLeft;
+var A=D.clientWidth-(B[0]-D.scrollLeft)
+}return{left:E,right:A}
+},getPosition:function(D,A,J){var B=this.getBase();
+var F=[$(A).offsetWidth,$(A).offsetHeight];
+var C=this.getHSpaces(D);
+var G=this.getVSpaces(D);
+if(this.isElement(D)){var E=this.screenOffset(D);
+var I={width:$(D).offsetWidth,height:$(D).offsetHeight};
+var H=[E[0],E[1]+I.height]
+}else{var H=[D[0],D[1]]
+}if(C.right<F[0]&&C.left>=F[0]){if(this.isElement(D)){H[0]=E[0]+I.width-F[0]
+}else{H[0]=D[0]-F[0]
+}}if(this.isElement(D)){H[0]+=B.scrollLeft
+}if(G.bottom<F[1]&&G.top>=F[1]){if(this.isElement(D)){H[1]=E[1]-F[1]
+}else{H[1]=H[1]-F[1]
+}}if(this.isElement(D)){H[1]+=B.scrollTop
+}return H
+},getOption:function(A){if(A){return $H(A)
+}else{return this.options
+}},calcSizes:function(A){if(A.tagName.toLowerCase()=="table"){A.style.width="0px";
+A.style.height="0px";
+return{width:A.offsetWidth,height:A.offsetHeight}
+}},isElement:function(A){return(A.length==undefined)
+}}
+}

Added: portlets/src/framework/RichFacesPortlet/src/main/webapp/js/ui.pack.js
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/js/ui.pack.js	                        (rev 0)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/js/ui.pack.js	2008-01-09 22:53:31 UTC (rev 192)
@@ -0,0 +1,6525 @@
+DragIndicator={init:function(A){var B=RichFaces.getIEVersion();
+DragIndicator.isIE6=(B&&B<7)
+},setContent:function(A,F,D){Element.clearChildren(this);
+var C=DnD.getDnDDefaultParams(this);
+if(!C){C={}
+}if(D){Object.extend(C,D)
+}if(!C["marker"]){if(C[A]){C["marker"]=C[A]
+}else{C["marker"]=this.markers[A]
+}}var B;
+if(F){B=this.indicatorTemplates["single"]
+}else{B=this.indicatorTemplates["multi"]
+}new Insertion.Top(this,B.invoke("getContent",C).join(""));
+if(DragIndicator.isIE6){this.initIFrame()
+}},show:function(){if(!this.floatedToBody){if(!this.realParent){this.realParent=this.parentNode;
+this._nextSibling=this.nextSibling
+}this.realParent.removeChild(this);
+document.body.appendChild(this);
+this.floatedToBody=true
+}Element.show(this);
+this.style.position="absolute"
+},hide:function(){Element.hide(this);
+this.style.position="";
+this.offsets=undefined;
+this.leave();
+if(this.floatedToBody&&this.realParent){document.body.removeChild(this);
+if(this._nextSibling){this.realParent.insertBefore(this,this._nextSibling)
+}else{this.realParent.appendChild(this)
+}this.floatedToBody=false
+}},position:function(A,B){if(!this.offsets){Element.show(this);
+this.style.position="absolute"
+}Element.setStyle(this,{"left":A+"px","top":B+"px"})
+},accept:function(){Element.removeClassName(this,"drgind_default");
+Element.removeClassName(this,"drgind_reject");
+Element.addClassName(this,"drgind_accept");
+var A=this.getAcceptClass();
+if(A){Element.addClassName(this,A)
+}},reject:function(){Element.removeClassName(this,"drgind_default");
+Element.removeClassName(this,"drgind_accept");
+Element.addClassName(this,"drgind_reject");
+var A=this.getRejectClass();
+if(A){Element.addClassName(this,A)
+}},leave:function(){Element.removeClassName(this,"drgind_accept");
+Element.removeClassName(this,"drgind_reject");
+Element.addClassName(this,"drgind_default");
+var B=this.getAcceptClass();
+var A=this.getRejectClass();
+if(B){Element.removeClassName(this,B)
+}if(A){Element.removeClassName(this,A)
+}},getAcceptClass:function(){return this.ils_acceptClass
+},getRejectClass:function(){return this.ils_rejectClass
+},initIFrame:function(){var A=document.createElement("iframe");
+Element.addClassName(A,"rich-dragindicator-iframe");
+this.insertBefore(A,this.firstChild);
+var B=A.nextSibling;
+A.style.width=B.offsetWidth+"px";
+A.style.height=B.offsetHeight+"px"
+}};
+function createDragIndicator(B,C,A){Object.extend(B,DragIndicator);
+B.init();
+B.ils_acceptClass=C;
+B.ils_rejectClass=A
+}DefaultDragIndicatorView=[new E("table",{"style":"height : 100%; z-index: 2;","className":"drgind_internal","cellspacing":"0","cellpadding":"3","border":"0"},[new E("tbody",{},[new E("tr",{},[new E("td",{"className":"drgind_marker"},[new ET(function(context){return Richfaces.eval("marker",context)
+})]),new E("td",{"className":"drgind_text"},[new E("div",{"className":"drgind_wordcut drgind_text_content"},[new ET(function(context){return Richfaces.eval("label",context)
+})])])])])]),new E("div",{"className":"drgind_shadow"})]
+
+DnD.SimpleDraggable=Class.create();
+Object.extend(DnD.SimpleDraggable.prototype,DnD.Draggable.prototype);
+Object.extend(DnD.SimpleDraggable.prototype,{initialize:function(B,A){this.id=$(B);
+if(!this.id){alert("drag: Element with ["+B+"] ID was not found in the DOM tree. Probably element has no client ID or client ID hasn't been written. DnD's disabled. Check please!");
+return 
+}this.options=A;
+this.dragIndicatorId=this.options.dragIndicator;
+this.eventMouseDown=this.initDrag.bindAsEventListener(this);
+Event.observe(this.id,"mousedown",this.eventMouseDown);
+this.form=this.id;
+while(this.form&&!/^form$/i.test(this.form.tagName)){this.form=this.form.parentNode
+}this.enableDraggableCursors(this.options.grab,this.options.grabbing)
+},getDnDDragParams:function(){if(this.options.dndParams){return this.options.dndParams.parseJSON(EventHandlersWalk)
+}return null
+},getIndicator:function(){var A=$(this.dragIndicatorId);
+if(!A){A=this.getOrCreateDefaultIndicator()
+}return A
+},ondragstart:function(B,A){A.params=this.options.parameters;
+A.params[this.id]=this.id;
+this.setIndicator(B);
+if(this.form){A.params[this.form.id]=this.form.id
+}},getContentType:function(){return this.options.dragType
+},getDraggableOptions:function(){return this.options
+},initDrag:function(A){if(Event.isLeftClick(A)){var B=Event.element(A);
+if(B.tagName&&/^INPUT|SELECT|OPTION|BUTTON|TEXTAREA$/i.test(B.tagName)){return 
+}Event.stop(A);
+this.startDrag(A)
+}}})
+
+DnD.SimpleDropZone=Class.create();
+Object.extend(DnD.SimpleDropZone.prototype,DnD.Dropzone.prototype);
+Object.extend(DnD.SimpleDropZone.prototype,{initialize:function(C,A){this.id=C;
+var B=$(C);
+if(!B){alert("drop: Element with ["+C+"] ID was not found in the DOM tree. Probably element has no client ID or client ID hasn't been written. DnD's disabled. Check please!");
+return 
+}this.element=B;
+if(A.acceptedTypes){this.acceptedTypes=A.acceptedTypes
+}else{this.acceptedTypes=[]
+}if(A.typeMapping){this.typeMapping=A.typeMapping
+}else{this.typeMapping={}
+}if(A.cursorTypeMapping){this.cursorTypeMapping=A.cursorTypeMapping
+}else{this.cursorTypeMapping={}
+}this.mouseoverBound=this.mouseover.bindAsEventListener(this);
+this.mouseoutBound=this.mouseout.bindAsEventListener(this);
+this.mouseupBound=this.mouseup.bindAsEventListener(this);
+Event.observe(B,"mouseover",this.mouseoverBound);
+Event.observe(B,"mouseout",this.mouseoutBound);
+Event.observe(B,"mouseup",this.mouseupBound);
+this.options=A||{};
+this.enableDropzoneCursors(A.acceptCursor,A.rejectCursor)
+},getDropzoneOptions:function(){return this.options
+},getDnDDropParams:function(){if(this.options.dndParams){return this.options.dndParams.parseJSON(EventHandlersWalk)
+}return null
+},mouseover:function(A){if(window.drag){this.dragEnter(A)
+}},mouseup:function(A){this.dragUp(A)
+},mouseout:function(A){if(window.drag){this.dragLeave(A)
+}},getAcceptedTypes:function(){return this.acceptedTypes
+},getTypeMapping:function(){return this.typeMapping
+},getCursorTypeMapping:function(){return this.cursorTypeMapping
+},drop:function(B,A){alert("I drop")
+},onafterdrag:function(A){if(this.options.onafterdrag){this.options.onafterdrag.call(this,A)
+}}})
+
+Richfaces.TreeSelectEvent="Richfaces.TreeSelectEvent";
+Richfaces.TreeExpandEvent="Richfaces.TreeExpandEvent";
+Richfaces.TreeCollapseEvent="Richfaces.TreeCollapseEvent";
+Tree=Class.create();
+Tree.ID_DEVIDER=":";
+Tree.ID_CONTENT="content";
+Tree.ID_CHILDS_ROW="childs";
+Tree.ID_CHILDS_TD="td";
+Tree.ID_HANDLE="handle";
+Tree.ID_HANDLE_IMG_EXPANDED="img:expanded";
+Tree.ID_HANDLE_IMG_COLLAPSED="img:collapsed";
+Tree.ID_ICON="icon";
+Tree.ID_TEXT="text";
+Tree.ID_MAIN_ROW="mainRow";
+Tree.CLASS_ITEM_SELECTED="dr-tree-i-sel";
+Tree.CLASS_ITEM_EXPANDED="dr-tree-h-ic-line-exp";
+Tree.CLASS_ITEM_COLLAPSED="dr-tree-h-ic-line-clp";
+Tree.CLASS_AJAX_SELECTED_LISTENER_FLAG="ajax_selected_listener_flag";
+Tree.prototype={initialize:function(H,A,E,D,C,G,F){this.childs=[];
+this.elements={};
+this.id=H;
+this.switchType=E;
+this.onselect=new Function("event",(D.onselect?D.onselect:"")+"; return true;");
+this.onexpand=new Function("event",(D.onexpand?D.onexpand:"")+"; return true;");
+this.oncollapse=new Function("event",(D.oncollapse?D.oncollapse:"")+"; return true;");
+this.onAjaxSelect=C;
+this.element=$(H);
+this.inputId=A;
+this.input=$(this.inputId);
+this.toggleOnClick=G;
+this.showConnectingLines=F;
+var B=Object.extend({columnCount:0},arguments[1]||{});
+this.options=B;
+this.getElements();
+this.selectionManager=new Tree.SelectionManager(this);
+this.selectionManager.restoreSelection();
+Event.observe(this.element,"click",function(M){if(Richfaces.eventIsSynthetic(M)){var N=M["treeItem"];
+if(M[Richfaces.TreeSelectEvent]){Event.stop(M);
+var K=N.getRichAttribute("onselected");
+K=new Function("event",(K?K:"")+"; return true;");
+var O=this.selectionManager.activeItem;
+N.toggleSelection(M);
+var L=K(M);
+if(!L){M["cancelSelection"]=true;
+M["treeItem"]=O;
+if(O){O.toggleSelection(M)
+}return 
+}L=this.onselect(M);
+if(!L){M["cancelSelection"]=true;
+M["treeItem"]=O;
+if(O){O.toggleSelection(M)
+}return 
+}var I=Richfaces.getNSAttribute("ajaxselectedlistener",$(M.selectedNode+Tree.ID_DEVIDER+Tree.ID_ICON));
+if(I){this.onAjaxSelect(M)
+}}else{if(M[Richfaces.TreeExpandEvent]){Event.stop(M);
+var J=N.getRichAttribute("onexpand");
+if(J){new Function("event",J).call(Event.element(M),M)
+}this.onexpand(M)
+}else{if(M[Richfaces.TreeCollapseEvent]){Event.stop(M);
+var J=N.getRichAttribute("oncollapse");
+if(J){new Function("event",J).call(Event.element(M),M)
+}this.oncollapse(M)
+}}}}}.bindAsEventListener(this))
+},getElements:function(B){this.elements.contentTd=$(this.id+Tree.ID_DEVIDER+Tree.ID_CHILDS_ROW);
+if(this.elements.contentTd){for(var A=this.elements.contentTd.firstChild;
+A!=null;
+A=A.nextSibling){if(A.nodeType==1&&A.tagName.toLowerCase()=="table"){this.addChild(new Tree.Item(A,this,this,B))
+}}}},addChild:function(A){this.childs.push(A)
+},getNodeElements:function(B){if(B){for(var A=0;
+A<B.length;
+A++){var C=B[A];
+if(C!=this.id){this._getNodeElements(this,C,C.substring(0,C.lastIndexOf(":")))
+}else{for(var A=0;
+A<this.childs.length;
+A++){var D=this.childs[A];
+D.destroy()
+}this.childs=[];
+this.getElements(true)
+}}this.input=$(this.inputId);
+this.selectionManager.restoreSelection()
+}},_getNodeElements:function(D,E,A){for(var B=0;
+B<D.childs.length;
+B++){var G=D.childs[B];
+var F=G.id;
+if(F==E){G.destroy();
+D.childs[B]=new Tree.Item(F,this,G.parent,true);
+break
+}else{var C=F.substring(0,F.lastIndexOf(":"));
+if(A.substr(0,C.length)==C&&A.charAt(C.length)==":"){this._getNodeElements(G,E,A);
+break
+}}}},showNode:function(F){var D=F;
+var C=0;
+while(D&&Element.isChildOf(D,this.element)){C+=D.offsetTop;
+D=D.offsetParent
+}D=F;
+var E=C+D.offsetHeight;
+var A=this.element.scrollTop;
+var B=A+this.element.clientHeight;
+if(C<A){this.element.scrollTop=C
+}else{if(E>B){this.element.scrollTop=E-this.element.clientHeight
+}}},getElement:function(){return $(this.id)
+}}
+
+Tree.SelectionManager=Class.create();
+Tree.SelectionManager.prototype={initialize:function(A){this.tree=A;
+this.eventKeyPress=this.processKeyDown.bindAsEventListener(this);
+Event.observe(document,"keypress",this.eventKeyPress);
+this.eventLostFocus=this.processLostFocus.bindAsEventListener(this);
+Event.observe(document,"click",this.eventLostFocus);
+this.eventPreventLostFocus=this.processPreventLostFocus.bindAsEventListener(this);
+Event.observe(this.tree.element,"click",this.eventPreventLostFocus)
+},restoreSelection:function(){if(this.tree.input.value){var A=$(this.tree.input.value);
+if(A){this.inFocus=true;
+this.setSelection(A.object)
+}}},processPreventLostFocus:function(A){if(Richfaces.eventIsSynthetic(A)){return 
+}this.inFocus=true;
+this.preventLostFocus=true
+},processLostFocus:function(A){if(Richfaces.eventIsSynthetic(A)){return 
+}if(!this.preventLostFocus){this.lostFocus()
+}else{this.preventLostFocus=false
+}},lostFocus:function(){this.inFocus=false
+},setSelection:function(A){A.toggleSelection();
+this.activeItem=A
+},processKeyDown:function(E){if(!this.activeItem){return 
+}if(!($(this.activeItem.id))){this.activeItem=null;
+this.tree.input.value="";
+return 
+}var C=false;
+var B=E.keyCode||E.charCode;
+switch(B){case Event.KEY_UP:if(this.inFocus){if(!E.ctrlKey&&!E.shiftKey&&!E.altKey){var D=this.activeItem;
+do{var A=this.getPreviousItemForSelection(D);
+if(A&&A!=D){D=A;
+if(D.toggleSelection(E)){this.activeItem=D;
+D=null
+}}else{D=null
+}}while(D)
+}C=true
+}break;
+case Event.KEY_DOWN:if(this.inFocus){if(!E.ctrlKey&&!E.shiftKey&&!E.altKey){var D=this.activeItem;
+do{var A=this.getNextItemForSelection(D);
+if(A&&A!=D){D=A;
+if(D.toggleSelection(E)){this.activeItem=D;
+D=null
+}}else{D=null
+}}while(D)
+}C=true
+}break;
+case Event.KEY_LEFT:if(this.inFocus){if(!E.ctrlKey&&!E.shiftKey&&!E.altKey){this.activeItem.collapse()
+}C=true
+}break;
+case Event.KEY_RIGHT:if(this.inFocus){if(!E.ctrlKey&&!E.shiftKey&&!E.altKey){this.activeItem.expand()
+}C=true
+}break;
+case Event.KEY_TAB:this.lostFocus()
+}if(C){if(E.preventBubble){E.preventBubble()
+}Event.stop(E)
+}},getNextItemForSelection:function(C){if(!C.isCollapsed()&&C.hasChilds()){return C.childs.first()
+}else{var B=C.next();
+if(B!=C){return B
+}else{var A=C.parent;
+while(A&&A!=this.tree){var B=A.next();
+if(B!=A){return B
+}else{A=A.parent
+}}return C
+}}},getPreviousItemForSelection:function(B){var A=B.previous();
+if(A==B){if(A.parent==this.tree){A=B
+}else{A=B.parent
+}}else{if(!A.isCollapsed()&&A.hasChilds()){A=A.childs.last();
+while(!A.isCollapsed()&&A.hasChilds()){A=A.childs.last()
+}}}return A
+}}
+
+Tree.Item=Class.create();
+Tree.Item.prototype={initialize:function(G,A,D,F){this.parent=D;
+this.tree=A;
+this.elements={};
+this.elementID={};
+var C;
+if(typeof G=="string"){C=$(G);
+this.id=G
+}else{C=G;
+this.id=C.id
+}C.object=this;
+this.elementID.children=this.id+Tree.ID_DEVIDER+Tree.ID_CHILDS_ROW;
+this.elementID.mainRow=this.id+Tree.ID_DEVIDER+Tree.ID_MAIN_ROW;
+this.elementID.handle=this.id+Tree.ID_DEVIDER+Tree.ID_HANDLE;
+this.elementID.handleImgExpanded=this.elementID.handle+Tree.ID_DEVIDER+Tree.ID_HANDLE_IMG_EXPANDED;
+this.elementID.handleImgCollapsed=this.elementID.handle+Tree.ID_DEVIDER+Tree.ID_HANDLE_IMG_COLLAPSED;
+this.elementID.icon=this.id+Tree.ID_DEVIDER+Tree.ID_ICON;
+this.elementID.text=this.id+Tree.ID_DEVIDER+Tree.ID_TEXT;
+this.getElements(C,F);
+this.eventSelectionClick=this.toggleSelection.bindAsEventListener(this);
+this.eventMouseOut=this.processMouseOut.bindAsEventListener(this);
+this.eventMouseOver=this.processMouseOver.bindAsEventListener(this);
+var E=this.getDraggableOptions();
+if(E){this.enableDraggableCursors(E.grab,E.grabbing)
+}var B=this.getDropzoneOptions();
+if(B){this.enableDropzoneCursors(B.acceptCursor,B.rejectCursor)
+}this.observeEvents(C)
+},destroy:function(){if(this==this.tree.selectionManager.activeItem){this.tree.selectionManager.activeItem=null
+}for(var A=0;
+A<this.childs.length;
+A++){this.childs[A].destroy()
+}this.childs=null
+},observeEvents:function(E){var B=E.rows[0].cells;
+var A=null;
+var F=null;
+if("NETSCAPE"==RichFaces.navigatorType()){for(var D=0;
+D<B.length;
+D++){if(B[D].id==this.elementID.icon){A=B[D]
+}else{if(B[D].id==this.elementID.text){F=B[D]
+}}if(A&&F){break
+}}}else{var B=E.rows[0].cells;
+A=B[this.elementID.icon];
+F=B[this.elementID.text]
+}if(A){var C=Richfaces.getNSAttribute("oncontextmenu",A);
+if(C&&C.length>0){this.onContextMenu=new Function("event",C+"; return true;").bindAsEventListener(this)
+}}if(A){Event.observe(A,"mousedown",this.eventSelectionClick);
+Event.observe(A,"mouseout",this.eventMouseOut);
+Event.observe(A,"mouseover",this.eventMouseOver);
+if(this.onContextMenu){A.oncontextmenu=this.onContextMenu
+}}if(F){Event.observe(F,"mousedown",this.eventSelectionClick);
+Event.observe(F,"mouseout",this.eventMouseOut);
+Event.observe(F,"mouseover",this.eventMouseOver);
+if(this.onContextMenu){F.oncontextmenu=this.onContextMenu
+}}if(this.tree.switchType=="client"&&this.childs.length>0){this.eventCollapsionClick=this.toggleCollapsion.bindAsEventListener(this);
+var G=this.tree.toggleOnClick?this.elementID.mainRow:this.elementID.handle;
+Event.observe(G,"click",this.eventCollapsionClick)
+}},getElements:function(B,E){this.childs=[];
+var C=B.nextSibling;
+if(E&&this.tree.showConnectingLines){var A=B.rows[0].cells[0];
+if(A.style&&A.style.removeExpression){A.style.backgroundImage=A.currentStyle.backgroundImage;
+A.style.removeExpression("backgroundImage")
+}if(C){if(C.style&&C.style.removeExpression){C.style.backgroundImage=C.currentStyle.backgroundImage;
+C.style.removeExpression("backgroundImage")
+}}}if(C){var D=C.firstChild;
+while(D!=null){if(D.nodeType==1&&D.tagName.toLowerCase()=="table"){this.addChild(new Tree.Item(D,this.tree,this))
+}D=D.nextSibling
+}}},addChild:function(A){this.childs.push(A)
+},fireExpansionEvent:function(){var A=new Object();
+A[Richfaces.TreeExpandEvent]=true;
+A["expandedNode"]=this.id;
+A["treeItem"]=this;
+Richfaces.createEvent("click",this.tree.element,null,A).fire()
+},fireCollapsionEvent:function(){var A=new Object();
+A[Richfaces.TreeCollapseEvent]=true;
+A["collapsedNode"]=this.id;
+A["treeItem"]=this;
+Richfaces.createEvent("click",this.tree.element,null,A).fire()
+},toggleCollapsion:function(){var D=this.id+Tree.ID_DEVIDER+Tree.ID_CHILDS_ROW;
+if(this.hasChilds()){Element.toggle(D)
+}var C=$(this.elementID.mainRow);
+if(C){Element.hide(C);
+Element.show(C)
+}var B=$(this.id+"NodeExpanded");
+var A=$(this.elementID.icon);
+if(this.isCollapsed()){Element.hide(this.elementID.handleImgExpanded);
+Element.show(this.elementID.handleImgCollapsed);
+if(A&&Element.hasClassName(A,Tree.CLASS_ITEM_EXPANDED)){Element.removeClassName(A,Tree.CLASS_ITEM_EXPANDED);
+Element.addClassName(A,Tree.CLASS_ITEM_COLLAPSED)
+}if(B){B.value="false"
+}this.fireCollapsionEvent()
+}else{Element.show(this.elementID.handleImgExpanded);
+Element.hide(this.elementID.handleImgCollapsed);
+if(A&&Element.hasClassName(A,Tree.CLASS_ITEM_COLLAPSED)){Element.removeClassName(A,Tree.CLASS_ITEM_COLLAPSED);
+Element.addClassName(A,Tree.CLASS_ITEM_EXPANDED)
+}if(B){B.value="true"
+}this.fireExpansionEvent()
+}},getRichAttribute:function(A){return Richfaces.getNSAttribute(A,$(this.elementID.icon))
+},collapse:function(){if(!this.isCollapsed()&&this.tree.switchType!="client"){var B=$(this.tree.toggleOnClick?this.elementID.mainRow:this.elementID.handle);
+if(B){B.onclick()
+}}if(this.hasChilds()&&!this.isCollapsed()){Element.hide(this.elementID.children);
+Element.hide(this.elementID.handleImgExpanded);
+Element.show(this.elementID.handleImgCollapsed);
+var A=$(this.elementID.icon);
+if(A&&Element.hasClassName(A,Tree.CLASS_ITEM_EXPANDED)){Element.removeClassName(A,Tree.CLASS_ITEM_EXPANDED);
+Element.addClassName(A,Tree.CLASS_ITEM_COLLAPSED)
+}}this.fireCollapsionEvent()
+},expand:function(){if(this.isCollapsed()&&this.tree.switchType!="client"){var B=$(this.tree.toggleOnClick?this.elementID.mainRow:this.elementID.handle);
+if(B){B.onclick()
+}}if(this.hasChilds()&&this.isCollapsed()){Element.show(this.elementID.children);
+Element.show(this.elementID.handleImgExpanded);
+Element.hide(this.elementID.handleImgCollapsed);
+var A=$(this.elementID.icon);
+if(A&&Element.hasClassName(A,Tree.CLASS_ITEM_COLLAPSED)){Element.removeClassName(A,Tree.CLASS_ITEM_COLLAPSED);
+Element.addClassName(A,Tree.CLASS_ITEM_EXPANDED)
+}}this.fireExpansionEvent()
+},isCollapsed:function(){var A=$(this.elementID.children);
+if(A){return A.style.display=="none"
+}else{return true
+}},processMouseOut:function(C){if(this.isMouseIn){this.isMouseIn=false;
+var B=$(this.elementID.text);
+var E=Richfaces.getNSAttribute("highlightedclass",B);
+if(E){var D=E.split(" ");
+for(var A=0;
+A<D.length;
+A++){Element.removeClassName(B,D[A])
+}if(window.drag){this.dragLeave(C)
+}}}},processMouseOver:function(C){if(!this.isMouseIn){this.isMouseIn=true;
+var B=$(this.elementID.text);
+var E=Richfaces.getNSAttribute("highlightedclass",B);
+if(E){var D=E.split(" ");
+for(var A=0;
+A<D.length;
+A++){Element.addClassName(B,D[A])
+}if(window.drag){this.dragEnter(C)
+}}}},toggleSelection:function(G){if(G&&!G[Richfaces.TreeSelectEvent]&&!Richfaces.eventIsSynthetic(G)){if(G&&G.type=="mousedown"){if(Event.isLeftClick(G)){var A=Event.element(G);
+if(A.tagName&&/^(input|select|option|button|textarea)$/i.test(A.tagName)){return 
+}Event.stop(G)
+}else{return 
+}}var H=new Object();
+H[Richfaces.TreeSelectEvent]=true;
+H["originatingEventType"]=G.type;
+H["treeItem"]=this;
+H["selectedNode"]=this.id;
+var I=Richfaces.createEvent("click",this.tree.element,null,H);
+I.fire();
+return !I.event["cancelSelection"]
+}else{var E=this.tree.selectionManager.activeItem;
+if(E){E.deselect()
+}var F=$(this.elementID.text);
+var C=Richfaces.getNSAttribute("selectedclass",F);
+if(C){var B=C.split(" ");
+for(var D=0;
+D<B.length;
+D++){Element.addClassName(F,B[D])
+}this.tree.input.value=this.id;
+this.tree.selectionManager.activeItem=this;
+if(this.tree.options.onSelection){this.tree.options.onSelection(this.id)
+}this.tree.showNode(F.parentNode);
+if(G&&G["originatingEventType"]=="mousedown"){this.startDrag(G)
+}}return true
+}},isSelected:function(){return Element.hasClassName(this.elementID.text,Tree.CLASS_ITEM_SELECTED)
+},deselect:function(){var B=$(this.elementID.text);
+var D=Richfaces.getNSAttribute("selectedclass",B);
+if(D){var C=D.split(" ");
+for(var A=0;
+A<C.length;
+A++){Element.removeClassName(B,C[A])
+}}},next:function(){var B=this.parent.childs;
+for(var A=0;
+A<B.length-1;
+A++){if(B[A]==this){return B[A+1]
+}}return this
+},previous:function(){var B=this.parent.childs;
+for(var A=1;
+A<B.length;
+A++){if(B[A]==this){return B[A-1]
+}}return this
+},hasChilds:function(){return this.childs.length>0
+},getElement:function(){return $(this.id)
+}}
+
+Object.extend(Tree.Item.prototype,DnD.Dropzone.prototype);
+Object.extend(Tree.Item.prototype,DnD.Draggable.prototype);
+Object.extend(Tree.Item.prototype,{getAcceptedTypes:function(){var B=this.getDropzoneOptions();
+if(B){var A=B["acceptedTypes"];
+if(A){return A
+}}return[]
+},mergeParams:function(C){var A=C(this.tree.getElement());
+var B=C(this.getElement());
+if(A){if(B){Object.extend(A,B)
+}return A
+}else{return B
+}},getDnDDefaultParams:function(){return this.mergeParams(DnD.getDnDDefaultParams)
+},getDnDDragParams:function(){return this.mergeParams(DnD.getDnDDragParams)
+},getDnDDropParams:function(){return this.mergeParams(DnD.getDnDDropParams)
+},getDropzoneOptions:function(){var A=Richfaces.getNSAttribute("dropzoneoptions",$(this.elementID.icon));
+if(A){return A.parseJSON(EventHandlersWalk)
+}return null
+},drop:function(C,A){A.params[DnD.Dropzone.DROP_TARGET_ID]=this.id;
+var B=this.getDropzoneOptions();
+if(B&&B.parameters){Object.extend(A.params,B.parameters)
+}this.tree.drop.call(this,C,A)
+},getIndicator:function(){var C=this.getDraggableOptions();
+var B=C?C.dragIndicator:null;
+var A=$(B);
+if(!A){A=this.getOrCreateDefaultIndicator()
+}return A
+},ondragstart:function(C,A){A.params[this.id]=this.id;
+var B=this.getDraggableOptions();
+if(B&&B.parameters){Object.extend(A.params,B.parameters)
+}this.dragEnter(C)
+},ondragend:function(B,A){this.dragStarted=false
+},getDraggableOptions:function(){if(window.drag&&window.drag.treeDraggableOptions){return window.drag.treeDraggableOptions
+}var A=Richfaces.getNSAttribute("draggableoptions",$(this.elementID.icon));
+if(A){var B=A.parseJSON(EventHandlersWalk);
+if(window.drag){window.drag.treeDraggableOptions=B
+}return B
+}return null
+},getContentType:function(){var A=this.getDraggableOptions();
+if(A){return A["dragType"]
+}return""
+},getElement:function(){return $(this.elementID.text).parentNode
+}})
+
+if(!window.DW){window.DW={}
+}if(!window.Richfaces){window.Richfaces={}
+}sizeA=4;
+sizeB=40;
+function discardElement(A){var B=document.getElementById("IELeakGarbageBin");
+if(!B){B=document.createElement("DIV");
+B.id="IELeakGarbageBin";
+B.style.display="none";
+document.body.appendChild(B)
+}Event.unloadElementsCache(A);
+B.appendChild(A);
+B.innerHTML=""
+}Selection={};
+Selection.eventHandler=function(A){Event.stop(A)
+};
+Selection.eventHandler=Selection.eventHandler.bindAsEventListener(Selection);
+Selection.disableSelection=function(A){if(typeof A.onselectstart!="undefined"){Event.observe(A,"selectstart",this.eventHandler)
+}else{if(typeof A.style.MozUserSelect!="undefined"){A.style.MozUserSelect="none"
+}else{Event.observe(A,"mousedown",this.eventHandler)
+}}};
+Selection.enableSelection=function(A){if(typeof A.onselectstart!="undefined"){Event.stopObserving(A,"selectstart",this.eventHandler)
+}else{if(typeof A.style.MozUserSelect!="undefined"){A.style.MozUserSelect=""
+}else{Event.stopObserving(A,"mousedown",this.eventHandler)
+}}};
+ModalPanel=Class.create();
+var ieVersion=RichFaces.getIEVersion();
+if(ieVersion&&ieVersion<7){ModalPanel.disableSelects=true
+}ModalPanel.panels=new Array();
+A4J.AJAX.AddListener({onafterajax:function(D,C,E){var B=0;
+while(B<ModalPanel.panels.length){var A=ModalPanel.panels[B];
+if(Element.isUninitialized(A.markerId)){A.destroy();
+ModalPanel.panels.splice(B,1);
+B=0
+}else{B++
+}}}});
+ModalPanel.Context=Class.create();
+ModalPanel.Context.prototype={initialize:function(A){this.cdiv=A.contentTable;
+this.isPositionFixed=Richfaces.getComputedStyle(this.cdiv,"position")=="fixed"
+},left:function(A){return A
+},top:function(A){return A
+},width:function(){return $(this.cdiv).offsetWidth
+},height:function(){return $(this.cdiv).offsetHeight
+}};
+function getSizeElement(){var A;
+if(RichFaces.navigatorType()!=RichFaces.OPERA&&document.compatMode=="CSS1Compat"){A=document.documentElement
+}else{A=document.body
+}return A
+}ModalPanel.prototype={initialize:function(E,B){this.markerId=$(E);
+this.id=$(E+"Container");
+this.options=B;
+this.baseZIndex=this.options.zindex?this.options.zindex:100;
+this.minWidth=Math.max(this.options.minWidth,2*sizeA+2);
+this.minHeight=Math.max(this.options.minHeight,2*sizeA+2);
+this.div=E+"Div";
+this.cursorDiv=E+"CursorDiv";
+this.cdiv=E+"CDiv";
+this.contentDiv=E+"ContentDiv";
+this.contentTable=E+"ContentTable";
+this.shadowDiv=E+"ShadowDiv";
+this.context=new ModalPanel.Context(this);
+this.borders=new Array();
+if(this.options.resizeable){this.borders.push(new ModalPanel.Border(E+"ResizerNWU",this,"NW-resize",ModalPanel.Sizer.NWU));
+this.borders.push(new ModalPanel.Border(E+"ResizerN",this,"N-resize",ModalPanel.Sizer.N));
+this.borders.push(new ModalPanel.Border(E+"ResizerNEU",this,"NE-resize",ModalPanel.Sizer.NEU));
+this.borders.push(new ModalPanel.Border(E+"ResizerNEL",this,"NE-resize",ModalPanel.Sizer.NEL));
+this.borders.push(new ModalPanel.Border(E+"ResizerE",this,"E-resize",ModalPanel.Sizer.E));
+this.borders.push(new ModalPanel.Border(E+"ResizerSEU",this,"SE-resize",ModalPanel.Sizer.SEU));
+this.borders.push(new ModalPanel.Border(E+"ResizerSEL",this,"SE-resize",ModalPanel.Sizer.SEL));
+this.borders.push(new ModalPanel.Border(E+"ResizerS",this,"S-resize",ModalPanel.Sizer.S));
+this.borders.push(new ModalPanel.Border(E+"ResizerSWL",this,"SW-resize",ModalPanel.Sizer.SWL));
+this.borders.push(new ModalPanel.Border(E+"ResizerSWU",this,"SW-resize",ModalPanel.Sizer.SWU));
+this.borders.push(new ModalPanel.Border(E+"ResizerW",this,"W-resize",ModalPanel.Sizer.W));
+this.borders.push(new ModalPanel.Border(E+"ResizerNWL",this,"NW-resize",ModalPanel.Sizer.NWL))
+}if(this.options.moveable&&$(E+"Header")){this.header=new ModalPanel.Border(E+"Header",this,"move",ModalPanel.Header)
+}this.markerId.component=this;
+var A=$(this.div);
+if(A.style.setExpression){if(ModalPanel.disableSelects||Richfaces.getComputedStyle(A,"position")!="fixed"){A.style.position="absolute";
+var C=$(this.cursorDiv);
+C.style.position="absolute";
+A.style.width="1px";
+A.style.height="1px";
+C.style.width="1px";
+C.style.height="1px";
+var D=$(this.cdiv);
+D.style.position="absolute";
+D.mpUseExpr=true
+}}if(this.options.onhide&&this.options.onhide!=""){this.eventOnHide=new Function("event",this.options.onhide)
+}ModalPanel.panels.push(this);
+this.eventFirstOnfocus=this.firstOnfocus.bindAsEventListener(this);
+this.eventLastOnfocus=this.lastOnfocus.bindAsEventListener(this);
+this.firstHref=E+"FirstHref";
+this.lastHref=E+"LastHref";
+this.selectBehavior=B.selectBehavior
+},destroy:function(){this.traverseSelects(true);
+this.parent=null;
+this.firstOutside=null;
+this.lastOutside=null;
+if(this.header){this.header.destroy();
+this.header=null
+}for(var A=0;
+A<this.borders.length;
+A++){this.borders[A].destroy()
+}this.borders=null;
+if(this.floatedToBody){var B=this.id;
+var C=B.parentNode;
+if(C){C.removeChild(B);
+discardElement(B)
+}}this.markerId.component=null;
+this.markerId=null
+},initIframe:function(){if(this.contentWindow){Element.setStyle(this.contentWindow.document.body,{"margin":"0px 0px 0px 0px"})
+}else{}if("transparent"==Element.getStyle(document.body,"background-color")){this.allowTransparency=true
+}},traverseSelects:function(C){if(!ModalPanel.disableSelects){return 
+}var F=document.body.childNodes;
+for(var A=0;
+A<F.length;
+A++){var G=F[A];
+if(G!=this.id&&G.getElementsByTagName){var E=G.getElementsByTagName("SELECT");
+for(var D=0;
+D<E.length;
+D++){var B=E[D];
+if(this.selectBehavior&&"hide"==this.selectBehavior){if(C){if(B._mdwCount){B._mdwCount-=1;
+if(B._mdwCount==0){if(B._mdwHidden){Element.setStyle(B,{"visibility":B._mdwHidden});
+B._mdwHidden=undefined
+}else{Element.setStyle(B,{"visibility":""})
+}B._mdwCount=undefined
+}}}else{if(B._mdwCount){B._mdwCount+=1
+}else{if(B.style.visibility&&""!=B.style.visibility){B._mdwHidden=B.style.visibility
+}Element.setStyle(B,{"visibility":"hidden"});
+B._mdwCount=1
+}}}else{if(C){if(B._mdwCount){B._mdwCount-=1;
+if(B._mdwCount==0){if(B._mdwDisabled){B._mdwDisabled=undefined
+}else{B.disabled=false
+}B._mdwCount=undefined
+}}}else{if(B._mdwCount){B._mdwCount+=1
+}else{if(B.disabled){B._mdwDisabled=true
+}else{B.disabled=true
+}B._mdwCount=1
+}}}}}}},setLeft:function(B){var A=$(this.cdiv);
+if(A.mpUseExpr){A.mpLeft=B
+}else{A.style.left=B+"px"
+}},setTop:function(B){var A=$(this.cdiv);
+if(A.mpUseExpr){A.mpTop=B
+}else{A.style.top=B+"px"
+}},firstOnfocus:function(A){var B=$(this.firstHref);
+if(B){B.focus()
+}},lastOnfocus:function(A){var B=$(this.lastHref);
+if(B){B.focus()
+}},processAllFocusElements:function(A){if(A.focus&&/^a|input|select|button|textarea$/i.test(A.tagName)&&!A.disabled&&!/^hidden$/.test(A.type)&&!/^none$/.test(A.style.display)){this.execute(A)
+}else{if(A.id&&A.id==this.cdiv){this.inModalPanel=true
+}var B=A.firstChild;
+while(B){this.processAllFocusElements(B);
+B=B.nextSibling
+}if(A.id&&A.id==this.cdiv){this.inModalPanel=false
+}}},processTabindexes:function(A){if(!this.inModalPanel){if(!this.firstOutside){this.firstOutside=A
+}this.lastOutside=A;
+if(A.tabIndex){A.prevTabIndex=A.tabIndex
+}A.tabIndex=undefined;
+if(A.accesskey){A.prevAccesskey=A.accesskey
+}A.accesskey=undefined
+}},restoreTabindexes:function(A){if(!this.inModalPanel){if(A.prevTabIndex){A.tabIndex=A.prevTabIndex
+}if(A.prevAccesskey){A.accesskey=A.prevAccesskey
+}}},preventFocus:function(){this.execute=this.processTabindexes;
+this.processAllFocusElements(document);
+if(this.firstOutside){Event.observe(this.firstOutside,"focus",this.eventFirstOnfocus)
+}if(this.lastOutside&&this.lastOutside!=this.firstOutside){Event.observe(this.lastOutside,"focus",this.eventLastOnfocus)
+}},restoreFocus:function(){this.execute=this.restoreTabindexes;
+this.processAllFocusElements(document);
+if(this.firstOutside){Event.stopObserving(this.firstOutside,"focus",this.eventFirstOnfocus);
+this.firstOutside=null
+}if(this.lastOutside){Event.stopObserving(this.lastOutside,"focus",this.eventLastOnfocus);
+this.lastOutside=null
+}},show:function(R,L){var A=this.id;
+if(this.invokeEvent("show",R,null,A)){this.preventFocus();
+if(!this.floatedToBody){this.parent=A.parentNode;
+document.body.insertBefore(this.parent.removeChild(A),null);
+this.floatedToBody=true
+}var U=$(this.cdiv);
+var D=U.getElementsByTagName("form");
+if(this.options.keepVisualState&&D){this.formOnsubmit=this.setStateInput.bindAsEventListener(this);
+for(var S=0;
+S<D.length;
+S++){Event.observe(D[S],"submit",this.formOnsubmit)
+}}var G;
+if(ModalPanel.disableSelects&&!this.iframe){this.iframe=this.id.id+"IFrame";
+new Insertion.Top(U,'<iframe src="javascript:\'\'" frameborder="0" scrolling="no" id="'+this.iframe+'" style="position: absolute; width: 1px; height: 1px; background-color: white; overflow-y: hidden; z-index: 1;"></iframe>');
+G=$(this.iframe);
+Event.observe(G,"load",this.initIframe.bindAsEventListener(G))
+}var C={};
+this.userOptions={};
+if(!U.mpSet){Object.extend(C,this.options)
+}if(L){Object.extend(C,L);
+Object.extend(this.userOptions,L)
+}var M=$(this.contentDiv);
+if(this.options.autosized){M.style.overflow="";
+C.width=-1;
+C.height=-1;
+M.style.width="100%";
+M.style.height="100%"
+}else{if(C.width&&C.width==-1){C.width=300
+}if(C.height&&C.height==-1){C.height=200
+}}if(C.width&&C.width!=-1){if(this.minWidth>C.width){C.width=this.minWidth
+}M.style.width=C.width+(/px/.test(C.width)?"":"px")
+}if(C.height&&C.height!=-1){if(this.minHeight>C.height){C.height=this.minHeight
+}M.style.height=C.height+(/px/.test(C.height)?"":"px")
+}U.mpSet=true;
+this.traverseSelects();
+var V=$(this.div);
+if(V.style.position=="absolute"){var J='getSizeElement().clientWidth + "px"';
+var F='getSizeElement().clientHeight + "px"';
+V.style.setExpression("width",J);
+V.style.setExpression("height",F);
+var K=$(this.cursorDiv);
+K.style.setExpression("width",J);
+K.style.setExpression("height",F);
+var O='-Position.cumulativeOffset(this.parentNode)[0] + getSizeElement().scrollLeft + "px"';
+var I='-Position.cumulativeOffset(this.parentNode)[1] + getSizeElement().scrollTop + "px"';
+V.style.setExpression("left",O);
+V.style.setExpression("top",I);
+K.style.setExpression("left",O);
+K.style.setExpression("top",I);
+var H='(this.mpLeft || 0) + -Position.cumulativeOffset(this.parentNode)[0] + getSizeElement().scrollLeft + "px"';
+var N='(this.mpTop || 0) + -Position.cumulativeOffset(this.parentNode)[1] + getSizeElement().scrollTop + "px"';
+U.style.setExpression("left",H);
+U.style.setExpression("top",N)
+}A.style.visibility="hidden";
+Element.show(A);
+this.correctShadowSizeEx(M);
+if(C.left){var T;
+if(C.left!="auto"){T=parseInt(C.left,10)
+}else{var B=getSizeElement().clientWidth;
+if(RichFaces.navigatorType()==RichFaces.OPERA){T=(B-M.parentNode.getWidth())/2
+}else{var E=Richfaces.getComputedStyleSize(M.parentNode,"width");
+if(isNaN(E)){E=M.parentNode.clientWidth
+}T=(B-E)/2
+}}this.setLeft(T)
+}if(C.top){var Q;
+if(C.top!="auto"){Q=parseInt(C.top,10)
+}else{var B=getSizeElement().clientHeight;
+if(RichFaces.navigatorType()==RichFaces.OPERA){Q=(B-M.parentNode.getHeight())/2
+}else{var W=Richfaces.getComputedStyleSize(M.parentNode,"height");
+if(isNaN(W)){W=M.parentNode.clientHeight
+}Q=(B-W)/2
+}}this.setTop(Q)
+}if(this.options.autosized){this.observerSize=window.setInterval(this.correctShadowSize.bindAsEventListener(this),500)
+}this.doResizeOrMove(ModalPanel.Sizer.Diff.EMPTY);
+for(var P=0;
+P<this.borders.length;
+P++){this.borders[P].doPosition()
+}if(this.header){this.header.doPosition()
+}A.style.visibility="";
+this.lastOnfocus();
+var R={};
+R.parameters=L||{};
+this.shown=true
+}},startDrag:function(A){Selection.disableSelection(document.body)
+},endDrag:function(B){for(var A=0;
+A<this.borders.length;
+A++){this.borders[A].doPosition()
+}Selection.enableSelection(document.body)
+},hide:function(G,F){this.restoreFocus();
+this.traverseSelects(true);
+var A=$(this.div);
+var H=$(this.cdiv);
+if(A.style.removeExpression){A.style.removeExpression("width");
+A.style.removeExpression("height");
+A.style.removeExpression("left");
+A.style.removeExpression("top");
+var E=$(this.cursorDiv);
+E.style.removeExpression("width");
+E.style.removeExpression("height");
+E.style.removeExpression("left");
+E.style.removeExpression("top");
+H.style.removeExpression("left");
+H.style.removeExpression("top")
+}var D=$(this.id);
+Element.hide(D);
+if(this.floatedToBody&&this.parent){document.body.removeChild(D);
+this.parent.appendChild(D);
+this.floatedToBody=false
+}var G={};
+G.parameters=F||{};
+if(this.eventOnHide){this.eventOnHide(G)
+}var B=H.getElementsByTagName("form");
+if(this.options.keepVisualState&&B){for(var C=0;
+C<B.length;
+C++){Event.stopObserving(B[C],"submit",this.formOnsubmit)
+}}this.shown=false;
+if(this.options.autosized){window.clearInterval(this.observerSize)
+}},doResizeOrMove:function(L){var B={};
+var I={};
+var C={};
+var G=false;
+var F;
+var E=$(this.contentDiv);
+if(RichFaces.navigatorType()!=RichFaces.OPERA){F=Richfaces.getComputedStyleSize(E,"width")
+}else{F=parseInt(E.style.width.replace("px",""),10)
+}var A=F;
+F+=L.deltaWidth||0;
+if(F>=this.minWidth){if(L.deltaWidth){C.width=F+"px"
+}}else{if(L.deltaWidth){C.width=this.minWidth+"px";
+B.vx=A-this.minWidth
+}B.x=true
+}if(B.vx&&L.deltaX){L.deltaX=-B.vx
+}var K=$(this.cdiv);
+if(L.deltaX&&(B.vx||!B.x)){if(B.vx){L.deltaX=B.vx
+}var H;
+if(K.mpUseExpr){H=K.mpLeft||0;
+H+=L.deltaX;
+K.mpLeft=H;
+I.left=H+"px"
+}else{H=Richfaces.getComputedStyleSize(K,"left");
+H+=L.deltaX;
+I.left=H+"px"
+}}if(RichFaces.navigatorType()!=RichFaces.OPERA){F=Richfaces.getComputedStyleSize(E,"height")
+}else{F=parseInt(E.style.height.replace("px",""),10)
+}var A=F;
+F+=L.deltaHeight||0;
+if(F>=this.minHeight){if(L.deltaHeight){C.height=F+"px"
+}}else{if(L.deltaHeight){C.height=this.minHeight+"px";
+B.vy=A-this.minHeight
+}B.y=true
+}if(B.vy&&L.deltaY){L.deltaY=-B.vy
+}if(L.deltaY&&(B.vy||!B.y)){if(B.vy){L.deltaY=B.vy
+}var H;
+if(K.mpUseExpr){H=K.mpTop||0;
+H+=L.deltaY;
+K.mpTop=H;
+I.top=H+"px"
+}else{H=Richfaces.getComputedStyleSize(K,"top");
+H+=L.deltaY;
+I.top=H+"px"
+}}Element.setStyle(K,I);
+Element.setStyle(E,C);
+this.correctShadowSizeEx(E);
+Object.extend(this.userOptions,I);
+Object.extend(this.userOptions,C);
+var J=this.context.width();
+var D=this.context.height();
+this.context.reduced=null;
+if(J<=2*sizeB){this.context.reduced={};
+this.context.reduced.w=J
+}if(D<=2*sizeB){if(!this.context.reduced){this.context.reduced={}
+}this.context.reduced.h=D
+}if(this.header){this.header.doPosition()
+}return B
+},setStateInput:function(E){var D=Event.element(E);
+if(E&&D){var A=document.createElement("input");
+A.type="hidden";
+A.id=this.id.id+"OpenedState";
+A.name=this.id.id+"OpenedState";
+A.value=this.shown?"true":"false";
+D.appendChild(A);
+var C=$H(this.userOptions).keys();
+if(C){for(var B=0;
+B<C.length;
+B++){A=document.createElement("input");
+A.type="hidden";
+A.id=this.id.id+"StateOption_"+C[B];
+A.name=this.id.id+"StateOption_"+C[B];
+A.value=this.userOptions[C[B]];
+D.appendChild(A)
+}}return true
+}},correctShadowSize:function(B){var A=$(this.contentDiv);
+this.correctShadowSizeEx($(this.contentDiv))
+},correctShadowSizeEx:function(G){var E=$(this.shadowDiv);
+var D=$(this.iframe);
+var C=0;
+var B=0;
+if(!Richfaces.browser.isIE){C=E.offsetWidth-E.clientWidth;
+B=E.offsetHeight-E.clientHeight
+}var A=G.parentNode.offsetWidth;
+var F=G.parentNode.offsetHeight;
+E.style.width=(A-C)+"px";
+E.style.height=(F-B)+"px";
+if(D){D.style.width=A+"px";
+D.style.height=F+"px"
+}},invokeEvent:function(B,E,G,C){var D=this.options["on"+B];
+var A;
+if(D){var F;
+if(E){F=E
+}else{if(document.createEventObject){F=document.createEventObject()
+}else{if(document.createEvent){F=document.createEvent("Events");
+F.initEvent(B,true,false)
+}}}F.rich={component:this};
+F.rich.value=G;
+try{A=D.call(C,F)
+}catch(H){LOG.warn("Exception: "+H.Message+"\n[on"+B+"]")
+}}if(A!=false){A=true
+}return A
+}};
+Richfaces.findModalPanel=function(F){if(F){var D=(F.charAt(0)==":"?F:":"+F);
+for(var B=0;
+B<ModalPanel.panels.length;
+B++){var A=ModalPanel.panels[B];
+if(A&&A.markerId){var E=A.markerId.id;
+if(E){if(E.length>=D.length){var C=E.substring(E.length-D.length,E.length);
+if(C==D){return A.markerId
+}}}}}}};
+Richfaces.showModalPanel=function(E,D,C){var B=(RichFaces.MSIE==RichFaces.navigatorType())?function(H){if(document.readyState!="complete"){var G=arguments;
+var F=this;
+window.setTimeout(function(){G.callee.apply(F,G)
+},50)
+}else{H()
+}}:function(F){F()
+};
+var A=$(E);
+if(!A){A=Richfaces.findModalPanel(E)
+}B(function(){A.component.show(C,D)
+})
+};
+Richfaces.hideModalPanel=function(D,C,B){var A=$(D);
+if(!A){A=Richfaces.findModalPanel(D)
+}A.component.hide(B,C)
+}
+
+ModalPanel.Border=Class.create();
+ModalPanel.Border.prototype={initialize:function(E,C,D,B){this.id=E;
+var A=$(E);
+A.style.cursor=D;
+this.boundStartDrag=this.startDrag.bindAsEventListener(this,new Date());
+Event.observe(this.id,"mousedown",this.boundStartDrag);
+this.modalPanel=C;
+this.sizer=B;
+this.boundDoDrag=this.doDrag.bindAsEventListener(this);
+this.boundEndDrag=this.endDrag.bindAsEventListener(this)
+},destroy:function(){Event.stopObserving(this.id,"mousedown",this.boundStartDrag);
+this.modalPanel=null
+},show:function(){Element.show(this.id)
+},hide:function(){Element.hide(this.id)
+},startDrag:function(B){this.doingDrag=true;
+this.dragX=B.clientX;
+this.dragY=B.clientY;
+Event.observe(document,"mousemove",this.boundDoDrag);
+Event.observe(document,"mouseup",this.boundEndDrag);
+var A=$(this.modalPanel.cursorDiv);
+A.style.cursor=$(this.id).style.cursor;
+A.style.zIndex=8;
+this.modalPanel.startDrag(this);
+this.onselectStartHandler=document.onselectstart;
+document.onselectstart=function(){return false
+}
+},doDrag:function(A){if(!this.doingDrag){return 
+}var E=A.clientX;
+var B=A.clientY;
+var G=Richfaces.getWindowSize();
+if(E<0){E=0
+}else{if(E>=G.width){E=G.width-1
+}}if(B<0){B=0
+}else{if(B>=G.height){B=G.height-1
+}}var K=E-this.dragX;
+var J=B-this.dragY;
+if(K!=0||J!=0){var D=this.id;
+var I=this.sizer.doDiff(K,J);
+var H;
+var F=$(this.modalPanel.cdiv);
+if(D.indexOf("panelHeader")>0){H=this.modalPanel.invokeEvent("move",A,null,F)
+}else{H=this.modalPanel.invokeEvent("resize",A,null,F)
+}var C;
+if(H){C=this.modalPanel.doResizeOrMove(I)
+}if(C){if(!C.x){this.dragX=E
+}else{if(!I.deltaX){this.dragX-=C.vx||0
+}else{this.dragX+=C.vx||0
+}}if(!C.y){this.dragY=B
+}else{if(!I.deltaY){this.dragY-=C.vy||0
+}else{this.dragY+=C.vy||0
+}}}}},endDrag:function(A){this.doingDrag=undefined;
+Event.stopObserving(document,"mousemove",this.boundDoDrag);
+Event.stopObserving(document,"mouseup",this.boundEndDrag);
+this.modalPanel.endDrag(this);
+this.modalPanel.doResizeOrMove(ModalPanel.Sizer.Diff.EMPTY);
+$(this.modalPanel.cursorDiv).style.zIndex=-200;
+document.onselectstart=this.onselectStartHandler;
+this.onselectStartHandler=null;
+var B=this.id
+},doPosition:function(){this.sizer.doPosition(this.modalPanel,$(this.id))
+}};
+ModalPanel.Sizer=Class.create();
+ModalPanel.Sizer.Diff=Class.create();
+ModalPanel.Sizer.Diff.prototype={initialize:function(C,A,B,D){this.deltaX=C;
+this.deltaY=A;
+this.deltaWidth=B;
+this.deltaHeight=D
+}};
+ModalPanel.Sizer.Diff.EMPTY=new ModalPanel.Sizer.Diff(0,0,0,0);
+ModalPanel.Sizer.prototype={initialize:function(){},doSetupSize:function(E,B){var D=0;
+var A=0;
+var C=E.context;
+if(C.reduced){if(C.reduced.w){D=C.reduced.w/2
+}if(C.reduced.h){A=C.reduced.h/2
+}}if(D>0){if(B.clientWidth>D){if(!B.reducedWidth){B.reducedWidth=B.style.width
+}B.style.width=D+"px"
+}else{if(D<sizeB&&B.reducedWidth==sizeB+"px"){B.style.width=D+"px"
+}}}else{if(B.reducedWidth){B.style.width=B.reducedWidth;
+B.reducedWidth=undefined
+}}if(A>0){if(B.clientHeight>A){if(!B.reducedHeight){B.reducedHeight=B.style.height
+}B.style.height=A+"px"
+}else{if(A<sizeB&&B.reducedHeight==sizeB+"px"){B.style.height=A+"px"
+}}}else{if(B.reducedHeight){B.style.height=B.reducedHeight;
+B.reducedHeight=undefined
+}}},doSetupPosition:function(E,A,D,C){var B=E.context;
+A.style.left=B.left(D)+"px";
+A.style.top=B.top(C)+"px"
+},doPosition:function(B,A){},doDiff:function(B,A){}};
+ModalPanel.Sizer.NWU=Object.extend(new ModalPanel.Sizer(),{doPosition:function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,0,0)
+},doDiff:function(B,A){return new ModalPanel.Sizer.Diff(B,A,-B,-A)
+}});
+ModalPanel.Sizer.N=new ModalPanel.Sizer();
+ModalPanel.Sizer.N.doPosition=function(B,A){A.style.width=B.context.width()+"px";
+this.doSetupPosition(B,A,0,0)
+};
+ModalPanel.Sizer.N.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,A,0,-A)
+};
+ModalPanel.Sizer.NEU=new ModalPanel.Sizer();
+ModalPanel.Sizer.NEU.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,B.context.width()-A.clientWidth,0)
+};
+ModalPanel.Sizer.NEU.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,A,B,-A)
+};
+ModalPanel.Sizer.NEL=new ModalPanel.Sizer();
+ModalPanel.Sizer.NEL.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,B.context.width()-A.clientWidth,0)
+};
+ModalPanel.Sizer.NEL.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,A,B,-A)
+};
+ModalPanel.Sizer.E=new ModalPanel.Sizer();
+ModalPanel.Sizer.E.doPosition=function(B,A){A.style.height=B.context.height()+"px";
+this.doSetupPosition(B,A,B.context.width()-A.clientWidth,0)
+};
+ModalPanel.Sizer.E.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,0,B,0)
+};
+ModalPanel.Sizer.SEU=new ModalPanel.Sizer();
+ModalPanel.Sizer.SEU.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,B.context.width()-A.clientWidth,B.context.height()-A.clientHeight)
+};
+ModalPanel.Sizer.SEU.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,0,B,A)
+};
+ModalPanel.Sizer.SEL=new ModalPanel.Sizer();
+ModalPanel.Sizer.SEL.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,B.context.width()-A.clientWidth,B.context.height()-A.clientHeight)
+};
+ModalPanel.Sizer.SEL.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,0,B,A)
+};
+ModalPanel.Sizer.S=new ModalPanel.Sizer();
+ModalPanel.Sizer.S.doPosition=function(B,A){A.style.width=B.context.width()+"px";
+this.doSetupPosition(B,A,0,B.context.height()-A.clientHeight)
+};
+ModalPanel.Sizer.S.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(0,0,0,A)
+};
+ModalPanel.Sizer.SWL=new ModalPanel.Sizer();
+ModalPanel.Sizer.SWL.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,0,B.context.height()-A.clientHeight)
+};
+ModalPanel.Sizer.SWL.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(B,0,-B,A)
+};
+ModalPanel.Sizer.SWU=new ModalPanel.Sizer();
+ModalPanel.Sizer.SWU.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,0,B.context.height()-A.clientHeight)
+};
+ModalPanel.Sizer.SWU.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(B,0,-B,A)
+};
+ModalPanel.Sizer.W=new ModalPanel.Sizer();
+ModalPanel.Sizer.W.doPosition=function(B,A){A.style.height=B.context.height()+"px";
+this.doSetupPosition(B,A,0,0)
+};
+ModalPanel.Sizer.W.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(B,0,-B,0)
+};
+ModalPanel.Sizer.NWL=new ModalPanel.Sizer();
+ModalPanel.Sizer.NWL.doPosition=function(B,A){this.doSetupSize(B,A);
+this.doSetupPosition(B,A,0,0)
+};
+ModalPanel.Sizer.NWL.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(B,A,-B,-A)
+};
+ModalPanel.Header=new ModalPanel.Sizer();
+ModalPanel.Header.doPosition=function(B,A){};
+ModalPanel.Header.doDiff=function(B,A){return new ModalPanel.Sizer.Diff(B,A,0,0)
+}
+
+Object.extend(Event,{_domReady:function(){if(arguments.callee.done){return 
+}arguments.callee.done=true;
+if(Event._timer){clearInterval(Event._timer)
+}Event._readyCallbacks.each(function(A){A()
+});
+Event._readyCallbacks=null
+},onReady:function(B){if(!this._readyCallbacks){var A=this._domReady;
+if(A.done){return B()
+}if(document.addEventListener){document.addEventListener("DOMContentLoaded",A,false)
+}if(/WebKit/i.test(navigator.userAgent)){this._timer=setInterval(function(){if(/loaded|complete/.test(document.readyState)){A()
+}},10)
+}Event.observe(window,"load",A);
+Event._readyCallbacks=[]
+}Event._readyCallbacks.push(B)
+}});
+Array.prototype.remove=function(B){var A=this.indexOf(B,0,this.length);
+if(A==-1){return 
+}if(A==0){this.shift()
+}else{this.splice(A,1)
+}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.getExternalClass=function(C,B){if(C){var A=C.length;
+while(B>=A){B-=A
+}return(C[B])?C[B]:""
+}return""
+};
+Richfaces.SelectItem=Class.create();
+Richfaces.SelectItem.prototype={initialize:function(A,C,B){this._label=A;
+this._node=B;
+this._node.item=this;
+this._id=C;
+this.input=$(B.id+"StateInput");
+this.selected=/^s/.test(this.input.value);
+this.active=/^s?a/.test(this.input.value)
+},doActive:function(E,C){var B=this.CLASSES;
+var F=this._node;
+var A=B.ROW.ACTIVE;
+var D=B.CELL.ACTIVE;
+if(this.isSelected()){A=B.ROW.SELECTED+" "+B.ROW.ACTIVE;
+D=B.CELL.SELECTED+" "+B.CELL.ACTIVE
+}this.changeClass(F,A,D,E,C);
+this.active=true;
+this.saveState()
+},doSelect:function(C,B){var D=this._node;
+var A=this.CLASSES;
+this.changeClass(D,A.ROW.SELECTED,A.CELL.SELECTED,C,B);
+this.selected=true;
+this.saveState()
+},doNormal:function(C,B){var D=this._node;
+var A=this.CLASSES;
+this.changeClass(D,A.ROW.NORMAL,A.CELL.NORMAL,C,B);
+this.active=false;
+this.selected=false;
+this.saveState()
+},isSelected:function(){return this.selected
+},isActive:function(){return this.active
+},changeClass:function(H,G,E,F,D){H.className=F+" "+G;
+var B=H.cells;
+for(var C=0;
+C<B.length;
+C++){var A=B[C];
+A.className=Richfaces.getExternalClass(D,A.cellIndex)+" "+E
+}},saveState:function(){var A=/^s?a?/;
+if(this.selected&&this.active){this.input.value=this.input.value.replace(A,"sa")
+}else{if(this.selected){this.input.value=this.input.value.replace(A,"s")
+}else{if(this.active){this.input.value=this.input.value.replace(A,"a")
+}else{this.input.value=this.input.value.replace(A,"")
+}}}}}
+
+LayoutManager=function(A,C){this.headerTable=$(A);
+this.contentTable=$(C);
+this.headerDiv=(this.headerTable)?this.headerTable.parentNode:null;
+this.contentDiv=this.contentTable.parentNode;
+var B=this;
+if(window.attachEvent){this.contentDiv.attachEvent("onscroll",function(){B.scrollHandler(B)
+})
+}else{this.contentDiv.addEventListener("scroll",function(){B.scrollHandler(B)
+},true)
+}};
+LayoutManager.SCROLL_WIDTH=17;
+LayoutManager.STYLE_CONTENTTD_BORDER=1;
+LayoutManager.STYLE_CONTENTTD_PADDING=4;
+LayoutManager.prototype.widthSynchronization=function(){var E=this.contentTable.tBodies[0].rows;
+if(E&&E[0]){var G=E[0].cells;
+if(!this.headerTable||!this.headerTable.tHead){return 
+}var B=this.headerTable.tHead.rows[0].cells;
+var D;
+for(var C=0;
+C<G.length;
+C++){var F=G[C];
+var A=B[C];
+D=LayoutManager.calculateWidth(F,A).colWidth;
+if(C==G.length-1){D=D+this.getScrollWidth()
+}A.firstChild.style.width=D+"px";
+A.style.width=D+"px"
+}}else{if(this.headerTable&&this.headerTable.tHead){this.headerTable.style.width="100%"
+}}};
+LayoutManager.prototype.getScrollWidth=function(){if(this.contentDiv.clientWidth!=0){return this.contentDiv.offsetWidth-this.contentDiv.clientWidth
+}return 0
+};
+LayoutManager.prototype.scrollHandler=function(A){if(A.headerDiv){A.headerDiv.scrollLeft=A.contentDiv.scrollLeft
+}};
+LayoutManager.getHeaderWidth=function(A,B){return B.offsetWidth+(A.offsetWidth-A.clientWidth)
+};
+LayoutManager.isIE=function(){return(/MSIE/.test(navigator.userAgent)&&!window.opera)
+};
+LayoutManager.getElemXY=function(C){var A=C.offsetLeft;
+var D=C.offsetTop;
+for(var B=C.offsetParent;
+B;
+B=B.offsetParent){A+=B.offsetLeft;
+D+=B.offsetTop
+}return{left:A,top:D}
+};
+LayoutManager.calculateWidth=function(G,B){var H=LayoutManager.getBorderWidth(G,"lr");
+var J=LayoutManager.getPaddingWidth(G,"lr");
+var E=LayoutManager.getMarginWidth(G,"lr");
+var C=LayoutManager.getBorderWidth(B,"lr");
+var I=LayoutManager.getPaddingWidth(B,"lr");
+var A=LayoutManager.getMarginWidth(B,"lr");
+var D=G.offsetWidth-H-J-E;
+var F=D+(H-C)+(J-I)+(E-A);
+F=(F>0)?F:0;
+return{srcWidth:D,colWidth:F}
+};
+LayoutManager.getBorderWidth=function(B,A){return LayoutManager.getStyles(B,A,LayoutManager.borders)
+};
+LayoutManager.getPaddingWidth=function(B,A){return LayoutManager.getStyles(B,A,LayoutManager.paddings)
+};
+LayoutManager.getMarginWidth=function(B,A){return LayoutManager.getStyles(B,A,LayoutManager.margins)
+};
+LayoutManager.getStyles=function(D,F,E){var G=0;
+for(var C=0,A=F.length;
+C<A;
+C++){var B=parseInt(Element.getStyle(D,E[F.charAt(C)]),10);
+if(!isNaN(B)){G+=B
+}}return G
+};
+LayoutManager.borders={l:"border-left-width",r:"border-right-width",t:"border-top-width",b:"border-bottom-width"},LayoutManager.paddings={l:"padding-left",r:"padding-right",t:"padding-top",b:"padding-bottom"},LayoutManager.margins={l:"margin-left",r:"margin-right",t:"margin-top",b:"margin-bottom"}
+
+Control=Class.create();
+Control.eventStub=function(){return false
+};
+Control.onfocus=function(A){A.hasFocus=true
+};
+Control.onblur=function(A){A.hasFocus=undefined
+};
+Control.prototype.initialize=function(A,E,D,B,C){this.disabledNode=E;
+this.disabledNode.onselectstart=Control.eventStub;
+this.enabledNode=A;
+this.enabledNode.onselectstart=Control.eventStub;
+this.isShown=D;
+this.isEnabled=B;
+this.action=C
+};
+Control.prototype.doShow=function(){this.isShown=true;
+if(this.isEnabled){this.doHideNode(this.disabledNode);
+this.doShowNode(this.enabledNode)
+}else{this.doHideNode(this.enabledNode);
+this.doShowNode(this.disabledNode)
+}};
+Control.prototype.doHide=function(){this.isShown=false;
+this.doHideNode(this.disabledNode);
+this.doHideNode(this.enabledNode)
+};
+Control.prototype.doEnable=function(){this.isEnabled=true;
+this.doHideNode(this.disabledNode);
+this.doShowNode(this.enabledNode)
+};
+Control.prototype.doDisable=function(){this.isEnabled=false;
+var B=this.enabledNode.select("a[id='"+this.enabledNode.id+"link']");
+var C=undefined;
+if(B&&B[0]){var D=B[0];
+if(D.hasFocus){var A=this.disabledNode.select("a[id='"+this.disabledNode.id+"link']");
+if(A&&A[0]){C=A[0]
+}}}this.doHideNode(this.enabledNode);
+this.doShowNode(this.disabledNode);
+if(C&&C.focus){C.disabled=false;
+C.focus();
+C.disabled=true
+}};
+Control.prototype.doHideNode=function(A){A.hide()
+};
+Control.prototype.doShowNode=function(A){A.show()
+}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.disableSelectionText=function(A){A.onselectstart=function(C){C=window.event||C;
+if(C.srcElement){if(C.srcElement.tagName){var B=C.srcElement.tagName.toUpperCase();
+if(B!="INPUT"&&B!="TEXTAREA"){return false
+}}}}
+};
+Richfaces.ListBase=Class.create();
+Richfaces.ListBase.compare=function(B,A){return((B==A)?0:((B<A)?-1:1))
+};
+Richfaces.ListBase.ORDERING_LIST_CLASSES={normal:"rich-ordering-list-items",disabled:"rich-ordering-list-disabled",active:"rich-ordering-list-active"};
+Richfaces.ListBase.ASC="acs";
+Richfaces.ListBase.DESC="desc";
+Richfaces.ListBase.CONTROL_SET=["A","INPUT","TEXTAREA","SELECT","OPTION","BUTTON"];
+Richfaces.ListBase.prototype={initialize:function(C,H,D,B,G,F,A,E){this.selectedItems=new Array();
+this.container=$(C);
+this.shuttleTable=$(H);
+Richfaces.disableSelectionText(this.shuttleTable);
+this.focusKeeper=$(B);
+this.focusKeeper.focused=false;
+this.focusKeeper.observe("keydown",(function(I){this.onkeydownHandler(window.event||I)
+}).bindAsEventListener(this));
+this.focusKeeper.observe("blur",function(I){this.focusListener(I)
+}.bindAsEventListener(this));
+this.focusKeeper.observe("focus",function(I){this.onfocusHandler(I)
+}.bindAsEventListener(this));
+this.shuttleTbody=this.shuttleTable.tBodies[0];
+this.activeItem=null;
+this.pseudoActiveItem=null;
+this.items=null;
+this.rowClasses=E;
+this.columnsClasses=A;
+this.retrieveShuttleItems(C,F);
+this.shuttle=null;
+this.sortOrder=Richfaces.ListBase.ASC;
+this.clckHandler=function(I){this.onclickHandler(window.event||I)
+}.bindAsEventListener(this);
+this.shuttleTable.observe("click",this.clckHandler)
+},setActiveItem:function(A){this.pseudoActiveItem=A;
+this.activeItem=A
+},retrieveShuttleItems:function(A,F){var D=this.shuttleTbody.rows;
+this.shuttleItems=new Array();
+var G;
+for(var B=0;
+B<D.length;
+B++){var E=D[B];
+G=E.id.split(A+":")[1];
+var C=new F(null,(G||B),E);
+if(C.isSelected()){this.selectedItems.push(E)
+}if(C.isActive()){this.setActiveItem(E)
+}this.shuttleItems[B]=C
+}},getExtremeItem:function(A){var D=this.selectedItems[0];
+var C;
+for(var B=1;
+B<this.selectedItems.length;
+B++){C=this.selectedItems[B];
+if(A=="first"){if(C.rowIndex<D.rowIndex){D=C
+}}else{if(C.rowIndex>D.rowIndex){D=C
+}}}return D
+},getEventTargetRow:function(A){var B;
+if(A.rangeParent){B=A.target
+}else{B=A.srcElement
+}if(B==null){return 
+}if(B.tagName&&Richfaces.ListBase.CONTROL_SET.indexOf(B.tagName.toUpperCase())!=-1){return 
+}while(B.tagName.toLowerCase()!="tr"){B=B.parentNode;
+if(!B.tagName){return 
+}}return B
+},onfocusHandler:function(A){if(!this.activeItem&&this.shuttleItems.length!=0){this.setActiveItem(this.shuttleItems[0]._node)
+}if(this.activeItem){this.activeItem.item.doActive(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses)
+}},onclickHandler:function(A){if(A.srcElement&&(A.srcElement.tagName.toLowerCase()=="tbody")){return 
+}var B=this.getEventTargetRow(A);
+if(B!=null){if(A.ctrlKey){this.addSelectedItem(B);
+this.setActiveItem(B)
+}else{if(A.shiftKey){this.selectItemGroup(B);
+this.activeItem=B
+}else{this.selectionItem(B);
+this.setActiveItem(B)
+}}this.setFocus()
+}},onkeydownHandler:function(A){var B=null;
+switch(A.keyCode){case 38:B="up";
+this.moveActiveItem(B,A);
+break;
+case 40:B="down";
+this.moveActiveItem(B,A);
+break;
+case 65:if(A.ctrlKey){this.selectAll();
+Event.stop(A)
+}this.activeItem.item.doActive(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses);
+break
+}},moveActiveItem:function(D,B){var A=this.activeItem;
+var C=this.shuttleTbody.rows;
+if((D=="up")&&(A.rowIndex>0)){this.changeActiveItems(C[A.rowIndex-1],A)
+}else{if((D=="down")&&(A.rowIndex<this.shuttleItems.length-1)){this.changeActiveItems(C[A.rowIndex+1],A)
+}}this.autoScrolling(D,B)
+},changeActiveItems:function(A,B){B.item.doNormal();
+this.resetMarked();
+A.item.doSelect(this.getExtRowClass(A.rowIndex),this.columnsClasses);
+A.item.doActive(this.getExtRowClass(A.rowIndex),this.columnsClasses);
+this.setActiveItem(A);
+this.selectedItems.push(A)
+},selectAll:function(){this.resetMarked();
+var B=0;
+var A=this.shuttleItems.length-1;
+this.selectItemRange(B,A)
+},selectionItem:function(B){var A=B;
+this.resetMarked();
+if(B.item.isSelected()){B.item.doNormal(this.getExtRowClass(B.rowIndex),this.columnsClasses)
+}else{B.item.doSelect(this.getExtRowClass(B.rowIndex),this.columnsClasses);
+this.selectedItems[0]=A
+}},addSelectedItem:function(B){var A=B;
+if(B.item.isSelected()){this.selectedItems.remove(A);
+B.item.doNormal(this.getExtRowClass(B.rowIndex),this.columnsClasses)
+}else{B.item.doSelect(this.getExtRowClass(B.rowIndex),this.columnsClasses);
+this.selectedItems.push(A)
+}if((this.activeItem!=null)&&(this.activeItem.rowIndex!=B.rowIndex)){if(this.activeItem.item.isSelected()){this.activeItem.item.doSelect(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses)
+}else{this.activeItem.item.doNormal(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses)
+}}},selectItemGroup:function(B){var A=this.pseudoActiveItem.rowIndex;
+var D;
+var C;
+if(B.rowIndex>A){D=A;
+C=B.rowIndex
+}else{D=B.rowIndex;
+C=A
+}this.resetMarked();
+this.selectItemRange(D,C)
+},selectItemRange:function(D,C){var B=this.shuttleTbody.rows;
+for(var A=D;
+A<=C;
+A++){B[A].item.doSelect(this.getExtRowClass(B[A].rowIndex),this.columnsClasses);
+this.selectedItems.push(B[A])
+}},resetMarked:function(){var C=this.selectedItems;
+var B=C.length;
+for(var A=0;
+A<B;
+A++){var D=C[A];
+D.item.doNormal(this.getExtRowClass(D.rowIndex),this.columnsClasses)
+}this.selectedItems.length=0
+},getSelectItemByNode:function(C){for(var A=0;
+A<this.shuttleItems.length;
+A++){var B=this.shuttleItems[A];
+if(C.rowIndex==B._node.rowIndex){return B
+}}return null
+},autoScrolling:function(G,F){this.selectedItems.sort(this.compareByRowIndex);
+var A;
+var H=this.shuttleTable.parentNode.scrollTop;
+var B=LayoutManager.getElemXY(this.shuttleTable.parentNode).top;
+if(G=="up"||G=="first"){var C=LayoutManager.getElemXY(this.selectedItems[0]).top;
+A=(C-H)-B;
+if(A<0){this.shuttleTable.parentNode.scrollTop+=A
+}}else{if(G=="down"||G=="last"){var E=this.selectedItems[this.selectedItems.length-1];
+var D=LayoutManager.getElemXY(this.selectedItems[this.selectedItems.length-1]).top+E.offsetHeight;
+var A=(D-H)-(B+this.shuttleTable.parentNode.clientHeight);
+if(A>0){this.shuttleTable.parentNode.scrollTop+=A
+}}}Event.stop(F)
+},setFocus:function(){this.focusKeeper.focus();
+this.focusKeeper.focused=true
+},focusListener:function(A){A=A||window.event;
+this.focusKeeper.focused=false;
+if(this.activeItem){if(this.activeItem.item.isSelected()){this.activeItem.item.doSelect(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses)
+}else{this.activeItem.item.doNormal(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses)
+}}},compareByLabel:function(B,A){B=B._label;
+A=A._label;
+return Richfaces.ListBase.compare(B,A)
+},compareByRowIndex:function(B,A){B=B.rowIndex;
+A=A.rowIndex;
+return Richfaces.ListBase.compare(B,A)
+},isListActive:function(){if((this.activeItem!=null||this.selectedItems.length!=0)&&this.focusKeeper.focused){return true
+}return false
+},getExtRowClass:function(A){return Richfaces.getExternalClass(this.rowClasses,A)
+}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.OrderingListSelectItem=Class.create(Richfaces.SelectItem);
+Richfaces.OrderingListSelectItem.prototype.CLASSES={ROW:{ACTIVE:"rich-ordering-list-row-active",SELECTED:"rich-ordering-list-row-selected",DISABLED:"rich-ordering-list-row-disabled",NORMAL:"rich-ordering-list-row"},CELL:{ACTIVE:"rich-ordering-list-cell-active",SELECTED:"rich-ordering-list-cell-selected",DISABLED:"rich-ordering-list-cell-disabled",NORMAL:"rich-ordering-list-cell",BEGIN:" rich-ordering-list-cell-first",END:" rich-ordering-list-cell-last"}},Richfaces.OrderingList=Class.create(Richfaces.ListBase,{initialize:function($super,F,H,D,G,A,E,I,J,B,C){$super(F,H,D,G,E,J,B,C);
+if(I){this.container.observe("rich:onorderchanged",I)
+}this.controlList=new Array();
+this.initControlList(F,A)
+},initControlList:function(A,D){for(var C=0;
+C<D.length;
+C++){var F=D[C];
+var E=$(A+F[0]);
+var B=$(A+F[1]);
+if(E&&B){E.observe("click",Richfaces.OrderingList.HANDLERS[F[0]].bindAsEventListener(this));
+this.controlList[C]=new Control(E,B,false,false,F[0])
+}}},controlListManager:function(){this.selectedItems.sort(this.compareByRowIndex);
+var A;
+this.controlsProcessing(["first","last","down","up"],"enable");
+if((this.shuttleItems.length==0)||(this.selectedItems.length==0)){this.controlsProcessing(["first","last","down","up"],"disable")
+}else{if(this.selectedItems[0].rowIndex==0){this.controlsProcessing(["first","up"],"disable")
+}if(this.selectedItems[this.selectedItems.length-1].rowIndex==(this.shuttleItems.length-1)){this.controlsProcessing(["down","last"],"disable")
+}}},controlsProcessing:function(C,B){for(var A=0;
+A<this.controlList.length;
+A++){control=this.controlList[A];
+if(control!=null){if(C!=null&&C.indexOf(control.action)!=-1){if(B=="disable"){control.doDisable()
+}else{control.doEnable()
+}}}}},onclickHandler:function($super,A){$super(A);
+this.controlListManager()
+},moveActiveItem:function($super,B,A){$super(B,A);
+this.controlListManager()
+},moveSelectedItems:function(F,D){D=window.event||D;
+var E=this.shuttleTbody.rows;
+var C;
+if(this.selectedItems.length>0){this.selectedItems.sort(this.compareByRowIndex);
+if((F=="up")&&this.getExtremeItem("first").previousSibling){for(var A=0;
+A<this.selectedItems.length;
+A++){C=this.selectedItems[A];
+C.parentNode.insertBefore(C,C.previousSibling)
+}}else{if((F=="down")&&this.getExtremeItem("last").nextSibling){for(var A=this.selectedItems.length-1;
+A>-1;
+A--){C=this.selectedItems[A];
+C.parentNode.insertBefore(C.nextSibling,C)
+}}else{if(F=="first"){var G=this.selectedItems[0].rowIndex;
+for(var A=0;
+A<this.selectedItems.length;
+A++){C=this.selectedItems[A];
+C.parentNode.insertBefore(C,E[C.rowIndex-G])
+}}else{if(F=="last"){var B=this.shuttleItems.length;
+var G=B-this.selectedItems[this.selectedItems.length-1].rowIndex;
+for(var A=this.selectedItems.length-1;
+A>-1;
+A--){C=this.selectedItems[A];
+if(C.rowIndex+G>B-1){C.parentNode.insertBefore(C,null)
+}else{C.parentNode.insertBefore(C,E[C.rowIndex+G])
+}}}}}}this.shuttleItems=new Array();
+for(var A=0;
+A<E.length;
+A++){this.shuttleItems.push(E[A].item)
+}if(F!=null){this.autoScrolling(F,D)
+}this.container.fire("rich:onorderchanged",{});
+this.controlListManager()
+}},onkeydownHandler:function(A){var B=null;
+switch(A.keyCode){case 34:B="last";
+this.moveSelectedItems(B,A);
+break;
+case 33:B="first";
+this.moveSelectedItems(B,A);
+break;
+case 38:B="up";
+if(A.ctrlKey){this.moveSelectedItems(B,A)
+}else{this.moveActiveItem(B,A)
+}break;
+case 40:B="down";
+if(A.ctrlKey){this.moveSelectedItems(B,A)
+}else{this.moveActiveItem(B,A)
+}break;
+case 65:if(A.ctrlKey){this.selectAll();
+Event.stop(A)
+}this.activeItem.item.doActive(this.getExtRowClass(this.activeItem.rowIndex),this.columnsClasses);
+this.controlListManager();
+break
+}}});
+Richfaces.OrderingList.ACTIVITY_MARKER="a";
+Richfaces.OrderingList.SELECTION_MARKER="s";
+Richfaces.OrderingList.ITEM_SEPARATOR=",";
+Richfaces.OrderingList.HANDLERS={first:function(A){this.moveSelectedItems("first",A);
+return false
+},last:function(A){this.moveSelectedItems("last",A);
+return false
+},up:function(A){this.moveSelectedItems("up",A);
+return false
+},down:function(A){this.moveSelectedItems("down",A);
+return false
+}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.ListShuttle=Class.create();
+Richfaces.ListShuttle.Source=Class.create(Richfaces.ListBase);
+Richfaces.ListShuttle.Target=Class.create(Richfaces.OrderingList);
+Richfaces.ListShuttle.Source.SelectItem=Class.create(Richfaces.SelectItem);
+Richfaces.ListShuttle.Source.SelectItem.prototype.CLASSES={ROW:{ACTIVE:"rich-shuttle-source-row-active",SELECTED:"rich-shuttle-source-row-selected",DISABLED:"rich-shuttle-source-row-disabled",NORMAL:"rich-shuttle-source-row"},CELL:{ACTIVE:"rich-shuttle-source-cell-active",SELECTED:"rich-shuttle-source-cell-selected",DISABLED:"rich-shuttle-source-cell-disabled",NORMAL:"rich-shuttle-source-cell",BEGIN:" rich-shuttle-source-cell-first",END:" rich-shuttle-source-cell-last"}};
+Richfaces.ListShuttle.Target.SelectItem=Class.create(Richfaces.SelectItem);
+Richfaces.ListShuttle.Target.SelectItem.prototype.CLASSES={ROW:{ACTIVE:"rich-shuttle-target-row-active",SELECTED:"rich-shuttle-target-row-selected",DISABLED:"rich-shuttle-target-row-disabled",NORMAL:"rich-shuttle-target-row"},CELL:{ACTIVE:"rich-shuttle-target-cell-active",SELECTED:"rich-shuttle-target-cell-selected",DISABLED:"rich-shuttle-target-cell-disabled",NORMAL:"rich-shuttle-target-cell",BEGIN:" rich-shuttle-target-cell-first",END:" rich-shuttle-target-cell-last"}};
+Richfaces.ListShuttle.prototype={initialize:function(H,F,A,E,G,B,D,C){this.containerId=A;
+this.targetList=H;
+this.sourceList=F;
+this.targetLayoutManager=D;
+this.sourceLayoutManager=B;
+if(G=="true"){this.targetList.shuttleTable.observe("click",function(I){this.moveItemByClick(window.event||I,this.targetList,this.sourceList)
+}.bindAsEventListener(this));
+this.sourceList.shuttleTable.observe("click",function(I){this.moveItemByClick(window.event||I,this.sourceList,this.targetList)
+}.bindAsEventListener(this));
+Event.stopObserving(this.sourceList.shuttleTable,"click",this.sourceList.clckHandler);
+Event.stopObserving(this.targetList.shuttleTable,"click",this.targetList.clckHandler)
+}else{this.targetList.shuttleTable.observe("dblclick",function(I){this.moveItemByClick(window.event||I,this.targetList,this.sourceList)
+}.bindAsEventListener(this));
+this.sourceList.shuttleTable.observe("dblclick",function(I){this.moveItemByClick(window.event||I,this.sourceList,this.targetList)
+}.bindAsEventListener(this));
+F._onclickHandler=F.onclickHandler;
+F.onclickHandler=function(I){this.onclickHandler(I,F)
+}.bindAsEventListener(this);
+H._onclickHandler=H.onclickHandler;
+H.onclickHandler=function(I){this.onclickHandler(I,H)
+}.bindAsEventListener(this)
+}F._onkeydownHandler=F.onkeydownHandler;
+F.onkeydownHandler=function(I){this.onkeydownHandler(I,F)
+}.bindAsEventListener(this);
+H._onkeydownHandler=H.onkeydownHandler;
+H.onkeydownHandler=function(I){this.onkeydownHandler(I,H)
+}.bindAsEventListener(this);
+this.controlList=new Array();
+this.initControlList(A,E);
+if(C){this.targetList.container.observe("rich:onorderchanged",C);
+$(this.containerId).observe("rich:onlistchanged",C)
+}},initControlList:function(A,D){for(var C=0;
+C<D.length;
+C++){var F=D[C];
+var E=$(A+F[0]);
+var B=$(A+F[1]);
+if(E&&B){E.observe("click",Richfaces.ListShuttle.HANDLERS[F[0]].bindAsEventListener(this));
+this.controlList[C]=new Control(E,B,false,false,F[0])
+}}},controlListManager:function(){this.controlsProcessing(["copy","copyAll","removeAll","remove"],"enable");
+if(this.sourceList.shuttleItems.length<1){this.controlsProcessing(["copy","copyAll"],"disable")
+}if(this.sourceList.selectedItems.length<1){this.controlsProcessing(["copy"],"disable")
+}if(this.targetList.shuttleItems.length<1){this.controlsProcessing(["removeAll","remove"],"disable")
+}if(this.targetList.selectedItems.length<1){this.controlsProcessing(["remove"],"disable")
+}},onclickHandler:function(B,A){A._onclickHandler(B);
+this.controlListManager();
+Event.stop(B)
+},onkeydownHandler:function(B,A){A._onkeydownHandler(B);
+this.controlListManager();
+if(B.keyCode!=Event.KEY_TAB){Event.stop(B)
+}},controlsProcessing:function(C,B){for(var A=0;
+A<this.controlList.length;
+A++){control=this.controlList[A];
+if(control!=null){if(C!=null&&C.indexOf(control.action)!=-1){if(B=="disable"){control.doDisable()
+}else{control.doEnable()
+}}}}},moveItems:function(E,F,A){if(A.length>0){var D=A.length;
+for(var B=0;
+A.length>0;
+){var C=A[B];
+this.moveItem(E,F,C)
+}this.controlListManager();
+this.targetList.controlListManager();
+this.targetLayoutManager.widthSynchronization();
+this.sourceLayoutManager.widthSynchronization();
+$(this.containerId).fire("rich:onlistchanged",{})
+}},moveItem:function(C,D,B){if(!(B instanceof Richfaces.SelectItem)){B=C.getSelectItemByNode(B)
+}if(!LayoutManager.isIE()&&(D.shuttleTbody.rows.length==0)){var A=null;
+if(B instanceof Richfaces.ListShuttle.Target.SelectItem){A=new Richfaces.ListShuttle.Target.SelectItem(B._label,B._id,B._node.cloneNode(true))
+}else{A=new Richfaces.ListShuttle.Source.SelectItem(B._label,B._id,B._node.cloneNode(true))
+}this.tableUpdate(D);
+this.addItem(D,A);
+this.removeItem(C,B);
+C.shuttleTable.deleteRow(B._node.rowIndex)
+}else{this.addItem(D,B);
+this.removeItem(C,B)
+}},removeItem:function(B,C){var A=B.shuttleItems;
+B.selectedItems.remove(C._node);
+A.remove(C);
+if(C==B.activeItem){B.activeItem==null
+}},addItem:function(A,B){B.doNormal(Richfaces.getExternalClass(B.rowIndex),A.columnsClasses);
+A.shuttleTbody.insertBefore(B._node,null);
+A.shuttleItems.push(B)
+},tableUpdate:function(B){var C=B.shuttleTable;
+C.removeChild(C.tBodies[0]);
+var A=document.createElement("tbody");
+C.appendChild(A);
+B.shuttleTbody=C.tBodies[0]
+},moveItemByClick:function(D,C,E,A){var B=this.sourceList.getEventTargetRow(D);
+this.moveItem(C,E,B);
+this.controlListManager();
+this.targetList.controlListManager();
+this.targetLayoutManager.widthSynchronization();
+this.sourceLayoutManager.widthSynchronization();
+$(this.containerId).fire("rich:onlistchanged",{})
+}};
+Richfaces.ListShuttle.HANDLERS={copy:function(A){this.moveItems(this.sourceList,this.targetList,this.sourceList.selectedItems);
+return false
+},copyAll:function(A){this.moveItems(this.sourceList,this.targetList,this.sourceList.shuttleItems);
+return false
+},remove:function(A){this.moveItems(this.targetList,this.sourceList,this.targetList.selectedItems);
+return false
+},removeAll:function(A){this.moveItems(this.targetList,this.sourceList,this.targetList.shuttleItems);
+return false
+}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.PanelBar=Class.create();
+Richfaces.PanelBar.prototype={initialize:function(B,A){this.FF=(RichFaces.navigatorType()==RichFaces.FF)?true:false;
+this.isIE=((navigator.userAgent.toLowerCase().indexOf("msie")!=-1)||(navigator.userAgent.toLowerCase().indexOf("explorer")!=-1))?true:false;
+this.panel=$(B);
+if(!this.panel){return 
+}this.hclient=0;
+this.COUNT=0;
+this.STEP=0;
+this.slides=new Array();
+this.ch=this.panel.clientHeight;
+this.options=A;
+this.onitemchange=A.onitemchange;
+this.onclick=A.onclick;
+this._attachBehaviors();
+this.input=$(B+"_panelBarInput");
+this.defaultIndex=this.findPanelById($F(B+"_panelBarInput"));
+Event.observe(window,"load",this.handleOnLoad.bindAsEventListener(this));
+this.mouseover=A.mouseover;
+this.mouseout=A.mouseout;
+this.mousemove=A.mousemove;
+this.items=A.items;
+if(this.mouseover&&this.mouseover!=""){Event.observe(this.panel,"mouseover",new Function("event",this.mouseover))
+}if(this.mouseout&&this.mouseout!=""){Event.observe(this.panel,"mouseout",new Function("event",this.mouseout))
+}if(this.mousemove&&this.mousemove!=""){Event.observe(this.panel,"mousemove",new Function("event",this.mousemove))
+}this.showSlide(this.slides[this.defaultIndex]);
+this.contentHight=-1
+},handleOnLoad:function(){if(this.timer){clearTimeout(this.timer)
+}if(this.panel.clientHeight<=0){this.contentHight=-1;
+this.timer=setTimeout(this.handleOnLoad.bind(this),100)
+}this.showSlide(this.slides[this.defaultIndex])
+},getContentHeight:function(){if(this.contentHight){}else{this.contentHight=-1
+}if(this.contentHight<=-1){var B=0;
+this.hclient=0;
+for(var A=0;
+A<this.slides.length;
+A++){B+=this.slides[A].item.offsetHeight
+}this.hclient=B;
+this.contentHight=this.panel.clientHeight-B
+}return this.contentHight
+},showSlide:function(A){if(this.current){this.current.hideContent()
+}var B=this.getContentHeight();
+if(this.current){this.current.hideHeader()
+}A.content.style.height=(B>0?B:0)+"px";
+if(B<=1&&(this.panel.style.height==""||this.panel.style.height.indexOf("%")!=-1)){this.panel.style.height="";
+A.content.style.height="100%"
+}A.showContent();
+this.current=A;
+this.input.value=this.current.item.id;
+this.firstLoad=false
+},_attachBehaviors:function(){var C=this._getDirectChildrenByTag(this.panel,"DIV");
+for(var B=0;
+B<C.length;
+B++){var A=this._getDirectChildrenByTag(C[B],"DIV");
+this.slides.push(new Richfaces.PanelBar.Slide(this,C[B],A[0],A[1],A[2],B,this.onclick))
+}},_getDirectChildrenByTag:function(F,D){var B=new Array();
+var A=F.childNodes;
+for(var C=0;
+C<A.length;
+C++){var E=A[C];
+if(E&&E.tagName&&E.tagName.toUpperCase()==D.toUpperCase()){B.push(E)
+}}return B
+},findPanelById:function(B){for(var A=0;
+A<this.slides.length;
+A++){if(this.slides[A].item.id==B){return A
+}}return 0
+},invokeEvent:function(F,A,I,C,E,B,D){var J;
+if(B){var H;
+if(A){H=A
+}else{if(document.createEventObject){H=document.createEventObject()
+}else{if(document.createEvent){H=document.createEvent("Events");
+H.initEvent(F,true,false)
+}}}H.rich={component:this};
+H.rich.enterElement=I;
+H.rich.leaveElement=C;
+try{J=B.call(E,H)
+}catch(G){LOG.warn("Exception: "+G.Message+"\n[on"+F+"]")
+}}if(J!=false){J=true
+}return J
+}};
+Richfaces.PanelBar.Slide=Class.create();
+Richfaces.PanelBar.Slide.prototype={initialize:function(F,E,G,A,D,C,B){this.index=C;
+this.slidePanel=F;
+this.item=E;
+this.header=G;
+this.header_act=A;
+this.content=D;
+this.onclick=B;
+this.header.onclick=this.headerOnClick.bindAsEventListener(this);
+this.header.onselectstart=this.headerOnSelectStart.bindAsEventListener(this);
+this.header_act.onclick=this.headerOnClick.bindAsEventListener(this);
+this.header_act.onselectstart=this.headerOnSelectStart.bindAsEventListener(this);
+this.content.style.display="none";
+this.content.style.overflow="auto";
+this.content.style.height="0px";
+this.hightFirefoxDelta=0;
+if(this.slidePanel.isIE){if(this.slidePanel.panel.style.width.indexOf("%")!=-1){this.item.style.width="100%"
+}else{this.item.style.width=this.slidePanel.panel.style.width
+}}if(this.onclick&&this.onclick!=""){this.onclickFunction=new Function("event",this.onclick)
+}},showContent:function(){this.content.style.display="block";
+this.content.firstChild.style.height="";
+this.header.style.display="none";
+this.header_act.style.display=""
+},hideContent:function(){this.content.style.display="none";
+this.content.firstChild.style.height="100%"
+},hideHeader:function(){this.header_act.style.display="none";
+this.header.style.display=""
+},headerOnClick:function(H){if(this.onclickFunction){var A=this.onclickFunction(H);
+if(A==false){return false
+}}if(this.content.style.display=="block"){return 
+}var G=this.item;
+var E=this.slidePanel.current.item;
+var C=this.slidePanel.items[this.index];
+var F;
+var B=this.slidePanel.items;
+for(var D=0;
+D<B.length;
+D++){if(this.slidePanel.items[D].id==E.id){F=this.slidePanel.items[D]
+}}if(!this.slidePanel.invokeEvent("onenter",H,E,G,G,C.onenter)){return false
+}if(!this.slidePanel.invokeEvent("onleave",H,E,G,E,F.onleave)){return false
+}if(!this.slidePanel.invokeEvent("onchangeitem",H,E,G,this.slidePanel.panel,this.slidePanel.onitemchange)){return false
+}this.slidePanel.showSlide(this);
+this.slidePanel.panel.style.maxHeight="";
+this.slidePanel.panel.style.minHeight=""
+},headerOnSelectStart:function(){return false
+}}
+
+TogglePanel=Class.create();
+TogglePanel.prototype={initialize:function(A,B,C){this.panelId=A;
+this.divs=B;
+this.currentId=C
+},toggleToState:function(B){Element.hide(this.panelId+"_"+this.currentId);
+var A;
+if(B!=null){A=this.divs.indexOf(B);
+this.currentId=this.divs[A]
+}else{A=this.divs.indexOf(this.currentId);
+if(this.divs.length==(A+1)){this.currentId=this.divs[0]
+}else{this.currentId=this.divs[A+1]
+}}Element.show(this.panelId+"_"+this.currentId);
+$(this.panelId+"_input").value=this.currentId
+}};
+TogglePanelManager=Class.create();
+TogglePanelManager.panels=$H($A({}));
+TogglePanelManager.add=function(B){var A=new Object();
+A[B.panelId]=B;
+this.panels=this.panels.merge(A)
+};
+TogglePanelManager.toggleOnServer=function(D,B,E){var A=document.forms[D];
+if(A==null){return 
+}var C=A[B];
+if(C==null){C=document.createElement("input");
+C.type="hidden";
+C.name=B;
+A.appendChild(C)
+}C.value=E;
+A.submit();
+return false
+};
+TogglePanelManager.toggleOnClient=function(A,B){this.panels.get(A).toggleToState(B);
+return false
+}
+
+if(!window.RichFaces){window.RichFaces={}
+}var RichFaces_FF_Loaded=(RichFaces.navigatorType()==RichFaces.FF);
+RichFaces.panelTabs={};
+RichFaces.tabPanel={};
+RichFaces.createImage=function(B){var A=new Image();
+A.src=B;
+return A
+};
+RichFaces.setLabelImages=function(A,B,C){A=$(A);
+if(A){A._image=this.createImage(B);
+A._mouseoverimage=this.createImage(C)
+}};
+RichFaces.isTabActive=function(A){var B=$(A);
+if(B){return Element.hasClassName(B,"rich-tab-active")
+}return false
+};
+RichFaces.switchTab=function(L,C,O){var A="_lbl";
+var K="_cell";
+var J="_shifted";
+var F="";
+var T=RichFaces.panelTabs[L];
+var E;
+var H=RichFaces_FF_Loaded;
+if(T){for(var Q=0;
+Q<T.length;
+Q++){var B=T[Q];
+var V=B.id;
+var P=$(V+F);
+var U=V+A;
+var G=$(U);
+var S=V+K;
+var D=$(S);
+var W=$(V+J);
+if(V==C){if(P){Element.show(P)
+}E=B;
+if(!H){if(G){G.className=B.activeClass
+}if(D){D.className=B.cellActiveClass
+}}}else{if(P){Element.hide(P)
+}if(G){G.className=B.inactiveClass
+}if(D){D.className=B.cellInactiveClass
+}if(W){W.style.top="0px"
+}}}}if(H&&E){var R=$(E.id+A);
+var D=$(E.id+K);
+if(!R||!G||!D){return 
+}var N=RichFaces.findNestingTable(R);
+var I=N.parentNode;
+var M=N.nextSibling;
+I.removeChild(N);
+R.className=E.activeClass;
+I.insertBefore(N,M);
+N=RichFaces.findNestingTable(D);
+I=N.parentNode;
+M=N.nextSibling;
+I.removeChild(N);
+D.className=E.cellActiveClass;
+I.insertBefore(N,M)
+}$(C+"_shifted").style.top="1px";
+$(L+"_input").value=O
+};
+RichFaces.findNestingTable=function(B){var A=B.parentNode;
+while(A&&A.nodeName.toLowerCase()!="table"){A=A.parentNode
+}return A
+};
+RichFaces.overTab=function(A){if(RichFaces._shouldHoverTab(A)){Element.addClassName(A,"dr-tbpnl-tb-sel")
+}};
+RichFaces.outTab=function(A){if(RichFaces._shouldHoverTab(A)){Element.removeClassName(A,"dr-tbpnl-tb-sel")
+}};
+RichFaces._shouldHoverTab=function(A){return(A.className.indexOf("dr-tbpnl-tb-act")<0)
+};
+RichFaces.onTabChange=function(A,C,D){var I="_lbl";
+var J=RichFaces.panelTabs[C];
+var L,F;
+if(J){for(var G=0;
+G<J.length;
+G++){if(L&&F){break
+}var B=J[G].id;
+if(B==D){F=J[G]
+}if(RichFaces.isTabActive(B+I)){L=J[G]
+}}}if(L&&F){if(A){A.leftTabName=L.name;
+A.enteredTabName=F.name
+}if(L.ontableave&&L.ontableave!=""){var E=new Function("event",L.ontableave);
+var K=E(A);
+if(typeof (K)=="boolean"&&!K){return false
+}}if(F.ontabenter&&F.ontabenter!=""){var E=new Function("event",F.ontabenter);
+var K=E(A);
+if(typeof (K)=="boolean"&&!K){return false
+}}var H=RichFaces.tabPanel[C];
+if(H.ontabchange&&H.ontabchange!=""){var E=new Function("event",H.ontabchange);
+var K=E(A);
+if(typeof (K)=="boolean"&&!K){return false
+}}}return true
+}
+
+SimpleTogglePanel=Class.create();
+SimpleTogglePanel.prototype={initialize:function(C,A,B){this.panelId=C;
+this.panelId_head=C+"_header";
+this.options=B;
+this.status=A;
+if(!this.status){this.status="true"
+}},toggleToState:function(D){var A=$(this.panelId+"_body");
+var C=$(this.panelId+"_switch_on");
+var B=$(this.panelId+"_switch_off");
+if(this.status=="false"){if(this.invokeEvent("expand",D,"false",A)){Element.show(A);
+this.status="true";
+B.style.display="none";
+C.style.display=""
+}}else{if(this.invokeEvent("collapse",D,"true",A)){Element.hide(A);
+this.status="false";
+C.style.display="none";
+B.style.display=""
+}}if(RichFaces.navigatorType()==RichFaces.MSIE){}$(this.panelId+"_input").value=this.status
+},invokeEvent:function(B,E,G,C){var D=this.options["on"+B];
+var A;
+if(D){var F;
+if(E){F=E
+}else{if(document.createEventObject){F=document.createEventObject()
+}else{if(document.createEvent){F=document.createEvent("Events");
+F.initEvent(B,true,false)
+}}}F.rich={component:this};
+F.rich.value=G;
+try{A=D.call(C,F)
+}catch(H){LOG.warn("Exception: "+H.Message+"\n[on"+B+"]")
+}}if(A!=false){A=true
+}return A
+}};
+SimpleTogglePanelManager=Class.create();
+SimpleTogglePanelManager.panels=$H($A({}));
+SimpleTogglePanelManager.add=function(B){var A=new Object();
+A[B.panelId]=B;
+this.panels=this.panels.merge(A)
+};
+SimpleTogglePanelManager.toggleOnServer=function(D,B){var A=A4J.findForm($(B+"_header"));
+if(!A||!A.appendChild){return 
+}var E=A[B];
+if(!E){E=document.createElement("input");
+E.type="hidden";
+E.name=B;
+A.appendChild(E)
+}var C=this.panels.get(B);
+if(C.status=="true"){if(C.invokeEvent("collapse",D,"true",E)){C.status="false"
+}}else{if(C.invokeEvent("expand",D,"false",E)){C.status="true"
+}}E.value=C.status;
+A.submit();
+return false
+};
+SimpleTogglePanelManager.toggleOnClient=function(B,A){this.panels.get(A).toggleToState(B);
+return false
+};
+SimpleTogglePanelManager.toggleOnAjax=function(D,C){var B=$(C);
+var A=this.panels.get(C);
+if(A.status=="true"){return A.invokeEvent("collapse",D,"true",B)
+}else{return A.invokeEvent("expand",D,"false",B)
+}}
+
+if(!window.RichFaces){window.RichFaces={}
+}var Suggestion={};
+Suggestion.Base=function(){};
+Suggestion.Base.prototype={baseInitialize:function(D,F,A){this.isOpera=(RichFaces.navigatorType()==RichFaces.OPERA?true:false);
+this.element=$(D);
+this.update=$(F);
+this.hasFocus=false;
+this.changed=false;
+this.active=false;
+this.index=0;
+this.prevIndex=-1;
+this.entryCount=0;
+this.keyEvent=false;
+this.oldValue=this.element.value;
+this.skipHover=false;
+A.selection=F+"_selection";
+var E=(RichFaces.navigatorType()==RichFaces.MSIE);
+if(E){A.iframeId=F+"_iframe"
+}if(this.setOptions){this.setOptions(A)
+}else{this.options=A||{}
+}this.options.param=this.options.param||this.element.name;
+this.options.selectedClasses=(this.options.selectedClass||"dr-sb-int-sel rich-sb-int-sel").split(" ");
+this.options.selectValueClass=this.options.selectValueClass||" ";
+this.options.tokens=$A(A.tokens)||[];
+this.options.frequency=this.options.frequency||0.4;
+this.options.minChars=parseInt(this.options.minChars)||1;
+this.options.onShow=this.options.onShow||function(H,I,G){if(!I.style.position||I.style.position=="absolute"){I.style.position="absolute";
+RichFaces.Position.smartClone(H,I,G)
+}if(!window.opera){Effect.Appear(I,{duration:0.15});
+if(G.iframeId){Effect.Appear($(G.iframeId),{duration:0.15})
+}}else{Effect.Appear(I,{duration:0.15,to:0.999999})
+}};
+this.options.onHide=this.options.onHide||function(H,I,G){if(G.iframeId){new Effect.Fade($(G.iframeId),{duration:0.15})
+}new Effect.Fade(I,{duration:0.15})
+};
+this.options.width=this.options.width||"auto";
+if(typeof (this.options.tokens)=="string"){this.options.tokens=new Array(this.options.tokens)
+}for(var C=0;
+C<this.options.tokens.length;
+C++){var B=this.options.tokens[C];
+if(B.charAt[0]=="'"&&B.charAt[B.length-1]=="'"){this.options.tokens[C]=B.substring(1,-1)
+}}this.observerHandle=null;
+this.element.setAttribute("autocomplete","off");
+Element.hide(this.update);
+this.onBlurListener=this.onBlur.bindAsEventListener(this);
+Event.observe(this.element,"blur",this.onBlurListener);
+this.onKeyDownListener=this.onKeyDown.bindAsEventListener(this);
+Event.observe(this.element,"keydown",this.onKeyDownListener);
+if(this.isOpera){this.onKeyUpListener=this.onKeyUp.bindAsEventListener(this);
+Event.observe(this.element,"keyup",this.onKeyUpListener);
+this.upDown=0
+}this.onScrollListener=this.onScroll.bindAsEventListener(this);
+if(A.popupClass){Element.addClassName(document.getElementsByClassName("dr-sb-ext-decor-3",this.update)[0],A.popupClass)
+}this.onNothingLabelClick=this.hideNLabel.bindAsEventListener(this)
+},onBoxKeyPress:function(A){if(this.upDown==1){this.keyEvent=true;
+this.markPrevious();
+this.render()
+}else{if(this.upDown==2){this.keyEvent=true;
+this.markNext();
+this.render()
+}else{if(this.upDown==3){this.keyEvent=true;
+this.markPreviousPage();
+this.render()
+}else{if(this.upDown==4){this.keyEvent=true;
+this.markNextPage();
+this.render()
+}}}}},cancelSubmit:function(A){Event.stop(A)
+},disableSubmit:function(){if(this.isOpera){var A=this.element;
+while(A.parentNode&&(!A.tagName||(A.tagName.toUpperCase()!="FORM"))){A=A.parentNode
+}if(A.tagName&&(A.tagName.toUpperCase()=="FORM")){this.parentForm=A;
+this.onSubmitListener=this.cancelSubmit.bindAsEventListener(this);
+Event.observe(A,"submit",this.onSubmitListener)
+}}},enableSubmit:function(){if(this.isOpera){if(this.parentForm){Event.stopObserving(this.parentForm,"submit",this.onSubmitListener)
+}}},onKeyUp:function(A){if(this.upDown>0){this.element.onkeypress=this.prevOnKeyPress
+}this.upDown=0
+},show:function(){if(RichFaces.SAFARI==RichFaces.navigatorType()){this.wasScroll=false;
+this.wasBlur=false;
+if(!this.overflow){this.overflow=document.getElementsByClassName("dr-sb-overflow",this.update)[0]
+}Event.observe(this.overflow,"scroll",this.onScrollListener)
+}if(Element.getStyle(this.update,"display")=="none"){this.options.onShow(this.element,this.update,this.options)
+}this.disableSubmit()
+},hide:function(){if(RichFaces.SAFARI==RichFaces.navigatorType()){if(this.wasScroll){this.wasScroll=false;
+return 
+}Event.stopObserving(this.overflow,"scroll",this.onScrollListener)
+}this.stopIndicator();
+if(Element.getStyle(this.update,"display")!="none"){this.options.onHide(this.element,this.update,this.options)
+}this.enableSubmit();
+this.hasFocus=false;
+this.active=false
+},hideNLabel:function(B){var A=$(this.update.id+"NothingLabel");
+if(A){Element.hide(A);
+Event.stopObserving(A,"click",this.onNothingLabelClick);
+this.hide()
+}},startIndicator:function(){if(this.options.indicator){Element.show(this.options.indicator)
+}},stopIndicator:function(){if(this.options.indicator){Element.hide(this.options.indicator)
+}},isUnloaded:function(){if(this.element.parentNode&&this.update.parentNode){return false
+}LOG.info("Element unloaded from DOM");
+if(this.element){Event.stopObserving(this.element,"blur",this.onBlurListener);
+Event.stopObserving(this.element,"keydown",this.onKeyDownListener)
+}return true
+},onKeyDown:function(D){if(this.isUnloaded()){return 
+}if(!this.initialized){if(this.options.iframeId){var A=$(this.options.iframeId);
+var C=A.cloneNode(true);
+A.parentNode.removeChild(A);
+document.body.insertBefore(C,document.body.firstChild)
+}var B=this.update.cloneNode(true);
+this.update.parentNode.removeChild(this.update);
+this.update=B;
+document.body.insertBefore(this.update,document.body.firstChild);
+this.initialized=true
+}this.wasBlur=false;
+if(this.active){this.wasScroll=false;
+switch(D.keyCode){case Event.KEY_TAB:case Event.KEY_RETURN:this.selectEntry(D);
+Event.stop(D);
+case Event.KEY_ESC:this.hide();
+this.active=false;
+Event.stop(D);
+if(this.isOpera){this.element.focus()
+}return ;
+case Event.KEY_LEFT:case Event.KEY_RIGHT:return ;
+case Event.KEY_UP:this.keyEvent=true;
+this.markPrevious();
+this.render();
+if(navigator.appVersion.indexOf("AppleWebKit")>0){Event.stop(D)
+}if(this.isOpera){this.upDown=1;
+this.prevOnKeyPress=this.element.onkeypress;
+this.element.onkeypress=this.onBoxKeyPress.bindAsEventListener(this)
+}return ;
+case Event.KEY_DOWN:this.keyEvent=true;
+this.markNext();
+this.render();
+if(navigator.appVersion.indexOf("AppleWebKit")>0){Event.stop(D)
+}if(this.isOpera){this.upDown=2;
+this.prevOnKeyPress=this.element.onkeypress;
+this.element.onkeypress=this.onBoxKeyPress.bindAsEventListener(this)
+}return ;
+case 33:this.keyEvent=true;
+this.markPreviousPage();
+this.render();
+if(navigator.appVersion.indexOf("AppleWebKit")>0){Event.stop(D)
+}if(this.isOpera){this.upDown=3;
+this.prevOnKeyPress=this.element.onkeypress;
+this.element.onkeypress=this.onBoxKeyPress.bindAsEventListener(this)
+}return ;
+case 34:this.keyEvent=true;
+this.markNextPage();
+this.render();
+if(navigator.appVersion.indexOf("AppleWebKit")>0){Event.stop(D)
+}if(this.isOpera){this.upDown=4;
+this.prevOnKeyPress=this.element.onkeypress;
+this.element.onkeypress=this.onBoxKeyPress.bindAsEventListener(this)
+}return 
+}}else{if(D.keyCode==Event.KEY_TAB||D.keyCode==Event.KEY_RETURN||D.keyCode==Event.KEY_ESC){return 
+}}this.changed=true;
+this.hasFocus=true;
+if(this.observerHandle){LOG.debug("clear existing observer");
+window.clearTimeout(this.observerHandle)
+}LOG.debug("set timeout for request suggestion");
+var E={};
+try{E.target=D.target;
+E.srcElement=D.srcElement;
+E.type=D.type;
+E.altKey=D.altKey;
+E.button=D.button;
+E.clientX=D.clientX;
+E.clientY=D.clientY;
+E.ctrlKey=D.ctrlKey;
+E.keyCode=D.keyCode;
+E.modifiers=D.modifiers;
+E.pageX=D.pageX;
+E.pageY=D.pageY;
+E.screenX=D.screenX;
+E.screenY=D.screenY;
+E.shiftKey=D.shiftKey;
+E.which=D.which
+}catch(F){LOG.warn("Exception on clone event")
+}this.observerHandle=window.setTimeout(this.onObserverEvent.bind(this,E),this.options.frequency*1000)
+},onHover:function(B){var A=Event.findElement(B,"TR");
+if(!this.skipHover){if(this.index!=A.autocompleteIndex){this.index=A.autocompleteIndex;
+this.render()
+}if(B.type=="mousemove"){Event.stopObserving(A,"mousemove",this.onHover)
+}}else{this.skipHover=false;
+Event.observe(A,"mousemove",this.onHover.bindAsEventListener(this))
+}Event.stop(B)
+},onClick:function(B){this.wasScroll=false;
+this.wasBlur=false;
+var A=Event.findElement(B,"TR");
+this.index=A.autocompleteIndex;
+this.selectEntry(B);
+this.hide()
+},onMouseOut:function(B){var A=Event.findElement(B,"TR");
+Event.stopObserving(A,"mousemove",this.onHover)
+},onBlur:function(C){if(this.isUnloaded()){return 
+}this.wasBlur=true;
+if(!this.active){return 
+}var B=RichFaces.Position.calcOffsets(this.update);
+if(RichFaces.navigatorType()!=RichFaces.MSIE){B["x"]=0;
+B["y"]=0
+}var A=C.clientX+document.body.scrollLeft+document.documentElement.scrollLeft;
+var D=C.clientY+document.body.scrollTop+document.documentElement.scrollTop;
+if(A>B["x"]&&A<(this.update.clientWidth+B["x"])){if(D>(B["y"]-this.update.clientHeight)&&D<B["y"]){this.element.focus();
+return 
+}}setTimeout(this.hide.bind(this),250)
+},onScroll:function(A){if(RichFaces.SAFARI==RichFaces.navigatorType()&&this.wasBlur){if(this.element){this.element.focus();
+this.wasScroll=true;
+this.wasBlur=false
+}}},calcEntryPosition:function(F,A){var E=F;
+var B=0;
+while(E&&(E!=A)){if(RichFaces.SAFARI==RichFaces.navigatorType()&&"TR"==E.tagName.toUpperCase()){B+=document.getElementsByClassName("dr-sb-cell-padding",E)[0].offsetTop
+}else{B+=E.offsetTop
+}if(E.parentNode==A){break
+}E=E.offsetParent
+}var D;
+if(RichFaces.SAFARI==RichFaces.navigatorType()){var C=document.getElementsByClassName("dr-sb-cell-padding",E)[0];
+D=C.offsetTop+C.offsetHeight
+}else{D=F.offsetHeight
+}return{realOffset:B,entryOffsetHeight:D}
+},countVisibleEntries:function(){var D=this.getEntry(this.index);
+var B=document.getElementsByClassName("_suggestion_size_",this.update)[0]||this.update;
+var A=this.calcEntryPosition(D,B);
+var C=Math.round(B.clientHeight/A.entryOffsetHeight);
+var E=Math.round((A.realOffset-B.scrollTop)/A.entryOffsetHeight);
+return{current:E,all:C}
+},render:function(){if(this.entryCount>0){LOG.debug("render for index "+this.index+" and old index "+this.prevIndex);
+if(this.prevIndex!=this.index){var F=this.getEntry(this.index);
+for(var B=0;
+B<this.options.selectedClasses.length;
+B++){Element.addClassName(F,this.options.selectedClasses[B])
+}var H=document.getElementsByClassName("dr-sb-cell-padding",F);
+for(var B=0;
+B<H.length;
+B++){Element.addClassName(H[B],this.options.selectValueClass)
+}if(this.keyEvent){var E=document.getElementsByClassName("_suggestion_size_",this.update)[0]||this.update;
+var I=this.calcEntryPosition(F,E);
+var A=E.scrollTop;
+if(I.realOffset>E.scrollTop+E.clientHeight-I.entryOffsetHeight){E.scrollTop=I.realOffset-E.clientHeight+I.entryOffsetHeight
+}else{if(I.realOffset<E.scrollTop){E.scrollTop=I.realOffset
+}}if(A!=E.scrollTop){this.skipHover=true
+}this.keyEvent=false
+}if(this.prevIndex>=0){var C=this.getEntry(this.prevIndex);
+if(C){var D=document.getElementsByClassName("dr-sb-cell-padding",C);
+for(var B=0;
+B<D.length;
+B++){Element.removeClassName(D[B],this.options.selectValueClass)
+}for(var B=0;
+B<this.options.selectedClasses.length;
+B++){Element.removeClassName(C,this.options.selectedClasses[B])
+}}}}this.prevIndex=this.index;
+if(this.hasFocus&&!this.wasBlur){this.show();
+this.active=true
+}}else{var G=$(this.update.id+"NothingLabel");
+if(!G||"none"==G.style.display){this.active=false;
+this.hide()
+}}},markPrevious:function(){if(this.index>0){this.index--
+}},markNext:function(){if(this.index<this.entryCount-1){this.index++
+}},markPreviousPage:function(){var A=this.countVisibleEntries();
+if(this.index>0){if(A.current>0){this.index=this.index-Math.min(A.current,A.all)
+}else{this.index=this.index-A.all
+}if(this.index<0){this.index=0
+}}},markNextPage:function(){var A=this.countVisibleEntries();
+if(this.index<this.entryCount-1){if((A.current<A.all-1)&&A.current>=0){this.index=this.index+(A.all-A.current-1)
+}else{this.index=this.index+A.all
+}if(this.index>this.entryCount-1){this.index=this.entryCount-1
+}}},getEntry:function(A){if(this.options.entryClass){return document.getElementsByClassName(this.options.entryClass,this.update)[A]
+}else{return this.update.firstChild.firstChild.childNodes[A]
+}},getCurrentEntry:function(){return this.getEntry(this.index)
+},selectEntry:function(B){this.active=false;
+var A=$(this.options.selection);
+A.value=this.index;
+this.updateElement(this.getCurrentEntry());
+if(this.options.onselect){this.options.onselect(this,B)
+}if(this.update.onselect){this.update.onselect(this,B)
+}A.value=""
+},updateElement:function(F){if(this.options.updateElement){this.options.updateElement(F);
+return 
+}var C="";
+if(this.options.select){var A=document.getElementsByClassName(this.options.select,F)||[];
+if(A.length>0){C=Element.collectTextNodes(A[0],this.options.select)
+}}else{C=Element.collectTextNodesIgnoreClass(F,"informal")
+}var E=this.findLastToken();
+if(E!=-1){var D=this.element.value.substr(0,E+1);
+var B=this.element.value.substr(E+1).match(/^\s+/);
+if(B){D+=B[0]
+}this.element.value=D+C
+}else{this.element.value=C
+}this.oldValue=this.element.value;
+this.element.focus();
+if(this.options.afterUpdateElement){this.options.afterUpdateElement(this.element,F)
+}},updateChoices:function(F){if(!this.changed&&this.hasFocus){if(F){this.update.firstChild.replaceChild(F,this.update.firstChild.firstChild)
+}var C=[];
+if(this.options.entryClass){C=document.getElementsByClassName(this.options.entryClass,this.update)||[]
+}else{if(this.update.firstChild&&this.update.firstChild.firstChild&&this.update.firstChild.firstChild.childNodes){Element.cleanWhitespace(this.update);
+Element.cleanWhitespace(this.update.firstChild);
+Element.cleanWhitespace(this.update.firstChild.firstChild);
+C=this.update.firstChild.firstChild.childNodes
+}}this.entryCount=C.length;
+for(var D=0;
+D<this.entryCount;
+D++){var E=C[D];
+E.autocompleteIndex=D;
+this.addObservers(E)
+}this.stopIndicator();
+var A=document.getElementsByClassName("_suggestion_size_",this.update)[0]||this.update;
+A.scrollTop=-1;
+A.scrollLeft=-1;
+this.index=0;
+this.prevIndex=-1;
+var B=$(this.update.id+"NothingLabel");
+if(B){if(this.entryCount<1){Element.show(B);
+Event.observe(B,"click",this.onNothingLabelClick);
+this.show()
+}}this.render()
+}},addObservers:function(A){Event.observe(A,"mouseover",this.onHover.bindAsEventListener(this));
+Event.observe(A,"click",this.onClick.bindAsEventListener(this));
+Event.observe(A,"mouseout",this.onMouseOut.bindAsEventListener(this))
+},onObserverEvent:function(B){LOG.debug("Observer event occurs");
+this.changed=false;
+var A=this.element.value;
+if(this.getToken().length>=this.options.minChars){LOG.debug("Call data for update choices");
+if((B.keyCode==Event.KEY_DOWN||this.oldValue!=A)&&A.length>0){this.startIndicator();
+this.getUpdatedChoices(B)
+}}else{this.active=false;
+this.hide()
+}this.oldValue=A;
+this.observerHandle=null
+},getToken:function(){var B=this.findLastToken();
+if(B!=-1){var A=this.element.value.substr(B+1).replace(/^\s+/,"").replace(/\s+$/,"")
+}else{var A=this.element.value
+}return/\n/.test(A)?"":A
+},findLastToken:function(){var C=-1;
+for(var B=0;
+B<this.options.tokens.length;
+B++){var A=this.element.value.lastIndexOf(this.options.tokens[B]);
+if(A>C){C=A
+}}return C
+}};
+RichFaces.Suggestion=Class.create();
+Object.extend(Object.extend(RichFaces.Suggestion.prototype,Suggestion.Base.prototype),{initialize:function(A,F,D,E,B,C){var G=C.popup||"ac1update";
+if(!$(G)){this.create(D,G,E,C)
+}this.baseInitialize(D,G,C);
+this.options.asynchronous=true;
+this.options.onajaxcomplete=C.oncomplete;
+this.options.oncomplete=this.onComplete.bind(this);
+this.options.defaultParams=this.options.parameters||null;
+this.content=E;
+this.containerId=A;
+this.actionUrl=F;
+if(B&&B!="null"){this.onsubmitFunction=new Function(B+";return true;").bind(this.element)
+}return this
+},getUpdatedChoices:function(A){this.options.parameters[this.options.param]=this.getToken();
+if(this.onsubmitFunction&&!this.onsubmitFunction()){return 
+}A4J.AJAX.Submit(this.containerId,this.actionUrl,A,this.options)
+},onComplete:function(B,A){LOG.debug("AJAX response  complete - updateChoices");
+if(!this.update.style.position||this.update.style.position=="absolute"){this.update.style.position="absolute";
+RichFaces.Position.smartClone(this.element,this.update,this.options)
+}this.updateChoices();
+LOG.debug("Choices updated");
+if(this.options.onajaxcomplete){this.options.onajaxcomplete(B,A)
+}},create:function(D,B,F,C){if(!$(D)){return 
+}var E="display:none;"+(C.popupStyle||"border:1px solid black;position:absolute; background-color:white;");
+var A=C.popupClass?' class="'+C.popupClass+'" ':"";
+new Insertion.Top($(D).ownerDocument.body,'<div id="'+B+'"'+A+' style="'+E+'"><table id="'+F+'" cellspacing="0" cellpadding="0"><tbody></tbody></table></div>')
+}});
+RichFaces.Position={source:null,target:null,smartClone:function(E,F,A){this.options=Object.extend({width:"auto"},A||{});
+this.source=$(E);
+this.target=$(F);
+var B={};
+var D=this.calcOffsets(this.source);
+Element.setStyle(this.target,Object.extend({"left":D["x"]+"px","top":D["y"]+"px"},B));
+if(A.iframeId){var C=$(A.iframeId);
+Position.clone(this.target,C);
+Element.setStyle(this.target,{zIndex:201});
+Element.setStyle(C,{zIndex:200});
+C.style.position="absolute";
+C.style.top=this.target.style.top;
+C.style.left=this.target.style.left;
+C.style.width=this.target.style.width;
+C.style.height=this.target.style.height
+}},calcOffsets:function(C){var B=new Object(),A=0;
+var F=C.offsetLeft;
+var E=C.offsetTop;
+var D=C.offsetParent;
+while(D){F+=D.offsetLeft;
+E+=D.offsetTop;
+D=D.offsetParent
+}B["x"]=F;
+B["y"]=E+C.offsetHeight;
+return B
+},_removePx:function(A){A+="";
+if(A.indexOf("px")!=-1){return A.substr(0,A.indexOf("px"))
+}return A
+},calcHeight:function(){return this.options.height=="auto"?"":this.options.height
+},calcTop:function(B){var C=Position.cumulativeOffset(this.source);
+var E=C[1];
+var D=this.source.offsetHeight;
+var A=this.getBody();
+return E+D-1
+},calcWidth:function(){if(this.options.width=="auto"){return""
+}else{if(this.options.width.indexOf("%")>=0){var B=parseInt(this.options.width.substring(0,this.options.width.indexOf("%")));
+var A=parseInt(this.source.offsetWidth)*B/100;
+this.options.width=A+"px"
+}return this.options.width
+}},calcLeft:function(C){var E=Position.cumulativeOffset(this.source);
+var F=E[0];
+var B=this.source.offsetWidth;
+var A=this.getBody();
+var D=parseInt(F)+parseInt(B)+parseInt(C);
+if(D<=parseInt(A.clientWidth)){return F
+}else{return D
+}},getBody:function(){return this.source.ownerDocument.body
+}}
+
+if(!window.RichFaces){window.RichFaces={}
+}if(!RichFaces.Menu){RichFaces.Menu={}
+}RichFaces.Menu.fitLayerToContent=function(A){if(!RichFaces.Menu.Layers.IE){return 
+}var C=A.childNodes[0];
+if(C){if(A.style.width.indexOf("px")!=-1){var B=parseFloat(A.style.width.substring(0,A.style.width.indexOf("px")));
+var D=Element.getDimensions(C);
+if(D.width>B){A.style.width=D.width+"px"
+}}}};
+RichFaces.Menu.removePx=function(A){if((A+"").indexOf("px")!=-1){return(A+"").substring(0,A.length-2)
+}else{return A
+}};
+RichFaces.Menu.Layers={listl:new Array(),father:{},lwidthDetected:false,lwidth:{},back:new Array(),horizontals:{},layers:{},levels:["","","","","","","","","","",""],detectWidth:function(){this.IE=(navigator.userAgent.indexOf("MSIE")>-1)&&(navigator.userAgent.indexOf("Opera")<0);
+this.NS=(navigator.userAgent.indexOf("Netscape")>-1)
+},menuTopShift:-11,menuRightShift:11,menuLeftShift:0,shadowWidth:0,thresholdY:0,abscissaStep:180,CornerRadius:0,toBeHidden:new Array(),toBeHiddenLeft:new Array(),toBeHiddenTop:new Array(),layersMoved:0,layerPoppedUp:"",layerTop:new Array(),layerLeft:new Array(),timeoutFlag:0,useTimeouts:1,timeoutLength:500,showTimeOutFlag:0,showTimeoutLength:0,queuedId:"",LMPopUp:function(B,A){if(!this.loaded||(this.isVisible(B)&&!A)){return 
+}if(B==this.father[this.layerPoppedUp]){this.LMPopUpL(this.layerPoppedUp,false)
+}else{if(this.father[B]==this.layerPoppedUp){this.LMPopUpL(B,true)
+}else{foobar=B;
+do{this.LMPopUpL(foobar,true);
+foobar=this.father[foobar]
+}while(foobar)
+}}this.layerPoppedUp=B
+},isVisible:function(A){return($(A).style.visibility=="visible")
+},LMPopUpL:function(A,B){if(!this.loaded){return 
+}this.detectWidth();
+var E=$(A);
+RichFaces.Menu.fitLayerToContent(E);
+var D=this.isVisible(A);
+this.setVisibility(A,B);
+this.ieSelectWorkAround(A,B);
+if(D&&!B){var C=this.layers[E.id];
+if(C&&C.eventOnClose){C.eventOnClose()
+}if(C&&C.eventOnCollapse){C.eventOnCollapse()
+}if(C.refItem){C.refItem.highLightGroup(false)
+}}else{if(!D&&B){var C=this.layers[E.id];
+if(C&&C.eventOnOpen){C.eventOnOpen()
+}if(C&&C.eventOnExpand){C.eventOnExpand()
+}if(C.level>0){do{C=this.layers[(this.father[C.id])]
+}while(C.level>0);
+if(C&&C.eventOnGroupActivate){C.eventOnGroupActivate()
+}}}}},ieSelectWorkAround:function(B,A){if(this.IE||this.NS){B=$(B).id;
+var F=$(B);
+var C=$(B+"_iframe");
+var D=(this.NS?7:0);
+if(A){var E=Element.getDimensions(F);
+C.style.top=F.style.top;
+C.style.left=F.style.left;
+C.style.width=F.offsetWidth+"px";
+C.style.height=F.offsetHeight+"px";
+C.style.visibility="visible"
+}else{C.style.visibility="hidden"
+}}},shutdown:function(){var C=false;
+for(var B=0;
+B<this.listl.length;
+B++){var A=this.listl[B];
+if($(A)){this.LMPopUpL(A,false)
+}else{C=true
+}}if(C){this.resetLayers()
+}this.layerPoppedUp="";
+if(this.Konqueror||this.IE5){this.seeThroughElements(true)
+}},resetLayers:function(){var B=new Array();
+for(i=0;
+i<this.listl.length;
+i++){var A=this.listl[i];
+if($(A)){B.push(A)
+}}this.listl=B
+},setVisibility:function(B,C){var D=$(B);
+if(C){D.style.visibility="visible"
+}else{if(D.getElementsByTagName){var A=D.getElementsByTagName("INPUT");
+if(A){$A(A).each(function(E){E.blur()
+})
+}}D.style.visibility="hidden"
+}},clearLMTO:function(){if(this.useTimeouts){clearTimeout(this.timeoutFlag)
+}},setLMTO:function(A){if(!A){A=this.timeoutLength
+}if(this.useTimeouts){clearTimeout(this.timeoutFlag);
+this.timeoutFlag=setTimeout("RichFaces.Menu.Layers.shutdown()",A)
+}},loaded:1,clearPopUpTO:function(){clearTimeout(this.showTimeOutFlag)
+},showMenuLayer:function(A,C,B){this.clearPopUpTO();
+this.showTimeOutFlag=setTimeout(new RichFaces.Menu.DelayedPopUp(A,C,function(){this.layerId=null
+}.bind(this)).show,B);
+this.layerId=A
+},showDropDownLayer:function(A,D,C,B){this.clearPopUpTO();
+this.showTimeOutFlag=setTimeout(new RichFaces.Menu.DelayedDropDown(A,D,C).show,B)
+},showPopUpLayer:function(A,B){this.shutdown();
+this.detectWidth();
+this.LMPopUp(menuName,false);
+this.setLMTO(4)
+}};
+RichFaces.Menu.getWindowElement=function(){return(document.documentElement||document.body)
+};
+RichFaces.Menu.getWindowDimensions=function(){var A,B;
+if(self.innerHeight){A=self.innerWidth;
+B=self.innerHeight
+}else{if(document.documentElement&&document.documentElement.clientHeight){A=document.documentElement.clientWidth;
+B=document.documentElement.clientHeight
+}else{if(document.body){A=document.body.clientWidth;
+B=document.body.clientHeight
+}}}return{width:A,height:B}
+};
+RichFaces.Menu.getWindowScrollOffset=function(){var A,B;
+if(typeof pageYOffset!="undefined"){A=window.pageXOffset;
+B=window.pageYOffset
+}else{if(document.documentElement&&document.documentElement.scrollTop){A=document.documentElement.scrollLeft;
+B=document.documentElement.scrollTop
+}else{if(document.body){A=document.body.scrollLeft;
+B=document.body.scrollTop
+}}}return{top:B,left:A}
+};
+RichFaces.Menu.getPageDimensions=function(){var A,D;
+var C=document.body.scrollHeight;
+var B=document.body.offsetHeight;
+if(C>B){A=document.body.scrollWidth;
+D=document.body.scrollHeight
+}else{A=document.body.offsetWidth;
+D=document.body.offsetHeight
+}return{width:A,height:D}
+};
+RichFaces.Menu.DelayedContextMenu=function(A,B){if(!B){B=window.event
+}Event.stop(B);
+this.event=B;
+this.element=Event.element(B);
+this.layer=$(A);
+this.show=function(){RichFaces.Menu.Layers.shutdown();
+var G=RichFaces.Menu.getPageDimensions();
+var H=RichFaces.Menu.getWindowDimensions();
+var M=G.height;
+var L=G.width;
+var D=this.event.clientX;
+var C=this.event.clientY;
+var K=Event.pointerY(this.event);
+var E=Event.pointerX(this.event);
+var F=Element.getDimensions(this.layer);
+var J=E;
+if(D+F.width>H.width){J-=(F.width-RichFaces.Menu.Layers.shadowWidth-RichFaces.Menu.Layers.CornerRadius)
+}if(J<0){J=0
+}var I=K;
+if(C+F.height>H.height){I-=(F.height-RichFaces.Menu.Layers.shadowWidth-RichFaces.Menu.Layers.CornerRadius)
+}if(I<0){I=0
+}this.layer.style.left=J+"px";
+this.layer.style.top=I+"px";
+RichFaces.Menu.Layers.LMPopUp(this.layer.id,false);
+RichFaces.Menu.Layers.clearLMTO()
+}.bind(this)
+};
+RichFaces.Menu.DelayedDropDown=function(B,A,C){if(!C){C=window.event
+}this.event=C;
+this.element=$(A)||Event.element(C);
+this.layer=$(B);
+Event.stop(C);
+this.listPositions=function(D,E){var G=new Array(new Array(2,1,4),new Array(1,2,3),new Array(4,3,2),new Array(3,4,1));
+var H=new Array();
+if(D>0&&E>0){H.push({jointPoint:D,direction:E})
+}else{if(D>0&&E==0){for(var F=0;
+F<3;
+F++){H.push({jointPoint:D,direction:G[D-1][F]})
+}}else{if(D==0&&E>0){for(var F=0;
+F<3;
+F++){H.push({jointPoint:G[E-1][F],direction:E})
+}}else{if(D==0&&E==0){H.push({jointPoint:4,direction:3});
+H.push({jointPoint:1,direction:2});
+H.push({jointPoint:3,direction:4});
+H.push({jointPoint:2,direction:1})
+}}}}return H
+}.bind(this);
+this.calcPosition=function(D,E){var F;
+var G;
+switch(D){case 1:F=this.left;
+G=this.top;
+break;
+case 2:F=this.right;
+G=this.top;
+break;
+case 3:F=this.right;
+G=this.bottom;
+break;
+case 4:F=this.left;
+G=this.bottom;
+break
+}switch(E){case 1:F-=this.layerdim.width;
+G-=this.layerdim.height;
+break;
+case 2:G-=this.layerdim.height;
+break;
+case 4:F-=this.layerdim.width
+}return{left:F,top:G}
+}.bind(this);
+this.show=function(){RichFaces.Menu.Layers.shutdown();
+var R=RichFaces.Menu.getWindowScrollOffset();
+var I=RichFaces.Menu.getWindowDimensions();
+var V=RichFaces.Menu.getPageDimensions();
+var M=I.height;
+var X=I.width;
+var N=Position.positionedOffset(this.element);
+var W=this.element.lastChild;
+var P=Element.getDimensions(this.element);
+var F=Position.cumulativeOffset(this.element);
+var E=Position.cumulativeOffset(W);
+var U=E[0]-F[0];
+var T=E[1]-F[1];
+this.top=N[1];
+this.left=N[0];
+this.bottom=this.top+P.height;
+this.right=this.left+P.width;
+this.layerdim=Element.getDimensions(this.layer);
+var H=RichFaces.Menu.Layers.layers[this.layer.id].options;
+var J=0;
+if(H.jointPoint){var K=H.jointPoint.toUpperCase();
+J=K.indexOf("TL")!=-1?1:J;
+J=K.indexOf("TR")!=-1?2:J;
+J=K.indexOf("BR")!=-1?3:J;
+J=K.indexOf("BL")!=-1?4:J
+}var S=0;
+if(H.direction){var D=H.direction.toUpperCase();
+S=D.indexOf("TOP-LEFT")!=-1?1:S;
+S=D.indexOf("TOP-RIGHT")!=-1?2:S;
+S=D.indexOf("BOTTOM-RIGHT")!=-1?3:S;
+S=D.indexOf("BOTTOM-LEFT")!=-1?4:S
+}var Y=H.horizontalOffset;
+var O=H.verticalOffset;
+var G=this.listPositions(J,S);
+var L;
+var Z=false;
+for(var Q=0;
+Q<G.length;
+Q++){L=this.calcPosition(G[Q].jointPoint,G[Q].direction);
+if((L.left+Y>=R.left)&&(L.left+Y+this.layerdim.width-R.left<=X)&&(L.top+O>=R.top)&&(L.top+O+this.layerdim.height-R.top<=M)){Z=true;
+break
+}}if(!Z){L=this.calcPosition(G[0].jointPoint,G[0].direction)
+}this.layer.style.left=L.left+Y-U-this.left+"px";
+this.layer.style.top=L.top+O-T-this.top+"px";
+this.layer.style.width=this.layer.clientWidth+"px";
+RichFaces.Menu.Layers.LMPopUp(this.layer.id,false);
+RichFaces.Menu.Layers.clearLMTO()
+}.bind(this)
+};
+RichFaces.Menu.DelayedPopUp=function(A,B){if(!B){B=window.event
+}this.event=B;
+this.element=Event.findElement(B,"div");
+if(this.element.id.indexOf(":folder")==(this.element.id.length-7)){this.element=this.element.parentNode
+}this.layer=$(A);
+this.show=function(){if(!RichFaces.Menu.Layers.isVisible(this.layer)&&RichFaces.Menu.Layers.isVisible(RichFaces.Menu.Layers.father[this.layer.id])){this.reposition();
+RichFaces.Menu.Layers.LMPopUp(this.layer,false)
+}}.bind(this)
+};
+RichFaces.Menu.DelayedPopUp.prototype.reposition=function(){var A=RichFaces.Menu.getWindowScrollOffset();
+var K=RichFaces.Menu.getWindowDimensions();
+var I=K.height;
+var Z=K.width;
+var C={top:0,left:0};
+var M=Position.positionedOffset(this.element);
+var P=RichFaces.Menu.removePx(this.element.parentNode.parentNode.style.left);
+var V=RichFaces.Menu.removePx(this.element.parentNode.parentNode.style.top);
+M[0]+=Number(P);
+M[1]+=Number(V);
+var Y=Position.cumulativeOffset(this.element);
+var W=[Y[0]-M[0],Y[1]-M[1]];
+var U=Element.getDimensions(this.element);
+var N=M[1]+C.top;
+var G=N+U.height;
+var F=M[0]+C.left;
+var X=F+U.width;
+var Q=Element.getDimensions(this.layer);
+var E=RichFaces.Menu.Layers.layers[this.layer.id].options;
+var S=0;
+var L=0;
+if(E.direction){strDirection=E.direction.toUpperCase();
+S=strDirection.indexOf("LEFT")!=-1?1:S;
+S=strDirection.indexOf("RIGHT")!=-1?2:S;
+if(S>0){if(strDirection.indexOf("LEFT-UP")!=-1||strDirection.indexOf("RIGHT-UP")!=-1){L=1
+}if(strDirection.indexOf("LEFT-DOWN")!=-1||strDirection.indexOf("RIGHT-DOWN")!=-1){L=2
+}}}var D=X;
+var T=N-this.layer.firstChild.firstChild.offsetTop;
+if(S==0){if(D+Q.width+W[0]-A.left>=Z){var R=D+Q.width+W[0]-A.left-Z;
+D=F-Q.width
+}if(D+W[0]<0){if(Math.abs(D+W[0])>R){D=X
+}}}else{if(S==1){D=F-Q.width
+}}if(L!=2){if(T+Q.height+W[1]-A.top>=I||L==1){var B=T+Q.height+W[1]-A.top-I;
+var O=this.layer.firstChild.childNodes;
+if(O.length>1){var J=O[O.length-2];
+var H=Position.positionedOffset(J);
+T=N-H[1];
+if(L==0){if(T<0){if(Math.abs(T)>B){T=N
+}}}}}}this.layer.style.left=D+"px";
+this.layer.style.top=T+"px";
+this.layer.style.width=this.layer.clientWidth+"px"
+};
+RichFaces.Menu.selectOpen=false;
+RichFaces.Menu.MouseIn=false;
+RichFaces.Menu.Layer=Class.create();
+RichFaces.Menu.Layer.prototype={initialize:function(A,D,E){RichFaces.Menu.Layers.listl.push(A);
+this.id=A;
+this.layer=$(A);
+this.level=0;
+this.delay=D;
+if(E){this.hideDelay=E
+}else{this.hideDelay=E
+}RichFaces.Menu.fitLayerToContent(this.layer);
+this.items=new Array();
+RichFaces.Menu.Layers.layers[A]=this;
+this.bindings=new Array();
+this.highlightParent=true;
+this.mouseover=function(K){RichFaces.Menu.MouseIn=true;
+RichFaces.Menu.Layers.clearLMTO();
+if(this.highlightParent){var J=RichFaces.Menu.Layers.layers[this.layer.id].layer.parentNode.parentNode;
+J.className="dr-menu-label dr-menu-label-select rich-ddmenu-label rich-ddmenu-label-select"
+}Event.stop(K)
+}.bindAsEventListener(this);
+this.mouseout=function(K){RichFaces.Menu.MouseIn=false;
+if(!RichFaces.Menu.selectOpen){RichFaces.Menu.Layers.setLMTO(this.hideDelay)
+}if(this.highlightParent){var J=RichFaces.Menu.Layers.layers[this.layer.id].layer.parentNode.parentNode;
+J.className="dr-menu-label dr-menu-label-unselect rich-ddmenu-label rich-ddmenu-label-unselect"
+}Event.stop(K)
+}.bindAsEventListener(this);
+var G=new RichFaces.Menu.Layer.Binding(this.id,"mouseover",this.mouseover);
+this.bindings.push(G);
+G.refresh();
+G=new RichFaces.Menu.Layer.Binding(this.id,"mouseout",this.mouseout);
+this.bindings.push(G);
+G.refresh();
+arrayinp=$A(this.layer.getElementsByTagName("select"));
+for(i=0;
+i<arrayinp.length;
+i++){var I=this.openSelect.bindAsEventListener(this);
+var H=this.closeSelect.bindAsEventListener(this);
+Event.observe(arrayinp[i],"focus",I);
+Event.observe(arrayinp[i],"blur",H);
+var C=this.MouseoverInInput.bindAsEventListener(this);
+var F=this.MouseoutInInput.bindAsEventListener(this);
+Event.observe(arrayinp[i],"mouseover",C);
+Event.observe(arrayinp[i],"mouseout",F);
+var B=this.OnKeyPress.bindAsEventListener(this);
+Event.observe(arrayinp[i],"keypress",B)
+}arrayinp=$A(this.layer.getElementsByTagName("input"));
+for(i=0;
+i<arrayinp.length;
+i++){var I=this.openSelect.bindAsEventListener(this);
+var H=this.closeSelect.bindAsEventListener(this);
+Event.observe(arrayinp[i],"focus",I);
+Event.observe(arrayinp[i],"blur",H);
+var C=this.MouseoverInInput.bindAsEventListener(this);
+var F=this.MouseoutInInput.bindAsEventListener(this);
+Event.observe(arrayinp[i],"mouseover",C);
+Event.observe(arrayinp[i],"mouseout",F);
+var B=this.OnKeyPress.bindAsEventListener(this);
+Event.observe(arrayinp[i],"keypress",B)
+}arrayinp=$A(this.layer.getElementsByTagName("textarea"));
+for(i=0;
+i<arrayinp.length;
+i++){var I=this.openSelect.bindAsEventListener(this);
+var H=this.closeSelect.bindAsEventListener(this);
+Event.observe(arrayinp[i],"focus",I);
+Event.observe(arrayinp[i],"blur",H);
+var C=this.MouseoverInInput.bindAsEventListener(this);
+var F=this.MouseoutInInput.bindAsEventListener(this);
+Event.observe(arrayinp[i],"mouseover",C);
+Event.observe(arrayinp[i],"mouseout",F)
+}},openSelect:function(B){RichFaces.Menu.selectOpen=true;
+var A=this.ClickInput.bindAsEventListener(this);
+Event.observe(Event.element(B),"click",this.ClickInput)
+},closeSelect:function(B){RichFaces.Menu.selectOpen=false;
+var A=this.ClickInput.bindAsEventListener(this);
+Event.stopObserving(Event.element(B),"click",this.ClickInput);
+if(RichFaces.Menu.MouseIn==false){RichFaces.Menu.Layers.setLMTO(this.hideDelay)
+}},OnKeyPress:function(A){if(A.keyCode==13){RichFaces.Menu.Layers.setLMTO(this.hideDelay)
+}},MouseoverInInput:function(B){var A=this.ClickInput.bindAsEventListener(this);
+Event.observe(Event.element(B),"click",this.ClickInput)
+},ClickInput:function(A){Event.stop(A||window.event);
+return false
+},MouseoutInInput:function(B){var A=this.ClickInput.bindAsEventListener(this);
+Event.stopObserving(Event.element(B),"click",this.ClickInput)
+},rebind:function(){$A(this.bindings).each(function(A){A.refresh()
+})
+},showMe:function(A){this.closeSiblings(A);
+RichFaces.Menu.Layers.showMenuLayer(this.id,A,this.delay);
+RichFaces.Menu.Layers.levels[this.level]=this
+},closeSiblings:function(B){if(RichFaces.Menu.Layers.levels[this.level]&&RichFaces.Menu.Layers.levels[this.level].id!=this.id){for(var A=this.level;
+A<RichFaces.Menu.Layers.levels.length;
+A++){if(RichFaces.Menu.Layers.levels[A]){RichFaces.Menu.Layers.levels[A].hideMe()
+}}}},closeMinors:function(C){var B=this.items[C];
+for(var A=this.level+(!B.childMenu?1:2);
+A<RichFaces.Menu.Layers.levels.length;
+A++){if(RichFaces.Menu.Layers.levels[A]){RichFaces.Menu.Layers.levels[A].hideMe()
+}}if(B.menu.refItem){B.menu.refItem.highLightGroup(true)
+}},addItem:function(E,B,I){var A=this;
+var G={highLightGroup:function(J){if(J){Element.removeClassName(this.id,"dr-menu-item-enabled");
+Element.addClassName(this.id,"dr-menu-item-hover");
+Element.addClassName(this.id,"rich-menu-group-hover");
+if(this.options.selectClass){Element.addClassName(this.id,this.options.selectClass)
+}Element.addClassName(this.id+":icon","rich-menu-item-icon-selected");
+Element.addClassName(this.id+":anchor","rich-menu-item-label")
+}else{if(!this.mouseOver){Element.removeClassName(this.id,"dr-menu-item-hover");
+Element.removeClassName(this.id,"rich-menu-group-hover");
+Element.addClassName(this.id,"dr-menu-item-enabled");
+if(this.options.selectClass){Element.removeClassName(this.id,this.options.selectClass)
+}Element.removeClassName(this.id+":icon","rich-menu-item-icon-selected");
+Element.removeClassName(this.id+":anchor","rich-menu-item-label")
+}}}};
+G.id=E;
+G.obj=$(E);
+G.menu=this;
+G.options=I||{};
+G.mouseOver=false;
+if(G.options.onmouseover&&G.options.onmouseover!=""){G.eventOnMouseOver=new Function("event",G.options.onmouseover).bindAsEventListener(G)
+}if(G.options.onmouseout&&G.options.onmouseout!=""){G.eventOnMouseOut=new Function("event",G.options.onmouseout).bindAsEventListener(G)
+}this.items[E]=G;
+var H=function(K){this.menu.closeMinors(this.id);
+if(this.options.flagGroup==1){this.mouseOver=true;
+this.highLightGroup(true)
+}if(this.eventOnMouseOver){var J=(K.relatedTarget)?K.relatedTarget:K.fromElement;
+while(J&&J!=this.obj&&J.nodeName!="BODY"){J=J.parentNode
+}if(J==this.obj){return 
+}this.eventOnMouseOver()
+}}.bindAsEventListener(G);
+var F=function(K){if(this.options.flagGroup==1){this.mouseOver=false;
+this.highLightGroup(false)
+}if(this.eventOnMouseOut){var J=(K.relatedTarget)?K.relatedTarget:K.toElement;
+while(J&&J!=this.obj&&J.nodeName!="BODY"){J=J.parentNode
+}if(J==this.obj){return 
+}this.eventOnMouseOut()
+}}.bindAsEventListener(G);
+var D=function(K){var J=G.menu;
+while(J.level>0){J=RichFaces.Menu.Layers.layers[(RichFaces.Menu.Layers.father[J.id])]
+}if(J&&J.eventOnItemSelect){J.eventOnItemSelect()
+}RichFaces.Menu.Layers.shutdown()
+}.bindAsEventListener(G);
+var C=new RichFaces.Menu.Layer.Binding(G.id,"mouseover",H);
+this.bindings.push(C);
+C.refresh();
+C=new RichFaces.Menu.Layer.Binding(G.id,"mouseout",F);
+this.bindings.push(C);
+C.refresh();
+if(B==1){C=new RichFaces.Menu.Layer.Binding(G.id,"click",D);
+this.bindings.push(C);
+C.refresh()
+}return this
+},hideMe:function(A){RichFaces.Menu.Layers.clearPopUpTO();
+RichFaces.Menu.Layers.levels[this.level]=null;
+RichFaces.Menu.Layers.LMPopUpL(this.id,false)
+},asDropDown:function(A,E,F,D){this.options=D||{};
+if(this.options.ongroupactivate){this.eventOnGroupActivate=this.options.ongroupactivate.bindAsEventListener(this)
+}if(this.options.onitemselect){this.eventOnItemSelect=this.options.onitemselect.bindAsEventListener(this)
+}if(this.options.oncollapse){this.eventOnCollapse=this.options.oncollapse.bindAsEventListener(this)
+}if(this.options.onexpand){this.eventOnExpand=this.options.onexpand.bindAsEventListener(this)
+}var H=function(I){if(!I){I=window.event
+}RichFaces.Menu.Layers.showDropDownLayer(this.id,A,I,this.delay)
+}.bindAsEventListener(this);
+if(!E){E="onmouseover"
+}E=this.eventJsToPrototype(E);
+if(!F){F="onmouseout"
+}F=this.eventJsToPrototype(F);
+var B=this;
+var C=function(I){RichFaces.Menu.Layers.setLMTO(this.hideDelay);
+RichFaces.Menu.Layers.clearPopUpTO()
+}.bindAsEventListener(this);
+var G=new RichFaces.Menu.Layer.Binding(A,E,H);
+this.bindings.push(G);
+G.refresh();
+G=new RichFaces.Menu.Layer.Binding(A,F,C);
+this.bindings.push(G);
+G.refresh();
+RichFaces.Menu.Layers.horizontals[this.id]=A;
+return this
+},asSubMenu:function(A,B,E,C){this.options=C||{};
+if(this.options.onclose){this.eventOnClose=this.options.onclose.bindAsEventListener(this)
+}if(this.options.onopen){this.eventOnOpen=this.options.onopen.bindAsEventListener(this)
+}if(!E){E="onmouseover"
+}E=this.eventJsToPrototype(E);
+this.level=RichFaces.Menu.Layers.layers[A].level+1;
+RichFaces.Menu.Layers.father[this.id]=A;
+if(!B){B="ref"+A
+}var G=$(B);
+this.refItem=RichFaces.Menu.Layers.layers[A].items[B];
+this.refItem.childMenu=this;
+var F=new RichFaces.Menu.Layer.Binding(B,E,this.showMe.bindAsEventListener(this));
+this.bindings.push(F);
+F.refresh();
+var D=this;
+while(D.level>0){D=RichFaces.Menu.Layers.layers[(RichFaces.Menu.Layers.father[D.id])]
+}if(D&&D.hideDelay){this.hideDelay=D.hideDelay
+}return this
+},asContextMenu:function(E,H){var F=$(E);
+if(!F){return this
+}var A=this.id;
+this.highlightParent=false;
+if(!H){H="onclick"
+}var C="onmouseout";
+C=this.eventJsToPrototype(C);
+var B=this;
+var G=function(J){RichFaces.Menu.Layers.setLMTO(this.hideDelay);
+RichFaces.Menu.Layers.clearPopUpTO()
+}.bindAsEventListener(this);
+H=this.eventJsToPrototype(H);
+var I=function(J){new RichFaces.Menu.DelayedContextMenu(this.id,J).show()
+}.bindAsEventListener(this);
+var D=new RichFaces.Menu.Layer.Binding(E,H,I);
+this.bindings.push(D);
+D.refresh();
+D=new RichFaces.Menu.Layer.Binding(E,C,G);
+this.bindings.push(D);
+D.refresh();
+return this
+},eventJsToPrototype:function(B){var A=B.indexOf("on");
+if(A>=0){B=B.substr(A+2)
+}return B
+}};
+RichFaces.Menu.Layer.Binding=Class.create();
+RichFaces.Menu.Layer.Binding.prototype={initialize:function(A,C,B){this.objectId=A;
+this.eventname=C;
+this.handler=B
+},refresh:function(){var A=$(this.objectId);
+if(A){Event.stopObserving(A,this.eventname,this.handler);
+Event.observe(A,this.eventname,this.handler);
+return true
+}return false
+}};
+if(!RichFaces.Menu.Item){RichFaces.Menu.Item={}
+}RichFaces.Menu.Item.Onclick=function(G,N,J,O,Q){var A=Event.findElement(G,"form");
+var D=new Array();
+var P=new Object();
+RichFaces.Menu.Item._createOrInitHiddenInput(N+":submit",N+":submit",D,P,A);
+if(O){for(var C in O){var B=C;
+var E=O[B];
+if(typeof (E)!="function"){if(E){E=String(E)
+}RichFaces.Menu.Item._createOrInitHiddenInput(B,E,D,P,A)
+}}}var I=D.length;
+for(var L=0;
+L<I;
+L++){var M=D[L];
+A.appendChild(M)
+}var F=A.target;
+if(Q){A.target=Q
+}A.submit();
+A.target=F;
+for(var K=0;
+K<I;
+K++){var M=D[K];
+if(A&&M){A.removeChild(M)
+}}for(var R in P){var H=P[R];
+if(typeof (H)!="function"){($(R)||A[R]).value=H
+}}};
+RichFaces.Menu.Item._createOrInitHiddenInput=function(C,F,E,A,D){var B=$(C)||D[C];
+if(!B){B=document.createElement("input");
+B.setAttribute("type","hidden");
+B.setAttribute("name",C);
+B.setAttribute("id",C);
+E.push(B)
+}else{A[C]=B.value
+}B.value=F
+}
+
+if(!Richfaces.tooltips){Richfaces.tooltips=[]
+}ToolTip=Class.create();
+ToolTip.prototype={initialize:function(J,A,F,G,D,I,C,H,L,K,B){this.event=J.event;
+this.onshow=new Function("event",J.onshow+";return true;");
+this.oncomplete=new Function("event",J.oncomplete+";return true;");
+this.onhide=new Function("event",J.onhide+";return true;");
+this.delay=J.delay;
+this.hideDelay=J.hideDelay;
+this.id=A;
+this.parentId=F;
+this.mode=G;
+this.direction=I;
+this.disabled=D;
+this.followMouse=C;
+this.horizontalOffset=H;
+this.verticalOffset=L;
+this.ajaxExecuteString=K;
+this.ajaxOptions=B;
+this.clientAjaxParams={};
+this.toolTip=$(A);
+this.toolTipContent=$(A+"content");
+this.toolTipDefaultContent=$(A+"defaultContent");
+this.toolTip.style.visibility="hidden";
+this.toolTip.style.display="block";
+this.toolTipOffsetW=this.toolTip.offsetWidth;
+this.toolTipOffsetH=this.toolTip.offsetHeight;
+this.toolTipW=this.toolTip.getWidth();
+this.toolTipH=this.toolTip.getHeight();
+this.toolTipBorderHeight=(this.toolTipOffsetH-this.toolTipH)/2;
+this.toolTipBorderWidth=(this.toolTipOffsetW-this.toolTipW)/2;
+this.toolTip.style.visibility="visible";
+this.toolTip.style.display="none";
+this.parentAttached=false;
+this.hintParentElement=null;
+this.isMouseOvered=false;
+if(Richfaces.browser.isIE6){var E=parseInt(this.toolTip.style.zIndex);
+new Insertion.Before(this.toolTip,'<iframe src="javascript:\'\'" frameborder="0" scrolling="no" id="'+this.id+'iframe"style="position: absolute; width: '+this.toolTipOffsetW+"px; height: "+this.toolTipOffsetH+"px; display: none;background-color:black; z-index: "+ +(E-1)+';"></iframe>');
+this.iframe=$(this.id+"iframe")
+}this.attachOnLoadEventsListner=this.attachOnLoadEvents.bindAsEventListener(this);
+this.setToolTipPositionListner=this.setToolTipPosition.bindAsEventListener(this);
+if(this.hideDelay>0){this.doHideListner=this.customHideHandler.bindAsEventListener(this)
+}else{this.doHideListner=this.doHide.bindAsEventListener(this)
+}this.leaveToolTipListner=this.leaveToolTip.bindAsEventListener(this);
+if(Richfaces.tooltips[F]){Richfaces.tooltips[F].destroy()
+}if(!this.disabled){Event.observe(document,"mousemove",this.attachOnLoadEventsListner,true)
+}Richfaces.tooltips[F]=this
+},destroy:function(){if(!this.parentAttached){if(!this.disabled){Event.stopObserving(document,"mousemove",this.attachOnLoadEventsListner,true)
+}}else{if(this.followMouse){Event.stopObserving(this.parent,"mousemove",this.setToolTipPositionListner,false)
+}Event.stopObserving(this.parent,this.event,this.customEventHandlerListner,false);
+Event.stopObserving(this.parent,"mouseout",this.doHideListner,false);
+Event.stopObserving(this.toolTip,"mouseout",this.leaveToolTipListner,false)
+}this.hintParentElement=null;
+this.parent=null;
+this.toolTip=null;
+this.toolTipContent=null;
+this.toolTipDefaultContent=null;
+this.iframe=null;
+this.eventCopy=null;
+this.event=null
+},attachOnLoadEvents:function(){if(!this.parentAttached){this.parent=$(this.parentId);
+if(this.parent!=null&&!this.disabled){this.attachParentEvents();
+this.parentAttached=true
+}Event.stopObserving(document,"mousemove",this.attachOnLoadEventsListner,true)
+}},customEventHandler:function(A){if(this.activationTimerHandle){return 
+}this.eventCopy=A4J.AJAX.CloneObject(A,false);
+this.activationTimerHandle=window.setTimeout(function(){this.doShow(this.eventCopy)
+}.bindAsEventListener(this),this.delay)
+},customHideHandler:function(A){if(this.hidingTimerHandle){return 
+}this.eventCopy=A4J.AJAX.CloneObject(A,false);
+this.hidingTimerHandle=window.setTimeout(function(){this.doHide(this.eventCopy)
+}.bindAsEventListener(this),this.hideDelay)
+},attachParentEvents:function(){if(this.followMouse){Event.observe(this.parent,"mousemove",this.setToolTipPositionListner,false)
+}var A;
+if(this.delay>0){this.customEventHandlerListner=this.customEventHandler.bindAsEventListener(this)
+}else{this.customEventHandlerListner=this.doShow.bindAsEventListener(this)
+}Event.observe(this.parent,this.event,this.customEventHandlerListner,false);
+Event.observe(this.parent,"mouseout",this.doHideListner,false);
+Event.observe(this.toolTip,"mouseout",this.leaveToolTipListner,false)
+},detectAncestorNode:function(A,B){var C=A;
+while(C!=null&&C!=B){C=C.parentNode
+}return(C!=null)
+},ffcheck:function(A){if(this.parent.tagName.toLowerCase()=="input"&&A){var B;
+try{B=A.className;
+if(B=="anonymous-div"){return true
+}}catch(C){return true
+}if(A==this.parent){return true
+}}return false
+},leaveToolTip:function(D){var B=false;
+var A=D.relatedTarget||D.toElement;
+var C;
+if(A){try{C=A.className;
+if(C!="anonymous-div"){}B=this.detectAncestorNode(A,this.hintParentElement)
+}catch(D){}}if(!B){this.doHide(D);
+this.isMouseOvered=false
+}},doShow:function(e){var obj;
+if(!e){var e=window.event
+}var relTarg=e.relatedTarget||e.fromElement;
+if(this.ffcheck(relTarg)){return 
+}var className;
+if(relTarg){try{className=relTarg.className;
+if(className!="anonymous-div"){}if(this.detectAncestorNode(relTarg,this.toolTip)){return 
+}}catch(e){}}this.onshow(e);
+this.isMouseOvered=true;
+if(e.target){this.hintParentElement=e.target
+}if(e.srcElement){this.hintParentElement=e.srcElement
+}if(this.mode=="ajax"){if(this.toolTipDefaultContent){this.toolTipContent.innerHTML=this.toolTipDefaultContent.innerHTML;
+this.toolTip.style.visibility="hidden";
+this.toolTip.style.display="block";
+this.setToolTipPosition(e);
+this.setToolTipVisible(false)
+}var event=e;
+var ajaxOptions=this.ajaxOptions;
+if(this.clientAjaxParams){if(e.clientX){this.clientAjaxParams["clientX"]=e.clientX;
+this.clientAjaxParams["clientY"]=e.clientY
+}else{this.clientAjaxParams["event.pageX"]=e.pageX;
+this.clientAjaxParams["event.pageY"]=e.pageY
+}Object.extend(ajaxOptions["parameters"],this.clientAjaxParams)
+}eval(this.ajaxExecuteString)
+}else{this.setToolTipPosition(e);
+this.displayDiv()
+}},doHide:function(C){this.eventCopy=null;
+if(!C){var C=window.event
+}var A=C.relatedTarget||C.toElement;
+if(this.ffcheck(A)){return 
+}if(this.activationTimerHandle){window.clearTimeout(this.activationTimerHandle);
+this.activationTimerHandle=undefined
+}var B;
+if(A){try{B=A.className;
+if(B!="anonymous-div"){}if(this.detectAncestorNode(A,this.toolTip)){return 
+}}catch(C){}}this.isMouseOvered=false;
+this.toolTip.style.visibility="hidden";
+this.toolTip.style.display="none";
+if(this.iframe){this.iframe.style.display="none"
+}this.hintParentElement=null;
+this.isMouseOvered=false;
+this.onhide(C);
+if(this.hidingTimerHandle){window.clearTimeout(this.hidingTimerHandle);
+this.hidingTimerHandle=undefined
+}},doEnable:function(){this.disabled=false
+},doDisable:function(){this.disabled=true
+},setToolTipPosition:function(F){var B=0;
+var A=0;
+var J=Event.pointerX(F);
+var H=Event.pointerY(F);
+var K=Richfaces.Position.getOffsetDimensions(this.toolTip);
+var C=Position.cumulativeOffset(this.toolTip);
+C[0]-=this.toolTip.offsetLeft||0;
+C[1]-=this.toolTip.offsetTop||0;
+B=J-C[0];
+A=H-C[1];
+var D=/^(top|bottom)-(left|right)$/;
+var E=this.direction.match(D);
+var L=E[2];
+var G=E[1];
+this.prePosition({"x":B,"y":A},K,L,G,{"x":this.horizontalOffset,"y":this.verticalOffset});
+var I=this.fitToolTip(F.clientX,F.clientY,{"x":B,"y":A},K,L,G,{"x":this.horizontalOffset,"y":this.verticalOffset});
+Element.setStyle(this.toolTip,{"left":I.x+"px","top":I.y+"px"});
+if(this.iframe){this.iframe.style.top=(I.y-this.toolTipBorderHeight)+"px";
+this.iframe.style.left=(I.x-this.toolTipBorderWidth)+"px"
+}this.eventCopy=A4J.AJAX.CloneObject(F,false)
+},prePosition:function(E,D,G,B,F){var C,A;
+C=G=="left"?E.x-D.width-F.x:E.x+=F.x;
+A=B=="top"?E.y-D.height-F.y:E.y+F.y;
+return{"x":C,"y":A}
+},fitToolTip:function(D,C,B,P,Q,M,H){var F=Richfaces.Position.getWindowDimensions();
+var K=D-H.x-P.width;
+var L=F.width-(D+H.x+P.width);
+var G=C-H.y-P.height;
+var A=F.height-(C+H.y+P.height);
+if(K<0){this.prePosition({"x":B.x,"y":B.y},P,"right",M,H);
+var J=F.width-(D+H.x+P.width);
+if(J>0){Q="right"
+}else{if(J>K){Q="right"
+}}}else{if(L<0){this.prePosition({"x":B.x,"y":B.y},P,"left",M,H);
+var I=D-H.x-P.width;
+if(I>0){Q="left"
+}else{if(I>L){Q="left"
+}}}}if(G<0){this.prePosition({"x":B.x,"y":B.y},P,Q,"bottom",H);
+var N=F.height-(C+H.y+P.height);
+if(N>0){M="bottom"
+}else{if(N>G){M="bottom"
+}}}else{if(A<0){this.prePosition({"x":B.x,"y":B.y},P,Q,"top",H);
+var E=C-H.y-P.height;
+if(E>0){M="top"
+}else{if(E>A){M="top"
+}}}}var O=this.prePosition({"x":B.x,"y":B.y},P,Q,M,H);
+return O
+},displayDiv:function(){if(this.isMouseOvered){if(this.mode=="ajax"){this.toolTip.style.display="none";
+if(this.clientAjaxParams){var B;
+if(this.clientAjaxParams.clientX){B="clientX"
+}else{B="pageX"
+}var A;
+if(this.clientAjaxParams.clientY){A="clientY"
+}else{A="pageY"
+}var C={};
+C[B]=this.clientAjaxParams[B];
+C[A]=this.clientAjaxParams[A];
+this.toolTip.style.visibility="hidden";
+this.toolTip.style.display="block";
+this.setToolTipPosition((this.eventCopy?this.eventCopy:C))
+}}this.setToolTipVisible(true)
+}},setToolTipVisible:function(A){this.activationTimerHandle=undefined;
+this.toolTip.style.display="block";
+this.toolTip.style.visibility="visible";
+if(this.iframe){this.iframe.style.display="block"
+}if(A){this.oncomplete(window.event)
+}}}
+
+if(!window.DW){window.DW={}
+}if(!window.Richfaces){window.Richfaces={}
+}var PanelMenuStorage=new Object();
+PanelMenu=Class.create();
+PanelMenu.prototype={initialize:function(A,C,B){this.childObj=new Array();
+this.expandSingle=C;
+this.lastExpanded=null;
+this.selectedChild=B;
+this.defaultSelectedClass="dr-pmenu-selected-item";
+this.userDefinedSelectedClass="rich-pmenu-selected-element";
+this.is="panelMenu";
+this.selectedNameInput=$(A+"selectedItemName");
+PanelMenuStorage[A]=this
+}};
+PanelMenuItem=Class.create();
+PanelMenuItem.prototype={initialize:function(F,B,Q,G,L,C,M,H,I,P,E,A,D,O,K){if(!B.parentId){return 
+}this.type=Q.type;
+this.onopen=Q.onopen;
+this.itemId=B.myId;
+this.onclose=Q.onclose;
+this.event=Q.event;
+this.disabled=Q.disabled;
+this.name=Q.name;
+this.params=F;
+this.myId=B.myId;
+this.mode=Q.mode;
+if(!this.mode){this.mode=("node"==this.type)?"none":"server"
+}this.ajaxSubmit=P;
+this.onItemHover=E;
+this.target=Q.target;
+this.hoveredStyles=G;
+this.hoveredClasses=L;
+this.tdhider=$(B.myId);
+this.tablehider=$("tablehide"+B.myId);
+this.haveDynamicIcon=M;
+if(this.haveDynamicIcon==true){this.iconswitcher=$("icon"+B.myId)
+}this.childObj=new Array();
+this.parentObj=PanelMenuStorage[B.parentId];
+this.parentObj.childObj.push(this);
+var N=this.parentObj;
+while(N){if(N.is&&"panelMenu"==N.is){this.expandSingle=N.expandSingle;
+break
+}N=N.parentObj
+}this.rootMenu=N;
+if(this.rootMenu.selectedChild==this.name){this.selected=true
+}else{this.selected=false
+}this.clientId=B.myId;
+this.obj=$(B.myId);
+this.leftIcon=$("leftIcon"+B.myId);
+this.rightIcon=$("rightIcon"+B.myId);
+this.labelArea=$("icon"+B.myId);
+this.content=document.getElementsByClassName("dr-pmenu-group-self-label",this.obj)[0];
+this.iconAlign=A;
+this.mainRow=$("row_"+B.myId);
+this.iconCollapsed=O;
+this.iconExpanded=D;
+this.iconSpacer=K;
+if(H){this.action=H
+}PanelMenuStorage[B.myId]=this;
+this.initialStyles=null;
+this.hasInitialSylesChecked=false;
+this._attachBehaviors();
+this.inputs=this._getDirectChildrenByTag(this.content,"INPUT");
+for(var J=0;
+J<this.inputs.length;
+J++){if(this.inputs[J].name.indexOf("panelMenuState")!=-1){this.inputState=this.inputs[J]
+}else{if(this.inputs[J].name.indexOf("panelMenuAction")!=-1){this.inputAction=this.inputs[J]
+}}}if(I){this.parentObj.lastExpanded=this;
+this.expand()
+}else{this.expanded=false
+}if(this.parentObj.type=="node"&&this.parentObj.expanded){if(this.type=="node"){this.tdhider.style.display=""
+}}},collapse:function(){if(!this.disabled){if(this.expanded){if(this._getDirectChildrenByTag(this.content,"INPUT")[0]!=null){this._getDirectChildrenByTag(this.content,"INPUT")[0].value="closed"
+}for(var B=0;
+B<this.childObj.length;
+B++){if(this.childObj[B]._getDirectChildrenByTag(this.childObj[B].content,"INPUT")[0]!=null){this.childObj[B]._getDirectChildrenByTag(this.childObj[B].content,"INPUT")[0].value=""
+}if(this.haveDynamicIcon){var A=null;
+if(this.iconAlign=="right"){A=this.rightIcon
+}else{A=this.leftIcon
+}if(A!=null){if(this.iconCollapsed!="none"){if(this.iconCollapsed!=null){A.src=this.iconCollapsed
+}else{A.src=this.iconSpacer
+}}}}this.childObj[B].collapse();
+this.childObj[B].hide()
+}}this.expanded=false
+}},hide:function(){this.obj.style.display="none"
+},expand:function(){if(!this.disabled){if(!this.expanded){if(this._getDirectChildrenByTag(this.content,"INPUT")[0]!=null){this.inputState.value="opened"
+}if(this.haveDynamicIcon){var A=null;
+if(this.iconAlign=="right"){A=this.rightIcon
+}else{A=this.leftIcon
+}if(A!=null){if(this.iconExpanded!="none"){if(this.iconExpanded!=null){A.src=this.iconExpanded
+}else{A.src=this.iconSpacer
+}}}}for(var B=0;
+B<this.childObj.length;
+B++){this.childObj[B].show()
+}}this.expanded=true
+}},show:function(){this.tdhider.style.display="";
+this.tablehider.style.display="";
+this.obj.style.display=""
+},preTrigger:function(A){this.inputAction.setAttribute("value",this.clientId)
+},postTrigger:function(A){this.inputAction.setAttribute("value","")
+},trigger:function(e){if("none"==this.mode){return 
+}this.preTrigger(e);
+var form=Event.findElement(e,"form");
+if("server"==this.mode){if(this.target){form.target=this.target
+}Richfaces.jsFormSubmit(this.myId,form.name,this.target,this.params)
+}else{if("ajax"==this.mode){var event=e;
+eval(this.ajaxSubmit)
+}}this.postTrigger(e)
+},itemClicked:function(A){this.globalClearSelection();
+this.setSelectedClass();
+this.rootMenu.selectedNameInput.value=this.name;
+if(this.action){if(this.action=="panelMenuNodeAction"){if(this.expanded){if("node"==this.type){if(new Function(this.onclose+";return true;")()){this.collapse()
+}}this.trigger(A)
+}else{if(this.parentObj.expandSingle){if(this.parentObj.lastExpanded!=null){this.parentObj.lastExpanded.collapse()
+}if("node"==this.type){if(new Function(this.onopen+";return true;")()){this.expand()
+}}this.trigger(A);
+this.parentObj.lastExpanded=this
+}else{if("node"==this.type){if(new Function(this.onopen+";return true;")()){this.expand()
+}}this.trigger(A)
+}}}else{this.trigger(A)
+}}else{if(this.expanded){if("node"==this.type){if(new Function(this.onclose+";return true;")()){this.collapse()
+}}this.trigger(A)
+}else{if(this.parentObj.expandSingle){if(this.parentObj.lastExpanded!=null){this.parentObj.lastExpanded.collapse()
+}if("node"==this.type){if(new Function(this.onopen+";return true;")()){this.expand()
+}}if(this.action){this.trigger(A)
+}this.parentObj.lastExpanded=this
+}else{if("node"==this.type){if(new Function(this.onopen+";return true;")()){this.expand()
+}}this.trigger(A)
+}}}},globalClearSelection:function(B){for(var A in PanelMenuStorage){if(PanelMenuStorage.hasOwnProperty(A)){if(PanelMenuStorage[A].type=="node"||PanelMenuStorage[A].type=="item"){PanelMenuStorage[A].removeSelectedClass()
+}}}},setSelectedClass:function(A){this.mainRow.addClassName(this.rootMenu.defaultSelectedClass);
+this.mainRow.addClassName(this.rootMenu.userDefinedSelectedClass)
+},removeSelectedClass:function(A){this.mainRow.removeClassName(this.rootMenu.defaultSelectedClass);
+this.mainRow.removeClassName(this.rootMenu.userDefinedSelectedClass)
+},addHoverStyles:function(A){if(!this.selected){if(!this.hasInitialSylesChecked){this.initialStyles=this.tablehider.style.cssText;
+this.hasInitialSylesChecked=true
+}if(this.hoveredStyles){Element.setStyle(this.tablehider,this.hoveredStyles)
+}if(this.hoveredClasses){for(i=0;
+i<this.hoveredClasses.length;
+i++){this.tablehider.addClassName(this.hoveredClasses[i])
+}}}},removeHoverStyles:function(B){if(!this.selected){if(this.hoveredStyles&&this.hasInitialSylesChecked){this.tablehider.style.cssText=this.initialStyles
+}if(this.hoveredClasses){for(var A=0;
+A<this.hoveredClasses.length;
+A++){this.tablehider.removeClassName(this.hoveredClasses[A])
+}}}},_getDirectChildrenByTag:function(F,E){var B=F.childNodes;
+var C=new Array();
+var A;
+E=E.toLowerCase();
+for(var D=0;
+D<B.length;
+D++){if(B[D]&&B[D].tagName&&B[D].tagName.toLowerCase()==E){C.push(B[D])
+}}return C
+},_fireEditEvent:function(B){if(document.createEvent){var A=document.createEvent("HTMLEvents");
+A.initEvent(B,true,false);
+this.edit.dispatchEvent(A)
+}else{if(document.createEventObject){this.edit.fireEvent("on"+B)
+}}},hoverItem:function(e){if(this.onItemHover!=""){eval(this.onItemHover)
+}},_attachBehaviors:function(){if(!this.disabled){if(this.event){Event.observe(this.tablehider,this.event,this.itemClicked.bindAsEventListener(this),false)
+}else{Event.observe(this.tablehider,"click",this.itemClicked.bindAsEventListener(this),false)
+}Event.observe(this.obj,"mouseover",this.hoverItem.bindAsEventListener(this),false);
+Event.observe(this.tablehider,"mouseover",this.addHoverStyles.bindAsEventListener(this),false);
+Event.observe(this.tablehider,"mouseout",this.removeHoverStyles.bindAsEventListener(this),false)
+}}};
+PanelMenu.doExpand=function(C){var B=PanelMenuStorage[C];
+if(B&&B.type&&"node"==B.type){var A=B.parentObj;
+if(A.expandSingle){if(B.parentObj.lastExpanded!=null){B.parentObj.lastExpanded.collapse()
+}}while(A){if(A.type&&"node"==A.type){A.expand()
+}A=A.parentObj
+}if(!B.expanded&&new Function(B.onopen+";return true;")()){B.expand()
+}}};
+PanelMenu.doCollapse=function(B){var A=PanelMenuStorage[B];
+if(A&&A.type&&"node"==A.type){if(A.expanded&&new Function(A.onclose+";return true;")()){A.collapse()
+}}}
+
+if(!window.LOG){window.LOG={warn:function(){}}
+}if(typeof Effect=="undefined"){throw ("calendar.js requires including script.aculo.us' effects.js library")
+}if(!window.Richfaces){window.Richfaces={}
+}Richfaces.Calendar={};
+Richfaces.Calendar.setElementPosition=function(F,A,L,Y,M){if(!M){M={dx:0,dy:0}
+}var I=Richfaces.Calendar.getOffsetDimensions(F);
+var G;
+var V;
+if(A.left!=undefined){G={width:A.width,height:A.height};
+V=[A.left,A.top]
+}else{G=Richfaces.Calendar.getOffsetDimensions(A);
+V=Position.cumulativeOffset(A)
+}var B=Richfaces.Calendar.getWindowViewport();
+var K=V[0];
+var J=V[1];
+var S=/^(top|bottom)-(left|right)$/;
+var P;
+if(typeof L=="object"){K=L.x;
+J=L.y
+}else{if(L&&(P=L.toLowerCase().match(S))!=null){if(P[2]=="right"){K+=G.width
+}if(P[1]=="bottom"){J+=G.height
+}}else{}}if(Y&&(P=Y.toLowerCase().match(S))!=null){var W=Y.toLowerCase().split("-");
+if(P[2]=="left"){K-=I.width+M.dx
+}else{if(P[2]=="right"){K+=M.dx
+}}if(P[1]=="top"){J-=I.height+M.dy
+}else{if(P[1]=="bottom"){J+=M.dy
+}}}else{var Z={square:0};
+var O=V[0]-M.dx;
+var N=V[1]+M.dy;
+var D={right:O+G.width,top:N+G.height};
+D.left=D.right-I.width;
+D.bottom=D.top+I.height;
+K=D.left;
+J=D.top;
+var Q=Richfaces.Calendar.checkCollision(D,B);
+if(Q!=0){if(K>=0&&J>=0&&Z.square<Q){Z={x:K,y:J,square:Q}
+}O=V[0]-M.dx;
+N=V[1]-M.dy;
+D={right:O+G.width,bottom:N};
+D.left=D.right-I.width;
+D.top=D.bottom-I.height;
+K=D.left;
+J=D.top;
+Q=Richfaces.Calendar.checkCollision(D,B);
+if(Q!=0){if(K>=0&&J>=0&&Z.square<Q){Z={x:K,y:J,square:Q}
+}O=V[0]+M.dx;
+N=V[1]+M.dy;
+D={left:O,top:N+G.height};
+D.right=D.left+I.width;
+D.bottom=D.top+I.height;
+K=D.left;
+J=D.top;
+Q=Richfaces.Calendar.checkCollision(D,B);
+if(Q!=0){if(K>=0&&J>=0&&Z.square<Q){Z={x:K,y:J,square:Q}
+}O=V[0]+M.dx;
+N=V[1]-M.dy;
+D={left:O,bottom:N};
+D.right=D.left+I.width;
+D.top=D.bottom-I.height;
+K=D.left;
+J=D.top;
+Q=Richfaces.Calendar.checkCollision(D,B);
+if(Q!=0){if(K<0||J<0||Z.square>Q){K=Z.x;
+J=Z.y
+}}}}}}var H=F.style;
+var C=H.visibility;
+var X=H.position;
+var R=H.display;
+H.visibility="hidden";
+H.position="absolute";
+H.display="";
+if(F.offsetParent&&F.offsetParent!=document.body){var U=Position.cumulativeOffset(F.offsetParent);
+K-=U[0];
+J-=U[1]
+}H.display=R;
+H.position=X;
+H.visibility=C;
+F.style.left=(K+B.left)+"px";
+F.style.top=(J+B.top)+"px"
+};
+Richfaces.Calendar.getOffsetDimensions=function(C){C=$(C);
+var H=$(C).getStyle("display");
+if(H!="none"&&H!=null){return{width:C.offsetWidth,height:C.offsetHeight}
+}var B=C.style;
+var G=B.visibility;
+var D=B.position;
+var A=B.display;
+B.visibility="hidden";
+B.position="absolute";
+B.display="block";
+var I=C.offsetWidth;
+var F=C.offsetHeight;
+B.display=A;
+B.position=D;
+B.visibility=G;
+return{width:I,height:F}
+};
+Richfaces.Calendar.checkCollision=function(A,B,D){if(A.left>=B.left&&A.top>=B.top&&A.right<=B.right&&A.bottom<=B.bottom){return 0
+}var C={left:(A.left>B.left?A.left:B.left),top:(A.top>B.top?A.top:B.top),right:(A.right<B.right?A.right:B.right),bottom:(A.bottom<B.bottom?A.bottom:B.bottom)};
+return(C.right-C.left)*(C.bottom-C.top)
+};
+Richfaces.Calendar.getWindowDimensions=function(){var A=self.innerWidth||document.documentElement.clientWidth||document.body.clientWidth||0;
+var B=self.innerHeight||document.documentElement.clientHeight||document.body.clientHeight||0;
+return{width:A,height:B}
+};
+Richfaces.Calendar.getWindowScrollOffset=function(){var B=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;
+var A=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;
+return{left:B,top:A}
+};
+Richfaces.Calendar.getWindowViewport=function(){var B=Richfaces.Calendar.getWindowDimensions();
+var A=Richfaces.Calendar.getWindowScrollOffset();
+return{left:A.left,top:A.top,right:B.width+A.left,bottom:B.height+A.top}
+};
+Richfaces.Calendar.clonePosition=function(D,C){if(!D.length){D=[D]
+}var F=Position.cumulativeOffset(C);
+F={left:F[0],top:F[1]};
+var A;
+if(C.style.position!="absolute"){A=Position.realOffset(C);
+F.left-=A.left;
+F.top-=A.top;
+A=Richfaces.Calendar.getWindowScrollOffset();
+F.left+=A.left;
+F.top+=A.top
+}for(var B=0;
+B<D.length;
+B++){A=Richfaces.Calendar.getParentOffset(D[B]);
+D[B].style.left=(F.left-A.left)+"px";
+D[B].style.top=(F.top-A.top)+"px"
+}return F
+};
+Richfaces.Calendar.getParentOffset=function(C){var G={left:0,top:0};
+var B=C.style;
+if(B.display!="none"){if(C.offsetParent&&C.offsetParent!=document.body){G=Position.cumulativeOffset(C.offsetParent)
+}}else{var F=B.visibility;
+var D=B.position;
+var A=B.display;
+B.visibility="hidden";
+B.position="absolute";
+B.display="";
+if(C.offsetParent&&C.offsetParent!=document.body){G=Position.cumulativeOffset(C.offsetParent)
+}B.display=A;
+B.position=D;
+B.visibility=F
+}return G
+};
+Richfaces.Calendar.joinArray=function(F,B,A,D){var C="";
+if(F.length!=0){C=B+F.pop()+A
+}while(F.length){C=B+F.pop()+A+D+C
+}return C
+};
+Richfaces.Calendar.getMonthByLabel=function(C,A){var B=0;
+while(B<A.length){if(A[B]==C){return B
+}else{B++
+}}};
+Object.extend(Event,{findElementByAttr:function(F,C,D,G,A){var B=Event.findElement(F,C);
+while(!B[D]||(A?B[D].indexOf(G)!=0:B[D]!=G)){B=B.parentNode
+}return B
+}});
+Object.extend(Element,{replaceClassName:function(B,A,D){if(!(B=$(B))){return 
+}var C=Element.classNames(B);
+C.remove(A);
+C.add(D);
+return B
+}});
+Richfaces.Calendar.getDefaultMonthNames=function(A){return(A?["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]:["January","February","March","April","May","June","July","August","September","October","November","December"])
+};
+Richfaces.Calendar.parseDate=function(U,Q,I,A){var L=/([.*+?^<>=!:${}()[\]\/\\])/g;
+var J;
+var C;
+if(!I){I=Richfaces.Calendar.getDefaultMonthNames();
+J=I.join("|")
+}else{J=I.join("|").replace(L,"\\$1")
+}if(!A){A=Richfaces.Calendar.getDefaultMonthNames(true);
+C=A.join("|")
+}else{C=A.join("|").replace(L,"\\$1")
+}var H=1;
+var G,M,R;
+var W,P,N;
+var B=false;
+Q=Q.replace(/([.*+?^<>=!:${}()|[\]\/\\])/g,"\\$1");
+Q=Q.replace(/(y+|M+|d+|a|H{1,2}|h{1,2}|m{2})/g,function(Y){switch(Y){case"y":case"yy":G=H;
+H++;
+return"(\\d{2})";
+case"MM":M=H;
+H++;
+return"(\\d{2})";
+case"M":M=H;
+H++;
+return"(\\d{1,2})";
+case"d":R=H;
+H++;
+return"(\\d{1,2})";
+case"MMM":M=H;
+H++;
+B=true;
+return"("+C+")";
+case"a":W=H;
+H++;
+return"(AM|am|PM|pm)?";
+case"HH":case"hh":P=H;
+H++;
+return"(\\d{2})?";
+case"H":case"h":P=H;
+H++;
+return"(\\d{1,2})?";
+case"mm":N=H;
+H++;
+return"(\\d{2})?"
+}var Z=Y.charAt(0);
+if(Z=="y"){G=H;
+H++;
+return"(\\d{4})"
+}if(Z=="M"){M=H;
+H++;
+return"("+J+")"
+}if(Z=="d"){R=H;
+H++;
+return"(\\d{2})"
+}});
+var L=new RegExp(Q,"i");
+var F=U.match(L);
+if(F!=null){var K=parseInt(F[G],10);
+if(isNaN(K)){return null
+}else{if(K<70){K+=2000
+}else{if(K<100){K+=1900
+}}}var O=parseInt(F[M],10);
+if(isNaN(O)){O=Richfaces.Calendar.getMonthByLabel(F[M],B?A:I)
+}else{if(--O<0||O>11){return null
+}}var S=parseInt(F[R],10);
+if(isNaN(S)||S<1||S>daysInMonth(K,O)){return null
+}if(N!=undefined&&P!=undefined){var D,V,X;
+V=parseInt(F[N],10);
+if(isNaN(V)||V<0||V>59){return null
+}D=parseInt(F[P],10);
+if(isNaN(D)){return null
+}if(W!=undefined){X=F[W].toLowerCase();
+if((X!="am"&&X!="pm")||D<1||D>12){return null
+}if(X=="pm"){if(D!=12){D+=12
+}}else{if(D==12){D=0
+}}}else{if(D<0||D>23){return null
+}}return new Date(K,O,S,D,V,0)
+}return new Date(K,O,S)
+}return null
+};
+Richfaces.Calendar.formatDate=function(A,G,F,H){if(!F){F=Richfaces.Calendar.getDefaultMonthNames()
+}if(!H){H=Richfaces.Calendar.getDefaultMonthNames(true)
+}var C;
+var I;
+var B;
+var D;
+var J=G.replace(/(\\\\|\\[yMdaHhm])|(y+|M+|d+|a|H{1,2}|h{1,2}|m{2})/g,function(K,N,M){if(N){return N.charAt(1)
+}switch(M){case"y":case"yy":return A.getYear().toString().slice(-2);
+case"M":return(A.getMonth()+1);
+case"MM":return((C=A.getMonth()+1)<10?"0"+C:C);
+case"MMM":return H[A.getMonth()];
+case"d":return A.getDate();
+case"a":return(A.getHours()<12?"AM":"PM");
+case"HH":return((B=A.getHours())<10?"0"+B:B);
+case"H":return A.getHours();
+case"hh":return((B=A.getHours())==0?"12":(B<10?"0"+B:(B>12?B-12:B)));
+case"h":return((B=A.getHours())==0?"12":(B>12?B-12:B));
+case"mm":return((D=A.getMinutes())<10?"0"+D:D)
+}var L=M.charAt(0);
+if(L=="y"){return A.getFullYear()
+}if(L=="M"){return F[A.getMonth()]
+}if(L=="d"){return((I=A.getDate())<10?"0"+I:I)
+}});
+return J
+};
+Richfaces.Calendar.escape=function(A){return A.replace(/([yMdaHhm\\])/g,"\\$1")
+};
+Richfaces.Calendar.unescape=function(A){return A.replace(/\\([yMdaHhm\\])/g,"$1")
+};
+function isLeapYear(A){return new Date(A,1,29).getDate()==29
+}function daysInMonth(A,B){return 32-new Date(A,B,32).getDate()
+}function daysInMonthByDate(A){return 32-new Date(A.getFullYear(),A.getMonth(),32).getDate()
+}function getDay(A,B){var C=A.getDay()-B;
+if(C<0){C=7+C
+}return C
+}function getFirstWeek(D,G,B){var C=new Date(D,0,1);
+var F=getDay(C,B);
+var A=(7-F<G)?0:1;
+return{date:C,firstDay:F,weekNumber:A,mdifw:G,fdow:B}
+}function getLastWeekOfPrevYear(D){var A=D.date.getFullYear()-1;
+var F=(isLeapYear(A)?366:365);
+var C=getFirstWeek(A,D.mdifw,D.fdow);
+F=(F-7+D.firstDay);
+var B=Math.floor(F/7)+1;
+return B+C.weekNumber
+}function weekNumber(C,F,D,A){var H=getFirstWeek(C,D,A);
+if(F==0){if(H.weekNumber==1){return 1
+}return getLastWeekOfPrevYear(H)
+}var B=604800000;
+var G=new Date(C,F,1);
+G.setDate(1+H.firstDay+(getDay(G,A)==0?1:0));
+weeknumber=H.weekNumber+Math.floor((G.getTime()-H.date.getTime())/B);
+return weeknumber
+}Calendar=Class.create();
+Object.extend(Calendar.prototype,{initialize:function(S,K){this.id=S;
+this.params=K;
+this.showApplyButton=(!this.params.popup)?false:this.params.showApplyButton;
+if(this.params.showWeekDaysBar==undefined){this.params.showWeekDaysBar=true
+}if(this.params.showWeeksBar==undefined){this.params.showWeeksBar=true
+}if(!this.params.datePattern){this.params.datePattern="MMM d, y"
+}this.setTimeProperties();
+if(!this.params.dayListMarkup){this.params.dayListMarkup=CalendarView.dayList;
+this.customDayListMarkup=false
+}else{this.customDayListMarkup=true
+}if(!this.params.weekNumberMarkup){this.params.weekNumberMarkup=CalendarView.weekNumber
+}if(!this.params.weekDayMarkup){this.params.weekDayMarkup=CalendarView.weekDay
+}if(!this.params.headerMarkup){this.params.headerMarkup=CalendarView.header
+}if(!this.params.footerMarkup){this.params.footerMarkup=CalendarView.footer
+}this.popupOffset={dx:(isNaN(this.params.horizontalOffset)?0:parseInt(this.params.horizontalOffset,10)),dy:(isNaN(this.params.verticalOffset)?0:parseInt(this.params.verticalOffset,10))};
+this.currentDate=this.params.currentDate?this.params.currentDate:(this.params.selectedDate?this.params.selectedDate:new Date());
+this.currentDate.setDate(1);
+this.selectedDate=this.params.selectedDate;
+if(typeof this.params.boundaryDatesMode=="string"){this.params.boundaryDatesMode=this.params.boundaryDatesMode.toLowerCase()
+}if(typeof this.params.todayControlMode=="string"){this.todayControlMode=this.params.todayControlMode.toLowerCase()
+}if(typeof this.params.isDayEnabled!="function"){this.params.isDayEnabled=function(c){return true
+}
+}if(typeof this.params.dayStyleClass!="function"){this.params.dayStyleClass=function(c){return""
+}
+}this.todayDate=new Date();
+this.firstWeekendDayNumber=6-this.params.firstWeekDay;
+this.secondWeekendDayNumber=(this.params.firstWeekDay>0?7-this.params.firstWeekDay:0);
+this.calendarContext=new CalendarContext(this);
+this.DATE_ELEMENT_ID=this.params.dayListTableId+"Cell";
+this.WEEKNUMBER_ELEMENT_ID=this.params.weekNumberBarId+"Cell";
+this.WEEKDAY_ELEMENT_ID=this.params.weekDayBarId+"Cell";
+this.POPUP_ID=this.id+"Popup";
+this.POPUP_BUTTON_ID=this.id+"PopupButton";
+this.INPUT_DATE_ID=this.id+"InputDate";
+this.IFRAME_ID=this.id+"IFrame";
+this.EDITOR_ID=this.id+"Editor";
+this.EDITOR_SHADOW_ID=this.id+"EditorShadow";
+this.TIME_EDITOR_LAYOUT_ID=this.id+"TimeEditorLayout";
+this.DATE_EDITOR_LAYOUT_ID=this.id+"DateEditorLayout";
+this.EDITOR_LAYOUT_SHADOW_ID=this.id+"EditorLayoutShadow";
+this.firstDateIndex=0;
+this.daysData={startDate:null,days:[]};
+this.days=[];
+this.todayCellId=null;
+this.todayCellColor="";
+this.selectedDateCellId=null;
+this.selectedDateCellColor="";
+var J="";
+this.isVisible=true;
+if(this.params.popup==true){J="display:none; position:absolute;";
+this.isVisible=false
+}var L='<table id="'+this.id+'" border="0" cellpadding="0" cellspacing="0" class="rich-calendar-exterior rich-calendar-popup'+(this.params.className?" "+this.params.className:"")+'" style="'+J+this.params.style+'"><tbody>\n';
+var C=(this.params.showWeeksBar?"8":"7");
+var I=(this.params.optionalHeaderMarkup)?'<tr><td class="rich-calendar-header-optional" colspan="'+C+'" id="'+this.id+'HeaderOptional"></td></tr>':"";
+var W=(this.params.optionalFooterMarkup)?'<tr><td class="rich-calendar-footer-optional" colspan="'+C+'" id="'+this.id+'FooterOptional"></td></tr>':"";
+var Z='<tr><td class="rich-calendar-header" colspan="'+C+'" id="'+this.id+'Header"></td></tr>';
+var U='<tr><td class="rich-calendar-footer" colspan="'+C+'" id="'+this.id+'Footer"></td></tr>';
+var F="</tbody></table>\n";
+var G='<iframe src="javascript:\'\'" frameborder="0" scrolling="no" id="'+this.IFRAME_ID+'" style="display:none; position: absolute; width: 1px; height: 1px; background-color:white;"></iframe>\n';
+var O;
+var A;
+var M="";
+var D;
+if(this.params.showWeekDaysBar){var M='<tr id="'+this.params.weekDayBarId+'">';
+if(this.params.showWeeksBar){M+='<td class="rich-calendar-days"><br/></td>'
+}var b=this.params.firstWeekDay;
+for(var X=0;
+X<7;
+X++){D={weekDayLabel:this.params.weekDayLabels[b],weekDayLabelShort:this.params.weekDayLabelsShort[b],weekDayNumber:b,isWeekend:this.isWeekend(X),elementId:this.WEEKDAY_ELEMENT_ID+X,component:this};
+var a=this.evaluateMarkup(this.params.weekDayMarkup,D);
+if(b==6){b=0
+}else{b++
+}O="rich-calendar-days";
+if(D.isWeekend){O+=" rich-calendar-weekends"
+}if(X==6){O+=" rich-right-cell"
+}M+='<td class="'+O+'" id="'+D.elementId+'">'+a+"</td>"
+}M+="</tr>\n"
+}var Y="";
+var R=0;
+for(k=1;
+k<7;
+k++){A=(k==6?"rich-bottom-cell ":"");
+Y+='<tr id="'+this.params.weekNumberBarId+k+'">';
+if(this.params.showWeeksBar){D={weekNumber:k,elementId:this.WEEKNUMBER_ELEMENT_ID+k,component:this};
+var H=this.evaluateMarkup(this.params.weekNumberMarkup,D);
+Y+='<td class="rich-calendar-week '+A+'" id="'+D.elementId+'">'+H+"</td>"
+}for(var X=0;
+X<7;
+X++){O=A+(!this.params.dayCellClass?"rich-calendar-cell-size":(!this.customDayListMarkup?this.params.dayCellClass:""))+" rich-calendar-cell";
+if(X==this.firstWeekendDayNumber||X==this.secondWeekendDayNumber){O+=" rich-calendar-holly"
+}if(X==6){O+=" rich-right-cell"
+}Y+='<td class="'+O+'" id="'+this.DATE_ELEMENT_ID+R+'">'+(this.customDayListMarkup?'<div class="rich-calendar-cell-div'+(this.params.dayCellClass?" "+this.params.dayCellClass:"")+'"></div>':"")+"</td>";
+R++
+}Y+="</tr>"
+}var V=$(this.POPUP_ID);
+var P=V.nextSibling;
+if(this.params.popup&&Richfaces.browser.isIE6){do{if(P.id==this.IFRAME_ID){var N=P;
+P=P.nextSibling;
+Element.replace(N,G);
+break
+}}while(P=P.nextSibling)
+}do{if(P.id==S){var Q=P;
+P=P.previousSibling;
+Element.replace(Q,L+I+Z+M+Y+U+W+F);
+break
+}}while(P=P.nextSibling);
+P=P.nextSibling;
+P.component=this;
+P.richfacesComponent="richfaces:calendar";
+P=null;
+V=null;
+if(this.params.submitFunction){this.submitFunction=this.params.submitFunction.bind(this)
+}this.prepareEvents();
+this.doSetCellEvents=true;
+if(this.params.popup&&!this.params.disabled){var B=new Function("event","$('"+this.id+"').component.doSwitch();").bindAsEventListener();
+Event.observe(this.POPUP_BUTTON_ID,"click",B,false);
+if(!this.params.enableManualInput){Event.observe(this.INPUT_DATE_ID,"click",B,false)
+}}},dateEditorSelectYear:function(A){if(this.dateEditorYearID){Element.removeClassName(this.dateEditorYearID,"rich-calendar-editor-btn-selected")
+}this.dateEditorYear=this.dateEditorStartYear+A;
+this.dateEditorYearID=this.DATE_EDITOR_LAYOUT_ID+"Y"+A;
+Element.addClassName(this.dateEditorYearID,"rich-calendar-editor-btn-selected")
+},dateEditorSelectMonth:function(A){this.dateEditorMonth=A;
+Element.removeClassName(this.dateEditorMonthID,"rich-calendar-editor-btn-selected");
+this.dateEditorMonthID=this.DATE_EDITOR_LAYOUT_ID+"M"+A;
+Element.addClassName(this.dateEditorMonthID,"rich-calendar-editor-btn-selected")
+},scrollEditorYear:function(D){var B=$(this.DATE_EDITOR_LAYOUT_ID+"TR");
+if(this.dateEditorYearID){Element.removeClassName(this.dateEditorYearID,"rich-calendar-editor-btn-selected");
+this.dateEditorYearID=""
+}if(!D){if(this.dateEditorMonth!=this.getCurrentMonth()){this.dateEditorMonth=this.getCurrentMonth();
+Element.removeClassName(this.dateEditorMonthID,"rich-calendar-editor-btn-selected");
+this.dateEditorMonthID=this.DATE_EDITOR_LAYOUT_ID+"M"+this.dateEditorMonth;
+Element.addClassName(this.dateEditorMonthID,"rich-calendar-editor-btn-selected")
+}}if(B){var F;
+var C=this.dateEditorStartYear=this.dateEditorStartYear+D*10;
+for(var A=0;
+A<5;
+A++){B=B.nextSibling;
+F=B.firstChild.nextSibling.nextSibling;
+F.firstChild.innerHTML=C;
+if(C==this.dateEditorYear){Element.addClassName(F.firstChild,"rich-calendar-editor-btn-selected");
+this.dateEditorYearID=F.firstChild.id
+}F=F.nextSibling;
+F.firstChild.innerHTML=C+5;
+if(C+5==this.dateEditorYear){Element.addClassName(F.firstChild,"rich-calendar-editor-btn-selected");
+this.dateEditorYearID=F.firstChild.id
+}C++
+}}},updateDateEditor:function(){this.dateEditorYear=this.getCurrentYear();
+this.dateEditorStartYear=this.getCurrentYear()-4;
+this.scrollEditorYear(0)
+},updateTimeEditor:function(){var G=$(this.id+"TimeHours");
+var F=$(this.id+"TimeSign");
+var C=$(this.id+"TimeMinutes");
+var D=this.selectedDate.getHours();
+var A=this.selectedDate.getMinutes();
+if(this.timeType==2){var B=(D<12?"AM":"PM");
+F.value=B;
+D=(D==0?"12":(D>12?D-12:D))
+}G.value=(this.timeHoursDigits==2&&D<10?"0"+D:D);
+C.value=(A<10?"0"+A:A)
+},createEditor:function(){var F=$(this.id);
+var A='<div id="'+this.EDITOR_SHADOW_ID+'" class="rich-calendar-editor-shadow" style="position:absolute; display:none;"></div><table border="0" cellpadding="0" cellspacing="0" id="'+this.EDITOR_ID+'" style="position:absolute; display:none;"><tbody><tr><td class="rich-calendar-editor-container" align="center"><div style="position:relative; width:100%">';
+var H='<div id="'+this.EDITOR_LAYOUT_SHADOW_ID+'" class="rich-calendar-editor-layout-shadow"></div>';
+var C="</div></td></tr></tbody></table>";
+new Insertion.After(F,A+H+C);
+var B=$(this.EDITOR_SHADOW_ID);
+var G=$(this.EDITOR_ID);
+var D=F.getStyle("z-index");
+B.style.zIndex=D;
+G.style.zIndex=parseInt(D,10)+1;
+this.isEditorCreated=true
+},createTimeEditorLayout:function(){Element.insert(this.EDITOR_LAYOUT_SHADOW_ID,{after:this.evaluateMarkup(this.calendarContext.timeEditorLayout,this.calendarContext)});
+var C=$(this.id+"TimeHours");
+var B;
+var A=$(this.id+"TimeMinutes");
+if(this.timeType==1){sbjQuery(C).SpinButton({digits:this.timeHoursDigits,min:0,max:23})
+}else{sbjQuery(C).SpinButton({digits:this.timeHoursDigits,min:1,max:12});
+B=$(this.id+"TimeSign");
+sbjQuery(B).SpinButton({})
+}sbjQuery(A).SpinButton({digits:2,min:0,max:59});
+this.isTimeEditorLayoutCreated=true
+},createDECell:function(G,D,A,F,C){var B=(A==0?"$('"+this.id+"').component.scrollEditorYear("+F+");":A==1?"$('"+this.id+"').component.dateEditorSelectMonth("+F+");":"$('"+this.id+"').component.dateEditorSelectYear("+F+");");
+return'<td><div id="'+G+'" class="rich-calendar-editor-btn'+(C?" "+C:"")+'" onmouseover="Element.addClassName(this, \'rich-calendar-editor-btn-over\');" onmouseout="Element.removeClassName(this, \'rich-calendar-editor-btn-over\');" onclick="'+B+'">'+D+"</div></td>"
+},createDateEditorLayout:function(){var A='<table id="'+this.DATE_EDITOR_LAYOUT_ID+'" class="rich-calendar-time-layout" border="0" cellpadding="0" cellspacing="0"><tbody><tr id="'+this.DATE_EDITOR_LAYOUT_ID+'TR">';
+var B="</tr></tbody></table>";
+var F=0;
+this.dateEditorYear=this.getCurrentYear();
+var D=this.dateEditorStartYear=this.dateEditorYear-4;
+var G=this.createDECell(this.DATE_EDITOR_LAYOUT_ID+"M"+F,this.params.monthLabelsShort[F],1,F)+this.createDECell(this.DATE_EDITOR_LAYOUT_ID+"M"+(F+6),this.params.monthLabelsShort[F+6],1,F+6)+this.createDECell("","<",0,-1)+this.createDECell("",">",0,1);
+F++;
+for(var C=0;
+C<5;
+C++){G+="</tr><tr>"+this.createDECell(this.DATE_EDITOR_LAYOUT_ID+"M"+F,this.params.monthLabelsShort[F],1,F)+this.createDECell(this.DATE_EDITOR_LAYOUT_ID+"M"+(F+6),this.params.monthLabelsShort[F+6],1,F+6)+this.createDECell(this.DATE_EDITOR_LAYOUT_ID+"Y"+C,D,2,C,(C==4?"rich-calendar-editor-btn-selected":""))+this.createDECell(this.DATE_EDITOR_LAYOUT_ID+"Y"+(C+5),D+5,2,C+5);
+F++;
+D++
+}this.dateEditorYearID=this.DATE_EDITOR_LAYOUT_ID+"Y4";
+this.dateEditorMonth=this.getCurrentMonth();
+this.dateEditorMonthID=this.DATE_EDITOR_LAYOUT_ID+"M"+this.dateEditorMonth;
+G+='</tr><tr><td colspan="2" class="rich-calendar-time-layout-ok"><div class="rich-calendar-time-btn" style="float:right;" onmousedown="Element.addClassName(this, \'rich-calendar-time-btn-press\');" onmouseout="Element.removeClassName(this, \'rich-calendar-time-btn-press\');" onmouseup="Element.removeClassName(this, \'rich-calendar-time-btn-press\');" onclick="$(\''+this.id+'\').component.hideDateEditor(true);">OK</div></td><td colspan="2" class="rich-calendar-time-layout-cancel"><div class="rich-calendar-time-btn" style="float:left;" onmousedown="Element.addClassName(this, \'rich-calendar-time-btn-press\');" onmouseout="Element.removeClassName(this, \'rich-calendar-time-btn-press\');" onmouseup="Element.removeClassName(this, \'rich-calendar-time-btn-press\');" onclick="$(\''+this.id+"').component.hideDateEditor(false);\">Cancel</div></td>";
+Element.insert(this.EDITOR_LAYOUT_SHADOW_ID,{after:A+G+B});
+Element.addClassName(this.dateEditorMonthID,"rich-calendar-editor-btn-selected");
+this.isDateEditorLayoutCreated=true
+},createSpinnerTable:function(A){return'<table cellspacing="0" cellpadding="0" border="0"><tbody><tr><td class="rich-calendar-spinner-input-container"><input id="'+A+'" class="rich-calendar-spinner-input" type="text" /></td><td class="rich-calendar-spinner-buttons"><table border="0" cellspacing="0" cellpadding="0"><tbody><tr><td><div id="'+A+'BtnUp" class="rich-calendar-spinner-up" onmousedown="this.className=\'rich-calendar-spinner-up rich-calendar-spinner-pressed\'" onmouseup="this.className=\'rich-calendar-spinner-up\'" onmouseout="this.className=\'rich-calendar-spinner-up\'"/></td></tr><tr><td><div id="'+A+'BtnDown" class="rich-calendar-spinner-down" onmousedown="this.className=\'rich-calendar-spinner-down rich-calendar-spinner-pressed\'" onmouseup="this.className=\'rich-calendar-spinner-down\'" onmouseout="this.className=\'rich-calendar-spinner-down\'" /></td></tr></tbody></table></td></tr></tbody></table>'
+},setTimeProperties:function(){this.timeType=0;
+var Q=this.params.datePattern;
+var N=[];
+var P=/(\\\\|\\[yMdaHhm])|(y+|M+|d+|a|H{1,2}|h{1,2}|m{2})/g;
+var B;
+while(B=P.exec(Q)){if(!B[1]){N.push({str:B[0],marker:B[2],idx:B.index})
+}}var F="";
+var R="";
+var G,M,I,H,O;
+var D=this.id;
+var C=function(S){return(S.length==0?K.marker:Q.substring(N[L-1].str.length+N[L-1].idx,K.idx+K.str.length))
+};
+for(var L=0;
+L<N.length;
+L++){var K=N[L];
+var A=K.marker.charAt(0);
+if(A=="y"||A=="M"||A=="d"){F+=C(F)
+}else{if(A=="a"){O=true;
+R+=C(R)
+}else{if(A=="H"){M=true;
+G=K.marker.length;
+R+=C(R)
+}else{if(A=="h"){I=true;
+G=K.marker.length;
+R+=C(R)
+}else{if(A=="m"){H=true;
+R+=C(R)
+}}}}}}this.datePattern=F;
+this.timePattern=R;
+var J=this;
+this.timePatternHtml=R.replace(/(\\\\|\\[yMdaHhm])|(H{1,2}|h{1,2}|m{2}|a)/g,function(S,V,U){if(V){return V.charAt(1)
+}switch(U){case"a":return"</td><td>"+J.createSpinnerTable(D+"TimeSign")+"</td><td>";
+case"H":case"HH":case"h":case"hh":return"</td><td>"+J.createSpinnerTable(D+"TimeHours")+"</td><td>";
+case"mm":return"</td><td>"+J.createSpinnerTable(D+"TimeMinutes")+"</td><td>"
+}});
+this.timePatternHtml='<table border="0" cellpadding="0"><tbody><tr><td>'+this.timePatternHtml+"</td></tr></tbody></table>";
+if(H&&M){this.timeType=1
+}else{if(H&&I&&O){this.timeType=2
+}}this.timeHoursDigits=G
+},doCollapse:function(){if(!this.params.popup||!this.isVisible){return 
+}if(this.isEditorVisible){this.hideEditor()
+}var A=$(this.id);
+if(this.invokeEvent("collapse",A)){Event.stopObserving(window.document,"click",this.eventOnCollapse,false);
+var B=null;
+if(Richfaces.browser.isIE6){B=$(this.IFRAME_ID)
+}if(B){Element.hide(B)
+}Element.hide(A);
+this.isVisible=false
+}},doExpand:function(J){this.skipEventOnCollapse=false;
+if(J&&J.type=="click"){this.skipEventOnCollapse=true
+}if(!this.params.popup||this.isVisible){return 
+}var H=$(this.id);
+if(this.invokeEvent("expand",H)){var F=null;
+if(Richfaces.browser.isIE6){F=$(this.IFRAME_ID)
+}var B=$(this.POPUP_ID);
+var N=B.firstChild;
+var O=N.nextSibling;
+if(N&&N.value!=undefined){this.selectDate(N.value)
+}var C=Position.cumulativeOffset(O);
+if(this.params.showInput){var G=Position.cumulativeOffset(N);
+C=[C[0]<G[0]?C[0]:G[0],C[1]<G[1]?C[1]:G[1]];
+var M=Richfaces.Calendar.getOffsetDimensions(N)
+}var K=Richfaces.Calendar.getOffsetDimensions(B);
+var I=Richfaces.Calendar.getOffsetDimensions(O);
+var L=Position.realOffset(O);
+var D={left:C[0]-L[0],top:C[1]-L[1],width:K.width,height:(M&&M.height>I.height?M.height:I.height)};
+Richfaces.Calendar.setElementPosition(H,D,this.params.jointPoint,this.params.direction,this.popupOffset);
+if(F){F.style.left=H.style.left;
+F.style.top=H.style.top;
+var A=Richfaces.Calendar.getOffsetDimensions(H);
+F.style.width=A.width+"px";
+F.style.height=A.height+"px";
+Element.show(F)
+}Element.show(H);
+this.isVisible=true;
+Event.observe(window.document,"click",this.eventOnCollapse,false)
+}},doSwitch:function(A){this.isVisible?this.doCollapse():this.doExpand(A)
+},eventOnCollapse:function(A){if(this.skipEventOnCollapse){this.skipEventOnCollapse=false;
+return true
+}if(Event.element(A).id==this.POPUP_BUTTON_ID||(!this.params.enableManualInput&&Event.element(A).id==this.INPUT_DATE_ID)){return true
+}if(Position.within($(this.id),Event.pointerX(A),Event.pointerY(A))){return true
+}this.doCollapse();
+return true
+},getCurrentDate:function(){return this.currentDate
+},getSelectedDate:function(){if(!this.selectedDate){return null
+}else{return this.selectedDate
+}},getSelectedDateString:function(A){if(!this.selectedDate){return""
+}if(!A){A=this.params.datePattern
+}return Richfaces.Calendar.formatDate(this.selectedDate,A,this.params.monthLabels,this.params.monthLabelsShort)
+},getPrevYear:function(){var A=this.currentDate.getFullYear()-1;
+if(A<0){A=0
+}return A
+},getPrevMonth:function(A){var B=this.currentDate.getMonth()-1;
+if(B<0){B=11
+}if(A){return this.params.monthLabels[B]
+}else{return B
+}},getCurrentYear:function(){return this.currentDate.getFullYear()
+},getCurrentMonth:function(A){var B=this.currentDate.getMonth();
+if(A){return this.params.monthLabels[B]
+}else{return B
+}},getNextYear:function(){return this.currentDate.getFullYear()+1
+},getNextMonth:function(A){var B=this.currentDate.getMonth()+1;
+if(B>11){B=0
+}if(A){return this.params.monthLabels[B]
+}else{return B
+}},isWeekend:function(A){return(A==this.firstWeekendDayNumber||A==this.secondWeekendDayNumber)
+},prepareEvents:function(){this.eventCellOnClick=this.eventCellOnClick.bindAsEventListener(this);
+this.eventCellOnMouseOver=this.eventCellOnMouseOver.bindAsEventListener(this);
+this.eventCellOnMouseOut=this.eventCellOnMouseOut.bindAsEventListener(this);
+this.eventOnCollapse=this.eventOnCollapse.bindAsEventListener(this)
+},setCellEvents:function(A){Event.observe(A,"click",this.eventCellOnClick,false);
+Event.observe(A,"mouseover",this.eventCellOnMouseOver,false);
+Event.observe(A,"mouseout",this.eventCellOnMouseOut,false)
+},stopCellEvents:function(A){Event.stopObserving(A,"click",this.eventCellOnClick,false);
+Event.stopObserving(A,"mouseover",this.eventCellOnMouseOver,false);
+Event.stopObserving(A,"mouseout",this.eventCellOnMouseOut,false)
+},invokeEvent:function(B,D,G,C){var F=this.params["on"+B];
+var A;
+if(F){var H;
+if(G){H=G
+}else{if(document.createEventObject){H=document.createEventObject()
+}else{if(document.createEvent){H=document.createEvent("Events");
+H.initEvent(B,true,false)
+}}}H.rich={component:this};
+H.rich.date=C;
+try{A=F.call(D,H)
+}catch(I){LOG.warn("Exception: "+I.Message+"\n[on"+B+"]")
+}}if(A!=false){A=true
+}return A
+},eventCellOnClick:function(D){var C=Event.findElementByAttr(D,"TD","id",this.DATE_ELEMENT_ID,true);
+if(C){var B=this.days[parseInt(C.id.substr(this.DATE_ELEMENT_ID.length),10)];
+if(B.enabled&&B._month==0){var A=new Date(this.currentDate);
+A.setDate(B.day);
+if(this.selectDate(A,true)&&!this.showApplyButton){this.doCollapse()
+}}else{if(this.params.boundaryDatesMode=="scroll"){if(B._month==-1){this.prevMonth()
+}else{this.nextMonth()
+}}else{if(this.params.boundaryDatesMode=="select"){if(this.selectDate(B.date)&&!this.showApplyButton){this.doCollapse()
+}}}}}},eventCellOnMouseOver:function(C){var B=Event.findElementByAttr(C,"TD","id",this.DATE_ELEMENT_ID,true);
+if(B){var A=this.days[parseInt(B.id.substr(this.DATE_ELEMENT_ID.length),10)];
+if(this.invokeEvent("datemouseover",B,C,A.date)&&A.enabled){if(A._month==0&&B.id!=this.selectedDateCellId&&B.id!=this.todayCellId){Element.addClassName(B,"rich-calendar-hover")
+}}}},eventCellOnMouseOut:function(C){var B=Event.findElementByAttr(C,"TD","id",this.DATE_ELEMENT_ID,true);
+if(B){var A=this.days[parseInt(B.id.substr(this.DATE_ELEMENT_ID.length),10)];
+if(this.invokeEvent("datemouseout",B,C,A.date)&&A.enabled){if(A._month==0&&B.id!=this.selectedDateCellId&&B.id!=this.todayCellId){Element.removeClassName(B,"rich-calendar-hover")
+}}}},load:function(B,A){if(!$(this.id).component){return 
+}if(B){this.daysData=this.indexData(B,A)
+}else{this.daysData=null
+}this.render();
+if(typeof this.afterLoad=="function"){this.afterLoad();
+this.afterLoad=null
+}},indexData:function(F,B){var C=F.startDate.getFullYear();
+var D=F.startDate.getMonth();
+F.index=[];
+F.index[C+"-"+D]=0;
+if(B){this.currentDate=F.startDate;
+this.currentDate.setDate(1);
+return F
+}var A=daysInMonthByDate(F.startDate)-F.startDate.getDate()+1;
+while(F.days[A]){if(D==11){C++;
+D=0
+}else{D++
+}F.index[C+"-"+D]=A;
+A+=(32-new Date(C,D,32).getDate())
+}return F
+},getCellBackgroundColor:function(D){var A;
+if(Richfaces.browser.isSafari&&this.params.popup&&!this.isVisible){var C=$(this.id).style;
+var F=C.visibility;
+var B=C.display;
+C.visibility="hidden";
+C.display="";
+A=Element.getStyle(D,"background-color").parseColor();
+C.display=B;
+C.visibility=F
+}else{A=Element.getStyle(D,"background-color").parseColor()
+}return A
+},clearEffect:function(A,C,B,F){if(C){C.cancel();
+C=null
+}if(A){var D=$(A);
+D.style["backgroundColor"]="";
+if(B){Element.removeClassName(D,B)
+}if(F){Element.addClassName(D,F)
+}}return null
+},render:function(){this.todayDate=new Date();
+var c=this.getCurrentYear();
+var R=this.getCurrentMonth();
+var L=(c==this.todayDate.getFullYear()&&R==this.todayDate.getMonth());
+var Q=this.todayDate.getDate();
+var S=this.selectedDate&&(c==this.selectedDate.getFullYear()&&R==this.selectedDate.getMonth());
+var X=this.selectedDate&&this.selectedDate.getDate();
+var H=getDay(this.currentDate,this.params.firstWeekDay);
+var G=daysInMonthByDate(this.currentDate);
+var A=daysInMonth(c,R-1);
+var P=0;
+var b=-1;
+this.days=[];
+var K=A-H+1;
+if(H>0){while(K<=A){this.days.push({day:K,isWeekend:this.isWeekend(P),_month:b});
+K++;
+P++
+}}K=1;
+b=0;
+this.firstDateIndex=P;
+if(this.daysData&&this.daysData.index[c+"-"+R]!=undefined){var O=this.daysData.index[c+"-"+R];
+if(this.daysData.startDate.getFullYear()==c&&this.daysData.startDate.getMonth()==R){var J=J=(this.daysData.days[O].day?this.daysData.days[O].day:this.daysData.startDate.getDate());
+while(K<J){this.days.push({day:K,isWeekend:this.isWeekend(P%7),_month:b});
+K++;
+P++
+}}var W=this.daysData.days.length;
+var M;
+var V;
+while(O<W&&K<=G){V=this.isWeekend(P%7);
+M=this.daysData.days[O];
+M.day=K;
+M.isWeekend=V;
+M._month=b;
+this.days.push(M);
+O++;
+K++;
+P++
+}}while(P<42){if(K>G){K=1;
+b=1
+}this.days.push({day:K,isWeekend:this.isWeekend(P%7),_month:b});
+K++;
+P++
+}this.renderHF();
+this.renderHeaderOptional();
+this.renderFooterOptional();
+P=0;
+var B;
+var I;
+var D;
+if(this.params.showWeeksBar){D=weekNumber(c,R,this.params.minDaysInFirstWeek,this.params.firstWeekDay)
+}this.selectedDayElement=null;
+var N=true;
+var Y;
+var a=(this.params.boundaryDatesMode=="scroll"||this.params.boundaryDatesMode=="select");
+this.todayCellId=this.clearEffect(this.todayCellId,this.highlightEffect,"rich-calendar-today");
+this.selectedDateCellId=this.clearEffect(this.selectedDateCellId,this.highlightEffect2,"rich-calendar-select","rich-calendar-btn");
+var M=$(this.params.weekNumberBarId+"1");
+for(var U=1;
+U<7;
+U++){I=this.days[P];
+B=M.firstChild;
+var Z;
+if(this.params.showWeeksBar){if(N&&R==11&&(U==5||U==6)&&(I._month==1||(G-I.day+1)<this.params.minDaysInFirstWeek)){D=1;
+N=false
+}Z=D;
+B.innerHTML=this.evaluateMarkup(this.params.weekNumberMarkup,{weekNumber:D++,elementId:B.id,component:this});
+if(U==1&&D>52){D=1
+}B=B.nextSibling
+}var d=this.params.firstWeekDay;
+var F=null;
+while(B){I.elementId=B.id;
+I.date=new Date(c,R+I._month,I.day);
+I.weekNumber=Z;
+I.component=this;
+I.isCurrentMonth=(I._month==0);
+I.weekDayNumber=d;
+if(I.enabled!=false){I.enabled=this.params.isDayEnabled(I)
+}if(!I.styleClass){I.customStyleClass=this.params.dayStyleClass(I)
+}else{var C=this.params.dayStyleClass(I);
+I.customStyleClass=I.styleClass;
+if(C){I.customStyleClass+=" "+C
+}}F=(this.customDayListMarkup?B.firstChild:B);
+F.innerHTML=this.evaluateMarkup(this.params.dayListMarkup,I);
+if(d==6){d=0
+}else{d++
+}Y=Element.classNames(B);
+if(B.rich&&B.rich.customStyleClass){B.rich.customStyleClass.split(" ").each(function(e){Y.remove(e)
+});
+B.rich.customStyleClass=null
+}if(I._month!=0){Y.add("rich-calendar-boundary-dates");
+if(a){Y.add("rich-calendar-btn")
+}else{Y.remove("rich-calendar-btn")
+}}else{Y.remove("rich-calendar-boundary-dates");
+if(I.enabled){Y.add("rich-calendar-btn")
+}else{Y.remove("rich-calendar-btn")
+}if(I.customStyleClass){Y.add(I.customStyleClass);
+B.rich={customStyleClass:I.customStyleClass}
+}}if(L&&I._month==0&&I.day==Q){this.todayCellId=B.id;
+this.todayCellColor=this.getCellBackgroundColor(B);
+Y.add("rich-calendar-today")
+}if(S&&I._month==0&&I.day==X){this.selectedDateCellId=B.id;
+this.selectedDateCellColor=this.getCellBackgroundColor(B);
+Y.remove("rich-calendar-btn");
+Y.add("rich-calendar-select")
+}if(this.doSetCellEvents){this.setCellEvents(B)
+}P++;
+I=this.days[P];
+B=B.nextSibling
+}M=M.nextSibling
+}this.doSetCellEvents=false
+},renderHF:function(){this.renderMarkup(this.params.headerMarkup,this.id+"Header",this.calendarContext);
+this.renderMarkup(this.params.footerMarkup,this.id+"Footer",this.calendarContext)
+},renderHeaderOptional:function(){this.renderMarkup(this.params.optionalHeaderMarkup,this.id+"HeaderOptional",this.calendarContext)
+},renderFooterOptional:function(){this.renderMarkup(this.params.optionalFooterMarkup,this.id+"FooterOptional",this.calendarContext)
+},renderMarkup:function(B,A,C){if(!B){return 
+}var D=$(A);
+if(!D){return 
+}D.innerHTML=B.invoke("getContent",C).join("")
+},evaluateMarkup:function(A,B){if(!A){return""
+}return A.invoke("getContent",B).join("")
+},onUpdate:function(){var A=Richfaces.Calendar.formatDate(this.getCurrentDate(),"MM/yyyy");
+$(this.id+"InputCurrentDate").value=A;
+if(this.submitFunction){this.submitFunction(A)
+}else{this.render()
+}},nextMonth:function(){this.changeCurrentDateOffset(0,1)
+},prevMonth:function(){this.changeCurrentDateOffset(0,-1)
+},nextYear:function(){this.changeCurrentDateOffset(1,0)
+},prevYear:function(){this.changeCurrentDateOffset(-1,0)
+},changeCurrentDate:function(B,C){if(this.getCurrentMonth()!=C||this.getCurrentYear()!=B){var A=new Date(B,C,1);
+if(this.invokeEvent("currentdateselect",$(this.id),null,A)){this.currentDate=A;
+this.onUpdate()
+}}},changeCurrentDateOffset:function(B,C){var A=new Date(this.currentDate.getFullYear()+B,this.currentDate.getMonth()+C,1);
+if(this.invokeEvent("currentdateselect",$(this.id),null,A)){this.currentDate=A;
+this.onUpdate()
+}},today:function(D,G){var B=new Date();
+var F=B.getFullYear();
+var H=B.getMonth();
+var C=B.getDate();
+var A=false;
+if(C!=this.todayDate.getDate()){A=true;
+this.todayDate=B
+}if(F!=this.currentDate.getFullYear()||H!=this.currentDate.getMonth()){A=true;
+this.currentDate=new Date(F,H,1)
+}if(this.todayControlMode=="select"){G=true
+}if(A){if(D){this.render()
+}else{this.onUpdate()
+}}else{if(this.isVisible&&this.todayCellId&&!G){this.clearEffect(this.todayCellId,this.highlightEffect);
+if(this.todayCellColor!="transparent"){this.highlightEffect=new Effect.Highlight($(this.todayCellId),{startcolor:this.todayCellColor,duration:0.3,transition:Effect.Transitions.sinoidal,afterFinish:this.onHighlightFinish})
+}}}if(this.todayControlMode=="select"){if(A&&!D&&this.submitFunction){this.afterLoad=this.selectToday
+}else{this.selectToday()
+}}},selectToday:function(){if(this.todayCellId){var A=this.days[parseInt($(this.todayCellId).id.substr(this.DATE_ELEMENT_ID.length),10)];
+if(A.enabled&&this.selectDate(new Date(),true)&&!this.showApplyButton){this.doCollapse()
+}}},onHighlightFinish:function(A){A.element.style["backgroundColor"]=""
+},selectDate:function(C,B,L){if(!L){L={event:null,element:null}
+}var A=this.selectedDate;
+var M;
+var H=false;
+if(C){if(typeof C=="string"){C=Richfaces.Calendar.parseDate(C,this.params.datePattern,this.params.monthLabels,this.params.monthLabelsShort);
+if(C){H=true
+}}M=C
+}else{M=null
+}var I=true;
+var D=false;
+if((A-M)&&(A!=null||M!=null)){D=true;
+I=this.invokeEvent("dateselect",L.element,L.event,C)
+}if(I){var J=$(this.INPUT_DATE_ID);
+this.selectedDate=M;
+if(this.selectedDate!=null){if(this.timeType&&!H){if(A!=null){this.selectedDate.setHours(A.getHours());
+this.selectedDate.setMinutes(A.getMinutes())
+}else{this.selectedDate.setHours(12);
+this.selectedDate.setMinutes(0)
+}this.selectedDate.setSeconds(0)
+}if(!this.showApplyButton){J.value=this.getSelectedDateString(this.params.datePattern)
+}var G=new Date(this.selectedDate);
+if(G.getMonth()==this.currentDate.getMonth()&&G.getFullYear()==this.currentDate.getFullYear()){if(!A||A.getDate()!=G.getDate()){var F=$(this.DATE_ELEMENT_ID+(this.firstDateIndex+this.selectedDate.getDate()-1));
+this.clearEffect(this.selectedDateCellId,this.highlightEffect2,"rich-calendar-select","rich-calendar-btn");
+this.selectedDateCellId=F.id;
+this.selectedDateCellColor=this.getCellBackgroundColor(F);
+Element.removeClassName(F,"rich-calendar-btn");
+Element.removeClassName(F,"rich-calendar-hover");
+Element.addClassName(F,"rich-calendar-select");
+this.renderHF()
+}else{if(this.timeType!=0){this.renderHF()
+}}}else{G.setDate(1);
+this.currentDate=G;
+if(B){this.render()
+}else{this.onUpdate()
+}}}else{this.selectedDate=null;
+J.value="";
+this.clearEffect(this.selectedDateCellId,this.highlightEffect2,"rich-calendar-select","rich-calendar-btn");
+if(this.selectedDateCellId){this.selectedDateCellId=null;
+this.renderHF()
+}var C=new Date();
+if(this.currentDate.getMonth()==C.getMonth()&&this.currentDate.getFullYear()==C.getFullYear()){this.renderHF()
+}var K=this.todayControlMode;
+this.todayControlMode="";
+this.today(B,true);
+this.todayControlMode=K
+}if(D){this.invokeEvent("dateselected",L.element,L.event,this.selectedDate)
+}}return I
+},resetSelectedDate:function(){if(!this.selectedDate){return 
+}if(this.invokeEvent("dateselect",null,null,null)){this.selectedDate=null;
+this.selectedDateCellId=this.clearEffect(this.selectedDateCellId,this.highlightEffect2,"rich-calendar-select","rich-calendar-btn");
+this.renderHF();
+if(!this.showApplyButton){$(this.INPUT_DATE_ID).value="";
+this.doCollapse();
+this.invokeEvent("dateselected",null,null,null)
+}}},showSelectedDate:function(){if(!this.selectedDate){return 
+}if(this.currentDate.getMonth()!=this.selectedDate.getMonth()||this.currentDate.getFullYear()!=this.selectedDate.getFullYear()){this.currentDate=new Date(this.selectedDate);
+this.currentDate.setDate(1);
+this.onUpdate()
+}else{if(this.isVisible&&this.selectedDateCellId){this.clearEffect(this.selectedDateCellId,this.highlightEffect2);
+if(this.selectedDateCellColor!="transparent"){this.highlightEffect2=new Effect.Highlight($(this.selectedDateCellId),{startcolor:this.selectedDateCellColor,duration:0.3,transition:Effect.Transitions.sinoidal,afterFinish:this.onHighlightFinish})
+}}}},close:function(B){if(B){var A=$(this.INPUT_DATE_ID);
+A.value=this.getSelectedDateString(this.params.datePattern)
+}this.doCollapse()
+},setEditorPosition:function(A,B,D){A;
+var C=Richfaces.Calendar.getOffsetDimensions(A);
+B.style.width=D.style.width=C.width+"px";
+B.style.height=D.style.height=C.height+"px";
+Richfaces.Calendar.clonePosition([B,D],A)
+},showTimeEditor:function(){if(this.timeType==0){return 
+}if(!this.isEditorCreated){this.createEditor()
+}if(!this.isTimeEditorLayoutCreated){this.createTimeEditorLayout()
+}$(this.TIME_EDITOR_LAYOUT_ID).show();
+var B=$(this.EDITOR_ID);
+var A=$(this.EDITOR_SHADOW_ID);
+this.setEditorPosition($(this.id),B,A);
+this.updateTimeEditor();
+A.show();
+B.show();
+Element.clonePosition(this.EDITOR_LAYOUT_SHADOW_ID,this.TIME_EDITOR_LAYOUT_ID,{offsetLeft:3,offsetTop:3});
+this.isEditorVisible=true
+},hideEditor:function(){$(this.EDITOR_ID).hide();
+$(this.EDITOR_SHADOW_ID).hide();
+if(this.isTimeEditorLayoutCreated){$(this.TIME_EDITOR_LAYOUT_ID).hide()
+}if(this.isDateEditorLayoutCreated){$(this.DATE_EDITOR_LAYOUT_ID).hide()
+}this.isEditorVisible=false
+},hideTimeEditor:function(B){this.hideEditor();
+if(B&&this.selectedDate){var A=parseInt($(this.id+"TimeMinutes").value,10);
+this.selectedDate.setMinutes(A);
+var C=parseInt($(this.id+"TimeHours").value,10);
+if(this.timeType==2){if($(this.id+"TimeSign").value.toLowerCase()=="am"){if(C==12){C=0
+}}else{if(C!=12){C+=12
+}}}this.selectedDate.setHours(C);
+this.renderHF()
+}if(this.params.popup&&!this.showApplyButton&&B){this.close(true)
+}},showDateEditor:function(){if(!this.isEditorCreated){this.createEditor()
+}if(!this.isDateEditorLayoutCreated){this.createDateEditorLayout()
+}else{this.updateDateEditor()
+}$(this.DATE_EDITOR_LAYOUT_ID).show();
+var B=$(this.EDITOR_ID);
+var A=$(this.EDITOR_SHADOW_ID);
+this.setEditorPosition($(this.id),B,A);
+A.show();
+B.show();
+Element.clonePosition(this.EDITOR_LAYOUT_SHADOW_ID,this.DATE_EDITOR_LAYOUT_ID,{offsetLeft:3,offsetTop:3});
+this.isEditorVisible=true
+},hideDateEditor:function(A){this.hideEditor();
+if(A){this.changeCurrentDate(this.dateEditorYear,this.dateEditorMonth)
+}}});
+CalendarView={};
+CalendarView.getControl=function(F,B,C,D){var A=Object.extend({onclick:(C?"Richfaces.getComponent('calendar',this)."+C+"("+(D?D:"")+");":"")+"return true;",className:"rich-calendar-btn"},B);
+return new E("div",A,[new T(F)])
+};
+CalendarView.getSelectedDateControl=function(B){if(!B.selectedDate||B.showApplyButton){return""
+}var C=Richfaces.Calendar.formatDate(B.selectedDate,(B.timeType?B.datePattern:B.params.datePattern),B.params.monthLabels,B.params.monthLabelsShort);
+var A=new E("div",{"class":"rich-calendar-tool-btn","onclick":"Richfaces.getComponent('calendar',this).showSelectedDate(); return true;"},[new ET(C)]);
+return A
+};
+CalendarView.getTimeControl=function(B){if(!B.selectedDate||!B.timeType){return""
+}var C=Richfaces.Calendar.formatDate(B.selectedDate,B.timePattern,B.params.monthLabels,B.params.monthLabelsShort);
+var A=new E("div",{"class":"rich-calendar-tool-btn rich-calendar-tool-btn-hover rich-calendar-tool-btn-press","onclick":"Richfaces.getComponent('calendar',this).showTimeEditor();return true;","onmouseover":"Element.removeClassName(this, 'rich-calendar-tool-btn-press');","onmouseout":"Element.addClassName(this, 'rich-calendar-tool-btn-press');"},[new ET(C)]);
+return A
+};
+CalendarView.toolButtonAttributes={className:"rich-calendar-tool-btn",onmouseover:"this.className='rich-calendar-tool-btn rich-calendar-tool-btn-hover'",onmouseout:"this.className='rich-calendar-tool-btn'",onmousedown:"this.className='rich-calendar-tool-btn rich-calendar-tool-btn-hover rich-calendar-tool-btn-press'",onmouseup:"this.className='rich-calendar-tool-btn rich-calendar-tool-btn-hover'"};
+CalendarView.nextYearControl=CalendarView.getControl(">>",CalendarView.toolButtonAttributes,"nextYear");
+CalendarView.previousYearControl=CalendarView.getControl("<<",CalendarView.toolButtonAttributes,"prevYear");
+CalendarView.nextMonthControl=CalendarView.getControl(">",CalendarView.toolButtonAttributes,"nextMonth");
+CalendarView.previousMonthControl=CalendarView.getControl("<",CalendarView.toolButtonAttributes,"prevMonth");
+CalendarView.currentMonthControl=function(A){return CalendarView.getControl(Richfaces.Calendar.formatDate(A.calendar.getCurrentDate(),"MMMM, yyyy",A.monthLabels,A.monthLabelsShort),CalendarView.toolButtonAttributes,"showDateEditor")
+};
+CalendarView.todayControl=function(A){return(A.calendar.todayControlMode!="hidden"?CalendarView.getControl(A.controlLabels.today,CalendarView.toolButtonAttributes,"today"):"")
+};
+CalendarView.selectedDateControl=function(A){return CalendarView.getSelectedDateControl(A.calendar)
+};
+CalendarView.timeControl=function(A){return CalendarView.getTimeControl(A.calendar)
+};
+CalendarView.closeControl=function(A){return(A.calendar.params.popup?CalendarView.getControl(A.controlLabels.close,CalendarView.toolButtonAttributes,"close","false"):"")
+};
+CalendarView.applyControl=function(A){return(A.calendar.showApplyButton?CalendarView.getControl(A.controlLabels.apply,CalendarView.toolButtonAttributes,"close","true"):"")
+};
+CalendarView.cleanControl=function(A){return(A.calendar.selectedDate?CalendarView.getControl(A.controlLabels.clean,CalendarView.toolButtonAttributes,"resetSelectedDate"):"")
+};
+CalendarView.timeEditorFields=function(A){return A.calendar.timePatternHtml
+};
+CalendarView.header=[new E("table",{"border":"0","cellpadding":"0","cellspacing":"0","width":"100%"},[new E("tbody",{},[new E("tr",{},[new E("td",{"class":"rich-calendar-tool"},[new ET(function(A){return Richfaces.evalMacro("previousYearControl",A)
+})]),new E("td",{"class":"rich-calendar-tool"},[new ET(function(A){return Richfaces.evalMacro("previousMonthControl",A)
+})]),new E("td",{"class":"rich-calendar-month"},[new ET(function(A){return Richfaces.evalMacro("currentMonthControl",A)
+})]),new E("td",{"class":"rich-calendar-tool"},[new ET(function(A){return Richfaces.evalMacro("nextMonthControl",A)
+})]),new E("td",{"class":"rich-calendar-tool"},[new ET(function(A){return Richfaces.evalMacro("nextYearControl",A)
+})]),new E("td",{"class":"rich-calendar-tool rich-calendar-tool-close","style":function(A){return(this.isEmpty?"display:none;":"")
+}},[new ET(function(A){return Richfaces.evalMacro("closeControl",A)
+})])])])])];
+CalendarView.footer=[new E("table",{"border":"0","cellpadding":"0","cellspacing":"0","width":"100%"},[new E("tbody",{},[new E("tr",{},[new E("td",{"class":"rich-calendar-toolfooter","style":function(A){return(this.isEmpty?"display:none;":"")
+}},[new ET(function(A){return Richfaces.evalMacro("selectedDateControl",A)
+})]),new E("td",{"class":"rich-calendar-toolfooter","style":function(A){return(this.isEmpty?"display:none;":"")
+}},[new ET(function(A){return Richfaces.evalMacro("cleanControl",A)
+})]),new E("td",{"class":"rich-calendar-toolfooter","style":function(A){return(this.isEmpty?"display:none;":"")
+}},[new ET(function(A){return Richfaces.evalMacro("timeControl",A)
+})]),new E("td",{"width":"100%"},[]),new E("td",{"class":"rich-calendar-toolfooter","style":function(A){return(this.isEmpty?"display:none;":"")+(!A.calendar.showApplyButton?"background-image:none;":"")
+}},[new ET(function(A){return Richfaces.evalMacro("todayControl",A)
+})]),new E("td",{"class":"rich-calendar-toolfooter","style":function(A){return(this.isEmpty?"display:none;":"")+"background-image:none;"
+}},[new ET(function(A){return Richfaces.evalMacro("applyControl",A)
+})])])])])];
+CalendarView.timeEditorLayout=[new E("table",{"id":function(A){return A.calendar.TIME_EDITOR_LAYOUT_ID
+},"border":"0","cellpadding":"0","cellspacing":"0","class":"rich-calendar-time-layout"},[new E("tbody",{},[new E("tr",{},[new E("td",{"class":"rich-calendar-time-layout-fields","colspan":"2","align":"center"},[new ET(function(A){return Richfaces.evalMacro("timeEditorFields",A)
+})])]),new E("tr",{},[new E("td",{"class":"rich-calendar-time-layout-ok"},[new E("div",{"class":"rich-calendar-time-btn","style":"float:right;","onmousedown":"Element.addClassName(this, 'rich-calendar-time-btn-press');","onmouseout":"Element.removeClassName(this, 'rich-calendar-time-btn-press');","onmouseup":"Element.removeClassName(this, 'rich-calendar-time-btn-press');","onclick":function(A){return"$('"+A.calendar.id+"').component.hideTimeEditor(true)"
+}},[new ET(function(A){return A.controlLabels.ok
+})])]),new E("td",{"class":"rich-calendar-time-layout-cancel"},[new E("div",{"class":"rich-calendar-time-btn","style":"float:left;","onmousedown":"Element.addClassName(this, 'rich-calendar-time-btn-press');","onmouseout":"Element.removeClassName(this, 'rich-calendar-time-btn-press');","onmouseup":"Element.removeClassName(this, 'rich-calendar-time-btn-press');","onclick":function(A){return"$('"+A.calendar.id+"').component.hideTimeEditor(false)"
+}},[new ET(function(A){return A.controlLabels.cancel
+})])])])])])];
+CalendarView.dayList=[new ET(function(A){return A.day
+})];
+CalendarView.weekNumber=[new ET(function(A){return A.weekNumber
+})];
+CalendarView.weekDay=[new ET(function(A){return A.weekDayLabelShort
+})];
+CalendarContext=Class.create();
+Object.extend(CalendarContext.prototype,{initialize:function(A){this.calendar=A;
+this.monthLabels=A.params.monthLabels;
+this.monthLabelsShort=A.params.monthLabelsShort;
+this.weekDayLabels=A.params.weekDayLabels;
+this.weekDayLabelsShort=A.params.weekDayLabelsShort;
+this.controlLabels=A.params.labels
+},nextYearControl:CalendarView.nextYearControl,previousYearControl:CalendarView.previousYearControl,nextMonthControl:CalendarView.nextMonthControl,previousMonthControl:CalendarView.previousMonthControl,currentMonthControl:CalendarView.currentMonthControl,selectedDateControl:CalendarView.selectedDateControl,cleanControl:CalendarView.cleanControl,timeControl:CalendarView.timeControl,todayControl:CalendarView.todayControl,closeControl:CalendarView.closeControl,applyControl:CalendarView.applyControl,timeEditorFields:CalendarView.timeEditorFields,timeEditorLayout:CalendarView.timeEditorLayout})
+
+var sbjQuery=oldJQuery;
+sbjQuery.fn.SpinButton=function(A){return this.each(function(){this.spinCfg={min:A&&!isNaN(parseFloat(A.min))?Number(A.min):null,max:A&&!isNaN(parseFloat(A.max))?Number(A.max):null,step:A&&A.step?Number(A.step):1,page:A&&A.page?Number(A.page):10,upClass:A&&A.upClass?A.upClass:"up",downClass:A&&A.downClass?A.downClass:"down",reset:A&&A.reset?A.reset:this.value,delay:A&&A.delay?Number(A.delay):500,interval:A&&A.interval?Number(A.interval):100,_btn_width:20,_btn_height:12,_direction:null,_delay:null,_repeat:null,digits:A&&A.digits?Number(A.digits):1};
+this.adjustValue=function(G){var F=this.value.toLowerCase();
+if(F=="am"){this.value="PM";
+return 
+}else{if(F=="pm"){this.value="AM";
+return 
+}}F=(isNaN(this.value)?this.spinCfg.reset:Number(this.value))+Number(G);
+if(this.spinCfg.min!==null){F=(F<this.spinCfg.min?(this.spinCfg.max!=null?this.spinCfg.max:this.spinCfg.min):F)
+}if(this.spinCfg.max!==null){F=(F>this.spinCfg.max?(this.spinCfg.min!=null?this.spinCfg.min:this.spinCfg.max):F)
+}var H=String(F);
+while(H.length<this.spinCfg.digits){H="0"+H
+}this.value=H
+};
+sbjQuery(this).keydown(function(F){switch(F.keyCode){case 38:this.adjustValue(this.spinCfg.step);
+break;
+case 40:this.adjustValue(-this.spinCfg.step);
+break;
+case 33:this.adjustValue(this.spinCfg.page);
+break;
+case 34:this.adjustValue(-this.spinCfg.page);
+break
+}}).bind("mousewheel",function(F){if(F.wheelDelta>=120){this.adjustValue(this.spinCfg.step)
+}else{if(F.wheelDelta<=-120){this.adjustValue(-this.spinCfg.step)
+}}F.preventDefault()
+}).change(function(F){this.adjustValue(0)
+});
+var D=this;
+var C=$(this.id+"BtnUp");
+sbjQuery(C).mousedown(function(G){var F=function(){D.adjustValue(D.spinCfg.step)
+};
+F();
+D.spinCfg._delay=window.setTimeout(function(){F();
+D.spinCfg._repeat=window.setInterval(F,D.spinCfg.interval)
+},D.spinCfg.delay);
+D.spinCfg._repeater=true
+}).mouseup(function(F){D.spinCfg._repeater=false;
+window.clearInterval(D.spinCfg._repeat);
+window.clearTimeout(D.spinCfg._delay)
+}).dblclick(function(F){if(sbjQuery.browser.msie){D.adjustValue(D.spinCfg.step)
+}}).mouseout(function(F){if(D.spinCfg._repeater){D.spinCfg._repeater=false;
+window.clearInterval(D.spinCfg._repeat);
+window.clearTimeout(D.spinCfg._delay)
+}});
+var E=$(this.id+"BtnDown");
+sbjQuery(E).mousedown(function(G){var F=function(){D.adjustValue(-D.spinCfg.step)
+};
+F();
+D.spinCfg._delay=window.setTimeout(function(){F();
+D.spinCfg._repeat=window.setInterval(F,D.spinCfg.interval)
+},D.spinCfg.delay);
+D.spinCfg._repeater=true
+}).mouseup(function(F){D.spinCfg._repeater=false;
+window.clearInterval(D.spinCfg._repeat);
+window.clearTimeout(D.spinCfg._delay)
+}).dblclick(function(F){if(sbjQuery.browser.msie){D.adjustValue(-D.spinCfg.step)
+}}).mouseout(function(F){if(D.spinCfg._repeater){D.spinCfg._repeater=false;
+window.clearInterval(D.spinCfg._repeat);
+window.clearTimeout(D.spinCfg._delay)
+}});
+if(this.addEventListener){this.addEventListener("DOMMouseScroll",function(F){if(F.detail>0){this.adjustValue(-this.spinCfg.step)
+}else{if(F.detail<0){this.adjustValue(this.spinCfg.step)
+}}F.preventDefault()
+},false)
+}});
+function B(D,F){var E=D[F],C=document.body;
+while((D=D.offsetParent)&&(D!=C)){if(!sbjQuery.browser.msie||(D.currentStyle.position!="relative")){E+=D[F]
+}}return E
+}}
+
+if(!ClientUILib){var ClientUILib={Version:"1.0.0",Name:"ClientUILib",LibraryPath:"./",packages:[],load:function(A){if((typeof Prototype=="undefined")||(typeof Element=="undefined")||(typeof Element.Methods=="undefined")||parseFloat(Prototype.Version.split(".")[0]+"."+Prototype.Version.split(".")[1])<1.5){throw ("ClientUILib requires the Prototype JavaScript framework >= 1.5.0")
+}$A(document.getElementsByTagName("script")).findAll(function(B){return(B.src&&B.src.match(/ClientUILib\.js(\?.*)?$/))
+}).each(function(B){LibraryPath=B.src.replace(/ClientUILib\.js(\?.*)?$/,"")
+});
+if(A){ClientUILogger.create("ClientUILogger");
+this.startTime=(new Date()).getTime()
+}this.initBrowser()
+},include:function(C){if(!this.packages){this.packages=[]
+}if(!this.packages[C]){this.packages[C]=true;
+var A=/\./g;
+var B=LibraryPath+C.replace(A,"/");
+document.write('<script type="text/javascript" src="'+B+'.js"><\/script>')
+}},include2:function(D){if(!this.packages){this.packages=[]
+}if(!this.packages[D]){this.packages[D]=true;
+var A=/\./g;
+var B=LibraryPath+D.replace(A,"/");
+var C=document.createElement("script");
+C.src=B+".js";
+C.type="text/javascript";
+document.getElementsByTagName("head")[0].appendChild(C)
+}},requireClass:function(A){if(!this.packages[A]){ClientUILib.log(ClientUILogger.ERROR,"Library '"+A+"' required!!!");
+throw ("Package '"+A+"' is required!")
+}},declarePackage:function(libName){var pckg=null;
+var packages=$A(libName.split("."));
+packages.each(function(s){if(pckg==null){pckg=eval(s)
+}else{if(!pckg[s]){pckg[s]={}
+}pckg=pckg[s]
+}});
+this.packages[libName]=true
+},log:function(B,A){if(ClientUILogger.isCreated){ClientUILogger.log(B,A)
+}else{switch(B){case ClientUILogger.INFO:LOG.info(A);
+break;
+case ClientUILogger.ERROR:LOG.error(A);
+break;
+case ClientUILogger.WARNING:LOG.warn(A);
+break;
+default:LOG.a4jDebug(A)
+}}},initBrowser:function(){var A=navigator.userAgent.toLowerCase();
+this.isOpera=(A.indexOf("opera")>-1);
+this.isSafari=(A.indexOf("webkit")>-1);
+this.isIE=(window.ActiveXObject);
+this.isIE7=(A.indexOf("msie 7")>-1);
+this.isGecko=!this.isSafari&&(A.indexOf("gecko")>-1);
+if(A.indexOf("windows")!=-1||A.indexOf("win32")!=-1){this.isWindows=true
+}else{if(A.indexOf("macintosh")!=-1){this.isMac=true
+}}if(this.isIE&&!this.isIE7){try{document.execCommand("BackgroundImageCache",false,true)
+}catch(B){}}}};
+var ClientUILogger={INFO:1,WARNING:2,ERROR:3,isCreated:false,width:460,height:90,create:function(){this.logElement=$(document.createElement("div"));
+this.logElement.setStyle({position:"absolute"});
+this.logElement.setStyle({overflow:"auto"});
+this.logElement.setStyle({whiteSpace:"nowrap"});
+Event.observe(window,"load",ClientUILogger.init);
+Event.observe(window,"resize",ClientUILogger.resizeWindow);
+this.isCreated=true
+},init:function(){if(ClientUILogger.logElement){document.body.appendChild(ClientUILogger.logElement)
+}ClientUILogger.show()
+},resizeWindow:function(){ClientUILogger.show()
+},show:function(){if(this.logElement){Element.show(this.logElement);
+this.logElement.setStyle({width:this.width+"px"});
+this.logElement.setStyle({height:this.height+"px"});
+this.logElement.setStyle({top:"0px"});
+this.logElement.setStyle({left:"250px"});
+this.logElement.setStyle({zIndex:"1000"})
+}},log:function(E,C){var D=$(document.createElement("div"));
+this.logElement.appendChild(D);
+D.setStyle({width:"100%"});
+var A="bold normal bold 10pt Arial";
+var B="red";
+switch(E){case ClientUILogger.INFO:B="black";
+A="normal normal normal 10pt Arial";
+break;
+case ClientUILogger.WARNING:B="blue";
+A="italic normal normal 10pt Arial";
+break;
+case ClientUILogger.ERROR:B="red";
+A="normal normal bold 10pt Arial";
+break;
+default:C="UNRESOLVED: level="+E+", msg="+C
+}D.setStyle({font:A});
+D.setStyle({color:B});
+D.appendChild(document.createTextNode("> "+C));
+this.logElement.scrollTop=this.logElement.scrollHeight
+},getWindowWidth:function(){var A;
+if(navigator.appVersion.indexOf("MSIE")>0){A=document.body.clientWidth
+}else{A=window.innerWidth
+}return A
+},getWindowHeight:function(){var A;
+if(navigator.appVersion.indexOf("MSIE")>0){A=document.body.clientHeight
+}else{A=window.innerHeight
+}return A
+}};
+ClientUILib.load();
+var ClientUI={controls:{},layouts:{}};
+if(!ClientUILib.isIE){HTMLElement.prototype.click=function(){var A=this.ownerDocument.createEvent("MouseEvents");
+A.initMouseEvent("click",true,true,this.ownerDocument.defaultView,1,0,0,0,0,false,false,false,false,0,null);
+this.dispatchEvent(A)
+}
+}Object.extend(Event,{_domReady:function(){if(arguments.callee.done){return 
+}arguments.callee.done=true;
+if(Event._timer){clearInterval(Event._timer)
+}Event._readyCallbacks.each(function(A){A()
+});
+Event._readyCallbacks=null
+},onReady:function(B){if(!this._readyCallbacks){var A=this._domReady;
+if(A.done){return B()
+}if(document.addEventListener){document.addEventListener("DOMContentLoaded",A,false)
+}if(/WebKit/i.test(navigator.userAgent)){this._timer=setInterval(function(){if(/loaded|complete/.test(document.readyState)){A()
+}},10)
+}Event.observe(window,"load",A);
+Event._readyCallbacks=[]
+}Event._readyCallbacks.push(B)
+}})
+}var Utils={DOM:{copyAttributes:function(F,A,B){var K=A.attributes;
+var H=(B&&B.exclude)?B.exclude:[];
+for(var D=0;
+D<K.length;
+D++){var J=K[D];
+var I=J.nodeName;
+var E=J.nodeValue;
+var G=E&&E.length>0&&H.indexOf(I)<0;
+if(ClientUILib.isIE){G&=J.specified
+}if(G){var C=document.createAttribute(I);
+C.nodeValue=J.nodeValue;
+F.setAttributeNode(C)
+}}},replaceNode:function(D,E){var G=document.getElementById(D);
+var B=E.getElementById(D);
+if(G&&B){var J=G.cells;
+for(var F=0;
+F<J.length;
+F++){Utils.DOM.Event.removeListeners(J[F])
+}if(ClientUILib.isIE){var K=String();
+var C="<table><tbody>"+B.xml+"</tbody></table>";
+var H=document.createElement("DIV");
+H.innerHTML=C;
+var I=H.firstChild.firstChild.firstChild;
+G.parentNode.replaceChild(I,G);
+return I
+}else{if(ClientUILib.isGecko){var A=document;
+Utils.DOM._clearAttributes(G);
+Utils.DOM.copyAttributes(G,B);
+G.innerHTML=B.innerHTML;
+return G
+}else{B=document.importNode(B,true);
+G.parentNode.replaceChild(B,G)
+}}}else{if(!G){ClientUILib.log(ClientUILogger.ERROR,"DOM Element with id "+D+" not found for update.")
+}if(!B){ClientUILib.log(ClientUILogger.ERROR,"RESPONSE Element with id "+D+" not found for update.");
+if(G){for(var F=0;
+F<G.cells.length;
+F++){G.cells[F].innerHTML=""
+}}}}},_clearAttributes:function(B){var A=B.attributes;
+if(B.clearAttributes){B.clearAttributes()
+}else{while(B.attributes.length>0){B.removeAttributeNode(B.attributes[0])
+}}},_formatNode:function(C){var D=new StringBuilder();
+D.append("<").append(C.nodeName);
+for(var B=0;
+B<C.attributes.length;
+B++){var A=C.attributes[B];
+if(A.specified){D.append(" ").append(A.nodeName).append('="').append(A.nodeValue).append('" ')
+}}D.append("/>");
+return D.toString()
+},Event:{observe:function(B,D,C,A){if(true){if(!B._listeners){B._listeners=[]
+}B._listeners[B._listeners.length]={event:D,handler:C,useCapture:A}
+}Event.observe(B,D,C,A)
+},stopObserving:function(B,D,C,A){if(B._listeners){B._listeners=B._listeners.reject(function(E){return E.event==D&&E.handler==C&&E.useCapture==A
+})
+}Event.stopObserving(B,D,C,A)
+},removeListeners:function(C){if(C._listeners){var A=C._listeners.length;
+for(var B=0;
+B<A;
+B++){var D=C._listeners[B];
+Event.stopObserving(C,D.event,D.handler,D.useCapture)
+}C._listeners=null
+}}}},AJAX:{updateRows:function(Q,D,A,O,I,F){var C=Q;
+var L=A.getBody().templFrozen.getElement().rows.length;
+var N=C.startRow;
+var G=C.count;
+var P,E,B;
+var J=A.dataModel;
+var K=O;
+var M=0;
+var H=[];
+for(E=0;
+E<G;
+E++){P=N+E;
+if(P>=L){P-=L
+}[":f:",":n:"].unbreakableEach(function(R){var T=[K,R,P].join("");
+var S=Utils.DOM.replaceNode(T,D);
+if(I){if(!H[E]){H[E]={}
+}H[E][R]={index:P,row:S};
+M++
+}})
+}if(ClientUILib.isIE7){setTimeout(function(){var R=A.getBody();
+["fTable","nTable"].unbreakableEach(function(S){R[S].hide();
+R[S].show()
+})
+},50)
+}if(I&&M>0){setTimeout(function(){for(var R=0;
+R<G;
+R++){I.unbreakableEach(function(S){if(H[R]){if(H[R][":f:"].row){S.call(A,H[R][":f:"])
+}if(H[R][":n:"].row){S.call(A,H[R][":n:"])
+}}})
+}if(F){F.unbreakableEach(function(S){S.call(A)
+})
+}},100)
+}A.getBody()._onDataReady(C)
+}}};
+Utils.execOnLoad=function(A,C,B){if(C()){A()
+}else{window.setTimeout(function(){Utils.execOnLoad(A,C,B)
+},B)
+}};
+Utils.Condition={ElementPresent:function(A){return function(){var B=$(A);
+return B&&B.offsetHeight>0
+}
+}};
+Array.prototype.unbreakableEach=function(B){for(var A=0;
+A<this.length;
+A++){B(this[A],A)
+}};
+ClientUILib.declarePackage("ClientUI.common.utils.StringBuilder");
+StringBuilder=Class.create({initialize:function(A){this._string=null;
+this._current=0;
+this._parts=[];
+this.length=0;
+if(A!=null){this.append(A)
+}},append:function(A){this._parts.push(String(A));
+this._string=null;
+return this
+},toString:function(){if(this._string!=null){return this._string
+}var A=this._parts.join("");
+this._parts=[A];
+this._current=1;
+this.length=A.length;
+return this._string=A
+},clean:function(A){this.initialize()
+}});
+Object.extend(StringBuilder.prototype,{length:0,_current:0,_parts:[],_string:null});
+var Validators={isIEObject:function(A){return this.isObject(A)&&typeof A.constructor!="function"
+},isArray:function(A){return this.isObject(A)&&A.constructor==Array
+},isBoolean:function(A){return typeof A=="boolean"
+},getBoolean:function(B,A){if(this.isBoolean(B)){return B
+}if(B=="true"){return true
+}else{if(B=="false"){return false
+}}return A
+},isEmpty:function(B){if(this.isObject(B)){for(var A in B){return false
+}}else{if(this.isString(B)&&B.length>0){return false
+}}return !this.IsNumber(B)
+},isFunction:function(A){return typeof A=="function"
+},isNull:function(A){return typeof A=="object"&&!A
+},IsNumber:function(B){if(typeof B=="number"&&isFinite(B)){return true
+}var A=/(^-?[1-9](\d{1,2}(\,\d{3})*|\d*)|^0{1})$/;
+if(A.test(B)){return true
+}return false
+},IsFormattedNumber:function(B){var A=/^-?(\d{1,3}|\d{1,3}(\,\d{3})*|\d*)$/g;
+if(!A.test(B)){return false
+}return true
+},isObject:function(A){return(typeof A=="object"&&!!A)||this.isFunction(A)
+},isString:function(A){return typeof A=="string"
+},isUndefined:function(A){return typeof A=="undefined"
+}};
+ClientUILib.declarePackage("ClientUI.common.box.Box");
+ClientUI.common.box.Box=Class.create({initialize:function(C,B,A){this.element=$(C);
+if(!this.element){this.element=$(document.createElement("div"));
+if($(B)){$(B).appendChild(this.element)
+}else{document.body.appendChild(this.element)
+}}this.element.wrapper=this;
+if(!this.element.parentNode&&$(B)){$(B).appendChild(this.element)
+}if(!this.element.id){this.element.id="ClientUI_Box"+ClientUI_common_box_Box_idGenerator++
+}if(!A){this.element.setStyle({overflow:"hidden"});
+this.element.setStyle({whiteSpace:"nowrap"})
+}},setParent:function(A){if(this.element.parentNode){this.element.parentNode.removeChild(this.element)
+}if(A){if(A.getElement){A=A.getElement()
+}$(A).appendChild(this.element)
+}return this
+},getElement:function(){return this.element
+},getHeight:function(){if(this.getElement().tagName.toLowerCase()!="body"){var A=Element.getHeight(this.element);
+return A>0?A:(this.element.boxHeight?parseInt(this.element.boxHeight):0)
+}if(self.innerHeight){return self.innerHeight
+}else{if(document.documentElement&&document.documentElement.clientHeight){return document.documentElement.clientHeight
+}else{if(document.body){return document.body.clientHeight
+}}}},isModified:false,setHeight:function(A){this.element.boxHeight=A;
+if(Validators.IsNumber(A)){if(A<0){A=0
+}A+="px"
+}this.element.setStyle({height:A});
+isModified=true;
+return this
+},getWidth:function(){if(this.getElement().tagName.toLowerCase()!="body"){var A=Element.getWidth(this.element);
+return A>0?A:(this.element.boxWidth?parseInt(this.element.boxWidth):0)
+}if(self.innerHeight){return self.innerWidth
+}else{if(document.documentElement&&document.documentElement.clientHeight){return document.documentElement.clientWidth
+}else{if(document.body){return document.body.clientWidth
+}}}},setWidth:function(A){this.element.boxWidth=A;
+if(Validators.IsNumber(A)){if(A<0){A=0
+}A+="px"
+}this.element.setStyle({width:A});
+isModified=true;
+return this
+},moveToX:function(A){if(Validators.IsNumber(A)){A+="px"
+}this.getElement().setStyle({left:A});
+isModified=true;
+return this
+},moveToY:function(A){if(Validators.IsNumber(A)){A+="px"
+}this.getElement().setStyle({top:A});
+isModified=true;
+return this
+},moveTo:function(A,B){this.moveToX(A);
+this.moveToY(B);
+return this
+},hide:function(){Element.hide(this.element);
+isModified=true;
+return this
+},show:function(){Element.show(this.element);
+isModified=true;
+return this
+},updateLayout:function(){isModified=false;
+return this
+},getViewportWidth:function(){if(this.getElement().tagName.toLowerCase()!="body"){var A=0;
+if(this.getElement().clientWidth){A=this.getElement().clientWidth
+}else{if(this.getElement().innerWidth){A=this.getElement().innerWidth-getScrollerWidth()
+}}if(ClientUILib.isGecko){A-=this.getPadding("lr")
+}return A
+}return this.getWidth()
+},getViewportHeight:function(){if(this.getElement().tagName.toLowerCase()!="body"){var A=0;
+if(this.getElement().clientHeight){A=this.getElement().clientHeight
+}else{if(this.getElement().innerHeight){A=this.getElement().innerHeight-getScrollerWidth()
+}}if(ClientUILib.isGecko){A-=this.getPadding("tb")
+}return A
+}return this.getHeight()
+},getBorderWidth:function(A){return this.getStyles(A,this.borders)
+},getPadding:function(A){return this.getStyles(A,this.paddings)
+},getStyles:function(E,D){var F=0;
+for(var C=0,A=E.length;
+C<A;
+C++){var B=parseInt(this.getElement().getStyle(D[E.charAt(C)]),10);
+if(!isNaN(B)){F+=B
+}}return F
+},makeAbsolute:function(A){if(A){Position.absolutize(this.getElement())
+}else{this.getElement().setStyle({position:"absolute"})
+}return this
+},getX:function(){return this.getElement().offsetLeft
+},getY:function(){return this.getElement().offsetTop
+},setStyle:function(A){this.getElement().setStyle(A);
+return this
+},borders:{l:"border-left-width",r:"border-right-width",t:"border-top-width",b:"border-bottom-width"},paddings:{l:"padding-left",r:"padding-right",t:"padding-top",b:"padding-bottom"},margins:{l:"margin-left",r:"margin-right",t:"margin-top",b:"margin-bottom"}});
+if(!ClientUI_common_box_Box_idGenerator){var ClientUI_common_box_Box_idGenerator=0
+}ClientUILib.declarePackage("ClientUI.common.box.InlineBox");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUI.common.box.InlineBox=Class.create(ClientUI.common.box.Box,{initialize:function($super,C,B,A){if(!C){C=$(document.createElement("span"));
+if($(B)){$(B).appendChild(C)
+}else{document.body.appendChild(C)
+}}if(!C.id){C.id="ClientUI_InlineBox"+ClientUI_common_box_InlineBox_idGenerator++
+}$super(C,B,A);
+if(!A){this.element.setStyle({display:"block"})
+}}});
+if(!ClientUI_common_box_InlineBox_idGenerator){var ClientUI_common_box_InlineBox_idGenerator=0
+}ClientUILib.declarePackage("ClientUI.common.box.ScrollableBox");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUI.common.box.ScrollableBox=Class.create(ClientUI.common.box.Box,{initialize:function($super,B,A){$super(B,A);
+this.element.setStyle({overflow:"auto"});
+this.eventOnScroll=this.scrollContent.bindAsEventListener(this);
+Event.observe(this.element,"scroll",this.eventOnScroll)
+},scrollContent:function(A){this.updateScrollPos()
+},updateScrollPos:function(){this.timer=null;
+if(this.scrollLeft!==this.getViewportScrollX()){this.scrollLeft=this.getViewportScrollX();
+this.element.fire("grid:onhcroll",{pos:this.getViewportScrollX()})
+}if(this.scrollTop!==this.getViewportScrollY()){this.scrollTop=this.getViewportScrollY();
+this.element.fire("grid:onvcroll",{pos:this.getViewportScrollY()})
+}},updateLayout:function($super){$super()
+},getViewportScrollX:function(){var A=0;
+if(this.getElement().scrollLeft){A=this.getElement().scrollLeft
+}else{if(this.getElement().pageXOffset){A=this.getElement().pageXOffset
+}else{if(this.getElement().scrollX){A=this.getElement().scrollX
+}}}return A
+},getViewportScrollY:function(){var A=0;
+if(this.getElement().scrollTop){A=this.getElement().scrollTop
+}else{if(this.getElement().pageYOffset){A=this.getElement().pageYOffset
+}else{if(this.getElement().scrollY){A=this.getElement().scrollY
+}}}return A
+},getScrollerWidth:function(){if(this.scrollerWidth&&this.scrollerWidth>0){return this.scrollerWidth
+}var D=null;
+var C=null;
+var A=0;
+var B=0;
+D=document.createElement("div");
+D.style.position="absolute";
+D.style.top="-1000px";
+D.style.left="-1000px";
+D.style.width="100px";
+D.style.height="50px";
+D.style.overflow="hidden";
+C=document.createElement("div");
+C.style.width="100%";
+C.style.height="200px";
+D.appendChild(C);
+document.body.appendChild(D);
+A=C.offsetWidth;
+D.style.overflow="auto";
+B=C.offsetWidth;
+document.body.removeChild(document.body.lastChild);
+this.scrollerWidth=(A-B);
+return this.scrollerWidth||0
+}});
+ClientUILib.declarePackage("ClientUI.controls.grid.DataModel");
+ClientUI.controls.grid.DataModel=Class.create({initialize:function(){},getRow:function(A){return[]
+},getCount:function(){return 0
+},loadRows:function(A){this.eventDataReady.fire(A)
+},getRequestDelay:function(){return 1000
+}});
+ClientUILib.declarePackage("ClientUI.controls.grid.ArrayDataModel");
+ClientUILib.requireClass("ClientUI.controls.grid.DataModel");
+ClientUI.controls.grid.ArrayDataModel=Class.create(ClientUI.controls.grid.DataModel,{initialize:function($super,A){$super();
+this.data=$A(A||[])
+},getRow:function(A){return this.data[A]
+},getCount:function(){return this.data.length
+},getRequestDelay:function(){return 50
+}});
+ClientUILib.declarePackage("ClientUI.controls.grid.FakeArrayDataModel ");
+ClientUI.controls.grid.FakeArrayDataModel=Class.create(ClientUI.controls.grid.DataModel,{initialize:function($super,A,B,C){$super();
+this.data=[];
+this.count=A;
+this.columns=B;
+this.gridId=C;
+this.curr_options
+},getRow:function(A){if(!this.data[A]){this.data[A]=[];
+for(var B=0;
+B<7;
+B++){this.data[A][B]=B+" : "+A
+}this.data[A][6]=A%2?"value 1":"value 2"
+}return this.data[A]
+},getCount:function(){return this.count
+},getRequestDelay:function(){return 150
+},getCurrentOptions:function(){if(!this.curr_options){this.curr_options={count:grid.getBody().templFrozen.getElement().rows.length,index:0,startRow:0}
+}return this.curr_options
+},loadRows:function(B){window.loadingStartTime=(new Date()).getTime();
+var C=B;
+var A=$(this.gridId+"_state_input");
+var D=$(this.gridId+"_submit_input");
+var E=C.count+","+C.index+","+C.startRow;
+A.value=E;
+this.curr_options=B;
+D.click()
+}});
+ClientUILib.declarePackage("ClientUI.layouts.LayoutManager");
+ClientUI.layouts.LayoutManager=Class.create(ClientUI.common.box.Box,{initialize:function($super,B,A){$super(B,A);
+this.container=A;
+if(this.container){this.container=new ClientUI.common.box.Box($(this.container))
+}this.eventContainerResize=this.containerResize.bindAsEventListener(this);
+this.registerEvents()
+},registerEvents:function(){Event.observe(window,"resize",this.eventContainerResize)
+},destroy:function(){Event.stopObserving(window,"resize",this.eventContainerResize)
+},containerResize:function(A){this.updateLayout()
+},updateLayout:function($super){if(this.container){var A=this.container.getWidth();
+var B=this.container.getHeight();
+if(ClientUILib.isGecko){A-=this.container.getBorderWidth("lr")+this.container.getPadding("lr");
+B-=this.container.getBorderWidth("tb")+this.container.getPadding("tb")
+}this.setWidth(A);
+this.setHeight(B)
+}$super()
+},getContainer:function(){return this.container
+}});
+ClientUILib.declarePackage("ClientUI.common.box.Substrate");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUI.common.box.Substrate=Class.create(ClientUI.common.box.Box,{initialize:function($super,D,C,B){if(!D){var A=$(document.createElement("div"));
+A.innerHTML='<iframe id="ClientUI_Substrate'+(ClientUI_common_box_Substrate_idGenerator++)+'" src="" scrolling="no" frameborder="0" style="filter:Alpha(opacity=0);position:absolute;top:0px;left:0px;display:block"></iframe>';
+D=$(A.getElementsByTagName("iframe")[0]);
+A.removeChild(D)
+}$super(D,C,B);
+if(!B){}}});
+if(!ClientUI_common_box_Substrate_idGenerator){var ClientUI_common_box_Substrate_idGenerator=0
+}ClientUILib.declarePackage("ClientUI.layouts.VLayoutManager");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUILib.requireClass("ClientUI.layouts.LayoutManager");
+var GridLayout_Enum={HEADER:1,BODY:2,FOOTER:3};
+ClientUI.layouts.VLayoutManager=Class.create(ClientUI.layouts.LayoutManager,{initialize:function($super,C,A,B){$super(C,A);
+this.registerEvents()
+},registerEvents:function($super){$super()
+},destroy:function($super){$super()
+},addPane:function(B,A){if(!this.panels){this.panels=[]
+}this.panels[B]=A;
+this.panels[B].makeAbsolute()
+},getPane:function(A){return this.panels[A]
+},updateLayout:function($super){$super();
+var F=this.getContainer();
+if(!F){F=this
+}var B=F.getHeight();
+var E=F.getViewportWidth();
+if(ClientUILib.isGecko){E-=F.getBorderWidth("lr")+F.getPadding("lr");
+B-=F.getBorderWidth("tb")+F.getPadding("tb")
+}if(this.panels){var C=0;
+var D=0;
+if(this.panels[GridLayout_Enum.HEADER]){C=this.panels[GridLayout_Enum.HEADER].getHeight();
+this.panels[GridLayout_Enum.HEADER].moveTo(0,0);
+this.panels[GridLayout_Enum.HEADER].setWidth(E);
+this.panels[GridLayout_Enum.HEADER].updateLayout()
+}if(this.panels[GridLayout_Enum.FOOTER]){D=this.panels[GridLayout_Enum.FOOTER].getHeight();
+this.panels[GridLayout_Enum.FOOTER].moveTo(0,B-D);
+this.panels[GridLayout_Enum.FOOTER].setWidth(E);
+this.panels[GridLayout_Enum.FOOTER].updateLayout()
+}if(this.panels[GridLayout_Enum.BODY]){var A=this.panels[GridLayout_Enum.BODY];
+A.setWidth(E);
+var G=B-(C+D);
+A.setHeight(G);
+A.moveTo(0,C);
+A.updateLayout()
+}}}});
+if(!ClientUI_layouts_VLayoutManager_idGenerator){var ClientUI_layouts_VLayoutManager_idGenerator=0
+}ClientUILib.declarePackage("ClientUI.layouts.GridLayoutManager");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUILib.requireClass("ClientUI.layouts.VLayoutManager");
+ClientUILib.requireClass("ClientUI.layouts.LayoutManager");
+var GridLayout_Enum={HEADER:1,BODY:2,FOOTER:3};
+ClientUI.layouts.GridLayoutManager=Class.create(ClientUI.layouts.VLayoutManager,{initialize:function($super,C,A,B){$super(C,A)
+},updateLayout:function(){ClientUI.layouts.LayoutManager.prototype.updateLayout.call(this);
+var G=this.getContainer();
+if(G==null){G=this
+}var C=G.getHeight();
+var F=G.getViewportWidth();
+if(this.panels){var D=0;
+var E=0;
+var B=0;
+if(this.panels[GridLayout_Enum.HEADER]){D=this.panels[GridLayout_Enum.HEADER].getHeight();
+this.panels[GridLayout_Enum.HEADER].moveTo(0,0);
+this.panels[GridLayout_Enum.HEADER].setWidth(F);
+this.panels[GridLayout_Enum.HEADER].updateLayout()
+}if(this.panels[GridLayout_Enum.BODY]){var A=this.panels[GridLayout_Enum.BODY];
+A.setWidth(F);
+var H=C-D;
+A.setHeight(H);
+A.moveTo(0,D);
+A.updateLayout();
+B=A.getY()+A.contentBox.getY()+A.scrollBox.getViewportHeight()
+}if(this.panels[GridLayout_Enum.FOOTER]){E=this.panels[GridLayout_Enum.FOOTER].getHeight();
+this.panels[GridLayout_Enum.FOOTER].moveTo(0,B-E);
+this.panels[GridLayout_Enum.FOOTER].setWidth(F);
+this.panels[GridLayout_Enum.FOOTER].updateLayout()
+}}}});
+ClientUILib.declarePackage("ClientUI.controls.grid.GridHeader");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUILib.requireClass("ClientUI.common.box.InlineBox");
+ClientUI.controls.grid.GridHeader=Class.create(ClientUI.common.box.Box,{initialize:function($super,B,A){this.grid=A;
+this.gridId=this.grid.getElement().id;
+$super(B);
+this.eventSepClick=this.OnSepClick.bindAsEventListener(this);
+this.eventSepMouseDown=this.OnSepMouseDown.bindAsEventListener(this);
+this.eventSepMouseUp=this.OnSepMouseUp.bindAsEventListener(this);
+this.eventSepMouseMove=this.OnSepMouseMove.bindAsEventListener(this);
+this.eventCellMouseDown=this.OnCellMouseDown.bindAsEventListener(this);
+Event.observe(document,"mousemove",this.eventSepMouseMove,true);
+Event.observe(document,"mouseup",this.eventSepMouseUp,true);
+this.createControl(B)
+},createControl:function(A){var B="";
+if(!A){B="Invalid template specified for GridHeader.";
+ClientUILib.log(ClientUILogger.ERROR,B);
+throw (B)
+}if(!this.parseTemplate(A)){B="Unable to parse template. GridHeader requires template specified over table element with one row.";
+ClientUILib.log(ClientUILogger.ERROR,B);
+throw (B)
+}this.setHeight(this.defaultHeight);
+this.setWidth(this.defaultWidth);
+this.controlCreated=true;
+this.agjustSeparators()
+},parseTemplate:function(S){if(!S){return false
+}var D=S.childNodes;
+for(var L=0;
+L<D.length;
+L++){if(D[L].tagName&&D[L].tagName.toLowerCase()=="div"){this.container=$(D[L]);
+this.container.setStyle({"z-index":100});
+break
+}}var T=null,R=null;
+var D=this.container.childNodes;
+for(var L=0;
+L<D.length;
+L++){if(D[L].id&&D[L].id.indexOf("FrozenBox")>=0){R=D[L]
+}else{if(D[L].id&&D[L].id.indexOf("NormalBox")>=0){T=D[L]
+}}}if(!T||!R){errMsg="Unable to parse template for GridHeader. Unable to find FrozenBox or NormalBox.";
+ClientUILib.log(ClientUILogger.ERROR,errMsg);
+throw (errMsg)
+}this.contentBox=new ClientUI.common.box.Box(T);
+this.frozenContentBox=new ClientUI.common.box.Box(R);
+var H=this.contentBox.getElement().firstChild;
+while(H){if(H.tagName&&H.tagName.toLowerCase()=="table"){this.headerRow=new ClientUI.common.box.Box($(H),null,true);
+break
+}H=H.nextSibling
+}H=this.frozenContentBox.getElement().firstChild;
+while(H){if(H.tagName&&H.tagName.toLowerCase()=="table"){this.headerFrozenRow=new ClientUI.common.box.Box($(H),null,true);
+break
+}H=H.nextSibling
+}this.helpObj=new ClientUI.common.box.Box(this.frozenContentBox.getElement(),null,true);
+var F=this.headerFrozenRow.getElement().rows;
+var M=F.length?F[0].cells.length:0;
+var P=this.headerRow.getElement().rows[0].cells.length;
+var B=new Array(M+P);
+var J=0;
+var C=0;
+var N=this.eventCellMouseDown.bind(this);
+var L=0,O,K=0,A;
+var G=this.headerFrozenRow.getElement().getElementsByTagName("col");
+this.frozenCells=M?this.headerFrozenRow.getElement().rows[0].cells:[];
+var I=this.grid.options.ids;
+var E=this.frozenCells.length;
+for(L=0;
+L<E;
+L++){A=this.frozenCells[L];
+B[K]={columnId:I[L],col:G[L],width:parseInt(G[L].width),styleClass:A.className,id:A.id,align:A.align,valign:A.vAlign,title:A.title,minWidth:10,frozen:true,fixedWidth:Validators.getBoolean(A.getAttribute("fixedWidth"),false),sortable:Validators.getBoolean(A.getAttribute("sortable"),false),sorted:Validators.getBoolean(A.getAttribute("sorted"),"desc")};
+if(B[K].sortable){Event.observe(A,"click",N)
+}O=Element.getHeight(A);
+if(O>C){C=O
+}J+=B[K].width;
+B[K].object=new ClientUI.common.box.InlineBox(A,null,true);
+var Q=this._getCellElements(K);
+B[K].sep=new ClientUI.common.box.InlineBox(Q[0],null,true);
+B[K].sep.getElement().columnIndex=K;
+if(!B[K].fixedWidth){Event.observe(B[K].sep.getElement(),"click",this.eventSepClick);
+Event.observe(B[K].sep.getElement(),"mousedown",this.eventSepMouseDown)
+}else{sep.setStyle({cursor:"auto"})
+}K++
+}G=this.headerRow.getElement().getElementsByTagName("col");
+this.cells=this.headerRow.getElement().rows[0].cells;
+E=this.cells.length;
+for(L=0;
+L<E;
+L++){A=this.cells[L];
+B[K]={columnId:I[L],col:G[L],width:parseInt(G[L].width),styleClass:A.className,id:A.id,align:A.align,valign:A.vAlign,title:A.title,minWidth:10,frozen:false,fixedWidth:Validators.getBoolean(A.getAttribute("fixedWidth"),false),sortable:Validators.getBoolean(A.getAttribute("sortable"),false),sorted:null};
+if(B[K].sortable){Event.observe(A,"click",N)
+}O=Element.getHeight(A);
+if(O>C){C=O
+}J+=B[K].width;
+B[K].object=new ClientUI.common.box.InlineBox(A,null,true);
+var Q=this._getCellElements(K);
+if(Q[0]){B[K].sep=new ClientUI.common.box.InlineBox(Q[0],null,true);
+B[K].sep.getElement().columnIndex=K;
+if(!B[K].fixedWidth){Event.observe(B[K].sep.getElement(),"click",this.eventSepClick);
+Event.observe(B[K].sep.getElement(),"mousedown",this.eventSepMouseDown)
+}else{sep.setStyle({cursor:"auto"})
+}}K++
+}this._columns=B;
+this.defaultHeight=C;
+this.defaultWidth=J;
+if(ClientUILib.isGecko){this.defaultWidth-=this.getBorderWidth("lr")+this.getPadding("lr");
+this.defaultHeight-=this.getBorderWidth("tb")+this.getPadding("tb")
+}this.frozenSubstrate=new ClientUI.common.box.Box(this.gridId+":hs",this.getElement());
+this.frozenSubstrate.getElement().name=this.getElement().id+"HRFrm";
+this.frozenSubstrate.setHeight(this.headerRow.getHeight());
+return true
+},_getCellElements:function(C){var B=new Array(3);
+var A=this.grid.getElement().id;
+B[0]=$(A+":hsep_"+C);
+B[1]=$(A+":hs_"+C);
+return B
+},agjustSeparators:function(){var B=0;
+var C=this.frozenCells.length;
+var D=4;
+if(this.cells[0].offsetWidth==this.cells[0].clientWidth){D--
+}for(var A=0;
+A<C;
+B++,A++){this._columns[B].sep.moveToX(this.frozenCells[A].offsetLeft+this.frozenCells[A].offsetWidth-D)
+}var C=this.cells.length-1;
+for(var A=0;
+A<C;
+B++,A++){this._columns[B].sep.moveToX(this.cells[A].offsetLeft+this.cells[A].offsetWidth-D)
+}},updateSize:function(){var H=0,G=0;
+var D=0,E,B=0;
+var C=this._columns;
+var F=$A(this.headerFrozenRow.getElement().getElementsByTagName("col"));
+var A=$A(this.headerFrozenRow.getElement().rows[0].cells);
+A.each(function(I){if(D<C.length){C[D].width=parseInt(F[B].width);
+E=Element.getHeight(I);
+if(E>G){G=E
+}H+=C[D].width
+}D++;
+B++
+});
+B=0;
+F=$A(this.headerRow.getElement().getElementsByTagName("col"));
+A=$A(this.headerRow.getElement().rows[0].cells);
+A.each(function(I){if(D<C.length){C[D].width=parseInt(F[B].width);
+E=Element.getHeight(I);
+if(E>G){G=E
+}H+=C[D].width
+}D++;
+B++
+});
+this.defaultHeight=G;
+this.defaultWidth=H;
+this.setHeight(this.defaultHeight);
+this.setWidth(this.defaultWidth);
+this.agjustSeparators();
+this.updateHeaders()
+},updateLayout:function($super){if(!this.controlCreated||!this.grid.controlCreated){return 
+}$super();
+var B=this.getHeight();
+var A=this.grid.getColumnsTotalWidth();
+var C=this.grid.getColumnsFrozenWidth();
+this.contentBox.setWidth(Math.max(this.getWidth(),A));
+this.contentBox.setHeight(B);
+this.contentBox.moveTo(C-this.grid.getScrollOffset(),0);
+this.headerRow.setHeight(B);
+this.frozenContentBox.setWidth(C);
+this.frozenContentBox.setHeight(B);
+this.frozenContentBox.moveTo(0,0);
+this.headerFrozenRow.setHeight(B);
+this.frozenSubstrate.setWidth(C);
+this.updateHeaders()
+},getColumns:function(){return this._columns
+},OnSepMouseDown:function(A){this.dragColumnInfo={srcElement:Event.element(A),dragStarted:false,mouseDown:true,startX:Event.pointerX(A),originalX:0};
+this.dragColumnInfo.object=this.getColumns()[this.dragColumnInfo.srcElement.columnIndex].object;
+this.dragColumnInfo.sep=this.getColumns()[this.dragColumnInfo.srcElement.columnIndex].sep;
+this.dragColumnInfo.minWidth=this.getColumns()[this.dragColumnInfo.srcElement.columnIndex].minWidth;
+Event.stop(A)
+},OnSepMouseUp:function(B){if(this.dragColumnInfo&&this.dragColumnInfo.dragStarted){this.dragColumnInfo.dragStarted=false;
+this.dragColumnInfo.mouseDown=false;
+var C=Event.pointerX(B)-this.dragColumnInfo.startX;
+var A=this.dragColumnInfo.object.getWidth()+C;
+if(A<this.dragColumnInfo.minWidth){A=this.dragColumnInfo.minWidth
+}setTimeout(function(){this.grid.adjustColumnWidth(this.dragColumnInfo.srcElement.columnIndex,A)
+}.bind(this),10)
+}this._hideSplitter()
+},OnSepMouseMove:function(B){if(this.dragColumnInfo&&this.dragColumnInfo.mouseDown){if(!this.dragColumnInfo.dragStarted){this.dragColumnInfo.dragStarted=true;
+this._showSplitter(this.dragColumnInfo.srcElement.columnIndex)
+}else{var D=Event.pointerX(B)-this.dragColumnInfo.startX;
+var C=this.dragColumnInfo.object.getWidth()-this.dragColumnInfo.minWidth;
+if(D>=-C){var A=this.dragColumnInfo.originalX+D;
+this.columnSplitter.moveToX(A-6)
+}}Event.stop(B)
+}},OnSepClick:function(A){Event.stop(A)
+},_showSplitter:function(A){if(!this.columnSplitter){this._createSplitter()
+}var B=this.dragColumnInfo.sep.getX();
+if(!this.getColumns()[A].frozen){B+=this.grid.getColumnsFrozenWidth()-this.grid.getScrollOffset()
+}this.dragColumnInfo.originalX=B;
+this.columnSplitter.show();
+this.columnSplitter.setHeight(this.defaultHeight+this.grid.getBody().contentBox.getHeight());
+this.columnSplitter.moveTo(B,0)
+},_hideSplitter:function(){if(this.columnSplitter){this.columnSplitter.hide()
+}},_createSplitter:function(){this.columnSplitter=new ClientUI.common.box.Box(this.gridId+":cs",this.grid.getElement());
+this.columnSplitter.makeAbsolute();
+this.columnSplitter.setWidth(10)
+},adjustScrollPosition:function(A){this.contentBox.moveToX(this.grid.getColumnsFrozenWidth()-A)
+},OnCellMouseDown:function(D){var C=Event.element(D);
+while(C&&!Element.hasClassName(C,"dr-sdt-hc")){C=C.parentNode
+}if(C){var B=parseInt(C.getAttribute("columnindex"));
+if(B>=0){var E=this.grid.getBody().templFrozen.getElement().rows;
+var A=E&&E.length>0?this.grid.getBody()._getRowIndex(E[0].id):0;
+this.grid.element.fire("grid:onsort",{column:B,startRow:A,index:this.grid.getBody().currRange.start});
+Event.stop(D)
+}}},updateHeaders:function(){var F=this.getColumns();
+for(var B=0;
+B<F.length;
+B++){var A=F[B];
+var G=A.object.getElement().firstChild;
+var C=this._getCellElements(B)[1];
+if(C){var E=G.clientWidth-C.getWidth();
+var D=(G.clientHeight-C.getHeight())/2;
+E=Math.floor(E);
+D=Math.floor(D);
+C.setStyle({left:E+"px",top:D+"px",visibility:"inherit"})
+}}},adjustColumnWidth:function(B,A){this._columns[B].col.width=A>0?A:1;
+if(A<=0){this.getColumns()[B].sep.hide()
+}this._columns[B].width=A
+},setFakeColumnWidth:function(){this._columns.last().col.width=1;
+var A=this.grid.getElement().offsetWidth-this.headerRow.getElement().offsetWidth;
+if(A<1){A=1
+}this._columns.last().col.width=A
+},hideColumn:function(B,F){var D=this._columns.splice(B,1)[0];
+var A=$(this.grid.getElement().id+"_hc");
+A.value=A.value+D.columnId+",";
+D.col.parentNode.removeChild(D.col);
+D.bodyCol.parentNode.removeChild(D.bodyCol);
+D.footerCol.parentNode.removeChild(D.footerCol);
+var E;
+if(F){E=this.headerFrozenRow.getElement().rows
+}else{E=this.headerRow.getElement().rows
+}for(var C=0;
+C<E.length;
+C++){E[C].removeChild(E[C].cells[B])
+}}});
+Object.extend(ClientUI.controls.grid.GridHeader.prototype,{sepStyleClass:"dr-sdt-hsep",_columns:[]});
+ClientUILib.declarePackage("ClientUI.controls.grid.DataCash");
+ClientUI.controls.grid.DataCash=Class.create({initialize:function(A){var C=parseInt(A/this.PKG_SIZE+1);
+this.cash=new Array(C);
+for(var B=0;
+B<C;
+B++){this.cash[B]=new Array(this.PKG_SIZE)
+}},getRow:function(B){var C=parseInt(B/this.PKG_SIZE),A=B%this.PKG_SIZE;
+return this.cash[C][A]
+},setRow:function(B,D){var C=parseInt(B/this.PKG_SIZE),A=B%this.PKG_SIZE;
+this.cash[C][A]=D
+}});
+Object.extend(ClientUI.controls.grid.DataCash.prototype,{PKG_SIZE:20});
+ClientUILib.declarePackage("ClientUI.controls.grid.GridBody");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUI.controls.grid.GridBody=Class.create(ClientUI.common.box.Box,{initialize:function($super,B,A){this.grid=A;
+this.gridId=A.getElement().id;
+$super(B);
+this._eventOnHScroll=this._onContentHScroll.bindAsEventListener(this);
+this._eventOnVScroll=this._onContentVScroll.bindAsEventListener(this);
+this.createControl(B);
+this.registerEvents()
+},registerEvents:function(){Event.observe(this.scrollBox.element,"grid:onhcroll",this._eventOnHScroll);
+Event.observe(this.scrollBox.element,"grid:onvcroll",this._eventOnVScroll)
+},destroy:function(){Event.stopObserving(this.scrollBox.element,"grid:onhcroll",this._eventOnHScroll);
+Event.stopObserving(this.scrollBox.element,"grid:onvcroll",this._eventOnVScroll)
+},_onContentHScroll:function(A){this.grid.adjustScrollPosition(A.memo.pos)
+},_onDataReady:function(A){window.loadingUpdateTime=(new Date()).getTime();
+this.invalidate(A);
+window.loadingInvalidateTime=(new Date()).getTime()
+},_onContentVScroll:function(A){this.helpObject1.moveToY(this.sizeBox.getHeight()+this.defaultRowHeight+5);
+this.helpObject2.moveToY(this.sizeBox.getHeight()+this.defaultRowHeight+5);
+this.setScrollPos(A.memo.pos);
+this.adjustDataPosition(A.memo.pos)
+},createControl:function(D){this.scrollInput=$(this.gridId+":si");
+var E=D.childNodes;
+for(var B=0;
+B<E.length;
+B++){if(E[B].id==this.gridId+":bc"){this.container=new ClientUI.common.box.Box(E[B],null,true);
+this.container.makeAbsolute();
+this.container.setStyle({"z-index":20});
+if(!ClientUILib.isIE){this.container.setStyle({overflow:"hidden"})
+}break
+}}Event.observe(this.container.getElement(),"keypress",this.synchronizeScroll.bindAsEventListener(this));
+this.scrollBox=new ClientUI.common.box.ScrollableBox(this.gridId+":scb",this.getElement());
+this.scrollBox.setWidth(this.getWidth());
+this.scrollBox.setHeight(this.getHeight());
+this.sizeBox=new ClientUI.common.box.Box(this.gridId+":sb",this.scrollBox.getElement());
+var G=null,F=null;
+var E=this.container.getElement().childNodes;
+for(var B=0;
+B<E.length;
+B++){if(E[B].id&&E[B].id.indexOf("FrozenBox")>=0){F=E[B]
+}else{if(E[B].id&&E[B].id.indexOf("NormalBox")>=0){G=E[B]
+}}}if(!G||!F){errMsg="Unable to parse template for GridBody. Unable to find FrozenBox or NormalBox.";
+ClientUILib.log(ClientUILogger.ERROR,errMsg);
+throw (errMsg)
+}this.contentBox=new ClientUI.common.box.Box(G);
+Event.observe(this.contentBox.getElement(),"keypress",this.synchronizeScroll.bindAsEventListener(this));
+this.frozenContentBox=new ClientUI.common.box.Box(F);
+this.helpObject1=new ClientUI.common.box.Box(this.gridId+":nho",this.contentBox.getElement());
+this.helpObject2=new ClientUI.common.box.Box(this.gridId+":fho",this.frozenContentBox.getElement());
+var C=this.frozenContentBox.getElement().firstChild;
+while(C){if(C.tagName&&C.tagName.toLowerCase()=="table"){this.templFrozen=new ClientUI.common.box.Box($(C),null,true);
+this.templFrozen.makeAbsolute();
+break
+}C=C.nextSibling
+}C=this.contentBox.getElement().firstChild;
+while(C){if(C.tagName&&C.tagName.toLowerCase()=="table"){this.templNormal=new ClientUI.common.box.Box($(C),null,true);
+this.templNormal.makeAbsolute();
+break
+}C=C.nextSibling
+}this.parseTemplate(this.templFrozen.getElement(),this.templNormal.getElement());
+var A=this.grid.getElement().id;
+this.fTable=$(A+":f");
+this.nTable=$(A+":n");
+this.controlCreated=true;
+this.sizeBox.setHeight(this.templNormal.getElement().offsetHeight)
+},parseTemplate:function(D,C){var A=false;
+if(C&&C.rows&&C.rows.length!=0){var F=this.grid.getHeader().getColumns();
+var E=0,B=0;
+var G=this.templFrozen.getElement().getElementsByTagName("col");
+for(E=0;
+E<G.length;
+E++){F[B].bodyCol=$(G[E]);
+B++
+}G=this.templNormal.getElement().getElementsByTagName("col");
+for(E=0;
+E<G.length;
+E++){F[B].bodyCol=$(G[E]);
+B++
+}this.rowsCount=Math.min(C.rows.length,this.grid.dataModel.getCount());
+this.helpObj=new ClientUI.common.box.Box(D,null,true);
+this.countToLoad=0;
+this.startRow=0;
+this.startIndex=0;
+A=true
+}this.currRange=$R(0,this.rowsCount);
+return A
+},setScrollPos:function(A){this.contentBox.getElement().scrollTop=A;
+this.frozenContentBox.getElement().scrollTop=A;
+if(ClientUILib.isIE&&!ClientUILib.isIE7){this.contentBox.getElement().scrollTop=A;
+this.frozenContentBox.getElement().scrollTop=A
+}},updateSize:function(){var A=this._calcDefaultRowHeight();
+if(isFinite(A)){this.defaultRowHeight=A
+}var B=this.templNormal.getElement().rows[0];
+if(B){this.defaultRowHeight=Element.getHeight(B.cells[0])
+}},updateLayout:function($super){if(!this.controlCreated||!this.grid.controlCreated){return 
+}$super();
+if(!this.scrollBox||!this.contentBox||!this.sizeBox){return 
+}var B=this.grid.getColumnsTotalWidth();
+this.scrollBox.moveTo(0,0);
+this.scrollBox.setWidth(this.getWidth());
+this.scrollBox.setHeight(this.getHeight());
+var F=this.grid.getScrollOffset();
+var A=this.scrollBox.getHeight();
+var D=this.grid.getFooter()?this.grid.getFooter().getHeight():0;
+if(D>A){D=0
+}var C=this.grid.getColumnsFrozenWidth();
+this.frozenContentBox.moveTo(0,0);
+this.contentBox.moveTo(C,0);
+this.sizeBox.moveTo(0,0);
+this.sizeBox.setWidth(B);
+this.scrollBox.setWidth(this.getWidth()+1);
+this.scrollBox.setHeight(this.getHeight()+1);
+this.scrollBox.setWidth(this.getWidth());
+this.scrollBox.setHeight(this.getHeight());
+A=this.scrollBox.getElement().clientHeight;
+this.contentBox.setHeight(A-D);
+this.frozenContentBox.setWidth(C);
+this.frozenContentBox.setHeight(A-D);
+this.container.setHeight(A-D);
+this.defaultRowHeight=this._calcDefaultRowHeight();
+this.scrollBox.hide();
+this.sizeBox.setHeight(this.defaultRowHeight*this.grid.dataModel.getCount()+D);
+this.helpObject1.moveToY(this.sizeBox.getHeight()+this.defaultRowHeight+5);
+this.helpObject2.moveToY(this.sizeBox.getHeight()+this.defaultRowHeight+5);
+this.dataVisible=parseInt(this.contentBox.getHeight()/this.defaultRowHeight,10)+1;
+this.dataVisible=Math.min(this.dataVisible,this.rowsCount);
+if(A>0){this.adjustDataPosition(this.currentPos)
+}this.scrollBox.show();
+var E=this.scrollBox.getViewportWidth();
+this.container.setWidth(E);
+if(ClientUILib.isIE){this.contentBox.setWidth(E-C)
+}else{this.contentBox.setWidth(Math.max(this.getWidth(),B))
+}var G=Math.min(B-E,F);
+this.grid.adjustScrollPosition(G)
+},adjustScrollPosition:function(A){this.templNormal.moveToX(-A)
+},getScrollYPosition:function(){return this.contentBox.getElement().scrollTop
+},adjustDataPosition:function(G){if(this.currentPos==G){return 
+}this.processedPos=G;
+var C=(this.currentPos<=G)?true:false;
+var D=parseInt(G/this.defaultRowHeight)-1;
+if(D<0){D=0
+}var F=Math.max(D-(C?1:(this.rowsCount-this.dataVisible-1)),0);
+var E=Math.min(D+(C?this.rowsCount-1:this.dataVisible+1),this.grid.dataModel.getCount());
+if(F==0){E=this.rowsCount
+}else{if(E==this.grid.dataModel.getCount()){F=E-this.rowsCount;
+if(F<0){F=0
+}}}var B=$R(F,E);
+if(this.currRange.start==F&&this.currRange.end==E){return 
+}if(F>=E){ClientUILib.log(ClientUILogger.WARNING,"!!! GridBody: adjustDataPosition. Pos: "+G+", From:"+F+", To:"+E);
+return 
+}var A=this._getPendingTask();
+if(E-F>0){A.timer=null;
+A.from=F;
+A.to=E;
+A.first=D;
+A.pos=G;
+this._setPendingTask(A)
+}},_getPendingTask:function(){if(!this.pendingTask){this.pendingTask={timer:null,rowsToLoad:[],rowsToLoadIdx:[],from:0,to:0,first:0,pos:0}
+}return this.pendingTask
+},_setPendingTask:function(A){clearTimeout(this.pendingTask.timer);
+this.pendingTask.timer=null;
+this.pendingTask=A;
+A.timer=setTimeout(function(){this.startLoadData()
+}.bind(this),this.grid.dataModel.getRequestDelay())
+},adjustColumnWidth:function(B,A){var C=this.grid.getHeader().getColumns()[B].bodyCol;
+if(C){C.width=A>0?A:1
+}},setFakeColumnWidth:function(){var A=this.grid.getHeader().getColumns();
+var C=A.last().bodyCol;
+if(C){C.width=1
+}var B=this.container.getElement().offsetWidth-this.fTable.offsetWidth-this.nTable.offsetWidth;
+if(B<1){B=1
+}if(C){C.width=B
+}},startLoadData:function(){if(this.updateStarted){this._setPendingTask(this._getPendingTask());
+return 
+}this.updateStarted=true;
+var D=this._getPendingTask();
+var H=$R(D.from,D.to);
+var A=5;
+var M=0;
+var K=0;
+var J=0;
+this.scrollInput.value=D.pos+","+H.start+","+H.end;
+if(this.currRange.end<H.start||this.currRange.start>H.end){A=0
+}if(A===0){K=this._getRowIndex(this.templFrozen.getElement().rows[0].id);
+M=H.start;
+J=H.end-H.start
+}else{var F,P,L,G;
+J=0;
+var E=this.templFrozen.getElement();
+var N=this.templNormal.getElement();
+if(H.start>this.currRange.start&&H.start<this.currRange.end){A=1;
+J=H.start-this.currRange.start;
+if(J>0){K=this._getRowIndex(E.rows[0].id);
+M=this.currRange.end
+}}else{if(H.start==this.currRange.start){A=3;
+J=H.end-this.currRange.end;
+if(J>0){M=this.currRange.end;
+var I=this.rowsCount-J;
+K=this._getRowIndex(E.rows[I].id)
+}}else{A=2;
+J=this.currRange.start-H.start;
+if(J>0){M=H.start;
+var I=this.rowsCount-J;
+K=this._getRowIndex(E.rows[I].id)
+}}}}var C=true;
+if(M>(D.first+this.dataVisible)||(M+J)<D.first){C=false
+}if(J>0&&C){this.updateStarted=true;
+ClientUILib.log(ClientUILogger.WARNING,"Start loading: index: "+M+", and startRow: "+K+", and count: "+J);
+this.currRange=H;
+this.currentPos=D.pos;
+if(this.grid.options.hideWhenScrolling){this.container.hide()
+}var O={index:M,count:J,startRow:K,switchType:A};
+var B={index:O.index,count:O.count,startRow:O.startRow,switchType:O.switchType};
+if(O.count>0){setTimeout(function(){this.updateInterval=screen.updateInterval;
+screen.updateInterval=1000;
+this.grid.dataModel.loadRows(O)
+}.bind(this),10)
+}}else{this.updateStarted=false
+}},forceReRender:function(){if(ClientUILib.isIE&&!ClientUILib.isIE7){var C=this.templFrozen.getElement();
+var B=this.templNormal.getElement();
+var A=C.insertRow();
+C.deleteRow(A.rowIndex);
+A=B.insertRow();
+B.deleteRow(A.rowIndex)
+}},rearrangeRows:function(B,M,H){var L=this.templFrozen.getElement();
+var Q=this.templNormal.getElement();
+if(B.switchType===0){var O=this.defaultRowHeight*B.index;
+var R=this.contentBox.getElement().scrollTop;
+if(H){this._showContainer()
+}this.templFrozen.moveToY(O);
+this.templNormal.moveToY(O);
+this.forceReRender()
+}else{if(B.switchType===1||B.switchType===2){var D=L.rows.length;
+var I=new Array(D),F=new Array(D);
+var N=0,P;
+var E=B.index;
+if(B.switchType===1){for(P=B.count;
+P<this.rowsCount;
+P++){I[N]=L.rows[P];
+F[N]=Q.rows[P];
+N++
+}for(P=0;
+P<B.count;
+P++){I[N]=L.rows[P];
+F[N]=Q.rows[P];
+N++
+}}else{for(P=this.rowsCount-B.count;
+P<this.rowsCount;
+P++){I[N]=L.rows[P];
+F[N]=Q.rows[P];
+N++
+}for(P=0;
+P<this.rowsCount-B.count;
+P++){I[N]=L.rows[P];
+F[N]=Q.rows[P];
+N++
+}}var A=navigator.product=="Gecko";
+var J=L.tBodies[0];
+var G=Q.tBodies[0];
+var K=J.nextSibling;
+var C=G.nextSibling;
+if(A){fp=J.parentNode;
+fp.removeChild(J);
+np=G.parentNode;
+np.removeChild(G)
+}for(P=0;
+P<D;
+P++){J.appendChild(I[P]);
+G.appendChild(F[P])
+}if(A){fp.insertBefore(J,K);
+np.insertBefore(G,C)
+}var O=(B.switchType==1)?this.currRange.start*this.defaultRowHeight:B.index*this.defaultRowHeight;
+if(H){this._showContainer()
+}this.templFrozen.moveToY(O);
+this.templNormal.moveToY(O)
+}else{var O=this.currRange.start*this.defaultRowHeight;
+if(H){this._showContainer()
+}this.templFrozen.moveToY(O);
+this.templNormal.moveToY(O)
+}}},_showContainer:function(){this.container.show();
+if(ClientUILib.isIE){this.setScrollPos(this.currentPos)
+}},invalidate:function(A){screen.updateInterval=this.updateInterval;
+this.rearrangeRows(A,true,true);
+this.container.show();
+this.updateStarted=false
+},processCashedValues:function(I){return I;
+var B={switchType:I.switchType};
+var G=this.getCash();
+var E=I.count;
+var F=I.index;
+var H=I.startRow;
+var D=0;
+var A;
+while(D<E&&(A=G.getRow(F+D))!=null){D++
+}if(D>0){B.count=D;
+B.index=F;
+B.startRow=H;
+this._restoreFromCash(B);
+I.count-=D;
+I.index=F+D;
+I.startRow=H+D;
+if(I.startRow>=this.rowsCount){I.startRow-=this.rowsCount
+}}var C=0;
+while(D<E&&!(A=G.getRow(F+D))){D++;
+C++
+}if(D<E){B.count=I.count-C;
+B.index=F+D;
+B.startRow=H+D;
+if(B.startRow>=this.rowsCount){B.startRow-=this.rowsCount
+}this._restoreFromCash(B);
+I.count=C;
+I.index=F+(D-C);
+I.startRow=H+(D-C);
+if(I.startRow>=this.rowsCount){I.startRow-=this.rowsCount
+}}return I
+},getCellText:function(F,D){var E=this.templFrozen.getElement().rows[F].cells;
+var C=E.length;
+var B=D;
+if(B>=C){B-=C;
+E=this.templNormal.getElement().rows[F].cells
+}var A=document.getElementsByClassName("dr-sdt-bcbody",E[B]);
+return(A&&A.length&&A.length>0)?A[0].innerHTML:""
+},ensureVisible:function(A){if(A>=0&&A<this.grid.dataModel.getCount()){var B=parseInt(this.contentBox.getHeight()/this.defaultRowHeight,10)+1;
+if(this.grid.dataModel.getCount()>B){var C=A*this.defaultRowHeight;
+this.scrollBox.getElement().scrollTop=C;
+this.currentPos=0;
+this._onContentVScroll({memo:{pos:C}})
+}}},reloadData:function(){this.currentPos=-(this.rowsCount*this.defaultRowHeight);
+this.scrollBox.getElement().scrollTop=0;
+this.currRange.start=-this.rowsCount;
+this.currRange.end=-1;
+this._onContentVScroll({memo:{pos:0}})
+},_getRowIndex:function(A){return Number(A.split(this.grid.getElement().id)[1].split(":")[2])
+},hideColumn:function(A,D){var C;
+if(D){C=this.templFrozen.getElement().rows
+}else{C=this.templNormal.getElement().rows
+}for(var B=0;
+B<C.length;
+B++){C[B].removeChild(C[B].cells[A])
+}},showRow:function(C){if(C=="up"){this.scrollBox.getElement().scrollTop=this.scrollBox.getElement().scrollTop-this.fTable.rows[1].offsetTop
+}else{if(C=="down"){this.scrollBox.getElement().scrollTop=this.scrollBox.getElement().scrollTop+this.fTable.rows[1].offsetTop
+}else{var B=$(this.gridId+":n:"+C);
+var A=this.fTable.offsetTop+B.offsetTop;
+if(this.frozenContentBox.getElement().scrollTop>A){this.scrollBox.getElement().scrollTop=A
+}else{A+=B.offsetHeight;
+A-=this.frozenContentBox.getElement().clientHeight;
+if(this.frozenContentBox.getElement().scrollTop<A){this.scrollBox.getElement().scrollTop=A
+}}}}this.scrollBox.updateScrollPos()
+},_calcDefaultRowHeight:function(){var A=this.templNormal.getElement();
+var B=A.rows.length;
+if(B){return Math.ceil(A.offsetHeight/B)
+}else{return 16
+}},restoreScrollState:function(){this.scrollInput=$(this.gridId+":si");
+var C=this.scrollInput.value;
+if(C!=""){var A=C.split(",");
+this.currentPos=A[0];
+this.scrollBox.getElement().scrollTop=A[0];
+this.currRange.start=A[1];
+this.currRange.end=A[2];
+var B=this.currRange.start*this.defaultRowHeight;
+this.templFrozen.moveToY(B);
+this.templNormal.moveToY(B)
+}},synchronizeScroll:function(A){if(Event.KEY_TAB==A.keyCode||Event.KEY_TAB==A.charCode){Event.stop(A)
+}}});
+Object.extend(ClientUI.controls.grid.GridBody.prototype,{dataVisible:50,dataDelta:5,currentPos:0});
+ClientUILib.declarePackage("ClientUI.controls.grid.GridFooter");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUI.controls.grid.GridFooter=Class.create(ClientUI.common.box.Box,{initialize:function($super,B,A){this.grid=A;
+$super(B);
+this.createControl(B)
+},createControl:function(A){var B="";
+if(!A){B="Invalid template specified for GridFooter.";
+ClientUILib.log(ClientUILogger.ERROR,B);
+throw (B)
+}if(!this.parseTemplate(A)){B="Unable to parse template. GridFooter requires template specified over table element with one row.";
+ClientUILib.log(ClientUILogger.ERROR,B);
+throw (B)
+}this.setHeight(this.defaultHeight);
+this.setWidth(this.defaultWidth);
+this.controlCreated=true
+},parseTemplate:function(D){if(!D){return false
+}var E=D.childNodes;
+for(var B=0;
+B<E.length;
+B++){if(E[B].tagName&&E[B].tagName.toLowerCase()=="div"){this.container=new ClientUI.common.box.Box(E[B],null,true);
+this.container.setStyle({"z-index":100});
+break
+}}var H=null,G=null;
+var E=this.container.getElement().childNodes;
+for(var B=0;
+B<E.length;
+B++){if(E[B].id&&E[B].id.indexOf("FrozenBox")>=0){G=E[B]
+}else{if(E[B].id&&E[B].id.indexOf("NormalBox")>=0){H=E[B]
+}}}if(!H||!G){errMsg="Unable to parse template for GridFooter. Unable to find FrozenBox or NormalBox.";
+ClientUILib.log(ClientUILogger.ERROR,errMsg);
+throw (errMsg)
+}this.contentBox=new ClientUI.common.box.Box(H);
+this.frozenContentBox=new ClientUI.common.box.Box(G);
+var C=this.contentBox.getElement().firstChild;
+while(C){if(C.tagName&&C.tagName.toLowerCase()=="table"){this.headerRow=new ClientUI.common.box.Box($(C),null,true);
+break
+}C=C.nextSibling
+}C=this.frozenContentBox.getElement().firstChild;
+while(C){if(C.tagName&&C.tagName.toLowerCase()=="table"){this.headerFrozenRow=new ClientUI.common.box.Box($(C),null,true);
+break
+}C=C.nextSibling
+}var A=this.grid.getHeader().getColumns();
+var B=0;
+var F=$A(this.headerFrozenRow.getElement().getElementsByTagName("col"));
+F.each(function(I){A[B].footerCol=$(I);
+B++
+});
+F=$A(this.headerRow.getElement().getElementsByTagName("col"));
+F.each(function(I){A[B].footerCol=$(I);
+B++
+});
+this.helpObj=new ClientUI.common.box.Box(this.frozenContentBox.getElement(),null,true);
+this.defaultWidth=this.grid.getHeader().defaultWidth;
+this.defaultHeight=Element.getHeight(this.headerRow.getElement().rows[0].cells[0]);
+if(ClientUILib.isGecko){this.defaultHeight-=this.getBorderWidth("tb")+this.getPadding("tb")
+}this.frozenSubstrate=new ClientUI.common.box.Box(this.grid.getElement().id+":fs",this.getElement());
+this.frozenSubstrate.getElement().name=this.getElement().id+"FRFrm";
+this.frozenSubstrate.setHeight(this.defaultHeight);
+return true
+},updateSize:function(){this.defaultWidth=this.grid.getHeader().defaultWidth;
+this.defaultHeight=Element.getHeight(this.headerRow.getElement().rows[0].cells[0]);
+if(ClientUILib.isGecko){this.defaultHeight-=this.getBorderWidth("tb")+this.getPadding("tb")
+}this.setHeight(this.defaultHeight);
+this.setWidth(this.defaultWidth)
+},updateLayout:function($super){if(!this.controlCreated||!this.grid.controlCreated){return 
+}$super();
+var B=this.getHeight();
+var A=this.grid.getColumnsTotalWidth();
+var C=this.grid.getColumnsFrozenWidth();
+this.contentBox.setWidth(Math.max(this.getWidth(),A));
+this.contentBox.setHeight(B);
+this.contentBox.moveTo(C-this.grid.getScrollOffset(),0);
+this.frozenContentBox.setWidth(C);
+this.frozenContentBox.setHeight(B);
+this.frozenContentBox.moveTo(0,0);
+var C=this.grid.getBody().frozenContentBox.getWidth();
+var D=this.grid.getBody().scrollBox.getViewportWidth();
+this.container.setWidth(D);
+this.setWidth(D);
+this.frozenSubstrate.setWidth(C)
+},adjustScrollPosition:function(A){this.contentBox.moveToX(this.grid.getColumnsFrozenWidth()-A)
+},adjustColumnWidth:function(C,B){var A=this.grid.getHeader().getColumns();
+A[C].footerCol.width=B>0?B:1
+},setFakeColumnWidth:function(){var A=this.grid.getHeader().getColumns();
+A.last().footerCol.width=1;
+var B=this.grid.getElement().offsetWidth-this.headerRow.getElement().offsetWidth;
+if(B<1){B=1
+}A.last().footerCol.width=B
+},hideColumn:function(A,D){var C;
+if(D){C=this.headerFrozenRow.getElement().rows
+}else{C=this.headerRow.getElement().rows
+}for(var B=0;
+B<C.length;
+B++){C[B].removeChild(C[B].cells[A])
+}}});
+ClientUILib.declarePackage("ClientUI.controls.grid.Grid");
+ClientUILib.requireClass("ClientUI.common.box.Box");
+ClientUILib.requireClass("ClientUI.controls.grid.GridHeader");
+ClientUILib.requireClass("ClientUI.controls.grid.GridBody");
+ClientUILib.requireClass("ClientUI.controls.grid.GridFooter");
+ClientUI.controls.grid.Grid=Class.create(ClientUI.common.box.Box,{initialize:function($super,C,B,A){$super(C);
+this.dataModel=B;
+this.templates=$A(A);
+this.createControl()
+},createControl:function(){var C=this;
+this.layout=new ClientUI.layouts.GridLayoutManager(this.getElement().id+":c",null);
+var A,D;
+for(var B=0;
+B<this.templates.length;
+B++){D=this.templates[B];
+switch(D.pane){case GridLayout_Enum.HEADER:A=new ClientUI.controls.grid.GridHeader($(D.ref),C);
+this.layout.addPane(GridLayout_Enum.HEADER,A);
+break;
+case GridLayout_Enum.BODY:A=new ClientUI.controls.grid.GridBody($(D.ref),C);
+this.layout.addPane(GridLayout_Enum.BODY,A);
+break;
+case GridLayout_Enum.FOOTER:A=new ClientUI.controls.grid.GridFooter($(D.ref),C);
+this.layout.addPane(GridLayout_Enum.FOOTER,A);
+break
+}}this.currentScrollPos=0;
+this.controlCreated=true;
+var C=this;
+Utils.execOnLoad(function(){C.updateLayout()
+},Utils.Condition.ElementPresent(C.client_id),100)
+},updateLayout:function($super){if(!this.controlCreated||this.getHeight()==0){return 
+}$super();
+var A=this.getHeader();
+if(A.getHeight()==0){A.updateSize();
+this.getBody().updateSize();
+if(this.getFooter()){this.getFooter().updateSize()
+}}if(this.layout){this.layout.updateLayout()
+}A.updateLayout();
+A.setFakeColumnWidth();
+this.getBody().setFakeColumnWidth();
+if(this.getFooter()){this.getFooter().setFakeColumnWidth()
+}},getHeader:function(){return this.layout.getPane(GridLayout_Enum.HEADER)
+},getFooter:function(){return this.layout.getPane(GridLayout_Enum.FOOTER)
+},getBody:function(){return this.layout.getPane(GridLayout_Enum.BODY)
+},adjustColumnWidth:function(A,B){this.getHeader().adjustColumnWidth(A,B);
+this.getBody().adjustColumnWidth(A,B);
+if(this.getFooter()){this.getFooter().adjustColumnWidth(A,B)
+}this.updateLayout();
+this.getHeader().agjustSeparators();
+this.element.fire("grid:onresizecolumn",{index:A,width:B})
+},adjustScrollPosition:function(A){if(A<0){A=0
+}this.currentScrollPos=A;
+this.getHeader().adjustScrollPosition(A);
+this.getBody().adjustScrollPosition(A);
+if(this.getFooter()){this.getFooter().adjustScrollPosition(A)
+}},getScrollOffset:function(){return this.currentScrollPos?this.currentScrollPos:0
+},setColumnMinWidth:function(A,B){if(A<0||A>=this.getHeader().getColumns().length){return false
+}this.getHeader().getColumns()[A].minWidth=B;
+return true
+},getColumnsTotalWidth:function(){var A=0;
+var C=this.getHeader().getColumns();
+for(var B=0;
+B<C.length;
+B++){A+=C[B].width
+}return A
+},getColumnsFrozenWidth:function(){var A=0;
+var C=this.getHeader().getColumns();
+var B=0;
+while(B<C.length&&C[B].frozen){A+=C[B++].width
+}return A
+},invalidate:function(A){this.getBody().invalidate(A)
+},adjustColumnsWidth:function(){var B=this.getHeader().getColumns();
+for(var A=0;
+A<B.length;
+A++){this.adjustColumnWidth(A,B[A].width)
+}},quickFind:function(B,J,I){var A=I||0;
+var K=".*"+J+".*";
+var G=new RegExp(K,"i");
+var H=-1;
+var F=this.getBody();
+var E=F.rowsCount;
+for(var C=A;
+C<E;
+C++){var D=F.getCellText(C,B);
+D=D.replace(/(<[^<]*>)/g,"");
+if(D.search(G)!=-1){H=C;
+break
+}}return H
+},ensureVisible:function(A){this.getBody().ensureVisible(A)
+},getDataIndex:function(B){var A=this.getBody();
+return A.currRange.start+B
+},getRowIndex:function(B){var A=this.getBody();
+return(B>=A.currRange.start&&B<A.currRange.start+A.rowsCount)?B-A.currRange.start:-1
+},hideColumn:function(A){this.adjustColumnWidth(A,0)
+},reloadData:function(){this.getBody().reloadData()
+},updateRowCount:function(B){var A=parseInt(B);
+if(A>=0){this.dataModel.count=A;
+this.updateLayout()
+}}});
+ClientUI.controls.grid.Selection=Class.create({initialize:function(){this.ranges=[]
+},addId:function(B){B=parseInt(B);
+if(this.isSelectedId(B)){return 
+}var A=0;
+while(A<this.ranges.length&&B>=this.ranges[A++].indexes[1]){}A--;
+if(this.ranges[A-1]&&B==(this.ranges[A-1].indexes[1]+1)){if(B==(this.ranges[A].indexes[0]-1)){this.ranges[A-1].indexes[1]=this.ranges[A].indexes[1];
+this.removeRange(A)
+}else{this.ranges[A-1].indexes[1]++
+}}else{if(this.ranges[A]){if(this.ranges[A]&&B==(this.ranges[A].indexes[0]-1)){this.ranges[A].indexes[0]--
+}else{if(B==(this.ranges[A].indexes[1]+1)){this.ranges[A].indexes[1]++
+}else{if(B<this.ranges[A].indexes[1]){this.addRange(A,new ClientUI.controls.grid.Range(B,B))
+}else{this.addRange(A+1,new ClientUI.controls.grid.Range(B,B))
+}}}}else{this.addRange(A,new ClientUI.controls.grid.Range(B,B))
+}}},addRange:function(B,A){var C=this.ranges.push(A)-2;
+if(B>=0){while(C>=B){this.ranges[C+1]=this.ranges[C--]
+}this.ranges[C+1]=A
+}},removeRange:function(A){var B=A+1;
+while(B!=this.ranges.length){this.ranges[B-1]=this.ranges[B++]
+}this.ranges.pop()
+},isSelectedId:function(B){var A=0;
+while(A<this.ranges.length&&B>=this.ranges[A].indexes[0]){if(B>=this.ranges[A].indexes[0]&&B<=this.ranges[A].indexes[1]){return true
+}else{A++
+}}return false
+},getSelectedIdsQuantity:function(){var B=0;
+for(var A=0;
+A<this.ranges.length;
+A++){B+=this.ranges[A].size()
+}return B
+},size:function(){return this.getSelectedIdsQuantity()
+},removeId:function(B){B=parseInt(B);
+if(!this.isSelectedId(B)){return 
+}var A=0;
+while(A<this.ranges.length&&B>this.ranges[A++].indexes[1]){}A--;
+if(this.ranges[A]){if(B==(this.ranges[A].indexes[1])){if(B==(this.ranges[A].indexes[0])){this.removeRange(A)
+}else{this.ranges[A].indexes[1]--
+}}else{if(B==(this.ranges[A].indexes[0])){this.ranges[A].indexes[0]++
+}else{this.addRange(A+1,new ClientUI.controls.grid.Range(B+1,this.ranges[A].indexes[1]));
+this.ranges[A].indexes[1]=B-1
+}}}},getState:function(){var A=this.clone();
+return{size:function(){return A.size()
+},each:function(B){A.each(B)
+},isSelected:function(B){return A.isSelectedId(B)
+}}
+},clone:function(){var A=Object.extend(new Object(),this);
+A.ranges=new Array(A.ranges.length);
+for(var B=0;
+B<A.ranges.length;
+B++){A.ranges[B]=this.ranges[B].clone()
+}return A
+},each:function(B){for(var A=0;
+A<this.ranges.length;
+A++){this.ranges[A].each(B)
+}},getRanges:function(){return this.ranges
+},setRanges:function(A){this.ranges=A
+},initRanges:function(C){if(C.length==0){this.ranges=[];
+return 
+}this.ranges=new Array(C.length);
+var A;
+for(var B=0;
+B<this.ranges.length;
+B++){A=C[B].split(",");
+this.ranges[B]=new ClientUI.controls.grid.Range(parseInt(A[0]),parseInt(A[1]))
+}},inspectRanges:function(){var A=this.getRanges();
+var B="";
+A.each(function(C){B+=C.inspect()
+});
+return B
+}});
+ClientUI.controls.grid.Range=Class.create({initialize:function(B,A){this.indexes=[B,A]
+},inspect:function(){return this.indexes[0]+","+this.indexes[1]+";"
+},toString:function(){return this.inspect()
+},size:function(){return this.indexes[1]-this.indexes[0]+1
+},each:function(B){var A=this.indexes[0];
+while(A<=this.indexes[1]){B(A++)
+}},clone:function(){var A=Object.extend(new Object(),this);
+A.indexes=this.indexes.clone();
+return A
+}});
+ClientUI.controls.grid.SelectionManager=Class.create({initialize:function(A){this.grid=A;
+this.selectionFlag;
+this.firstIndex;
+this.activeRow=-1;
+var B=A.getElement();
+this.prefix=B.id;
+this.selection=new ClientUI.controls.grid.Selection();
+this.inputElement=A.options.selectionInput;
+this.onselectionchange=A.options.onselectionchange;
+this.selectedClass=A.options.selectedClass;
+this.activeClass=A.options.activeClass;
+this.restoreState();
+this.setListeners();
+this.eventKeyPress=this.processKeyDown.bindAsEventListener(this);
+Event.observe(document,"keypress",this.eventKeyPress);
+A4J.AJAX.AddListener({onafterajax:function(D,C,E){if(!$(this.prefix+":n")){Event.stopObserving(document,"keypress",this.eventKeyPress)
+}}.bind(this)});
+if(document.selection){Event.observe(B,"click",this.resetSelection.bindAsEventListener(this))
+}this.eventLostFocus=this.processLostFocus.bindAsEventListener(this);
+Event.observe(document,"click",this.eventLostFocus);
+this.eventPreventLostFocus=this.processPreventLostFocus.bindAsEventListener(this);
+Event.observe(B,"click",this.eventPreventLostFocus)
+},restoreState:function(){this.selectionFlag=null;
+var F=$(this.inputElement).value.split(";");
+if(F.length!=0){var D=F[F.length-1];
+if(D.indexOf(";")==-1){this.setActiveRow(D);
+F.pop()
+}}this.selection.initRanges(F);
+var C=0;
+var A;
+while(C<this.selection.ranges.length){A=this.selection.ranges[C].indexes[0];
+while(A<=this.selection.ranges[C].indexes[1]){var E=$(this.prefix+":f:"+A);
+var B=$(this.prefix+":n:"+A);
+Element.addClassName(E,"dr-sdt-row-selected");
+Element.addClassName(B,"dr-sdt-row-selected");
+Element.addClassName(E,"rich-sdt-row-selected");
+Element.addClassName(B,"rich-sdt-row-selected");
+Element.addClassName(E,this.selectedClass);
+Element.addClassName(B,this.selectedClass);
+A++
+}C++
+}this.oldState=this.selection.getState()
+},setListeners:function(){var A=$(this.prefix+":f").rows;
+var C=$(this.prefix+":n").rows;
+this.rowCount=A.length;
+var D;
+for(var B=0;
+B<this.rowCount;
+B++){D=Number(A[B].id.split(this.prefix)[1].split(":")[2]);
+this.addListener(A[B],D);
+this.addListener(C[B],D)
+}},addListener:function(C,E){var D=this.processClick.bindAsEventListener(this,E);
+var A=C.cells;
+for(var B=0;
+B<A.length;
+B++){Utils.DOM.Event.observe(A[B],"click",D)
+}},processPreventLostFocus:function(){this.inFocus=true;
+this.preventLostFocus=true
+},processLostFocus:function(){if(!this.preventLostFocus){this.lostFocus()
+}else{this.preventLostFocus=false
+}},lostFocus:function(){this.inFocus=false
+},processKeyDown:function(D){if($(this.prefix+":n").rows.length>0){if(!D.shiftKey){this.shiftRow=null
+}var A,E;
+var C=this.activeRow;
+var B=false;
+this.firstIndex=Number($(this.prefix+":n").rows[0].id.split(this.prefix)[1].split(":")[2]);
+switch(D.keyCode||D.charCode){case Event.KEY_UP:if(this.inFocus&&C!=null){if(this.firstIndex!=C){E=(this.rowCount+C-1)%this.rowCount;
+if(!D.ctrlKey&&!D.shiftKey){this.selectionFlag="x";
+A=[E,E];
+this.setSelection(A)
+}else{if(!D.ctrlKey&&D.shiftKey){if(!this.shiftRow){this.shiftRow=this.activeRow
+}if(this.shiftRow>=this.activeRow){this.addRowToSelection(E)
+}else{this.removeRowFromSelection(C)
+}}}B=true;
+this.setActiveRow(E)
+}else{this.grid.getBody().showRow("up")
+}}break;
+case Event.KEY_DOWN:if(this.inFocus&&C!=null){E=(C+1)%this.rowCount;
+if(this.firstIndex!=E){if(!D.ctrlKey&&!D.shiftKey){this.selectionFlag="x";
+A=[E,E];
+this.setSelection(A)
+}else{if(!D.ctrlKey&&D.shiftKey){if(!this.shiftRow){this.shiftRow=this.activeRow
+}if(this.shiftRow<=this.activeRow){this.addRowToSelection(E)
+}else{this.removeRowFromSelection(C)
+}}}B=true;
+this.setActiveRow(E)
+}else{this.grid.getBody().showRow("down")
+}}break;
+case 65:case 97:if(this.inFocus&&D.ctrlKey){this.selectionFlag="a";
+A=[0,this.rowCount];
+this.setSelection(A);
+B=true
+}break;
+case Event.KEY_TAB:this.lostFocus()
+}if(B){this.grid.getBody().showRow(this.activeRow);
+this.selectionChanged(D);
+if(D.preventBubble){D.preventBubble()
+}Event.stop(D)
+}}},processClick:function(B,C){if(!B.shiftKey){this.shiftRow=null
+}var A;
+if(B.shiftKey&&!B.ctrlKey&&!B.altKey){this.firstIndex=Number($(this.prefix+":n").rows[0].id.split(this.prefix)[1].split(":")[2]);
+this.selectionFlag="x";
+if(!this.shiftRow){this.shiftRow=this.activeRow
+}this.startRow=this.shiftRow;
+if(((this.startRow<=C)&&(this.firstIndex<=this.startRow||C<this.firstIndex))||(this.startRow>C&&this.firstIndex<this.startRow&&C<=this.firstIndex)){this.endRow=C
+}else{this.endRow=this.startRow;
+this.startRow=C
+}A=[this.startRow,this.endRow];
+this.setSelection(A)
+}else{if(!B.shiftKey&&B.ctrlKey&&!B.altKey){if(this.selection.isSelectedId(C)){this.removeRowFromSelection(C)
+}else{this.addRowToSelection(C)
+}}else{if(!B.shiftKey&&!B.ctrlKey&&!B.altKey){this.selectionFlag="x";
+A=[C,C];
+this.setSelection(A)
+}}}this.setActiveRow(C);
+if(B.shiftKey){if(window.getSelection){window.getSelection().removeAllRanges()
+}else{if(document.selection){document.selection.empty()
+}}}this.selectionChanged(B)
+},selectionChanged:function(A){$(this.inputElement).value=this.selection.inspectRanges()+this.activeRow+";"+(this.selectionFlag?this.selectionFlag:"");
+var B=this.selection.getState();
+A.oldSelection=this.oldState;
+A.newSelection=B;
+if(this.onselectionchange){this.onselectionchange(A)
+}this.oldState=B
+},setShiftRow:function(A){if(A.shiftKey){if(!this.shiftRow){this.shiftRow=this.activeRow
+}}else{this.shiftRow=null
+}},setSelection:function(A){var B=A[0];
+A[1]=(A[1]+1)%this.rowCount;
+while(B!=A[1]){this.addRowToSelection(B);
+B=(B+1)%this.rowCount
+}while(B!=A[0]){this.removeRowFromSelection(B);
+B=(B+1)%this.rowCount
+}},resetSelection:function(A){if(A.shiftKey){document.selection.empty()
+}},addRowToSelection:function(C){this.selection.addId(C);
+var B=$(this.prefix+":f:"+C);
+var A=$(this.prefix+":n:"+C);
+Element.addClassName(B,"dr-sdt-row-selected");
+Element.addClassName(A,"dr-sdt-row-selected");
+Element.addClassName(B,"rich-sdt-row-selected");
+Element.addClassName(A,"rich-sdt-row-selected");
+Element.addClassName(B,this.selectedClass);
+Element.addClassName(A,this.selectedClass)
+},removeRowFromSelection:function(C){this.selection.removeId(C);
+var B=$(this.prefix+":f:"+C);
+var A=$(this.prefix+":n:"+C);
+Element.removeClassName(B,"dr-sdt-row-selected");
+Element.removeClassName(A,"dr-sdt-row-selected");
+Element.removeClassName(B,"rich-sdt-row-selected");
+Element.removeClassName(A,"rich-sdt-row-selected");
+Element.removeClassName(B,this.selectedClass);
+Element.removeClassName(A,this.selectedClass)
+},setActiveRow:function(C){var B,A;
+if(this.activeRow!=null){B=$(this.prefix+":f:"+this.activeRow);
+A=$(this.prefix+":n:"+this.activeRow);
+Element.removeClassName(B,"dr-sdt-row-active");
+Element.removeClassName(A,"dr-sdt-row-active");
+Element.removeClassName(B,"rich-sdt-row-active");
+Element.removeClassName(A,"rich-sdt-row-active");
+Element.removeClassName(B,this.activeClass);
+Element.removeClassName(A,this.activeClass)
+}B=$(this.prefix+":f:"+C);
+A=$(this.prefix+":n:"+C);
+Element.addClassName(B,"dr-sdt-row-active");
+Element.addClassName(A,"dr-sdt-row-active");
+Element.addClassName(B,"rich-sdt-row-active");
+Element.addClassName(A,"rich-sdt-row-active");
+Element.addClassName(B,this.activeClass);
+Element.addClassName(A,this.activeClass);
+this.activeRow=C
+}});
+ClientUILib.declarePackage("ClientUI.controls.grid.ScrollableGrid");
+ClientUI.controls.grid.ScrollableGrid=Class.create(ClientUI.controls.grid.Grid,{initialize:function($super,A){this.startInitTime=(new Date()).getTime();
+this.options=A;
+this.client_id=this.options.client_id;
+this.rows_count=$(this.client_id+"_rows_input").value;
+this.columns_count=this.options.columnsCount;
+this.splash_id=this.options.splash_id;
+this.dataModel=new ClientUI.controls.grid.FakeArrayDataModel(this.rows_count,this.columns_count,this.client_id);
+this.templates=[{pane:GridLayout_Enum.HEADER,ref:this.client_id+"_GridHeaderTemplate"},{pane:GridLayout_Enum.BODY,ref:this.client_id+"_GridBodyTemplate"},{pane:GridLayout_Enum.FOOTER,ref:this.client_id+"_GridFooterTemplate"}];
+this.startCreateTime=(new Date()).getTime();
+$super(this.client_id,this.dataModel,this.templates);
+this.endCreateTime=(new Date()).getTime();
+Event.observe(this.element,"grid:onsort",this.onSorted.bindAsEventListener(this));
+if(this.options.selectionInput){this.selectionManager=new ClientUI.controls.grid.SelectionManager(this)
+}this.getBody().restoreScrollState();
+this.endInitTime=(new Date()).getTime();
+this.rowCallbacks=[]
+},onSortComplete:function(C,B,D){this.dataModel.count=$(this.client_id+"_rows_input").value;
+var A=C.getJSON("options");
+Utils.AJAX.updateRows(A,C,this,this.client_id,[this.updateSelectionCallBack],[function(){this.selectionManager.restoreState();
+this.element.fire("grid:onpostsort",{column:A.column,order:A.order})
+}]);
+this.updateLayout();
+this.getBody().restoreScrollState()
+},onScrollComplete:function(C,B,D){this.dataModel.count=$(this.client_id+"_rows_input").value;
+var A=this.dataModel.getCurrentOptions();
+window.loadingServerTime=(new Date()).getTime();
+Utils.AJAX.updateRows(A,C,this,this.client_id,[this.updateSelectionCallBack],[function(){this.selectionManager.restoreState();
+this.element.fire("grid:onpostscroll",{start:this.getBody().currRange.start})
+}]);
+this.updateLayout();
+this.getBody().restoreScrollState();
+window.loadingEndTime=(new Date()).getTime();
+ClientUILib.log(ClientUILogger.ERROR,"Total time of data loading of "+A.count+" rows is: "+(window.loadingEndTime-window.loadingStartTime)+" miliseconds.");
+ClientUILib.log(ClientUILogger.WARNING,"...Server load time: "+(window.loadingServerTime-window.loadingStartTime));
+ClientUILib.log(ClientUILogger.WARNING,"...DOM updated time: "+(window.loadingUpdateTime-window.loadingServerTime));
+ClientUILib.log(ClientUILogger.WARNING,"...Grid invalidation time: "+(window.loadingInvalidateTime-window.loadingUpdateTime));
+ClientUILib.log(ClientUILogger.WARNING,"...Selection mng time: "+(window.loadingEndTime-window.loadingInvalidateTime))
+},onSorted:function(A){this.options.onSortAjaxUpdate(A.memo)
+},updateSelectionCallBack:function(A){if(this.selectionManager){this.selectionManager.addListener(A.row,A.index)
+}},setSizes:function(C,A){var B=this.element.style;
+B.width=C+"px";
+B.height=A+"px";
+this.updateLayout()
+},doCollapse:function(A){var E=this.getHeader();
+var D=E.headerFrozenRow.getElement().rows[0].cells.length;
+var C=E.headerRow.getElement().rows[0].cells.length;
+if(A<D+C-1){var B=true;
+if(A>=D){A-=D;
+B=false
+}this.hideColumn(A,B)
+}},hideColumn:function(A,B){this.getHeader().hideColumn(A,B);
+this.getBody().hideColumn(A,B);
+if(this.getFooter()){this.getFooter().hideColumn(A,B)
+}this.updateLayout()
+}})
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.ContextMenu=Class.create();
+Richfaces.ContextMenu.prototype={initialize:function(D,B,C,A){this.options=A||{};
+this.id=D;
+this.evaluator=C;
+$(D).component=this;
+this.doShow=this.show;
+this.doHide=this.hide;
+this.delay=B
+},attachToParent:function(F,D,B){var A=$(F);
+if(!A){A=$(this.id);
+if(A){A=A.parentNode
+}}if(A){this.applyDecoration(A)
+}var C=D.substr(2);
+var E=this.show.bindAsEventListener(this,B);
+Event.observe(A,C,E)
+},hide:function(){RichFaces.Menu.Layers.shutdown()
+},show:function(B,A){this.construct(A);
+B.parameters=A;
+var C=new RichFaces.Menu.DelayedContextMenu(this.id+"_menu",B);
+window.setTimeout(C.show,this.delay)
+},construct:function(B){if(this.isNewContext(B)){this.destroy()
+}var C=document.createElement("div");
+C.id=this.id+":_auto_created";
+$(this.id).appendChild(C);
+var A=this.evaluator.invoke("getContent",B||window).join("");
+new Insertion.Top(C,A)
+},destroy:function(){var A=$(this.id+":_auto_created");
+Richfaces.infernalCachePurge(A);
+if(A){A.parentNode.removeChild(A)
+}},isNewContext:function(A){return true
+},applyDecoration:function(A){$(A).addClassName("rich-cm-attached")
+}};
+Richfaces.disableDefaultHandler=function(A){if(A.startsWith("on")){A=A.substr(2)
+}Event.observe(document,A,Event.stop)
+};
+Richfaces.enableDefaultHandler=function(A){if(A.startsWith("on")){A=A.substr(2)
+}Event.stopObserving(document,A,Event.stop)
+};
+Richfaces.infernalCachePurge=function(A){if(A){if(A._eventID){Event.stopObserving(A)
+}var B=A.firstChild;
+while(B){Richfaces.infernalCachePurge(B);
+B=B.nextSibling
+}}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.processEffect=function(A){new Effect[A.type]($(A.targetId),A)
+};
+Richfaces.effectEventOnOut=function(A){return A.substr(0,2)=="on"?A.substr(2):A
+}
+
+function __addLoadEvent(A){Event.observe(window,"load",A)
+}function __addUnLoadEvent(A){Event.observe(window,"unload",A)
+}function __initGmapdiv(C,D,A){var B=document.getElementById(D);
+if(GBrowserIsCompatible()){window[C]=new GMap2(B);
+B.map=window[C]
+}else{B.innerHTML=A
+}}function __applyGmapparam(H,F,G,J,A,D,K,C,E,L,B,I){if(GBrowserIsCompatible()){window[H].setCenter(new GLatLng(F,G),J,A);
+if(D){window[H].enableDragging()
+}else{window[H].disableDragging()
+}if(K){window[H].enableInfoWindow()
+}else{window[H].disableInfoWindow()
+}if(C){window[H].enableDoubleClickZoom()
+}else{window[H].disableDoubleClickZoom()
+}if(E){window[H].enableContinuousZoom()
+}else{window[H].disableContinuousZoom()
+}if(L){window[H].addControl(new GMapTypeControl())
+}if(B){window[H].addControl(new GScaleControl())
+}if(I){window[H].addControl(new GLargeMapControl())
+}}}
+function __addLoadEvent(A){Event.observe(window,"load",A)
+}function __initVirtualEarthdiv(A,B){window[A]=new VEMap(B)
+}function __applyVirtualEarthparam(E,H,G,B,D,A,C){var F=window[E];
+F.SetDashboardSize(C);
+F.onLoadMap=H;
+F.LoadMap();
+F.SetCenterAndZoom(new VELatLong(G,B),D);
+F.SetMapStyle(A)
+}
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.Slider=Class.create();
+Richfaces.Slider.prototype={initialize:function(C,B,E,G,H,I){var A=this;
+this.handle=$(C);
+this.tip=$(E);
+this.track=$(B);
+this.mainTable=$(G);
+this.input=$(I.inputId)||document.getElementsByName(I.inputId)[0];
+this.options=I||{};
+this.classes={};
+this.classes.arrow="dr-insldr-handler rich-inslider-handler";
+this.classes.arrowSelected="dr-insldr-handler-sel rich-inslider-handler-selected";
+this.classes.temp=this.handle.className;
+this.classes.base=" "+this.trim(this.classes.temp.replace("dr-insldr-handler rich-inslider-handler",""));
+this.classes.handleSelected=" "+H;
+this.table=this.findTableForTrack(this.track);
+this.input.value=this.options.sliderValue;
+this.prevInputValue=this.input.value;
+this.graggedImageOn=false;
+this.range=this.options.range||$R(0,1);
+this.value=0;
+this.minimum=this.options.minimum||this.range.start;
+this.maximum=this.options.maximum||this.range.end;
+this.digCount=0;
+this.step=this.options.step;
+if((this.step+"").indexOf(".")!=-1){var F=(this.step+"");
+this.digCount=(F.substring(F.indexOf(".")+1,F.length)).length
+}this.availableValues=this.calculateAvailableValues();
+this.tip.maxlength=(this.maximum+"").length+(this.digCount!=0?this.digCount+1:0);
+this.handleLength=9;
+this.active=false;
+this.dragging=false;
+this.editInFocus=false;
+this.disabled=this.options.disabled?true:false;
+var D=this.track.childNodes[0];
+this.prevMouseUp=window.document.onmouseup;
+this.prevMouseMove=window.document.onmousemove;
+this.documentBodyOload=this.load.bindAsEventListener(this);
+Event.observe(window,"load",this.documentBodyOload);
+this.eventWindowResized=this.windowResized.bindAsEventListener(this);
+Event.observe(window,"resize",this.eventWindowResized);
+if(!this.options.disabled){this.eventMouseUp=this.processMouseUp.bindAsEventListener(this);
+this.eventMouseMove=this.update.bindAsEventListener(this);
+this.eventMouseDown=this.startDrag.bindAsEventListener(this);
+this.eventEditFocus=this.editFocus.bindAsEventListener(this);
+this.eventEditBlur=this.editBlur.bindAsEventListener(this);
+this.eventEditChange=this.editChange.bindAsEventListener(this);
+this.eventEditValidate=this.inputValidate.bindAsEventListener(this);
+this.eventInputChange=this.inputChange.bindAsEventListener(this);
+this.eventWindowMouseOut=this.windowMouseOut.bindAsEventListener(this);
+if(this.options.onerr){this.eventError=new Function("event","clientErrorMessage",this.options.onerr)
+}if(this.options.onchange!=""){this.eventChanged=new Function("event",this.options.onchange).bindAsEventListener(this)
+}Event.observe(this.track,"mousedown",this.eventMouseDown);
+Event.observe(D,"mousedown",this.eventMouseDown);
+Event.observe(this.input,"keydown",this.eventEditValidate);
+Event.observe(this.input,"keyup",this.eventEditChange);
+Event.observe(this.input,"focus",this.eventEditFocus);
+Event.observe(this.input,"blur",this.eventEditBlur);
+Event.observe(document,"mouseout",this.eventWindowMouseOut);
+if(this.input.onchange){this.eventInputOnChange=this.input.onchange.bindAsEventListener(this.input);
+this.input.onchange=null
+}Event.observe(this.input,"change",this.eventInputChange)
+}this.initialized=true;
+this.setInitialValue();
+this.required=I.required
+},setInitialValue:function(){this.setValue(parseFloat(this.options.sliderValue||this.range.start));
+this.handle.style.visibility="visible";
+this.prevValue=this.value;
+this.valueChanged=false
+},calculateAvailableValues:function(){var A=new Array();
+var C=this.roundFloat(this.minimum);
+var B=0;
+while(C<this.maximum){A[B]=C;
+C=this.roundFloat(C+parseFloat(this.step));
+B++
+}A[B]=this.roundFloat(this.maximum);
+return A
+},roundFloat:function(A){if(!this.digCount){return Math.round(A)
+}return parseFloat(Number(A).toFixed(this.digCount))
+},windowMouseOut:function(A){var B=null;
+if(A.srcElement){B=A.toElement
+}else{B=A.relatedTarget
+}if(B==null){this.endDrag(A)
+}},windowResized:function(A){this.setValue(this.value)
+},findTableForTrack:function(B){var A=B.parentElement||B.parentNode;
+if(A.tagName.toUpperCase()=="TABLE"){return A
+}else{return this.findTableForTrack(A)
+}},getNearestValue:function(B){var C;
+C=this.binsearch(this.availableValues,B);
+if(C>0){var A=C-1;
+if(Math.abs(B-this.availableValues[A])<Math.abs(this.availableValues[C]-B)){C=A
+}}return this.roundFloat(this.availableValues[C])
+},binsearch:function(B,E){var D=0;
+var C=B.length-1;
+var A;
+while(D<C){A=Math.round((D+C)/2+0.5)-1;
+if(E<=B[A]){C=A
+}else{D=A+1
+}}return D
+},setValue:function(A){if(isNaN(A)){A=0
+}A=this.getNearestValue(A);
+this.value=A;
+if(!this.editInFocus&&(this.required||""!=this.input.value||this.updating)){this.input.value=this.value;
+this.handle.style.left=this.translateToPx(A)
+}else{this.handle.style.left="-2px"
+}if(!this.tip.firstChild){this.tip.appendChild(window.document.createTextNode(this.value))
+}this.tip.firstChild.nodeValue=this.value;
+this.tip.style.left=this.handle.offsetLeft+"px"
+},translateToPx:function(A){return Math.round(((this.maximumOffset()-this.handleLength)/(this.range.end-this.range.start))*(A-this.range.start))+"px"
+},translateToValue:function(A){return((A/(this.maximumOffset()-this.handleLength)*(this.range.end-this.range.start))+this.range.start)
+},maximumOffset:function(){return this.removePx(this.track.style.width||this.track.offsetWidth)
+},removePx:function(A){if((A+"").indexOf("px")!=-1){return(A+"").substring(0,A.length-2)
+}else{return A
+}},startDrag:function(B){if(this.editInFocus){this.input.blur()
+}window.document.onmouseup=this.eventMouseUp.bindAsEventListener(this);
+window.document.onmousemove=this.eventMouseMove.bindAsEventListener(this);
+this.editBlur();
+this.prevMouseDownEvent=B;
+if(Event.isLeftClick(B)){if(!this.disabled){this.handle.className=this.classes.arrowSelected+this.classes.base+this.classes.handleSelected;
+if(this.options.currValue){Element.show(this.tip);
+Element.setStyle(this.tip,{top:"-"+(this.tip.offsetHeight+2)+"px"})
+}Richfaces.createEvent("mousedown",this.mainTable,null,null).fire();
+this.active=true;
+var D=Event.element(B);
+var E=Event.pointerX(B);
+var A=Position.cumulativeOffset(this.track);
+this.updating=true;
+var C=this.translateToValue((E-A[0])-(this.handleLength/2));
+if(this.invokeEvent("slide",B,this.getNearestValue(C),this.input)){this.setValue(C)
+}this.updating=false;
+var A=Position.cumulativeOffset(this.handle);
+this.offsetX=E-A[0]
+}Event.stop(B)
+}},update:function(A){this.updating=true;
+if(this.active){if(!this.dragging){this.dragging=true
+}this.draw(A);
+Event.stop(A)
+}this.updating=false
+},draw:function(B){var C=Event.pointerX(B);
+var A=Position.cumulativeOffset(this.track);
+C-=this.offsetX+A[0];
+this.setValue(this.translateToValue(C))
+},processMouseUp:function(A){this.endDrag(A);
+this.fireClickIfNeeded(A)
+},endDrag:function(A){window.document.onmouseup=this.prevMouseUp;
+window.document.onmousemove=this.prevMouseMove;
+if(this.options.currValue){Element.hide(this.tip)
+}if(this.eventChanged&&this.isValueChanged()){this.eventChanged(A)
+}this.handle.className=this.classes.arrow+this.classes.base;
+if(this.active&&this.dragging){this.active=false;
+this.dragging=false;
+Richfaces.createEvent("mouseup",this.mainTable,null,null).fire();
+Event.stop(A)
+}if(RichFaces.navigatorType()!=RichFaces.MSIE){Richfaces.createEvent("change",this.input,null,null).fire()
+}},fireClickIfNeeded:function(A){if((this.prevMouseDownEvent.target!=A.target&&RichFaces.navigatorType()==RichFaces.FF)||(RichFaces.getOperaVersion()&&RichFaces.getOperaVersion()<9&&A.target.tagName.toLowerCase()!="div")){Richfaces.createEvent("click",this.mainTable,null,null).fire()
+}},isValueChanged:function(){var A=this.prevValue!=this.value;
+this.prevValue=this.value;
+return A
+},inputChange:function(A){this.editInFocus=false;
+if(isNaN(Number(this.input.value))){this.setValue(this.value)
+}else{if(this.outOfRange){if(this.eventError){this.eventError(A,this.options.clientErrorMessage)
+}}this.setValue(Number(this.input.value))
+}this.value=this.input.value?this.input.value:this.value;
+if(this.eventInputOnChange){this.eventInputOnChange()
+}if(this.eventChanged&&this.isValueChanged()){this.eventChanged(A)
+}},inputValidate:function(A){if(A.keyCode==13){if(isNaN(Number(this.input.value))){this.input.value=this.value;
+this.editBlur();
+this.setValue(this.value)
+}}},editChange:function(A){if(this.input.value=="-"){return 
+}if(isNaN(Number(this.input.value))){this.setValue(Number(this.value));
+this.input.value=this.value;
+if(this.eventError){this.eventError(A,this.options.clientErrorMsg)
+}}else{if(!(A.keyCode>=37&&A.keyCode<=40)){this.setValue(Number(this.input.value))
+}}if(A.keyCode==13){if(this.required||""!=this.input.value){this.input.value=this.getNearestValue(this.value)
+}this.input.form.submit()
+}if(this.eventChanged&&this.isValueChanged()){this.eventChanged(A)
+}},editFocus:function(){this.editInFocus=true
+},editBlur:function(){this.editInFocus=false;
+if((this.input.value+"").indexOf(this.value)!=0){this.setValue(this.input.value);
+this.eventInputChange()
+}else{this.setValue(this.input.value)
+}},load:function(){if(this.input.value){this.options.sliderValue=this.input.value
+}this.setInitialValue()
+},trim:function(A){return A.replace(/^\s+|\s+$/,"")
+},invokeEvent:function(B,E,G,C){var D=this.options["on"+B];
+var A;
+if(D){var F;
+if(E){F=E
+}else{if(document.createEventObject){F=document.createEventObject()
+}else{if(document.createEvent){F=document.createEvent("Events");
+F.initEvent(B,true,false)
+}}}F.rich={component:this};
+F.rich.value=G;
+try{A=D.call(C,F)
+}catch(H){LOG.warn("Exception: "+H.Message+"\n[on"+B+"]")
+}}if(A!=false){A=true
+}return A
+}}
+
+if(!window.Richfaces){window.Richfaces={}
+}Richfaces.Spinner=Class.create();
+Richfaces.Spinner.prototype={initialize:function(F,B,E,C,A){this.content=$(F.edit);
+this.controls=$(F.buttons);
+this.fie=$(F.forIE);
+this.ch=B.chameleon;
+this.items=new Array();
+this.table=$(F.buttons.substr(F.buttons.indexOf("buttons")+7));
+if(RichFaces.navigatorType()==RichFaces.FF||RichFaces.navigatorType()==RichFaces.NETSCAPE){if(!this.fie){this.table.style.display="-moz-inline-box"
+}}this.options=B;
+if(!B.disabled){this.buttonUp=null;
+this.buttonDown=null
+}this.cycled=B.cycled;
+this.edited=B.edited;
+var D=this._getDirectChildrenByTag(this.content,"INPUT")[0];
+this.upClick=new Function(C.onup+";return true;").bindAsEventListener(D);
+this.downClick=new Function(C.ondown+";return true;").bindAsEventListener(D);
+this.error=new Function("event","clientErrorMessage",C.onerr+";return true;").bind(D);
+this.data=E;
+this.max=null;
+this.min=null;
+this.delta=null;
+this.required=B.required;
+this._attachBehaviors();
+this._load()
+},switchItems:function(B){var A=this.controls.edit.value;
+if(B=="up"){if(""==A){this.controls.edit.value=this.min
+}else{A-=this.delta*-1;
+A=this.roundFloat(A);
+if(A<=this.max&&A>=this.min){this.controls.edit.value=A
+}else{if(this.cycled){if(this.delta>0){this.controls.edit.value=this.min
+}else{this.controls.edit.value=this.max
+}}else{this.error(B,this.options.clientErrorMsg);
+this.controls.fireEditEvent("error");
+this.controls.edit.value=this.max;
+return true
+}}}}else{if(""==A){this.controls.edit.value=this.max
+}else{A-=this.delta;
+A=this.roundFloat(A);
+if(A>=this.min&&A<=this.max){this.controls.edit.value=A
+}else{if(this.cycled){if(this.delta<0){this.controls.edit.value=this.min
+}else{this.controls.edit.value=this.max
+}}else{this.error(B,this.options.clientErrorMsg);
+this.controls.fireEditEvent("error");
+this.controls.edit.value=this.min;
+return true
+}}}}return false
+},roundFloat:function(A){var D=this.delta.toString();
+var C=0;
+if(!/\./.test(D)){if(this.delta>=1){return A
+}if(/e/.test(D)){C=D.split("-")[1]
+}}else{C=D.length-D.indexOf(".")-1
+}var B=A.toFixed(C);
+return B
+},_load:function(){this.controls.edit.readOnly=this.edited?"":"readOnly";
+if(this.options.disabled){this.controls.edit.readOnly="readOnly";
+Element.setStyle(this.controls.edit,{color:"gray"})
+}else{Element.setStyle(this.controls.edit,{color:""})
+}},_attachBehaviors:function(){this.max=this.data.max;
+this.min=this.data.min;
+this.delta=this.data.delta;
+var C=this._getDirectChildrenByTag(this.controls,"TBODY")[0];
+var B=this._getDirectChildrenByTag(C,"TR");
+var F=this._getDirectChildrenByTag(B[0],"TD")[0];
+var G=this._getDirectChildrenByTag(B[1],"TD")[0];
+var E=this._getDirectChildrenByTag(this.content,"INPUT")[0];
+if(this.ch=="false"){this.buttonUp=this._getDirectChildrenByTag(F,"INPUT")[0];
+this.buttonDown=this._getDirectChildrenByTag(G,"INPUT")[0];
+var A=null;
+var D=null
+}else{var A=this._getDirectChildrenByTag(F,"INPUT")[0];
+var D=this._getDirectChildrenByTag(G,"INPUT")[0]
+}this.controls=new Richfaces.Spinner.Controls(this,{button:F,img:A},{button:G,img:D},E)
+},_getDirectChildrenByTag:function(E,D){var B=new Array();
+var A=E.childNodes;
+for(var C=0;
+C<A.length;
+C++){if(A[C]&&A[C].tagName&&A[C].tagName.toUpperCase()==D.toUpperCase()){B.push(A[C])
+}}return B
+},_removePx:function(A){return A.substring(0,A.indexOf("px"))
+}};
+Richfaces.Spinner.Controls=Class.create();
+Richfaces.Spinner.Controls.prototype={initialize:function(C,A,D,B){this.spinner=C;
+this.up=$(A.button);
+this.upimg=$(A.img);
+this.down=$(D.button);
+this.downimg=$(D.img);
+this.mousedown=false;
+this.onUpButton=false;
+this.onDownButton=false;
+this.fie=this.spinner.fie;
+this.edit=$(B);
+this.originalColor=B.style.color;
+this.prevEditValue=(this.edit.value||!this.spinner.required)?this.edit.value:this.spinner.min;
+this.edit.value=this.prevEditValue;
+this.previousMU=window.document.onmouseup;
+this.previousMM=window.document.onmousemove;
+if(!C.options.disabled){this._attachBehaviors();
+this.edit.style.color=this.originalColor
+}else{if(!this.fie){this.edit.style.color="gray"
+}}},upClick:function(B){if(B.preventDefault){B.preventDefault()
+}var A=this.spinner.switchItems("up");
+this.spinner.upClick();
+if(!A){window.document.onmouseup=this.mouseUp.bindAsEventListener(this);
+this.mousedown=true;
+this.timer=setTimeout(this.continueUpClick.bind(this),750)
+}},downClick:function(B){if(B.preventDefault){B.preventDefault()
+}var A=this.spinner.switchItems("down");
+this.spinner.downClick();
+if(!A){window.document.onmouseup=this.mouseUp.bindAsEventListener(this);
+this.mousedown=true;
+this.timer=setTimeout(this.continueDownClick.bind(this),750)
+}},continueUpClick:function(){if(!this.mousedown){return 
+}window.document.onmousemove=this.mouseMoveUp.bindAsEventListener(this);
+this.spinner.switchItems("up");
+if(this.timer){clearTimeout(this.timer)
+}this.timer=setTimeout(this.continueUpClick.bind(this),100)
+},continueDownClick:function(){if(!this.mousedown){return 
+}window.document.onmousemove=this.mouseMoveDown.bindAsEventListener(this);
+this.spinner.switchItems("down");
+if(this.timer){clearTimeout(this.timer)
+}this.timer=setTimeout(this.continueDownClick.bind(this),100)
+},mouseUp:function(A){clearTimeout(this.timer);
+if(this.spinner.ch=="true"){if(!this.onUpButton){this.upUp()
+}if(!this.onDownButton){this.downUp()
+}}if(this.mousedown){this.mousedown=false;
+this.fireEditEvent("change")
+}},mouseMoveDown:function(A){if(A.preventDefault){A.preventDefault()
+}if((this.downimg!=Event.element(A))){window.document.onmousemove=this.previousMM;
+clearTimeout(this.timer);
+this.mousedown=false;
+if(this.spinner.ch=="true"){if(!this.onUpButton){this.upUp()
+}if(!this.onDownButton){this.downUp()
+}}this.fireEditEvent("change")
+}},mouseMoveUp:function(A){if(A.preventDefault){A.preventDefault()
+}if(this.upimg!=Event.element(A)){window.document.onmousemove=this.previousMM;
+clearTimeout(this.timer);
+this.mousedown=false;
+if(this.spinner.ch=="true"){if(!this.onUpButton){this.upUp()
+}if(!this.onDownButton){this.downUp()
+}}this.fireEditEvent("change")
+}},inputChange:function(A){if((this.edit.value==""&&this.spinner.required)||isNaN(Number(this.edit.value))){this.edit.value=this.prevEditValue
+}else{if(""!=this.edit.value){if(this.edit.value>this.spinner.max){this.edit.value=this.spinner.max
+}else{if(this.edit.value<this.spinner.min){this.edit.value=this.spinner.min
+}}}}if(""!=this.edit.value){this.prevEditValue=this.edit.value
+}if(this.eventEditOnChange){this.eventEditOnChange()
+}},editChange:function(A){if((this.edit.value<this.spinner.max)&&(this.edit.value>this.spinner.min)&&!isNaN(Number(this.edit.value))&&this.edit.value!=""){this.prevEditValue=this.edit.value
+}if(A.keyCode==13){if(this.spinner.required||""!=this.edit.value){this.edit.value=this.getValidValue(this.edit.value)
+}this.edit.form.submit()
+}},getValidValue:function(A){if(isNaN(A)||A==""){return this.prevEditValue
+}if(A>this.spinner.max){return this.spinner.max
+}if(A<this.spinner.min){return this.spinner.min
+}return A
+},drag:function(){return false
+},_attachBehaviors:function(){this.up.onmousedown=this.upClick.bindAsEventListener(this);
+this.down.onmousedown=this.downClick.bindAsEventListener(this);
+this.up.onmouseup=this.mouseUp.bindAsEventListener(this);
+this.down.onmouseup=this.mouseUp.bindAsEventListener(this);
+this.edit.onkeydown=this.editChange.bindAsEventListener(this);
+this.eventInputChange=this.inputChange.bindAsEventListener(this);
+if(this.edit.onchange){this.eventEditOnChange=this.edit.onchange
+}this.edit.onchange=this.eventInputChange.bindAsEventListener(this.edit)
+},fireEditEvent:function(B){if(document.createEvent){var A=document.createEvent("HTMLEvents");
+A.initEvent(B,true,false);
+this.edit.dispatchEvent(A)
+}else{if(document.createEventObject){this.edit.fireEvent("on"+B)
+}}}}
+
+if(!window.Richfaces){window.Richfaces={}
+}if(!Richfaces.componentControl){Richfaces.componentControl={}
+}Richfaces.componentControl.eachComponent=function(A,B){jQuery(A).each(function(){if(this.component){B(this.component)
+}})
+};
+Richfaces.componentControl.applyDecorations=function(B,A,C){if(C){C(B)
+}Richfaces.componentControl.eachComponent(A,function(D){if(D.applyDecoration){D.applyDecoration(B)
+}})
+};
+Richfaces.componentControl.attachEvent=function(C,F,B,A,E,D){jQuery(C).bind(Richfaces.effectEventOnOut(F),function(G){Richfaces.componentControl.performOperation(G,B,A,E,D)
+}).each(function(){Richfaces.componentControl.applyDecorations(this,B,function(G){})
+})
+};
+Richfaces.componentControl.performOperation=function(D,B,A,E,C){Richfaces.componentControl.eachComponent(B,function(F){F[A](D,E)
+});
+if(C){Event.stop(D)
+}};
+Richfaces.effectEventOnOut=function(A){return A.substr(0,2)=="on"?A.substr(2):A
+}
+

Modified: portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/include/header.xhtml
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/include/header.xhtml	2008-01-09 18:08:25 UTC (rev 191)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/include/header.xhtml	2008-01-09 22:53:31 UTC (rev 192)
@@ -26,7 +26,7 @@
 <tbody>
 	<tr>
 		<td>
-			<strong>Skins:</strong>
+			<!--<strong>Skins:</strong>-->
 		</td>
 		<td>
 			<rich:togglePanel id="skin_chooser" value="#{skinBean.skinChooserState}" switchType="ajax" stateOrder="s,b">

Modified: portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/main.xhtml
===================================================================
--- portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/main.xhtml	2008-01-09 18:08:25 UTC (rev 191)
+++ portlets/src/framework/RichFacesPortlet/src/main/webapp/templates/main.xhtml	2008-01-09 22:53:31 UTC (rev 192)
@@ -12,8 +12,6 @@
 	<ui:insert name="title"/>
 </title>
 <link rel="STYLESHEET" type="text/css" href="${facesContext.externalContext.requestContextPath}/css/common.css"/>
-<!--<script src="http://localhost:8080/RichFacesPortlet/faces/a4j_3_2_0-SNAPSHOTorg/ajax4jsf/framework.pack.js" type="text/javascript"/>-->
-   <!--<script src="http://localhost:8080/RichFacesPortlet/faces/a4j_3_2_0-SNAPSHOTorg/richfaces/ui.pack.js" type="text/javascript"/>-->
 <ui:include src="/templates/include/dynamic-css.xhtml" />
 </head>
 




More information about the jboss-svn-commits mailing list