001package jmri.jmrix.openlcb.swing.protocoloptions;
002
003import java.awt.event.ActionEvent;
004
005import javax.swing.AbstractAction;
006
007import jmri.jmrix.can.CanSystemConnectionMemo;
008import jmri.util.JmriJFrame;
009
010/**
011 * Invokeable action to open the protocol settings frame.
012 *
013 * @author Balazs Racz, (C) 2018.
014 */
015
016class ProtocolOptionsAction extends AbstractAction {
017
018    final CanSystemConnectionMemo sc;
019
020    ProtocolOptionsAction(CanSystemConnectionMemo sc) {
021        super(Bundle.getMessage("WindowTitle"));
022        this.sc = sc;
023    }
024
025    @Override
026    public void actionPerformed(ActionEvent actionEvent) {
027        JmriJFrame f = new ProtocolOptionsFrame(sc);
028        f.initComponents();
029        f.setVisible(true);
030    }
031}