Zimlet JavaScript API Reference - DwtSlider

Class DwtSlider


Extends DwtControl.

This class represents a slider.

Defined in: DwtSlider.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
DwtSlider(parent, orientation, className, posStyle)
Creates a slider.
Field Summary
Field Attributes Field Name and Description
<static>  
DwtSlider.HORIZONTAL
Defines the "horizontal" orientation.
<static>  
DwtSlider.VERTICAL
Defines the "vertical" orientation.
Method Summary
Method Attributes Method Name and Description
 
Adds a change listener.
 
Gets the maximum allowed value
 
Gets the minimum allowed value.
 
Gets the slider value.
 
Checks if the slider is currently dragging.
 
setRange(minimum, maximum, value, notify)
Sets the range and value of the slider.
 
setValue(value, notify)
Sets the value of the slider, moving the position button accordingly.
Methods borrowed from class DwtControl:
addClassName, addControlListener, addDisposeListener, addListener, appendElement, blur, clearContent, clearHandler, condClassName, delClassName, dispose, focus, getBounds, getClassName, getContent, getCursor, getData, getDragBox, getDragSource, getDropTarget, getEnabled, getFocusElement, getH, getHtmlElement, getHTMLElId, getInsetBounds, getInsets, getLocation, getMargins, getOpacity, getOuterSize, getPosition, getScrollContainer, getScrollStyle, getSize, getTabGroupMember, getTooltipBase, getToolTipContent, getVisibility, getVisible, getW, getX, getXW, getY, getYH, getZIndex, hasFocus, isAlertShown, isDisposed, isInitialized, isListenerRegistered, notifyListeners, preventContextMenu, preventSelection, removeAllListeners, removeControlListener, removeDisposeListener, removeListener, reparent, reparentHtmlElement, replaceElement, setBounds, setClassName, setContent, setCursor, setData, setDisplay, setDisplayState, setDragBox, setDragSource, setDropTarget, setEnabled, setEventPropagation, setFocusElement, setHandler, setHtmlElementId, setLocation, setOpacity, setPosition, setScrollStyle, setSize, setToolTipContent, setVisibility, setVisible, setZIndex, showAlert, zShow
Class Detail
DwtSlider(parent, orientation, className, posStyle)
Creates a slider.
Parameters:
{DwtControl} parent
the parent widget
{DwtSlider.HORIZONTAL|DwtSlider.VERTICAL} orientation
the orientation of the slider
{string} className Optional
the CSS class. If not provided defaults to "DwtHorizontalSlider" or "DwtVerticalSlider"
{constant} posStyle Optional, Default: DwtControl.STATIC_STYLE
the positioning style (see DwtControl)
Field Detail
<static> DwtSlider.HORIZONTAL
Defines the "horizontal" orientation.

<static> DwtSlider.VERTICAL
Defines the "vertical" orientation.
Method Detail
addChangeListener(listener)
Adds a change listener.
Parameters:
{AjxListener} listener
the listener

{number} getMaximum()
Gets the maximum allowed value
Returns:
{number} the maximum value

{number} getMinimum()
Gets the minimum allowed value.
Returns:
{number} the minimum value

{number} getValue()
Gets the slider value.
Returns:
{number} the value

{Boolean} isDragging()
Checks if the slider is currently dragging.
Returns:
{Boolean} true if the slider is dragging

setRange(minimum, maximum, value, notify)
Sets the range and value of the slider.
Parameters:
{number} minimum
the minimum allowed value
{number} maximum
the maximum allowed value
{number} value
the value
{boolean} notify
if true, notify change listeners of the new value

setValue(value, notify)
Sets the value of the slider, moving the position button accordingly.
Parameters:
{number} value
the value
{boolean} notify
if true, to notify change listeners of the new value

Documentation generated by JsDoc Toolkit 2.3.0 on Tue Jun 28 2016 21:01:29 GMT-0400 (EDT)