Add MozBeforeInitialXULLayout event

RESOLVED FIXED in Firefox 59

Status

()

enhancement
P3
normal
RESOLVED FIXED
2 years ago
2 months ago

People

(Reporter: gandalf, Assigned: gandalf)

Tracking

(Blocks 1 bug)

unspecified
mozilla59
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox59 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

In bug 1347798 we're adding a small per-document JS code that enables DOM localization using the new API.

At the moment, we only translate the document on window.onready, but it may be better to do this before layout.
Posted patch mozbeforelayout.diff (obsolete) — Splinter Review
Assignee

Updated

2 years ago
Depends on: 1347798
Assignee

Updated

2 years ago
Blocks: 1347798
No longer depends on: 1347798
Could we call the events something like Before/AfterInitialLayout
Maybe even Before/AfterInitialXULLayout
Sure! I'm not even yet at the stage where I'd know if I need it. Just wanted to dump my patches into bugzilla.

If I'll get it on track to land I'll rename. Thanks :)
Priority: -- → P3
Assignee

Updated

2 years ago
Blocks: 1365426
No longer blocks: 1347798
Assignee: nobody → gandalf
Blocks: 1415730
No longer blocks: 1365426
Status: NEW → ASSIGNED
Summary: Add MozBeforeLayout event → Add MozBeforeInitialXULLayout event
Comment hidden (mozreview-request)
Attachment #8866504 - Attachment is obsolete: true
While profiling Preferences with Fluent we noticed that the localization is applied way too late[0], which brought me back to this event.

With this event we can trigger DOM localization right before layout  is started which prevents FOUCs.

[0] https://searchfox.org/mozilla-central/rev/c8e791091973825680bbba807fc1c4f5bda0f5a1/intl/l10n/l10n.js#17

Comment 7

a year ago
mozreview-review
Comment on attachment 8937210 [details]
Bug 1363864 - Add MozBeforeInitialXULLayout event.

https://reviewboard.mozilla.org/r/207930/#review213902
Attachment #8937210 - Flags: review?(bugs) → review+

Comment 8

a year ago
Pushed by zbraniecki@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/16471f5143c7
Add MozBeforeInitialXULLayout event. r=smaug

Comment 9

a year ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/16471f5143c7
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla59
Component: DOM → DOM: Core & HTML
Product: Core → Core
You need to log in before you can comment on or make changes to this bug.