Is it possible to pass a function/callback from javascript to a java applet?
For example i have an applet with a button that when pressed it will call the passed js callback
function onCommand() { alert('Button pressed from applet'); } applet.onCommand(onCommand);
I tend to use something I derived from the reflection example at the bottom of this page, as then you don’t need to meddle with your classpath to get it to compile
Then I just pass JSON strings around between the applet and javascript