added size accessor
fluxgen fluxgen
2 files changed,
8 insertions(+),
2 deletions(-)
M
src/FbTk/MacroCommand.cc
→
src/FbTk/MacroCommand.cc
@@ -19,7 +19,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: MacroCommand.cc,v 1.1 2003/01/11 01:09:24 fluxgen Exp $ +// $Id: MacroCommand.cc,v 1.2 2003/09/29 14:00:46 fluxgen Exp $ #include "MacroCommand.hh"@@ -27,6 +27,10 @@ namespace FbTk {
void MacroCommand::add(RefCount<Command> &com) { m_commandlist.push_back(com); +} + +unsigned int MacroCommand::size() const { + return m_commandlist.size(); } void MacroCommand::execute() {
M
src/FbTk/MacroCommand.hh
→
src/FbTk/MacroCommand.hh
@@ -19,7 +19,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: MacroCommand.hh,v 1.1 2003/01/11 01:09:24 fluxgen Exp $ +// $Id: MacroCommand.hh,v 1.2 2003/09/29 14:00:45 fluxgen Exp $ #ifndef FBTK_MACROCOMMAND_HH #define FBTK_MACROCOMMAND_HH@@ -35,7 +35,9 @@ /// executes a list of commands
class MacroCommand:public Command { public: void add(RefCount<Command> &com); + unsigned int size() const; virtual void execute(); + private: std::vector<RefCount<Command> > m_commandlist; };