Reputation: 50117
Given a JApplet, how do I obtain the JFrame object corresponding to this applet?
JApplet applet = this;
JRootPane rootPane = getRootPane();
Container contentPane = getContentPane();
JFrame jframe = ...; // How do I obtain the JFrame?
Upvotes: 0
Views: 868
Reputation: 35246
You can create a new JFrame from an Applet. But there is no container like a JFrame surrounding an Applet. The Applet is ths container.
Upvotes: 3