Back to index

wims  3.65+svn20090927
Public Member Functions
ptolemy.plot.PlotFrame.SpecialMenuListener Class Reference
Inheritance diagram for ptolemy.plot.PlotFrame.SpecialMenuListener:
Inheritance graph
[legend]
Collaboration diagram for ptolemy.plot.PlotFrame.SpecialMenuListener:
Collaboration graph
[legend]

List of all members.

Public Member Functions

void actionPerformed (ActionEvent e)

Detailed Description

Definition at line 586 of file PlotFrame.java.


Member Function Documentation

Definition at line 587 of file PlotFrame.java.

                                                   {
            JMenuItem target = (JMenuItem) e.getSource();
            String actionCommand = target.getActionCommand();

            try {
                if (actionCommand.equals("About")) {
                    _about();
                } else if (actionCommand.equals("Help")) {
                    _help();
                } else if (actionCommand.equals("Fill")) {
                    plot.fillPlot();
                } else if (actionCommand.equals("Reset axes")) {
                    plot.resetAxes();
                } else if (actionCommand.equals("Clear")) {
                    plot.clear(false);
                    plot.repaint();
                } else if (actionCommand.equals("Sample plot")) {
                    plot.clear(true);
                    samplePlot();
                }
            } catch (Exception exception) {
                // If we do not catch exceptions here, then they
                // disappear to stdout, which is bad if we launched
                // where there is no stdout visible.
                JOptionPane.showMessageDialog(null, "Special Menu Exception:\n"
                        + exception.toString(), "Ptolemy Plot Error",
                        JOptionPane.WARNING_MESSAGE);
            }

            // NOTE: The following should not be needed, but there jdk1.3beta
            // appears to have a bug in swing where repainting doesn't
            // properly occur.
            repaint();
        }

Here is the call graph for this function:


The documentation for this class was generated from the following file: