2 * Copyright 2000-2009 JetBrains s.r.o.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
16 package com
.intellij
.ui
.wizard
;
19 import java
.awt
.event
.ActionEvent
;
21 public abstract class WizardAction
extends AbstractAction
{
23 protected WizardModel myModel
;
25 public WizardAction(String name
, WizardModel model
) {
30 protected void setMnemonic(char value
) {
31 putValue(Action
.MNEMONIC_KEY
, new Integer(value
));
34 public final void setName(String name
) {
35 putValue(Action
.NAME
, name
);
38 public static class Next
extends WizardAction
{
40 public Next(WizardModel model
) {
41 super("Next >", model
);
45 public void actionPerformed(ActionEvent e
) {
50 public static class Previous
extends WizardAction
{
52 public Previous(WizardModel model
) {
53 super("< Previous", model
);
57 public void actionPerformed(ActionEvent e
) {
62 public static class Finish
extends WizardAction
{
64 public Finish(WizardModel model
) {
65 super("Finish", model
);
69 public void actionPerformed(ActionEvent e
) {
74 public static class Cancel
extends WizardAction
{
76 public Cancel(WizardModel model
) {
77 super("Cancel", model
);
81 public void actionPerformed(ActionEvent e
) {