mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 952977: Switch GetMarkerTransform to gfx::Matrix r=nical
This commit is contained in:
parent
a574e57920
commit
9ebab3c8b3
@ -296,7 +296,7 @@ SVGMarkerElement::GetPreserveAspectRatio()
|
||||
//----------------------------------------------------------------------
|
||||
// public helpers
|
||||
|
||||
gfxMatrix
|
||||
gfx::Matrix
|
||||
SVGMarkerElement::GetMarkerTransform(float aStrokeWidth,
|
||||
float aX, float aY, float aAutoAngle,
|
||||
bool aIsStart)
|
||||
@ -317,9 +317,9 @@ SVGMarkerElement::GetMarkerTransform(float aStrokeWidth,
|
||||
break;
|
||||
}
|
||||
|
||||
return gfxMatrix(cos(angle) * scale, sin(angle) * scale,
|
||||
-sin(angle) * scale, cos(angle) * scale,
|
||||
aX, aY);
|
||||
return gfx::Matrix(cos(angle) * scale, sin(angle) * scale,
|
||||
-sin(angle) * scale, cos(angle) * scale,
|
||||
aX, aY);
|
||||
}
|
||||
|
||||
nsSVGViewBoxRect
|
||||
|
@ -121,9 +121,9 @@ public:
|
||||
virtual bool HasValidDimensions() const MOZ_OVERRIDE;
|
||||
|
||||
// public helpers
|
||||
gfxMatrix GetMarkerTransform(float aStrokeWidth,
|
||||
float aX, float aY, float aAutoAngle,
|
||||
bool aIsStart);
|
||||
mozilla::gfx::Matrix GetMarkerTransform(float aStrokeWidth,
|
||||
float aX, float aY, float aAutoAngle,
|
||||
bool aIsStart);
|
||||
nsSVGViewBoxRect GetViewBoxRect();
|
||||
gfxMatrix GetViewBoxTransform();
|
||||
|
||||
|
@ -86,11 +86,11 @@ nsSVGMarkerFrame::GetCanvasTM(uint32_t aFor, nsIFrame* aTransformRoot)
|
||||
gfxMatrix markedTM = mMarkedFrame->GetCanvasTM(aFor, aTransformRoot);
|
||||
mInUse2 = false;
|
||||
|
||||
gfxMatrix markerTM = content->GetMarkerTransform(mStrokeWidth, mX, mY,
|
||||
mAutoAngle, mIsStart);
|
||||
Matrix markerTM = content->GetMarkerTransform(mStrokeWidth, mX, mY,
|
||||
mAutoAngle, mIsStart);
|
||||
gfxMatrix viewBoxTM = content->GetViewBoxTransform();
|
||||
|
||||
return viewBoxTM * markerTM * markedTM;
|
||||
return viewBoxTM * ThebesMatrix(markerTM) * markedTM;
|
||||
}
|
||||
|
||||
static nsIFrame*
|
||||
@ -184,11 +184,11 @@ nsSVGMarkerFrame::GetMarkBBoxContribution(const Matrix &aToBBoxUserspace,
|
||||
mAutoAngle = aMark->angle;
|
||||
mIsStart = aMark->type == nsSVGMark::eStart;
|
||||
|
||||
gfxMatrix markerTM =
|
||||
Matrix markerTM =
|
||||
content->GetMarkerTransform(mStrokeWidth, mX, mY, mAutoAngle, mIsStart);
|
||||
gfxMatrix viewBoxTM = content->GetViewBoxTransform();
|
||||
|
||||
Matrix tm = ToMatrix(viewBoxTM * markerTM) * aToBBoxUserspace;
|
||||
Matrix tm = ToMatrix(viewBoxTM) * markerTM * aToBBoxUserspace;
|
||||
|
||||
nsISVGChildFrame* child = do_QueryFrame(GetAnonymousChildFrame(this));
|
||||
// When we're being called to obtain the invalidation area, we need to
|
||||
|
Loading…
Reference in New Issue
Block a user