diff --git a/gfx/layers/basic/BasicLayersImpl.cpp b/gfx/layers/basic/BasicLayersImpl.cpp index de00ae807fa8..2551a9c2d6be 100644 --- a/gfx/layers/basic/BasicLayersImpl.cpp +++ b/gfx/layers/basic/BasicLayersImpl.cpp @@ -174,32 +174,6 @@ FillRectWithMask(DrawTarget* aDT, aDT->FillRect(aRect, SurfacePattern(aSurface, ExtendMode::CLAMP, Matrix(), aFilter), aOptions); } -void -FillWithMask(gfxContext* aContext, float aOpacity, Layer* aMaskLayer) -{ - AutoMaskData mask; - if (GetMaskData(aMaskLayer, &mask)) { - if (aOpacity < 1.0) { - aContext->PushGroup(gfxContentType::COLOR_ALPHA); - aContext->FillWithOpacity(aOpacity); - aContext->PopGroupToSource(); - aContext->SetMatrix(ThebesMatrix(mask.GetTransform())); - aContext->Mask(mask.GetSurface()); - } else { - aContext->Save(); - aContext->Clip(); - aContext->SetMatrix(ThebesMatrix(mask.GetTransform())); - aContext->Mask(mask.GetSurface()); - aContext->NewPath(); - aContext->Restore(); - } - return; - } - - // if there is no mask, just fill normally - aContext->FillWithOpacity(aOpacity); -} - BasicImplData* ToData(Layer* aLayer) { diff --git a/gfx/layers/basic/BasicLayersImpl.h b/gfx/layers/basic/BasicLayersImpl.h index 70039e978b2e..a9130460af63 100644 --- a/gfx/layers/basic/BasicLayersImpl.h +++ b/gfx/layers/basic/BasicLayersImpl.h @@ -94,7 +94,6 @@ void PaintWithMask(gfxContext* aContext, float aOpacity, Layer* aMaskLayer); // Fill the rect with the source, using a mask and opacity, if present -void FillWithMask(gfxContext* aContext, float aOpacity, Layer* aMaskLayer); void FillRectWithMask(gfx::DrawTarget* aDT, const gfx::Rect& aRect,