com.jme.ui
Class UICheck
java.lang.Object
com.jme.scene.Spatial
com.jme.scene.Node
com.jme.ui.UIObject
com.jme.ui.UIActiveObject
com.jme.ui.UICheck
- All Implemented Interfaces:
- java.io.Serializable
- public class UICheck
- extends UIActiveObject
UIObject derrived object that adds another state beyond the UIButton, a
checked state.
The UICheck may be Up, Over, Down or Checked. When the state is Checked, then
the other states are disabled. When UnChecked the Up, Over and Down states
apply.
- Author:
- schustej
- See Also:
- Serialized Form
| Fields inherited from class com.jme.ui.UIObject |
_bottomborder, _height, _leftborder, _quad, _rightborder, _textureStates, _topborder, _width, _x, _y, BORDER, INVERSE_BORDER, TEXTURE |
| Fields inherited from class com.jme.scene.Spatial |
currentStates, defaultStateList, forceCull, forceView, frustrumIntersects, geometricalControllers, lightCombineMode, localRotation, localScale, localTranslation, name, parent, queueDistance, renderQueueMode, renderStateList, textureCombineMode, worldBound, worldRotation, worldScale, worldTranslation, zOrder |
|
Constructor Summary |
UICheck(java.lang.String name,
int x,
int y,
int width,
int height,
InputHandler inputHandler,
java.lang.String upfile,
java.lang.String overfile,
java.lang.String downfile,
java.lang.String selectedfile,
int flags)
|
UICheck(java.lang.String name,
int x,
int y,
int width,
int height,
InputHandler inputHandler,
UIColorScheme scheme,
int flags)
|
UICheck(java.lang.String name,
int x,
int y,
int width,
int height,
InputHandler inputHandler,
UIColorScheme scheme,
java.lang.String upfile,
java.lang.String overfile,
java.lang.String downfile,
java.lang.String selectedfile,
int flags,
boolean useClassLoader)
Alternate constructer allow developer to load directly from file system |
|
Method Summary |
int |
getState()
Override of the UIObject getState() which returns also the checked or selected
state. |
void |
setSelected(boolean sel)
sets the current state of the button. |
void |
setText(UIFonts fonts,
java.lang.String fontName,
java.lang.String text)
|
boolean |
update(float time)
Checks the state of the mouse against the state of the control. |
| Methods inherited from class com.jme.scene.Node |
applyRenderState, attachChild, detachAllChildren, detachChild, detachChildAt, detachChildNamed, draw, drawBounds, findCollisions, findPick, getChild, getChild, getChildren, getQuantity, hasChild, hasCollision, putClone, setChild, setForceView, updateCollisionTree, updateWorldBound, updateWorldData |
| Methods inherited from class com.jme.scene.Spatial |
addController, applyDefaultStates, calculateCollisions, calculatePick, clearCurrentState, clearCurrentStates, clearRenderState, getController, getControllers, getCurrentState, getLastFrustumIntersection, getLightCombineMode, getLocalRotation, getLocalScale, getLocalTranslation, getName, getParent, getRenderQueueMode, getRenderStateList, getTextureCombineMode, getWorldBound, getWorldRotation, getWorldScale, getWorldTranslation, getZOrder, isForceCulled, isForceView, onDraw, onDrawBounds, propagateBoundToRoot, propagateStatesFromRoot, removeController, removeFromParent, setForceCull, setLightCombineMode, setLocalRotation, setLocalRotation, setLocalScale, setLocalScale, setLocalTranslation, setName, setParent, setRenderQueueMode, setRenderState, setTextureCombineMode, setWorldBound, setZOrder, toString, updateGeometricState, updateRenderState, updateRenderState |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
_selected
protected boolean _selected
UICheck
public UICheck(java.lang.String name,
int x,
int y,
int width,
int height,
InputHandler inputHandler,
UIColorScheme scheme,
int flags)
UICheck
public UICheck(java.lang.String name,
int x,
int y,
int width,
int height,
InputHandler inputHandler,
java.lang.String upfile,
java.lang.String overfile,
java.lang.String downfile,
java.lang.String selectedfile,
int flags)
UICheck
public UICheck(java.lang.String name,
int x,
int y,
int width,
int height,
InputHandler inputHandler,
UIColorScheme scheme,
java.lang.String upfile,
java.lang.String overfile,
java.lang.String downfile,
java.lang.String selectedfile,
int flags,
boolean useClassLoader)
- Alternate constructer allow developer to load directly from file system
update
public boolean update(float time)
- Checks the state of the mouse against the state of the control.
- Specified by:
update in class UIActiveObject
- Returns:
getState
public int getState()
- Override of the UIObject getState() which returns also the checked or selected
state.
- Overrides:
getState in class UIActiveObject
- Returns:
setSelected
public void setSelected(boolean sel)
- sets the current state of the button.
setText
public void setText(UIFonts fonts,
java.lang.String fontName,
java.lang.String text)