Antares Simulator
Power System Simulator
Loading...
Searching...
No Matches
Antares::Map::Tool::Remover Class Reference
Inheritance diagram for Antares::Map::Tool::Remover:
Antares::Map::Tool::Tool

Public Member Functions

 Remover (Manager &manager)
 
virtual void draw (DrawingContext &dc, const bool mouseDown, const wxPoint &position, const wxPoint &absolute) const
 Draw the tool.
 
virtual bool onMouseUp (const int mx, const int my)
 Event: The user has clicked on the tool.
 
- Public Member Functions inherited from Antares::Map::Tool::Tool
 Tool (Manager &manager, const char *icon)
 Constructor.
 
virtual ~Tool ()
 Destructor.
 
Managermanager ()
 
const Managermanager () const
 
int x () const
 Get the X-Coordinate of the tool.
 
void x (const int v)
 Set the X-Coordinate of the tool.
 
int y () const
 Get the Y-Coordinate of the tool.
 
void y (const int v)
 Set the Y-Coordinate of the tool.
 
uint width () const
 Get the width of the tool.
 
uint height () const
 Get the height of the tool.
 
const wxBitmap * icon () const
 Get the icon of the tool, NULL if not available.
 
void icon (const char *filename)
 Set the icon representing the tool.
 
LifeSpan lifeSpan () const
 Get the lifespan of the tool.
 
bool contains (const int x, const int y) const
 Get if a point is insided the bounding box of the tool.
 
virtual bool actionIsImmediate () const
 Get if the action triggered by the tool is immediate.
 

Additional Inherited Members

- Protected Attributes inherited from Antares::Map::Tool::Tool
ManagerpManager
 The parent manager.
 
int pX
 The X-Coordinate.
 
int pY
 The Y-Coordinate.
 
int pWidth
 Width.
 
int pHeight
 Height.
 
wxBitmap * pIcon
 Icon.
 

Member Function Documentation

◆ draw()

void Antares::Map::Tool::Remover::draw ( DrawingContext & dc,
const bool mouseDown,
const wxPoint & position,
const wxPoint & absolute ) const
virtual

Draw the tool.

Parameters
dcA drawing context
mouseDownTrue if the mouse is down
position
absolute

Reimplemented from Antares::Map::Tool::Tool.

◆ onMouseUp()

bool Antares::Map::Tool::Remover::onMouseUp ( const int mx,
const int my )
virtual

Event: The user has clicked on the tool.

Returns
True to invalidate all tools (ex: some nodes have been removed, moved...)

Implements Antares::Map::Tool::Tool.


The documentation for this class was generated from the following files: