mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 831768 - Delay async painting calls so that they never nest within RPC calls. The Adobe Flash implementation doesn't expect this reentry and sometimes deadlocks. The Apple Java stub doesn't expect this reentry and corrupts NPRuntime objects. r=gfritzsche
--HG-- extra : rebase_source : 4cf6c2cd28fbfdf259c3ed2250135810fb2511a7
This commit is contained in:
parent
4b6f455e23
commit
0b88092a3d
@ -2713,18 +2713,16 @@ PluginInstanceChild::RecvAsyncSetWindow(const gfxSurfaceType& aSurfaceType,
|
||||
mCurrentAsyncSetWindowTask = nullptr;
|
||||
}
|
||||
|
||||
if (mPendingPluginCall) {
|
||||
// We shouldn't process this now. Run it later.
|
||||
mCurrentAsyncSetWindowTask =
|
||||
NewRunnableMethod<PluginInstanceChild,
|
||||
void (PluginInstanceChild::*)(const gfxSurfaceType&, const NPRemoteWindow&, bool),
|
||||
gfxSurfaceType, NPRemoteWindow, bool>
|
||||
(this, &PluginInstanceChild::DoAsyncSetWindow,
|
||||
aSurfaceType, aWindow, true);
|
||||
MessageLoop::current()->PostTask(FROM_HERE, mCurrentAsyncSetWindowTask);
|
||||
} else {
|
||||
DoAsyncSetWindow(aSurfaceType, aWindow, false);
|
||||
}
|
||||
// We shouldn't process this now because it may be received within a nested
|
||||
// RPC call, and both Flash and Java don't expect to receive setwindow calls
|
||||
// at arbitrary times.
|
||||
mCurrentAsyncSetWindowTask =
|
||||
NewRunnableMethod<PluginInstanceChild,
|
||||
void (PluginInstanceChild::*)(const gfxSurfaceType&, const NPRemoteWindow&, bool),
|
||||
gfxSurfaceType, NPRemoteWindow, bool>
|
||||
(this, &PluginInstanceChild::DoAsyncSetWindow,
|
||||
aSurfaceType, aWindow, true);
|
||||
MessageLoop::current()->PostTask(FROM_HERE, mCurrentAsyncSetWindowTask);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user