R
Richard
I have a JFrame that creates an instance of a class that is a
subclass, of an abstract class, that is itself a subclass of JPanel.
What I am trying to do is to add a button in the abstract classand
then when it is clicked to go to a listener in the Jframe.
Normally I would use
myButton.addActionListener(this);
but it does not even allow me to use this method, but this would not
do what I want anyway. I think I am using the correct imports:
import javax.swing.*;
import java.awt.*;
import java.lang.*;
import java.awt.event.*;
import javax.swing.event.*;
Any help would be greatly received.
Thanks
subclass, of an abstract class, that is itself a subclass of JPanel.
What I am trying to do is to add a button in the abstract classand
then when it is clicked to go to a listener in the Jframe.
Normally I would use
myButton.addActionListener(this);
but it does not even allow me to use this method, but this would not
do what I want anyway. I think I am using the correct imports:
import javax.swing.*;
import java.awt.*;
import java.lang.*;
import java.awt.event.*;
import javax.swing.event.*;
Any help would be greatly received.
Thanks