Forum
Mon, 22 Aug 2005 12:37:06 -0700
Hello,
I think swixml doesn't work properly with JDK 5.0.
I have modified Parser.java to detect RootPaneContainer when we want to
get LayoutManager.
Before this patch, i can't change layout on frame, after there is no probleme.
--- swixml_144/src/org/swixml/Parser.java 2005-06-04 15:25:36.000000000
+0200
+++ swixml_144.patch/src/org/swixml/Parser.java 2005-08-03 22:24:13.000000000
+0200
@@ -518,7 +518,15 @@
// process child tags
//
- LayoutManager layoutMgr = obj instanceof Container ? ((Container)
obj).getLayout() : null;
+// BB patch //
+ LayoutManager layoutMgr = null;
+ if(obj instanceof RootPaneContainer){
+ layoutMgr = ((RootPaneContainer)obj).getContentPane().getLayout();
+ } else if (obj instanceof Container){
+ layoutMgr = ((Container) obj).getLayout();
+ }
+// LayoutManager layoutMgr = obj instanceof Container ? ((Container)
obj).getLayout() : null;
+// BB patch //
Iterator it = element.getChildren().iterator();
while (it != null && it.hasNext()) {
--
Benjamin
--------------------
email: [EMAIL PROTECTED] () campagne du ruban ascii
http://www.codelutin.com /\ pour les mails en ascii
_______________________________________________
Forum mailing list
Forum@carlsbadcubes.com
http://carlsbadcubes.com/mailman/listinfo/forum_carlsbadcubes.com