-
1. Re: keepTransient attribute on a4j:outputPanel not working?
nbelaevski Oct 30, 2008 10:24 PM (in response to tinydragon)Hi,
I've created an issue for that: https://jira.jboss.org/jira/browse/RF-4799
Facelets text is "extra" transient: see the source code for UIComponent instance representing text http://kickjava.com/src/com/sun/facelets/compiler/UILeaf.java.htm
You can wrap text inside <f:verbatim> tag. Unfortunately that doesn't work with 1.15.B1 Facelets :( -
2. Re: keepTransient attribute on a4j:outputPanel not working?
tinydragon Oct 31, 2008 3:30 AM (in response to tinydragon)Hi,
thanks for your answer. I've tried your suggestion using f:verbatim with our facelets version 1.1.14 but it doesn't work eighter. -
3. Re: keepTransient attribute on a4j:outputPanel not working?
nbelaevski Oct 31, 2008 10:46 AM (in response to tinydragon)Strange, that worked for me. Can you please post full page source?
-
4. Re: keepTransient attribute on a4j:outputPanel not working?
tinydragon Oct 31, 2008 11:48 AM (in response to tinydragon)OK, you are right, the simple example work if u use f:verbatim, but not our real world application.
I've created a very simplified use-case to show you how our application works. You can use it to reproduce the bug.
It consists of 2 pages, one is included in the other with ui:include. The included one is inside a rich:tabpanel which is client-side switched. The included content is rerendered if you click on the tab itself. An a4j:jsFunction is used to do that.
If you set the selfRendered propperty from the a4j:region to false, the bold text "text text text" shows up between -begin- and -end- after you click on the tab. If you set selfRendered to true, the "text text text" never shows. Thats our problem.
There are the xhtml files:
master:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:s="http://jboss.com/products/seam/taglib" xmlns:rich="http://richfaces.org/rich" xmlns:a4j="http://richfaces.org/a4j" > <ui:composition > <h:form> <a4j:region selfRendered="true"> <rich:tabPanel switchType="client"> <rich:tab label="tab" switchType="client" onlabelclick="LoadContent();" > -begin- <h:panelGroup layout="block" id="ContentContainer"> <s:fragment rendered="#{controller.contentLoaded}"> <ui:include src="test_inc.xhtml" /> </s:fragment> </h:panelGroup> -end- <a4j:jsFunction name="LoadContent" reRender="ContentContainer" > <a4j:actionparam assignTo="#{controller.contentLoaded}" value="true" name="loaded" /> </a4j:jsFunction> </rich:tab> </rich:tabPanel> </a4j:region> </h:form> </ui:composition> </html>
include:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:f="http://java.sun.com/jsf/core" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:a4j="http://richfaces.org/a4j" > <ui:composition> <a4j:outputPanel keepTransient="true" id="test" > <f:verbatim> <b>text text text</b> </f:verbatim> </a4j:outputPanel> </ui:composition> </html>
-
5. Re: keepTransient attribute on a4j:outputPanel not working?
nbelaevski Dec 10, 2008 3:31 PM (in response to tinydragon)That happens because panel is not rendered initially.