R
raj_indian_sikh
import java.awt.event.*;
import javax.swing.*;
public class demo extends JPanel
implements
ActionListener {
public static void main(String[] args) {
JPanel cb2 = new demo();
}//main
}//end class
this is working .why?
demo is JPanel.OK but it is also
implementing ActionListener.then how can we
write JPanel on right hand side of cb2.
import javax.swing.*;
public class demo extends JPanel
implements
ActionListener {
public static void main(String[] args) {
JPanel cb2 = new demo();
}//main
}//end class
this is working .why?
demo is JPanel.OK but it is also
implementing ActionListener.then how can we
write JPanel on right hand side of cb2.