[gnome-software] menu spec plugin: Use context to translate subcategory titles



commit 4fd1592bfc127533709e571eb399fbd11f0722c2
Author: Rafal Luzynski <digitalfreak lingonborough com>
Date:   Wed Aug 19 00:56:55 2015 +0200

    menu spec plugin: Use context to translate subcategory titles
    
    The same as in commit 9dba158e8b285f04b859179c40b05a56cc33cb7c
    by Frédéric Péters is also required here or otherwise the subcategory
    name in the Details view is not translated.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=726890

 src/plugins/gs-plugin-menu-spec-refine.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/plugins/gs-plugin-menu-spec-refine.c b/src/plugins/gs-plugin-menu-spec-refine.c
index 02d477b..7af5e22 100644
--- a/src/plugins/gs-plugin-menu-spec-refine.c
+++ b/src/plugins/gs-plugin-menu-spec-refine.c
@@ -73,9 +73,11 @@ gs_plugin_refine_app_category (GsPlugin *plugin,
                ret = gs_app_has_category (app, tmp + 2);
                if (ret) {
                        _cleanup_free_ gchar *str = NULL;
+                       _cleanup_free_ gchar *msgctxt = NULL;
+                       msgctxt = g_strdup_printf ("Menu subcategory of %s", cat->text);
                        str = g_strdup_printf ("%s → %s",
                                               gettext (cat->text),
-                                              gettext (msdata[i].text));
+                                              g_dpgettext2 (GETTEXT_PACKAGE, msgctxt, msdata[i].text));
                        gs_app_set_menu_path (app, str);
                        break;
                }


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