Solutions to other chapters:
Java Methods A & AB:
|
1. |
JPanel none none JLabel none none JButton ActionListener none JCheckBox \ ActionListener isSelected JRadioButton | or isSelected JComboBox / ItemListener getSelectedIndex or getSelectedItem JTextField ActionListener getText JSlider ChangeListener getValue JMenuItem ActionListener none |
2. | (a) | T -- why not? It's a regular method. |
(b) | T -- this object's class must implement both
ActionListener and ItemListener interfaces and must
supply actionPerformed and itemStateChanged
methods. |
|
(c) | T -- then all of their respective actionPerformed methods
are called. |
7. | See
JM\Ch16\Exercises\Solutions\PizzaGui.java . |
Copyright © 2006 by Skylight Publishing