Backed out changeset 36d662fbab77 (bug 1350633) for failures in test_group_mouseevents.html a=backout
MozReview-Commit-ID: Gh9eflBppgq
This commit is contained in:
@@ -149,6 +149,11 @@ parent:
|
|||||||
|
|
||||||
async PPaymentRequest();
|
async PPaymentRequest();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return native data of root widget
|
||||||
|
*/
|
||||||
|
nested(inside_cpow) sync GetWidgetNativeData() returns (WindowsHandle value);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sends an NS_NATIVE_CHILD_OF_SHAREABLE_WINDOW to be adopted by the
|
* Sends an NS_NATIVE_CHILD_OF_SHAREABLE_WINDOW to be adopted by the
|
||||||
* widget's shareable window on the chrome side. Only used on Windows.
|
* widget's shareable window on the chrome side. Only used on Windows.
|
||||||
@@ -889,12 +894,6 @@ child:
|
|||||||
*/
|
*/
|
||||||
async SetOriginAttributes(OriginAttributes aOriginAttributes);
|
async SetOriginAttributes(OriginAttributes aOriginAttributes);
|
||||||
|
|
||||||
/**
|
|
||||||
* Pass the current handle for the current native widget to the content
|
|
||||||
* process, so it can be used by PuppetWidget.
|
|
||||||
*/
|
|
||||||
async SetWidgetNativeData(WindowsHandle aHandle);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* FIXME: write protocol!
|
* FIXME: write protocol!
|
||||||
|
|
||||||
|
|||||||
@@ -411,7 +411,6 @@ TabChild::TabChild(nsIContentChild* aManager,
|
|||||||
, mPendingDocShellPreserveLayers(false)
|
, mPendingDocShellPreserveLayers(false)
|
||||||
, mPendingDocShellReceivedMessage(false)
|
, mPendingDocShellReceivedMessage(false)
|
||||||
, mPendingDocShellBlockers(0)
|
, mPendingDocShellBlockers(0)
|
||||||
, mWidgetNativeData(0)
|
|
||||||
{
|
{
|
||||||
nsWeakPtr weakPtrThis(do_GetWeakReference(static_cast<nsITabChild*>(this))); // for capture by the lambda
|
nsWeakPtr weakPtrThis(do_GetWeakReference(static_cast<nsITabChild*>(this))); // for capture by the lambda
|
||||||
mSetAllowedTouchBehaviorCallback = [weakPtrThis](uint64_t aInputBlockId,
|
mSetAllowedTouchBehaviorCallback = [weakPtrThis](uint64_t aInputBlockId,
|
||||||
@@ -3213,13 +3212,6 @@ TabChild::RecvSetOriginAttributes(const OriginAttributes& aOriginAttributes)
|
|||||||
return IPC_OK();
|
return IPC_OK();
|
||||||
}
|
}
|
||||||
|
|
||||||
mozilla::ipc::IPCResult
|
|
||||||
TabChild::RecvSetWidgetNativeData(const WindowsHandle& aWidgetNativeData)
|
|
||||||
{
|
|
||||||
mWidgetNativeData = aWidgetNativeData;
|
|
||||||
return IPC_OK();
|
|
||||||
}
|
|
||||||
|
|
||||||
mozilla::plugins::PPluginWidgetChild*
|
mozilla::plugins::PPluginWidgetChild*
|
||||||
TabChild::AllocPPluginWidgetChild()
|
TabChild::AllocPPluginWidgetChild()
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -697,12 +697,6 @@ public:
|
|||||||
void AddPendingDocShellBlocker();
|
void AddPendingDocShellBlocker();
|
||||||
void RemovePendingDocShellBlocker();
|
void RemovePendingDocShellBlocker();
|
||||||
|
|
||||||
// The HANDLE object for the widget this TabChild in.
|
|
||||||
WindowsHandle WidgetNativeData()
|
|
||||||
{
|
|
||||||
return mWidgetNativeData;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual ~TabChild();
|
virtual ~TabChild();
|
||||||
|
|
||||||
@@ -744,8 +738,6 @@ protected:
|
|||||||
|
|
||||||
virtual mozilla::ipc::IPCResult RecvSetOriginAttributes(const OriginAttributes& aOriginAttributes) override;
|
virtual mozilla::ipc::IPCResult RecvSetOriginAttributes(const OriginAttributes& aOriginAttributes) override;
|
||||||
|
|
||||||
virtual mozilla::ipc::IPCResult RecvSetWidgetNativeData(const WindowsHandle& aWidgetNativeData) override;
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void HandleDoubleTap(const CSSPoint& aPoint, const Modifiers& aModifiers,
|
void HandleDoubleTap(const CSSPoint& aPoint, const Modifiers& aModifiers,
|
||||||
const ScrollableLayerGuid& aGuid);
|
const ScrollableLayerGuid& aGuid);
|
||||||
@@ -889,8 +881,6 @@ private:
|
|||||||
bool mPendingDocShellReceivedMessage;
|
bool mPendingDocShellReceivedMessage;
|
||||||
uint32_t mPendingDocShellBlockers;
|
uint32_t mPendingDocShellBlockers;
|
||||||
|
|
||||||
WindowsHandle mWidgetNativeData;
|
|
||||||
|
|
||||||
DISALLOW_EVIL_CONSTRUCTORS(TabChild);
|
DISALLOW_EVIL_CONSTRUCTORS(TabChild);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -292,17 +292,6 @@ TabParent::SetOwnerElement(Element* aElement)
|
|||||||
|
|
||||||
AddWindowListeners();
|
AddWindowListeners();
|
||||||
TryCacheDPIAndScale();
|
TryCacheDPIAndScale();
|
||||||
|
|
||||||
// Try to send down WidgetNativeData, now that this TabParent is associated
|
|
||||||
// with a widget.
|
|
||||||
nsCOMPtr<nsIWidget> widget = GetTopLevelWidget();
|
|
||||||
if (widget) {
|
|
||||||
WindowsHandle widgetNativeData = reinterpret_cast<WindowsHandle>(
|
|
||||||
widget->GetNativeData(NS_NATIVE_SHAREABLE_WINDOW));
|
|
||||||
if (widgetNativeData) {
|
|
||||||
Unused << SendSetWidgetNativeData(widgetNativeData);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@@ -2329,6 +2318,18 @@ TabParent::GetTopLevelWidget()
|
|||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mozilla::ipc::IPCResult
|
||||||
|
TabParent::RecvGetWidgetNativeData(WindowsHandle* aValue)
|
||||||
|
{
|
||||||
|
*aValue = 0;
|
||||||
|
nsCOMPtr<nsIWidget> widget = GetTopLevelWidget();
|
||||||
|
if (widget) {
|
||||||
|
*aValue = reinterpret_cast<WindowsHandle>(
|
||||||
|
widget->GetNativeData(NS_NATIVE_SHAREABLE_WINDOW));
|
||||||
|
}
|
||||||
|
return IPC_OK();
|
||||||
|
}
|
||||||
|
|
||||||
mozilla::ipc::IPCResult
|
mozilla::ipc::IPCResult
|
||||||
TabParent::RecvSetNativeChildOfShareableWindow(const uintptr_t& aChildWindow)
|
TabParent::RecvSetNativeChildOfShareableWindow(const uintptr_t& aChildWindow)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -305,6 +305,8 @@ public:
|
|||||||
|
|
||||||
virtual mozilla::ipc::IPCResult RecvGetWidgetRounding(int32_t* aValue) override;
|
virtual mozilla::ipc::IPCResult RecvGetWidgetRounding(int32_t* aValue) override;
|
||||||
|
|
||||||
|
virtual mozilla::ipc::IPCResult RecvGetWidgetNativeData(WindowsHandle* aValue) override;
|
||||||
|
|
||||||
virtual mozilla::ipc::IPCResult RecvSetNativeChildOfShareableWindow(const uintptr_t& childWindow) override;
|
virtual mozilla::ipc::IPCResult RecvSetNativeChildOfShareableWindow(const uintptr_t& childWindow) override;
|
||||||
|
|
||||||
virtual mozilla::ipc::IPCResult RecvDispatchFocusToTopLevelWindow() override;
|
virtual mozilla::ipc::IPCResult RecvDispatchFocusToTopLevelWindow() override;
|
||||||
|
|||||||
@@ -821,6 +821,8 @@ description =
|
|||||||
description =
|
description =
|
||||||
[PBrowser::PPluginWidget]
|
[PBrowser::PPluginWidget]
|
||||||
description =
|
description =
|
||||||
|
[PBrowser::GetWidgetNativeData]
|
||||||
|
description =
|
||||||
[PBrowser::DispatchFocusToTopLevelWindow]
|
[PBrowser::DispatchFocusToTopLevelWindow]
|
||||||
description =
|
description =
|
||||||
[PBrowser::NotifyIMEFocus]
|
[PBrowser::NotifyIMEFocus]
|
||||||
|
|||||||
@@ -1189,14 +1189,10 @@ PuppetWidget::GetNativeData(uint32_t aDataType)
|
|||||||
{
|
{
|
||||||
switch (aDataType) {
|
switch (aDataType) {
|
||||||
case NS_NATIVE_SHAREABLE_WINDOW: {
|
case NS_NATIVE_SHAREABLE_WINDOW: {
|
||||||
// NOTE: We can not have a tab child in some situations, such as when we're
|
MOZ_ASSERT(mTabChild, "Need TabChild to get the nativeWindow from!");
|
||||||
// rendering to a fake widget for thumbnails.
|
|
||||||
if (!mTabChild) {
|
|
||||||
NS_WARNING("Need TabChild to get the nativeWindow from!");
|
|
||||||
}
|
|
||||||
mozilla::WindowsHandle nativeData = 0;
|
mozilla::WindowsHandle nativeData = 0;
|
||||||
if (mTabChild) {
|
if (mTabChild) {
|
||||||
nativeData = mTabChild->WidgetNativeData();
|
mTabChild->SendGetWidgetNativeData(&nativeData);
|
||||||
}
|
}
|
||||||
return (void*)nativeData;
|
return (void*)nativeData;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user