Changeset 4252 in orxonox.OLD
- Timestamp:
- May 21, 2005, 11:39:23 PM (19 years ago)
- Location:
- orxonox/branches/levelLoader/src/util/loading
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/levelLoader/src/util/loading/factory.h
r4250 r4252 33 33 this should be used at the beginning of all the Classes that should be loadable (in the cc-file) 34 34 */ 35 #define CREATE_FACTORY(x) tFactory<x>* global_ ## x ## Factory = new tFactory<x>(#x) 35 #define CREATE_FACTORY(CLASS_NAME) tFactory<CLASS_NAME>* global_##CLASS_NAME##Factory = new tFactory<CLASS_NAME>(#CLASS_NAME); \ 36 CREATE_LOAD_DOC(CLASS_NAME) 36 37 37 38 -
orxonox/branches/levelLoader/src/util/loading/load_param.cc
r4251 r4252 26 26 \brief if the description of Parameters should be executed 27 27 */ 28 bool LoadClassDescription:: ParametersDescription = false;28 bool LoadClassDescription::parametersDescription = false; -
orxonox/branches/levelLoader/src/util/loading/load_param.h
r4251 r4252 68 68 { \ 69 69 const char* loadString = grabParameter(root, paramName); \ 70 if (loadString != NULL ) \70 if (loadString != NULL && root != NULL) \ 71 71 (*pt2Object.*function)(type1##_FUNC(loadString)); \ 72 72 else \ … … 81 81 { \ 82 82 const char* loadString = grabParameter(root, paramName); \ 83 if (loadString != NULL ) \83 if (loadString != NULL && root != NULL) \ 84 84 { \ 85 85 SubString subLoads(loadString); \ … … 101 101 { \ 102 102 const char* loadString = grabParameter(root, paramName); \ 103 if (loadString != NULL ) \103 if (loadString != NULL && root != NULL) \ 104 104 { \ 105 105 SubString subLoads(loadString); \ … … 121 121 { \ 122 122 const char* loadString = grabParameter(root, paramName); \ 123 if (loadString != NULL ) \123 if (loadString != NULL && root != NULL) \ 124 124 { \ 125 125 SubString subLoads(loadString); \ … … 141 141 { \ 142 142 const char* loadString = grabParameter(root, paramName); \ 143 if (loadString != NULL ) \143 if (loadString != NULL && root != NULL) \ 144 144 { \ 145 145 SubString subLoads(loadString); \ … … 155 155 156 156 157 158 #define CREATE_LOAD_DOC(CLASS_NAME) \ 159 160 /* void documentLoadClass(void) \ 161 { \ 162 if(LoadClassDescription::parametersDescription) \ 163 { \ 164 CLASS_NAME docuClass; \ 165 docuClass.load(NULL); \ 166 } \ 167 } \ 168 documentLoadClass(); 169 */ 157 170 158 171 class LoadParamDescription … … 170 183 171 184 172 static bool ParametersDescription;185 static bool parametersDescription; 173 186 174 187 private:
Note: See TracChangeset
for help on using the changeset viewer.