2
* Created on 27.03.2005
2
GanttProject is an opensource project management tool.
3
Copyright (C) 2005-2011 GanttProject Team
5
This program is free software; you can redistribute it and/or
6
modify it under the terms of the GNU General Public License
7
as published by the Free Software Foundation; either version 3
8
of the License, or (at your option) any later version.
10
This program is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY; without even the implied warranty of
12
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
GNU General Public License for more details.
15
You should have received a copy of the GNU General Public License
16
along with this program; if not, write to the Free Software
17
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
4
19
package net.sourceforge.ganttproject.action;
21
import java.awt.event.ActionEvent;
24
* Default cancel action for dialogs.
25
* {@link UIFacade#createDialog(java.awt.Component, javax.swing.Action[], String)}
26
* adds additional/special functionalities for this action
9
public abstract class CancelAction extends GPAction {
28
public class CancelAction extends GPAction {
29
/** CancelAction which does not do anything */
30
public final static CancelAction EMPTY = new CancelAction();
32
public static final CancelAction CLOSE = new CancelAction("close");
10
34
public CancelAction() {
13
protected CancelAction(String key) {
38
/** For concealed CancelActions (with a different text) */
39
public CancelAction(String key) {
44
public void actionPerformed(ActionEvent e) {
45
// Do nothing, as cancel mostly does nothing