mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Backed out 2 changesets (bug 1138181, bug 1132874) for e10s crashes in browser_windowopen_reflows.js
CLOSED TREE Backed out changeset fdf4671db324 (bug 1132874) Backed out changeset ddd5517ce7d2 (bug 1138181)
This commit is contained in:
parent
5fbf8d8a74
commit
35e249e402
@ -70,7 +70,18 @@ PluginWidgetParent::~PluginWidgetParent()
|
||||
// A destroy call can actually get skipped if a widget is associated
|
||||
// with the last out-of-process page, make sure and cleanup any left
|
||||
// over widgets if we have them.
|
||||
KillWidget();
|
||||
if (mWidget) {
|
||||
#if defined(MOZ_WIDGET_GTK)
|
||||
mWidget->SetNativeData(NS_NATIVE_PLUGIN_OBJECT_PTR, (uintptr_t)0);
|
||||
mWrapper = nullptr;
|
||||
#elif defined(XP_WIN)
|
||||
::RemovePropW((HWND)mWidget->GetNativeData(NS_NATIVE_WINDOW),
|
||||
kPluginWidgetParentProperty);
|
||||
#endif
|
||||
mWidget->UnregisterPluginWindowForRemoteUpdates();
|
||||
mWidget->Destroy();
|
||||
mWidget = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
mozilla::dom::TabParent*
|
||||
@ -180,30 +191,14 @@ PluginWidgetParent::RecvCreate(nsresult* aResult)
|
||||
return true;
|
||||
}
|
||||
|
||||
void
|
||||
PluginWidgetParent::KillWidget()
|
||||
{
|
||||
PWLOG("PluginWidgetParent::KillWidget() widget=%p\n", mWidget);
|
||||
if (mWidget) {
|
||||
#if defined(MOZ_WIDGET_GTK)
|
||||
mWidget->SetNativeData(NS_NATIVE_PLUGIN_OBJECT_PTR, (uintptr_t)0);
|
||||
mWrapper = nullptr;
|
||||
#elif defined(XP_WIN)
|
||||
::RemovePropW((HWND)mWidget->GetNativeData(NS_NATIVE_WINDOW),
|
||||
kPluginWidgetParentProperty);
|
||||
#endif
|
||||
mWidget->UnregisterPluginWindowForRemoteUpdates();
|
||||
mWidget->Destroy();
|
||||
mWidget = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
PluginWidgetParent::Shutdown(ShutdownType aType)
|
||||
{
|
||||
PWLOG("PluginWidgetParent::Shutdown(%s)\n", aType == TAB_CLOSURE ? "TAB_CLOSURE" : "CONTENT");
|
||||
if (mWidget) {
|
||||
KillWidget();
|
||||
mWidget->UnregisterPluginWindowForRemoteUpdates();
|
||||
DebugOnly<nsresult> rv = mWidget->Destroy();
|
||||
NS_ASSERTION(NS_SUCCEEDED(rv), "widget destroy failure");
|
||||
mWidget = nullptr;
|
||||
unused << SendParentShutdown(aType);
|
||||
}
|
||||
}
|
||||
@ -212,7 +207,6 @@ void
|
||||
PluginWidgetParent::ActorDestroy(ActorDestroyReason aWhy)
|
||||
{
|
||||
PWLOG("PluginWidgetParent::ActorDestroy()\n");
|
||||
KillWidget();
|
||||
}
|
||||
|
||||
// Called by TabParent's Destroy() in response to an early tear down (Early
|
||||
|
@ -63,7 +63,6 @@ public:
|
||||
|
||||
private:
|
||||
void Shutdown(ShutdownType aType);
|
||||
void KillWidget();
|
||||
|
||||
// The chrome side native widget.
|
||||
nsCOMPtr<nsIWidget> mWidget;
|
||||
|
@ -252,6 +252,8 @@ CompositorChild::RecvUpdatePluginConfigurations(const nsIntPoint& aContentOffset
|
||||
// Handle invalidation, this can be costly, avoid if it is not needed.
|
||||
if (isVisible) {
|
||||
// invalidate region (widget origin)
|
||||
nsIntRect bounds = aPlugins[pluginsIdx].bounds();
|
||||
nsIntRect rect(0, 0, bounds.width, bounds.height);
|
||||
#if defined(XP_WIN)
|
||||
// Work around for flash's crummy sandbox. See bug 762948. This call
|
||||
// digs down into the window hirearchy, invalidating regions on
|
||||
|
@ -1818,7 +1818,8 @@ UpdatePluginWindowState(uint64_t aId)
|
||||
}
|
||||
|
||||
bool shouldComposePlugin = !!lts.mRoot &&
|
||||
!!lts.mRoot->GetParent();
|
||||
!!lts.mRoot->GetParent() &&
|
||||
lts.mUpdatedPluginDataAvailable;
|
||||
|
||||
bool shouldHidePlugin = (!lts.mRoot ||
|
||||
!lts.mRoot->GetParent()) &&
|
||||
@ -1831,7 +1832,6 @@ UpdatePluginWindowState(uint64_t aId)
|
||||
// calculating clipping.
|
||||
nsTArray<uintptr_t> aVisibleIdList;
|
||||
unused << lts.mParent->SendUpdatePluginVisibility(aVisibleIdList);
|
||||
lts.mUpdatedPluginDataAvailable = false;
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user