Author: vbaranov
Date: 2008-03-18 08:30:57 -0400 (Tue, 18 Mar 2008)
New Revision: 6901
Modified:
branches/3.1.x/ui/simpleTogglePanel/src/main/java/org/richfaces/renderkit/html/SimpleTogglePanelRenderer.java
Log:
http://jira.jboss.com/jira/browse/RF-2545
Modified:
branches/3.1.x/ui/simpleTogglePanel/src/main/java/org/richfaces/renderkit/html/SimpleTogglePanelRenderer.java
===================================================================
---
branches/3.1.x/ui/simpleTogglePanel/src/main/java/org/richfaces/renderkit/html/SimpleTogglePanelRenderer.java 2008-03-18
12:30:38 UTC (rev 6900)
+++
branches/3.1.x/ui/simpleTogglePanel/src/main/java/org/richfaces/renderkit/html/SimpleTogglePanelRenderer.java 2008-03-18
12:30:57 UTC (rev 6901)
@@ -107,10 +107,16 @@
panel.setOpened(new Boolean((String) clnId).booleanValue());
}
+ // in case of "ajax" request and "ajax" switch mode of
toggle panel
+ // set the regions to be rendered (reRendered) after operating this
"ajax" request
if (AjaxRendererUtils.isAjaxRequest(context) &&
panel.getSwitchType().equals(UISimpleTogglePanel.AJAX_SWITCH_TYPE)) {
- AjaxRendererUtils.addRegionByName(context,
+ // add toggle panel itself to rendered list of components
+ AjaxRendererUtils.addRegionByName(context,
panel,
panel.getId());
+ // add regions specified in the "reRender" attribute of toggle
panel
+ // to rendered list of components
+ AjaxRendererUtils.addRegionsFromComponent(panel, context);
}
}