KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > fractal > swing > AbstractAction


1 /**
2  * copyright area
3  */

4
5 package org.objectweb.fractal.swing;
6
7 import java.awt.event.ActionEvent JavaDoc;
8
9 import javax.swing.ImageIcon JavaDoc;
10
11 public class AbstractAction extends javax.swing.AbstractAction JavaDoc
12   implements ActionAttributes
13 {
14
15   private String JavaDoc iconURL;
16
17   public String JavaDoc getName () {
18     return (String JavaDoc)getValue(NAME);
19   }
20
21   public void setName (String JavaDoc name) {
22     putValue(NAME, name);
23   }
24
25   public String JavaDoc getIconURL () {
26     return iconURL;
27   }
28
29   public void setIconURL (String JavaDoc iconURL) {
30     this.iconURL = iconURL;
31     putValue(SMALL_ICON, new ImageIcon JavaDoc(getClass().getResource(iconURL)));
32   }
33
34   public String JavaDoc getToolTipText () {
35     return (String JavaDoc)getValue(SHORT_DESCRIPTION);
36   }
37
38   public void setToolTipText (String JavaDoc toolTipText) {
39     putValue(SHORT_DESCRIPTION, toolTipText);
40   }
41
42   public String JavaDoc getAcceleratorKey () {
43     return (String JavaDoc)getValue(ACCELERATOR_KEY);
44   }
45
46   public void setAcceleratorKey (String JavaDoc acceleratorKey) {
47     putValue(ACCELERATOR_KEY, acceleratorKey);
48   }
49
50   public void actionPerformed (ActionEvent JavaDoc e) {
51   }
52 }
53
Popular Tags