Logo Search packages:      
Sourcecode: scummvm version File versions  Download package

virtual bool Common::XMLParser::keyCallback ( ParserNode node  )  [protected, pure virtual]

The keycallback function is automatically overloaded on custom parsers when using the CUSTOM_XML_PARSER() macro.

Its job is to call the corresponding Callback function for the given node. A function for each key type must be declared separately. See the custom parser creation instructions.

When parsing a key in such function, one may chose to skip it, e.g. because it's not needed on the current configuration. In order to ignore a key, you must set the "ignore" field of its KeyNode struct to "true": The key and all its children will then be automatically ignored by the parser.

The callback function must return true if the key was properly handled (this includes the case when the key is being ignored). False otherwise. The return of keyCallback() is the same as the callback function's. See the sample implementation in GUI::ThemeParser.

Referenced by parseActiveKey().


Generated by  Doxygen 1.6.0   Back to index