Swap childrens widget
"abdielcs" <[email protected]> Wed, 01 Nov 2017 22:04:09 +0000
| Newsgroups | gmane.comp.java.netbeans.modules.openide.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi, I added two org.netbeans.api.visual.widget.Widget to one parent with a simple addChild(), now I try to swap it's positions. Trying with Code: Collections.swap(parent.getChildren(), index, index-1) get Code: java.lang.UnsupportedOperationException at java.util.Collections$UnmodifiableList.set(Collections.java:1311) So, seems that the list is unmodifiable. Also try with Code: parent.addChild(0, childWidget) for change the childs index and get Code: java.lang.AssertionError . So, how the childs widgets can be reordered?