Using the applet itself as a method argument (JavaScript to Java)