com.aelitis.azureus.ui.swt.toolbar
Class ToolBarItemSO

java.lang.Object
  extended by com.aelitis.azureus.ui.swt.toolbar.ToolBarItemSO
All Implemented Interfaces:
ToolBarItem, UIToolBarItem

public class ToolBarItemSO
extends Object
implements ToolBarItem

Author:
TuxPaper

Field Summary
 
Fields inherited from interface org.gudy.azureus2.plugins.ui.toolbar.UIToolBarItem
STATE_DOWN, STATE_ENABLED
 
Constructor Summary
ToolBarItemSO(ToolBarView tbView, String id, boolean isPluginItem)
           
ToolBarItemSO(ToolBarView tbView, String id, String imageid)
           
ToolBarItemSO(ToolBarView tbView, String id, String imageid, String textID)
           
 
Method Summary
 void dispose()
           
 UIToolBarActivationListener getDefaultActivationListener()
           
 long getDefaultState()
           
 String getGroupID()
           
 String getID()
          Retrieve the ID of the toolbar item
 String getImageID()
          Get the ID of the image used
 SWTSkinButtonUtility getSkinButton()
           
 long getState()
           
 String getTextID()
          Return the message bundle ID for the button text
 String getTooltipID()
           
 boolean isAlwaysAvailable()
          Returns if the toolbar item is always available (enabled)
 void setAlwaysAvailable(boolean alwaysAvailable)
           
 void setDefaultActivationListener(UIToolBarActivationListener defaultActivation)
           
 void setDefaultState(long state)
           
 void setGroupID(String groupID)
           
 void setImageID(String imageID)
          Sets the toolbar item to use the specified image
 void setSkinButton(SWTSkinButtonUtility btn)
           
 void setSkinTitle(SWTSkinObjectText s)
           
 void setState(long state)
           
 void setTextID(String textID)
          Sets the button's text to a messagebundle value looked up using the id
 void setTooltipID(String tooltipID)
           
 boolean triggerToolBarItem(long activationType, Object datasource)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ToolBarItemSO

public ToolBarItemSO(ToolBarView tbView,
                     String id,
                     String imageid)
Parameters:
id -
image -

ToolBarItemSO

public ToolBarItemSO(ToolBarView tbView,
                     String id,
                     String imageid,
                     String textID)

ToolBarItemSO

public ToolBarItemSO(ToolBarView tbView,
                     String id,
                     boolean isPluginItem)
Method Detail

triggerToolBarItem

public boolean triggerToolBarItem(long activationType,
                                  Object datasource)
Specified by:
triggerToolBarItem in interface ToolBarItem
Specified by:
triggerToolBarItem in interface UIToolBarItem

getID

public String getID()
Description copied from interface: UIToolBarItem
Retrieve the ID of the toolbar item

Specified by:
getID in interface UIToolBarItem

setSkinButton

public void setSkinButton(SWTSkinButtonUtility btn)

getSkinButton

public SWTSkinButtonUtility getSkinButton()

setSkinTitle

public void setSkinTitle(SWTSkinObjectText s)

getState

public long getState()
Specified by:
getState in interface UIToolBarItem

setState

public void setState(long state)
Specified by:
setState in interface UIToolBarItem

getImageID

public String getImageID()
Description copied from interface: UIToolBarItem
Get the ID of the image used

Specified by:
getImageID in interface UIToolBarItem

setImageID

public void setImageID(String imageID)
Description copied from interface: UIToolBarItem
Sets the toolbar item to use the specified image

Specified by:
setImageID in interface UIToolBarItem

setTextID

public void setTextID(String textID)
Description copied from interface: UIToolBarItem
Sets the button's text to a messagebundle value looked up using the id

Specified by:
setTextID in interface UIToolBarItem
Parameters:
textID - the textID to set

getTextID

public String getTextID()
Description copied from interface: UIToolBarItem
Return the message bundle ID for the button text

Specified by:
getTextID in interface UIToolBarItem
Returns:
the textID

getTooltipID

public String getTooltipID()
Specified by:
getTooltipID in interface ToolBarItem

setTooltipID

public void setTooltipID(String tooltipID)

setAlwaysAvailable

public void setAlwaysAvailable(boolean alwaysAvailable)
Specified by:
setAlwaysAvailable in interface ToolBarItem

isAlwaysAvailable

public boolean isAlwaysAvailable()
Description copied from interface: UIToolBarItem
Returns if the toolbar item is always available (enabled)

Specified by:
isAlwaysAvailable in interface UIToolBarItem

setDefaultActivationListener

public void setDefaultActivationListener(UIToolBarActivationListener defaultActivation)
Specified by:
setDefaultActivationListener in interface ToolBarItem
Specified by:
setDefaultActivationListener in interface UIToolBarItem

getDefaultActivationListener

public UIToolBarActivationListener getDefaultActivationListener()
Specified by:
getDefaultActivationListener in interface ToolBarItem

dispose

public void dispose()

getGroupID

public String getGroupID()

setGroupID

public void setGroupID(String groupID)

setDefaultState

public void setDefaultState(long state)

getDefaultState

public long getDefaultState()