Mercurial > hg > svcore
diff base/Command.cpp @ 1450:a12fd0456f0c streaming-csv-writer
Merge from default branch
author | Chris Cannam |
---|---|
date | Tue, 17 Apr 2018 10:35:42 +0100 |
parents | 48e9f538e6e9 |
children |
line wrap: on
line diff
--- a/base/Command.cpp Tue Apr 17 10:03:51 2018 +0100 +++ b/base/Command.cpp Tue Apr 17 10:35:42 2018 +0100 @@ -24,7 +24,7 @@ MacroCommand::~MacroCommand() { for (size_t i = 0; i < m_commands.size(); ++i) { - delete m_commands[i]; + delete m_commands[i]; } } @@ -38,13 +38,13 @@ MacroCommand::deleteCommand(Command *command) { for (std::vector<Command *>::iterator i = m_commands.begin(); - i != m_commands.end(); ++i) { + i != m_commands.end(); ++i) { - if (*i == command) { - m_commands.erase(i); - delete command; - return; - } + if (*i == command) { + m_commands.erase(i); + delete command; + return; + } } } @@ -58,7 +58,7 @@ MacroCommand::execute() { for (size_t i = 0; i < m_commands.size(); ++i) { - m_commands[i]->execute(); + m_commands[i]->execute(); } } @@ -66,7 +66,7 @@ MacroCommand::unexecute() { for (size_t i = 0; i < m_commands.size(); ++i) { - m_commands[m_commands.size() - i - 1]->unexecute(); + m_commands[m_commands.size() - i - 1]->unexecute(); } }