[PATCH] Do not translate a blank window name.

Vratislav Podzimek vpodzime at redhat.com
Mon Apr 29 10:48:03 UTC 2013


On Fri, 2013-04-26 at 11:16 -0400, Chris Lumens wrote:
> This should prevent us from getting the .po file header displayed on the
> screen again in the future.
> ---
>  widgets/src/BaseWindow.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/widgets/src/BaseWindow.c b/widgets/src/BaseWindow.c
> index 7493ca4..5aa8420 100644
> --- a/widgets/src/BaseWindow.c
> +++ b/widgets/src/BaseWindow.c
> @@ -313,7 +313,14 @@ static void anaconda_base_window_set_property(GObject *object, guint prop_id, co
>          }
>  
>          case PROP_WINDOW_NAME: {
> -            char *markup = g_markup_printf_escaped("<span weight='bold' size='large'>%s</span>", _(g_value_get_string(value)));
> +            char *markup;
> +
> +            /* Do not translate an empty string here. */
> +            if (strcmp(g_value_get_string(value), "") == 0)
> +                markup = g_markup_printf_escaped("<span weight='bold' size='large'></span>");
> +            else
> +                markup = g_markup_printf_escaped("<span weight='bold' size='large'>%s</span>", _(g_value_get_string(value)));
> +
>              gtk_label_set_markup(GTK_LABEL(priv->name_label), markup);
>              g_free(markup);
>  
ACK, nice catch!

-- 
Vratislav Podzimek

Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic



More information about the anaconda-patches mailing list