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

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

Improved help browser layout (now uses custom CSS shipped with JOSM)
Help browser now in separate process, not blocked any more when invoked from modal dialogs in JOSM
Added standard browser actions (home, prev, next) etc.
Added help support for conflict resolution

File size: 995 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("Object history"), "about",
16 tr("Display history information about OSM ways, nodes, or relations."),
17 Shortcut.registerShortcut("core:history",
18 tr("Object history"), KeyEvent.VK_H, Shortcut.GROUP_HOTKEY), true);
19 }
20
21 @Override
22 protected String createInfoUrl(Object infoObject) {
23 OsmPrimitive primitive = (OsmPrimitive)infoObject;
24 return getBaseBrowseUrl() + "/" + OsmPrimitiveType.from(primitive).getAPIName() + "/" + primitive.getId() + "/history";
25 }
26}
Note: See TracBrowser for help on using the repository browser.