package graphics; import java.awt.event.MouseEvent; public interface Draggable { /** * Tell the object that a drag operation might be beginning. * The Draggable object can decide whether it really wants * to be dragged, based on the MouseEvent. It should return * true to indicate that a drag should really be started, and * false if it wants to ignore the MouseEvent. */ public boolean startDrag(MouseEvent evt); /** * Continue a drag that was started in startDrag(). Presumably * the event is a mouseDragged event. */ public void continueDrag(MouseEvent evt); /** * Finish a draw that was started in startDrag(). Presumably * the event is a mouseReleased event. */ public void finishDrag(MouseEvent evt); }