Page MenuHomePhabricator

Bug 1501116 - Part 5: Use alias for StyleFillRule.
ClosedPublic

Authored by boris on Oct 30 2018, 12:56 AM.

Details

Summary

This needs to update the "fill-rule" and "clip-rule" to use
predefined_type to avoid some compilation errors.

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

boris created this revision.Oct 30 2018, 12:56 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 30 2018, 12:56 AM
phab-bot changed the visibility from "Custom Policy" to "Public (No Login Required)".Oct 30 2018, 12:56 AM
phab-bot changed the edit policy from "Custom Policy" to "Restricted Project (Project)".
phab-bot removed a project: Restricted Project.
boris requested review of this revision.Oct 30 2018, 12:56 AM
boris updated this revision to Diff 29820.Oct 30 2018, 9:45 PM

Revision updated.

boris retitled this revision from Bug 1501116 - Part 3: Map StyleFillRule to Bug 1501116 - Part 5: Use alias for StyleFillRule..Oct 30 2018, 9:45 PM
boris edited the summary of this revision. (Show Details)
boris updated this revision to Diff 29836.Oct 30 2018, 9:56 PM

Revision updated.

Hmm, instead of introducing more mako magic, why not using the general machinery we have to share types across multiple properties, something like:

rust
pub use values::generics::FillRule;

In both specified/basic_shape.rs and computed/basic_shape.rs.

Then changing these two to use prefefined_type("FillRule")?

Then these can just use impl_simple in gecko.mako.rs.

wdyt?

Then changing these two to use prefefined_type("FillRule")?

Yes. This works. I can update this by predefined_type.

boris updated this revision to Diff 29938.Oct 31 2018, 6:20 AM

Revision updated.

boris edited the summary of this revision. (Show Details)Oct 31 2018, 6:20 AM
emilio accepted this revision.Oct 31 2018, 10:57 AM

Nice!

This revision is now accepted and ready to land.Oct 31 2018, 10:57 AM
This revision was automatically updated to reflect the committed changes.