Bug 1141917 - Remove unused member function RectTextureImage::UpdateFromDrawTarget(). r=mstange

This commit is contained in:
Chris Peterson 2015-03-10 21:21:56 -07:00
parent 530e295577
commit 89ae8d79ca

View File

@ -318,10 +318,6 @@ public:
const nsIntRegion& aDirtyRegion,
CGContextRef aCGContext);
void UpdateFromDrawTarget(const nsIntSize& aNewSize,
const nsIntRegion& aDirtyRegion,
gfx::DrawTarget* aFromDrawTarget);
nsIntRegion GetUpdateRegion() {
MOZ_ASSERT(mInUpdate, "update region only valid during update");
return mUpdateRegion;
@ -2734,29 +2730,6 @@ RectTextureImage::UpdateFromCGContext(const nsIntSize& aNewSize,
}
}
void
RectTextureImage::UpdateFromDrawTarget(const nsIntSize& aNewSize,
const nsIntRegion& aDirtyRegion,
gfx::DrawTarget* aFromDrawTarget)
{
mUpdateDrawTarget = aFromDrawTarget;
mBufferSize.SizeTo(aFromDrawTarget->GetSize().width, aFromDrawTarget->GetSize().height);
RefPtr<gfx::DrawTarget> drawTarget = BeginUpdate(aNewSize, aDirtyRegion);
if (drawTarget) {
if (drawTarget != aFromDrawTarget) {
RefPtr<gfx::SourceSurface> source = aFromDrawTarget->Snapshot();
gfx::Rect rect(0, 0, aFromDrawTarget->GetSize().width, aFromDrawTarget->GetSize().height);
gfxUtils::ClipToRegion(drawTarget, GetUpdateRegion());
drawTarget->DrawSurface(source, rect, rect,
gfx::DrawSurfaceOptions(),
gfx::DrawOptions(1.0, gfx::CompositionOp::OP_SOURCE));
drawTarget->PopClip();
}
EndUpdate();
}
mUpdateDrawTarget = nullptr;
}
void
RectTextureImage::Draw(GLManager* aManager,
const nsIntPoint& aLocation,