1
2
3
4
5
6
7
8
9
10 package nl.tudelft.simulation.dsol.gui.animation2D.actions;
11
12 import java.awt.event.ActionEvent;
13
14 import javax.swing.AbstractAction;
15
16 import nl.tudelft.simulation.introspection.gui.IntroSpectionDialog;
17
18 /***
19 * <p>
20 * (c) copyright 2002-2005 <a href="http://www.simulation.tudelft.nl">Delft
21 * University of Technology </a>, the Netherlands. <br>
22 * See for project information <a
23 * href="http://www.simulation.tudelft.nl">www.simulation.tudelft.nl </a> <br>
24 * License of use: <a href="http://www.gnu.org/copyleft/lesser.html">Lesser
25 * General Public License (LGPL) </a>, no warranty.
26 *
27 * @author <a href="http://www.tbm.tudelft.nl/webstaf/peterja/index.htm">Peter
28 * Jacobs </a>
29 *@version $Revision$ $Date$
30 * @since 1.4
31 */
32 public class IntrospectionAction extends AbstractAction
33 {
34 /*** the target to introspect */
35 private Object target = null;
36
37 /***
38 * constructs a new IntrospectionAction
39 *
40 * @param target the target to introspect
41 */
42 public IntrospectionAction(final Object target)
43 {
44 super(target.toString());
45 this.target = target;
46 }
47
48 /***
49 * @see java.awt.event.ActionListener#actionPerformed(java.awt.event.ActionEvent)
50 */
51 public void actionPerformed(final ActionEvent e)
52 {
53 new IntroSpectionDialog(this.target);
54 }
55 }