当前页面:
在线文档首页 >
NetBeans API Javadoc (Current Development Version)
TabActionEvent (Tab Control) - NetBeans API Javadoc (Current Development Version)
org.netbeans.swing.tabcontrol.event
Class TabActionEvent
java.lang.Object
java.util.EventObject
java.awt.AWTEvent
java.awt.event.ActionEvent
org.netbeans.swing.tabcontrol.event.TabActionEvent
- All Implemented Interfaces:
- Serializable
public final class TabActionEvent
- extends ActionEvent
An action event which may be consumed by a listener. These are fired by
TabControl and TabbedContainer to determine if outside code wants to handle
an event, such as clicking the close button (which might be vetoed), or if
the control should handle it itself.
- See Also:
- Serialized Form
Fields inherited from class java.awt.AWTEvent |
ACTION_EVENT_MASK, ADJUSTMENT_EVENT_MASK, COMPONENT_EVENT_MASK, consumed, CONTAINER_EVENT_MASK, FOCUS_EVENT_MASK, HIERARCHY_BOUNDS_EVENT_MASK, HIERARCHY_EVENT_MASK, id, INPUT_METHOD_EVENT_MASK, INVOCATION_EVENT_MASK, ITEM_EVENT_MASK, KEY_EVENT_MASK, MOUSE_EVENT_MASK, MOUSE_MOTION_EVENT_MASK, MOUSE_WHEEL_EVENT_MASK, PAINT_EVENT_MASK, RESERVED_ID_MAX, TEXT_EVENT_MASK, WINDOW_EVENT_MASK, WINDOW_FOCUS_EVENT_MASK, WINDOW_STATE_EVENT_MASK |
Method Summary |
void |
consume()
Consume this event - any changes that should be performed as a result
will be done by external code by manipulating the models or other means |
MouseEvent |
getMouseEvent()
If the action event was triggered by a mouse event, get the mouse event
in question |
int |
getTabIndex()
|
boolean |
isConsumed()
Determine if the event has been consumed |
void |
setSource(Object source)
|
String |
toString()
|
TabActionEvent
public TabActionEvent(Object source,
String command,
int tabIndex)
- Creates a new instance of TabActionEvent
TabActionEvent
public TabActionEvent(Object source,
String command,
int tabIndex,
MouseEvent mouseEvent)
consume
public void consume()
- Consume this event - any changes that should be performed as a result
will be done by external code by manipulating the models or other means
- Overrides:
consume
in class AWTEvent
isConsumed
public boolean isConsumed()
- Determine if the event has been consumed
- Overrides:
isConsumed
in class AWTEvent
getMouseEvent
public MouseEvent getMouseEvent()
- If the action event was triggered by a mouse event, get the mouse event
in question
- Returns:
- The mouse event, or null
getTabIndex
public int getTabIndex()
setSource
public void setSource(Object source)
- Overrides:
setSource
in class AWTEvent
toString
public String toString()
- Overrides:
toString
in class AWTEvent