Bug 990338 - Remove FillWithMask since it's dead code. r=nical

This commit is contained in:
Matt Woodrow 2014-04-01 15:52:10 +08:00
Родитель c90effdac3
Коммит aa186f3408
2 изменённых файлов: 0 добавлений и 27 удалений

Просмотреть файл

@ -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)
{

Просмотреть файл

@ -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,