OpenJDK / portola / portola
changeset 5630:9606922fdd90
6888130: SwingSet2: Demo is not launching and throwing NPE.
Reviewed-by: prr
author | lana |
---|---|
date | Mon, 07 Jun 2010 15:35:36 -0700 |
parents | 41a5aa28250e |
children | cfb4f43485f3 |
files | jdk/src/share/classes/javax/swing/plaf/basic/BasicTabbedPaneUI.java |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/jdk/src/share/classes/javax/swing/plaf/basic/BasicTabbedPaneUI.java Tue Jun 01 21:36:00 2010 -0700 +++ b/jdk/src/share/classes/javax/swing/plaf/basic/BasicTabbedPaneUI.java Mon Jun 07 15:35:36 2010 -0700 @@ -3527,7 +3527,9 @@ Integer index = (Integer) e.getNewValue(); // remove the current index // to let updateHtmlViews() insert the correct one - htmlViews.removeElementAt(index); + if (htmlViews != null) { + htmlViews.removeElementAt(index); + } updateHtmlViews(index); } else if (name == "tabLayoutPolicy") { BasicTabbedPaneUI.this.uninstallUI(pane);