Closed
Bug 955917
Opened 11 years ago
Closed 11 years ago
Remove unused functions from nsSVGUtils
Categories
(Core :: SVG, defect)
Core
SVG
Tracking
()
RESOLVED
FIXED
mozilla29
People
(Reporter: longsonr, Assigned: longsonr)
Details
Attachments
(2 files)
4.89 KB,
patch
|
dholbert
:
review+
|
Details | Diff | Splinter Review |
6.52 KB,
patch
|
dholbert
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → longsonr
OS: Windows Vista → All
Hardware: x86 → All
Assignee | ||
Updated•11 years ago
|
Attachment #8355071 -
Attachment is patch: true
Attachment #8355071 -
Flags: review?(dholbert)
Comment 1•11 years ago
|
||
It looks like nsSVGUtils::SetupContextPaint (made into a private-to-nsSVGUtils.cpp function in this patch) is actually near-identical to SVGTextFrame::SetupContextPaint(). Seems like maybe we should keep the nsSVGUtils method public, and (perhaps in a separate bug) make SVGTextFrame share its code rather than reimplementing it.
Comment 2•11 years ago
|
||
Comment on attachment 8355071 [details] [diff] [review] utils.txt Definitely r=me on the rest, though (the non-SetupContextPaint-related, strictly-code-removal parts. Let's hold off on the SetupContextPaint tweak for now, since per above, I think there may be reasons to keep that function public.
Attachment #8355071 -
Flags: review?(dholbert) → review+
Assignee | ||
Comment 3•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/2343e90583b0
Flags: in-testsuite-
Assignee | ||
Updated•11 years ago
|
Whiteboard: [leave open]
Assignee | ||
Comment 4•11 years ago
|
||
Attachment #8355196 -
Flags: review?(dholbert)
Comment 5•11 years ago
|
||
Comment on attachment 8355196 [details] [diff] [review] part 2 >diff --git a/layout/svg/SVGTextFrame.cpp b/layout/svg/SVGTextFrame.cpp >--- a/layout/svg/SVGTextFrame.cpp >+++ b/layout/svg/SVGTextFrame.cpp >@@ -5582,56 +5582,26 @@ SVGTextFrame::SetupInheritablePaint(gfxC > const FramePropertyDescriptor* aProperty) > { > const nsStyleSVG *style = aFrame->StyleSVG(); > nsSVGPaintServerFrame *ps = > nsSVGEffects::GetPaintServer(aFrame, &(style->*aFillOrStroke), aProperty); > > if (ps && ps->SetupPaintServer(aContext, aFrame, aFillOrStroke, aOpacity)) { > aTargetPaint.SetPaintServer(aFrame, aContext->CurrentMatrix(), ps); >- } else if (SetupContextPaint(aContext, aFrame, aFillOrStroke, aOpacity, aOuterContextPaint)) { >+ } else if (nsSVGUtils::SetupContextPaint(aContext, aOuterContextPaint, >+ aFrame->StyleSVG()->*aFillOrStroke, We already looked up StyleSVG() above, so this last line can just be: style->*aFillOrStroke r=me with that Optional: I'd marginally prefer to have this part split this out from the second half of this patch (dropping PathExtentsToMaxStrokeExtents), because a function-swap is functionally different from unused-code-removal. (It's also conceivable that we'd want to back out the first piece, e.g. if the SetupContextPaint functions were subtly different in a way that we didn't notice; in that case, we wouldn't want to back out the second piece). If you do that, r=me on both pieces.
Attachment #8355196 -
Flags: review?(dholbert) → review+
Assignee | ||
Comment 6•11 years ago
|
||
Split out into another bug or split out into another patch in this bug?
Comment 7•11 years ago
|
||
I just meant a separate patch (in this bug is fine).
Comment 8•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/2343e90583b0
Assignee | ||
Comment 9•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/247d083cf4dd
Assignee | ||
Comment 10•11 years ago
|
||
https://tbpl.mozilla.org/?tree=Try&rev=32f4505415be
Assignee | ||
Comment 12•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/df7e0f8fa993
Whiteboard: [leave open]
Comment 13•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/df7e0f8fa993
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla29
You need to log in
before you can comment on or make changes to this bug.
Description
•