As reported in this forum post:
"I'm trying to develop a JavaFX web page loader. I want to explore the DOM tree after page loading, so I load the DOM after I receive a Worker State SUCCEEDED, but the problem in that when I test my code on the url: www.repubblica.it, I got SUCCEEDED but the DOM is still null.
It seems to be that the page is not completely loaded although I got the SUCCEEDED event.
This is the piece of code that fails:
webEngine.getLoadWorker().stateProperty().addListener(new ChangeListener<Worker.State>() {
@Override
public void changed(ObservableValue ov, Worker.State oldState, Worker.State newState) {
if (newState == Worker.State.SUCCEEDED) {
webEngine.getDocument(); // On www.repubblica.it dom is still null
}
}
});
"
"I'm trying to develop a JavaFX web page loader. I want to explore the DOM tree after page loading, so I load the DOM after I receive a Worker State SUCCEEDED, but the problem in that when I test my code on the url: www.repubblica.it, I got SUCCEEDED but the DOM is still null.
It seems to be that the page is not completely loaded although I got the SUCCEEDED event.
This is the piece of code that fails:
webEngine.getLoadWorker().stateProperty().addListener(new ChangeListener<Worker.State>() {
@Override
public void changed(ObservableValue ov, Worker.State oldState, Worker.State newState) {
if (newState == Worker.State.SUCCEEDED) {
webEngine.getDocument(); // On www.repubblica.it dom is still null
}
}
});
"
- relates to
-
JDK-8088348 MiscellaneousTest.testRT30835 is failing again, this time on Windows
-
- Open
-