fi.hut.tml.xsmiles.gui.components.awt
Class AWTLink
java.lang.Object
fi.hut.tml.xsmiles.gui.components.awt.ComponentWithCaption
fi.hut.tml.xsmiles.gui.components.awt.AWTComponent
fi.hut.tml.xsmiles.gui.components.awt.AWTLink
- All Implemented Interfaces:
- XComponent, XLinkComponent
- public class AWTLink
- extends AWTComponent
- implements XLinkComponent
Default desktop lightweight linkcomponent.
- Author:
- Juha, Mikko Honkala
| Methods inherited from class fi.hut.tml.xsmiles.gui.components.awt.ComponentWithCaption |
addActionListener, addFocusListener, addHelpListener, addMouseListener, getActionable, getDefaultBackgroundColor, getHeight, getMinimumSize, getSize, getStyle, getWidth, getX, getY, removeActionListener, removeFocusListener, removeHelpListener, removeMouseListener, setActionable, setBackground, setBounds, setCaptionStyle, setCaptionText, setEnabled, setFocus, setFont, setForeground, setStyle, setVisible, setZoom |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface fi.hut.tml.xsmiles.gui.components.XComponent |
addActionListener, addFocusListener, addHelpListener, addMouseListener, getHeight, getSize, getStyle, getWidth, getX, getY, removeActionListener, removeFocusListener, removeHelpListener, removeMouseListener, setBackground, setBounds, setEnabled, setFocus, setForeground, setHintText, setInputMode, setStyle, setVisible, setZoom |
AWTLink
public AWTLink()
init
public void init()
- Description copied from class:
AWTComponent
- in init the subclass always creates its component first and then calls
super.init
- Overrides:
init in class AWTComponent
getComponent
public java.awt.Component getComponent()
- Description copied from interface:
XComponent
- Return the visual component for this extension element
- Specified by:
getComponent in interface XComponent- Overrides:
getComponent in class ComponentWithCaption
isFocusTraversable
public boolean isFocusTraversable()
setDestination
public void setDestination(java.lang.String dest)
- Specified by:
setDestination in interface XLinkComponent
- Parameters:
dest - Set the destination
getDestination
public java.lang.String getDestination()
- Specified by:
getDestination in interface XLinkComponent
- Returns:
- The destination where the link points to
setLabel
public void setLabel(java.lang.String l)
getLabel
public java.lang.String getLabel()
paint
public void paint(java.awt.Graphics g)
- Draw a rectangle around the active link, if in Digitv GUI
- Parameters:
g - ...
layoutComponent
public void layoutComponent()
- Description copied from class:
ComponentWithCaption
- layouts the component using the caption, content and the main container parts
of the control
- Overrides:
layoutComponent in class ComponentWithCaption
setActive
public void setActive(boolean val)
- Sets active flag
- Specified by:
setActive in interface XLinkComponent
- Parameters:
val - true or false
isActive
public boolean isActive()
- Is link active
- Returns:
- true if active
addClickedActionListener
public void addClickedActionListener(java.awt.event.ActionListener al)
- Specified by:
addClickedActionListener in interface XLinkComponent
addHoverListener
public void addHoverListener(XHoverListener fl)
- Specified by:
addHoverListener in interface XLinkComponent
- Parameters:
fl - Receive event when link has pointer focus or when it is lost
openAction
public void openAction()
focusLost
public void focusLost()
focusGained
public void focusGained()
getEnabled
public boolean getEnabled()
- Specified by:
getEnabled in interface XComponent
- Returns:
X-Smiles 1.2