-
Bug
-
Resolution: Duplicate
-
P3
-
None
-
jfx11, jfx12, jfx15, jfx16
-
generic
-
generic
A DESCRIPTION OF THE PROBLEM :
The method always fails due to throwing hardcoded exception
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Calling TextAreaSkin.dispose() directly, or by calling textArea.setSkin(null or some skin)
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Should never fail
ACTUAL -
Always fails
---------- BEGIN SOURCE ----------
import javafx.application.Application;
import javafx.application.Platform;
import javafx.scene.Scene;
import javafx.scene.control.TextArea;
import javafx.scene.layout.StackPane;
import javafx.stage.Stage;
/** Showcasing javafx bug */
class JavaFxBugTextAreaDispose extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage stage) {
final TextArea textArea = new TextArea();
final StackPane background = new StackPane(textArea);
final Scene scene = new Scene(background, 600, 500);
stage.setScene(scene);
stage.show();
Platform.runLater(() -> {
background.getChildren().clear();
textArea.setSkin(null);
});
}
}
---------- END SOURCE ----------
FREQUENCY : always
The method always fails due to throwing hardcoded exception
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Calling TextAreaSkin.dispose() directly, or by calling textArea.setSkin(null or some skin)
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Should never fail
ACTUAL -
Always fails
---------- BEGIN SOURCE ----------
import javafx.application.Application;
import javafx.application.Platform;
import javafx.scene.Scene;
import javafx.scene.control.TextArea;
import javafx.scene.layout.StackPane;
import javafx.stage.Stage;
/** Showcasing javafx bug */
class JavaFxBugTextAreaDispose extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage stage) {
final TextArea textArea = new TextArea();
final StackPane background = new StackPane(textArea);
final Scene scene = new Scene(background, 600, 500);
stage.setScene(scene);
stage.show();
Platform.runLater(() -> {
background.getChildren().clear();
textArea.setSkin(null);
});
}
}
---------- END SOURCE ----------
FREQUENCY : always
- duplicates
-
JDK-8244419 TextAreaSkin: throws UnsupportedOperation on dispose
- Resolved