|
From: Peter De B. (JIRA) <no...@sp...> - 2008-01-29 12:03:49
|
[ http://jira.springframework.org/browse/RCP-528?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_31366 ]
Peter De Bruycker commented on RCP-528:
---------------------------------------
can you specify what exceptions are thrown?
I'm trying to reproduce this behaviour, but I'm not having any problems:
<code>
public class ExtTabbedPaneTest implements Runnable {
public static void main(String[] args) {
SwingUtilities.invokeLater(new ExtTabbedPaneTest());
}
public void run() {
JFrame frame = new JFrame("test");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
final ExtTabbedPane tabbedPane = new ExtTabbedPane();
tabbedPane.addTab(new Tab("test", new JLabel("test")));
tabbedPane.addTab(new Tab("test2", new JLabel("test2")));
tabbedPane.addTab(new Tab("test3", new JLabel("test3")));
frame.add(tabbedPane.getControl(), BorderLayout.CENTER);
JButton btn = new JButton("test");
btn.addActionListener(new ActionListener() {
int counter = 4;
public void actionPerformed(ActionEvent e) {
Tab tab = new Tab("test" + counter, new JLabel("test" + counter));
tabbedPane.addTab(tab);
tabbedPane.selectTab(tab);
counter++;
}
});
frame.add(btn, BorderLayout.SOUTH);
frame.pack();
frame.setLocationRelativeTo(null);
frame.setVisible(true);
}
}
</code>
Perhaps you can modify the above code to demonstrate the problem. That would even be beter.
Thanks,
Peter
> Prepare ExtTabbedPane for late addition of tabs
> -----------------------------------------------
>
> Key: RCP-528
> URL: http://jira.springframework.org/browse/RCP-528
> Project: Spring Framework Rich Client Project
> Issue Type: Improvement
> Affects Versions: 1.0.0
> Reporter: Johannes Schneider
> Assignee: Peter De Bruycker
> Attachments: allows_the_late_addition_of_tabs_.patch
>
>
> adding a tab when the pane is shown results in exceptions.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.springframework.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
|