/** * File menu for the MainView's menubar. * * @author Eric Liebowitz * @version 23jun11 */ package simple_uml.view; import javax.swing.*; import java.awt.*; import java.awt.event.*; public class EditMenu extends JMenu { public EditMenu () { super ("Edit"); addPreferences(); } /** * Adds a "Preferences" option to the menu. The window subsequently displayed * will allow the user to customize various attributes of the program. */ private void addPreferences () { this.add(new JMenuItem("Preferences...")).addActionListener ( new ActionListener () { public void actionPerformed (ActionEvent ae) { System.out.println ("Preferring..."); } } ); } }