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

NPE in Labeled when setGraphic() is called on a TitledPane

XMLWordPrintable


      Calling setGraphic(new Label("TEST")) on a TitledPane *when it is already displayed* raise the following NPE :

      java.lang.NullPointerException
      at com.sun.javafx.scene.control.skin.LabeledImpl$1.invalidated(LabeledImpl.java:110)
      at com.sun.javafx.binding.ExpressionHelper$SingleInvalidation.fireValueChangedEvent(ExpressionHelper.java:134)
      at com.sun.javafx.binding.ExpressionHelper.fireValueChangedEvent(ExpressionHelper.java:79)
      at javafx.beans.property.ObjectPropertyBase.fireValueChangedEvent(ObjectPropertyBase.java:102)
      at javafx.beans.property.ObjectPropertyBase.markInvalid(ObjectPropertyBase.java:109)
      at javafx.beans.property.ObjectPropertyBase.set(ObjectPropertyBase.java:142)
      at javafx.beans.property.ObjectProperty.setValue(ObjectProperty.java:63)
      at javafx.scene.control.Labeled.setGraphic(Labeled.java:320)

            kwwong Kinsley Wong (Inactive)
            jcambon Jerome Cambon
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: