View Javadoc

1   /*
2    * @(#)$Id: RunBatchAction.java 588 2008-10-25 13:09:33Z kurmannu $
3    *
4    * Author   : Ueli Kurmann, igesture@uelikurmann.ch
5    *                                   
6    *                                   
7    * Purpose  : 
8    *
9    * -----------------------------------------------------------------------
10   *
11   * Revision Information:
12   *
13   * Date       Who     Reason
14   *
15   * 23.03.2008 ukurmann  Initial Release
16   *
17   * -----------------------------------------------------------------------
18   *
19   * Copyright 1999-2009 ETH Zurich. All Rights Reserved.
20   *
21   * This software is the proprietary information of ETH Zurich.
22   * Use is subject to license terms.
23   * 
24   */
25  
26  
27  package org.ximtec.igesture.tool.view.batch.action;
28  
29  import java.awt.event.ActionEvent;
30  
31  import org.ximtec.igesture.tool.GestureConstants;
32  import org.ximtec.igesture.tool.core.Command;
33  import org.ximtec.igesture.tool.core.Controller;
34  import org.ximtec.igesture.tool.core.LocateableAction;
35  import org.ximtec.igesture.tool.view.batch.BatchController;
36  
37  
38  public class CancelBatchAction extends LocateableAction {
39     
40     private Controller controller;
41  
42     public CancelBatchAction(Controller controller) {
43        super(GestureConstants.BATCH_CANCEL, controller.getLocator());
44        this.controller = controller;
45  
46     }
47  
48  
49     @Override
50     public void actionPerformed(ActionEvent action) {
51        Command command = new Command(BatchController.CMD_CANCEL_BATCH);
52        controller.execute(command);
53        
54     }
55  
56  }