aboutsummaryrefslogtreecommitdiffstats
path: root/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
diff options
context:
space:
mode:
Diffstat (limited to 'plugin/icedteanp/java/sun/applet/PluginAppletViewer.java')
-rw-r--r--plugin/icedteanp/java/sun/applet/PluginAppletViewer.java14
1 files changed, 8 insertions, 6 deletions
diff --git a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
index 7742035..cfa3109 100644
--- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
+++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
@@ -115,6 +115,7 @@ import net.sourceforge.jnlp.security.appletextendedsecurity.ExecuteUnsignedApple
import net.sourceforge.jnlp.splashscreen.SplashController;
import net.sourceforge.jnlp.splashscreen.SplashPanel;
import net.sourceforge.jnlp.splashscreen.SplashUtils;
+import netscape.javascript.JSObject;
import sun.awt.AppContext;
import sun.awt.SunToolkit;
import sun.awt.X11.XEmbeddedFrame;
@@ -903,18 +904,19 @@ public class PluginAppletViewer extends XEmbeddedFrame
return v.elements();
}
- /**
- * Ignore.
- */
public void showDocument(URL url) {
PluginDebug.debug("Showing document...");
showDocument(url, "_self");
}
- /**
- * Ignore.
- */
public void showDocument(URL url, String target) {
+ // If it is a javascript document, eval on current page.
+ if ("javascript".equals(url.getProtocol())) {
+ // Snip protocol off string
+ String evalString = url.toString().substring("javascript:".length());
+ eval(getWindow(), evalString);
+ return;
+ }
try {
Long reference = getRequestIdentifier();
write("reference " + reference + " LoadURL " + UrlUtil.encode(url.toString(), "UTF-8") + " " + target);