source: josm/trunk/src/org/openstreetmap/josm/actions/HistoryInfoAction.java@ 2001

Last change on this file since 2001 was 1697, checked in by Gubaer, 15 years ago

#2779: patch by avar (slightly refactored in order to avoid duplicated code)

File size: 938 bytes
Line 
1//License: GPL. Copyright 2007 by Immanuel Scholz and others
2package org.openstreetmap.josm.actions;
3
4import static org.openstreetmap.josm.tools.I18n.tr;
5
6import java.awt.event.KeyEvent;
7
8import org.openstreetmap.josm.data.osm.OsmPrimitive;
9import org.openstreetmap.josm.data.osm.OsmPrimitiveType;
10import org.openstreetmap.josm.tools.Shortcut;
11
12public class HistoryInfoAction extends AbstractInfoAction {
13
14 public HistoryInfoAction() {
15 super(tr("History of Element"), "about",
16 tr("Display history information about OSM ways, nodes, or relations."),
17 Shortcut.registerShortcut("core:history",
18 tr("History of Element"), KeyEvent.VK_H, Shortcut.GROUP_HOTKEY), true);
19 }
20
21 @Override
22 protected String createInfoUrl(OsmPrimitive primitive) {
23 return getBaseURL() + "/" + OsmPrimitiveType.from(primitive).getAPIName() + "/" + primitive.id + "/history";
24 }
25}
Note: See TracBrowser for help on using the repository browser.