javaFX in e4 vs Java application [message #1308936] |
Tue, 22 April 2014 07:13  |
Eclipse User |
|
|
|
I am using e4 Kepler (not e(fx) for this particular application).
I am using the SwtJavaFxInteroperabilityDemo as a test of a javaFX component embedded in a SWT application (http://www.javaworld.com/article/2074496/core-java/integrating-javafx-2-0-with-swing-and-swt.html).
I created a plugin project and ran fine using jdk1.7 + plugin from existing jar (jfxswt.jar) or using jdk1.8.
I then modified the plugin to accept a Composite, that was passed in from an e4 application:
public class SwtJavaFxInteroperabilityTrial {
public void showFxCanvas(Composite comp) {
final Shell shell = comp.getShell();
shell.setText("JavaFX / SWT Integration");
shell.setLayout(new FillLayout());
final FXCanvas canvas = new FXCanvas(shell, SWT.NONE);
final Scene scene = TextIntegrationSceneCreator.createTextScene();
canvas.setScene(scene);
shell.open();
}
}
When I then tried running the class, the e4 DefaultClassLoader could not find the FXCanvas class. (I tried using JDK1.8 for both e4 app and javafx plugin, and jdk1.7 + plugin from existing jar (jfxswt.jar)).
How can I get the e4 class loader to recognize javafx.embed.swt.FXCanvas?
Cheers
Don
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.07098 seconds