de.guibuilder.framework.event
Class GuiActionEvent

java.lang.Object
  extended by de.guibuilder.framework.event.GuiUserEvent
      extended by de.guibuilder.framework.event.GuiActionEvent

public final class GuiActionEvent
extends GuiUserEvent

Von einem MenuItem oder einem Button ausgelöster ActionEvent.

Since:
0.9.3d

Field Summary
 GuiAction action
          Das MenuItem oder der Button, der dieses Ereignis augelöst hat.
 java.awt.event.ActionEvent actionEvent
          Das awt.event
 GuiMember invoker
          Wenn PopupMenu, dann steht hier der Invoker, sonst null.
 
Fields inherited from class de.guibuilder.framework.event.GuiUserEvent
ACTION, cancel, CHANGE, CLICK, CREATE, DBL_CLICK, DRAG_ENTER, DRAG_EXIT, DRAG_OVER, DROP, FILEDROP, KEY, LOST_FOCUS, member, MESSAGE_BOX, MOUSE_MOVED, MOUSE_OVER, NODE_CHANGE, POPUP_SHOW, TAB, TABLE, TREE, window, WINDOW
 
Constructor Summary
GuiActionEvent(GuiWindow win, GuiAction a, java.awt.event.ActionEvent e)
           
 
Method Summary
 GuiAction getAction()
           
 int getEventType()
          Liefert den jeweiligen Event-Typ; dieses soll Ketten von if (... instanceof ...) else if ...
 
Methods inherited from class de.guibuilder.framework.event.GuiUserEvent
getMember, getWindow
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

action

public transient GuiAction action
Das MenuItem oder der Button, der dieses Ereignis augelöst hat.


actionEvent

public java.awt.event.ActionEvent actionEvent
Das awt.event


invoker

public GuiMember invoker
Wenn PopupMenu, dann steht hier der Invoker, sonst null. Der Invoker ist die Komponente, dem das PopupMenu zugeordnet ist (z.B. Table oder Tree).

Constructor Detail

GuiActionEvent

public GuiActionEvent(GuiWindow win,
                      GuiAction a,
                      java.awt.event.ActionEvent e)
Method Detail

getEventType

public final int getEventType()
Description copied from class: GuiUserEvent
Liefert den jeweiligen Event-Typ; dieses soll Ketten von if (... instanceof ...) else if ... vermeiden.


 public final void userActionPerformed(GuiUserEvent event) {
    switch (event.getEventType() ) {
    case GuiUserEvent.ACTION:
       GuiActionEvent action = (GuiActionEvent)event;
       ...
       break;
    case GuiUserEvent.CHANGE:
       GuiChangeEvent change = (GuiChangeEvent)event;
       ...
       break;
    ...
    }
 }
 

Specified by:
getEventType in class GuiUserEvent

getAction

public GuiAction getAction()