javax.rad.genui.container
Class InternalToolBarPanel

java.lang.Object
  extended by javax.rad.genui.container.InternalToolBarPanel

public class InternalToolBarPanel
extends Object

The InternalToolBarPanel is an UIContainer for IToolBars.


Constructor Summary
InternalToolBarPanel(UIContainer<? extends IToolBarPanel> pOwner)
          Creates a new instance of InternalToolBarPanel with an owner.
 
Method Summary
 void addNotify()
          Notification to forward addNotify to all sub toolbars.
 void addToolBar(IToolBar pToolBar, int pIndex)
          Adds a toolbar to this panel at a specified index.
 void beforeAddNotify(IComponent pParent)
          Invoked before this component is added.
 IToolBar getToolBar(int pIndex)
          Gets the IToolBar from a specific index.
 int getToolBarArea()
          Gets the area where the toolbar(s) are added.
 int getToolBarCount()
          Gets the number of IToolBars in this panel.
 int indexOfToolBar(IToolBar pToolBar)
          Gets the nth position of an IToolBar in this panel.
 boolean isBeforeNotified()
          Gets whether this component is notified before it was added.
 boolean isNotified()
          Gets if the InternalToolBarPanel was notified about addNotify.
 boolean isToolBarMovable()
          Gets whether the toolbars are movable.
 void removeNotify()
          Notification to forward removeNotify to all sub toolbars.
 void removeToolBar(int pIndex)
          Removes a toolbar from this panel.
 void removeToolBar(IToolBar pToolBar)
          Removes a toolbar from this panel.
 void setToolBarArea(int pArea)
          Sets the display area where the toolbars will be added.
 void setToolBarMovable(boolean pMovable)
          Sets all toolbars movable or fixed.
 void updateTranslation()
          Notification for updating the translation of all sub toolbars.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InternalToolBarPanel

public InternalToolBarPanel(UIContainer<? extends IToolBarPanel> pOwner)
Creates a new instance of InternalToolBarPanel with an owner.

Parameters:
pOwner - the owner of the internal toolbar
Method Detail

addToolBar

public void addToolBar(IToolBar pToolBar,
                       int pIndex)
Adds a toolbar to this panel at a specified index.

Parameters:
pToolBar - the toolbar to be added
pIndex - the index for the toolbar

removeToolBar

public void removeToolBar(int pIndex)
Removes a toolbar from this panel.

Parameters:
pIndex - the toolbar

removeToolBar

public void removeToolBar(IToolBar pToolBar)
Removes a toolbar from this panel.

Parameters:
pToolBar - the toolbar

getToolBarCount

public int getToolBarCount()
Gets the number of IToolBars in this panel.

Returns:
the number of toolbars

getToolBar

public IToolBar getToolBar(int pIndex)
Gets the IToolBar from a specific index.

Parameters:
pIndex - the index
Returns:
the toolbar at pIndex

indexOfToolBar

public int indexOfToolBar(IToolBar pToolBar)
Gets the nth position of an IToolBar in this panel.

Parameters:
pToolBar - the IToolBar to search
Returns:
the nth position of pToolBar in this panel or -1 if pToolBar is not added

setToolBarArea

public void setToolBarArea(int pArea)
Sets the display area where the toolbars will be added.

Parameters:
pArea - an area constant IToolBarPanel.AREA_TOP, IToolBarPanel.AREA_LEFT, IToolBarPanel.AREA_BOTTOM, IToolBarPanel.AREA_RIGHT

getToolBarArea

public int getToolBarArea()
Gets the area where the toolbar(s) are added.

Returns:
an area constant IToolBarPanel.AREA_TOP, IToolBarPanel.AREA_LEFT, IToolBarPanel.AREA_BOTTOM, IToolBarPanel.AREA_RIGHT

setToolBarMovable

public void setToolBarMovable(boolean pMovable)
Sets all toolbars movable or fixed.

Parameters:
pMovable - true to move the toolbars, false otherwise

isToolBarMovable

public boolean isToolBarMovable()
Gets whether the toolbars are movable.

Returns:
true if the toolbars are movable, false otherwise

updateTranslation

public void updateTranslation()
Notification for updating the translation of all sub toolbars.


beforeAddNotify

public void beforeAddNotify(IComponent pParent)
Invoked before this component is added.

Parameters:
pParent - the parent

isBeforeNotified

public boolean isBeforeNotified()
Gets whether this component is notified before it was added.

Returns:
true this component is notified, false otherwise

addNotify

public void addNotify()
Notification to forward addNotify to all sub toolbars.


isNotified

public boolean isNotified()
Gets if the InternalToolBarPanel was notified about addNotify.

Returns:
true if addNotify was called; false otherwise

removeNotify

public void removeNotify()
Notification to forward removeNotify to all sub toolbars.



Copyright © 2009 SIB Visions GmbH. All Rights Reserved.