mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-27 04:38:02 +00:00
Bug 893301. Some rebasing fixes. r=nical
This commit is contained in:
parent
c85dfc76bf
commit
8c5eb6d31b
@ -291,6 +291,20 @@ ContentClientRemoteBuffer::SwapBuffers(const nsIntRegion& aFrontUpdatedRegion)
|
||||
mFrontAndBackBufferDiffer = true;
|
||||
}
|
||||
|
||||
void
|
||||
ContentClientRemoteBuffer::OnActorDestroy()
|
||||
{
|
||||
if (mTextureClient) {
|
||||
mTextureClient->OnActorDestroy();
|
||||
}
|
||||
if (mTextureClientOnWhite) {
|
||||
mTextureClientOnWhite->OnActorDestroy();
|
||||
}
|
||||
for (size_t i = 0; i < mOldTextures.Length(); ++i) {
|
||||
mOldTextures[i]->OnActorDestroy();
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
DeprecatedContentClientRemoteBuffer::DestroyBuffers()
|
||||
{
|
||||
@ -645,6 +659,26 @@ ContentClientDoubleBuffered::UpdateDestinationFrom(const RotatedBuffer& aSource,
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
ContentClientDoubleBuffered::OnActorDestroy()
|
||||
{
|
||||
if (mTextureClient) {
|
||||
mTextureClient->OnActorDestroy();
|
||||
}
|
||||
if (mTextureClientOnWhite) {
|
||||
mTextureClientOnWhite->OnActorDestroy();
|
||||
}
|
||||
for (size_t i = 0; i < mOldTextures.Length(); ++i) {
|
||||
mOldTextures[i]->OnActorDestroy();
|
||||
}
|
||||
if (mFrontClient) {
|
||||
mFrontClient->OnActorDestroy();
|
||||
}
|
||||
if (mFrontClientOnWhite) {
|
||||
mFrontClientOnWhite->OnActorDestroy();
|
||||
}
|
||||
}
|
||||
|
||||
DeprecatedContentClientDoubleBuffered::~DeprecatedContentClientDoubleBuffered()
|
||||
{
|
||||
if (mDeprecatedTextureClient) {
|
||||
|
@ -242,6 +242,8 @@ public:
|
||||
return mTextureInfo;
|
||||
}
|
||||
|
||||
virtual void OnActorDestroy() MOZ_OVERRIDE;
|
||||
|
||||
protected:
|
||||
void DestroyBuffers();
|
||||
|
||||
@ -404,6 +406,8 @@ public:
|
||||
|
||||
virtual void SyncFrontBufferToBackBuffer() MOZ_OVERRIDE;
|
||||
|
||||
virtual void OnActorDestroy() MOZ_OVERRIDE;
|
||||
|
||||
protected:
|
||||
virtual void CreateFrontBuffer(const nsIntRect& aBufferRect) MOZ_OVERRIDE;
|
||||
virtual void DestroyFrontBuffer() MOZ_OVERRIDE;
|
||||
@ -441,13 +445,13 @@ public:
|
||||
|
||||
virtual void SyncFrontBufferToBackBuffer() MOZ_OVERRIDE;
|
||||
|
||||
virtual void OnActorDestroy() MOZ_OVERRIDE;
|
||||
|
||||
protected:
|
||||
virtual void CreateFrontBufferAndNotify(const nsIntRect& aBufferRect) MOZ_OVERRIDE;
|
||||
virtual void DestroyFrontBuffer() MOZ_OVERRIDE;
|
||||
virtual void LockFrontBuffer() MOZ_OVERRIDE;
|
||||
|
||||
virtual void OnActorDestroy() MOZ_OVERRIDE;
|
||||
|
||||
private:
|
||||
void UpdateDestinationFrom(const RotatedBuffer& aSource,
|
||||
const nsIntRegion& aUpdateRegion);
|
||||
|
@ -93,6 +93,15 @@ CompositableHost::GetTextureHost(uint64_t aTextureID)
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void
|
||||
CompositableHost::OnActorDestroy()
|
||||
{
|
||||
TextureHost* it = mFirstTexture;
|
||||
while (it) {
|
||||
it->OnActorDestroy();
|
||||
it = it->GetNextSibling();
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
CompositableHost::SetCompositor(Compositor* aCompositor)
|
||||
|
@ -112,7 +112,7 @@ public:
|
||||
* Our IPDL actor is being destroyed, get rid of any shmem resources now and
|
||||
* don't worry about compositing anymore.
|
||||
*/
|
||||
virtual void OnActorDestroy() = 0;
|
||||
virtual void OnActorDestroy();
|
||||
|
||||
// If base class overrides, it should still call the parent implementation
|
||||
virtual void SetCompositor(Compositor* aCompositor);
|
||||
|
@ -337,6 +337,18 @@ ContentHostBase::Dump(FILE* aFile,
|
||||
}
|
||||
#endif
|
||||
|
||||
void
|
||||
ContentHostBase::OnActorDestroy()
|
||||
{
|
||||
if (mTextureHost) {
|
||||
mTextureHost->OnActorDestroy();
|
||||
}
|
||||
if (mTextureHostOnWhite) {
|
||||
mTextureHostOnWhite->OnActorDestroy();
|
||||
}
|
||||
CompositableHost::OnActorDestroy();
|
||||
}
|
||||
|
||||
DeprecatedContentHostBase::DeprecatedContentHostBase(const TextureInfo& aTextureInfo)
|
||||
: ContentHost(aTextureInfo)
|
||||
, mPaintWillResample(false)
|
||||
|
@ -112,9 +112,8 @@ public:
|
||||
const char* aPrefix="",
|
||||
bool aDumpHtml=false) MOZ_OVERRIDE;
|
||||
#endif
|
||||
#ifdef MOZ_LAYERS_HAVE_LOG
|
||||
|
||||
virtual void PrintInfo(nsACString& aTo, const char* aPrefix) MOZ_OVERRIDE;
|
||||
#endif
|
||||
|
||||
virtual TextureHost* GetAsTextureHost() MOZ_OVERRIDE;
|
||||
|
||||
@ -124,6 +123,8 @@ public:
|
||||
|
||||
virtual void SetPaintWillResample(bool aResample) { mPaintWillResample = aResample; }
|
||||
|
||||
virtual void OnActorDestroy() MOZ_OVERRIDE;
|
||||
|
||||
protected:
|
||||
virtual nsIntPoint GetOriginOffset()
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user