EDIT : THIS CHANGE IS LAME, BUT IT'S NOT A BUG REGARDING ORACLE, SEE : http://www.oracle.com/technetwork/java/javase/7u21-relnotes-1932873.html
NO ONLINE DOC UPDATE, NO ANNOUNCED TRANSITION, WEB INTEGRATION MADE (LOT MORE) PAINFUL... SHOULD I PRAISE ADOBE TO TAKE ME BACK ?
The javascript object I get with document.getElementById("APPLET_ID") has no Packages attribute with JRE7u21, JRE7u40b27 and JRE8b92.
I run my tests on Windows XP, Windows7 and Ubuntu with IE8, FF and Chrome up to date.
Here is my test code :
package test;
import netscape.javascript.JSObject;
import javafx.application.Application;
import javafx.application.Platform;
import javafx.scene.Scene;
import javafx.scene.control.TextField;
import javafx.scene.layout.HBox;
import javafx.stage.Stage;
public class Main extends Application {
private JSObject js;
TextField tf;
@Override
public void start(Stage primaryStage) {
js = this.getHostServices().getWebContext();
HBox hb = new HBox();
Scene s = new Scene(hb, 400, 400);
tf = new TextField("MAIN");
primaryStage.setScene(s);
hb.getChildren().add(tf);
primaryStage.show();
runTest();
}
public static void main(String[] args) {
launch(args);
}
void runTest(){
new Thread(new Runnable() {
@Override
public void run() {
try {
Thread.sleep(5000);
} catch (InterruptedException e) {
e.printStackTrace();
}
Platform.runLater(
new Runnable() {
@Override
public void run() {
tf.setText("" + js.eval("document.getElementById('applet_id').Packages == null"));
}
}
);
}
}).start();
}
}
Displays "false" from JRE7u7 to JRE7u17 and "true" with JRE >= 7u21, with all browsers, under Windows XP, Windows 7, and Ubuntu.
NO ONLINE DOC UPDATE, NO ANNOUNCED TRANSITION, WEB INTEGRATION MADE (LOT MORE) PAINFUL... SHOULD I PRAISE ADOBE TO TAKE ME BACK ?
The javascript object I get with document.getElementById("APPLET_ID") has no Packages attribute with JRE7u21, JRE7u40b27 and JRE8b92.
I run my tests on Windows XP, Windows7 and Ubuntu with IE8, FF and Chrome up to date.
Here is my test code :
package test;
import netscape.javascript.JSObject;
import javafx.application.Application;
import javafx.application.Platform;
import javafx.scene.Scene;
import javafx.scene.control.TextField;
import javafx.scene.layout.HBox;
import javafx.stage.Stage;
public class Main extends Application {
private JSObject js;
TextField tf;
@Override
public void start(Stage primaryStage) {
js = this.getHostServices().getWebContext();
HBox hb = new HBox();
Scene s = new Scene(hb, 400, 400);
tf = new TextField("MAIN");
primaryStage.setScene(s);
hb.getChildren().add(tf);
primaryStage.show();
runTest();
}
public static void main(String[] args) {
launch(args);
}
void runTest(){
new Thread(new Runnable() {
@Override
public void run() {
try {
Thread.sleep(5000);
} catch (InterruptedException e) {
e.printStackTrace();
}
Platform.runLater(
new Runnable() {
@Override
public void run() {
tf.setText("" + js.eval("document.getElementById('applet_id').Packages == null"));
}
}
);
}
}).start();
}
}
Displays "false" from JRE7u7 to JRE7u17 and "true" with JRE >= 7u21, with all browsers, under Windows XP, Windows 7, and Ubuntu.