Bug 1077120 - Remove gfxContext::HasError(). r=Bas
--- a/gfx/thebes/gfxContext.cpp
+++ b/gfx/thebes/gfxContext.cpp
@@ -1154,23 +1154,16 @@ bool
gfxContext::PointInStroke(const gfxPoint& pt)
{
EnsurePath();
return mPath->StrokeContainsPoint(CurrentState().strokeOptions,
ToPoint(pt),
Matrix());
}
-bool
-gfxContext::HasError()
-{
- // As far as this is concerned, an Azure context is never in error.
- return false;
-}
-
void
gfxContext::RoundedRectangle(const gfxRect& rect,
const gfxCornerSizes& corners,
bool draw_clockwise)
{
//
// For CW drawing, this looks like:
//
--- a/gfx/thebes/gfxContext.h
+++ b/gfx/thebes/gfxContext.h
@@ -80,21 +80,16 @@ public:
* Return the raw cairo_t object.
* XXX this should go away at some point.
*/
cairo_t *GetCairo();
mozilla::gfx::DrawTarget *GetDrawTarget() { return mDT; }
/**
- * Returns true if the cairo context is in an error state.
- */
- bool HasError();
-
- /**
** State
**/
// XXX document exactly what bits are saved
void Save();
void Restore();
/**
** Paths & Drawing
--- a/layout/svg/nsSVGOuterSVGFrame.cpp
+++ b/layout/svg/nsSVGOuterSVGFrame.cpp
@@ -614,18 +614,16 @@ nsDisplayOuterSVG::Paint(nsDisplayListBu
aContext->ThebesContext()->Save();
// We include the offset of our frame and a scale from device pixels to user
// units (i.e. CSS px) in the matrix that we pass to our children):
gfxMatrix tm = nsSVGIntegrationUtils::GetCSSPxToDevPxMatrix(mFrame) *
gfxMatrix::Translation(devPixelOffset);
nsSVGUtils::PaintFrameWithEffects(mFrame, aContext, tm, &contentAreaDirtyRect);
aContext->ThebesContext()->Restore();
- NS_ASSERTION(!aContext->ThebesContext()->HasError(), "Cairo in error state");
-
#if defined(DEBUG) && defined(SVG_DEBUG_PAINT_TIMING)
PRTime end = PR_Now();
printf("SVG Paint Timing: %f ms\n", (end-start)/1000.0);
#endif
}
static PLDHashOperator CheckForeignObjectInvalidatedArea(nsPtrHashKey<nsSVGForeignObjectFrame>* aEntry, void* aData)
{