Package com._1c.g5.lwt.controls
Class LightUpDownButton
- java.lang.Object
-
- com._1c.g5.lwt.AbstractLightControl
-
- com._1c.g5.lwt.LightComposite
-
- com._1c.g5.lwt.controls.LightUpDownButton
-
- All Implemented Interfaces:
ILightComposite
,ILightControl
public class LightUpDownButton extends LightComposite
Up-down button with two arrow buttons pointing up and down.
-
-
Constructor Summary
Constructors Constructor Description LightUpDownButton()
Instantiates a new light up-down button.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addButtonListener(IUpDownButtonListener listener)
Adds the button listener.org.eclipse.swt.graphics.Point
computeSize(org.eclipse.swt.graphics.GC gc, int width, int height, boolean flushCache)
Computes the size of this control.void
layout(org.eclipse.swt.graphics.GC gc)
Layouts this composite using its layout, if any.void
removeButtonListener(IUpDownButtonListener listener)
Removes the button listener.void
setEnabled(boolean enabled)
Sets this control enablement.-
Methods inherited from class com._1c.g5.lwt.LightComposite
addChild, addChild, addChildAfter, addLayerAbove, addLayerBehind, controlFromPoint, dispose, getActiveControl, getChildCount, getChildren, getLayers, getLayout, layout, paint, removeChild, removeChild, revealRectangle, setActiveControl, setBounds, setFocus, setLayout, translatePointFromControl, translatePointToControl, translateRectangleFromControl, translateRectangleToControl, traverse, traverse
-
Methods inherited from class com._1c.g5.lwt.AbstractLightControl
addControlListener, getBounds, getCursor, getData, getLayoutData, getOverlay, getParent, getTooltip, getVisibleBounds, handleEvent, invalidate, invalidate, isDisposed, isEnabled, isFocused, isVisible, removeControlListener, setCursor, setData, setFocusable, setLayoutData, setOverlay, setParent, setTooltip, setVisible
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com._1c.g5.lwt.ILightComposite
getMainLayer
-
Methods inherited from interface com._1c.g5.lwt.ILightControl
addControlListener, getBounds, getCursor, getData, getLayoutData, getParent, getTooltip, getVisibleBounds, handleEvent, initialize, invalidate, invalidate, isDisposed, isEnabled, isFocused, isVisible, removeControlListener, setCursor, setData, setLayoutData, setParent, setTooltip, setVisible
-
-
-
-
Method Detail
-
addButtonListener
public void addButtonListener(IUpDownButtonListener listener)
Adds the button listener.- Parameters:
listener
- the listener to add.
-
removeButtonListener
public void removeButtonListener(IUpDownButtonListener listener)
Removes the button listener.- Parameters:
listener
- the listener to remove.
-
computeSize
public org.eclipse.swt.graphics.Point computeSize(org.eclipse.swt.graphics.GC gc, int width, int height, boolean flushCache)
Description copied from interface:ILightControl
Computes the size of this control.- Specified by:
computeSize
in interfaceILightControl
- Overrides:
computeSize
in classLightComposite
- Parameters:
gc
- the GC to do measurements with.width
- the width hint,SWT.DEFAULT
to compute the preferred width.height
- the height hint,SWT.DEFAULT
to compute the preferred height.flushCache
- the flush cache flag, instructs the associated layout to reset all its caches, if any.- Returns:
- the computed size.
-
layout
public void layout(org.eclipse.swt.graphics.GC gc)
Description copied from interface:ILightComposite
Layouts this composite using its layout, if any.- Specified by:
layout
in interfaceILightComposite
- Overrides:
layout
in classLightComposite
- Parameters:
gc
- theGC
to do the measurements with.
-
setEnabled
public void setEnabled(boolean enabled)
Description copied from interface:ILightControl
Sets this control enablement.- Specified by:
setEnabled
in interfaceILightControl
- Overrides:
setEnabled
in classAbstractLightControl
-
-