[gnome-software] Add support for reading <project_group> in AppData files



commit 7d92dbd3933cab47a24cf6ef9be73c5b639f90af
Author: Richard Hughes <richard hughsie com>
Date:   Wed Oct 9 16:51:07 2013 +0100

    Add support for reading <project_group> in AppData files

 src/plugins/gs-plugin-appdata.c |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/gs-plugin-appdata.c b/src/plugins/gs-plugin-appdata.c
index f79a1ec..19d4441 100644
--- a/src/plugins/gs-plugin-appdata.c
+++ b/src/plugins/gs-plugin-appdata.c
@@ -414,6 +414,15 @@ appdata_parse_text_cb (GMarkupParseContext *context,
                        gs_app_set_url (helper->app, tmp);
                }
                break;
+       case APPSTREAM_TAG_PROJECT_GROUP:
+               if (gs_app_get_project_group (helper->app) == NULL) {
+                       tmp = appdata_xml_unmunge (text, text_len);
+                       if (tmp == NULL)
+                               break;
+                       g_debug ("AppData: Setting project-group: %s", tmp);
+                       gs_app_set_project_group (helper->app, tmp);
+               }
+               break;
        default:
                tmp = appdata_xml_unmunge (text, text_len);
                if (tmp == NULL)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]