summaryrefslogtreecommitdiff
path: root/modules/gallery/js
diff options
context:
space:
mode:
authorAndy Staudacher <andy.st@gmail.com>2010-02-27 20:06:37 -0800
committerAndy Staudacher <andy.st@gmail.com>2010-02-27 20:06:37 -0800
commitdacb58ceed224fea34fa9cff740e6f30c70f0a7f (patch)
treec724367bcab8b147ba5d74fc548bcc10f05e592e /modules/gallery/js
parentcaf9ae88badfa5c2b8eb3eac03e298f1beea79a3 (diff)
Additional fixes for plural handling when deleting translations / marking them as untranslated.
Diffstat (limited to 'modules/gallery/js')
-rw-r--r--modules/gallery/js/l10n_client.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/gallery/js/l10n_client.js b/modules/gallery/js/l10n_client.js
index a77667f3..a1170e2d 100644
--- a/modules/gallery/js/l10n_client.js
+++ b/modules/gallery/js/l10n_client.js
@@ -166,7 +166,7 @@ jQuery.extend(Gallery, {
if (form == 'one') {
text = source['one'];
}
- $('#l10n-edit-plural-translation-' + form)
+ $("#plural-" + form + " textarea[name='l10n-edit-plural-translation-" + form + "']")
.attr('value', text);
}
} else {
@@ -264,8 +264,8 @@ Gallery.behaviors.l10nClient = function(context) {
if (is_plural) {
for (var i = 0; i < num_plural_forms; i++) {
var form = plural_forms[i];
- translation[form] = $('#g-l10n-client-save-form #l10n-edit-plural-translation-' + form).attr('value');
- is_non_empty |= translation[form];
+ translation[form] = $("#plural-" + form + " textarea[name='l10n-edit-plural-translation-" + form + "']").attr('value');
+ is_non_empty = is_non_empty || translation[form];
}
} else {
translation = $('#l10n-edit-translation').attr('value');
@@ -287,7 +287,7 @@ Gallery.behaviors.l10nClient = function(context) {
for (var i = 0; i < num_plural_forms; i++) {
var form = plural_forms[i];
- $('#g-l10n-client-save-form #l10n-edit-plural-translation-' + form).val('');
+ $("#plural-" + form + " textarea[name='l10n-edit-plural-translation-" + form + "']").val('');
}
$("#g-l10n-client-save-form input[name='l10n-message-key']").val('');
},