mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Backed out changeset f52300725e6f (bug 924622) for Linux Test Bustage
This commit is contained in:
parent
7f4e00ef38
commit
bd2330e021
@ -331,10 +331,6 @@ static void ReleaseImageClientNow(ImageClient* aClient)
|
||||
// static
|
||||
void ImageBridgeChild::DispatchReleaseImageClient(ImageClient* aClient)
|
||||
{
|
||||
if (!IsCreated()) {
|
||||
return;
|
||||
}
|
||||
|
||||
sImageBridgeChildSingleton->GetMessageLoop()->PostTask(
|
||||
FROM_HERE,
|
||||
NewRunnableFunction(&ReleaseImageClientNow, aClient));
|
||||
@ -349,10 +345,6 @@ static void ReleaseTextureClientNow(TextureClient* aClient)
|
||||
// static
|
||||
void ImageBridgeChild::DispatchReleaseTextureClient(TextureClient* aClient)
|
||||
{
|
||||
if (!IsCreated()) {
|
||||
return;
|
||||
}
|
||||
|
||||
sImageBridgeChildSingleton->GetMessageLoop()->PostTask(
|
||||
FROM_HERE,
|
||||
NewRunnableFunction(&ReleaseTextureClientNow, aClient));
|
||||
@ -372,10 +364,6 @@ static void UpdateImageClientNow(ImageClient* aClient, ImageContainer* aContaine
|
||||
void ImageBridgeChild::DispatchImageClientUpdate(ImageClient* aClient,
|
||||
ImageContainer* aContainer)
|
||||
{
|
||||
if (!IsCreated()) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (InImageBridgeChildThread()) {
|
||||
UpdateImageClientNow(aClient, aContainer);
|
||||
return;
|
||||
@ -400,10 +388,6 @@ static void FlushAllImagesSync(ImageClient* aClient, ImageContainer* aContainer,
|
||||
//static
|
||||
void ImageBridgeChild::FlushAllImages(ImageClient* aClient, ImageContainer* aContainer, bool aExceptFront)
|
||||
{
|
||||
if (!IsCreated()) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (InImageBridgeChildThread()) {
|
||||
FlushAllImagesNow(aClient, aContainer, aExceptFront);
|
||||
return;
|
||||
@ -593,14 +577,15 @@ bool ImageBridgeChild::StartUpOnThread(Thread* aThread)
|
||||
|
||||
void ImageBridgeChild::DestroyBridge()
|
||||
{
|
||||
if (!IsCreated()) {
|
||||
return;
|
||||
}
|
||||
NS_ABORT_IF_FALSE(!InImageBridgeChildThread(),
|
||||
"This method must not be called in this thread.");
|
||||
// ...because we are about to dispatch synchronous messages to the
|
||||
// ImageBridgeChild thread.
|
||||
|
||||
if (!IsCreated()) {
|
||||
return;
|
||||
}
|
||||
|
||||
ReentrantMonitor barrier("ImageBridgeDestroyTask lock");
|
||||
ReentrantMonitorAutoEnter autoMon(barrier);
|
||||
|
||||
@ -622,8 +607,7 @@ void ImageBridgeChild::DestroyBridge()
|
||||
|
||||
bool InImageBridgeChildThread()
|
||||
{
|
||||
return ImageBridgeChild::IsCreated() &&
|
||||
sImageBridgeChildThread->thread_id() == PlatformThread::CurrentId();
|
||||
return sImageBridgeChildThread->thread_id() == PlatformThread::CurrentId();
|
||||
}
|
||||
|
||||
MessageLoop * ImageBridgeChild::GetMessageLoop() const
|
||||
@ -640,7 +624,6 @@ void ImageBridgeChild::ConnectAsync(ImageBridgeParent* aParent)
|
||||
void
|
||||
ImageBridgeChild::IdentifyCompositorTextureHost(const TextureFactoryIdentifier& aIdentifier)
|
||||
{
|
||||
MOZ_ASSERT(IsCreated());
|
||||
if (sImageBridgeChildSingleton) {
|
||||
sImageBridgeChildSingleton->IdentifyTextureHost(aIdentifier);
|
||||
}
|
||||
|
@ -491,6 +491,12 @@ gfxPlatform::Shutdown()
|
||||
mozilla::gl::GLContextProviderEGL::Shutdown();
|
||||
#endif
|
||||
|
||||
// This will block this thread untill the ImageBridge protocol is completely
|
||||
// deleted.
|
||||
ImageBridgeChild::ShutDown();
|
||||
|
||||
CompositorParent::ShutDown();
|
||||
|
||||
delete gGfxPlatformPrefsLock;
|
||||
|
||||
gfxPrefs::DestroySingleton();
|
||||
|
@ -126,9 +126,6 @@ extern nsresult nsStringInputStreamConstructor(nsISupports *, REFNSIID, void **)
|
||||
#include "mozilla/ClearOnShutdown.h"
|
||||
#include "mozilla/SystemMemoryReporter.h"
|
||||
|
||||
#include "mozilla/layers/ImageBridgeChild.h"
|
||||
#include "mozilla/layers/CompositorParent.h"
|
||||
|
||||
#ifdef MOZ_VISUAL_EVENT_TRACER
|
||||
#include "mozilla/VisualEventTracer.h"
|
||||
#endif
|
||||
@ -745,11 +742,6 @@ ShutdownXPCOM(nsIServiceManager* servMgr)
|
||||
}
|
||||
}
|
||||
|
||||
// This must happen after the shutdown of media and widgets, which
|
||||
// are triggered by the NS_XPCOM_SHUTDOWN_OBSERVER_ID notification.
|
||||
mozilla::layers::ImageBridgeChild::ShutDown();
|
||||
mozilla::layers::CompositorParent::ShutDown();
|
||||
|
||||
NS_ProcessPendingEvents(thread);
|
||||
mozilla::scache::StartupCache::DeleteSingleton();
|
||||
if (observerService)
|
||||
|
Loading…
Reference in New Issue
Block a user