diff options
author | Richard Hughes <richard@hughsie.com> | 2016-08-09 12:31:35 +0100 |
---|---|---|
committer | Richard Hughes <richard@hughsie.com> | 2016-08-09 13:04:07 +0100 |
commit | 486ff9615ecbfb024a6b24319038d8c15de32f4b (patch) | |
tree | 179020333d23288dd8b35c101684c558da0bfef7 /client | |
parent | fe430efc51c0d449e81137955b1ec280b89896bf (diff) | |
download | appstream-glib-486ff9615ecbfb024a6b24319038d8c15de32f4b.tar.gz |
Add the TRANSLATE URL kind
Diffstat (limited to 'client')
-rw-r--r-- | client/as-util.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/client/as-util.c b/client/as-util.c index 77482f2..dd975f1 100644 --- a/client/as-util.c +++ b/client/as-util.c @@ -395,6 +395,26 @@ as_util_convert_appdata (GFile *file_input, "the application"); } } + if (as_node_find_with_attribute (n, "url", "type", "translate") == NULL) { + if (g_strcmp0 (project_group, "GNOME") == 0) { + n3 = as_node_insert (n, "url", "https://wiki.gnome.org/TranslationProject", + AS_NODE_INSERT_FLAG_NONE, + "type", "translate", NULL); + } else if (g_strcmp0 (project_group, "KDE") == 0) { + n3 = as_node_insert (n, "url", "http://i18n.kde.org/", + AS_NODE_INSERT_FLAG_NONE, + "type", "translate", NULL); + } else if (g_strcmp0 (project_group, "XFCE") == 0) { + n3 = as_node_insert (n, "url", "https://wiki.xfce.org/translations", + AS_NODE_INSERT_FLAG_NONE, + "type", "translate", NULL); + } else { + n3 = as_node_insert (n, "url", "<!-- http://www.homepage.com/how-to-submit-translations.html -->", + AS_NODE_INSERT_FLAG_PRE_ESCAPED, + "type", "translate", NULL); + } + as_node_set_comment (n3, "FIXME: where to submit translations"); + } /* fix old <update_contact> name */ n2 = as_node_find (n, "updatecontact"); |