|
| Components |
|
| |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||
com.sas.visuals.DefaultButtonListener
public class DefaultButtonListener
DefaultButtonListener is an implementation of the ButtonListenerInterface used to listen
for user events on a button component and change the state of the ButtonModelInterface property.
The button component will listen on the ButtonModelInterface object and will forward the state changes
of the ButtonModelInterface to the user.
DefaultButtonModel,
BaseButton,
ButtonModelInterface,
Serialized Form| Field Summary | |
|---|---|
protected ButtonModelInterface |
model
|
| Constructor Summary | |
|---|---|
DefaultButtonListener()
Default Constructor |
|
DefaultButtonListener(ButtonModelInterface btnModel)
Constructor that sets the buttonModel to change the state of based on the user events listened for. |
|
| Method Summary | |
|---|---|
ButtonModelInterface |
getButtonModel()
Get the ButtonModelInterface object associated with this ButtonListenerInterface. |
protected boolean |
isActivationKey(java.awt.event.KeyEvent keyEvent)
Method to determine if a key should activate the model. |
void |
keyPressed(java.awt.event.KeyEvent evt)
Method invoked when a key is pressed by the user while the component listened on has focus. |
void |
keyReleased(java.awt.event.KeyEvent evt)
Method invoked when a key is released by the user while the component listened on has focus. |
void |
keyTyped(java.awt.event.KeyEvent evt)
Method invoked when a key is typed by the user while the component listened on has focus. |
void |
mouseClicked(java.awt.event.MouseEvent evt)
Method invoked when the mouse is clicked. |
void |
mouseDragged(java.awt.event.MouseEvent evt)
Method invoked when the mouse is dragged. |
void |
mouseEntered(java.awt.event.MouseEvent evt)
Method invoked when the mouse enters the button component area. |
void |
mouseExited(java.awt.event.MouseEvent evt)
Method invoked when the mouse exits the button component area. |
void |
mouseMoved(java.awt.event.MouseEvent evt)
Method invoked when the mouse is moved. |
void |
mousePressed(java.awt.event.MouseEvent evt)
Method invoked when the mouse is pressed. |
void |
mouseReleased(java.awt.event.MouseEvent evt)
Method invoked when the mouse is released. |
void |
setButtonModel(ButtonModelInterface btnModel)
Set the ButtonModelInterface object associated with this ButtonListenerInterface The buttonModel state will be changed based on the user events received by this buttonListener. |
| Field Detail |
|---|
protected ButtonModelInterface model
| Constructor Detail |
|---|
public DefaultButtonListener()
public DefaultButtonListener(ButtonModelInterface btnModel)
| Method Detail |
|---|
public ButtonModelInterface getButtonModel()
getButtonModel in interface ButtonListenerInterfacepublic void setButtonModel(ButtonModelInterface btnModel)
setButtonModel in interface ButtonListenerInterfaceprotected boolean isActivationKey(java.awt.event.KeyEvent keyEvent)
keyCode - the KeyEvent virtual key code.public void keyPressed(java.awt.event.KeyEvent evt)
keyPressed in interface java.awt.event.KeyListenerKeyListenerpublic void keyReleased(java.awt.event.KeyEvent evt)
keyReleased in interface java.awt.event.KeyListenerKeyListenerpublic void keyTyped(java.awt.event.KeyEvent evt)
keyTyped in interface java.awt.event.KeyListenerKeyListenerpublic void mouseMoved(java.awt.event.MouseEvent evt)
mouseMoved in interface java.awt.event.MouseMotionListenerMouseMotionListenerpublic void mouseDragged(java.awt.event.MouseEvent evt)
mouseDragged in interface java.awt.event.MouseMotionListenerMouseMotionListenerpublic void mouseClicked(java.awt.event.MouseEvent evt)
mouseClicked in interface java.awt.event.MouseListenerMouseListenerpublic void mousePressed(java.awt.event.MouseEvent evt)
mousePressed in interface java.awt.event.MouseListenerMouseListenerpublic void mouseReleased(java.awt.event.MouseEvent evt)
mouseReleased in interface java.awt.event.MouseListenerMouseListenerpublic void mouseEntered(java.awt.event.MouseEvent evt)
mouseEntered in interface java.awt.event.MouseListenerMouseListenerpublic void mouseExited(java.awt.event.MouseEvent evt)
mouseExited in interface java.awt.event.MouseListenerMouseListener
|
| Components |
|
| |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||