public class DeleteTool extends Tool
| Modifier and Type | Field and Description |
|---|---|
(package private) boolean |
dragging |
(package private) Vector2D |
originalMousePosition |
application, objectContainer, view| Constructor and Description |
|---|
DeleteTool(CutCADApplet application,
ObjectContainer container) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getIconName()
Return the name of the SVG for the icon for the tool.
|
void |
mouseButtonPressed(Vector2D position,
int button)
Will be called by the application when a mouse button was pressed.
|
void |
mouseMoved(Vector2D position)
Will be called by the application when the mouse was moved.
|
private void |
removeConnectionsContaining(Shape s) |
private void |
removeCutoutsContaining(Shape s) |
void |
toolWasSelected()
Will be called by the application when this tool was selected.
|
void |
toolWasUnselected()
Will be called by the application when another tool was selected.
|
canStaySelected, draw2D, getButton, mouseButtonReleasedboolean dragging
Vector2D originalMousePosition
public DeleteTool(CutCADApplet application, ObjectContainer container)
application - the main class of the projectcontainer - the currently loaded ObjectContainerpublic java.lang.String getIconName()
ToolgetIconName in class Toolpublic void mouseButtonPressed(Vector2D position, int button)
ToolmouseButtonPressed in class Toolposition - The absolute position of the mouse cursor.button - The button that was pressed.private void removeConnectionsContaining(Shape s)
private void removeCutoutsContaining(Shape s)
public void mouseMoved(Vector2D position)
ToolmouseMoved in class Toolposition - The absolute position of the mouse cursor.public void toolWasSelected()
TooltoolWasSelected in class Toolpublic void toolWasUnselected()
TooltoolWasUnselected in class Tool