Questions on Swing implementation maturity via an example
Patrick
patrick@drexsuite.org
Mon May 31 01:11:00 GMT 2004
As has been pointed out to me off-list, I made two rather obvious
mistakes in my code:
(1) There is no 'this' in a static method. I should have instantiated
the class and passed that to addActionListener.
(2) I forgot to add the button to the content frame of my window by
calling getContentFrame() on the JFrame.
I seem to repeat these two mistakes each time I start a Java/Swing
application and unfortunately I quickly fired off a message to the list
rather than trying to think what the problem could be.
Apologies.
Patrick
More information about the Java
mailing list