aboutsummaryrefslogtreecommitdiffstats
path: root/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java
diff options
context:
space:
mode:
Diffstat (limited to 'netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java')
-rw-r--r--netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java b/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java
index 993bf50..321e18e 100644
--- a/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java
+++ b/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java
@@ -207,6 +207,20 @@ public class AppletEnvironment implements AppletContext, AppletStub {
}
/**
+ * Set the applet of this environment; can only be called once.
+ */
+ public void setApplet(Applet applet) {
+ if (this.applet != null) {
+ if (JNLPRuntime.isDebug()) {
+ Exception ex = new IllegalStateException("Applet can only be set once.");
+ ex.printStackTrace();
+ }
+ return;
+ }
+ this.applet = applet;
+ }
+
+ /**
* Returns an enumeration that contains only the applet
* from the JNLP file.
*/