swingx
  1. swingx
  2. SWINGX-1356

JXComboBox: throw NPE on toggling LAF

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 1.6.2
    • Fix Version/s: 1.6.3
    • Component/s: Misc Component
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      1,356

      Description

      (don't know since when - reporting from Eclipse-Mylyn, where most current version is 1.6.1++
      which probably needs updating, either locally only or in the tracker)

      or fails silently - f.i. arrowbutton not showing

      to reproduce NPE, run JXComboBoxVisualCheck and toggle LAF

      start of stacktrace (when starting with metal, toggle to motif, f.i.)
      Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
      at com.sun.java.swing.plaf.motif.MotifComboBoxUI.iconAreaWidth(MotifComboBoxUI.java:228)
      at com.sun.java.swing.plaf.motif.MotifComboBoxUI.rectangleForCurrentValue(MotifComboBoxUI.java:211)
      at com.sun.java.swing.plaf.motif.MotifComboBoxUI.paint(MotifComboBoxUI.java:128)
      at javax.swing.plaf.ComponentUI.update(ComponentUI.java:143)
      at javax.swing.JComponent.paintComponent(JComponent.java:752)
      at javax.swing.JComponent.paint(JComponent.java:1029)

        Activity

        Hide
        Karl Schaefer added a comment -

        Issue 1356: Ensure that the we do not query the UI delegate during update.
        Prevents the NPE, which was caused because we accessed the UI delegate during
        update prior to complete configuration of the delegate.

        swingx-core/src/main/java/org/jdesktop/swingx/JXComboBox.java

        Committed revision 3890.

        Show
        Karl Schaefer added a comment - Issue 1356: Ensure that the we do not query the UI delegate during update. Prevents the NPE, which was caused because we accessed the UI delegate during update prior to complete configuration of the delegate. swingx-core/src/main/java/org/jdesktop/swingx/JXComboBox.java Committed revision 3890.

          People

          • Assignee:
            Karl Schaefer
            Reporter:
            kleopatra
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: