mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1141917 - Remove unused member function RectTextureImage::UpdateFromDrawTarget(). r=mstange
This commit is contained in:
parent
530e295577
commit
89ae8d79ca
@ -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,
|
||||
|
Loading…
Reference in New Issue
Block a user