SymbolEditor  1.3.0
 All Classes Files Functions Variables Enumerations Enumerator Friends Pages
DeleteSymbolCommand Class Reference

Delete a symbol from the library command. More...

#include <Commands.h>

Inheritance diagram for DeleteSymbolCommand:
Collaboration diagram for DeleteSymbolCommand:

Public Member Functions

 DeleteSymbolCommand (SymbolLibrary *library, qint16 index)
 
virtual ~DeleteSymbolCommand ()
 
virtual void undo ()
 
virtual void redo ()
 

Private Attributes

SymbolLibrarym_symbolLibrary
 
qint16 m_index
 
Symbol m_symbol
 

Detailed Description

Delete a symbol from the library command.

Implement deleting a symbol from the library using the index specified.

The index and the symbol removed are stored for a possible undo.

Definition at line 440 of file Commands.h.

Constructor & Destructor Documentation

DeleteSymbolCommand::DeleteSymbolCommand ( SymbolLibrary library,
qint16  index 
)

Constructor

Parameters
librarya pointer to the SymbolLibrary
indexthe index of the Symbol to delete

Definition at line 819 of file Commands.cpp.

DeleteSymbolCommand::~DeleteSymbolCommand ( )
virtual

Destructor

Definition at line 830 of file Commands.cpp.

Member Function Documentation

void DeleteSymbolCommand::redo ( )
virtual

Redo deleting the Symbol. Store the removed Symbol for undo.

Definition at line 847 of file Commands.cpp.

Here is the call graph for this function:

void DeleteSymbolCommand::undo ( )
virtual

Undo deleting the Symbol restoring it from the saved one.

Definition at line 838 of file Commands.cpp.

Here is the call graph for this function:

Member Data Documentation

qint16 DeleteSymbolCommand::m_index
private

index of the symbol

Definition at line 451 of file Commands.h.

Symbol DeleteSymbolCommand::m_symbol
private

the symbol deleted, stored for undo

Definition at line 452 of file Commands.h.

SymbolLibrary* DeleteSymbolCommand::m_symbolLibrary
private

pointer to the SymbolLibrary

Definition at line 450 of file Commands.h.


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