Author: abelevich
Date: 2008-03-17 10:46:54 -0400 (Mon, 17 Mar 2008)
New Revision: 6860
Modified:
trunk/ui/pickList/src/main/templates/htmlPickList.jspx
Log:
http://jira.jboss.com/jira/browse/RF-2549
Modified: trunk/ui/pickList/src/main/templates/htmlPickList.jspx
===================================================================
--- trunk/ui/pickList/src/main/templates/htmlPickList.jspx 2008-03-17 14:45:46 UTC (rev
6859)
+++ trunk/ui/pickList/src/main/templates/htmlPickList.jspx 2008-03-17 14:46:54 UTC (rev
6860)
@@ -155,19 +155,22 @@
<script type="text/javascript">
var clientId = '#{clientId}';
- Event.onReady(function() {
- var cotrolsIdPrefix = [['up', 'disup'], ['down',
'disdown'], ['last', 'dislast'],
['first','disfirst']];
- var listShuttleCotrolsIdPrefix = [['copy', 'discopy'],
['copyAll', 'discopyAll'], ['remove', 'disremove'],
['removeAll','disremoveAll']];
+ RichShuttleUtils.execOnLoad(
+ function(){
+ var cotrolsIdPrefix = [['up', 'disup'], ['down',
'disdown'], ['last', 'dislast'],
['first','disfirst']];
+ var listShuttleCotrolsIdPrefix = [['copy', 'discopy'],
['copyAll', 'discopyAll'], ['remove', 'disremove'],
['removeAll','disremoveAll']];
- var sourceLayoutManager = new LayoutManager('#{clientId}internal_header_tab',
'#{clientId}internal_tab');
- var targetLayoutManager = new
LayoutManager('#{clientId}tlInternal_header_tab',
'#{clientId}tlInternal_tab');
+ var sourceLayoutManager = new LayoutManager('#{clientId}internal_header_tab',
'#{clientId}internal_tab');
+ var targetLayoutManager = new
LayoutManager('#{clientId}tlInternal_header_tab',
'#{clientId}tlInternal_tab');
- var listShuttle = new Richfaces.PickList(new
Richfaces.PickList.Target('#{clientId}', '#{clientId}tlInternal_tab',
'#{clientId}tlInternal_header_tab', '#{clientId}tlFocusKeeper', undefined,
Richfaces.PickList.Target.SelectItem, #{this:getColumnClassesAsJSArray(context,
component)}, #{this:getRowClassesAsJSArray(context, component)}),
+ var listShuttle = new Richfaces.PickList(new
Richfaces.PickList.Target('#{clientId}', '#{clientId}tlInternal_tab',
'#{clientId}tlInternal_header_tab', '#{clientId}tlFocusKeeper', undefined,
Richfaces.PickList.Target.SelectItem, #{this:getColumnClassesAsJSArray(context,
component)}, #{this:getRowClassesAsJSArray(context, component)}),
new Richfaces.PickList.Source('#{clientId}',
'#{clientId}internal_tab', '#{clientId}internal_header_tab',
'#{clientId}focusKeeper', undefined, Richfaces.PickList.Source.SelectItem,
#{this:getColumnClassesAsJSArray(context, component)},
#{this:getRowClassesAsJSArray(context, component)}),
"#{clientId}", listShuttleCotrolsIdPrefix,
"#{switchByClick}", sourceLayoutManager, targetLayoutManager,
#{this:getAsEventHandler(context, component, "onlistchanged")},
"#{clientId}valueKeeper");
- sourceLayoutManager.widthSynchronization();
- targetLayoutManager.widthSynchronization();
- });
+ sourceLayoutManager.widthSynchronization();
+ targetLayoutManager.widthSynchronization();
+ },
+ RichShuttleUtils.Condition.ElementPresent("#{clientId}"), 100
+ );
</script>
</f:root>
\ No newline at end of file