From 77c34a416d5b35011ab361b4ffb25a2addfc2494 Mon Sep 17 00:00:00 2001 From: Robert O'Callahan Date: Thu, 26 Mar 2015 11:40:36 +1300 Subject: [PATCH] Bug 1143575. Convert SetCurrentImage(nullptr) callers to call ClearAllImages instead. r=nical --HG-- extra : commitid : BN8G7I6BhiD extra : rebase_source : 19fba64a55316faa5350274b21b4ee772c9cdad6 --- dom/plugins/ipc/PluginInstanceParent.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/dom/plugins/ipc/PluginInstanceParent.cpp b/dom/plugins/ipc/PluginInstanceParent.cpp index b9bbde9a4da6..e7042186ccd5 100644 --- a/dom/plugins/ipc/PluginInstanceParent.cpp +++ b/dom/plugins/ipc/PluginInstanceParent.cpp @@ -197,13 +197,10 @@ PluginInstanceParent::ActorDestroy(ActorDestroyReason why) UnsubclassPluginWindow(); } #endif - // After this method, the data backing the remote surface may no - // longer be valid. The X surface may be destroyed, or the shared - // memory backing this surface may no longer be valid. if (mFrontSurface) { mFrontSurface = nullptr; if (mImageContainer) { - mImageContainer->SetCurrentImage(nullptr); + mImageContainer->ClearAllImages(); } #ifdef MOZ_X11 FinishX(DefaultXDisplay()); @@ -639,7 +636,7 @@ PluginInstanceParent::RecvShow(const NPRect& updatedRect, container->SetCurrentImage(cairoImage); } else if (mImageContainer) { - mImageContainer->SetCurrentImage(nullptr); + mImageContainer->ClearAllImages(); } mFrontSurface = surface;