Closed Bug 1773070 Opened 2 years ago Closed 2 years ago

Unify rust and C++'s EventState bits.

Categories

(Core :: DOM: Core & HTML, task)

task

Tracking

()

RESOLVED FIXED
103 Branch
Tracking Status
firefox103 --- fixed

People

(Reporter: emilio, Assigned: emilio)

References

Details

Attachments

(6 files)

No description provided.

Add a dom/base/rust crate called just "dom" where we can share these.

Most of the changes are automatic:

s/mozilla::EventStates/mozilla::dom::ElementState/
s/EventStates/ElementState/
s/NS_EVENT_STATE_/ElementState::/
s/NS_DOCUMENT_STATE_/DocumentState::/

And so on. This requires a new cbindgen version to avoid ugly casts for
large shifts.

Attached file Generated file.

For now this is fine, if we want to generate more stuff in the future
changing the header name is trivial.

Depends on D148553

Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/51947744ce12
Unify Gecko and Servo EventState/ElementState bits. r=smaug
https://hg.mozilla.org/integration/autoland/rev/596be2b0e47f
Rename generated header name as per Matrix suggestion. r=smaug
https://hg.mozilla.org/integration/autoland/rev/ca710e35634f
While at it use some better names for some bits. r=smaug
https://hg.mozilla.org/integration/autoland/rev/9cb912e74f72
While at it rename ContentStateChanged to ElementStateChanged, and make it take elements. r=smaug
https://hg.mozilla.org/integration/autoland/rev/a65534f2a923
Rename/remove some eventState/s variables. r=smaug
Regressions: 1773336
No longer regressions: 1773336
Regressions: 1773259
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: