Last change
on this file since 729 was 655, checked in by ramack, 16 years ago |
patch by bruce89, closes #812; thanks bruce
|
-
Property svn:eol-style
set to
native
|
File size:
752 bytes
|
Line | |
---|
1 | // License: GPL. Copyright 2007 by Immanuel Scholz and others
|
---|
2 | package org.openstreetmap.josm.actions;
|
---|
3 |
|
---|
4 | import static org.openstreetmap.josm.tools.I18n.tr;
|
---|
5 |
|
---|
6 | import java.awt.event.ActionEvent;
|
---|
7 | import java.awt.event.InputEvent;
|
---|
8 | import java.awt.event.KeyEvent;
|
---|
9 |
|
---|
10 | import org.openstreetmap.josm.Main;
|
---|
11 |
|
---|
12 |
|
---|
13 | /**
|
---|
14 | * Redoes the last command.
|
---|
15 | *
|
---|
16 | * @author imi
|
---|
17 | */
|
---|
18 | public class RedoAction extends JosmAction {
|
---|
19 |
|
---|
20 | /**
|
---|
21 | * Construct the action with "Redo" as label.
|
---|
22 | */
|
---|
23 | public RedoAction() {
|
---|
24 | super(tr("Redo"), "redo", tr("Redo the last undone action."), KeyEvent.VK_Y, InputEvent.CTRL_DOWN_MASK, true);
|
---|
25 | setEnabled(false);
|
---|
26 | }
|
---|
27 |
|
---|
28 | public void actionPerformed(ActionEvent e) {
|
---|
29 | if (Main.map == null)
|
---|
30 | return;
|
---|
31 | Main.map.repaint();
|
---|
32 | Main.main.undoRedo.redo();
|
---|
33 | }
|
---|
34 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.