From 61b1b673a3992221af7f0c12faa3ee2a3731e7d6 Mon Sep 17 00:00:00 2001 From: Wil Clouser Date: Mon, 9 May 2011 09:03:52 -0700 Subject: [PATCH] fixing l10n problems --- apps/amo/log.py | 2 +- apps/compat/templates/compat/index.html | 1 + apps/zadmin/views.py | 4 ++-- media/js/zamboni/admin_validation.js | 5 +++-- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/apps/amo/log.py b/apps/amo/log.py index 399daa1807..541cc9dcaa 100644 --- a/apps/amo/log.py +++ b/apps/amo/log.py @@ -347,7 +347,7 @@ class BULK_VALIDATION_UPDATED(_LOG): class BULK_VALIDATION_EMAILED(_LOG): id = 47 action_class = None - format = _(u'Authors emailed about compatability of {version}.') + format = _(u'Authors emailed about compatibility of {version}.') class CUSTOM_TEXT(_LOG): diff --git a/apps/compat/templates/compat/index.html b/apps/compat/templates/compat/index.html index 9ff4b23065..e07f728afa 100644 --- a/apps/compat/templates/compat/index.html +++ b/apps/compat/templates/compat/index.html @@ -23,6 +23,7 @@ + {# L10n: "#" means "number" #} {% for key, title in keys %} diff --git a/apps/zadmin/views.py b/apps/zadmin/views.py index a353277d00..043d6defff 100644 --- a/apps/zadmin/views.py +++ b/apps/zadmin/views.py @@ -240,8 +240,8 @@ def notify(request, job): notify_form = NotifyForm(request.POST) if not notify_form.is_valid(): - messages.error(request, _('Error processing the mail template: %s' - % notify_form.errors['text'][0])) + msg = _('Error processing the mail template: %s') + messages.error(request, msg % notify_form.errors['text'][0]) else: file_pks = job.result_failing().values_list('file_id', flat=True) diff --git a/media/js/zamboni/admin_validation.js b/media/js/zamboni/admin_validation.js index 315e1e655a..d99928cd31 100644 --- a/media/js/zamboni/admin_validation.js +++ b/media/js/zamboni/admin_validation.js @@ -41,8 +41,9 @@ function initAdminValidation(doc) { var $version_popup = $('#set-max-version').popup('a.set-max-version', { callback: function(obj) { var $ct = $(obj.click_target); - var msg = ngettext('Set {0} addon-on to a max version of {1}.', - 'Set {0} addon-ons to a max version of {1}.', + // L10n: {0} is the number of add-ons, {1} is a version like 4.0 + var msg = ngettext('Set {0} add-on to a max version of {1}.', + 'Set {0} add-ons to a max version of {1}.', $ct.attr('data-job-count')); $(this).children('p').text(format(msg, [$ct.attr('data-job-count'), $ct.attr('data-job-version')]));
{{ _('Version') }}{{ _('# of Add-ons') }}