Changeset 3350 for code/branches/resource/src
- Timestamp:
- Jul 25, 2009, 9:46:24 PM (15 years ago)
- Location:
- code/branches/resource/src/core
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/resource/src/core/ConsoleCommandCompilation.cc
r3198 r3350 94 94 if (newline) 95 95 { 96 COUT(0) << text<< std::endl;96 COUT(0) << stripEnclosingBraces(text) << std::endl; 97 97 } 98 98 else 99 99 { 100 COUT(0) << text;100 COUT(0) << stripEnclosingBraces(text); 101 101 } 102 102 } -
code/branches/resource/src/core/TclBind.cc
r3345 r3350 86 86 try 87 87 { 88 this->interpreter_->eval("proc query args { orxonox::query [join $args] }"); 89 this->interpreter_->eval("proc crossquery {id args} { orxonox::crossquery 0 $id [join $args] }"); 90 this->interpreter_->eval("proc crossexecute {id args} { orxonox::crossquery 0 $id [join $args] }"); 88 this->interpreter_->eval("proc query {args} { orxonox::query $args }"); 89 this->interpreter_->eval("proc crossquery {id args} { orxonox::crossquery 0 $id $args }"); 90 this->interpreter_->eval("proc crossexecute {id args} { orxonox::crossquery 0 $id $args }"); 91 this->interpreter_->eval("proc running {} { return 1 }"); 91 92 this->interpreter_->eval("set id 0"); 92 93 this->interpreter_->eval("rename exit tcl::exit; proc exit {} { execute exit }"); … … 105 106 Tcl::interpreter* interpreter; 106 107 #ifdef DEPENDENCY_PACKAGE_ENABLE 107 if ( true)//Core::isDevelopmentRun())108 if (Core::isDevelopmentRun()) 108 109 interpreter = new Tcl::interpreter(std::string(ORXONOX_DEP_LIB_PATH) + "/tcl"); 109 110 else -
code/branches/resource/src/core/TclThreadManager.cc
r3344 r3350 257 257 newbundle->interpreter_->def("execute", TclThreadManager::tcl_execute, Tcl::variadic()); 258 258 newbundle->interpreter_->def("crossexecute", TclThreadManager::tcl_crossexecute, Tcl::variadic()); 259 newbundle->interpreter_->eval("proc query args{ orxonox::query " + id_string + " $args }");259 newbundle->interpreter_->eval("proc query {args} { orxonox::query " + id_string + " $args }"); 260 260 newbundle->interpreter_->eval("proc crossquery {id args} { orxonox::crossquery " + id_string + " $id $args }"); 261 newbundle->interpreter_->eval("proc running {} { return [orxonox::running " + id_string + "] }"); 261 262 262 263 // Define a variable containing the thread id … … 268 269 269 270 // Redefine some native functions 270 //newbundle->interpreter_->eval("rename while tcl::while");271 // newbundle->interpreter_->eval("proc while {test command} { tcl::while {[uplevel 1 expr $test]} {uplevel 1 $command} }"); // (\"$test\" && [orxonox::running " + id + "]]) 272 //newbundle->interpreter_->eval("rename for tcl::for");273 // newbundle->interpreter_->eval("proc for {start test next command} { uplevel tcl::for \"$start\" \"$test\" \"$next\" \"$command\" }");271 newbundle->interpreter_->eval("rename while tcl::while"); 272 newbundle->interpreter_->eval("rename orxonox::while while"); 273 newbundle->interpreter_->eval("rename for tcl::for"); 274 newbundle->interpreter_->eval("rename orxonox::for for"); 274 275 } 275 276 catch (const Tcl::tcl_error& e) … … 296 297 // TODO 297 298 // Not yet implemented 299 TclInterpreterBundle* bundle = TclThreadManager::getInstance().getInterpreterBundle(id); 300 if (bundle) 301 { 302 bundle->bRunning_ = false; 303 } 298 304 } 299 305
Note: See TracChangeset
for help on using the changeset viewer.