[Sugar-devel] [PATCH] sl#2815: Localization fixes.

Chris Leonard cjlhomeaddress at gmail.com
Mon Jan 23 09:03:01 EST 2012


On Mon, Jan 23, 2012 at 8:47 AM, Ajay Garg <ajay at activitycentral.com> wrote:
> Added note for "not" localizing the format-specifier token.
>
> Thanks Gonzalo Odiard. Thanks Chris Leonard.
>
> ---
>  extensions/deviceicon/battery.py |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/extensions/deviceicon/battery.py b/extensions/deviceicon/battery.py
> index 260cb12..ea25aef 100644
> --- a/extensions/deviceicon/battery.py
> +++ b/extensions/deviceicon/battery.py
> @@ -155,6 +155,8 @@ class BatteryPalette(Palette):
>                 minutes_remaining = self._time // 60
>                 remaining_hourpart = minutes_remaining // 60
>                 remaining_minpart = minutes_remaining % 60
> +
> +                # TRANS: do not translate the token "%(hour)d:%(min).2d". Only translate the token "remaining".
>                 secondary_text = _('%(hour)d:%(min).2d remaining') % \
>                         {'hour': remaining_hourpart, 'min': remaining_minpart}
>         else:


This looks good to me.

cjl


More information about the Sugar-devel mailing list