source: josm/src/org/openstreetmap/josm/actions/RedoAction.java@ 104

Last change on this file since 104 was 104, checked in by imi, 18 years ago
  • started i18n
  • started "download incomplete ways" action
  • added straight line selection mode
File size: 826 bytes
Line 
1package org.openstreetmap.josm.actions;
2
3import static org.openstreetmap.josm.tools.I18n.tr;
4
5import java.awt.event.ActionEvent;
6import java.awt.event.InputEvent;
7import java.awt.event.KeyEvent;
8
9import javax.swing.KeyStroke;
10
11import org.openstreetmap.josm.Main;
12
13
14/**
15 * Redoes the last command.
16 *
17 * @author imi
18 */
19public class RedoAction extends JosmAction {
20
21 /**
22 * Construct the action with "Undo" as label.
23 */
24 public RedoAction() {
25 super(tr("Redo"), "redo", tr("Redo the last undone action."), tr("Ctrl-Shift-Z"), KeyStroke.getKeyStroke(KeyEvent.VK_Z, InputEvent.CTRL_DOWN_MASK | InputEvent.SHIFT_DOWN_MASK));
26 setEnabled(false);
27 }
28
29 public void actionPerformed(ActionEvent e) {
30 if (Main.map == null)
31 return;
32 Main.map.repaint();
33 Main.main.editLayer().redo();
34 }
35}
Note: See TracBrowser for help on using the repository browser.