forked from len0rd/rockbox
Add a T type to the tag table which allows parameters to be a single tag
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27716 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
a0dd4cd057
commit
145571d9b5
2 changed files with 12 additions and 0 deletions
|
|
@ -673,6 +673,17 @@ static int skin_parse_tag(struct skin_element* element, const char** document)
|
|||
if(!element->params[i].data.code)
|
||||
return 0;
|
||||
}
|
||||
else if (tolower(*tag_args) == 't')
|
||||
{
|
||||
struct skin_element* child = skin_alloc_element();
|
||||
child->type = TAG;
|
||||
if (!skin_parse_tag(child, &cursor))
|
||||
return 0;
|
||||
child->next = NULL;
|
||||
element->params[i].type = CODE;
|
||||
element->params[i].data.code = child;
|
||||
}
|
||||
|
||||
|
||||
skip_whitespace(&cursor);
|
||||
|
||||
|
|
|
|||
|
|
@ -273,6 +273,7 @@ enum skin_token_type {
|
|||
* F - Required file name
|
||||
* f - Nullable file name
|
||||
* C - Required skin code
|
||||
* T - Required single skin tag
|
||||
* N - any amount of strings.. must be the last param in the list
|
||||
* \n - causes the parser to eat everything up to and including the \n
|
||||
* MUST be the last character of the prams string
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue