Changeset 3360 for code/branches/resource/src/cpptcl/changes_orxonox.diff
- Timestamp:
- Jul 28, 2009, 5:04:38 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/resource/src/cpptcl/changes_orxonox.diff
r2710 r3360 28 28 Tcl_SetResult(interp, const_cast<char*>(e.what()), TCL_VOLATILE); 29 29 return TCL_ERROR; 30 @@ -858,6 +858,18 @@31 owner_ = true;32 }33 34 +interpreter::interpreter(string const &libpath)35 +{36 + interp_ = Tcl_CreateInterp();37 + owner_ = true;38 +39 + try40 + {41 + this->eval("set tcl_library \"" + libpath + "\"");42 + Tcl_Init(this->interp_);43 + } catch (...) {}44 +}45 +46 interpreter::interpreter(Tcl_Interp *interp, bool owner)47 {48 interp_ = interp;49 --- cpptcl.h Wed Jan 28 20:56:11 200950 +++ cpptcl.h Sat Jan 24 12:52:54 200951 @@ -467,6 +467,7 @@52 {53 public:54 interpreter();55 + interpreter(std::string const &libpath);56 interpreter(Tcl_Interp *, bool owner = true);57 ~interpreter();58
Note: See TracChangeset
for help on using the changeset viewer.