From d1659d69df55501f2cda82ccddde00b4018681c1 Mon Sep 17 00:00:00 2001 From: Robert Bieber Date: Tue, 1 Jun 2010 07:11:23 +0000 Subject: Theme Editor: Made Viewport the top level parse tree element, along with a bugfix to the tag parsing function git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26442 a1c6a512-1295-4272-9138-f99709370657 --- utils/themeeditor/skin_scan.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'utils/themeeditor/skin_scan.c') diff --git a/utils/themeeditor/skin_scan.c b/utils/themeeditor/skin_scan.c index dfe5d008e5..37c948fb3c 100644 --- a/utils/themeeditor/skin_scan.c +++ b/utils/themeeditor/skin_scan.c @@ -22,6 +22,7 @@ #include #include #include +#include #include "skin_scan.h" #include "skin_debug.h" @@ -136,3 +137,22 @@ int scan_int(char** document) *document = cursor; return retval; } + +int check_viewport(char* document) +{ + if(strlen(document) < 3) + return 0; + + if(document[0] != TAGSYM) + return 0; + + if(document[1] != 'V') + return 0; + + if(document[2] != ARGLISTOPENSYM + && document[2] != 'l' + && document[2] != 'i') + return 0; + + return 1; +} -- cgit v1.2.3