usbloadergx/source/xml/xml.h
giantpune a02013f03f put in a possible "fix" for the disappearing cursors that some people are getting. when menu_disclist is called the cursors are deleted and recreated. so at least if they do go away, this may make them come back.
make the homebrew menu read the XML data from meta.xml file.  put this data on the homebrew buttons and prompt.  there is 4 structs created globally that hold the XML daa.  i tried to make them pointers but i got errors so i'll leave it like this and let dimok fix it :P
2009-07-20 14:20:27 +00:00

88 lines
2.0 KiB
C

#ifndef _XML_H_
#define _XML_H_
#ifdef __cplusplus
extern "C"
{
#endif
// open database, close database, load info for a game
bool OpenXMLDatabase(char* xmlfilepath, char* argdblang, bool argJPtoEN, bool openfile, bool loadtitles, bool keepopen);
void CloseXMLDatabase();
bool LoadGameInfoFromXML(char* gameid, char* langcode);
#define XML_ELEMMAX 15
struct gameXMLinfo
{
char id[7];
char version[50];
char region[7];
char title[200];
char synopsis[3000];
char title_EN[200];
char synopsis_EN[3000];
char locales[XML_ELEMMAX+1][3];
int localeCnt;
char developer[75];
char publisher[75];
char publisherfromid[75];
char year[5];
char month[3];
char day[3];
char genre[75];
char genresplit[XML_ELEMMAX+1][20];
int genreCnt;
char ratingtype[5];
char ratingvalue[5];
char ratingdescriptors[XML_ELEMMAX+1][40];
int descriptorCnt;
char ratingvalueCERO[5];
char ratingvalueESRB[5];
char ratingvaluePEGI[5];
char wifiplayers[4];
char wififeatures[XML_ELEMMAX+1][20];
int wifiCnt;
char players[4];
char accessories[XML_ELEMMAX+1][20];
int accessoryCnt;
char accessoriesReq[XML_ELEMMAX+1][20];
int accessoryReqCnt;
char iso_crc[9];
char iso_md5[33];
char iso_sha1[41];
} ;
struct homebrewXMLinfo
{
char name[50];
char coder[50];
char version[30];
char releasedate[30];
char shortdescription[150];
char longdescription[500];
} ;
bool OpenXMLFile(char* filename);
int LoadHomebrewXMLData(char* filename,int i);
void LoadTitlesFromXML(char *langcode, bool forcejptoen);
void GetPublisherFromGameid(char *idtxt, char *dest, int destsize);
char *ConvertLangTextToCode(char *langtext);
void ConvertRating(char *ratingvalue, char *fromrating, char *torating, char *destvalue, int destsize);
void PrintGameInfo(bool showfullinfo);
char *MemInfo();
void title_set(char *id, char *title);
char* trimcopy(char *dest, char *src, int size);
#ifdef __cplusplus
}
#endif
#endif