Ignore:
Timestamp:
2011-03-25T20:02:44+01:00 (14 years ago)
Author:
zverik
Message:

keyboard shortcuts for add, find, role (reltoolbox plugin)

Location:
applications/editors/josm/plugins/relcontext/src/relcontext/actions
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/relcontext/src/relcontext/actions/AddRemoveMemberAction.java

    r25688 r25717  
    55import static org.openstreetmap.josm.tools.I18n.tr;
    66import java.awt.event.ActionEvent;
     7import java.awt.event.KeyEvent;
    78import org.openstreetmap.josm.Main;
    89import org.openstreetmap.josm.actions.JosmAction;
     
    1415import org.openstreetmap.josm.data.osm.Way;
    1516import org.openstreetmap.josm.tools.ImageProvider;
     17import org.openstreetmap.josm.tools.Shortcut;
    1618import relcontext.ChosenRelation;
    1719import relcontext.ChosenRelationListener;
     
    2931
    3032    public AddRemoveMemberAction( ChosenRelation rel ) {
    31         super(null, "relcontext/addremove", tr("Add/remove members from the chosen relation"), null, false);
     33        super(null, "relcontext/addremove", tr("Add/remove members from the chosen relation"),
     34                Shortcut.registerShortcut("reltoolbox:addremove", tr("Relation Toolbox: {0}", tr("Add/remove members from the chosen relation")),
     35                KeyEvent.VK_EQUALS, Shortcut.GROUP_EDIT), true);
    3236        this.rel = rel;
    3337        rel.addChosenRelationListener(this);
  • applications/editors/josm/plugins/relcontext/src/relcontext/actions/FindRelationAction.java

    r25695 r25717  
    1515import org.openstreetmap.josm.gui.DefaultNameFormatter;
    1616import org.openstreetmap.josm.gui.OsmPrimitivRenderer;
     17import org.openstreetmap.josm.tools.Shortcut;
    1718import relcontext.ChosenRelation;
    1819
     
    2627
    2728    public FindRelationAction( ChosenRelation chRel ) {
    28         super("Find", "relcontext/find", "Find a relation", null, false);
     29        super("Find", "relcontext/find", tr("Find a relation"),
     30                Shortcut.registerShortcut("reltoolbox:find", tr("Relation Toolbox: {0}", tr("Find a relation")),
     31                KeyEvent.VK_F, Shortcut.GROUP_EDIT), true);
    2932        this.chRel = chRel;
    3033    }
Note: See TracChangeset for help on using the changeset viewer.