Closed Bug 1550488 Opened 6 years ago Closed 6 years ago

Change the OTR localization to use Fluent

Categories

(Chat Core :: Security: OTR, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Instantbird 68

People

(Reporter: KaiE, Assigned: KaiE)

References

(Blocks 1 open bug)

Details

Attachments

(2 files, 7 obsolete files)

The initial landing of the OTR code might still use the classic approach for localized strings.

We must port it to use Fluent.

Attached patch otr-finger-fluent.patch (obsolete) — Splinter Review

example for conversion to fluent

Attached patch 1550488-v2.patch (obsolete) — Splinter Review

two dialogs done now...

Also fixes the problem with the ask-for-auth dialog, the <caption> had stopped working. Replaced it with html:h4

Assignee: nobody → kaie
Blocks: 1551896
Attached patch 1550488-v3.patch (obsolete) — Splinter Review
Attachment #9064738 - Attachment is obsolete: true
Attachment #9064862 - Attachment is obsolete: true
Attached patch 1550488-v4.patch (obsolete) — Splinter Review
Attachment #9065114 - Attachment is obsolete: true

Note to self:

If this gets checked in prior to being done with our strings, the .ftl files must be committed to a location outside of the locale/en-US directory, to avoid that localizers work on unfinished strings.

An example how to do that can be found here:
https://searchfox.org/mozilla-central/source/browser/locales/jar.mn#11

searchfox contents might move, therefore I'm pasting the example:

[localization] @AB_CD@.jar:
  browser/aboutLogins.ftl                          (../components/aboutlogins/content/aboutLogins.ftl)
  browser                                          (%browser/**/*.ftl)
Attached patch 1550488-v5.patch (obsolete) — Splinter Review

Adjusted to apply on top of bug 1518172.

Moved all .ftl files out of the locales scope for now.

Attachment #9065444 - Attachment is obsolete: true
Comment on attachment 9065641 [details] [diff] [review] 1550488-v5.patch Magnus can you please review? If you want a phabricator request, I can do that soon, after bug 1518172 lands (probably today).
Attachment #9065641 - Flags: review?(mkmelin+mozilla)

Change the OTR localization to use Fluent

Comment on attachment 9065641 [details] [diff] [review] 1550488-v5.patch let's use phab
Attachment #9065641 - Attachment is obsolete: true
Attachment #9065641 - Flags: review?(mkmelin+mozilla)
Status: NEW → ASSIGNED
Attached patch 1550488-final.patch (obsolete) — Splinter Review
Attachment #9065983 - Flags: review+

Jörg, can you please land the attached patch? Reviewed in phab. Thanks!

Flags: needinfo?(jorgk)
Keywords: checkin-needed
Attachment #9065983 - Attachment is obsolete: true
Attachment #9065983 - Flags: review+

You should run linting before submitting a patch :-( - I'll fix it for you now:

c:\mozilla-source\comm-central\comm\chat\modules\OTR.jsm
12:3 error 'XPCOMUtils' is assigned a value but never used. no-unused-vars (eslint)
13:3 error 'l10nHelper' is assigned a value but never used. no-unused-vars (eslint)
21:26 error Missing trailing comma. comma-dangle (eslint)

c:\mozilla-source\comm-central\comm\chat\modules\OTRUI.jsm
11:3 error 'XPCOMUtils' is assigned a value but never used. no-unused-vars (eslint)
12:3 error 'l10nHelper' is assigned a value but never used. no-unused-vars (eslint)
17:28 error Missing trailing comma. comma-dangle (eslint)

? 6 problems (6 errors, 0 warnings)

Flags: needinfo?(jorgk)

Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/ae087d73b3ce
Change the OTR localization to use Fluent. r=mkmelin

Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Instantbird 68

(In reply to Jorg K (GMT+2) from comment #14)

You should run linting before submitting a patch :-( - I'll fix it for you now:

Yes, I should have, thanks a lot for your help!

Jörg reported a failure:
"WARNING: Failed to open external DTD: publicId "" systemId "chrome://chat/content/otr-chat.dtd"

I should have removed it as part of this bug.

Attachment #9069972 - Flags: review?(jorgk)
Attachment #9069972 - Flags: approval-comm-beta?
Comment on attachment 9069972 [details] [diff] [review] 1550488-remove-dtd.patch Thanks.
Attachment #9069972 - Flags: review?(jorgk)
Attachment #9069972 - Flags: review+
Attachment #9069972 - Flags: approval-comm-beta?
Attachment #9069972 - Flags: approval-comm-beta+
Pushed by mozilla@jorgk.com: https://hg.mozilla.org/comm-central/rev/fdc11cc83535 Follow-up: Remove reference to DTD file. r=jorgk
Component: General → Security: OTR
Attachment #9065698 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: