X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=ao-tools%2Faltosui%2FAltosChannelMenu.java;h=abbb86f43c31ea56e75b6cd6e5a48b11e18a5a24;hp=8069c8531b1c71f9a5802be9c1e3a94d23a4c352;hb=9a99cabc1c34c657fc95246192ba6d330f5f22d3;hpb=594e80572821f1848db062d0cff18ca8bf0d90ce diff --git a/ao-tools/altosui/AltosChannelMenu.java b/ao-tools/altosui/AltosChannelMenu.java index 8069c853..abbb86f4 100644 --- a/ao-tools/altosui/AltosChannelMenu.java +++ b/ao-tools/altosui/AltosChannelMenu.java @@ -30,31 +30,11 @@ import java.util.concurrent.LinkedBlockingQueue; public class AltosChannelMenu extends JComboBox implements ActionListener { int channel; - LinkedList listeners; - - public void addActionListener(ActionListener l) { - listeners.add(l); - } - - public void actionPerformed(ActionEvent e) { - channel = getSelectedIndex(); - - ActionEvent newe = new ActionEvent(this, channel, e.getActionCommand()); - - ListIterator i = listeners.listIterator(); - - while (i.hasNext()) { - ActionListener listener = i.next(); - listener.actionPerformed(newe); - } - setMaximumSize(getPreferredSize()); - } public AltosChannelMenu(int current_channel) { channel = current_channel; - listeners = new LinkedList(); for (int c = 0; c <= 9; c++) addItem(String.format("Channel %1d (%7.3fMHz)", c, 434.550 + c * 0.1)); setSelectedIndex(channel);