JTabbedPane.setComponentAt(index, null) throws NPE

XMLWordPrintable

    • Type: Bug
    • Resolution: Duplicate
    • Priority: P4
    • None
    • Affects Version/s: 6
    • Component/s: client-libs

      JTabbedPane.setComponentAt() should be allowed to replace the component with null. Currently, if you replace a valid component with null, you get a NPE:

      Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
              at javax.swing.JTabbedPane.setComponentAt(JTabbedPane.java:1398)

      The code tries to set visibility to true and add the component even when non-null.

            Assignee:
            Shannon Hickey (Inactive)
            Reporter:
            Shannon Hickey (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: