001package jmri.jmrit.operations.rollingstock.cars.tools;
002
003import java.awt.event.ActionEvent;
004
005import javax.swing.AbstractAction;
006import javax.swing.JTable;
007
008/**
009 * Swing action to create and register a CarsSetFrame object.
010 *
011 * @author Bob Jacobsen Copyright (C) 2001
012 * @author Daniel Boudreau Copyright (C) 2010
013 */
014public class CarsSetFrameAction extends AbstractAction {
015
016    JTable _carsTable;
017
018    public CarsSetFrameAction(JTable carsTable) {
019        super(Bundle.getMessage("TitleSetCars"));
020        _carsTable = carsTable;
021    }
022
023    @Override
024    public void actionPerformed(ActionEvent e) {
025        // create a car table frame
026        CarsSetFrame csf = new CarsSetFrame();
027        csf.initComponents(_carsTable);
028    }
029}
030
031