-
Bug
-
Resolution: Fixed
-
P2
-
1.2.0
-
swing0.8
-
sparc
-
solaris_2.5.1
-
Verified
Name: akC57697 Date: 11/20/97
The java.awt.swing.JSeparator.getUI() always returns null.
This happens because JSeparator.getUI() returns a value of
protected SeparatorUI ui field which is overriden and not
initialized in this class.
-------------------Example-----------------------------------
import com.sun.java.swing.*;
public class JSeparatorUITest {
public static void main( String argv[] ) {
JSeparator s = new JSeparator();
s.updateUI();
s.getUI().getMinimumSize(s); // Try to work with the UI
}
}
-------------------Output------------------------------------
(novo35 57): java -fullversion
java full version "JDK1.2U"
(novo35 58): javac JSeparatorUITest.java
(novo35 59): java JSeparatorUITest
java.lang.NullPointerException
at JSeparatorUITest.main(JSeparatorUITest.java:7)
======================================================================