Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Applet  RSS feed

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is the difference between inheriting from Applet and JApplet?
 
Shriram Shivakumar
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JApplet is the JFC version of the Java AWT applet.
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The JApplet adds support for the swing component architechture.
The difference b/w Applet and JApplet is as follows :
the JApplet has the JRootPane as the only child. Therefore any child that has to be added to JApplet should be added to it.
ex: applet.getContentPane().add(child).
whereas in applet u could directly add it to the applet
ex: applet.add(child).
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!