-
Type:
Bug
-
Resolution: Fixed
-
Priority:
P2
-
Affects Version/s: 6
-
Component/s: client-libs
-
b36
-
generic
-
generic
-
Verified
Adding a tab component that is already a child of the JTabbedPane throws StackOverFlowException.
If I use
JCheckBox checkBox = new JCheckBox("I am check Box", true);
checkBox.setOpaque(false);
tabbedPane.add("Title", checkBox);
tabbedPane.setTabComponentAt(0, checkBox);
I get an StackOverFlowException.
We should throw an IllegalArgumentException from setTabComponentAt() if the user attempts to add a tab component that is already a child of the JTabbedPane.
###@###.### 2005-04-10 08:59:56 GMT
If I use
JCheckBox checkBox = new JCheckBox("I am check Box", true);
checkBox.setOpaque(false);
tabbedPane.add("Title", checkBox);
tabbedPane.setTabComponentAt(0, checkBox);
I get an StackOverFlowException.
We should throw an IllegalArgumentException from setTabComponentAt() if the user attempts to add a tab component that is already a child of the JTabbedPane.
###@###.### 2005-04-10 08:59:56 GMT