All classes deriving from nsIFrame that did not have any subclasses themselves
(at the time of writing this patch) have been marked with `final`.
Some other Layout classes have also been made final, but this was opportunistic
while working on nsIFrame subclasses, and is definitely not exhaustive, further
patches welcome; refer to bug 1332680.
Advantages of marking a class final include:
- Allowing the compiler to devirtualize some method calls (i.e., calling
virtual functions directly instead of going through the vtable),
- Indicating that the class is not currently subclassed,
- Preventing subclassing without being aware that this would remove the
finalization benefits of the parent class.
`final` does not signify that these classes should *never* be subclassed, this
is left for developers to decide.
Differential Revision: https://phabricator.services.mozilla.com/D5020
--HG--
extra : moz-landing-system : lando
This flag and function name are used for both basic shapes and path function,
so rename it. For now, we treat path() and other basic-shapes as the
different object (i.e. StyleSVGPath and StyleBasicShape), so I rename
these functions and mask flag.
Differential Revision: https://phabricator.services.mozilla.com/D3636
Create clip-path for the path function and reuse some APIs in
nsCSSClipPathInstance, so we don't have to update the code flow.
Differential Revision: https://phabricator.services.mozilla.com/D3635
We end up with three <svg:use> elements to update (lol), because the target (#c)
changes, since we create another element with that ID in the document via
outerHTML.
Differential Revision: https://phabricator.services.mozilla.com/D2650
--HG--
extra : moz-landing-system : lando
For each file touched in this patch, the file had an #include for nsContentUtils.h, but no other mentions of the string "nsContentUtils", nor any mention of its "ScriptBlocker"-related types. So these files likely don't need their nsContentUtils.h include anymore, and we can remove it to get a marginal win on build time/complexity.
Differential Revision: https://phabricator.services.mozilla.com/D3370
--HG--
extra : moz-landing-system : lando
Now that the content is not anonymous we don't need to exclude them explicitly.
This happens because anonymous content inside the shadow tree does report to be
inside the shadow tree, which is true but at the same time slightly footgunny.
In any case the other uses of the use shadow tree stuff are base-uri related,
and changing anon content's base uri in that case sounds like the right thing,
even though anon content shouldn't rely on those anyway.
Differential Revision: https://phabricator.services.mozilla.com/D3409
This is needed for patch 4.
This is based both on the wording in the spec and the discussion in
https://github.com/w3c/csswg-drafts/issues/2987, and also doesn't
support them for nsMathMLContainerFrame, which is similar to inlines and
ruby.
Differential Revision: https://phabricator.services.mozilla.com/D2815
--HG--
extra : rebase_source : b7e23fb248fa34957ca2d539134e872f5a03f5a8
Summary:
This fixes a couple fuzz bugs and prevents special-casing <svg:use> even more in
bug 1431255.
Unfortunately not as many hacks went away as I'd have hoped, since we still need
to match document rules, see the linked SVGWG issues.
But blocks_ancestor_combinators goes away, which is nice since it's on a very
hot path.
Test Plan: WPT for style invalidation, covered by existing tests otherwise.
Reviewers: heycam
Tags: #secure-revision
Bug #: 1450250
Differential Revision: https://phabricator.services.mozilla.com/D2154
MozReview-Commit-ID: C4mthjoSNFh
In the case of an invalid clip-path, the browser is supposed to discard the
mask entirely. In the non-webrender codepath this would happen
implicitly because the computed MaskUsage would have no flags set, and
so no actions would be taken on the gfxContext which contained the
display items rasterized so far. In the WebRender codepath, though, we
invoke the code on a A8 drawtarget that's zero-filled, so if PaintMask
fails to rasterize anything into it, it gets treated as a "mask everything
out" mask. Instead, this patch makes it so that we detect the scenario
where the computed MaskUsage is a no-op, and ensure that we don't apply
the mask in that case.
An alternative approach considered was to initialize the A8 drawtarget to
white instead of black but in cases where there is an actual mask, the
rest of the code assumes it is zero-filled and so that doesn't work.
MozReview-Commit-ID: Hw7nCiUXVJl
--HG--
extra : rebase_source : 241d550fa0ed1b3bd088c73d9565b166acbcece8
This patch is an automatic replacement of s/NS_NOTREACHED/MOZ_ASSERT_UNREACHABLE/. Reindenting long lines and whitespace fixups follow in patch 6b.
MozReview-Commit-ID: 5UQVHElSpCr
--HG--
extra : rebase_source : 4c1b2fc32b269342f07639266b64941e2270e9c4
extra : source : 907543f6eae716f23a6de52b1ffb1c82908d158a
I'm replacing non-failing calls to NS_NOTREACHED with MOZ_ASSERT_UNREACHABLE, but this NS_NOTREACHED fails when running the dom/svg/crashtests/412104-1.svg test. This assertion failure is bug 903785.
This patch DOES NOT fix the cause of the assertion failure (a missing TextNodeCorrespondenceProperty). It just replaces this failing NS_NOTREACHED with NS_ERROR because I can't replace with a fatal MOZ_ASSERT_UNREACHABLE.
MozReview-Commit-ID: 8ffEdO5W1zU
--HG--
extra : rebase_source : 618008591b516e3b4b51871debcd0cf177a3f5b1
extra : intermediate-source : 099e1bbbc5b43b67ad9324464e4eec2e33d7eaa3
extra : source : f95d808c6f81b656c680d1dd005236571dedee20
This was a memory-saving optimization introduced as part of dependencies for bug
686875, but a more general system landed in bug 77999 for Gecko and
https://github.com/servo/servo/pull/18509 for Servo.
So now it's probably even a bit of a pessimization (though probably not huge),
and given this causes bugs like bug 1462742, bug 1157592, and bug 1468145, and
fishiness like the one pointed out in this bug, we may as well remove it.
The performance impact of having to lookup through more rules should be minimal
given the bloom filter and the rule hash optimizations.
This makes me wonder whether we could remove the whole concept of on-demand UA
sheets, since they've caused pain, for example, when the frontend people try
loading <svg>s from NAC (since that triggers sheet loading from frame
construction, which is not good). I'm not concerned about loading mathml.css and
svg.css everywhere, though xul.css may not be as doable since it adds a bunch of
attribute-dependent selectors. Though on the other hand I asserted in the
xul.css code and we don't load it in content with <video> / <input
type="date/time/etc"> and such, afaict, so maybe now that legacy addons are gone
we can remove that sheet from content processes altogether.
MozReview-Commit-ID: 9JCWNZj6BkT
Those changesets which are related to animations introduced in bug 1462497
seems to cause new crashes. I think the first two changesets for the bug fixed
the original crash cases but the last two (i.e. these changesets) introduced
other crashes unfortunately.
MozReview-Commit-ID: 9LD2hIIXA2y
--HG--
extra : rebase_source : 102c5532128039dcf8274c214e17d58d9a1aa483
Change mStopColor, mFloodColor, and mLightingColor in nsStyleSVGReset.
MozReview-Commit-ID: KMRMtHk1jNK
--HG--
extra : rebase_source : c0c12fa811d17ab6fe0a5ceb31ff32ec585314e0
This ensures that the nsDisplaySVGWrapper's mFrame and its reference frame are the same frame: the nsSVGOuterSVGAnonChildFrame.
It'll also cause the nsDisplaySVGWrapper to be *inside* the nsDisplayTransform for the <svg> element's viewbox transform.
This patch reverts nsSVGOuterSVGFrame::BuildDisplayList to its pre-bug 1407938 form.
(That's the bug that introduced nsDisplaySVGWrapper.)
MozReview-Commit-ID: 3jCyP6Sj8x9
I don't think this part is necessary, but putting the patch up in case we decide we want to take it.
MozReview-Commit-ID: G0JTNddvZma
--HG--
extra : rebase_source : 442a6a563044c2c510f332f881d9fab55c4455be
Second test-case is because I initially made this code work with
display: contents. But then realised that display: contents meant allowing
Shadow DOM in there, which I don't really want to deal with right now.
MozReview-Commit-ID: HSjFbWEbPAb
--HG--
extra : rebase_source : 51b950d5e74e17b0200112a7d447b3e3b9414602
The old name no longer makes sense, since it no longer exports an spawn_task
symbol, and add_task is what we really care about.
MozReview-Commit-ID: IE7B8Czv8DH
--HG--
rename : testing/mochitest/tests/SimpleTest/SpawnTask.js => testing/mochitest/tests/SimpleTest/AddTask.js
extra : rebase_source : 03bca5aa69a7625a49b4455a6c96ce4c59de3a5a
This method is not a virtual call, and also looks nicer.
This patch was mostly generated by a Python script, but I manually
cleaned up the code in a few places where statements didn't need to be
split across multiple lines any more.
MozReview-Commit-ID: 8JExxqSRc59
--HG--
extra : rebase_source : df6330a89e8d65dfe7a6fda0c8cb9f9732302efc
When we finish decoding an image frame, we need to trigger reflow for the
frame containing a float with shape-outside: <image>, and delay the firing
of the document's onload event until that reflow is complete.
When we finish decoding an image frame, we need to trigger reflow for the
frame containing a float with shape-outside: <image>, and delay the firing
of the document's onload event until that reflow is complete.
AnimVal() is a DOM getter, and it flushes animations, which we don't want
in GetBBox() which is called from display list building cide and
FrameLayerBuilder.
This is consistent with most other methods that take a drawTarget parameter r=dholbert
--HG--
extra : amend_source : 77aa7f7d9cb19f9aa08014fff3b209dc151b75f3
-Wmissing-prototypes is a new optional warning available in clang ToT. It warns about global functions that have no previous function declaration (e.g. from an #included header file). These functions can probably be made static (allowing the compiler to better optimize them) or they may be unused.
Confusingly, clang's -Wmissing-prototypes is equivalent to gcc's -Wmissing-declarations, not gcc's -Wmissing-prototypes. A function prototype is a function declaration that specifies the function's argument types. C++ requires that all function declarations specify their argument types, but C does not. As such, gcc's -Wmissing-prototypes is a C-only warning about C functions that have no previous function *prototypes* (with argument types), even if a previous function *declaration* (without argument types) was seen.
MozReview-Commit-ID: FGKVLzeQ2oK
--HG--
extra : rebase_source : 81e62163bf41a5d5dd87abf5397e6e8c62ed4096
extra : source : 653a9fc279e2f6a6d066474a94a70d65ac703d6b
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm
MozReview-Commit-ID: 1Nc3XDu0wGl
--HG--
extra : source : 12fc4dee861c812fd2bd032c63ef17af61800c70
extra : intermediate-source : 34c999fa006bffe8705cf50c54708aa21a962e62
extra : histedit_source : b2be2c5e5d226e6c347312456a6ae339c1e634b0
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm
MozReview-Commit-ID: 1Nc3XDu0wGl
--HG--
extra : source : 12fc4dee861c812fd2bd032c63ef17af61800c70
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm
MozReview-Commit-ID: 1Nc3XDu0wGl
--HG--
extra : rebase_source : c004a023389f1f6bf3d2f3efe93c13d423b23ccd
Returning a zero-sized viewport in the case there's no shell / pres context.
For now, no other change yet. After this we can start tweaking the ShadowRoot
Stylist setup, and even try to return computed styles without a document \o/.
MozReview-Commit-ID: 3cT2PKQISri
It's good to save some copy constructor calls.
MozReview-Commit-ID: 6TveqwkOvc0
--HG--
extra : rebase_source : 02e678f985c074f6c972cf8478e233aa5e4607db
The core of this change is in gfxContext.*:
- change gfxContext::CurrentMatrix() and gfxContext::SetMatrix() to
return and take a Matrix respectively, instead of converting to
and from a gfxMatrix (which uses doubles). These functions therefore
will now match the native representation of the transform in gfxContext.
- add two new functions CurrentMatrixDouble() and SetMatrixDouble() that
do what the old CurrentMatrix() and SetMatrix() used to do, i.e.
convert between the float matrix and the double matrix.
The rest of the change is just updating the call sites to avoid round-
tripping between floats and doubles where possible. Call sites that are
hard to fix are migrated to the new XXXDouble functions which preserves
the existing behaviour.
MozReview-Commit-ID: 5sbBpLUus3U
This patch was generated automatically by the "modeline.py" script, available
here: https://github.com/amccreight/moz-source-tools/blob/master/modeline.py
For every file that is modified in this patch, the changes are as follows:
(1) The patch changes the file to use the exact C++ mode lines from the
Mozilla coding style guide, available here:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line
(2) The patch deletes any blank lines between the mode line & the MPL
boilerplate comment.
(3) If the file previously had the mode lines and MPL boilerplate in a
single contiguous C++ comment, then the patch splits them into
separate C++ comments, to match the boilerplate in the coding style.
MozReview-Commit-ID: EuRsDue63tK
--HG--
extra : rebase_source : 3356d4b80ff6213935192e87cdbc9103fec6084c
Summary:
The implementations of most SVGTextElement methods flush layout when they're
called. Any SVG <text> that is displayed normally will be reflowed by
SVGTextFrame::ReflowSVG, and any <text> that is in displayed SVG but is not
displayed directly (such as <text> under a <defs>) will be reflowed by
SVGTextFrame::ReflowSVGNonDisplayText. Prior to this fix the changed
code always assumed that one of these methods would reflow the text. However,
in the case that the SVG is under an HTML element that isn't itself ever
reflowed (such as if it's under an HTML <caption>) then the SVG text will
not be reflowed either and the invariants of the code are broken.
This patch modifies the functions that implement the SVGTextElement
methods to return an error code if the text has not been reflowed.
Note: I did try to reuse SVGTextFrame::ReflowSVGNonDisplayText in this
case, but I ran into problems. Given that this is an edge case and likely one
than normal authors will never run into I gave up trying to make that work for
now.
Reviewers: heycam
Bug #: 1402109
Differential Revision: https://phabricator.services.mozilla.com/D107
(Path is actually r=froydnj.)
Bug 1400459 devirtualized nsIAtom so that it is no longer a subclass of
nsISupports. This means that nsAtom is now a better name for it than nsIAtom.
MozReview-Commit-ID: 91U22X2NydP
--HG--
rename : xpcom/ds/nsIAtom.h => xpcom/ds/nsAtom.h
extra : rebase_source : ac3e904a21b8b48e74534fff964f1623ee937c67
After StyleBasicShape is set to StyleShapeSource, it's life cycle never go
beyond StyleShapeSource, so I make StyleBasicShape hold by a UniquePtr in
StyleShapeSource.
Also, replace all raw pointers to StyleBasicShape by UniquePtr in all APIs.
MozReview-Commit-ID: 1MfIFjP8TsQ
--HG--
extra : rebase_source : bdbbd47de57e0bc610e37913752ab8413f62588a
mTargetFrame is not a correct one, we should check the SVGStyle of 'frame'
object.
MozReview-Commit-ID: 3UNfbXkICkz
--HG--
extra : amend_source : 9fa5f095881fc3b92329a7d187f4d5926c43fed7
Now we no longer post InvalidateRenderingObservers change hint during post
traversal.
MozReview-Commit-ID: H3jJ1LKgJyV
--HG--
extra : rebase_source : 96d6bf77e6fc2b4b79882e5c7e5f43e087b56089
If the frame has opacity animation, we can't optimize it at all.
MozReview-Commit-ID: JQYiPvSaxEs
--HG--
extra : rebase_source : b344b56793ba93ac2f763a6cc7f16edcf06e8f7a
Both nsSVGMarkerProperty::DoUpdate and nsSVGPaintingProperty::DoUpdate call
nsSVGRenderingObserverProperty::DoUpdate which takes care of posting the
nsChangeHint_InvalidateRenderingObservers change hint. There is no need for
these methods to do that again.
nsReflowStatus::IsEmpty() assertions are added after DISPLAY_REFLOW in the
beginning of the Reflow().
A few Reflow() implementations have Reset() calls at the end which are left
in place by this patch (with an explanatory comment added to each). These
ending Reset()s are only needed for cases where a non-splittable frame
passes its own nsReflowStatus to a child's reflow method. Just in case the
child leaves a "not fully complete" value in the nsReflowStatus, the
non-splittable parent frame must clear out the nsReflowStatus before
returning, so that its own parent doesn't then try to split it.
MozReview-Commit-ID: 6Jj3jfMAqj4
--HG--
extra : rebase_source : e1fe6a775ad97e16a6d7cc224634ff962ccb0fbf
There are two callers of nsFilterInstance::PaintFilteredFrame:
1. nsSVGUtils::PaintFrameWithEffects at [1]
This function is used while painting a filtered element on a path which
display item painting is not supported yet, such as drawing elements inside a
indirect painted SVG object, such as a mask, a clipPath or a gradient object.
Let's say we have a masked element, which refers to an SVG mask, and there is
a filtered element inside that SVG mask.
Using nsFilterInstance::PaintFilteredFrame to paint that filtered frame in
the mask, we have to pass a gfxContext and a transform matrix to it. The
transform of the gfxContext 'target' that we pass in consists of a transform
from the referenced frame, of the masked frame, to the masked frame. We also
pass in a transform matrix 'aTransform', this matrix contains a transform
from the the masked frame to the filtered frame in *device units*, which
means it contains css-to-dev-px scaling factor.
2. nsSVGIntegrationUtils::PaintFilter at [2]
This function is used by normal display item painting.
The same, we pass a gfxContext 'context' and a transform matrix 'tm' into
nsFilterInstance::PaintFilteredFrame. The transform matrix of 'context'
consists of a transform from the referenced frame, of the filtered frame,
to this filtered frame, but the scale factor was taken out . The transform
matrix 'tm' we pass in contains scale transform from the referenced frame to
the filtered frame in *device unit*.
Inside nsFilterInstance::PaintFilteredFrame, we treat the transform matrix of
'aCtx' and 'aTransform' as parameters we pass in in #2 caller. So it can be
failed in #1. For example, if the filtered frame inside a masked frame has a
translation transform applied, since that translation was put in 'aTransfrom',
but we only use the scale factor of 'aTransform' in
nsFilterInstance::PaintFilteredFrame, translation factor disappears.
In this patch, I unified the definition of parameters of
nsFilterInstance::PaintFilteredFrame:
1. nsFilterInstance::PaintFilteredFrame(aCtx): the transform matrix of aCtx
should be a transform from the referenced frame to the filtered frame in
*css units*. Originally, the aCtx we passed in #1 is in device units, which
should be fixed; the aCtx we passed in #2 does not even include css scaling
factor, need be fixed too.
2. nsFilterInstance::PaintFilteredFrame(aTransform): this transform matrix
should contain only scaling factor in device units. And I removed it in the
end since I found we can get this value easily right inside the callee.
[1]
https://hg.mozilla.org/mozilla-central/file/ef585ac7c476/layout/svg/nsSVGUtils.cpp#l857
[2]
https://hg.mozilla.org/mozilla-central/file/ef585ac7c476/layout/svg/nsSVGIntegrationUtils.cpp#l1114
MozReview-Commit-ID: gRV128NyQv
--HG--
extra : rebase_source : 15d130babd07734c3c36e24e9ea8b5c4e5f7dbbf
This change makes the next patch free of doing Matrix to gfxMatrix conversion.
MozReview-Commit-ID: 8K9RNgjZPTw
--HG--
extra : rebase_source : 190a80c2580622b7866ddb4d80a161311e97a2f5
These tests no longer assert so we can remove the stylo annotations.
MozReview-Commit-ID: 7sWWTkoFp1G
--HG--
extra : rebase_source : e42f418ef1756a08bc0f11b02b42b2a1737deb76
All classes which have mCanvasTM declared as a member object are inherited from
nsSVGDisplayContainerFrame. We should just declare a protected member in the
base class and then remove mCanvasTM and duplicated implementaion of
GetCanvasTM & NotifySVGChanged in those derived classes.
MozReview-Commit-ID: 8f8EgFNEXHJ
--HG--
extra : rebase_source : 593e16d7b701061ca37b8ca8a6fe1de2292ea62d
In nsSVGUtils::GetBBox, we cache fill-gemorty's bbox in ObjectBoundingBoxProperty
of the given frame[1] so that we can just return the cache value without
recomputing bbox. Some new added flags, such as eUseFrameBoundsForOuterSVG,
prevent storing and reusing this cache value. This patch is trying to make this
cache mechanism work again.
[1]
https://hg.mozilla.org/mozilla-central/file/ef585ac7c476/layout/svg/nsSVGUtils.cpp#l1119
MozReview-Commit-ID: 8vWDzFi8qCw
--HG--
extra : rebase_source : 07725c856f77f95717f16e61a9838393b09f5789
When nsSVGUtils::getBBox is called on <use> element:
1. Call from SVGGraphicsElement::getBBox(WebAPI):
According to the spec, getBBox should return the bbox as the union box of
children in user space.
2. Call from mask/ clip-path or filter painting:
Since we want to paint those elements in the coordinate space formed by
<use>(bug 537623), getBBox should return the bbox as the union box of
children in coordinate system of <use>.
Depend on the use case, we return the bbox of an <use> element on different
coordinate system. In this patch, I bring in a new
flag(eInUserSpaceOfUseElement) so that nsSVGUtils::getBBox can return bbox on
different coordinate system accordingly.
MozReview-Commit-ID: FfZalTI8J0y
--HG--
extra : rebase_source : c33e980c00c450792b30f60f6aa01b53e1c5595c
The failure mode in the attached crashtest is an inconsistency in the flattened
tree. Specifically, we null out mVideoControls in an nsVideoFrame, but defer
the UnbindFromTree call on that NAC element, which measn that its mParent still
points to the nsVideoFrame's mContent. Because all this stuff runs off of script
runners, and the anonymous content destroyer is not guaranteed to run before
other potential script runners, we end up running arbitrary script while the
tree mismatch exists. This script calls back into ProcessPendingRestyles, which
causes trouble.
We could build a separate deferral mechanism, but it's not clear that we actually
need to defer the unbind anymore. The deferred unbind was added in bug 489008,
which predated a lot of simplifications in layout/dom interaction.
MozReview-Commit-ID: 1JYAhiXKVJC
This patch has no direct relation with this bug. When tracing the code, I noticed
those local nsSVGLength2 variables can be declared as const reference.
MozReview-Commit-ID: 6gkdlpv8W7H
--HG--
extra : rebase_source : 0b875b0a375e9254eec3d1c569274fae8edfdcfe
There are two overloads of nsSVGLength2::GetAnimValue:
1. float nsSVGLength2::GetAnimValue(nsSVGElement*) const;
2. float nsSVGLength2::GetAnimValue(SVGSVGElement*) const;
In Bug 265894, I created SVGViewportElement as a base class of SVGSVGElement.
SVGSVGElement::GetViewBoxTransform was moved to SVGViewportElement in that
refactoring. The local variable 'ctx' in that function was changed from
SVGSVGElement to SVGViewportElement, which when passed to
nsSVGLength2::GetAnimValue caused us to switch from calling the overload that
takes a SVGSVGElement to the overload that takes a nsSVGElement, which is not
what we want.
This patch changes the argument type of the nsSVGLength2::GetAnimValue overload
that takes an SVGSVGElement to take an SVGViewportElement instead, which causes
the GetAnimValue(ctx) calls in SVGViewportElement::GetViewBoxTransform to call
the correct GetAnimValue overload again.
MozReview-Commit-ID: 2cmgIoltYfY
--HG--
extra : rebase_source : b45282cc492cf067ecc3935b03cde243a69ef2b5
In while-loop [1],
1. The first SetMatrix call that I remvoed in this patch is totally useless,
we can just pass initialMatrix to contextPaint, instead of set initialMatrix
to aContenxt and read back from aContext and then pass it to contextPaint.
2. This function, SVGTextFrame::PaintSVG, is the only caller of
SetupStrokeGeometry, and it does not need SetupStrokeGeometry to setup matrix at
all, since it will be overwritten the transform matrix of aContext at several
lines below[2].
[1]
https://hg.mozilla.org/mozilla-central/file/5115e2dea29a/layout/svg/SVGTextFrame.cpp#l3658
[2]
https://hg.mozilla.org/mozilla-central/file/5115e2dea29a/layout/svg/SVGTextFrame.cpp#l3685
MozReview-Commit-ID: AlKQh4abbpa
--HG--
extra : rebase_source : e0dfd66ff25be0d7cffadecf9e3333bba10cff9b
(This patch is not relative to performance)
Rename this function since it has not relation with cario at all.
MozReview-Commit-ID: DHvrsVZAJ7B
--HG--
extra : rebase_source : 4994c9058bd93c7d6671e57ce7f204185e679a1a
Unless we need to draw stroke of glyphs, which will change the state of the
target context, we only need to save & restore transform matrix of the target
context.
MozReview-Commit-ID: LLKnxrKrDaT
--HG--
extra : rebase_source : 1226c48d283a04cb0ea6959f12fd6938fece49d2
nsDisplaySVGText::Paint calls SVGTextFrame::PaintSVG, and we already save/restore
context state in SVGTextFrame::PaintSVG.
I also filed Bug 1385929 to find a solution to prevent duplicated
gfxContext::Save/Restore.
MozReview-Commit-ID: 4WxdFZzvmvF
--HG--
extra : rebase_source : 752d5d027776538edc1ab043ad2e90e1de22a079
I've been having problems with interdiffs on mozreview lately, so for
ease of review, this patch is being submitted as a seperate patch for
review. Once it is r+'d, it will be folded into the first patch in
this set before landing.
MozReview-Commit-ID: CS9MngaXlBd
--HG--
extra : rebase_source : 6a86fd4f7a66e73497a756976a2562d183002a2a
nscoord_MAX is (1<<30) so that we can check for overflow *after* adding
two nscoords. However, (nscoord_MAX + nscoord_MAX) will still overflow.
Subtracting one makes this no longer possible.
MozReview-Commit-ID: BtbQRMp5kWm
nscoord_MAX is (1<<30) so that we can check for overflow *after* adding
two nscoords. However, (nscoord_MAX + nscoord_MAX) will still overflow.
Subtracting one makes this no longer possible.
MozReview-Commit-ID: BtbQRMp5kWm
One thing to note here is that the Scale function on gfxRect has a
different implementation than that in gfx::Rect which is replacing it.
The former just scales the width/height directly whereas the latter
scales the XMost/YMost and recomputes the width/height.
MozReview-Commit-ID: 5FImdIaNfC3
--HG--
extra : rebase_source : 98662d2a52ff9652ec60b066641a07c6d5ee8e08
Most of this patch is updating a few places that use gfxMatrix to use
the equivalent-but-differently-named functions on MatrixDouble:
- Translate/Rotate/Scale get turned into PreTranslate/PreRotate/PreScale
- Transform(Point) gets turned into TransformPoint(Point)
- gfxMatrix::TransformBounds(gfxRect) gets turned into
gfxRect::TransformBoundsBy(gfxMatrix).
- gfxMatrix::Transform(gfxRect) gets turned into
gfxRect::TransformBy(gfxMatrix).
The last two functions are added in this patch as convenience wrappers
to gfxRect instead of Matrix.h because we don't want Matrix.h to "know"
about gfxRect (to avoid adding gecko dependencies on Moz2D). Once we
turn gfxRect into a typedef for RectDouble these will be eliminated
anyway.
MozReview-Commit-ID: BnOjHzmOSKn
--HG--
extra : rebase_source : cf1692d1f0d44a4b05d684a66678739181a426d5
This extracts a BaseMatrix template of which Matrix is now a particular
specialization. The BaseMatrix allows us to reuse the same code for
floats and doubles, much like the other "base" classes (BasePoint,
BaseRect, etc.).
MozReview-Commit-ID: HO7bA83S9E0
--HG--
extra : rebase_source : dcd84d9a978cdea00bb54eb11eefcca9c6635901
Most of the changes in this patch are just using the explicit
constructor from gfx::IntSize to gfx::Size, since gfxSize did
that implicitly but gfx::Size doesn't.
MozReview-Commit-ID: CzikGjHEXje
--HG--
extra : rebase_source : 9d19977f2a774d9a2a653db923553a6c2e06f82a
The spec said:
The generated instance of a ‘symbol’ that is the direct referenced element of a
‘use’ element must always have a computed value of inline for the display
property. In other words, it must be rendered whenever the host ‘use’ element is
rendered.
We use -moz-use-shadow-tree-root pseudo class to achieve this requirement.
MozReview-Commit-ID: 1ReJjmjxq6G
--HG--
extra : rebase_source : b4d267792dd6d69f7d5336c5ed33a0fc60e97b9e
Since we already have nsSVGSymbolFrame, there is no need to leverage svg element
for rendering symbol element in use-element shadow tree, remove conversion code.
MozReview-Commit-ID: GmGLZ7Az6Gb
--HG--
extra : rebase_source : 897a1fb7b34bb3aa3babe99b7199e7f002d59e6b
As I've said before, as module owner I prefer that MOZ_ASSERT_IF not be
used in the module because I consider it to be unreadable. However, a
few uses have crept in, and this patch removes them.
I consider it to be unreadable because the name looks like a name that
uses smalltalk-ish naming conventions, i.e., with a part of the name
corresponding to each parameter, in order. However, the parameters are
in the order opposite the name.
This was written primarily with the vim commands:
:%s/MOZ_ASSERT_IF(\([^,]*\),/MOZ_ASSERT(!\1 ||/
:wn
followed by manual cleanup for indentation and removal of !!.
MozReview-Commit-ID: G6rLbOn7k8d
nsIFrame::mClass is of type enum class nsQueryFrame::ClassID which is
a strict subset of the nsQueryFrame::FrameIID values. For a concrete
frame class, its FrameIID is the same numeric value as its ClassID.
MozReview-Commit-ID: 1N0AkCGo1ol
Remove HasUserSpaceOnUseUnitsMaskOrClipPath since it's not necessary.
MozReview-Commit-ID: 2sen23m5GjE
--HG--
extra : rebase_source : fe15fc807daf79f6f2175224928a1d83736cf85b
The reason of this change is the same as for Part 2, except that this commit fixes
nsSVGPaintServerFrame::GetPaintServerPattern rather than PaintSVG.
Commit-ID: 691YrKZ0Lm9
MozReview-Commit-ID: KSnFhCndFUk
The reason of this change is the same as for Part 2, except this commit fixes
nsSVGMaskFrame::GetMaskForMaskedFrame rather than PaintSVG.
MozReview-Commit-ID: DS0eG6eKDgs
The DrawResult return was not in fact anything to do with the success or
failure of that method, but was actually passing out a very specific piece of information
about the success or failure of any imagelib drawing that may not have occurred
under the various PaintSVG calls.
The signature of PaintSVG is changed from
DrawResult PaintSVG(...., uint32 flags);
to
void PaintSVG(...., imgDrawingParams& aPackage);
imgDrawingParams wraps DrawResult and imgIContainer::FLAG_* as a pack, pass through
PaintSVG to imagelib draw calls under beneath.
MozReview-Commit-ID: IOq2evUAOQF
The primary patch in bug 1308876 causes frames to be reflowed less often
with NS_FRAME_IS_DIRTY, particularly when multiple passes of reflow are
required for the frame or one of its ancestors (which is generally the
case for a document that ends up not having scrollbars). This change
causes this assert to fire on various SVG tests such as
layout/reftests/svg/svg-integration/conditions-outer-svg-01.xhtml .
This happens because the outer SVG with conditional processing (in this
test, systemLanguage="x") is reflowed due to its parent resizing,
without NS_FRAME_IS_DIRTY set. This is a relatively normal thing to
happen during reflow; we just didn't have any tests that exercise it.
This patch adds a crashtest that triggers the assertion through the same
mechanism, but with a dynamic change, rather than depending on the
non-dirty reflow triggered by bug 1308876. (I confirmed locally that
this test does trigger the assertion without this patch, when run in the
crashtest harness.)
I think fundamentally the assertion isn't valid, and we should instead
be testing the condition that it asserts.
MozReview-Commit-ID: D8hjAbjKyuL
--HG--
extra : transplant_source : %98C%3A%B1%93jb%E7%3D%81%19%97%A6%04%0F%88%8B%D2%A35
The reason of this change is the same as for Part 2, except that this commit fixes
nsSVGPaintServerFrame::GetPaintServerPattern rather than PaintSVG.
Commit-ID: 691YrKZ0Lm9
MozReview-Commit-ID: KSnFhCndFUk
--HG--
extra : rebase_source : 3397613129fff6023833cdc3bd639f0d2b151652
extra : source : fa29f1920a88d88bcf0f5239462d32ee8955895c
The reason of this change is the same as for Part 2, except this commit fixes
nsSVGMaskFrame::GetMaskForMaskedFrame rather than PaintSVG.
MozReview-Commit-ID: DS0eG6eKDgs
--HG--
extra : rebase_source : 696bf495edc98a390f49ff0638165724521460b1
extra : source : 95f38c2c8b57134504e7fbe03d1637866e3e65ba
The DrawResult return was not in fact anything to do with the success or
failure of that method, but was actually passing out a very specific piece of information
about the success or failure of any imagelib drawing that may not have occurred
under the various PaintSVG calls.
The signature of PaintSVG is changed from
DrawResult PaintSVG(...., uint32 flags);
to
void PaintSVG(...., imgDrawingParams& aPackage);
imgDrawingParams wraps DrawResult and imgIContainer::FLAG_* as a pack, pass through
PaintSVG to imagelib draw calls under beneath.
MozReview-Commit-ID: IOq2evUAOQF
--HG--
extra : rebase_source : 66c9a9e391c2f9e142575f42fd47b37334ec5752
extra : source : 97a08873177c0f18edffdb1b5589c77843a50553
GetPreEffectsVisualOverflowRect is a function that be used in both reflowing
and painting. PreEffectsBBoxProperty of continuations is not set correctly yet
in reflow process, so we should skip this assertion check during reflow.
PS:
I will change MOZ_ASSERT, in GetPreEffectsVisualOverflowRect, back to NS_ASSERTION
if we still encounter this assertion in the future.
MozReview-Commit-ID: 6Gvg3XOd2mD
--HG--
extra : rebase_source : 88f605dc3aa2fd63fbe60925c0a21cc370ff3b6b
extra : amend_source : 0fb6a36486d7a96546e3362393d8501744ebdc34
This avoids conflicts with mozilla::dom::FrameType.
MozReview-Commit-ID: 7aEMbHRaTFk
--HG--
extra : rebase_source : 2d01321f5ce0ec8c0e3f70984674f82678034b3c
ResolveURLUsingLocalRef is designed to be internally used by
nsSVGEffects::Get-{SVGEffect}-URI functions. Since we also need it in
SVGUseElement::LookupHref, make it public in nsSVGEffects.
MozReview-Commit-ID: Hsvs8Uzahrz
--HG--
extra : rebase_source : 54698a477a2ebb3f635fb3a77f6bc39b1741b05b
Now, remove Layer::mSourceURI, there are several benefit of doing this:
1. Reduce the size of nsStyleImage::Layer.
2. By storing style image and url information in nsStyleImage, we can remove
many verbose comments. That is becasue there is no need to explain why we use
mSourceURI here, or why we use nsStyleImage there anymore.
3. Since all inforamtion is stored in on place, nsStyleImage, we can setup image
request or URLs by one single Gecko_SetUrlImageValue call.
MozReview-Commit-ID: 7aTQobddTB1
--HG--
extra : rebase_source : 247e3b66c727a9116c58d3d6ff3ae0f7a58f2338
Previously if an outer-<svg> had children-only transforms we would create
an nsDisplayTransform display list item for every child of the <svg> element.
For certain SVG files this could cause performance problems. This commit makes
us create a single nsDisplayTransform for the nsSVGOuterSVGFrame's anonymous
child frame rathen than one nsDisplayTransform for every real child.
Add one paramater to nsSVGDisplayableFrame::PaintSVG, so that we can pass
sync-decode flag from nsXXXXDisplayItem::Paint function to SVG paint call.
MozReview-Commit-ID: 6VZbxnFaoUj
--HG--
extra : rebase_source : c55e457e0d7a81b4a574d970924e0af6f7a7db48
According to bug 1345853 comment 5, tn said:
You probably want to return whatever was drawn there regardless of the
DrawResult. SVGMaskFrame has the same problem. Keep in mind that DrawResult is
only reporting on how drawing of any images went, not the drawing of anything
else. Also looking over the patches from bug 1258510 I see a couple places where
BAD_ARGS is returned if the transform matrix is singular. We would want to
return SUCCESS in that case I think, because we drew what we were instructed to
draw.
MozReview-Commit-ID: 5XcDuKQwXTJ
--HG--
extra : rebase_source : 5c558d469148e0cb3cfe9365aed1a4a65c572532
I did many change in many files in this patch. But the goal is pretty simple: To
pass the return value of nsSVGPatternFrame::PaintPattern back to the caller
(nsDisplaySVGGeometry). My suggestion is to review this patch right from
nsSVGPatternFrame.cpp.
I made two mistakes in bug 1258510
1. We should not return directly at [1]. RemoveStateBits at l418 will be skip.
2. nsSVGPatternFrame::PaintPattern should return both SourceSurface and draw
result, so that we can update UpdateDrawResult in display item.
All the other changes are to
1. make sure the return value of nsSVGPatternFrame::PaintPattern goes back to
nsDisplaySVGGeometry::Paint correctly.
2. Since the return value of nsSVGPatternFrame::PaintPattern change, we need
modify all existed callers.
I also filed bug 1346124 for handle the returning value of PaintMarkers.
[1] https://hg.mozilla.org/mozilla-central/file/c0700bedb4f7/layout/svg/nsSVGPatternFrame.cpp#l415
MozReview-Commit-ID: Iq9RPQ6Omz0
--HG--
extra : rebase_source : ca7a35bb9f5e27880d5dc62e03feb91b6ac3435d
This change makes SVGEmbeddingContextPaint's GetFillPattern and
GetStrokePattern methods honor their opacity arguments as they should. Since
these arguments must affect the gfxPattern that is returned, the code now
creates those on demand rather than creating them up front and caching them.
MozReview-Commit-ID: 4oemU2nRMeQ
Implement this unil function to improve readability
MozReview-Commit-ID: FLKOGyq180W
--HG--
extra : rebase_source : db8dbc67dbc63c19df806e79ea36016d3d5fc8b6
extra : source : 47fa0a1f03acd6007e2d40e4ec5bc0ddba221361
This is a bug from https://hg.mozilla.org/mozilla-central/rev/2d171d75b746 (bug 1157546). It took a shortcut in trying to get around one of the downsides of tracking visibility on frames instead of content nodes.
We cannot get our primary frame during FrameCreate calls because FrameCreate is called during the frame's Init() function, which happens before the primary frame pointer is set.
So when TrackImage is called from FrameCreate |frame| will be null but mFrameCreateCalled will be true. So we won't hit the early return that tries to detect nonvisible images.
The comment being removed is just wrong. We can obtain a frame for <feImage> just as well as any other image type.
The thing that is different about <feImage> is that it calls IncApproximateVisibleCount() followed by FrameCreated() in the frame's Init() function. This means that the frame is marked visible at the time of the FrameCreated, and there will be no further calls to TrackImage (because there are no further changes). So the FrameCreated call is the last chance to mark this image visible. The regressing changeset tries to get around this by just considering the image visible whenever we know a frame exists (because of mFrameCreateCalled) but can't access it. This ends up affecting all types of images, not just <feImage>.
The above paragraph is also true for SVG <image> that are non-display.
This function is not a virtual function and always returns CAIRO_STATUS_SUCCESS
after the patch in bug 1054838 landed. There is no reason to keep it anymore.
MozReview-Commit-ID: EadrrFQyjfY
--HG--
extra : rebase_source : 3f6a284dc9fa396d5cfd3f64190562373801a0a2
According to bug 1345853 comment 5, tn said:
You probably want to return whatever was drawn there regardless of the
DrawResult. SVGMaskFrame has the same problem. Keep in mind that DrawResult is
only reporting on how drawing of any images went, not the drawing of anything
else. Also looking over the patches from bug 1258510 I see a couple places where
BAD_ARGS is returned if the transform matrix is singular. We would want to
return SUCCESS in that case I think, because we drew what we were instructed to
draw.
MozReview-Commit-ID: 5XcDuKQwXTJ
--HG--
extra : rebase_source : ba764df599844c9eb179736f61d6c7f6ee46c9fc
I did many change in many files in this patch. But the goal is pretty simple: To
pass the return value of nsSVGPatternFrame::PaintPattern back to the caller
(nsDisplaySVGGeometry). My suggestion is to review this patch right from
nsSVGPatternFrame.cpp.
I made two mistakes in bug 1258510
1. We should not return directly at [1]. RemoveStateBits at l418 will be skip.
2. nsSVGPatternFrame::PaintPattern should return both SourceSurface and draw
result, so that we can update UpdateDrawResult in display item.
All the other changes are to
1. make sure the return value of nsSVGPatternFrame::PaintPattern goes back to
nsDisplaySVGGeometry::Paint correctly.
2. Since the return value of nsSVGPatternFrame::PaintPattern change, we need
modify all existed callers.
I also filed bug 1346124 for handle the returning value of PaintMarkers.
[1] https://hg.mozilla.org/mozilla-central/file/c0700bedb4f7/layout/svg/nsSVGPatternFrame.cpp#l415
MozReview-Commit-ID: Iq9RPQ6Omz0
--HG--
extra : rebase_source : bc338b1a33f1dbf209706577b2455315dfb855e2
This change fixes the code so that it does not assume that frames with the
NS_FRAME_SVG_LAYOUT bit set implement nsISVGChildFrame. This assumption is
incorrect since there are many SVG frame types that do not inherit
nsISVGChildFrame (such as nsSVGGradientFrame).
MozReview-Commit-ID: 9dCZAhJk3E0
--HG--
extra : rebase_source : 346755b3215b38560ab57e87cf12585b4a869d65
I introduced ComputeTargetBBoxInFilterSpace[1] function in bug 1287492.
Two reasons that I think we should not clip filter boundary by viewport
in that function:
1. The patch in bug 1336480 can also fix bug 1287492 and is more correct.
2. That restriction cause wrong rendering result
In this bug, reporter apply filter onto a path object in pattern element.
Before the clipping applied in [1], the boundary of filter effects region is
(x=-1, y=-1, width=10, height=10) in CSS units
After clipping by svg viewport, the boundary turns out to be
(x=0, y=0, width=9, height=9) in CSS units
which is smaller then we need for filter painting. So we should stop clip the
boundary by svg viewport. (Please refer to filter-in-pattern-02.svg in the next
patch).
[1] https://hg.mozilla.org/mozilla-central/file/dbabc189256e/layout/svg/nsFilterInstance.cpp#l235
MozReview-Commit-ID: 2d14rnyWPJs
--HG--
extra : rebase_source : ca3a523c8ae95d166441690d5ee1def2ed56a550
There are two places that use nsFilterInstance::PaintFilteredFrame. One is
nsSVGIntegrationUtil::PaintFilter, we do take care of it in bug 1224207.
Another path is at nsSVGUtils::PaintFrameWithEffects, apparently I missed that
path while working on bug 1224207.
MozReview-Commit-ID: K4MjKa4ZpCR
--HG--
extra : rebase_source : 46696b620b210348052fe554b15abf0c3adedc72
Specifically:
- SVGGeometryFrame.cpp has several uses the type SVGGeometryElement which is
really mozilla::dom::SVGGeometryElement. So I'm adding a 'using' decl for
the 'mozilla::dom' namespace (and I'm dropping a now-unnecessary explicit
dom:: prefix from another type there).
- SVGImageContext.cpp calls several functions on nsIFrame (PresContext() &
StyleSVG() at least). So I'm adding an #include for nsIFrame.h.
- nsSVGMarkerFrame.cpp uses the type SVGGeometryFrame, which is really
mozilla::SVGGeometryFrame. So I'm adding a 'using' decl for
the 'mozilla' namespace.
MozReview-Commit-ID: AlCrocHhPtr
--HG--
extra : rebase_source : 8fe64f35179954813c00188587e0d7724f17791c
These only build successfully (in unified mode) right now because they're lucky
enough to pick up a "using namespace mozilla;" declaration from a .cpp file
earlier in their unified compilation unit.
MozReview-Commit-ID: JylaTtjdSZu
--HG--
extra : rebase_source : 5233e0322556f2494745fa6ece6ea0fd6af23fec
SVG <image> elements have approximately the same level of visibility tracking as regular html <img>s so we shouldn't need to do sync decode. It shows up in some profiles.
The comment being removed was written a long time ago, before image visibility tracking for one.
We could even go a step further and ask for no sync decoding at all, but one step at a time to make sure this doesn't cause any regressions.
This patch is written by the following script with some manual adjustment to
the comment in nsRubyTextContainerFrame.cpp and nsRubyFrame.cpp, and
nsColumnSetFrame's constructor.
function rename() {
find layout\
-type f\
\( -name "*.cpp" -or\
-name "*.h" \)\
-exec sed -i -r "s/$1/$2/g" "{}" \;
}
rename "nsReflowStatus *([a-zA-Z0-9]*) = NS_FRAME_COMPLETE" "nsReflowStatus \1"
rename "([a-zA-Z0-9.*]*) *= NS_FRAME_COMPLETE;" "\1.Reset();"
rename "([a-zA-Z0-9.*]*) == NS_FRAME_COMPLETE" "\1.IsEmpty()"
MozReview-Commit-ID: 9tqQAHvdQex
--HG--
extra : rebase_source : 3119776946dc2c8350098b7bf9f3ceff29bdffb5
There is no need to limit output space bounds in
nsFilterInstance::OutputFilterSpaceBounds(), it's just far too early.
MozReview-Commit-ID: 9i9huKDGxq6
--HG--
extra : rebase_source : 3f7a16fe27f661e79087c6a302235b01f65169d5
For a table, the primary frame is the table wrapper anonymous box. That
anonymous box inherits style from its _child_ table frame, which is the frame that
has the actual style for the element. So we want to use the stylo-computed
style for the table frame, and then compute an updated style for the table
wrapper too, because some things (like absolute positioning) are done for the
table wrapper anonymous box, not the table frame.
Except during restyle process, we should skip this checking in reflow as well.
But what really should do is to skip this checking if this function is called
from ComputeEffectsRect. The reason is explained in the beginning of
ComputePostEffectsVisualOverflowRect.
Also promote NS_ASSERTION to MOZ_ASSERTION in this patch.
MozReview-Commit-ID: 3CuKkdR4kTK
--HG--
extra : rebase_source : 968f708603ec4424dd32f23bf2a4ffc74ce3fc85
1.
mUserSpaceBounds & GetFilterSpaceBounds are not used at all. This patch is
simply removing mUserSpaceBounds and codes relative to them.
2.
GetFilterSpaceBounds is defined but not used. Remove.
MozReview-Commit-ID: 7vJmZP4jC5F
--HG--
extra : rebase_source : 6798c938a4e3b1ab513dcc3b3f6da293fda45e1f
According to jwatt's suggestion, rename back to original name.
MozReview-Commit-ID: 8dUo7ZWoac6
--HG--
extra : rebase_source : 0beb263ca4c99597661da37dca14943637fd4e9e
After fighting with this assertion several months, I decided to remove it for
two reasons:
This assertion allows PreEffectBBoxProperty not being cached only under specific
condition. But the condition is wider then we expect.
1.
PreEffectsBBoxProperty is cached by nsIFrame::FinishAndStoreOverflow(this
function calls ComputeEffectsRect which cache this property actually) and
it is called from nsXXXFrame::Reflow on demand. Yes, *on demand*, not always.
And this is the fist reason that why I think we should just remove
this assertion.
For example, nsBlockFrame::Reflow calls FinishAndStoreOverflow to store this
property. But like BRFrame, it does not call FinishAndStoreOverflow at all.
In anohter word, if you apply any SVG effect to a BRFrame, you will always hit
this assertion. Here is an example:
<br style="filter: saturate(0%);"/>
So, if we still want to keep this assertion, we may need to create a list which
list all frame types that cache PreEffectsBBoxProperty, and do this check only if
the type of aFrame is listed. This is error prone since we may introduce a
new frame type at any time and forget to update this table.
2.
So, I think it's better just removing this assertion. The assertion that we
really need is the next one(2nd one):
MOZ_ASSERT(!preTransformOverflows,
"GetVisualOverflowRect() won't return the pre-effects rect!");
Since hitting that assertion, the 2nd one, means caller will retrieve wrong
effect region. Hitting the first assertion only means we do not cache
PreEffectsBBoxProperty, it's pretty normal and not hurt anything. This is the
second reason that I think we should remvoe this assertion.
MozReview-Commit-ID: JfiYTiP2laG
--HG--
extra : rebase_source : b0225e36cd7e33a23516cfbe5a40c731d92f8825
Clip mTargetBBoxInFilterSpace by the bounds of parent SVG frame. Fix this bug and
good for both rendering performance and memory consumption.
The root cause of this bug
<svg width="100" height="100" style="filter: opacity(100%);">
<g transform="matrix(200,0,0,200,-20000,-20000)">
<rect width="200" height="200" style="fill:lime">
</g>
</svg>
In this example, <rect> is going to be a huge graphic object because of the scale
transform in <g>. The bounding-box of <svg> is an union of all descedants, so the
size of mTargetBBoxInFilterSpace is huage too. We are not able to create such a
huge surface because of the limitation at
nsFilterInstance::OutputFilterSpaceBounds[1].
[1] https://hg.mozilla.org/mozilla-central/file/f4f6790e3926/layout/svg/nsFilterInstance.cpp#l556
MozReview-Commit-ID: 4Fdj5mgcE0V
--HG--
extra : rebase_source : 00b668933255cc9ea4a5f5e4fddc6d2f509c41c7
GetNearestSVGViewport is not used anymore, rewrite it, Part 3 will need this new
version.
MozReview-Commit-ID: GNJXICG9akj
--HG--
extra : rebase_source : 7498404cdafca7563ad93d685efac7c606a7ff0b