Added my own evdev handler for dpad/dpadbuttons/nubs, works fantastic
[pandora-libraries.git] / lib / pnd_tinyxml.cpp
index 0e05ad0..6159562 100644 (file)
@@ -53,7 +53,7 @@ unsigned char pnd_pxml_parse_titles(const TiXmlHandle hRoot, pnd_pxml_t *app) {
     title->language = lang;
     title->string = text;
 
-    pnd_log ( PND_LOG_DEFAULT, (char*)"    Title/Lang: %s/%s\n", text, lang );
+    //pnd_log ( PND_LOG_DEFAULT, (char*)"    Title/Lang: %s/%s\n", text, lang );
 
   }
 
@@ -140,7 +140,7 @@ unsigned char pnd_pxml_parse ( const char *pFilename, char *buffer, unsigned int
   // until we run out of applications in the PXML..
   while ( 1 ) {
 
-    pnd_log ( PND_LOG_DEFAULT, (char*)"  App #%u inside of PXML %s\n", appcount, pFilename );
+    //pnd_log ( PND_LOG_DEFAULT, (char*)"  App #%u inside of PXML %s\n", appcount, pFilename );
 
     // create the buffer to hold the pxml
     apps [ appcount ] = (pnd_pxml_t*) malloc ( sizeof(pnd_pxml_t) );
@@ -157,10 +157,10 @@ unsigned char pnd_pxml_parse ( const char *pFilename, char *buffer, unsigned int
     //Get unique ID first.
     if ( appwrappermode ) {
       app->unique_id = pnd_pxml_get_attribute(appElem, PND_PXML_ATTRNAME_UID);
-      pnd_log ( PND_LOG_DEFAULT, (char*)"  Subapp #%u has unique_id %s\n", appcount, app -> unique_id );
+      //pnd_log ( PND_LOG_DEFAULT, (char*)"  Subapp #%u has unique_id %s\n", appcount, app -> unique_id );
     } else {
       app->unique_id = pnd_pxml_get_attribute(hRoot.Element(), PND_PXML_ATTRNAME_UID);
-      pnd_log ( PND_LOG_DEFAULT, (char*)"  Only-app #%u has unique_id %s\n", appcount, app -> unique_id );
+      //pnd_log ( PND_LOG_DEFAULT, (char*)"  Only-app #%u has unique_id %s\n", appcount, app -> unique_id );
     }
 
     //Everything related to the title:
@@ -185,6 +185,14 @@ unsigned char pnd_pxml_parse ( const char *pFilename, char *buffer, unsigned int
       app->icon       = pnd_pxml_get_attribute(pElem, PND_PXML_ATTRNAME_ICONSRC);
     }
 
+    // <info>
+    if ( (pElem = hRoot.FirstChild(PND_PXML_ENAME_INFO).Element()) )
+     {
+       app-> info_name = pnd_pxml_get_attribute ( pElem, PND_PXML_ATTRNAME_INFONAME );
+       app-> info_filename = pnd_pxml_get_attribute ( pElem, PND_PXML_ATTRNAME_INFOSRC );
+       app-> info_type = pnd_pxml_get_attribute ( pElem, PND_PXML_ATTRNAME_INFOTYPE );
+     }
+
     //The preview pics:
     if ( (pElem = hRoot.FirstChild(PND_PXML_NODENAME_PREVPICS).Element()) )
     {
@@ -373,7 +381,7 @@ unsigned char pnd_pxml_parse ( const char *pFilename, char *buffer, unsigned int
     if ( appwrappermode ) {
       appElem = appElem -> NextSiblingElement ( PND_PXML_APP );
       if ( ! appElem ) {
-       pnd_log ( PND_LOG_DEFAULT, (char*)"  No more applications within PXML\n" );
+       //pnd_log ( PND_LOG_DEFAULT, (char*)"  No more applications within PXML\n" );
        break; // no more applications
       }
       // got another application..