|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--edu.umd.cs.jazz.event.ZCompositeSelectionHandler
ZCompositeSelectionHandler is a convenience class that allows applications to use a single event handler to manage the multiple jazz selection event handlers.
ZSelectionManager, ZSelectionModifyHandler, ZSelectionMoveHandler, ZSelectionDeleteHandler, ZSelectionScaleHandler, ZSelectionResizeHandler, Serialized Form
| Field Summary | |
protected boolean |
activetrue when event handler is active |
static int |
ALL_AVAILABLEFlag used to indicate all available selection behaviors |
protected ZCanvas |
canvascanvas this event handler attaches to |
static int |
DELETEFlag used to indicate selection deletion |
protected ZLayerGroup |
layerMarquee layer |
static int |
MODIFYFlag used to indicate selection modification |
static int |
MOVEFlag used to indicate selection movement |
protected ZNode |
nodenode this event handler attaches to |
static int |
RESIZEFlag used to indicate selection resizing |
static int |
SCALEFlag used to indicate selection keyboard scaling |
| Constructor Summary | |
ZCompositeSelectionHandler(ZNode node, ZCanvas canvas, ZLayerGroup marqueeLayer)Creates a composite selection handler with all available selection event handler types enabled. |
|
ZCompositeSelectionHandler(ZNode node, ZCanvas canvas, ZLayerGroup marqueeLayer, int flags)Creates a composite selection handler with the specified enabled selection event handler types. |
|
| Method Summary | |
protected ZSelectionDeleteHandler |
createSelectionDeleteHandler() |
protected ZSelectionModifyHandler |
createSelectionModifyHandler() |
protected ZSelectionMoveHandler |
createSelectionMoveHandler() |
protected ZSelectionResizeHandler |
createSelectionResizeHandler() |
protected ZSelectionScaleHandler |
createSelectionScaleHandler() |
ZLayerGroup |
getMarqueeLayer() |
ZSelectionDeleteHandler |
getSelectionDeleteHandler()This method returns the current selection delete handler if ZCompositeSelectionHandler.DELETE is enabled. |
ZSelectionModifyHandler |
getSelectionModifyHandler()This method returns the current selection modify handler if ZCompositeSelectionHandler.MODIFY is enabled. |
ZSelectionMoveHandler |
getSelectionMoveHandler()This method returns the current selection move handler if ZCompositeSelectionHandler.MOVE is enabled. |
ZSelectionResizeHandler |
getSelectionResizeHandler()This method returns the current selection resize handler if ZCompositeSelectionHandler.RESIZE is enabled. |
ZSelectionScaleHandler |
getSelectionScaleHandler()This method returns the current selection scale handler if ZCompositeSelectionHandler.SCALE is enabled. |
boolean |
isActive()Determines if this event handler is active. |
void |
setActive(boolean active)Specifies whether this event handler is active |
void |
setEnabled(int flags, boolean enable)Sets whether the specified event handlers are enabled. |
void |
setMarqueeLayer(ZLayerGroup layer)Sets the marquee layer for this event handler |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int MODIFY
public static final int MOVE
public static final int SCALE
public static final int DELETE
public static final int RESIZE
public static final int ALL_AVAILABLE
protected boolean active
protected ZNode node
protected ZCanvas canvas
protected ZLayerGroup layer
| Constructor Detail |
public ZCompositeSelectionHandler(ZNode node,
ZCanvas canvas,
ZLayerGroup marqueeLayer)
node - The node to which this event hander attachescanvas - The canvas for which this event handler is activemarqueeLayer - The layer on which marquee selection is drawn
public ZCompositeSelectionHandler(ZNode node,
ZCanvas canvas,
ZLayerGroup marqueeLayer,
int flags)
flags include boolean combinations of MOVE, MODIFY, SCALE, DELETE, and ALL_AVAILABLE.
node - The node to which this event hander attachescanvas - The canvas for which this event handler is activemarqueeLayer - The layer on which marquee selection is drawnflags - The event handlers to enable| Method Detail |
public void setActive(boolean active)
setActive in interface ZEventHandler
active - True to make this event handler activepublic boolean isActive()
isActive in interface ZEventHandler
public ZLayerGroup getMarqueeLayer()
public void setMarqueeLayer(ZLayerGroup layer)
layer - The new marquee layer
public void setEnabled(int flags,
boolean enable)
flags include boolean combinations of MOVE, MODIFY, SCALE, DELETE, and ALL_AVAILABLE.
flags - The event handlers to enable or disableenable - Should the specified event handlers be enabled or disabledpublic ZSelectionModifyHandler getSelectionModifyHandler()
ZCompositeSelectionHandler.MODIFY is enabled. Otherwise it returns null.
public ZSelectionMoveHandler getSelectionMoveHandler()
ZCompositeSelectionHandler.MOVE is enabled. Otherwise it returns null.
public ZSelectionScaleHandler getSelectionScaleHandler()
ZCompositeSelectionHandler.SCALE is enabled. Otherwise it returns null.
public ZSelectionDeleteHandler getSelectionDeleteHandler()
ZCompositeSelectionHandler.DELETE is enabled. Otherwise it returns null.
public ZSelectionResizeHandler getSelectionResizeHandler()
ZCompositeSelectionHandler.RESIZE is enabled. Otherwise it returns null.
protected ZSelectionMoveHandler createSelectionMoveHandler()
protected ZSelectionResizeHandler createSelectionResizeHandler()
protected ZSelectionModifyHandler createSelectionModifyHandler()
protected ZSelectionScaleHandler createSelectionScaleHandler()
protected ZSelectionDeleteHandler createSelectionDeleteHandler()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||