Bug 591555: Shadow layer resources are scoped to their PLayerParent, of which there may be many for one layer manager, so move resource management down into Shadow*Layer. r=joe sr=roc

This commit is contained in:
Chris Jones
2010-09-24 17:41:31 -05:00
parent ddab342535
commit d8c619a26a
5 changed files with 75 additions and 39 deletions

View File

@@ -1803,7 +1803,7 @@ public:
mOldYResolution = 1.0;
if (IsSurfaceDescriptorValid(mFrontBufferDescriptor)) {
BasicManager()->ShadowLayerManager::DestroySharedSurface(&mFrontBufferDescriptor);
BasicManager()->ShadowLayerManager::DestroySharedSurface(&mFrontBufferDescriptor, mAllocator);
}
}
@@ -1919,7 +1919,7 @@ public:
virtual void DestroyFrontBuffer()
{
if (mFrontSurface) {
BasicManager()->ShadowLayerManager::DestroySharedSurface(mFrontSurface);
BasicManager()->ShadowLayerManager::DestroySharedSurface(mFrontSurface, mAllocator);
}
mFrontSurface = nsnull;
}
@@ -2003,7 +2003,7 @@ public:
virtual void DestroyFrontBuffer()
{
if (mFrontSurface) {
BasicManager()->ShadowLayerManager::DestroySharedSurface(mFrontSurface);
BasicManager()->ShadowLayerManager::DestroySharedSurface(mFrontSurface, mAllocator);
}
mFrontSurface = nsnull;
}