Class ActionBar
- java.lang.Object
- 
- org.eclipse.swt.widgets.Widget
- 
- org.eclipse.swt.widgets.Control
- 
- org.eclipse.swt.widgets.Scrollable
- 
- org.eclipse.swt.widgets.Composite
- 
- com._1c.g5.v8.dt.common.ui.controls.ActionBar
 
 
 
 
 
- 
- All Implemented Interfaces:
- org.eclipse.swt.graphics.Drawable
 
 public class ActionBar extends org.eclipse.swt.widgets.CompositeAction bar contains the set of action buttons, having their unique listeners and decorating images.
- 
- 
Constructor SummaryConstructors Constructor Description ActionBar(org.eclipse.swt.widgets.Composite parent, org.eclipse.ui.forms.widgets.FormToolkit toolkit, int actionBarHeight, int style)Creates an instance of the action bar.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddActionBarListener(IActionBarListener listener)Adds action bar listener to the bar.IActionBarItemaddButton(String id, org.eclipse.swt.graphics.Image image, String toolTip, int style)Add a new button to the action bar.IActionBarItemaddSpinner(String id, int style)IActionBarItem[]getItems()voidremoveActionBarListener(IActionBarListener listener)Removes action bar listener from the bar.voidsetHeight(int height)Sets the height of the action bar.- 
Methods inherited from class org.eclipse.swt.widgets.Compositechanged, checkSubclass, drawBackground, getBackgroundMode, getChildren, getLayout, getLayoutDeferred, getTabList, isLayoutDeferred, layout, layout, layout, layout, layout, setBackgroundMode, setFocus, setLayout, setLayoutDeferred, setTabList, toString
 - 
Methods inherited from class org.eclipse.swt.widgets.ScrollablecomputeTrim, getClientArea, getHorizontalBar, getScrollbarsMode, getVerticalBar
 - 
Methods inherited from class org.eclipse.swt.widgets.ControladdControlListener, addDragDetectListener, addFocusListener, addGestureListener, addHelpListener, addKeyListener, addMenuDetectListener, addMouseListener, addMouseMoveListener, addMouseTrackListener, addMouseWheelListener, addPaintListener, addTouchListener, addTraverseListener, computeSize, computeSize, dragDetect, dragDetect, forceFocus, getAccessible, getBackground, getBackgroundImage, getBorderWidth, getBounds, getCursor, getDragDetect, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getMonitor, getOrientation, getParent, getRegion, getShell, getSize, getTextDirection, getToolTipText, getTouchEnabled, getVisible, internal_dispose_GC, internal_new_GC, isEnabled, isFocusControl, isReparentable, isVisible, moveAbove, moveBelow, pack, pack, print, redraw, redraw, removeControlListener, removeDragDetectListener, removeFocusListener, removeGestureListener, removeHelpListener, removeKeyListener, removeMenuDetectListener, removeMouseListener, removeMouseMoveListener, removeMouseTrackListener, removeMouseWheelListener, removePaintListener, removeTouchListener, removeTraverseListener, requestLayout, setBackground, setBackgroundImage, setBounds, setBounds, setCapture, setCursor, setDragDetect, setEnabled, setFont, setForeground, setLayoutData, setLocation, setLocation, setMenu, setOrientation, setParent, setRedraw, setRegion, setSize, setSize, setTextDirection, setToolTipText, setTouchEnabled, setVisible, toControl, toControl, toDisplay, toDisplay, traverse, traverse, traverse, update
 - 
Methods inherited from class org.eclipse.swt.widgets.WidgetaddDisposeListener, addListener, checkWidget, dispose, getData, getData, getDisplay, getListeners, getStyle, isAutoDirection, isDisposed, isListening, notifyListeners, removeDisposeListener, removeListener, removeListener, reskin, setData, setData
 
- 
 
- 
- 
- 
Constructor Detail- 
ActionBarpublic ActionBar(org.eclipse.swt.widgets.Composite parent, org.eclipse.ui.forms.widgets.FormToolkit toolkit, int actionBarHeight, int style)Creates an instance of the action bar. The creator is able to specify desired height of the action bar
 By default 24px height and width are used.- Parameters:
- parent- Parent composite holding this action bar.
- toolkit- Reference to the form toolkit.
- actionBarHeight- Actionbar height.
- style- Desired style.
 
 
- 
 - 
Method Detail- 
getItemspublic IActionBarItem[] getItems() - Returns:
- array of action items of this action bar. Never null.
 
 - 
addActionBarListenerpublic void addActionBarListener(IActionBarListener listener) Adds action bar listener to the bar.- Parameters:
- listener- Listener to add.
 
 - 
removeActionBarListenerpublic void removeActionBarListener(IActionBarListener listener) Removes action bar listener from the bar.- Parameters:
- listener- Listener to remove.
 
 - 
addButtonpublic IActionBarItem addButton(String id, org.eclipse.swt.graphics.Image image, String toolTip, int style) Add a new button to the action bar. The button is being placed as the rightmost button in the bar. previously existing buttons.- Parameters:
- id- Identifier of the button, can be used for distinguishing buttons in- IActionBarListenercalls.
- image- Image being displayed on the button. Ideally it shouln't exceed dimensions of the button.
- toolTip- Tooltip that is displayed when mouse moves over the button.
- style- Style modifier for the button being added.
- Returns:
- ActionBar button for further pre-launch modification.
 
 - 
addSpinnerpublic IActionBarItem addSpinner(String id, int style) 
 - 
setHeightpublic void setHeight(int height) Sets the height of the action bar. Rescales child elements (buttons) accordingly.- Parameters:
- height- The height to set.
 
 
- 
 
-