|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xith3d.ui.hud.utils.WidgetMover
public class WidgetMover
A WidgetMover interpolatedly moves a Widget from its current location to a destination location.
| Constructor Summary | |
|---|---|
WidgetMover(Widget widget)
Creates a new WidgetMover for the given Widget and destination location. |
|
WidgetMover(Widget widget,
float destX,
float destY,
float speed)
Creates a new WidgetMover for the given Widget and destination location. |
|
WidgetMover(Widget widget,
org.openmali.vecmath2.Tuple2f destLocation,
float speed)
Creates a new WidgetMover for the given Widget and destination location. |
|
| Method Summary | |
|---|---|
org.openmali.vecmath2.Tuple2f |
getDestinationLocation()
|
float |
getDestinationLocationX()
|
float |
getDestinationLocationY()
|
float |
getSpeed()
|
org.openmali.vecmath2.Tuple2f |
getStartLocation()
|
float |
getStartLocationX()
|
float |
getStartLocationY()
|
Widget |
getWidget()
|
void |
invert()
|
boolean |
isMoving()
|
protected void |
onMovementStopped()
This method is invoked when the Widget has reached its destination location. |
void |
setDestinationLocation(float destLocationX,
float destLocationY)
Sets the Widget's destination location for the movement. |
void |
setDestinationLocation(org.openmali.vecmath2.Tuple2f destLocation)
Sets the Widget's destination location for the movement. |
void |
setSpeed(float speed)
Sets the speed for the movement (in units per second). |
void |
startMoving()
Starts the movement from the Widget's current location to the destination location. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WidgetMover(Widget widget,
float destX,
float destY,
float speed)
widget - the Widget to be moveddestX - the destination location x-coordinatedestY - the destination location y-coordinatespeed - the speed for the movement (in units per second)
public WidgetMover(Widget widget,
org.openmali.vecmath2.Tuple2f destLocation,
float speed)
widget - the Widget to be moveddestLocation - the destination locationspeed - the speed for the movement (in units per second)public WidgetMover(Widget widget)
widget - the Widget to be moved| Method Detail |
|---|
public Widget getWidget()
getWidget in interface WidgetWrapperpublic org.openmali.vecmath2.Tuple2f getStartLocation()
public float getStartLocationX()
public float getStartLocationY()
public void setDestinationLocation(org.openmali.vecmath2.Tuple2f destLocation)
destLocation -
public void setDestinationLocation(float destLocationX,
float destLocationY)
destLocationX - destLocationY - public org.openmali.vecmath2.Tuple2f getDestinationLocation()
public float getDestinationLocationX()
public float getDestinationLocationY()
public void setSpeed(float speed)
speed - public float getSpeed()
public void startMoving()
public boolean isMoving()
protected void onMovementStopped()
public void invert()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||