Closed
Bug 768067
Opened 12 years ago
Closed 11 years ago
Implement canvasRenderingContext2D.get/setLineDash
Categories
(Core :: Graphics: Canvas2D, defect)
Core
Graphics: Canvas2D
Tracking
()
RESOLVED
FIXED
mozilla27
Tracking | Status | |
---|---|---|
relnote-firefox | --- | 27+ |
People
(Reporter: peterv, Assigned: cabanier)
References
(Blocks 1 open bug, )
Details
(Keywords: dev-doc-complete, html5, Whiteboard: [parity with Safari, Chrome and IE])
Attachments
(2 files, 5 obsolete files)
8.54 KB,
patch
|
Details | Diff | Splinter Review | |
2.13 KB,
patch
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Comment 1•11 years ago
|
||
Assignee | ||
Updated•11 years ago
|
Attachment #813354 -
Flags: review?(roc)
Assignee | ||
Comment 4•11 years ago
|
||
Not sure about removing the moz methods. That would break current sites...
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → cabanier
Keywords: dev-doc-needed,
html5
Whiteboard: [parity with Safari, Chrome and IE]
Assignee | ||
Updated•11 years ago
|
Attachment #813354 -
Flags: review?(roc) → review?(bas)
Assignee | ||
Updated•11 years ago
|
Attachment #813354 -
Attachment is obsolete: true
Attachment #813354 -
Flags: review?(bas)
Comment 7•11 years ago
|
||
This Bug 768067, Bug 740284, Bug 683051 and Bug 809586 seem to overlap at least in part. Can somebody with the necessary knowledge (and privs) please clean up/merge and clarify the individual bugs & summaries?
Comment on attachment 815180 [details] [diff] [review] Add support for set/getLineDash and dash offset Review of attachment 815180 [details] [diff] [review]: ----------------------------------------------------------------- ::: content/canvas/src/CanvasRenderingContext2D.cpp @@ +2856,5 @@ > +CanvasRenderingContext2D::SetLineDash(const mozilla::dom::AutoSequence<double>& mSegments) { > + FallibleTArray<mozilla::gfx::Float>& dash = CurrentState().dash; > + dash.Clear(); > + > + for(mozilla::dom::AutoSequence<double>::index_type x = 0; x < mSegments.Length(); x++) { uint32_t type for 'x'. @@ +2859,5 @@ > + > + for(mozilla::dom::AutoSequence<double>::index_type x = 0; x < mSegments.Length(); x++) { > + dash.AppendElement(mSegments[x]); > + } > + if(mSegments.Length()%2) { // If the number of elements is odd, concatenate again Sapace after 'if' and 'for'. @@ +2867,5 @@ > + } > +} > + > +void > +CanvasRenderingContext2D::GetLineDash(nsTArray<double>& mSegments) const { This parameter should be called aSegments @@ +2871,5 @@ > +CanvasRenderingContext2D::GetLineDash(nsTArray<double>& mSegments) const { > + const FallibleTArray<mozilla::gfx::Float>& dash = CurrentState().dash; > + mSegments.Clear(); > + > + for(FallibleTArray<mozilla::gfx::Float>::index_type x = 0; x < dash.Length(); x++) { Space after 'for'. Also, you can make x 'uint32_t'. Easier to read.
Attachment #815180 -
Flags: review?(bas) → review+
Assignee | ||
Comment 10•11 years ago
|
||
Updated patch per roc's comments. Try server: https://tbpl.mozilla.org/?tree=Try&rev=e6dd13184378
Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
Comment 11•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/b16182c733bb
Flags: in-testsuite+
Keywords: checkin-needed
Comment 12•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/b16182c733bb
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
Updated•11 years ago
|
relnote-firefox:
--- → ?
Comment 14•11 years ago
|
||
(In reply to Rik Cabanier from comment #10) > Updated patch per roc's comments. The comments were not addressed.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 15•11 years ago
|
||
(In reply to :Ms2ger from comment #14) > (In reply to Rik Cabanier from comment #10) > > Updated patch per roc's comments. > > The comments were not addressed. I must have copied the wrong patch :-( Will fix this asap
Assignee | ||
Comment 17•11 years ago
|
||
Attachment #823033 -
Attachment is obsolete: true
Attachment #823033 -
Flags: review?(Ms2ger)
Attachment #823037 -
Flags: review?(Ms2ger)
Comment 18•11 years ago
|
||
Comment on attachment 823037 [details] [diff] [review] Fix incorrect style Review of attachment 823037 [details] [diff] [review]: ----------------------------------------------------------------- This is r=roc in comment 8.
Attachment #823037 -
Flags: review?(Ms2ger)
Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
Updated•11 years ago
|
Summary: Implement canvasRenderingContext2D.get/setLineDash and deprecate/remove mozDash → Implement canvasRenderingContext2D.get/setLineDash
Comment 19•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/222175ec725f
Keywords: checkin-needed
Comment 20•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/222175ec725f
Status: REOPENED → RESOLVED
Closed: 11 years ago → 11 years ago
Resolution: --- → FIXED
Updated•11 years ago
|
Comment 21•10 years ago
|
||
Reference: https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D.getLineDash https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D.setLineDash https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D.lineDashOffset Release notes: https://developer.mozilla.org/en-US/Firefox/Releases/27#Interfaces.2FAPIs.2FDOM
Keywords: dev-doc-needed → dev-doc-complete
Updated•2 years ago
|
You need to log in
before you can comment on or make changes to this bug.
Description
•