Package org.pepstock.charba.client.zoom
Class Wheel
- java.lang.Object
-
- org.pepstock.charba.client.commons.NativeObjectContainer
-
- org.pepstock.charba.client.commons.AbstractNode
-
- org.pepstock.charba.client.zoom.Wheel
-
public final class Wheel extends AbstractNode
Base object to map wheel options forZoomPlugin.IDplugin configuration.
It represents the container for WHEEL options.- Author:
- Andrea "Stock" Stocchero
-
-
Field Summary
Fields Modifier and Type Field Description static booleanDEFAULT_ENABLEDDefault enabled, false.static doubleDEFAULT_SPEEDDefault speed, 0.1.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ModifierKeygetModifierKey()Returns the modifier key to activate zooming by wheeling.doublegetSpeed()Returns the speed of element via mouse wheel (percentage of element on a wheel event).booleanisEnabled()Returnstrueto enable element for wheel zooming.voidsetEnabled(boolean enabled)Setstrueto enable element for wheel zooming.voidsetModifierKey(ModifierKey modifierKey)Sets the modifier key to activate zooming by wheeling.voidsetSpeed(double speed)Sets the speed of element via mouse wheel (percentage of element on a wheel event).
Must be a value from 0 and 1.-
Methods inherited from class org.pepstock.charba.client.commons.AbstractNode
checkAndAddToParent, getChildKey, getParentNode, getRootNode, getUpdateListener, retrieveRoot, setArrayValueAndAddToParent, setArrayValueAndAddToParent, setArrayValueAndAddToParent, setElementAndAddToParent, setInternalCallbackToModel, setInternalCallbackToModel, setUpdateListener, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent, setValueOrArrayAndAddToParent
-
Methods inherited from class org.pepstock.charba.client.commons.NativeObjectContainer
checkAndGetColor, checkDefaultValuesArgument, empty, getArrayValue, getElement, getIncrementalId, getNativeChart, getNativeEvent, getNativeObject, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValueForMultipleKeyTypes, getValueForMultipleKeyTypes, getValueForMultipleKeyTypes, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, has, has, isType, keys, loadNativeObject, remove, remove, setArrayValue, setArrayValue, setArrayValue, setElement, setEmptyValue, setNewIncrementalId, setNewIncrementalId, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, toJSON, type
-
-
-
-
Field Detail
-
DEFAULT_ENABLED
public static final boolean DEFAULT_ENABLED
Default enabled, false.- See Also:
- Constant Field Values
-
DEFAULT_SPEED
public static final double DEFAULT_SPEED
Default speed, 0.1.- See Also:
- Constant Field Values
-
-
Method Detail
-
setEnabled
public void setEnabled(boolean enabled)
Setstrueto enable element for wheel zooming.- Parameters:
enabled-trueto enable element for wheel zooming
-
isEnabled
public boolean isEnabled()
Returnstrueto enable element for wheel zooming.- Returns:
trueto enable element for wheel zooming
-
setSpeed
public void setSpeed(double speed)
Sets the speed of element via mouse wheel (percentage of element on a wheel event).
Must be a value from 0 and 1.- Parameters:
speed- the speed of element via mouse wheel
-
getSpeed
public double getSpeed()
Returns the speed of element via mouse wheel (percentage of element on a wheel event).- Returns:
- the speed of element via mouse wheel
-
setModifierKey
public void setModifierKey(ModifierKey modifierKey)
Sets the modifier key to activate zooming by wheeling.- Parameters:
modifierKey- the modifier key to activate zooming by wheeling
-
getModifierKey
public ModifierKey getModifierKey()
Returns the modifier key to activate zooming by wheeling.- Returns:
- the modifier key to activate zooming by wheeling
-
-