[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ProgSoc] Java....
> If I make a class which extends JWindow, and make it do all kinds of JButton
> stuff, etc. It works fine.
> But if I change it so it extends JPanel instead of JWindow, and then add it
> to a JWindow, nothing appears.
> (..and change all the .getContentPane().add() references to just .add() )
In the second case, i take it u r not extending 'JWindow'. Create a new
class extends JWindow and add your JPanel to that. Then somewhere in the
new JWindow constructor make sure u r calling
Otherwise nothing will come up. Also make sure ur calling
.setShowing(true) after u've added the JPanel(). That oughta do it.
You are subscribed to the progsoc mailing list. To unsubscribe, send a
message containing "unsubscribe" to email@example.com.
If you are having trouble, ask firstname.lastname@example.org for help.