#include <UndoStackManager.h>
Public Member Functions | |
| void | addUndoStack (QUndoCommand *command) |
| Method that insert command Undo/Redo of type AddCommand in the Undo/Redo stack. More... | |
| void | addWatch (Feature *feature) |
| const std::vector< Feature * > & | getAddWatches () const |
| QUndoStack * | getUndoStack () |
| Method that return stack of Undo/Redo. More... | |
| void | reset () |
Static Public Member Functions | |
| static UndoStackManager & | getInstance () |
| It returns a reference to the singleton instance. More... | |
Public Attributes | |
| int | m_currentIndex |
Protected Member Functions | |
| UndoStackManager () | |
| It initializes the singleton instance of the repository manager. More... | |
| ~UndoStackManager () | |
| Singleton destructor. More... | |
Protected Attributes | |
| std::vector< Feature * > | m_addWatches |
| QUndoStack * | m_undoStack |
| Undo/Redo stack. More... | |
Friends | |
| class | te::common::Singleton< UndoStackManager > |
Definition at line 49 of file UndoStackManager.h.
|
protected |
It initializes the singleton instance of the repository manager.
Definition at line 41 of file UndoStackManager.cpp.
|
protected |
Singleton destructor.
Definition at line 46 of file UndoStackManager.cpp.
References te::common::FreeContents(), m_addWatches, and m_undoStack.
| void te::edit::UndoStackManager::addUndoStack | ( | QUndoCommand * | command | ) |
Method that insert command Undo/Redo of type AddCommand in the Undo/Redo stack.
| command | command |
Definition at line 54 of file UndoStackManager.cpp.
References m_undoStack.
Referenced by te::edit::SubtractAreaTool::storeUndoCommand(), te::edit::AggregateAreaTool::storeUndoCommand(), te::edit::MoveGeometryTool::storeUndoCommand(), te::edit::CreatePolygonTool::storeUndoCommand(), and te::edit::VertexTool::storeUndoCommand().
| void te::edit::UndoStackManager::addWatch | ( | Feature * | feature | ) |
Definition at line 77 of file UndoStackManager.cpp.
References m_addWatches, and m_currentIndex.
Referenced by te::edit::SubtractAreaTool::storeUndoCommand(), te::edit::AggregateAreaTool::storeUndoCommand(), te::edit::MoveGeometryTool::storeUndoCommand(), te::edit::CreatePolygonTool::storeUndoCommand(), and te::edit::VertexTool::storeUndoCommand().
| const std::vector< te::edit::Feature * > & te::edit::UndoStackManager::getAddWatches | ( | ) | const |
Definition at line 72 of file UndoStackManager.cpp.
References m_addWatches.
Referenced by te::edit::AddCommand::countFeaturesById(), te::edit::AddCommand::draw(), te::edit::VertexTool::onCommandFeedback(), te::edit::AddCommand::redo(), and te::edit::AddCommand::undo().
|
staticinherited |
It returns a reference to the singleton instance.
Referenced by te::qt::plugins::edit::ToolBar::initializeActions(), te::qt::plugins::edit::ToolBar::onCreateUndoViewActivated(), te::qt::plugins::edit::ToolBar::onEditActivated(), te::qt::plugins::edit::ToolBar::onResetVisualizationToolActivated(), and te::qt::plugins::edit::ToolBar::onSaveActivated().
| QUndoStack * te::edit::UndoStackManager::getUndoStack | ( | ) |
Method that return stack of Undo/Redo.
Definition at line 62 of file UndoStackManager.cpp.
References m_undoStack.
Referenced by te::edit::AddCommand::redo().
| void te::edit::UndoStackManager::reset | ( | ) |
Definition at line 96 of file UndoStackManager.cpp.
References te::common::FreeContents(), m_addWatches, and m_undoStack.
Referenced by te::qt::plugins::edit::ToolBar::onResetVisualizationToolActivated().
|
friend |
Definition at line 51 of file UndoStackManager.h.
|
protected |
Definition at line 85 of file UndoStackManager.h.
Referenced by addWatch(), getAddWatches(), reset(), and ~UndoStackManager().
| int te::edit::UndoStackManager::m_currentIndex |
Definition at line 75 of file UndoStackManager.h.
Referenced by addWatch(), te::edit::AddCommand::draw(), te::edit::CreatePolygonTool::draw(), te::edit::MoveGeometryTool::draw(), te::edit::VertexTool::onCommandFeedback(), te::edit::AddCommand::redo(), and te::edit::AddCommand::undo().
|
protected |
Undo/Redo stack.
Definition at line 87 of file UndoStackManager.h.
Referenced by addUndoStack(), getUndoStack(), reset(), and ~UndoStackManager().