Changeset 11974 in osm for applications/editors/josm/plugins/livegps
- Timestamp:
- 2008-11-18T20:04:58+01:00 (16 years ago)
- Location:
- applications/editors/josm/plugins/livegps/livegps
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/livegps/livegps/LiveGpsDialog.java
r11934 r11974 19 19 import org.openstreetmap.josm.gui.MapFrame; 20 20 import org.openstreetmap.josm.gui.dialogs.ToggleDialog; 21 import org.openstreetmap.josm.tools.Short Cut;21 import org.openstreetmap.josm.tools.Shortcut; 22 22 23 23 /** … … 39 39 * @param iconName 40 40 * @param tooltip 41 * @param short Cut41 * @param shortcut 42 42 * @param preferredHeight 43 43 */ 44 44 public LiveGpsDialog(final MapFrame mapFrame) { 45 45 super(tr("Live GPS"), "livegps", tr("Show GPS data."), 46 Short Cut.registerShortCut("subwindow:livegps", tr("Toggle: {0}", tr("Live GPS")),47 KeyEvent.VK_G, Short Cut.GROUP_LAYER, ShortCut.SHIFT_DEFAULT), 100);46 Shortcut.registerShortcut("subwindow:livegps", tr("Toggle: {0}", tr("Live GPS")), 47 KeyEvent.VK_G, Shortcut.GROUP_LAYER, Shortcut.SHIFT_DEFAULT), 100); 48 48 panel = new JPanel(); 49 49 panel.setLayout(new GridLayout(6,2)); -
applications/editors/josm/plugins/livegps/livegps/LiveGpsPlugin.java
r11934 r11974 20 20 import org.openstreetmap.josm.gui.MapFrame; 21 21 import org.openstreetmap.josm.plugins.Plugin; 22 import org.openstreetmap.josm.tools.Short Cut;22 import org.openstreetmap.josm.tools.Shortcut; 23 23 24 24 public class LiveGpsPlugin extends Plugin … … 40 40 public CaptureAction() { 41 41 super(tr("Capture GPS Track"), "capturemenu", tr("Connect to gpsd server and show current position in LiveGPS layer."), 42 Short Cut.registerShortCut("menu:livegps:capture", tr("Menu: {0}", tr("Capture GPS Track")),43 KeyEvent.VK_R, Short Cut.GROUP_MENU), true);42 Shortcut.registerShortcut("menu:livegps:capture", tr("Menu: {0}", tr("Capture GPS Track")), 43 KeyEvent.VK_R, Shortcut.GROUP_MENU), true); 44 44 } 45 45 … … 52 52 public CenterAction() { 53 53 super(tr("Center Once"), "centermenu", tr("Center the LiveGPS layer to current position."), 54 Short Cut.registerShortCut("edit:centergps", tr("Edit: {0}", tr("Center Once")),55 KeyEvent.VK_HOME, Short Cut.GROUP_EDIT), true);54 Shortcut.registerShortcut("edit:centergps", tr("Edit: {0}", tr("Center Once")), 55 KeyEvent.VK_HOME, Shortcut.GROUP_EDIT), true); 56 56 } 57 57 … … 66 66 public AutoCenterAction() { 67 67 super(tr("Auto-Center"), "autocentermenu", tr("Continuously center the LiveGPS layer to current position."), 68 Short Cut.registerShortCut("menu:livegps:autocenter", tr("Menu: {0}", tr("Capture GPS Track")),69 KeyEvent.VK_HOME, Short Cut.GROUP_MENU), true);68 Shortcut.registerShortcut("menu:livegps:autocenter", tr("Menu: {0}", tr("Capture GPS Track")), 69 KeyEvent.VK_HOME, Shortcut.GROUP_MENU), true); 70 70 } 71 71 … … 87 87 lgpscapture = new JCheckBoxMenuItem(captureAction); 88 88 lgpsmenu.add(lgpscapture); 89 lgpscapture.setAccelerator(captureAction.getShort Cut().getKeyStroke());89 lgpscapture.setAccelerator(captureAction.getShortcut().getKeyStroke()); 90 90 91 91 JosmAction centerAction = new CenterAction(); 92 92 JMenuItem centerMenu = new JMenuItem(centerAction); 93 93 lgpsmenu.add(centerMenu); 94 centerMenu.setAccelerator(centerAction.getShort Cut().getKeyStroke());94 centerMenu.setAccelerator(centerAction.getShortcut().getKeyStroke()); 95 95 96 96 JosmAction autoCenterAction = new AutoCenterAction(); 97 97 lgpsautocenter = new JCheckBoxMenuItem(autoCenterAction); 98 98 lgpsmenu.add(lgpsautocenter); 99 lgpsautocenter.setAccelerator(autoCenterAction.getShort Cut().getKeyStroke());99 lgpsautocenter.setAccelerator(autoCenterAction.getShortcut().getKeyStroke()); 100 100 } 101 101
Note:
See TracChangeset
for help on using the changeset viewer.