Refactor out StrokeOptions from DrawCommands

RESOLVED FIXED in Firefox 56

Status

()

RESOLVED FIXED
a year ago
a year ago

People

(Reporter: mchang, Assigned: mchang)

Tracking

unspecified
mozilla56
Points:
---

Firefox Tracking Flags

(firefox56 fixed)

Details

Attachments

(1 attachment)

Created attachment 8886722 [details] [diff] [review]
Add a StrokeOptionsCommand to store StrokeOptions data

Since we have copies of mDashes everywhere and to copy them, create a new StrokeOptions commands which does this for us.
Attachment #8886722 - Flags: review?(dvander)
Comment on attachment 8886722 [details] [diff] [review]
Add a StrokeOptionsCommand to store StrokeOptions data

Review of attachment 8886722 [details] [diff] [review]:
-----------------------------------------------------------------

::: gfx/2d/DrawCommand.h
@@ +74,5 @@
> +    // between now and replay.
> +    if (aStrokeOptions.mDashLength) {
> +      mDashes.resize(aStrokeOptions.mDashLength);
> +      mStrokeOptions.mDashPattern = &mDashes.front();
> +      PodCopy(&mDashes.front(), aStrokeOptions.mDashPattern, mStrokeOptions.mDashLength * sizeof(Float));

PodCopy does the sizeof(Float) for you.
Attachment #8886722 - Flags: review?(dvander) → review+

Comment 2

a year ago
Pushed by mchang@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/b25d6223cf67
Refactor out StrokeOptions from DrawCommands. r=dvander
https://hg.mozilla.org/mozilla-central/rev/b25d6223cf67
Status: NEW → RESOLVED
Last Resolved: a year ago
status-firefox56: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
You need to log in before you can comment on or make changes to this bug.