net.java.dev.joode.graphics2D.tool
Interface ViewTool

All Superinterfaces:
java.util.EventListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, WorldStepListener
All Known Implementing Classes:
AbstractTool, CompositeTool, CreateBodyCircleTool, CreateTool, ForceTool, MouseObjectMover, MouseZoomScroll

public interface ViewTool
extends java.awt.event.MouseMotionListener, java.awt.event.MouseListener, WorldStepListener


Method Summary
 void activate()
          Tells the tool that it has been activated (i.e.
 void deactivate()
          Tells the tool that it has been deactivate (i.e.
 javax.swing.Icon getIcon()
          gets the tools icon for buttons etc.
 java.lang.String getLabel()
          returns the label that should be used for menus etc.
 void install(ViewTools tools)
          called once when the tool is added to the tools interface the object passed in can be queried to retreive information such as the space or world
 void update()
          called if the world or space changes when a tool is active
 
Methods inherited from interface java.awt.event.MouseMotionListener
mouseDragged, mouseMoved
 
Methods inherited from interface java.awt.event.MouseListener
mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased
 
Methods inherited from interface net.java.dev.joode.WorldStepListener
notifyQuickStep, notifyStep
 

Method Detail

activate

void activate()
Tells the tool that it has been activated (i.e. it is now the selected tool and should expect event notifications)


update

void update()
called if the world or space changes when a tool is active


deactivate

void deactivate()
Tells the tool that it has been deactivate (i.e. another tool has been selected) The tool should reset its state at this point


install

void install(ViewTools tools)
called once when the tool is added to the tools interface the object passed in can be queried to retreive information such as the space or world

Parameters:
tools -

getIcon

javax.swing.Icon getIcon()
gets the tools icon for buttons etc.

Returns:

getLabel

java.lang.String getLabel()
returns the label that should be used for menus etc.

Returns: