source: subversion/applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/actions/OpenPreferencesActions.java

Last change on this file was 34452, checked in by donvip, 8 months ago

update to JOSM 14153

File size: 1.2 KB
Line 
1// License: GPL. For details, see LICENSE file.
2package org.openstreetmap.josm.plugins.opendata.core.actions;
3
4import static org.openstreetmap.josm.tools.I18n.tr;
5
6import java.awt.event.ActionEvent;
7import java.awt.event.KeyEvent;
8
9import org.openstreetmap.josm.actions.JosmAction;
10import org.openstreetmap.josm.gui.MainApplication;
11import org.openstreetmap.josm.gui.preferences.PreferenceDialog;
12import org.openstreetmap.josm.plugins.opendata.core.OdConstants;
13import org.openstreetmap.josm.plugins.opendata.core.gui.OdPreferenceSetting;
14import org.openstreetmap.josm.tools.Shortcut;
15
16public class OpenPreferencesActions extends JosmAction {
17
18    public OpenPreferencesActions() {
19        super(tr("OpenData preferences"), OdConstants.ICON_CORE_24, null,
20                Shortcut.registerShortcut("opendata_open_preferences", tr("OpenData preferences"),
21                KeyEvent.CHAR_UNDEFINED, Shortcut.NONE), true, false);
22    }
23
24    @Override
25    public void actionPerformed(ActionEvent e) {
26        final PreferenceDialog p = new PreferenceDialog(MainApplication.getMainFrame());
27        p.selectPreferencesTabByClass(OdPreferenceSetting.class);
28        p.setVisible(true);
29    }
30}
Note: See TracBrowser for help on using the repository browser.