Hi Bernd,
I guess I found a problem in LayoutUtil (not sure if the root of the
problem is another one). When adding the children the lines containing
comments are considered components. If you skip these (using
child.isTransient()) the layout seems to be correct (I will have to test
with a more complex example).
See the attached diff for LayoutUtil.
Regards,
Stefan.
Stefan Hedtfeld schrieb:
Hello Bernd,
I've attached the files - home.xhtml is in dir "app" and the others
are in "templates". The only bean used so far is clientConfiguration
which returns a Locale in its locale property (you can skip this).
I took a look in the GridLayoutManager tests, but that's how I thought
the layout manager would look like. My guess is that the cause of the
problem is somewhere up the stack - before the layout manager is
started. I'm not sure how the layout facet's subelements are
interpreted. Maybe that's where it starts to go wrong.
I'll try to debug my application during processing the layout and
become wiser :)
Best regards,
Stefan.
Bernd Bohmann schrieb:
Hello Stefan,
can you attach an example page, please.
I will ask Udo for some information about the new layout management in
Tobago. Maybe the Unit-Tests in
core/src/test/java/org/apache/myfaces/tobago/layout/grid
provides some information.
Regards
Bernd
Index: core/src/main/java/org/apache/myfaces/tobago/util/LayoutUtil.java
===================================================================
--- core/src/main/java/org/apache/myfaces/tobago/util/LayoutUtil.java (Revision 712553)
+++ core/src/main/java/org/apache/myfaces/tobago/util/LayoutUtil.java (Arbeitskopie)
@@ -163,6 +163,9 @@
public static List<UIComponent> addChildren(List<UIComponent> children, UIComponent panel) {
for (Object o : panel.getChildren()) {
UIComponent child = (UIComponent) o;
+ if (child.isTransient()) {
+ continue;
+ }
if (isTransparentForLayout(child)) {
addChildren(children, child);
} else {