Fix localization comments for plural forms in webrtcIndicator.properties

RESOLVED FIXED in Firefox 34

Status

()

defect
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: flod, Assigned: Gijs)

Tracking

unspecified
Firefox 34
Points:
1
Bug Flags:
firefox-backlog +
qe-verify -

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

Reporter

Description

5 years ago
I realized it after the landing from bug 1057006.

I know it's painful, but for plural form we need the entire localization comment
http://hg.mozilla.org/mozilla-central/file/ffc10f34de13/browser/locales/en-US/chrome/browser/webrtcIndicator.properties#l32

Also one separated comment for each string.

https://developer.mozilla.org/en-US/docs/Mozilla/Localization/Localization_best_practices#Use_proper_plural_forms
Assignee

Comment 1

5 years ago
(In reply to Francesco Lodolo [:flod] (offline from Aug 31 to Sep 7) from comment #0)
> I realized it after the landing from bug 1057006.
> 
> I know it's painful, but for plural form we need the entire localization
> comment
> http://hg.mozilla.org/mozilla-central/file/ffc10f34de13/browser/locales/en-
> US/chrome/browser/webrtcIndicator.properties#l32

I'm happy to fix something here, but what do you mean by "entire localization comment" ?

> Also one separated comment for each string.
> 
> https://developer.mozilla.org/en-US/docs/Mozilla/Localization/
> Localization_best_practices#Use_proper_plural_forms

you mean that rather than the * notation you want something like: http://hg.mozilla.org/mozilla-central/file/ffc10f34de13/browser/locales/en-US/chrome/browser/browser.properties#l509 ?
Flags: needinfo?(francesco.lodolo)
Reporter

Comment 2

5 years ago
We need a localization comment like this on each string

# LOCALIZATION NOTE (stringid):
# Semicolon-separated list of plural forms. See:
# http://developer.mozilla.org/en/docs/Localization_and_Plurals

This form of comment is used by tool to identify plural forms.

I don't think multiple stringids in one comment would work, that's why I said "one per string", even if painful to look at.
Flags: needinfo?(francesco.lodolo)
Assignee

Comment 3

5 years ago
(In reply to Francesco Lodolo [:flod] (offline from Aug 31 to Sep 7) from comment #2)
> I don't think multiple stringids in one comment would work

Can you elaborate on "work"? Why are we using them everywhere if they don't "work"? Is this issue specific to a particular tool? (which?)
Assignee

Comment 4

5 years ago
Like this?
Attachment #8480503 - Flags: review?(francesco.lodolo)
Assignee

Updated

5 years ago
Assignee: nobody → gijskruitbosch+bugs
Status: NEW → ASSIGNED
Reporter

Comment 5

5 years ago
Tools for localizations parse comments to display them near the string. This is one of the tools that do that: http://mozilla.locamotion.org/

"Won't work": I simply doubt that such tools will be able to correctly match "getUserMedia.*" (or list of IDs) to all the strings starting with "getUserMedia.".

That explains the part "match a string to its comment".

Plural forms are a special case: how do you recognize a plural form? You can't search for ";", because that's a common character that could be used in a string. So we settle on "parse the comment associated to the string".

Compare-locales is another tool that relies on these comments to display warnings and errors, and it's the tool running all l10n-dashboards
http://hg.mozilla.org/l10n/compare-locales
Reporter

Comment 6

5 years ago
Comment on attachment 8480503 [details] [diff] [review]
update l10n comments,

Review of attachment 8480503 [details] [diff] [review]:
-----------------------------------------------------------------

Perfect :-)
Attachment #8480503 - Flags: review?(francesco.lodolo) → review+
Assignee

Comment 7

5 years ago
remote:   https://hg.mozilla.org/integration/fx-team/rev/ee64990e130c
Iteration: --- → 34.3
Points: --- → 1
Flags: qe-verify-
Flags: firefox-backlog+
Whiteboard: [fixed-in-fx-team]
Assignee

Comment 8

5 years ago
Marco, can you add this to the spreadsheet? Thanks!
Flags: needinfo?(mmucci)
Added to IT 34.3.
Flags: needinfo?(mmucci)
https://hg.mozilla.org/mozilla-central/rev/ee64990e130c
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 34
Component: General → Device Permissions
You need to log in before you can comment on or make changes to this bug.