Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 27, 2008, 10:22:32 PM (16 years ago)
Author:
landauf
Message:

CommandExecutor uses Tcl

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/console/src/core/CommandExecutor.cc

    r1194 r1198  
    3636#include "Executor.h"
    3737#include "ConfigValueContainer.h"
     38#include "TclBind.h"
    3839
    3940#define COMMAND_EXECUTOR_KEYWORD_SET_CONFIG_VALUE "set"
     
    379380    }
    380381
    381     bool CommandExecutor::execute(const std::string& command)
    382     {
    383         if ((CommandExecutor::getEvaluation().processedCommand_ != command) || (CommandExecutor::getEvaluation().state_ == CS_Uninitialized))
    384             CommandExecutor::parse(command);
    385 
    386         return CommandExecutor::execute(CommandExecutor::getEvaluation());
     382    bool CommandExecutor::execute(const std::string& command, bool useTcl)
     383    {
     384        if (useTcl)
     385        {
     386            return TclBind::eval(command);
     387        }
     388        else
     389        {
     390            if ((CommandExecutor::getEvaluation().processedCommand_ != command) || (CommandExecutor::getEvaluation().state_ == CS_Uninitialized))
     391                CommandExecutor::parse(command);
     392
     393            return CommandExecutor::execute(CommandExecutor::getEvaluation());
     394        }
    387395    }
    388396
Note: See TracChangeset for help on using the changeset viewer.