Sorry levent, I just didn't realise about the tags, my browser seems to find the code and tag it anyway, which is odd.
The method Card() is in the class Card and goes like this:
public Card() {
setLayout(cards);
ActionListener listener = new ActionListener() {
public void actionPerformed(ActionEvent e) {
cards.next(Card.this);
}
};
JButton button;
button = new JButton("one");
button.addActionListener(listener);
add(button, "one");
button = new JButton("two");
button.addActionListener(listener);
add(button, "two");
button = new JButton("three");
button.addActionListener(listener);
add(button, "three");
}
All my attempts to call this method have failed.