Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-5096948

1.5.0 Regression: NPE when switching from Metal L&F with JComboBox

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 5.0
    • Fix Version/s: 5.0u1
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      beta
    • CPU:
      x86
    • OS:
      windows_nt

      Backports

        Description

        Bug 4864304 made various performance enhancements to Swing. One of the things it did was to allow null for the horizontal scroll bar of a JScrollPane. It then changed BasicComboPopup to set the horizontal scrollbar of the scrollpane to null.

        After this fix, when using a JComboBox to switch the look and feel from Metal, a NullPointerException is thrown from MetalScrollPaneUI.uninstallUI (which doesn't check for null). A test case is attached (JSliderTest.java). Run it, and switch to another L&F.

        Note: I have another test case which does something similar (ListTest.java), but it isn't affected. I don't know why - could this be timing related?

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                svioletsunw Scott Violet (Inactive)
                Reporter:
                shickeysunw Shannon Hickey (Inactive)
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: