Page MenuHomePhabricator

Bug 1554716 - Remove nsStyleColor moving the color property to nsStyleText. r=#style,jfkthame
ClosedPublic

Authored by emilio on May 27 2019, 3:36 PM.

Details

Summary

I think this is a good change regardless of other discussion in bug 1552587. If
we decide to move mColor to the top-level of the struct that can be done
separately.

Diff Detail

Repository
rMOZILLACENTRAL mozilla-central
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

emilio created this revision.May 27 2019, 3:36 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 27 2019, 3:36 PM
phab-bot requested review of this revision.May 27 2019, 3:37 PM
phab-bot changed the visibility from "Custom Policy" to "Public (No Login Required)".
phab-bot changed the edit policy from "Custom Policy" to "Restricted Project (Project)".
phab-bot removed a project: Restricted Project.
emilio updated this revision to Diff 110595.May 27 2019, 7:40 PM

Fix windows build

emilio edited the summary of this revision. (Show Details)May 27 2019, 7:40 PM
emilio updated this revision to Diff 110604.May 27 2019, 8:06 PM
emilio edited the summary of this revision. (Show Details)

Fix rust test size

emilio edited the summary of this revision. (Show Details)May 27 2019, 8:06 PM

The one thing I wonder is whether this means we'll be computing an entire Text struct in cases where previously we didn't need it. Have you tried to figure out (either by auditing usage of StyleColor() vs StyleText() or by instrumentation) how often that happens? I'm sure in many cases we use both anyway, but that may not always be true.

jfkthame accepted this revision.May 30 2019, 3:17 PM

Emilio reminded me on irc that we always compute all the structs, so that's not really a concern here. So this LGTM.

This revision is now accepted and ready to land.May 30 2019, 3:17 PM
emilio updated this revision to Diff 112762.May 31 2019, 2:48 PM
emilio edited the summary of this revision. (Show Details)

Update property database since color appears in a different order now

emilio edited the summary of this revision. (Show Details)May 31 2019, 2:48 PM
This revision was automatically updated to reflect the committed changes.