com.threerings.tudey.client.cursor
Class SelectionCursor

java.lang.Object
  extended by com.threerings.expr.SimpleScope
      extended by com.threerings.tudey.client.cursor.Cursor
          extended by com.threerings.tudey.client.cursor.SelectionCursor
All Implemented Interfaces:
Scope, ScopeUpdateListener, Compositable, Tickable

public class SelectionCursor
extends Cursor

A cursor for a selection.


Field Summary
protected  ArrayList<EntryCursor> _cursors
          The contained cursors.
protected  HashMap<Object,EntryCursor> _cursorsByKey
          Maps entry keys to cursors.
protected  Compound _shape
          The shape of the cursor.
protected  ArrayList<Shape> _shapes
          Holds the component shapes when updating.
 
Fields inherited from class com.threerings.tudey.client.cursor.Cursor
_ctx
 
Fields inherited from class com.threerings.expr.SimpleScope
_parentScope
 
Fields inherited from interface com.threerings.expr.Scope
EPOCH, NOW
 
Constructor Summary
SelectionCursor(TudeyContext ctx, TudeySceneView view)
          Creates the cursor.
 
Method Summary
 void composite()
          Adds this object's Dependencys and Enqueueables to the compositor in preparation for rendering.
protected static boolean containsKey(TudeySceneModel.Entry[] entries, Object key)
          Determines whether the supplied array of entries contains an entry with the specified key.
 Compound getShape()
          Returns a reference to the shape of the cursor.
 void tick(float elapsed)
          Updates the state of this object based on the elapsed time in seconds.
 void update(TudeySceneModel.Entry[] entries)
          Updates the cursor with new entry state.
 
Methods inherited from class com.threerings.tudey.client.cursor.Cursor
getScopeName
 
Methods inherited from class com.threerings.expr.SimpleScope
addListener, dispose, get, getParentScope, removeListener, scopeUpdated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_cursors

protected ArrayList<EntryCursor> _cursors
The contained cursors.


_cursorsByKey

protected HashMap<Object,EntryCursor> _cursorsByKey
Maps entry keys to cursors.


_shape

protected Compound _shape
The shape of the cursor.


_shapes

protected ArrayList<Shape> _shapes
Holds the component shapes when updating.

Constructor Detail

SelectionCursor

public SelectionCursor(TudeyContext ctx,
                       TudeySceneView view)
Creates the cursor.

Method Detail

getShape

public Compound getShape()
Returns a reference to the shape of the cursor.


update

public void update(TudeySceneModel.Entry[] entries)
Updates the cursor with new entry state.


tick

public void tick(float elapsed)
Description copied from interface: Tickable
Updates the state of this object based on the elapsed time in seconds.

Specified by:
tick in interface Tickable
Overrides:
tick in class Cursor

composite

public void composite()
Description copied from interface: Compositable
Adds this object's Dependencys and Enqueueables to the compositor in preparation for rendering.

Specified by:
composite in interface Compositable
Overrides:
composite in class Cursor

containsKey

protected static boolean containsKey(TudeySceneModel.Entry[] entries,
                                     Object key)
Determines whether the supplied array of entries contains an entry with the specified key.